:root {
    color: #17233c;
    background: #f5f7fb;
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.5;
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    margin: 0;
}

.welcome {
    width: min(720px, calc(100% - 2rem));
    margin: 15vh auto 0;
    padding: 3rem;
    background: #ffffff;
    border: 1px solid #d7deea;
    border-radius: 0.75rem;
    box-shadow: 0 1rem 3rem rgba(23, 35, 60, 0.1);
}

.eyebrow {
    margin-bottom: 0.5rem;
    color: #174ea6;
    font-weight: 700;
}

h1 {
    margin: 0 0 1rem;
    font-size: clamp(2rem, 7vw, 3.5rem);
    line-height: 1.1;
}

@media (max-width: 600px) {
    .welcome {
        margin-top: 5vh;
        padding: 2rem 1.25rem;
    }
}

.auth-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem 1rem;
}

.auth-card {
    width: min(100%, 34rem);
    padding: 2.5rem;
    background: #ffffff;
    border: 1px solid #d9e2ef;
    border-radius: 1rem;
    box-shadow: 0 1.25rem 3rem rgba(22, 34, 58, 0.1);
}

.auth-card h1 {
    margin: 1rem 0 0.5rem;
}

.auth-card form {
    display: grid;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.auth-card label {
    margin-top: 0.5rem;
    font-weight: 700;
}

.auth-card input,
.auth-card select {
    width: 100%;
    padding: 0.8rem;
    font: inherit;
    color: #16223a;
    background: #ffffff;
    border: 1px solid #9aa9bd;
    border-radius: 0.5rem;
}

.auth-card input:focus,
.auth-card select:focus {
    outline: 3px solid rgba(29, 89, 170, 0.2);
    border-color: #1d59aa;
}

.auth-card button {
    margin-top: 1rem;
    padding: 0.9rem 1.25rem;
    font: inherit;
    font-weight: 700;
    color: #ffffff;
    background: #1d59aa;
    border: 0;
    border-radius: 0.5rem;
    cursor: pointer;
}

.auth-card button:hover {
    background: #174987;
}

.brand-link {
    color: #1d59aa;
    font-weight: 700;
    text-decoration: none;
}

.error-summary {
    margin-top: 1rem;
    padding: 1rem;
    color: #7a1c1c;
    background: #fff1f1;
    border: 1px solid #e7aaaa;
    border-radius: 0.5rem;
}

.error-summary ul {
    margin-bottom: 0;
}

.primary-link {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.8rem 1.1rem;
    color: #ffffff;
    font-weight: 700;
    text-decoration: none;
    background: #1d59aa;
    border-radius: 0.5rem;
}

.primary-link:hover {
    background: #174987;
}

.status-message {
    margin-top: 1rem;
    font-weight: 700;
    color: #17643a;
}

.checkbox-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.auth-card .checkbox-row input {
    width: auto;
}

.text-link {
    color: #1d59aa;
    font-weight: 700;
}

.auth-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
}

.secondary-link,
.secondary-button {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.8rem 1.1rem;
    color: #1d59aa;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    background: #ffffff;
    border: 1px solid #1d59aa;
    border-radius: 0.5rem;
    cursor: pointer;
}

.secondary-link:hover,
.secondary-button:hover {
    background: #eef5ff;
}

.logout-form {
    margin: 0;
}

.auth-card textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    font: inherit;
    color: #17223b;
    background: #fff;
    border: 1px solid #9fb2cf;
    border-radius: 0.5rem;
    resize: vertical;
}

.auth-card textarea:focus {
    outline: 3px solid rgba(37, 99, 181, 0.2);
    border-color: #2563b5;
}

.request-page {
    width: min(900px, calc(100% - 2rem));
}

.request-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    margin-bottom: 1.5rem;
}

.request-actions .primary-link,
.request-actions .secondary-link {
    margin-top: 1rem;
}

.request-card {
    margin-top: 1rem;
    padding: 1.25rem;
    background: #f8fafc;
    border: 1px solid #d4deec;
    border-radius: 0.75rem;
}

.request-card-heading {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    justify-content: space-between;
}

.request-card h2 {
    margin: 0.2rem 0 0;
    font-size: 1.4rem;
}

