/* ─────────────────────────────────────────────────────────────
   Filament forum wall, portrait 1080 × 1920.
   Tokens from the Filament design system v0.3.
   Loop = entrance-piece look (glow-peach and white on filament-red).
   Explore = production look (filament-red and ink on white, Roboto Mono).
   Everything is square; the only curve is the thread's bend.
   ───────────────────────────────────────────────────────────── */

:root {
  /* Brand colours */
  --filament-red: #8a1b1d;
  --glow-peach: #f3b87e;
  --white: #ffffff;
  --sign-ink: #231f20;

  /* Semantic (Day theme) */
  --surface: var(--white);
  --surface-raised: #f6eeee;
  --ink: #1e1a1a;
  --ink-muted: #5e5454;
  --accent: var(--filament-red);

  --font-mono: 'Roboto Mono', ui-monospace, Menlo, Consolas, monospace;

  /* Spacing */
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 40px;
  --space-5: 72px;
  --space-6: 80px;

  /* The thread: outer 5 : middle 3 : inner 1 (wall and screen sizes) */
  --thread-outer: 15px;
  --thread-mid: 9px;
  --thread-inner: 3px;
  --rule-bar: 5px;

  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --scale: 1;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  overflow: hidden;
  background: var(--filament-red);
  font-family: var(--font-mono);
  -webkit-font-smoothing: antialiased;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; text-align: left; }
ul { list-style: none; }

/* ── Stage: designed at 1080 × 1920, scaled to fit ─────────── */

.viewport { position: fixed; inset: 0; overflow: hidden; }

.stage {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 1080px;
  height: 1920px;
  transform: translate(-50%, -50%) scale(var(--scale));
  overflow: hidden;
  background: var(--surface);
}

/* ── Shared type ───────────────────────────────────────────── */

.label, .eyebrow {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1.2;
}

.clock {
  font-size: 44px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.clock--small { font-size: 40px; }

.headline {
  font-size: 104px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.02;
}
.headline--md { font-size: 96px; }

.item__note { font-size: 0.62em; opacity: 0.8; font-weight: 400; }

.leader {
  flex: 1;
  min-width: 40px;
  border-bottom: 3px dotted currentColor;
  opacity: 0.35;
  transform: translateY(-0.22em);
}

.logo { display: block; width: 100%; height: auto; }

.icon { display: block; height: 1em; width: auto; }

.wx-icon {
  display: block;
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 5;
  stroke-linecap: square;
  stroke-linejoin: miter;
}
.wx-icon .wx-cloud { fill: var(--ground); }

.status-dot {
  display: inline-block;
  width: 0.4em;
  height: 0.4em;
  margin-right: 0.5em;
  background: currentColor;
  vertical-align: 0.12em;
}
.status-dot.is-open { animation: pulse 2.4s var(--ease) infinite; }

@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 currentColor; }
  70%  { box-shadow: 0 0 0 0.5em transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

/* Staggered entrances: any .rise inside an .is-in container */
.rise {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 900ms var(--ease), transform 900ms var(--ease);
  transition-delay: calc(var(--i, 0) * 140ms + 150ms);
}
.is-in .rise { opacity: 1; transform: none; }

/* ═════════════════════════════════════════════════════════════
   LOOP
   ═════════════════════════════════════════════════════════════ */

.loop {
  --ground: var(--filament-red);
  position: absolute;
  inset: 0;
  z-index: 2;
  background: var(--filament-red);
  color: var(--glow-peach);
  clip-path: inset(0 0 0 0);
  transition: clip-path 1100ms cubic-bezier(0.7, 0, 0.2, 1);
  cursor: pointer;
}

.stage[data-mode='explore'] .loop {
  clip-path: inset(0 0 100% 0);
  pointer-events: none;
}

.topbar {
  position: absolute;
  top: 72px;
  left: var(--space-6);
  right: var(--space-6);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  color: var(--white);
}
.topbar__time { display: flex; flex-direction: column; align-items: flex-end; gap: 16px; }
.topbar .clock { order: -1; color: var(--glow-peach); font-size: 56px; }

.scenes {
  position: absolute;
  left: var(--space-6);
  right: var(--space-6);
  top: 240px;
  bottom: 400px;
}

.scene {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: opacity 700ms var(--ease);
}
.scene.is-out { opacity: 0; }
.scene.is-out .rise { transform: translateY(-20px); transition-delay: 0ms; }

.scene .eyebrow { color: var(--white); margin-bottom: var(--space-4); }
.scene__note { margin-top: var(--space-5); font-size: 30px; line-height: 1.4; color: var(--white); }

/* Welcome: the logo is lit from left to right, like current along a filament */
.welcome__logo { width: 100%; }
.welcome__logo.rise {
  opacity: 1;
  transform: none;
  clip-path: inset(0 100% 0 0);
  transition: clip-path 1800ms cubic-bezier(0.6, 0, 0.2, 1) 200ms;
}
.is-in .welcome__logo.rise { clip-path: inset(0 0 0 0); }

/* Today */
.today__status { margin-top: 56px; font-size: 44px; line-height: 1.35; color: var(--white); }
.today__status .status-dot { color: var(--glow-peach); }

/* Specials */
.big-list__row {
  display: flex;
  align-items: baseline;
  gap: 28px;
  font-size: 68px;
  line-height: 1.15;
  padding: 26px 0;
}
.big-list__name { color: var(--glow-peach); }
.big-list__row .leader { color: var(--glow-peach); }
.big-list__price { color: var(--white); font-weight: 600; font-variant-numeric: tabular-nums; }

/* Weather */
.wx-now { display: flex; flex-wrap: wrap; align-items: center; gap: 48px; }
.wx-now__icon { font-size: 220px; }
.wx-now__temp { font-size: 260px; font-weight: 300; letter-spacing: -0.05em; line-height: 0.9; }
.wx-now__text { flex-basis: 100%; margin-top: 16px; }
.wx-now__desc { font-size: 64px; color: var(--white); }
.wx-now__meta { font-size: 32px; color: var(--white); margin-top: 16px; }
.wx-tip { font-size: 32px; line-height: 1.4; margin-top: 40px; }
.wx-tip strong { font-weight: 600; color: var(--white); }

.wx-hours {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  margin-top: 72px;
  border-top: 2px solid rgba(243, 184, 126, 0.5);
}
.wx-hours li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding-top: 28px;
  font-size: 28px;
}
.wx-hours__time { color: var(--white); font-size: 24px; }
.wx-hours .wx-icon { font-size: 60px; }
.wx-hours__temp { font-weight: 600; }

