:root {
  --bg: #f5f3ee; --surface: #ffffff; --ink: #14213d; --ink-2: #33415c; --muted: #6b7385; --line: #e4e0d6;
  --brass: #a8843f; --brass-soft: #f3ead9; --navy: #14213d; --navy-2: #1d2e52;
  --good: #1a7f5a; --good-soft: #e3f3ec; --warn: #b7791f; --warn-soft: #fbf0d9; --bad: #b42318; --bad-soft: #fbe6e3;
  --radius: 14px; --shadow: 0 1px 2px rgba(20,33,61,.06), 0 8px 24px rgba(20,33,61,.06);
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --serif: "Iowan Old Style", "Palatino Linotype", Georgia, serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font: 14px/1.5 var(--sans); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; margin: 0; letter-spacing: -.01em; }
h1 { font-size: 30px; line-height: 1.15; } h2 { font-size: 19px; } h3 { font-size: 15px; font-family: var(--sans); }
button, select, input { font: inherit; color: inherit; }
.boot { padding: 80px; text-align: center; color: var(--muted); }

.shell { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }
.side { background: linear-gradient(180deg, var(--navy) 0%, #0d1730 100%); color: #dfe5f2; padding: 26px 18px; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.brand { padding: 0 8px 22px; border-bottom: 1px solid rgba(255,255,255,.1); margin-bottom: 16px; }
.brand .eyebrow { font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: #c9a965; }
.brand .name { font-family: var(--serif); font-size: 21px; color: #fff; margin-top: 4px; line-height: 1.2; }
.brand .sub { font-size: 12px; color: #9aa6c0; margin-top: 4px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 9px; color: #c3cce0; font-weight: 500; margin: 2px 0; }
.nav a:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav a.on { background: rgba(201,169,101,.16); color: #fff; box-shadow: inset 2px 0 0 #c9a965; }
.nav .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .6; }
.side .foot { margin-top: auto; font-size: 12px; color: #8f9bb7; padding: 14px 8px 0; border-top: 1px solid rgba(255,255,255,.1); }
.side .foot b { color: #e6ebf6; font-weight: 600; display: block; }
.side .foot button { background: none; border: 0; color: #c9a965; padding: 6px 0 0; cursor: pointer; }
.main { padding: 34px 40px 80px; max-width: 1400px; width: 100%; }
.head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 22px; flex-wrap: wrap; }
.head .kicker { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--brass); font-weight: 600; margin-bottom: 6px; }
.head p { margin: 6px 0 0; color: var(--muted); max-width: 720px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.btn { border: 1px solid var(--line); background: var(--surface); padding: 8px 14px; border-radius: 9px; cursor: pointer; font-weight: 500; }
.btn:hover { border-color: #cfc8b8; } .btn.primary { background: var(--navy); border-color: var(--navy); color: #fff; } .btn.primary:hover { background: var(--navy-2); }
.btn.small { padding: 5px 10px; font-size: 12.5px; } .btn:disabled { opacity: .5; cursor: default; }

.filters { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 20px; align-items: center; }
.filters label { display: flex; flex-direction: column; font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); gap: 3px; }
.filters select, .filters input, .field input, .field select { border: 1px solid var(--line); border-radius: 8px; padding: 6px 8px; background: #fff; min-width: 118px; font-size: 13px; text-transform: none; letter-spacing: 0; color: var(--ink); }
.filters .clear { margin-left: auto; align-self: flex-end; }
.grid { display: grid; gap: 16px; } .kpis { grid-template-columns: repeat(4, minmax(0,1fr)); margin-bottom: 16px; } .two { grid-template-columns: repeat(2, minmax(0,1fr)); } .three { grid-template-columns: 2fr 1fr; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; min-width: 0; }
.card > h2 { margin-bottom: 4px; } .card > .hint { color: var(--muted); font-size: 12.5px; margin: 0 0 10px; }
.kpi .label { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.kpi .value { font-family: var(--serif); font-size: 34px; line-height: 1.1; margin-top: 6px; } .kpi .value small { font-size: 15px; color: var(--muted); font-family: var(--sans); }
.kpi .note { color: var(--muted); font-size: 12.5px; margin-top: 4px; } .kpi.accent { background: linear-gradient(135deg, #14213d, #22376a); color: #fff; border-color: transparent; } .kpi.accent .label, .kpi.accent .note { color: #c8d1e6; }
.chart { height: 290px; } .chart.tall { height: 1180px; } .chart.mid { height: 420px; }
.findings { margin: 8px 0 0; padding: 0; list-style: none; } .findings li { padding: 9px 0 9px 22px; border-top: 1px solid var(--line); position: relative; } .findings li:first-child { border-top: 0; }
.findings li::before { content: ""; position: absolute; left: 2px; top: 17px; width: 8px; height: 8px; border-radius: 2px; background: var(--brass); transform: rotate(45deg); }

table { width: 100%; border-collapse: collapse; } th { text-align: left; font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding: 9px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; cursor: default; }
th.sort { cursor: pointer; } th.sort:hover { color: var(--ink); } td { padding: 10px; border-bottom: 1px solid #efece4; vertical-align: middle; } tr.link { cursor: pointer; } tr.link:hover td { background: #faf8f3; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; } .sub { color: var(--muted); font-size: 12.5px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; background: #eef0f5; color: var(--ink-2); white-space: nowrap; }
.chip.good { background: var(--good-soft); color: var(--good); } .chip.warn { background: var(--warn-soft); color: var(--warn); } .chip.bad { background: var(--bad-soft); color: var(--bad); } .chip.brass { background: var(--brass-soft); color: #7a5f28; }
.score { display: inline-grid; place-items: center; min-width: 40px; padding: 3px 8px; border-radius: 8px; font-weight: 700; font-variant-numeric: tabular-nums; }
.score.good { background: var(--good-soft); color: var(--good); } .score.warn { background: var(--warn-soft); color: var(--warn); } .score.bad { background: var(--bad-soft); color: var(--bad); } .score.none { background: #eef0f5; color: var(--muted); }
.bar { height: 8px; border-radius: 99px; background: #ece8dd; overflow: hidden; } .bar > i { display: block; height: 100%; border-radius: 99px; background: var(--navy); }
.pillar { display: grid; grid-template-columns: 150px 1fr 64px; gap: 12px; align-items: center; padding: 7px 0; } .pillar span:last-child { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.empty { text-align: center; padding: 56px 20px; color: var(--muted); } .empty h2 { color: var(--ink); margin-bottom: 8px; }
.banner { background: var(--warn-soft); color: #7a5410; border: 1px solid #ecd9a8; padding: 9px 14px; border-radius: 10px; margin-bottom: 16px; font-weight: 500; }

/* call page */
.player { background: linear-gradient(180deg, #14213d, #101a33); color: #fff; border: 0; padding: 20px 22px; }
.player .wave { margin: 6px 0 4px; min-height: 76px; } .lane { position: relative; height: 8px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; margin-bottom: 14px; }
.lane i { position: absolute; top: 0; bottom: 0; } .lane i.caller { background: #c9a965; } .lane i.hotel { background: #7fb6ff; }
.controls { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; } .controls .time { font-variant-numeric: tabular-nums; color: #c8d1e6; min-width: 96px; }
.controls button, .controls select { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); color: #fff; border-radius: 9px; padding: 7px 12px; cursor: pointer; } .controls button:hover { background: rgba(255,255,255,.16); }
.controls .play { background: #c9a965; border-color: #c9a965; color: #14213d; font-weight: 700; min-width: 86px; } .controls .play:hover { background: #d8ba7c; } .controls select option { color: #14213d; }
.controls .spacer { flex: 1; } .controls input[type=range] { width: 90px; accent-color: #c9a965; } .legend { display: flex; gap: 14px; font-size: 12px; color: #c8d1e6; } .legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; }
.transcript { max-height: 640px; overflow: auto; padding-right: 6px; scroll-behavior: smooth; }
.turn { display: grid; grid-template-columns: 54px 1fr; gap: 12px; padding: 10px 10px; border-radius: 10px; border-left: 3px solid transparent; } .turn.active { background: #faf6ec; border-left-color: var(--brass); }
.turn .ts { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 12px; padding-top: 2px; cursor: pointer; } .turn .who { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; margin-bottom: 2px; }
.turn.caller .who { color: var(--brass); } .turn.hotel .who { color: #2456a6; } .turn .w { cursor: pointer; border-radius: 4px; padding: 1px 0; } .turn .w:hover { background: #f0ead9; } .turn .w.said { color: var(--ink); } .turn .w.now { background: #f3dfae; }
.turn p { margin: 0; color: #4a5568; font-size: 15px; line-height: 1.6; }
.crit { display: grid; grid-template-columns: 22px 1fr auto; gap: 8px; padding: 8px 0; border-top: 1px solid #efece4; align-items: start; } .crit .mark { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 700; margin-top: 2px; }
.crit .mark.y { background: var(--good-soft); color: var(--good); } .crit .mark.n { background: var(--bad-soft); color: var(--bad); } .crit .mark.u { background: #eef0f5; color: var(--muted); } .crit small { display: block; color: var(--muted); }
.ring { width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--c) calc(var(--v) * 1%), #ece8dd 0); } .ring > div { width: 72px; height: 72px; border-radius: 50%; background: #fff; display: grid; place-items: center; font-family: var(--serif); font-size: 26px; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; } .facts div span { display: block; font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); } .facts div b { font-weight: 600; }
.daycards { display: grid; grid-template-columns: repeat(5, minmax(0,1fr)); gap: 12px; } .daycard { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: #fff; cursor: pointer; } .daycard:hover { border-color: var(--brass); } .daycard.missing { opacity: .55; cursor: default; }

/* auth */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; } .auth .art { background: linear-gradient(160deg, #14213d 0%, #0d1730 60%, #2a2413 100%); color: #fff; padding: 64px; display: flex; flex-direction: column; justify-content: flex-end; }
.auth .art .eyebrow { color: #c9a965; letter-spacing: .2em; text-transform: uppercase; font-size: 11px; } .auth .art h1 { font-size: 44px; margin: 10px 0 14px; } .auth .art p { color: #b9c3da; max-width: 460px; font-size: 16px; }
.auth form { align-self: center; justify-self: center; width: min(380px, 90%); } .auth form h2 { font-size: 26px; margin-bottom: 6px; } .field { display: flex; flex-direction: column; gap: 5px; margin: 14px 0; font-size: 12.5px; color: var(--ink-2); } .field input { padding: 10px 12px; font-size: 14px; }
.error { color: var(--bad); margin: 8px 0; min-height: 20px; } .prose p { max-width: 760px; color: var(--ink-2); } .prose li { margin: 4px 0; color: var(--ink-2); }
@media (max-width: 1100px) { .kpis { grid-template-columns: repeat(2, 1fr); } .two, .three { grid-template-columns: 1fr; } .daycards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 820px) { .shell { grid-template-columns: 1fr; } .side { position: static; height: auto; } .main { padding: 22px 16px 60px; } .auth { grid-template-columns: 1fr; } .auth .art { display: none; } }
@media print { .side, .filters, .actions { display: none !important; } .shell { display: block; } .main { padding: 0; max-width: none; } .card { box-shadow: none; break-inside: avoid; } body { background: #fff; } }
.three { align-items: start; } .three > .card:first-child { position: sticky; top: 16px; } .transcript { max-height: calc(100vh - 190px); }
