* {
    box-sizing: border-box;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
    margin: 0;
    background: #f4f6f8;
    color: #12263f;
}

.container {
    width: min(1100px, 90%);
    margin: 0 auto;
}

.app-header {
    background: #1d3557;
    color: #fff;
    padding: 1rem 0;
}

.app-header .brand a {
    color: #fff;
    font-weight: bold;
    text-decoration: none;
    font-size: 1.25rem;
}

.app-header nav {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.app-header nav a {
    color: #f1faee;
    text-decoration: none;
    font-weight: 500;
}

.logout-form {
    margin: 0;
}

.logout-form button {
    background: #e63946;
    border: none;
    color: #fff;
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    cursor: pointer;
}

main {
    padding: 2rem 0;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.card {
    background: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.card .count {
    font-size: 2.5rem;
    margin: 0;
}

.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

th, td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e9ecef;
    text-align: left;
}

th {
    background: #f8f9fa;
    font-weight: 600;
}

.table-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.button, button {
    display: inline-block;
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    background: #457b9d;
    color: #fff;
    border: none;
    cursor: pointer;
    text-decoration: none;
}

form {
    background: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

form label {
    font-weight: 600;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

input, textarea, select {
    padding: 0.5rem;
    border-radius: 4px;
    border: 1px solid #cfd8e3;
    font: inherit;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.flash {
    padding: 0.75rem 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.flash-success {
    background: #d8f3dc;
    color: #1b4332;
}

.flash-error {
    background: #ffe3e3;
    color: #b02a37;
}

.auth-card {
    max-width: 400px;
    margin: 4rem auto;
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.app-footer {
    border-top: 1px solid #e0e0e0;
    padding: 1rem 0;
    background: #fff;
    color: #6c757d;
    margin-top: 2rem;
}

.warning {
    padding: 0.75rem;
    background: #fff3cd;
    color: #856404;
    border-radius: 4px;
}
