* {
    box-sizing: border-box;
}

:root {
    --background: #f5f7fb;
    --surface: #ffffff;
    --surface-soft: #f8fafc;

    --text: #18202f;
    --text-muted: #697386;

    --primary: #263b62;
    --primary-hover: #1d2e4d;

    --accent: #d7a84d;

    --border: #e5e9f0;

    --success: #27835c;
    --warning: #b97819;

    --radius: 16px;

    --shadow:
        0 8px 30px rgba(18, 38, 63, 0.06);
}


html,
body {
    margin: 0;
    min-height: 100%;
}


body {
    font-family:
        Inter,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    background: var(--background);
    color: var(--text);
}


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


.app-shell {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    min-height: 100vh;
}


.sidebar {
    background: var(--primary);
    color: white;

    padding: 28px 20px;

    min-height: 100vh;
}


.brand {
    display: flex;
    align-items: center;
    gap: 12px;

    margin-bottom: 42px;
}


.brand-mark {
    width: 42px;
    height: 42px;

    border-radius: 12px;

    background: var(--accent);
    color: var(--primary);

    display: grid;
    place-items: center;

    font-size: 22px;
    font-weight: 800;
}


.brand-name {
    font-weight: 700;
}


.brand-subtitle {
    margin-top: 2px;

    font-size: 12px;

    color: rgba(255,255,255,.65);
}


.nav {
    display: grid;
    gap: 8px;
}


.nav-item {
    padding: 12px 14px;

    border-radius: 10px;

    color: rgba(255,255,255,.72);

    transition: .15s ease;
}


.nav-item:hover {
    color: white;

    background: rgba(255,255,255,.08);
}


.nav-item.active {
    color: white;

    background: rgba(255,255,255,.13);
}


.main-content {
    width: 100%;
    max-width: 1500px;

    padding: 36px 42px;
}


.page-header {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    align-items: center;

    margin-bottom: 26px;
}


.eyebrow {
    color: var(--accent);

    letter-spacing: .11em;
    font-weight: 800;
    font-size: 12px;
}


h1 {
    margin: 6px 0 3px;

    font-size: 32px;
    letter-spacing: -.03em;
}


.header-subtitle {
    margin: 0;

    color: var(--text-muted);
}


.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}


.select-control {
    height: 44px;

    min-width: 190px;

    border: 1px solid var(--border);

    border-radius: 10px;

    background: white;

    padding: 0 14px;

    font-size: 14px;

    color: var(--text);
}


.button {
    min-height: 44px;

    padding: 0 18px;

    border-radius: 10px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    font-size: 14px;
    font-weight: 700;

    border: 0;

    cursor: pointer;
}


.button-primary {
    background: var(--primary);
    color: white;
}


.button-primary:hover {
    background: var(--primary-hover);
}


.week-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;

    padding: 22px 24px;

    border-radius: var(--radius);

    background: var(--primary);
    color: white;

    margin-bottom: 22px;
}


.week-label {
    font-size: 11px;

    letter-spacing: .12em;

    color: rgba(255,255,255,.65);

    margin-bottom: 5px;
}


.week-title {
    font-size: 20px;
    font-weight: 700;
}


.week-pill {
    padding: 8px 13px;

    border-radius: 999px;

    background: rgba(255,255,255,.12);

    font-size: 13px;
}


.stat-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 16px;

    margin-bottom: 22px;
}


.stat-card {
    background: var(--surface);

    border: 1px solid var(--border);

    border-radius: var(--radius);

    box-shadow: var(--shadow);

    padding: 20px;
}


.stat-label {
    display: block;

    color: var(--text-muted);

    font-size: 13px;

    margin-bottom: 10px;
}


.stat-number {
    display: block;

    font-size: 32px;

    letter-spacing: -.04em;

    margin-bottom: 6px;
}


.stat-detail {
    color: var(--text-muted);

    font-size: 12px;
}


.scoreboard-card {
    background: var(--surface);

    border: 1px solid var(--border);

    border-radius: var(--radius);

    box-shadow: var(--shadow);

    overflow: hidden;
}


.section-heading {
    padding: 22px 24px;

    border-bottom: 1px solid var(--border);
}


.section-heading h2 {
    margin: 0 0 4px;

    font-size: 18px;
}


.section-heading p {
    margin: 0;

    color: var(--text-muted);

    font-size: 13px;
}


.table-wrapper {
    overflow-x: auto;
}


.scoreboard-table {
    width: 100%;

    border-collapse: collapse;
}


.scoreboard-table th {
    padding: 13px 20px;

    text-align: left;

    font-size: 11px;

    letter-spacing: .06em;

    text-transform: uppercase;

    color: var(--text-muted);

    background: var(--surface-soft);
}


.scoreboard-table td {
    padding: 17px 20px;

    border-top: 1px solid var(--border);

    font-size: 14px;
}


.staff-name {
    font-weight: 700;
}


