/* Name That Plate! in GreetRV's look: cream page, forest header, white rounded cards, rust primary
   buttons, Outfit. Colors are GreetRV's design tokens (GreetRV/design/tailwind-theme.js). */
:root {
  --cream: #fbf3e6;
  --cream-hover: #f3e6cf;
  --ink: #1c1b19;
  --ink-muted: #3a3631;
  --ink-subtle: #5a4a3a;
  --line: #eedcc4;
  --forest: #2e5a37;
  --forest-dark: #1f3a27;
  --forest-tint: #ddebe2;
  --forest-ondark: #d6e6db;
  --rust: #c8461b;
  --rust-ondark: #f2a77e;
  --badge-bg: #fce9dd;
  --badge-text: #8f3a10;
  --gold: #f2c230;
  --card: 20px;
  --panel: 28px;
  --shadow: 0 12px 30px rgba(28, 27, 25, 0.08);
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--cream);
  color: var(--ink);
  font-family: Outfit, 'Avenir Next', 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.4;
  -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, summary:focus-visible { outline: 3px solid var(--rust); outline-offset: 2px; }

.shell { height: 100%; display: flex; flex-direction: column; }

/* Header bar */
.bar {
  flex: none;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--forest-dark); color: var(--cream);
  padding: max(8px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) 8px max(14px, env(safe-area-inset-left));
}
.title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.title img { flex: none; }
.title small { display: block; font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--forest-ondark); }
.wordmark { display: block; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; white-space: nowrap; }
.bar-right { display: flex; align-items: center; gap: 8px; }
.hud { font-weight: 800; font-size: 16px; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
.hud-label { font-weight: 600; font-size: 13px; color: var(--forest-ondark); }
.hud-sep { display: inline-block; width: 1px; height: 14px; margin: 0 6px; background: rgba(214, 230, 219, .4); vertical-align: middle; }
.fs { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 0; border-radius: 999px; background: rgba(251, 243, 230, .15); color: var(--cream); }
.fs[hidden] { display: none; }
@media (max-width: 380px) { .title small { display: none; } .wordmark { font-size: 17px; } }

/* Scrolling content */
#app { flex: 1; min-height: 0; overflow-y: auto; padding: 14px max(14px, env(safe-area-inset-right)) max(18px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left)); }
.card { background: #fff; border-radius: var(--card); box-shadow: var(--shadow); padding: 16px; }
.plate-wrap { max-width: 460px; margin: 0 auto; }
.plate { display: block; width: 100%; height: auto; filter: drop-shadow(0 6px 10px rgba(28, 27, 25, .25)); }
@media (prefers-reduced-motion: no-preference) {
  .plate { animation: pop .25s ease-out; }
  @keyframes pop { from { transform: scale(.96); opacity: .6; } to { transform: none; opacity: 1; } }
}
.muted { color: var(--ink-subtle); margin: 0; }
.note { font-size: 13px; color: var(--ink-subtle); text-align: center; margin: 4px 0 0; }
.tag { display: inline-block; background: var(--badge-bg); color: var(--badge-text); font-weight: 800; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; border-radius: 999px; padding: 3px 10px; }
.stars { color: var(--gold); letter-spacing: 2px; font-size: 18px; white-space: nowrap; }
.stars .off { color: var(--line); }

/* Menu */
.menu { max-width: 980px; margin: 0 auto; display: grid; gap: 14px; }
.hero { display: grid; gap: 12px; }
.lede { margin: 0; color: var(--ink-muted); }
.modes { display: grid; gap: 10px; }
.mode {
  display: grid; gap: 4px; text-align: left; width: 100%; min-height: 64px;
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--card); padding: 12px 16px;
}
.mode-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mode strong { font-size: 18px; font-weight: 800; }
.mode .sub { font-size: 15px; color: var(--ink-subtle); }
.mode.daily { background: var(--forest-tint); border-color: var(--forest-tint); }
.mode.daily[aria-disabled="true"] { cursor: default; opacity: .85; }
.streak { font-weight: 700; font-size: 14px; color: var(--forest-dark); white-space: nowrap; }
.how summary { font-weight: 800; cursor: pointer; }
.how p { margin: 8px 0 0; color: var(--ink-muted); }
@media (min-width: 760px) {
  .menu { grid-template-columns: 1.15fr 1fr; align-items: start; }
  .how, .menu .note { grid-column: 1 / -1; }
}

/* A question */
.play { max-width: 1040px; min-height: 100%; margin: 0 auto; display: grid; gap: 12px; align-content: center; }
.plate-card { padding: 14px; }
.answer-side { display: grid; gap: 10px; align-content: start; }
.prompt { font-weight: 800; font-size: 19px; text-align: center; padding: 4px 0; }
.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.choice {
  min-height: 56px; border-radius: 16px; border: 1.5px solid var(--line); background: #fff;
  font-weight: 700; font-size: 17px; padding: 8px 10px; line-height: 1.15;
}
.choice:disabled { cursor: default; }
.choice.right { background: var(--forest-tint); border-color: var(--forest); color: var(--forest-dark); }
.choice.wrong { background: var(--badge-bg); border-color: var(--rust); color: var(--badge-text); }
.feedback { border-radius: 16px; padding: 10px 14px; border: 1.5px solid; display: grid; gap: 2px; }
.feedback.ok { background: var(--forest-tint); border-color: var(--forest); }
.feedback.no { background: var(--badge-bg); border-color: var(--rust); }
.feedback strong { font-size: 18px; }
.feedback .slogan { font-size: 14px; font-weight: 600; color: var(--ink-subtle); }
.feedback .fact { font-size: 15px; color: var(--ink-muted); }
.hot { display: inline-block; margin-left: 6px; background: var(--rust); color: #fff; font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; border-radius: 999px; padding: 2px 8px; vertical-align: 2px; }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; }
.btn { min-height: 52px; border-radius: 999px; font-weight: 800; font-size: 17px; padding: 10px 20px; border: 1.5px solid var(--ink); background: transparent; }
.btn.primary { background: var(--rust); border-color: var(--rust); color: #fff; }
/* Wide boxes (desktop, phones sideways): plate on the left, answers on the right. */
@media (min-width: 700px) and (min-aspect-ratio: 5/4) {
  .play { grid-template-columns: 1.2fr 1fr; align-items: center; }
  .plate-wrap { max-width: none; }
}

/* Results */
.result { max-width: 480px; margin: 12px auto; display: grid; gap: 8px; justify-items: center; text-align: center; padding: 24px 18px; }
.result h2 { margin: 4px 0 0; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.result p { margin: 0; }
.result .row { width: 100%; margin-top: 8px; }
.result-stars .stars { font-size: 34px; letter-spacing: 6px; }
.big { font-size: 48px; font-weight: 800; line-height: 1; color: var(--forest); letter-spacing: -0.03em; }
.clock { display: inline-block; min-width: 2.6ch; }
.clock.low { color: var(--rust-ondark); }

/* Hover only with a real mouse: on phones a tap leaves "hover" stuck on whatever button lands under the finger next. */
@media (hover: hover) and (pointer: fine) {
  .fs:hover { background: rgba(251, 243, 230, .25); }
  .mode:hover { border-color: var(--forest); background: #fffdf8; }
  .choice:hover:not(:disabled) { border-color: var(--forest); background: #fffdf8; }
  .btn.primary:hover { background: #b23d17; }
  .btn.ghost:hover { background: var(--cream-hover); }
}