/* Menu */
.scene--menu .headline { margin-bottom: 48px; }
.mid-list__row {
  display: flex;
  align-items: baseline;
  gap: 20px;
  font-size: 40px;
  padding: 16px 0;
  color: var(--white);
}
.mid-list__row .leader { color: var(--glow-peach); }
.mid-list__price { color: var(--glow-peach); font-weight: 600; }

/* The thread: enters left, leaves right, one per surface */
.thread {
  position: absolute;
  left: 0;
  width: 1080px;
  height: 120px;
  overflow: visible;
  pointer-events: none;
}
.thread--loop { bottom: 230px; }
.thread path { fill: none; stroke-linecap: butt; }
.thread__outer { stroke: var(--glow-peach); stroke-width: var(--thread-outer); }
.thread__mid { stroke: var(--filament-red); stroke-width: var(--thread-mid); }
.thread__inner { stroke: var(--glow-peach); stroke-width: var(--thread-inner); }
.thread__outer, .thread__mid, .thread__inner {
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
  animation: draw 2200ms cubic-bezier(0.6, 0, 0.2, 1) 300ms forwards;
}
@keyframes draw { to { stroke-dashoffset: 0; } }

/* A spark of light that runs along the thread with each new scene */
.thread__spark {
  stroke: #fff4e8;
  stroke-width: var(--thread-inner);
  stroke-dasharray: 160 3000;
  stroke-dashoffset: 180;
  opacity: 0;
  filter: drop-shadow(0 0 6px var(--glow-peach)) drop-shadow(0 0 14px var(--glow-peach));
}
.thread__spark.is-running { animation: spark 2800ms cubic-bezier(0.5, 0, 0.3, 1) forwards; }
@keyframes spark {
  0%   { stroke-dashoffset: 180; opacity: 0; }
  8%   { opacity: 1; }
  85%  { opacity: 1; }
  100% { stroke-dashoffset: -1150; opacity: 0; }
}

.loop__hint {
  position: absolute;
  left: var(--space-6);
  right: var(--space-6);
  bottom: 96px;
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 32px;
  color: var(--white);
}
.hint__dot {
  width: 20px;
  height: 20px;
  flex: none;
  background: var(--glow-peach);
  color: var(--glow-peach);
  animation: pulse 2s var(--ease) infinite;
}
.scene-dots { margin-left: auto; display: flex; gap: 10px; }
.scene-dots i {
  width: 32px;
  height: 5px;
  background: var(--glow-peach);
  opacity: 0.35;
  transition: opacity 600ms var(--ease);
}
.scene-dots i.is-on { opacity: 1; }