.staff-email {
    margin-top: 3px;

    color: var(--text-muted);

    font-size: 12px;
}


.progress-bar {
    width: 100px;
    height: 7px;

    border-radius: 999px;

    background: #ebeff4;

    overflow: hidden;
}


.progress-fill {
    height: 100%;

    border-radius: inherit;

    background: var(--primary);
}


.goal-cell {
    display: flex;
    align-items: center;
    gap: 10px;
}


@media (max-width: 1000px) {

    .app-shell {
        grid-template-columns: 1fr;
    }

    .sidebar {
        min-height: auto;
    }

    .stat-grid {
        grid-template-columns: repeat(2, 1fr);
    }

}


@media (max-width: 650px) {

    .main-content {
        padding: 22px 16px;
    }

    .page-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .header-actions {
        width: 100%;
        flex-direction: column;
    }

    .select-control,
    .button {
        width: 100%;
    }

    .stat-grid {
        grid-template-columns: 1fr;
    }

}
/* ---------------------------------------
   Scoreboard Data
--------------------------------------- */

.weekly-count {
    font-weight: 700;
    font-size: 15px;
}

.weekly-goal {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 12px;
}

.count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 36px;
    height: 30px;

    padding: 0 10px;

    border-radius: 999px;

    font-weight: 700;
    font-size: 13px;
}

.care-badge {
    background: #eef7f2;
    color: #267052;
}

.connect-badge {
    background: #eef3f9;
    color: #2f5b8c;
}

.dashboard-error {
    padding: 20px;

    color: #b42318;

    line-height: 1.6;
}

.scoreboard-table tbody tr {
    transition: background 0.15s ease;
}

.scoreboard-table tbody tr:hover {
    background: #fafbfd;
}
/* ---------------------------------------
   Interaction Form
--------------------------------------- */

.interaction-layout {
    max-width: 850px;
}


.interaction-card {
    background: var(--surface);

    border: 1px solid var(--border);

    border-radius: var(--radius);

    box-shadow: var(--shadow);

    overflow: hidden;
}


.interaction-form {
    padding: 28px;
}


.form-group {
    margin-bottom: 22px;
}


.form-group label {
    display: block;

    margin-bottom: 8px;

    color: var(--text);

    font-size: 13px;

    font-weight: 700;
}


.form-group select,
.form-group input[type="date"],
.form-group input[type="text"] {
    width: 100%;
    height: 48px;

    padding: 0 14px;

    border: 1px solid var(--border);

    border-radius: 10px;

    background: white;

    color: var(--text);

    font-family: inherit;
    font-size: 14px;
}


.form-group select:focus,
.form-group input:focus {
    outline: none;

    border-color: var(--primary);

    box-shadow:
        0 0 0 3px
        rgba(38, 59, 98, 0.10);
}


.form-row {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 18px;
}


.mode-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 14px;
}


.mode-option {
    cursor: pointer;
}


.mode-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}


.mode-card {
    min-height: 110px;

    display: flex;
    flex-direction: column;
    justify-content: center;

    padding: 20px;

    border: 2px solid var(--border);

    border-radius: 14px;

    background: white;

    transition:
        border-color .15s ease,
        background .15s ease,
        transform .15s ease;
}


.mode-card strong {
    margin-bottom: 5px;

    font-size: 18px;
}


.mode-card small {
    color: var(--text-muted);

    line-height: 1.45;
}


.mode-option:hover .mode-card {
    transform: translateY(-1px);

    border-color: #bcc7d7;
}


.mode-option input:checked + .mode-card {
    border-color: var(--primary);

    background: #f4f7fb;
}


.season-box {
    margin-bottom: 26px;

    padding: 16px 18px;

    display: flex;
    justify-content: space-between;
    align-items: center;

    border-radius: 12px;

    background: var(--surface-soft);

    border: 1px solid var(--border);
}


.season-box-label {
    color: var(--text-muted);

    font-size: 12px;

    text-transform: uppercase;

    letter-spacing: .06em;
}


.form-actions {
    display: flex;

    justify-content: flex-end;

    gap: 10px;

    padding-top: 22px;

    border-top: 1px solid var(--border);
}


.form-message {
    margin-bottom: 22px;

    padding: 14px 16px;

    border-radius: 10px;

    font-size: 14px;

    line-height: 1.5;
}


.form-message-success {
    background: #edf8f2;

    border: 1px solid #ccebdc;

    color: #17633f;
}


.form-message-error {
    background: #fff1f0;

    border: 1px solid #ffd5d2;

    color: #a5231a;
}


button:disabled {
    cursor: wait;

    opacity: .7;
}


@media (max-width: 650px) {

    .form-row,
    .mode-grid {
        grid-template-columns: 1fr;
    }

    .interaction-form {
        padding: 20px;
    }

    .form-actions {
        flex-direction: column-reverse;
    }

    .form-actions .button {
        width: 100%;
    }

}