.request-type,
.request-date {
    margin: 0;
    color: #53627a;
}

.status-badge {
    padding: 0.4rem 0.65rem;
    color: #155e35;
    font-weight: 700;
    background: #dcfce7;
    border-radius: 999px;
}

.empty-message {
    margin-top: 1.5rem;
    padding: 1rem;
    background: #f8fafc;
    border: 1px dashed #9fb2cf;
    border-radius: 0.75rem;
}

.request-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    margin-top: 1.25rem;
}

.request-card-actions .secondary-link {
    margin-top: 0;
}

.request-card-actions form {
    margin: 0;
}

.danger-button {
    padding: 0.7rem 1rem;
    color: #b42318;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    background: #fff;
    border: 1px solid #b42318;
    border-radius: 0.5rem;
}

.danger-button:hover {
    color: #fff;
    background: #b42318;
}

.section-heading {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-size: 1.7rem;
}

.assigned-section {
    margin-top: 3rem;
}

.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: end;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f8fafc;
    border: 1px solid #d4deec;
    border-radius: 0.75rem;
}

.filter-form label {
    width: 100%;
    font-weight: 700;
}

.filter-form select {
    min-width: 240px;
    padding: 0.75rem;
    color: #17223b;
    font: inherit;
    background: #fff;
    border: 1px solid #9fb2cf;
    border-radius: 0.5rem;
}

.filter-form .primary-button,
.request-card .primary-button {
    width: auto;
    margin-top: 0;
}

.filter-form .secondary-link {
    margin-top: 0;
    padding: 0.75rem;
}

.request-card h3 {
    margin: 0.2rem 0 0;
    font-size: 1.4rem;
}

.customer-details {
    font-weight: 700;
}

.status-form {
    display: grid;
    gap: 0.65rem;
    margin-top: 1.25rem;
}

.status-form label {
    font-weight: 700;
}

.status-form textarea {
    width: 100%;
    padding: 0.8rem;
    color: #17223b;
    font: inherit;
    border: 1px solid #9fb2cf;
    border-radius: 0.5rem;
    resize: vertical;
}

.status-form .primary-button {
    justify-self: start;
}

.provider-notes {
    margin-top: 1rem;
    padding: 0.9rem;
    background: #eef5ff;
    border-radius: 0.5rem;
}

.primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1rem;
    color: #fff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    background: #2563b5;
    border: 1px solid #2563b5;
    border-radius: 0.5rem;
}

.primary-button:hover {
    background: #174f97;
    border-color: #174f97;
}

.admin-page {
    width: min(1100px, calc(100% - 2rem));
}

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

.summary-card {
    padding: 1.25rem;
    background: #f8fafc;
    border: 1px solid #d4deec;
    border-radius: 0.75rem;
}

.summary-card p {
    margin: 0;
    color: #53627a;
}

.summary-card strong {
    display: block;
    margin-top: 0.4rem;
    color: #17223b;
    font-size: 2rem;
}

.admin-filter-form {
    display: grid;
    grid-template-columns: repeat(
        auto-fit,
        minmax(190px, 1fr)
    );
    gap: 1rem;
    align-items: end;
    margin: 1.5rem 0;
    padding: 1rem;
    background: #f8fafc;
    border: 1px solid #d4deec;
    border-radius: 0.75rem;
}

.admin-filter-form div {
    display: grid;
    gap: 0.4rem;
}

.admin-filter-form label {
    font-weight: 700;
}

.admin-filter-form select {
    width: 100%;
    padding: 0.75rem;
    color: #17223b;
    font: inherit;
    background: #fff;
    border: 1px solid #9fb2cf;
    border-radius: 0.5rem;
}

.admin-filter-form .secondary-link {
    margin-top: 0;
    padding: 0.75rem;
}

.table-wrapper {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #d4deec;
    border-radius: 0.75rem;
}

.admin-table {
    width: 100%;
    min-width: 750px;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 0.85rem;
    text-align: left;
    border-bottom: 1px solid #d4deec;
}

.admin-table th {
    color: #17223b;
    background: #eef5ff;
}

.admin-table tbody tr:last-child td {
    border-bottom: 0;
}