:root {
  color-scheme: light;
  --bg: #f4f2ed;
  --surface: #fffdf8;
  --ink: #1e2320;
  --muted: #6c716b;
  --line: #dcd8cf;
  --coral: #f05f45;
  --coral-soft: #fbdcd3;
  --sage: #1e5a48;
  --shadow: 0 18px 55px rgba(40, 36, 29, .08);
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
button, select { font: inherit; }
.topbar { min-height: 92px; padding: 22px clamp(24px, 5vw, 72px); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 28px; background: rgba(244, 242, 237, .9); }
.topbar h1 { margin: 2px 0 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(24px, 3vw, 34px); font-weight: 500; letter-spacing: -.03em; }
.eyebrow, .kicker { margin: 0; color: var(--coral); font-size: 11px; font-weight: 750; letter-spacing: .14em; text-transform: uppercase; }
.topbar-actions { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
select { appearance: none; border: 1px solid var(--line); border-radius: 999px; padding: 10px 34px 10px 14px; color: var(--ink); background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5' fill='none' stroke='%231e2320' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 12px center; }
.account { border-left: 1px solid var(--line); margin-left: 6px; padding-left: 18px; }
main { width: min(1240px, calc(100% - 40px)); margin: 0 auto; padding: 66px 0 80px; }
.intro { display: flex; justify-content: space-between; align-items: end; gap: 36px; margin-bottom: 36px; }
.intro h2 { max-width: 780px; margin: 10px 0 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(34px, 5vw, 62px); line-height: 1.02; font-weight: 500; letter-spacing: -.045em; }
.updated { flex: 0 0 auto; margin: 0 0 8px; color: var(--muted); font-size: 12px; }
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 14px; }
.card, .panel { border: 1px solid var(--line); border-radius: 18px; background: var(--surface); box-shadow: var(--shadow); }
.card { min-height: 160px; padding: 22px; display: flex; flex-direction: column; }
.card.accent { background: var(--coral); border-color: var(--coral); color: white; }
.card span, .agent-grid span { color: var(--muted); font-size: 13px; }
.card.accent span, .card.accent small { color: rgba(255,255,255,.8); }
.card strong { margin-top: auto; font-family: Georgia, "Times New Roman", serif; font-size: 46px; line-height: .95; font-weight: 500; letter-spacing: -.04em; }
.card small { margin-top: 10px; color: var(--muted); font-size: 11px; }
.panel { padding: 26px; }
.wide { margin-bottom: 14px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.panel h3, .privacy-note h3 { margin: 5px 0 0; font-family: Georgia, "Times New Roman", serif; font-size: 25px; font-weight: 500; letter-spacing: -.02em; }
.legend { display: flex; gap: 18px; color: var(--muted); font-size: 11px; }
.legend span { display: flex; align-items: center; gap: 7px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ink); }
.dot.coral { background: var(--coral); }
.chart { min-height: 230px; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(12px, 1fr); align-items: end; gap: clamp(3px, .7vw, 9px); padding-top: 18px; border-bottom: 1px solid var(--line); background: repeating-linear-gradient(to bottom, transparent 0, transparent 54px, rgba(220,216,207,.55) 55px); }
.chart-day { height: 210px; display: flex; align-items: end; justify-content: center; gap: 2px; position: relative; }
.bar { width: min(10px, 42%); min-height: 2px; border-radius: 4px 4px 0 0; background: var(--ink); transition: height .35s ease; }
.bar.views { background: var(--coral); }
.chart-day time { position: absolute; bottom: -23px; left: 50%; transform: translateX(-50%); color: var(--muted); font-size: 9px; white-space: nowrap; }
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-bottom: 14px; }
.ranking { display: grid; gap: 15px; }
.rank { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.rank-main { min-width: 0; }
.rank-label { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.rank-track { height: 4px; margin-top: 8px; border-radius: 999px; background: #ebe7df; overflow: hidden; }
.rank-fill { display: block; height: 100%; border-radius: inherit; background: var(--coral); }
.rank-value { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.empty { color: var(--muted); font-size: 13px; }
.agent-panel { background: var(--ink); color: #f8f4ec; border-color: var(--ink); }
.agent-panel .eyebrow { color: #ff8c73; }
.status { display: flex; align-items: center; gap: 8px; color: #b9bdb7; font-size: 11px; }
.status i { width: 8px; height: 8px; border-radius: 50%; background: #74d2a8; box-shadow: 0 0 0 4px rgba(116,210,168,.12); }
.agent-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid #424643; border-bottom: 1px solid #424643; }
.agent-grid div { padding: 24px 20px; border-right: 1px solid #424643; }
.agent-grid div:last-child { border: 0; }
.agent-grid span { display: block; color: #a8ada7; }
.agent-grid strong { display: block; margin-top: 10px; font-family: Georgia, "Times New Roman", serif; font-size: 31px; font-weight: 500; }
.status-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.status-pill { border: 1px solid #4e534f; border-radius: 999px; padding: 8px 12px; color: #d9ddd7; font-size: 11px; }
.status-pill b { margin-left: 6px; color: white; }
.privacy-note { margin-top: 14px; border: 1px dashed #bdb8ae; border-radius: 18px; padding: 24px 28px; display: flex; gap: 18px; align-items: center; }
.privacy-note h3 { font-size: 20px; }
.privacy-note p { max-width: 850px; margin: 6px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.shield { flex: 0 0 auto; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; color: var(--sage); background: #dcebe5; font-weight: 800; }
.error { position: fixed; right: 22px; bottom: 22px; padding: 14px 18px; border-radius: 12px; color: white; background: #a53a2d; box-shadow: var(--shadow); font-size: 13px; }

@media (max-width: 900px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .intro { display: block; }
  .updated { margin-top: 20px; }
  .agent-grid { grid-template-columns: repeat(2, 1fr); }
  .agent-grid div:nth-child(2) { border-right: 0; }
  .agent-grid div:nth-child(-n+2) { border-bottom: 1px solid #424643; }
}
@media (max-width: 620px) {
  .topbar { align-items: flex-start; }
  .topbar-actions { align-items: flex-end; flex-direction: column; }
  .topbar-actions label, .account { display: none; }
  main { width: min(100% - 24px, 1240px); padding-top: 42px; }
  .cards, .grid { grid-template-columns: 1fr; }
  .intro h2 { font-size: 39px; }
  .chart { overflow: hidden; gap: 3px; }
  .chart-day time { display: none; }
  .panel { padding: 20px; }
  .agent-grid { grid-template-columns: 1fr 1fr; }
}
