body {
    font-family: -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    color: #1f2933;
    background: #f7f8fa;
}

.navbar {
    background: #1f2933;
    padding: 0.75rem 1.5rem;
    display: flex;
    gap: 1.25rem;
    align-items: center;
    flex-wrap: wrap;
}

.navbar a {
    color: #fff;
    text-decoration: none;
    font-size: 0.95rem;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.1rem;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1.5rem;
}

.btn {
    display: inline-block;
    background: #2563eb;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

th, td {
    text-align: left;
    padding: 0.6rem;
    border-bottom: 1px solid #e4e7eb;
    vertical-align: top;
}

.form-group {
    margin-bottom: 1rem;
}

label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

input[type="text"], input[type="email"], input[type="number"], input[type="date"],
textarea, select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #cbd2d9;
    border-radius: 4px;
    box-sizing: border-box;
}

.text-danger {
    color: #b91c1c;
}

.footer {
    text-align: center;
    color: #7b8794;
    padding: 1.5rem;
    font-size: 0.85rem;
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.stat-tile {
    background: #fff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 1.25rem;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #2563eb;
}

.stat-label {
    color: #52606d;
    font-size: 0.9rem;
}

.quick-add-grid {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: #f7f8fa;
    margin: 0;
}

.login-box {
    background: #fff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 2rem;
    width: 100%;
    max-width: 340px;
}

.login-box h1 {
    font-size: 1.25rem;
    margin-top: 0;
    margin-bottom: 1.5rem;
    text-align: center;
}

.navbar-spacer {
    flex: 1;
}

.logout-form {
    display: inline;
}

.logout-form button {
    background: none;
    border: none;
    color: #fff;
    font-size: 0.95rem;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
}

/* Required-field marker: piggybacks on the data-val-required attribute that
   ASP.NET Core's tag helpers already emit for non-nullable/[Required] model
   properties, so this stays correct automatically as fields are added -
   no per-field markup needed. Checkboxes are excluded since they always
   post a value (true/false) and never actually block saving. */
.form-group label:has(+ input:not([type="checkbox"])[data-val-required])::after,
.form-group label:has(+ select[data-val-required])::after {
    content: " *";
    color: #b91c1c;
    font-weight: 700;
}

.required-hint {
    color: #52606d;
    font-size: 0.9rem;
}

th a {
    color: inherit;
    text-decoration: none;
}

th a:hover {
    text-decoration: underline;
}

.due-date-warning {
    border: 1px solid #b91c1c;
    padding: 0.75rem;
    border-radius: 6px;
    background: #fef2f2;
}

.badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    background: #e4e7eb;
    font-size: 0.8rem;
}