/* ═════════════════════════════════════════════════════════════
   EXPLORE
   ═════════════════════════════════════════════════════════════ */

.explore {
  --ground: var(--surface);
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--surface);
  color: var(--ink);
}

.ex-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 72px var(--space-6) 48px;
}
.ex-head__logo { width: 420px; color: var(--filament-red); }
.ex-head__time { display: flex; flex-direction: column; align-items: flex-end; gap: 14px; color: var(--filament-red); }
.ex-head__time .label { color: var(--ink-muted); }

/* The thread, edge to edge under the header */
.ex-thread {
  flex: none;
  height: var(--thread-outer);
  background: linear-gradient(180deg,
    var(--filament-red) 0 3px, var(--surface) 3px 6px,
    var(--filament-red) 6px 9px, var(--surface) 9px 12px,
    var(--filament-red) 12px 15px);
}

.panel__body {
  flex: 1;
  min-height: 0;
  padding: 64px var(--space-6) 40px;
  opacity: 0;
  transition: opacity 400ms var(--ease);
}
.panel__body.is-in { opacity: 1; }

/* Bottom navigation: big tabs, three to a row */
.ex-nav { flex: none; padding: 0 var(--space-6) 56px; }
.ex-nav__tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: var(--surface-raised);
  border-top: var(--rule-bar) solid var(--filament-red);
}
.tab {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  height: 112px;
  padding: 0 24px;
  font-size: 28px;
  font-weight: 500;
  line-height: 1.2;
  background: var(--surface);
  transition: background 250ms var(--ease), color 250ms var(--ease);
}
.tab__arrow { flex: none; font-size: 22px; color: var(--filament-red); }
.tab:active { background: var(--surface-raised); }
.tab.is-on { background: var(--filament-red); color: var(--white); }
.tab.is-on .tab__arrow { color: var(--glow-peach); }

.ex-nav__foot { display: flex; align-items: center; gap: 32px; margin-top: 24px; }
.back {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  font-size: 26px;
  color: var(--filament-red);
  flex: none;
}
.back .icon { font-size: 24px; }
.idle-timer { flex: 1; height: var(--rule-bar); background: var(--surface-raised); }
.idle-timer span {
  display: block;
  height: 100%;
  background: var(--filament-red);
  transform-origin: left;
  transition: transform 200ms linear;
}

/* Page basics */
.page-title {
  font-size: 96px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--filament-red);
}
.page-lead { font-size: 32px; color: var(--ink-muted); margin-top: 20px; }
.page-note { font-size: 26px; color: var(--ink-muted); margin-top: var(--space-4); line-height: 1.5; }
.explore .label { color: var(--filament-red); }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  margin-top: 32px;
  padding: 16px 0;
  font-size: 30px;
  font-weight: 500;
  color: var(--filament-red);
}
.text-link .icon { font-size: 24px; }

/* Specials page: one block per special */
.special-grid { display: grid; gap: 24px; margin-top: 56px; }
.special {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  align-items: baseline;
  column-gap: 24px;
  padding: 80px 48px;
  background: var(--surface-raised);
}
.special__num { font-size: 22px; font-weight: 600; letter-spacing: 0.14em; color: var(--filament-red); }
.special__name { font-size: 60px; font-weight: 500; line-height: 1.15; }
.special__note { grid-column: 2; margin-top: 12px; font-size: 26px; color: var(--ink-muted); }
.special__price { grid-column: 3; grid-row: 1; font-size: 60px; font-weight: 600; color: var(--filament-red); }

/* Menu page */
.chips { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 48px; }
.chip {
  padding: 16px 24px;
  font-size: 26px;
  font-weight: 500;
  color: var(--filament-red);
  border: 2px solid var(--filament-red);
  transition: background 200ms var(--ease), color 200ms var(--ease);
}
.chip.is-on { background: var(--filament-red); color: var(--white); }

.menu-list { margin-top: 56px; }
.menu-list__row {
  display: flex;
  align-items: baseline;
  gap: 20px;
  font-size: 40px;
  padding: 24px 0;
}
.menu-list__row .leader { color: var(--filament-red); }
.menu-list__price { font-weight: 600; color: var(--filament-red); font-variant-numeric: tabular-nums; }
.menu-foot { margin-top: 48px; font-size: 24px; line-height: 1.5; color: var(--ink-muted); }

