/* Athena demo. Roman's Pizza design system tokens only, no new hex values. */
@import url('/rp-style.css');

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--color-surface-dim, #f8f9fa);
  color: var(--color-text, #111827);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-text-size-adjust: 100%;
}

/* Mobile first. Everything below assumes a 360px phone held in one hand. */
.shell { max-width: 480px; margin: 0 auto; min-height: 100dvh; display: flex; flex-direction: column;
         background: var(--color-surface, #fff); }
.wide  { max-width: 1200px; }

.topbar { background: var(--gradient-brand-blue, linear-gradient(135deg,#014085,#0260c9));
          color: #fff; padding: 14px 16px; display: flex; align-items: center; gap: 12px;
          position: sticky; top: 0; z-index: 10; }
.topbar h1 { font-size: 1rem; margin: 0; font-weight: 700; letter-spacing: .01em; }
.topbar .sub { font-size: .75rem; opacity: .85; }
.brandmark { width: 30px; height: 30px; border-radius: 8px; background: var(--color-brand-red, #ed1c24);
             display: grid; place-items: center; font-weight: 800; font-size: .85rem; flex: 0 0 auto; }

main { padding: 16px; flex: 1; }
.card { background: var(--color-surface, #fff); border: 1px solid var(--color-border, #e5e7eb);
        border-radius: 14px; padding: 16px; margin-bottom: 14px; }
h2 { font-size: 1.05rem; margin: 0 0 8px; }
p  { line-height: 1.55; margin: 0 0 12px; }
.muted { color: var(--color-text-muted, #6b7280); font-size: .85rem; }

/* Tap targets sized for a person wearing gloves in a hurry. */
.btn { display: flex; align-items: center; justify-content: center; gap: 10px;
       width: 100%; min-height: 56px; border-radius: 12px; border: 0; cursor: pointer;
       font-size: 1rem; font-weight: 650; padding: 12px 16px; }
.btn-primary { background: var(--color-brand-blue, #014085); color: #fff; }
.btn-danger  { background: var(--color-brand-red, #ed1c24); color: #fff; }
.btn-ghost   { background: var(--color-surface-container, #f3f4f6); color: var(--color-text, #111827); }
.btn:disabled { opacity: .5; }
.btn + .btn { margin-top: 10px; }

/* An answer option must be answerable without reading it: big, tappable, with audio. */
.opt { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
       min-height: 64px; padding: 12px 14px; margin-bottom: 10px; cursor: pointer;
       background: var(--color-surface, #fff); border: 2px solid var(--color-border, #e5e7eb);
       border-radius: 14px; font-size: 1rem; line-height: 1.4; color: inherit; }
.opt:active { transform: scale(.99); }
.opt.sel { border-color: var(--color-brand-blue, #014085);
           background: var(--color-surface-variant, #eef2f7); }
.opt .num { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 50%; display: grid;
            place-items: center; font-weight: 800; background: var(--color-surface-container, #f3f4f6); }
.opt.sel .num { background: var(--color-brand-blue, #014085); color: #fff; }
.opt .play { flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; border: 0;
             background: var(--color-brand-blue, #014085); color: #fff; font-size: 1rem; cursor: pointer; }

.speak { display: inline-flex; align-items: center; gap: 8px; border: 0; cursor: pointer;
         background: var(--color-brand-blue, #014085); color: #fff; border-radius: 999px;
         padding: 10px 16px; font-size: .95rem; font-weight: 600; min-height: 44px; }
.speak.playing { background: var(--color-brand-red, #ed1c24); }

.prog { height: 8px; border-radius: 999px; background: var(--color-surface-container, #f3f4f6); overflow: hidden; }
.prog > i { display: block; height: 100%; background: var(--color-brand-blue, #014085); transition: width .25s; }

.pill { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .72rem;
        font-weight: 700; letter-spacing: .02em; }
.pill-ok   { background: var(--color-success-light, #dcfce7); color: var(--color-success-on, #15803d); }
.pill-warn { background: var(--color-warning-light, #fef3c7); color: var(--color-warning-on, #b45309); }
.pill-bad  { background: #fee2e2; color: #b91c1c; }
.pill-info { background: var(--color-surface-variant, #eef2f7); color: var(--color-brand-blue, #014085); }

.timer { font-variant-numeric: tabular-nums; font-weight: 700; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

.stat  { text-align: left; }
.stat b { display: block; font-size: 1.9rem; line-height: 1.05; font-variant-numeric: tabular-nums; }
.stat span { font-size: .78rem; color: var(--color-text-muted, #6b7280); }
.grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }

table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th, td { text-align: left; padding: 9px 8px; border-bottom: 1px solid var(--color-border, #e5e7eb); }
th { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--color-text-muted,#6b7280); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

.cert { border: 2px solid var(--color-brand-blue, #014085); border-radius: 16px; padding: 22px; text-align: center;
        background: var(--color-surface, #fff); }
.cert .code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 1.25rem;
              letter-spacing: .12em; font-weight: 700; }

.offline-banner { background: var(--color-warning-light, #fef3c7); color: var(--color-warning-on, #b45309);
                  padding: 10px 16px; font-size: .85rem; font-weight: 600; text-align: center; }

@media (min-width: 900px) { .two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; } }
