/* Fonts: Latin + only the Japanese glyphs used on the site (subset with pyftsubset) */
@font-face { font-family: "Dela Gothic One"; src: url(/fonts/dela-gothic-one-400.woff2?v=2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Zen Kaku Gothic New"; src: url(/fonts/zen-kaku-gothic-new-400.woff2?v=2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Zen Kaku Gothic New"; src: url(/fonts/zen-kaku-gothic-new-700.woff2?v=2) format("woff2"); font-weight: 700; font-display: swap; }

/* Tokyo back-alley at night: wet asphalt, red neon, paper-lantern amber */
:root {
  --neon: #FF2E3F;       /* red neon tube */
  --lantern: #FFB547;    /* chochin glow */

  --glow-red: 0 0 4px #fff3, 0 0 10px var(--neon), 0 0 28px var(--neon), 0 0 60px #ff2e3f88;

  --display: "Dela Gothic One", "Hiragino Sans", "Yu Gothic", sans-serif;
  --body: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", sans-serif;
  --max: 1160px;
  --pad: 20px;
}

/* Theme tokens. Dark = night alley (default). The hero and the header over it always stay dark. */
:root, .hero, .header-over {
  --night: #0E0A12;
  --alley: #1A1320;
  --paper: #F5EFE6;
  --dim: #A79FAE;
  --lantern-text: #FFB547;
  --focus: #FFB547;
  --glow-amber: 0 0 8px #ffb54788, 0 0 24px #ffb54755;
  --kicker: #ff6b77;
  --kicker-glow: 0 0 10px #ff2e3f99;
  --btn-bg: #ff2e3f22;
  --btn-bg-hover: #D41A2C;
  --btn-glow: 0 0 12px #ff2e3f99, inset 0 0 12px #ff2e3f55;
  --logo-filter: brightness(0) invert(1) drop-shadow(0 0 6px #ff2e3faa);
  --surface: linear-gradient(160deg, #22182a, #1A1320);
  --card-border: #ff2e3f55;
  --card-glow: 0 0 0 1px #ff2e3f22, 0 0 30px #ff2e3f22, inset 0 0 40px #ff2e3f11;
  --card-glow-hover: 0 0 0 1px #ff2e3f55, 0 0 44px #ff2e3f44, inset 0 0 40px #ff2e3f1a;
  --unlit-bg: #3a2c22;
  --unlit-fg: #9a8466;
  --tag-open-fg: #fff;
  --tag-open-bg: #ff2e3f33;
  --sign-bg: radial-gradient(ellipse at 50% 0%, #2a142099, transparent 70%);
  --title-color: #fff4f4;
  --title-glow: var(--glow-red);
  --footer-bg: linear-gradient(#0E0A12, #170e19);
  color-scheme: dark;
}
/* Light = the same street by day: paper white, ink, red and amber as plain accents */
[data-theme="light"] {
  --night: #F7F4F0;
  --alley: #FFFFFF;
  --paper: #1C1620;
  --dim: #5E5566;
  --lantern-text: #8F4C00;
  --focus: #8F4C00;
  --glow-amber: none;
  --kicker: #C8102E;
  --kicker-glow: none;
  --btn-bg: #D41A2C;
  --btn-bg-hover: #A8101F;
  --btn-glow: none;
  --logo-filter: none;
  --surface: #FFFFFF;
  --card-border: #E6D6D9;
  --card-glow: 0 8px 28px #1c162012;
  --card-glow-hover: 0 10px 34px #c8102e22;
  --unlit-bg: #EDE6DC;
  --unlit-fg: #8A7A66;
  --tag-open-fg: #A8101F;
  --tag-open-bg: #FFE3E6;
  --sign-bg: radial-gradient(ellipse at 50% 0%, #fbe3e6, transparent 70%);
  --title-color: #C8102E;
  --title-glow: none;
  --footer-bg: #EFE9E2;
  color-scheme: light;
}

* { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; background: var(--night); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { font: 400 1rem/1.7 var(--body); color: var(--paper); background: var(--night); }
@media (min-width: 960px) { body { font-size: 1.0625rem; } :root { --pad: 32px; } }
img, video, iframe { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
ul { padding: 0; list-style: none; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.1; }
h2 { font-size: clamp(1.9rem, 5vw, 3rem); }
h3 { font-size: 1.35rem; }
[lang="ja"] { font-family: var(--body); letter-spacing: .08em; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }
.section { padding: 72px 0; }
.lead { max-width: 60ch; margin-top: 18px; color: var(--dim); }
.muted { color: var(--dim); }
.skip { position: absolute; left: 8px; top: -60px; z-index: 10; padding: 8px 16px; background: var(--paper); color: var(--night); }
.skip:focus { top: 8px; }

/* Japanese line as a neon kicker above section headings */
.kicker { margin: 0 0 12px; font-family: var(--body); font-weight: 700; font-size: 1.05rem; letter-spacing: .2em; color: var(--kicker); text-shadow: var(--kicker-glow); }

/* Buttons: neon outlines */
.btn { display: inline-flex; align-items: center; min-height: 48px; padding: 0 26px; border: 2px solid currentColor; border-radius: 999px; font-weight: 700; text-decoration: none; transition: background .2s, box-shadow .2s, color .2s; }
.btn-primary { color: #fff; border-color: var(--btn-bg-hover); background: var(--btn-bg); box-shadow: var(--btn-glow); }
.btn-primary:hover { background: var(--btn-bg-hover); }
.btn-ghost { color: var(--lantern-text); }
.btn-ghost:hover, .btn-ink:hover { background: var(--lantern); color: #0E0A12; box-shadow: var(--glow-amber); }
.btn-ink { color: var(--lantern-text); }
.btn-ink[aria-current] { background: var(--lantern); color: #0E0A12; box-shadow: var(--glow-amber); }

/* Header */
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: var(--max); margin: 0 auto; padding: 14px var(--pad); }
.logo img { width: 60px; height: 60px; filter: var(--logo-filter); }
.site-header nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0 22px; }
.site-header nav a { font-weight: 700; text-decoration: none; padding: 10px 0; }
.site-header nav a:hover, .site-header nav a[aria-current] { color: var(--lantern-text); text-shadow: var(--glow-amber); }
.header-over { position: absolute; z-index: 2; inset: 0 0 auto; color: var(--paper); }

/* Hero: the neon sign */
.hero { position: relative; display: grid; place-items: center; min-height: 92vh; min-height: 92svh; padding: 120px var(--pad) 72px; background: var(--night) url(/assets/hero-poster.jpg) center/cover; text-align: center; overflow: hidden; isolation: isolate; color: var(--paper); }
.hero video { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; filter: saturate(1.3) brightness(.9); }
/* Video stays visible at the edges; a dark pool behind the text keeps it readable on bright frames */
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(ellipse 55% 50% at 50% 50%, #0e0a12c7 0%, #0e0a12b0 55%, #0e0a1240 100%), linear-gradient(transparent 75%, var(--night)); }
.hero-content { max-width: 60rem; }
.hero h1 { display: grid; gap: 18px; }
.neon-sign { text-transform: uppercase; font-size: clamp(3rem, 14.5vw, 11rem); line-height: .9; letter-spacing: .02em; color: #fff4f4; text-shadow: var(--glow-red); }
.hero-sub { font-family: var(--body); font-weight: 700; font-size: clamp(1.1rem, 2.6vw, 1.6rem); letter-spacing: .02em; color: var(--paper); }
.hero p { margin-top: 10px; color: var(--paper); }
.hero-shops { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin-top: 22px; font-size: .95rem; }
.hero-shops a { text-decoration: none; color: var(--paper); }
.hero-shops a:hover { color: var(--lantern); }
.hero-shops li::before { content: ""; display: inline-block; width: .55em; height: .55em; margin-right: .5em; border-radius: 50%; background: #5a4b55; vertical-align: .05em; }
.hero-shops li.is-open::before { background: var(--lantern); box-shadow: 0 0 10px var(--lantern); }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 36px; }
.hero-actions .btn { white-space: nowrap; }
/* vertical shop-front strips either side of the sign */
.hero-kana { position: absolute; top: 50%; transform: translateY(-50%); writing-mode: vertical-rl; font-family: var(--display); font-size: clamp(1.6rem, 4vw, 3rem); line-height: 1; letter-spacing: .15em; color: var(--lantern); text-shadow: var(--glow-amber); }
.hero-kana.left { left: max(var(--pad), 4vw); }
.hero-kana.right { right: max(var(--pad), 4vw); color: #fff; text-shadow: var(--glow-red); }
@media (max-width: 700px) { .hero-kana { display: none; } .hero { min-height: 72svh; padding-top: 96px; } }
.video-toggle { position: absolute; right: var(--pad); bottom: 22px; width: 48px; height: 48px; border: 2px solid var(--paper); border-radius: 999px; background: #0e0a1299; color: var(--paper); cursor: pointer; display: grid; place-items: center; }
.video-toggle::before { content: ""; width: 12px; height: 14px; border-left: 4px solid; border-right: 4px solid; }
.video-toggle[data-playing="false"]::before { width: 0; height: 0; border: 8px solid transparent; border-left: 13px solid currentColor; border-right: 0; margin-left: 5px; }

/* The one motion moment: the sign flickers on, like a neon tube warming up */
@media (prefers-reduced-motion: no-preference) {
  .neon-sign { animation: flicker-on 1.6s steps(1, end) both .2s; }
  @keyframes flicker-on {
    0% { opacity: .15; text-shadow: none; }
    8% { opacity: 1; text-shadow: var(--glow-red); }
    12% { opacity: .2; text-shadow: none; }
    22% { opacity: 1; text-shadow: var(--glow-red); }
    26% { opacity: .35; text-shadow: none; }
    40%, 100% { opacity: 1; text-shadow: var(--glow-red); }
  }
}

/* Locations: lit lanterns hanging in the alley */
.signboards { padding: 72px 0 56px; background: var(--sign-bg); }
.boards { display: grid; gap: 34px; margin: 40px auto 0; padding: 18px var(--pad) 0; max-width: var(--max); }
.board { position: relative; display: grid; grid-template-columns: auto 1fr; grid-template-rows: repeat(4, auto) 1fr; gap: 0 18px; align-content: start; padding: 26px 22px 26px 16px; background: var(--surface); border: 1px solid var(--card-border); border-radius: 14px; box-shadow: var(--card-glow); }
.board::before { content: ""; position: absolute; top: -18px; left: 50%; width: 2px; height: 18px; background: #6b5a72; }
.board > * { grid-column: 2; }
.board-kana { grid-column: 1; grid-row: 1 / -1; writing-mode: vertical-rl; font-family: var(--display); font-size: 2.1rem; line-height: 1; padding: 14px 8px; margin-right: 4px; border-radius: 10px; letter-spacing: .05em; background: var(--unlit-bg); color: var(--unlit-fg); transition: background .4s, box-shadow .4s; }
/* Lantern lit when the shop is open (class set by main.js) */
.board.is-lit .board-kana { background: var(--lantern); color: #0E0A12; box-shadow: 0 0 28px #ffb547aa, 0 0 70px #ffb54744; }
.board h3 small { display: block; font: 700 .75rem var(--body); letter-spacing: .2em; color: var(--dim); }
.board h3 { margin-bottom: 14px; }
.board-status { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; min-height: 1.7em; font-weight: 700; color: var(--dim); }
/* Japanese shop-door tags: 準備中 (getting ready) / 営業中 (open). Alt text "" keeps them out of screen readers. */
.board-status::before { content: "準備中"; content: "準備中" / ""; flex: 0 0 auto; white-space: nowrap; padding: 2px 8px; border: 1px solid var(--dim); border-radius: 4px; font-size: .8rem; letter-spacing: .1em; }
.board-status.is-open { color: var(--paper); }
.board-status.is-open::before { content: "営業中"; content: "営業中" / ""; color: var(--tag-open-fg); border-color: var(--neon); background: var(--tag-open-bg); box-shadow: var(--kicker-glow); }
.board address { font-style: normal; margin-top: 14px; }
.board address a { text-decoration-color: #ff2e3f99; text-underline-offset: 4px; }
.board address a:hover { color: var(--lantern-text); }
.board-hours { margin-top: 12px; color: var(--dim); font-size: .9375rem; }
/* Actions pinned to the card bottom (last row is 1fr). Two buttons sit side by side at equal width when each gets 8.5rem, else stack full width; a lone button fills the row. */
.board-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 8.5rem), 1fr)); gap: 10px; align-self: end; margin-top: 22px; }
.board-actions .btn { justify-content: center; padding: 0 14px; white-space: nowrap; }
.board:hover { border-color: #ff2e3faa; box-shadow: var(--card-glow-hover); }
@media (min-width: 900px) { .boards { grid-template-columns: repeat(2, 1fr); gap: 28px; } }
@media (min-width: 1440px) { .boards { grid-template-columns: repeat(4, 1fr); max-width: 1400px; } }

/* Full-bleed photo band: the prefecture signboards above the yellow counter */
.band { height: clamp(120px, 18vw, 220px); background: url(/assets/slide-1.jpg) center 22%/cover; filter: saturate(1.15); box-shadow: inset 0 30px 40px -20px var(--night), inset 0 -30px 40px -20px var(--night); }

/* Chef */
.chef .wrap { display: grid; gap: 36px; align-items: center; }
.chef img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 4px; box-shadow: 0 0 80px #ff2e3f44; }
.chef h2 { font-size: clamp(2.2rem, 5.5vw, 3.8rem); }
@media (min-width: 800px) { .chef .wrap { grid-template-columns: 1fr 1fr; gap: 64px; } }

/* Vision + photo strip */
.strip { display: flex; gap: 12px; margin-top: 32px; padding-bottom: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: thin; scrollbar-color: var(--neon) transparent; }
.strip img { flex: 0 0 min(72%, 300px); scroll-snap-align: start; border-radius: 6px; object-fit: cover; }
@media (min-width: 960px) {
  .vision-grid { display: grid; grid-template-columns: 2fr 3fr; gap: 56px; align-items: center; }
  .strip { display: grid; grid-template-columns: 1fr 1fr; margin-top: 0; overflow: visible; padding: 0; }
  .strip img { width: 100%; height: 100%; aspect-ratio: 4 / 5; }
}

/* Video facade */
.video-box { position: relative; margin-top: 32px; aspect-ratio: 16 / 9; background: var(--alley); border-radius: 14px; overflow: hidden; box-shadow: 0 0 60px #ff2e3f22; }
.video-box iframe, .video-facade { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-facade { padding: 0; background: none; cursor: pointer; }
.video-facade img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.9); }
.video-facade:focus-visible { outline-offset: -6px; }
.play { position: absolute; left: 50%; top: 50%; width: 80px; height: 80px; margin: -40px 0 0 -40px; border: 3px solid var(--neon); border-radius: 50%; background: #0e0a1288; box-shadow: var(--glow-red); }
.play::before { content: ""; position: absolute; left: 30px; top: 22px; border: 15px solid transparent; border-left: 24px solid #fff; border-right: 0; }
.video-facade:hover .play { background: var(--neon); }

/* Menu pages */
.page-head { padding-top: 48px; }
.page-head h1 { font-size: clamp(2.6rem, 8vw, 4.5rem); color: var(--title-color); text-shadow: var(--title-glow); }
.page-head .muted { margin-top: 10px; }
/* Shop switcher stays pinned while scrolling the long menu images */
.switch { position: sticky; top: 0; z-index: 3; display: flex; flex-wrap: wrap; gap: 12px; max-width: var(--max); margin: 24px auto 0; padding: 10px var(--pad); background: var(--night); }
.menu-images { display: grid; gap: 28px; max-width: 900px; margin: 40px auto 88px; padding: 0 var(--pad); }
.menu-images img { width: 100%; border-radius: 10px; box-shadow: 0 0 50px #ffb54722; }

/* Text pages (mentions légales, 404) */
.prose { max-width: 70ch; padding-bottom: 88px; }
.prose h1 { font-size: clamp(2.2rem, 6vw, 3.5rem); }
.prose h2 { font-size: 1.6rem; margin-top: 44px; }
.prose h2::before { display: none; }
.prose p, .prose ul { margin-top: 12px; color: var(--dim); }
.prose li { margin-top: 4px; }
.todo { background: var(--lantern); color: #0E0A12; padding: 0 4px; font-weight: 700; }

/* Footer */
.site-footer { background: var(--footer-bg); border-top: 1px solid #ff2e3f44; box-shadow: 0 -1px 24px #ff2e3f22; padding: 56px 0 32px; }
.site-footer .wrap { display: grid; gap: 32px; }
.site-footer .logo img { width: 68px; height: 68px; }
.footer-shops { display: grid; gap: 20px; }
.footer-shops address { font-style: normal; color: var(--dim); }
.footer-shops strong, .footer-shops a, .footer-shops span { display: block; }
.footer-shops strong { color: var(--paper); }
.footer-shops a { text-decoration-color: #ff2e3f77; text-underline-offset: 4px; }
.footer-shops a:hover { color: var(--lantern-text); }
.footer-nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer-nav a { padding: 10px 0; text-decoration: none; }
.footer-nav a:hover { color: var(--lantern-text); }
.site-footer small { color: var(--dim); }
@media (min-width: 800px) {
  .site-footer .wrap { grid-template-columns: auto 1fr; align-items: start; }
  .footer-shops { grid-template-columns: repeat(3, 1fr); }
  .footer-nav, .site-footer small { grid-column: 2; }
}

/* Theme toggle */
.theme-toggle { width: 44px; height: 44px; margin-left: 6px; padding: 0; border: 2px solid currentColor; border-radius: 999px; background: transparent; color: inherit; cursor: pointer; font-size: 0; line-height: 0; display: inline-grid; place-items: center; align-self: center; }
/* SVG icons: sun in dark mode (switch to light), moon in light mode */
.theme-toggle svg { display: block; }
.theme-toggle .icon-moon, [data-theme="light"] .theme-toggle .icon-sun { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: block; }
.theme-toggle:hover { color: var(--lantern-text); }

/* Mobile UX (agent B) */
/* Tap feedback everywhere: no double-tap zoom delay, a visible press state */
a, button, .strip { touch-action: manipulation; }
a, button { -webkit-tap-highlight-color: #ff2e3f2e; }
.btn:active { transform: scale(.97); }
.btn-primary:active { background: var(--btn-bg-hover); }
.btn-ghost:active, .btn-ink:active { background: var(--lantern); color: #0E0A12; }
.site-header nav a:active, .footer-nav a:active, .footer-shops a:active, .hero-shops a:active { color: var(--lantern-text); }
.theme-toggle:active, .video-toggle:active { transform: scale(.92); }
.video-facade:active .play { background: var(--neon); }
.menu-images a { display: block; text-decoration: none; }
.menu-images a:active img { opacity: .85; }

/* Menu pages: on touch screens, say that a menu page opens full size */
.zoom-hint { display: none; }
@media (hover: none) { .zoom-hint { display: block; margin-top: 8px; text-align: center; font-size: .875rem; color: var(--dim); } }

/* Sticky action bar: mobile only, toggled by main.js (.is-visible) */
.action-bar { display: none; }

/* Photo strip below the 2-column breakpoint: edge to edge, peek + right fade say "it scrolls" */
@media (max-width: 959px) {
  .strip { margin-inline: calc(-1 * var(--pad)); padding-inline: var(--pad); scroll-padding-inline: var(--pad); overscroll-behavior-x: contain;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 48px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 48px), transparent); }
  /* main.js sets .at-end; the mask would also hide the focus ring, so lift it on focus */
  .strip.at-end, .strip:focus-visible { -webkit-mask-image: none; mask-image: none; }
  .strip:focus-visible { outline-offset: -3px; }
}

@media (max-width: 700px) {
  /* Header: logo, both links and the theme toggle on one row, vertically centered */
  .site-header { gap: 10px; padding-block: 10px; }
  .site-header .logo { flex: 0 0 auto; }
  .site-header .logo img { width: 48px; height: 48px; }
  .site-header nav { flex-wrap: nowrap; align-items: center; gap: 0 6px; }
  .site-header nav a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 44px; padding: 0 8px; white-space: nowrap; }
  .theme-toggle { flex: 0 0 44px; margin-left: 2px; }

  /* Hero */
  .hero { padding-bottom: 88px; } /* clears the video pause button */
  .hero h1 { gap: 12px; }
  .hero-shops { display: grid; gap: 0; max-width: 22rem; margin: 20px auto 0; text-align: left; background: #0e0a12b3; border: 1px solid #ffffff1f; border-radius: 12px; }
  .hero-shops:empty { display: none; }
  .hero-shops li { display: flex; align-items: center; padding-left: 14px; }
  .hero-shops li + li { border-top: 1px solid #ffffff14; }
  .hero-shops li::before { flex: 0 0 auto; }
  .hero-shops a { flex: 1; display: flex; align-items: center; min-height: 44px; padding: 6px 14px 6px 0; line-height: 1.35; }
  .hero-shops a:focus-visible { outline-offset: -3px; }
  .hero-actions { display: grid; gap: 10px; max-width: 22rem; margin: 24px auto 0; }
  .hero-actions .btn { justify-content: center; }

  /* Rhythm */
  .section { padding: 56px 0; }
  .page-head { padding-top: 28px; }
  .switch { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; padding-block: 8px; box-shadow: 0 8px 12px -10px #000a; }
  .switch .btn { justify-content: center; text-align: center; min-height: 44px; padding: 4px 10px; font-size: .9rem; line-height: 1.2; }
  .menu-images { gap: 20px; margin: 20px auto 56px; }
  .site-footer { padding-top: 44px; }

  /* Action bar */
  .action-bar { position: fixed; z-index: 5; inset: auto 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 10px var(--pad) calc(10px + env(safe-area-inset-bottom)); background: var(--night); border-top: 1px solid #ff2e3f44; box-shadow: 0 -6px 20px #0004; transform: translateY(110%); visibility: hidden; }
  .action-bar.is-visible { transform: none; visibility: visible; }
  .action-bar .btn { justify-content: center; padding: 0 12px; white-space: nowrap; }
  /* Room at the end of the content; on main, not body, so no off-colour strip under the footer */
  body:has(.action-bar) main { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
}
@media (max-width: 700px) and (prefers-reduced-motion: no-preference) {
  .action-bar { transition: transform .25s ease, visibility 0s .25s; }
  .action-bar.is-visible { transition: transform .25s ease; }
}

/* Smallest phones (320–380px): tighter gutter and header so the one-row header never overflows */
@media (max-width: 380px) {
  :root { --pad: 16px; }
  .site-header { gap: 8px; }
  .site-header .logo img { width: 40px; height: 40px; }
  .site-header nav { gap: 0 4px; }
  .site-header nav a { padding: 0 6px; font-size: .875rem; }
  .theme-toggle { margin-left: 0; }
}

/* iPhone notch / home bar: with viewport-fit=cover, keep content clear of the safe areas in landscape */
@supports (padding: max(0px)) {
  .site-header, .wrap { padding-left: max(var(--pad), env(safe-area-inset-left)); padding-right: max(var(--pad), env(safe-area-inset-right)); }
}

/* Restaurants carousel (agent A) */
/* Mobile: the four boards become a horizontal swipe carousel (CSS only, works without JS); chips and dots are built by main.js. */
@media (max-width: 899px) {
  .signboards { padding: 40px 0 28px; }
  .boards { grid-auto-flow: column; grid-auto-columns: 84%; gap: 14px; margin-top: 14px; padding: 18px var(--pad) 22px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad); scrollbar-width: none; }
  .boards::-webkit-scrollbar { display: none; }
  .boards:focus-visible { outline-offset: -3px; }
  .board { scroll-snap-align: center; }
  .boards.is-carousel .board:not(.is-active) { opacity: .8; } /* reduced motion; otherwise main.js sets scale/opacity per frame from the scroll position */

  .shops-tabs { display: flex; gap: 8px; margin-top: 16px; padding: 2px var(--pad); overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; }
  .shops-tabs::-webkit-scrollbar { display: none; }
  .shops-tabs button { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid var(--card-border); border-radius: 999px; background: var(--alley); color: var(--dim); font: 700 .875rem var(--body); cursor: pointer; }
  .shops-tabs button[aria-current] { color: var(--paper); border-color: var(--neon); box-shadow: var(--card-glow); }
  .shops-tabs button:focus-visible { outline-offset: -3px; }
  .shops-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--dim); opacity: .6; }
  .shops-tabs .is-open .shops-dot { background: var(--lantern); opacity: 1; box-shadow: 0 0 8px var(--lantern); }

  .shops-dots { display: flex; justify-content: center; gap: 8px; }
  .shops-dots span { width: 8px; height: 8px; border-radius: 999px; background: var(--dim); opacity: .5; }
  .shops-dots .is-active { width: 24px; background: var(--neon); opacity: 1; }
}
@media (min-width: 900px) { .shops-tabs, .shops-dots { display: none; } }
@media (max-width: 899px) and (prefers-reduced-motion: no-preference) {
  /* no transform/opacity transition: it would trail behind the finger-driven values */
  .boards.is-carousel .board { will-change: transform, opacity; }
  .shops-tabs button { transition: color .2s, border-color .2s; }
  .shops-dots span { transition: width .3s ease-out, background-color .3s ease-out; }
}

/* Mobile story swipe (agent B) */
.story-ui { display: none; }
@media (max-width: 899px) {
  /* Hero: shorter, so the restaurants section peeks above the fold */
  .hero { min-height: 0; grid-template-columns: minmax(0, 1fr); padding-bottom: 76px; }
  .hero-content { width: 100%; min-width: 0; }
  .hero-kana { display: none; } /* the full-width chip row would run into them */
  .hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 30rem; margin: 18px auto 0; }
  .hero-actions .btn { flex: 1 1 auto; justify-content: center; padding: 0 16px; font-size: .9375rem; }

  /* Hero live status: one row of swipeable chips, edge fades say "it scrolls" (main.js sets .at-end) */
  .hero-chips { margin: 14px calc(-1 * var(--pad)) 0; }
  .hero-shops { display: flex; flex-wrap: nowrap; justify-content: flex-start; gap: 8px; max-width: none; margin: 0; padding: 6px var(--pad) 8px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad); scrollbar-width: none; text-align: left; background: none; border: 0; border-radius: 0;
    -webkit-mask-image: linear-gradient(to right, transparent, #000 var(--pad), #000 calc(100% - 40px), transparent); mask-image: linear-gradient(to right, transparent, #000 var(--pad), #000 calc(100% - 40px), transparent); }
  .hero-shops::-webkit-scrollbar { display: none; }
  .hero-shops.at-end { -webkit-mask-image: linear-gradient(to right, transparent, #000 var(--pad)); mask-image: linear-gradient(to right, transparent, #000 var(--pad)); }
  .hero-shops:focus-within { -webkit-mask-image: none; mask-image: none; }
  .hero-shops li, .hero-shops li + li { position: relative; display: flex; flex: 0 0 auto; max-width: 88%; padding: 0; scroll-snap-align: start; background: #0e0a12b3; border: 1px solid #ffffff2e; border-radius: 999px; }
  .hero-shops li.is-open { border-color: #ffb54766; }
  /* the dot sits inside the link's padding, so the whole chip is the tap target */
  .hero-shops li::before { position: absolute; left: 14px; top: 50%; margin: 0; transform: translateY(-50%); pointer-events: none; }
  .hero-shops a { flex: 1; display: flex; align-items: center; min-height: 44px; padding: 6px 16px 6px 32px; border-radius: 999px; font-size: .875rem; line-height: 1.3; }
  .hero-shops a:focus-visible { outline-offset: -3px; }

  /* Decorative band repeats a story photo: hidden, it only adds scroll */
  .band { display: none; }

  /* Story: chef + vision + photos as one horizontal swipe (scroll-snap, next slide peeks) */
  .story { padding: 40px 0 36px; }
  .story:focus-visible { outline-offset: -3px; }
  .story-track { display: grid; grid-auto-flow: column; grid-auto-columns: min(calc(100% - 24px), 420px); gap: 12px; padding: 12px var(--pad) 16px; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad); scrollbar-width: none; }
  .story-track::-webkit-scrollbar { display: none; }
  .story .vision, .story .vision-grid, .story .strip { display: contents; }
  .story .story-slide { flex: 0 0 min(calc(100% - 24px), 420px); min-width: 0; scroll-snap-align: start; }
  .story .chef, .story .vision-text { display: flex; flex-direction: column; padding: 0; background: var(--surface); border: 1px solid var(--card-border); border-radius: 14px; box-shadow: var(--card-glow); overflow: hidden; }
  .story .chef .wrap { display: block; max-width: none; padding: 0; }
  .story .chef img { aspect-ratio: 16 / 10; object-position: 50% 25%; border-radius: 0; box-shadow: none; }
  .story .chef-text { padding: 18px 20px 22px; }
  .story .vision-text { justify-content: center; padding: 28px 20px; }
  .story h2 { font-size: 1.9rem; }
  .story .kicker { font-size: .95rem; letter-spacing: .14em; }
  .story .lead { margin-top: 12px; font-size: .95rem; line-height: 1.6; }
  .story .strip img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; } /* grid row = tallest slide, photos fill it */
  /* Cooking roadmap (bouillon -> bol), shown once main.js has wired the scroll listener: red line fills with the swipe, passed steps glow amber, current one pops */
  .story.is-ready .story-ui { display: block; padding: 6px var(--pad) 0; }
  .roadmap { position: relative; max-width: 380px; margin: 0 auto; }
  .roadmap ol { display: flex; justify-content: space-between; margin: 0; padding: 0 0 24px; list-style: none; }
  .roadmap li { position: relative; }
  .roadmap-line { position: absolute; top: 21px; left: 22px; right: 22px; height: 2px; border-radius: 2px; background: var(--card-border); }
  .roadmap-line i { display: block; height: 100%; border-radius: inherit; background: var(--kicker); box-shadow: var(--kicker-glow); transform-origin: left; transform: scaleX(0); }
  .roadmap button { position: relative; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1.5px solid var(--card-border); border-radius: 50%; background: var(--night); color: var(--dim); cursor: pointer; }
  .roadmap svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .roadmap .is-done { border-color: var(--lantern-text); color: var(--lantern-text); box-shadow: var(--glow-amber); }
  .roadmap .is-active { border-color: var(--kicker); color: var(--kicker); box-shadow: var(--kicker-glow); transform: scale(1.15); }
  .roadmap-label { position: absolute; top: calc(100% + 6px); left: 50%; transform: translateX(-50%); color: var(--kicker); font-size: .7rem; font-weight: 700; line-height: 1; white-space: nowrap; opacity: 0; pointer-events: none; }
  .roadmap li:first-child .roadmap-label { left: 0; transform: none; }
  .roadmap li:last-child .roadmap-label { left: auto; right: 0; transform: none; }
  .roadmap .is-active + .roadmap-label { opacity: 1; }
  .story-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

  /* Video: compact, 16:9 edge to edge */
  .video-section { padding: 28px 0 40px; }
  .video-section h2 { font-size: 1.6rem; }
  .video-section .video-box { margin: 14px calc(-1 * var(--pad)) 0; border-radius: 0; }
}
@media (max-width: 899px) and (prefers-reduced-motion: no-preference) {
  /* the active slide lifts 12px and brightens; neighbours stay visible as a swipe hint */
  .story.is-ready .story-slide { transition: opacity .45s ease, transform .45s ease; }
  .story.is-ready .story-slide:not(.is-active) { transform: translateY(12px); }
  /* each checkpoint "cooks" as it becomes current: pot wobbles, others hop, the bowl steams */
  .roadmap button { transition: transform .35s cubic-bezier(.3, 1.6, .5, 1), color .3s, border-color .3s, box-shadow .3s; }
  .roadmap-label { transition: opacity .3s; }
  .roadmap .is-active svg { animation: roadmap-hop .45s ease; }
  .roadmap .is-active .ico-pot { transform-origin: 50% 80%; animation-name: roadmap-wobble; }
  .roadmap .is-active .steam { animation: roadmap-steam 1.2s ease-out 3; }
  @keyframes roadmap-hop { 40% { transform: translateY(-4px); } 70% { transform: translateY(1px); } }
  @keyframes roadmap-wobble { 25% { transform: rotate(-12deg); } 50% { transform: rotate(9deg); } 75% { transform: rotate(-5deg); } }
  @keyframes roadmap-steam { 0% { opacity: 0; transform: translateY(3px); } 40% { opacity: 1; } 100% { opacity: 0; transform: translateY(-3px); } }
}
/* Dim only on phones, where an inactive slide is just a peek; on tablets it is fully readable */
@media (max-width: 700px) and (prefers-reduced-motion: no-preference) {
  .story.is-ready .story-slide:not(.is-active) { opacity: .45; }
}

/* Light theme: softer lit lantern (full neon amber + glow is too bright on white cards) */
[data-theme="light"] .board.is-lit .board-kana { background: #E9B467; color: #2A1A08; box-shadow: 0 4px 14px #b8742433; }
[data-theme="light"] .shops-tabs .is-open .shops-dot { background: #D9922E; box-shadow: none; }
[data-theme="light"] .hero-shops li.is-open::before { box-shadow: none; }

/* Videos: autoplay + lightbox (agent C) */
/* "Voir le film": pill left of the pause/play toggle */
.film-open { position: absolute; right: calc(var(--pad) + 60px); bottom: 22px; display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 18px 0 14px; border: 2px solid var(--paper); border-radius: 999px; background: #0e0a12b3; color: var(--paper); font: 700 .9375rem/1 var(--body); cursor: pointer; }
.film-open::before { content: ""; border: 7px solid transparent; border-left: 11px solid var(--neon); border-right: 0; }
.film-open:hover { background: var(--neon); }
.film-open:hover::before { border-left-color: #fff; }
.film-open:active { transform: scale(.95); }
@media (max-width: 899px) {
  /* Lighter veil so the film shows; the text shadow keeps hero text AA on bright frames */
  .hero::after { background: radial-gradient(ellipse 70% 55% at 50% 50%, #0e0a12a6 0%, #0e0a128c 60%, #0e0a1240 100%), linear-gradient(transparent 75%, var(--night)); }
  .hero-content p, .hero-sub { text-shadow: 0 1px 3px #000, 0 0 12px #0e0a12; }
  .film-open { left: var(--pad); right: auto; }
}

/* Full-screen lightbox player (always dark, both themes) */
.lightbox { width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 64px 12px 16px; border: 0; background: #000000eb; color: #fff; }
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: #000c; }
.lightbox-frame { width: min(100%, calc((100vh - 96px) * 16 / 9)); width: min(100%, calc((100dvh - 96px) * 16 / 9)); aspect-ratio: 16 / 9; background: #000; }
.lightbox-frame video { width: 100%; height: 100%; object-fit: contain; }
.lightbox-close { position: absolute; top: 12px; right: 12px; min-height: 44px; padding: 0 18px; border: 2px solid #fff; border-radius: 999px; background: #0e0a12; color: #fff; font: 700 1rem/1 var(--body); cursor: pointer; }
.lightbox-close:hover { background: var(--neon); }
.lightbox :focus-visible { outline-color: #FFB547; }
html.lightbox-open, html.lightbox-open body { overflow: hidden; }
@media (prefers-reduced-motion: no-preference) {
  .lightbox[open] { animation: lightbox-in .2s ease-out; }
  @keyframes lightbox-in { from { opacity: 0; } }
}

/* YouTube placeholder label and the muted-start sound hint */
.play-label { position: absolute; left: 0; right: 0; top: calc(50% + 52px); color: #fff; font-weight: 700; text-shadow: 0 1px 4px #000; }
.sound-hint { margin-top: 14px; background: none; font: 700 1rem/1 var(--body); cursor: pointer; }
@media (max-width: 899px) { .sound-hint { display: flex; width: fit-content; margin: 14px auto 0; } }

/* Hero rebalance: no pause button; "Voir le film" sits centred under the main actions */
.video-toggle { display: none; }
.hero-content .film-open { position: static; margin: 20px auto 0; min-height: 44px; padding: 0 18px 0 14px; border: 1px solid #f5efe673; background: #0e0a1259; font-size: .875rem; letter-spacing: .02em; }
.hero-content .film-open:hover { background: #f5efe61f; border-color: var(--paper); }
.hero-content .film-open:hover::before { border-left-color: var(--neon); }
.hero { padding-bottom: 72px; }
@media (max-width: 899px) {
  .hero { padding-bottom: 36px; }
  .hero-content .film-open { margin-top: 14px; }
}
