:root {
  color-scheme: light dark;
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB', system-ui, sans-serif;
  --background: #f2f4f8;
  --surface: #fff;
  --ink: #17202c;
  --secondary: #536071;
  --line: #dce2ea;
  --action: #1457a8;
  --action-text: #fff;
  --soft-action: #edf4ff;
  --positive: #245f4a;
  --alert: #92510c;
  --radius: 1.2rem;
}
@media (prefers-color-scheme: dark) {
  :root {
    --background: #14181f;
    --surface: #202731;
    --ink: #f6f7fa;
    --secondary: #b8c4d4;
    --line: #3d4654;
    --action: #accfff;
    --action-text: #17273d;
    --soft-action: #293c54;
    --positive: #99d7b7;
    --alert: #f7cb91;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--background); color: var(--ink); }
main { max-width: 57rem; margin: 0 auto; padding: 1.5rem clamp(1rem, 4vw, 2.5rem) 2.5rem; }
a { color: var(--action); }
:focus-visible { outline: 2px solid var(--action); outline-offset: 3px; }
h1, h2, h3, p, dl, dd { margin: 0; }
h1 { font-size: clamp(1.7rem, 5.6vw, 2.65rem); line-height: 1.18; font-weight: 720; letter-spacing: -.025em; }
h2 { font-size: 1.08rem; font-weight: 680; }
h3 { font-size: 1rem; font-weight: 680; }
p, dd { overflow-wrap: anywhere; }
.brand { display: flex; align-items: center; gap: .65rem; font-weight: 725; }
.brand span { padding-left: .65rem; border-left: 1px solid var(--line); color: var(--secondary); font-size: .85rem; font-weight: 520; }
.account-shell { max-width: 27rem; margin: clamp(1.5rem, 11vh, 6.5rem) auto 0; }
.intro { display: grid; gap: .55rem; margin: 1.4rem 0 1.25rem; }
.intro p, .panel p, .note { color: var(--secondary); }
.panel { background: var(--surface); border-radius: var(--radius); padding: 1rem; }
.panel > p + .button, .panel h2 + p { margin-top: .6rem; }
.account-actions { display: grid; gap: .65rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; border: 0; border-radius: .78rem; padding: .55rem 1rem; font: inherit; font-weight: 650; text-align: center; text-decoration: none; cursor: pointer; }
.primary { background: var(--action); color: var(--action-text); }
.secondary, .compact { background: var(--soft-action); color: var(--action); }
.compact { font-size: .88rem; white-space: nowrap; padding: .4rem .65rem; }
.panel:not(.reports) .button { width: 100%; }
.button:disabled { opacity: .63; cursor: default; }
.button:active:not(:disabled) { transform: translateY(1px); }
.back, .text-link { display: inline-flex; align-items: center; min-height: 44px; font-size: .92rem; text-underline-offset: .18em; }
.text-link { margin-top: .4rem; }
.account-links { display: flex; flex-wrap: wrap; column-gap: 1.15rem; }
.note { font-size: .88rem; margin: .75rem 0 0; }
.dashboard-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; }
.reports { padding: 0 1rem; }
.reports h2, .empty { padding: .85rem 0; }
.report-list { padding: 0; margin: 0; list-style: none; }
.report-list li { border-top: 1px solid var(--line); }
.report-row { display: grid; grid-template-columns: minmax(6rem, 1.1fr) minmax(0, 2fr); gap: 1rem; padding: .8rem 0; }
.report-row p { font-size: .84rem; }
.report-row dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.report-row dt { color: var(--secondary); font-size: .82rem; }
.report-row dd { font-weight: 600; }
.key-action { display: grid; gap: .55rem; }
.key-action .status { min-height: 1.5rem; font-size: .9rem; }
.key-action [data-state='success'] { color: var(--positive); }
.key-action [data-state='error'] { color: var(--alert); }
.key-action [hidden] { display: none; }
@media (max-width: 460px) {
  .report-row { grid-template-columns: 1fr; gap: .55rem; }
  .panel { padding-inline: .85rem; }
}
@media (prefers-reduced-motion: reduce) {
  .button:active:not(:disabled) { transform: none; }
}
