@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("/assets/fonts/plus-jakarta-sans-400.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("/assets/fonts/plus-jakarta-sans-500.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("/assets/fonts/plus-jakarta-sans-600.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("/assets/fonts/plus-jakarta-sans-700.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

:root {
    --ink: #171a17;
    --muted: #667066;
    --line: rgba(23, 26, 23, 0.08);
    --bg: #eef3ee;
    --card: #ffffff;
    --blue: #d5e3f8;
    --blue-ink: #17325f;
    --exodo: #1f4f9a;
    --gold: #e3a322;
    --danger: #9d2c2c;
    --warn: #8a5a12;
    --shadow: 0 1px 1px rgba(20, 28, 22, 0.04), 0 16px 40px rgba(20, 28, 22, 0.06);
    --radius: 24px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: "Plus Jakarta Sans", "Avenir Next", "Segoe UI", sans-serif;
    color: var(--ink);
    background:
        radial-gradient(900px 420px at 0% -10%, rgba(31, 79, 154, 0.08), transparent 55%),
        radial-gradient(720px 380px at 100% 0%, rgba(227, 163, 34, 0.12), transparent 48%),
        var(--bg);
    font-size: 15px;
    line-height: 1.5;
    min-height: 100vh;
}
a { color: var(--exodo); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }
img { max-width: 100%; }

.logo-plate {
    background: #fff;
    border-radius: 14px;
    display: grid;
    place-items: center;
    padding: 4px 8px 2px;
    box-shadow: inset 0 0 0 1px rgba(23, 26, 23, 0.06);
}
.logo-plate img { height: 34px; width: auto; display: block; }
.logo-plate-lg { padding: 8px 14px 6px; border-radius: 18px; width: fit-content; }
.logo-plate-lg img { height: 64px; }

.shell { min-height: 100vh; }
.dock {
    position: sticky;
    top: 14px;
    z-index: 20;
    margin: 14px 16px 0;
    padding: 8px 10px 8px 12px;
    display: flex;
    align-items: center;
    gap: 16px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: 999px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); min-width: max-content; }
.brand-copy strong { display: block; font-size: 15px; letter-spacing: -0.03em; line-height: 1.1; }
.brand-copy span { display: block; color: var(--muted); font-size: 12px; }
.tabs {
    display: flex;
    gap: 2px;
    margin: 0 auto;
    padding: 4px;
    background: #f3f5f2;
    border-radius: 999px;
}
.tabs a, .subnav a {
    color: #3d453f;
    font-weight: 600;
    font-size: 14px;
    padding: 8px 14px;
    border-radius: 999px;
    white-space: nowrap;
}
.tabs a.active { background: var(--ink); color: #fff; }
.tabs a:hover:not(.active) { background: rgba(23, 26, 23, 0.05); }
.who { display: flex; align-items: center; gap: 10px; min-width: max-content; }
.avatar {
    width: 36px; height: 36px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--exodo); color: #fff;
    font-size: 12px; font-weight: 700; letter-spacing: 0.04em;
}
.who-meta { display: flex; flex-direction: column; line-height: 1.15; }
.who-meta strong { font-size: 13px; }
.who-meta span { color: var(--muted); font-size: 12px; }
.who form { margin: 0; }

.subnav { display: flex; justify-content: center; margin-top: 12px; }
.subnav nav {
    display: flex;
    gap: 2px;
    padding: 4px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.75);
    box-shadow: 0 8px 24px rgba(20, 28, 22, 0.04);
    backdrop-filter: blur(12px);
}
.subnav a.active { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(20, 28, 22, 0.08); }