/* Weather page */
.wx-page { margin-top: 48px; }
.wx-big { display: flex; align-items: center; gap: 40px; color: var(--filament-red); }
.wx-big .wx-icon { font-size: 180px; }
.wx-big__temp { font-size: 200px; font-weight: 300; letter-spacing: -0.05em; line-height: 0.9; }
.wx-page__desc { margin-top: 32px; font-size: 44px; }
.wx-page__meta { margin-top: 16px; font-size: 28px; line-height: 1.5; color: var(--ink-muted); }
.wx-suggest { margin-top: 40px; padding: 32px 40px; background: var(--surface-raised); }
.wx-suggest__item { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; margin-top: 12px; font-size: 36px; }

.wx-page__side { margin-top: 56px; }
.wx-page__side .label { margin-bottom: 16px; }
.wx-strip {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  margin-bottom: 48px;
  border-top: 2px solid var(--filament-red);
}
.wx-strip li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding-top: 18px;
  font-size: 22px;
}
.wx-strip .wx-icon { font-size: 56px; color: var(--filament-red); }
.wx-strip strong { font-size: 28px; font-weight: 600; }
.wx-strip__pop { font-size: 20px; color: var(--ink-muted); }

.wx-days li {
  display: grid;
  grid-template-columns: 1fr 64px 100px 180px;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  font-size: 28px;
  border-top: 2px solid var(--surface-raised);
}
.wx-days .wx-icon { font-size: 48px; color: var(--filament-red); }
.wx-days__pop { color: var(--ink-muted); font-size: 24px; }
.wx-days__temps { text-align: right; color: var(--ink-muted); }
.wx-days__temps strong { color: var(--ink); font-weight: 600; margin-right: 12px; }

/* Case studies */
.cases { display: grid; gap: 32px; margin-top: 56px; }
.case { background: var(--surface-raised); }
.case__image { aspect-ratio: 16 / 9; overflow: hidden; }
.case__image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.case__body { padding: 56px 48px; }
.case__title { margin-top: 16px; font-size: 72px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.05; }
.case__summary { margin-top: 24px; font-size: 30px; line-height: 1.5; color: var(--ink-muted); }

.case-scene__image { aspect-ratio: 16 / 9; margin-bottom: 56px; overflow: hidden; }
.case-scene__image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.case-scene__client { margin-top: 32px; font-size: 48px; color: var(--white); }

/* Find your way: rows of icon + destination + arrow, split by bar rules */
.wayfinding { margin-top: 56px; color: var(--sign-ink); }
.wayfinding__row {
  display: grid;
  grid-template-columns: 100px 1fr 100px;
  align-items: center;
  gap: 40px;
  padding: 36px 0;
  border-top: var(--rule-bar) solid var(--filament-red);
}
.wayfinding__row:last-child { border-bottom: var(--rule-bar) solid var(--filament-red); }
.wayfinding__icon { font-size: 80px; justify-self: center; }
.wayfinding__label { font-size: 64px; line-height: 1.1; }
.wayfinding__arrow { font-size: 76px; justify-self: end; color: var(--filament-red); }

/* Hours & Wi-Fi */
.info-grid { margin-top: 48px; }
.info-status { font-size: 36px; margin-bottom: 32px; }
.info-status .status-dot { color: var(--filament-red); }
.hours { width: 100%; border-collapse: collapse; font-size: 32px; }
.hours th, .hours td { padding: 16px 0; border-top: 2px solid var(--surface-raised); text-align: left; font-weight: 400; }
.hours tr.is-today th, .hours tr.is-today td { color: var(--filament-red); font-weight: 600; }
.hours__flag { text-align: right !important; font-size: 18px; letter-spacing: 0.14em; text-transform: uppercase; }

.wifi {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 40px;
  margin-top: 48px;
  padding: 48px;
  background: var(--filament-red);
  color: var(--white);
}
.wifi__icon { grid-column: 1 / -1; font-size: 64px; color: var(--glow-peach); margin-bottom: 32px; }
.wifi__cell .label { color: var(--glow-peach); }
.wifi__value { font-size: 40px; font-weight: 500; margin-top: 10px; overflow-wrap: anywhere; }
.wifi__value--sm { font-size: 30px; font-weight: 400; line-height: 1.3; }

@media (prefers-reduced-motion: reduce) {
  .thread__spark.is-running, .status-dot.is-open, .hint__dot { animation: none; }
  .rise, .welcome__logo.rise { transition-duration: 1ms; }
}