.page { width: min(1120px, calc(100% - 32px)); margin: 0 auto; padding: 28px 0 64px; }
.pagehead { margin-bottom: 18px; }
.crumb, .eyebrow {
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.pagehead h1 {
    margin-top: 4px;
    font-size: 40px;
    line-height: 1.05;
    letter-spacing: -0.045em;
    font-weight: 700;
}

.hello, .card, .tile {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.hello { padding: 26px 28px; margin-bottom: 14px; }
.hello h2 {
    margin: 8px 0 8px;
    font-size: 32px;
    letter-spacing: -0.04em;
    font-weight: 700;
}
.hello p:last-child { max-width: 62ch; color: #3d453f; }

.stats { display: grid; grid-template-columns: 1.15fr 1fr 1fr; gap: 14px; }
.tile {
    min-height: 156px;
    padding: 18px 20px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.tile span { color: var(--muted); font-size: 13px; font-weight: 600; }
.tile b {
    margin-top: auto;
    font-size: 44px;
    line-height: 1;
    letter-spacing: -0.05em;
    font-variant-numeric: tabular-nums;
}
.tile small { color: var(--muted); font-size: 13px; }
.tile-ink { background: var(--ink); color: #fff; }
.tile-ink span, .tile-ink small { color: rgba(255, 255, 255, 0.72); }
.tile-blue { background: var(--blue); color: var(--blue-ink); }
.tile-blue span, .tile-blue small { color: #3d5d8c; }
.runtime { margin-top: 16px; color: var(--muted); font-size: 12px; }

.card { padding: 18px 20px 16px; }
.card h2, .login h2 { font-size: 20px; letter-spacing: -0.03em; font-weight: 700; }
.section { margin-top: 18px; }
.section h2, .card h3 { font-size: 16px; margin-bottom: 8px; }
.toolbar {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    margin-bottom: 14px;
}
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.toolbar .row > input,
.toolbar .row > select,
.row > .field { width: auto; flex: 1 1 180px; min-width: 160px; max-width: 320px; }
.row > .field input,
.row > .field select { width: 100%; }
.split { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 14px; align-items: start; }

table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
th {
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: 700;
}
tr:last-child td { border-bottom: 0; }
td[colspan] { color: var(--muted); padding: 28px 8px; }
.num, .money { text-align: right; font-variant-numeric: tabular-nums; }
td a {
    display: inline-flex;
    padding: 5px 10px;
    border-radius: 999px;
    background: #f3f5f2;
    color: var(--ink);
    font-size: 13px;
    font-weight: 600;
}

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.wide { grid-column: 1 / -1; }
.field span { font-size: 12px; font-weight: 600; color: var(--muted); }
input, select, textarea {
    width: 100%;
    background: #fbfcfb;
    border: 1px solid #e1e6e1;
    border-radius: 12px;
    padding: 11px 12px;
}
textarea { min-height: 88px; resize: vertical; }
input:focus, select:focus, textarea:focus {
    outline: 3px solid rgba(31, 79, 154, 0.16);
    border-color: var(--exodo);
    background: #fff;
}
.btn, button.btn {
    border: 0;
    border-radius: 999px;
    padding: 10px 16px;
    cursor: pointer;
    background: var(--ink);
    color: #fff;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.btn:hover { background: #2a2e2a; }
.btn.ghost, .btn.quiet {
    background: transparent;
    color: var(--ink);
    border: 1px solid #d9e0da;
}
.btn.quiet { padding: 7px 12px; font-size: 13px; }
.btn.warn { background: var(--danger); }
.btn.warn:hover { background: #7d2222; }
.login form { display: flex; flex-direction: column; gap: 12px; margin-top: 22px; }
.login .btn { width: 100%; height: 46px; margin-top: 6px; }
.login h2 { font-size: 32px; letter-spacing: -0.04em; margin: 6px 0 8px; }

.flash { padding: 12px 14px; border-radius: 14px; margin-bottom: 14px; }
.flash.ok { background: #e7f6ef; color: #0d5a40; }
.flash.bad { background: #fdecec; color: var(--danger); }
.badge {
    display: inline-flex;
    border-radius: 999px;
    padding: 3px 9px;
    font-size: 12px;
    font-weight: 700;
    background: #eef1ee;
    text-transform: capitalize;
}
.badge.pending { background: #fff1d6; color: var(--warn); }
.badge.approved, .badge.active, .badge.final { background: #e7f6ef; color: #0d5a40; }
.badge.rejected, .badge.inactive { background: #fdecec; color: var(--danger); }
.banner {
    background: #fff6e8;
    color: #6d4a12;
    padding: 12px 14px;
    border-radius: 14px;
    margin-bottom: 14px;
}
.muted { color: var(--muted); }
.steps { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0 16px; }
.step { background: #f3f5f2; border-radius: 999px; padding: 5px 11px; font-size: 13px; font-weight: 600; }
.check { display: flex; gap: 8px; align-items: center; }
.check input { width: auto; }
dl.facts { display: grid; grid-template-columns: 160px 1fr; gap: 10px 12px; margin: 14px 0 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; }
.card ul { list-style: none; padding: 0; margin: 8px 0 12px; }
.card.narrow { max-width: 480px; }
.narrow form, form.stack { display: flex; flex-direction: column; gap: 12px; }
.list-head { display: flex; justify-content: space-between; gap: 16px; align-items: end; margin-bottom: 14px; }
.filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; flex: 1; align-items: end; }
.filter-actions { display: flex; gap: 8px; align-items: center; }
.row > input { width: auto; flex: 1 1 180px; min-width: 0; }
.inpage { display: flex; flex-wrap: wrap; gap: 6px; margin: -6px 0 18px; }
.inpage a {
    color: #3d453f;
    font-weight: 600;
    font-size: 14px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
}
.inpage a.active { background: var(--ink); color: #fff; }

.native-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    margin: -1px !important;
    padding: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    border: 0 !important;
    white-space: nowrap !important;
}
.picker, .datepick { position: relative; }
.picker-btn, .datepick-btn {
    width: 100%;
    text-align: left;
    background: #fbfcfb url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%23667066' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 12px center;
    border: 1px solid #e1e6e1;
    border-radius: 12px;
    padding: 11px 36px 11px 12px;
    cursor: pointer;
}
.picker-btn.is-empty, .datepick-btn.is-empty { color: #8b948c; }
.picker-btn:focus, .datepick-btn:focus {
    outline: 3px solid rgba(31, 79, 154, 0.16);
    border-color: var(--exodo);
    background-color: #fff;
}
.picker-menu, .datepick-pop {
    position: absolute;
    z-index: 40;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    max-height: 280px;
    overflow: auto;
    background: #fff;
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: 6px;
}
.datepick-pop { right: auto; width: 300px; max-height: none; padding: 12px; }
.picker-search { margin: 2px 2px 6px; }
.picker-item, .cal-nav, .cal-day {
    border: 0;
    background: transparent;
    cursor: pointer;
    font: inherit;
}
.picker-item {
    display: block;
    width: 100%;
    text-align: left;
    border-radius: 10px;
    padding: 8px 10px;
    color: var(--ink);
}
.picker-item.is-empty { color: var(--muted); }
.picker-item.is-on, .picker-item:hover { background: #f3f5f2; }
.picker-item.is-on { font-weight: 700; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.cal-nav {
    width: 32px;
    height: 32px;
    border-radius: 999px;
    background: #f3f5f2;
    font-size: 18px;
    line-height: 1;
}
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal-grid span { text-align: center; font-size: 11px; font-weight: 700; color: var(--muted); padding: 4px 0; }
.cal-day { height: 34px; border-radius: 10px; color: var(--ink); }
.cal-day.is-today { box-shadow: inset 0 0 0 1px #c5cdc6; }
.cal-day.is-on { background: var(--ink); color: #fff; }
.cal-day:hover:not(.is-on) { background: #f3f5f2; }
.time-row { display: flex; gap: 8px; align-items: center; margin-top: 12px; }
.time-row input { width: 72px; }
.card li { padding: 8px 0; border-bottom: 1px solid var(--line); }

.guest {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(320px, 1.05fr) minmax(340px, 0.95fr);
}
.guest-side {
    padding: 36px 48px 32px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 32px;
}
.guest-side h1 {
    margin-top: 12px;
    max-width: 11ch;
    font-size: 58px;
    line-height: 0.96;
    letter-spacing: -0.05em;
    font-weight: 700;
}
.guest-foot { color: var(--muted); }
.login-panel {
    margin: 16px;
    background: #fff;
    border-radius: 28px;
    box-shadow: var(--shadow);
    display: grid;
    place-items: center;
    padding: 36px 28px;
}
.login { width: min(380px, 100%); }

@media print {
    .dock, .subnav, .pagehead, .no-print, .who, .picker-menu, .datepick-pop { display: none !important; }
    body, .shell, .page, .card, .tile, .hello { background: white; box-shadow: none; }
    .page { width: auto; padding: 0; }
}
@media (max-width: 980px) {
    .shell, .guest, .guest-side, .login-panel, .dock, .page, .hello, .card, .tile {
        min-width: 0;
        max-width: 100%;
    }
    .shell, .guest { overflow-x: hidden; }
    .dock {
        width: calc(100% - 24px);
        margin: 12px auto 0;
        border-radius: 22px;
        flex-wrap: wrap;
        position: static;
    }
    .tabs {
        order: 3;
        flex: 1 0 100%;
        width: 0;
        min-width: 0;
        margin: 0;
        overflow-x: auto;
    }
    .tabs a { font-size: 13px; padding: 7px 9px; }
    .who { margin-left: auto; }
    .who-meta { display: none; }
    .stats, .form-grid, .split, dl.facts, .guest { grid-template-columns: 1fr; }
    .page { width: min(1120px, calc(100% - 24px)); }
    .pagehead h1, .hello h2 { font-size: 30px; }
    .hello, .card, .tile, .login-panel { min-width: 0; }
    .guest-side { min-height: auto; padding: 24px 20px 8px; gap: 20px; }
    .guest-side h1 { font-size: 36px; max-width: 100%; }
    .login, .login p, .hello p { max-width: 100%; }
    .login-panel { margin: 8px 12px 16px; padding: 28px 18px; overflow: hidden; }
    .toolbar, .list-head { align-items: stretch; flex-direction: column; }
    .filters { grid-template-columns: 1fr; }
    .toolbar .btn, .list-head > .btn { align-self: flex-start; }
    .inpage { overflow-x: auto; flex-wrap: nowrap; }
    .inpage a { white-space: nowrap; }
    .datepick-pop, .picker-menu {
        position: fixed;
        left: 12px;
        right: 12px;
        top: auto;
        bottom: 12px;
        width: auto;
        max-height: 70vh;
    }
}
