/* ============================================================
   Before Cafe — Warm Minimal
   ============================================================ */

:root {
  /* Light theme — cream / caramel / coffee */
  --bg: #faf6f0;
  --bg-elev: #f3eadd;
  --surface: #efe4d2;
  --line: #e3d6c0;
  --text: #2e2218;
  --text-soft: #6b5742;
  --muted: #9b8770;
  --accent: #a67b5b;
  --accent-deep: #7b5836;
  --highlight: #d9b282;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow-soft: 0 30px 60px -30px rgba(70, 45, 20, 0.18);

  --font-serif: "Cormorant Garamond", "Times New Roman", serif;
  --font-sans: "DM Sans", "IBM Plex Sans Thai", system-ui, -apple-system, sans-serif;
  --font-thai: "IBM Plex Sans Thai", "DM Sans", sans-serif;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 700ms;
}

[data-theme="dark"] {
  --bg: #16110d;
  --bg-elev: #1f1813;
  --surface: #2a211a;
  --line: #3a2e24;
  --text: #f1e7d6;
  --text-soft: #c4b39a;
  --muted: #8a7864;
  --accent: #d4ad82;
  --accent-deep: #b3895d;
  --highlight: #e7c69a;
  --shadow-soft: 0 30px 60px -30px rgba(0, 0, 0, 0.6);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}

:lang(th), body { font-family: var(--font-thai); }

h1, h2, h3, .serif, em {
  font-family: var(--font-serif);
  font-weight: 500;
  font-style: normal;
  letter-spacing: 0.01em;
}

em { font-style: italic; color: var(--accent-deep); }

a {
  color: inherit;
  text-decoration: none;
  position: relative;
}

img { max-width: 100%; display: block; }

::selection { background: var(--accent); color: var(--bg); }

/* ============================================================
   Logo (inline SVG via <use> — recolor follows currentColor)
   viewBox is 272.25 x 83.06 → aspect ~3.28:1
   ============================================================ */
.logo {
  display: inline-block;
  fill: currentColor;
  vertical-align: middle;
}
.logo--nav    { width: 110px; height: 34px; }
.logo--footer { width: 130px; height: 40px; }
.logo--loader { width: 220px; height: 67px; }

/* ============================================================
   "What's new" announcement banner (hidden by default)
   ============================================================ */
.whatsnew {
  position: relative;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding: 12px 6vw;
  margin-top: 80px; /* clear the fixed nav */
  background: color-mix(in srgb, var(--highlight) 22%, transparent);
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  color: var(--text);
  z-index: 50;
}
.whatsnew.is-hidden { display: none; }

.whatsnew__pulse {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent-deep);
  flex-shrink: 0;
  animation: comingPulse 2s ease-in-out infinite;
}
.whatsnew__badge {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-deep);
  padding: 3px 9px;
  border: 1px solid var(--accent);
  border-radius: 999px;
}
.whatsnew__text {
  flex: 1 1 200px;
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}
.whatsnew__cta {
  color: var(--accent-deep);
  font-weight: 500;
  letter-spacing: 0.02em;
  border-bottom: 1px solid currentColor;
  padding-bottom: 1px;
  transition: color 250ms var(--ease);
}
.whatsnew__cta:hover { color: var(--text); }
.whatsnew__close {
  display: grid;
  place-items: center;
  width: 28px; height: 28px;
  border: none;
  background: transparent;
  color: var(--text-soft);
  border-radius: 50%;
  cursor: pointer;
  transition: color 250ms var(--ease), background 250ms var(--ease);
}
.whatsnew__close svg { width: 16px; height: 16px; }
.whatsnew__close:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--text) 10%, transparent);
}

/* Body offset so hero isn't pushed down by margin-top when banner hidden */
.whatsnew:not(.is-hidden) ~ main .hero { padding-top: 80px; }

/* ============================================================
   Thai-mode tweaks — reviews are originals in TH, so:
   - hide the AI-translated disclaimer
   - hide the per-review "see original" toggle
   ============================================================ */
html[lang="th"] .reviews .ai-note,
html[lang="th"] .review__toggle {
  display: none;
}

/* ============================================================
   Scroll progress bar — thin line at top showing read progress
   ============================================================ */
.scroll-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  z-index: 9000;
  background: linear-gradient(90deg, var(--highlight), var(--accent), var(--accent-deep));
  transform: scaleX(0);
  transform-origin: 0 50%;
  will-change: transform;
  pointer-events: none;
}

/* ============================================================
   Focus visible — clear ring for keyboard users
   ============================================================ */
*:focus { outline: none; }
*:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}
.btn:focus-visible,
.nav__theme:focus-visible,
.nav__burger:focus-visible,
.nav__langBtn:focus-visible,
.backtop:focus-visible {
  outline-offset: 4px;
}
a:focus-visible { outline-offset: 4px; }

/* ============================================================
   Skip-to-content (a11y) — visible only when focused via Tab
   ============================================================ */
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 10001;
  padding: 10px 18px;
  background: var(--text);
  color: var(--bg);
  border-radius: 999px;
  font-size: 13px;
  letter-spacing: 0.06em;
  transform: translateY(-150%);
  transition: transform 300ms var(--ease);
}
.skip-link:focus { transform: translateY(0); }

/* ============================================================
   Back-to-top button — appears after the user scrolls
   ============================================================ */
.backtop {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--text);
  cursor: pointer;
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 350ms var(--ease), visibility 350ms var(--ease), transform 350ms var(--ease), border-color 250ms var(--ease), color 250ms var(--ease);
  z-index: 80;
  box-shadow: var(--shadow-soft);
}
.backtop.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.backtop:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}
.backtop svg { width: 18px; height: 18px; transition: transform 300ms var(--ease); }
.backtop:hover svg { transform: translateY(-2px); }

/* ============================================================
   Get-directions button extras (use .btn styles, position only)
   ============================================================ */
.visit__directions {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* ============================================================
   Active nav highlight (scroll-spy)
   ============================================================ */
.nav__links a.is-current {
  color: var(--text);
}
.nav__links a.is-current::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* ============================================================
   Cursor
   ============================================================ */
.cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-deep);
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 250ms var(--ease), height 250ms var(--ease),
              background 250ms var(--ease), opacity 250ms var(--ease);
  mix-blend-mode: normal;
}
.cursor--ring {
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--accent);
  transition: transform 400ms var(--ease), width 350ms var(--ease),
              height 350ms var(--ease), opacity 350ms var(--ease),
              border-color 350ms var(--ease);
}
.cursor.is-hover { width: 12px; height: 12px; opacity: 0; }
.cursor--ring.is-hover {
  width: 56px; height: 56px;
  border-color: var(--accent-deep);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
}
@media (hover: none) {
  .cursor { display: none; }
}

/* ============================================================
   Loader
   ============================================================ */
.loader {
  position: fixed; inset: 0;
  background: var(--bg);
  z-index: 10000;
  display: grid;
  place-items: center;
  transition: opacity 700ms var(--ease), visibility 700ms var(--ease);
}
.loader.is-done { opacity: 0; visibility: hidden; }
.loader__inner {
  display: flex; flex-direction: column; align-items: center; gap: 18px;
  color: var(--text);
  animation: loaderBreath 1800ms ease-in-out infinite;
}
.loader__inner .logo--loader {
  animation: loaderReveal 1400ms var(--ease) both;
}
.loader__tag {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 14px;
  letter-spacing: 0.04em;
  color: var(--text-soft);
  opacity: 0;
  animation: loaderTag 1200ms var(--ease) 400ms forwards;
}
@keyframes loaderReveal {
  0%   { opacity: 0; transform: translateY(10px); clip-path: inset(0 100% 0 0); }
  60%  { opacity: 1; }
  100% { opacity: 1; transform: translateY(0); clip-path: inset(0 0 0 0); }
}
@keyframes loaderTag {
  to { opacity: 1; }
}
@keyframes loaderBreath {
  0%, 100% { opacity: 0.92; transform: translateY(0); }
  50%      { opacity: 1; transform: translateY(-2px); }
}

/* ============================================================
   Nav
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 6vw;
  z-index: 100;
  transition: padding 450ms var(--ease);
  /* Background / blur / border live on ::before below so the nav itself
     never has backdrop-filter (which creates a containing block that
     would trap the fixed mobile menu inside this 60px strip). */
}
.nav::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: transparent;
  border-bottom: 1px solid transparent;
  pointer-events: none;
  transition: background 450ms var(--ease),
              backdrop-filter 450ms var(--ease),
              -webkit-backdrop-filter 450ms var(--ease),
              border-color 450ms var(--ease);
}
.nav.is-scrolled { padding: 14px 6vw; }
.nav.is-scrolled::before {
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}
.nav__brand {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-serif);
  font-size: 20px;
  letter-spacing: 0.04em;
  color: var(--text);
  transition: color 250ms var(--ease), transform 250ms var(--ease);
}
.nav__brand:hover { color: var(--accent-deep); }
.nav__brand:hover .logo { transform: translateY(-1px); }
.nav__brand .logo { transition: transform 350ms var(--ease); }
.nav__links {
  display: flex; gap: 36px;
  font-size: 14px;
  letter-spacing: 0.04em;
}
.nav__links a {
  color: var(--text-soft);
  transition: color 250ms var(--ease);
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  height: 1px; width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 450ms var(--ease);
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }

.nav__right {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Language switcher — globe button + dropdown menu */
.nav__lang {
  position: relative;
  display: inline-flex;
}
.nav__langBtn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font-family: inherit;
  font-size: 11px;
  letter-spacing: 0.14em;
  cursor: pointer;
  transition: border-color 250ms var(--ease), color 250ms var(--ease);
}
.nav__langBtn:hover { border-color: var(--accent); color: var(--accent-deep); }
.nav__langIcon {
  width: 14px;
  height: 14px;
  transition: transform 400ms var(--ease);
}
.nav__lang.is-open .nav__langIcon { transform: rotate(180deg); }

.nav__langMenu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  list-style: none;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: color-mix(in srgb, var(--bg) 96%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--shadow-soft);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 280ms var(--ease), transform 280ms var(--ease), visibility 280ms var(--ease);
  z-index: 200;
}
.nav__lang.is-open .nav__langMenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.nav__langMenu li { list-style: none; }
.nav__langOpt {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 9px 12px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  color: var(--text-soft);
  transition: background 220ms var(--ease), color 220ms var(--ease);
}
.nav__langOpt span:first-child {
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--muted);
}
.nav__langOpt span:last-child {
  font-size: 14px;
  font-family: var(--font-serif);
}
.nav__langOpt:hover {
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  color: var(--text);
}
.nav__langOpt.is-active {
  background: var(--text);
  color: var(--bg);
}
.nav__langOpt.is-active span:first-child { color: color-mix(in srgb, var(--bg) 65%, transparent); }

/* Translation-disclaimer note (reviews + menu) */
.ai-note {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.02em;
  font-style: italic;
  margin-top: 30px;
  max-width: 540px;
}
.ai-note--center {
  text-align: center;
  margin: 14px auto 0;
}
.reviews .ai-note {
  text-align: center;
  margin: 30px auto 24px;
}

/* Hamburger button — hidden on desktop */
.nav__burger {
  display: none;
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  position: relative;
  transition: border-color 250ms var(--ease), background 250ms var(--ease);
}
.nav__burger:hover { border-color: var(--accent); }
.nav__burger span {
  position: absolute;
  left: 50%; top: 50%;
  width: 16px;
  height: 1.5px;
  background: currentColor;
  border-radius: 1px;
  transform-origin: center;
  transition: transform 350ms var(--ease), opacity 250ms var(--ease);
}
.nav__burger span:nth-child(1) { transform: translate(-50%, calc(-50% - 5px)); }
.nav__burger span:nth-child(2) { transform: translate(-50%, -50%); }
.nav__burger span:nth-child(3) { transform: translate(-50%, calc(-50% + 5px)); }

.nav__burger.is-open span:nth-child(1) { transform: translate(-50%, -50%) rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { opacity: 0; }
.nav__burger.is-open span:nth-child(3) { transform: translate(-50%, -50%) rotate(-45deg); }

@media (max-width: 1024px) {
  .nav__links { gap: 22px; font-size: 13px; }
}

/* Close button hidden on desktop (only visible inside mobile overlay) */
.nav__close { display: none; }

@media (max-width: 720px) {
  .nav__burger { display: block; }

  /* Mobile menu — full-screen overlay
     Performance: only transform/opacity animate here. backdrop-filter is
     expensive, so we keep its radius moderate and avoid repainting layers. */
  .nav__links {
    position: fixed;
    inset: 0;
    /* Static layered gradient — costs nothing per frame */
    background:
      radial-gradient(55vw 55vw at 18% 28%, color-mix(in srgb, var(--accent) 28%, transparent), transparent 55%),
      radial-gradient(50vw 50vw at 82% 72%, color-mix(in srgb, var(--highlight) 32%, transparent), transparent 55%),
      color-mix(in srgb, var(--bg) 62%, transparent);
    backdrop-filter: blur(18px) saturate(1.1);
    -webkit-backdrop-filter: blur(18px) saturate(1.1);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 28px;
    font-size: 22px;
    letter-spacing: 0.05em;
    z-index: 90;
    opacity: 0;
    visibility: hidden;
    overflow: hidden;
    transition: opacity 600ms var(--ease), visibility 600ms var(--ease);
  }
  .nav__links.is-open {
    opacity: 1;
    visibility: visible;
  }

  /* Two soft orbs drift across the overlay.
     The gradient itself fades to transparent — no filter:blur() needed,
     so motion stays GPU-cheap. */
  .nav__links::before,
  .nav__links::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 800ms var(--ease);
    will-change: transform;
    transform: translate3d(0, 0, 0);
  }
  .nav__links::before {
    width: 80vw; height: 80vw;
    max-width: 600px; max-height: 600px;
    top: -22%; left: -28%;
    background: radial-gradient(circle,
      color-mix(in srgb, var(--highlight) 70%, transparent) 0%,
      color-mix(in srgb, var(--highlight) 18%, transparent) 38%,
      transparent 68%);
    animation: orbDriftA 14s ease-in-out infinite;
  }
  .nav__links::after {
    width: 90vw; height: 90vw;
    max-width: 680px; max-height: 680px;
    bottom: -26%; right: -30%;
    background: radial-gradient(circle,
      color-mix(in srgb, var(--accent) 65%, transparent) 0%,
      color-mix(in srgb, var(--accent) 16%, transparent) 42%,
      transparent 68%);
    animation: orbDriftB 18s ease-in-out infinite;
  }
  .nav__links.is-open::before,
  .nav__links.is-open::after {
    opacity: 0.85;
  }

  @keyframes orbDriftA {
    0%   { transform: translate3d(0, 0, 0) scale(1); }
    50%  { transform: translate3d(12vw, 28vh, 0) scale(1.15); }
    100% { transform: translate3d(0, 0, 0) scale(1); }
  }
  @keyframes orbDriftB {
    0%   { transform: translate3d(0, 0, 0) scale(1); }
    50%  { transform: translate3d(-14vw, -18vh, 0) scale(0.88); }
    100% { transform: translate3d(0, 0, 0) scale(1); }
  }

  /* Close button — top-right of the overlay */
  .nav__close {
    display: grid;
    place-items: center;
    position: absolute;
    top: 22px; right: 6vw;
    width: 46px; height: 46px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: color-mix(in srgb, var(--bg) 50%, transparent);
    color: var(--text);
    cursor: pointer;
    z-index: 2;
    opacity: 0;
    transform: scale(0.6) rotate(-45deg);
    transition:
      opacity 500ms var(--ease) 200ms,
      transform 500ms var(--ease) 200ms,
      border-color 250ms var(--ease),
      background 250ms var(--ease);
  }
  .nav__close svg {
    width: 18px; height: 18px;
    transition: transform 350ms var(--ease);
  }
  .nav__close:hover {
    border-color: var(--accent);
    background: color-mix(in srgb, var(--accent) 14%, transparent);
  }
  .nav__close:hover svg { transform: rotate(90deg); }
  .nav__links.is-open .nav__close {
    opacity: 1;
    transform: scale(1) rotate(0);
  }

  /* Link entrance — use :nth-of-type so the close <button> doesn't shift counting */
  .nav__links a {
    font-family: var(--font-serif);
    color: var(--text);
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 600ms var(--ease), transform 600ms var(--ease), color 250ms var(--ease);
    z-index: 1;
  }
  .nav__links.is-open a {
    opacity: 1;
    transform: translateY(0);
  }
  .nav__links.is-open a:nth-of-type(1) { transition-delay: 200ms; }
  .nav__links.is-open a:nth-of-type(2) { transition-delay: 260ms; }
  .nav__links.is-open a:nth-of-type(3) { transition-delay: 320ms; }
  .nav__links.is-open a:nth-of-type(4) { transition-delay: 380ms; }
  .nav__links.is-open a:nth-of-type(5) { transition-delay: 440ms; }
  .nav__links.is-open a:nth-of-type(6) { transition-delay: 500ms; }
  .nav__links a::after { display: none; }
}

.nav__theme {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  display: grid; place-items: center;
  transition: background 250ms var(--ease), border-color 250ms var(--ease), transform 250ms var(--ease);
}
.nav__theme:hover { border-color: var(--accent); transform: rotate(15deg); }
.nav__themeIcon {
  width: 18px; height: 18px;
  /* Stack both sun + moon icons in the same grid cell so they overlap perfectly.
     Avoids `position: absolute` which was floating to .nav on mobile. */
  grid-area: 1 / 1;
  transition: opacity 350ms var(--ease), transform 350ms var(--ease);
}
[data-theme="light"] .nav__themeIcon--sun { opacity: 1; transform: rotate(0); }
[data-theme="light"] .nav__themeIcon--moon { opacity: 0; transform: rotate(-90deg); }
[data-theme="dark"] .nav__themeIcon--sun { opacity: 0; transform: rotate(90deg); }
[data-theme="dark"] .nav__themeIcon--moon { opacity: 1; transform: rotate(0); }

/* ============================================================
   Reveal animation
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 900ms var(--ease), transform 900ms var(--ease);
  transition-delay: var(--delay, 0ms);
}
.reveal.is-in { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ============================================================
   Typography helpers
   ============================================================ */
.eyebrow {
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin-bottom: 18px;
  font-weight: 500;
}
.section__title {
  font-size: clamp(2rem, 4.2vw, 3.2rem);
  line-height: 1.1;
  margin-bottom: 28px;
}
.section__head {
  text-align: center;
  margin: 0 auto 60px;
  max-width: 720px;
  padding: 0 6vw;
}
.section__lede { color: var(--text-soft); }

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  padding: 140px 6vw 80px;
  display: grid;
  align-items: center;
  overflow: hidden;
}
.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  /* fallback ขณะวิดีโอยังโหลด / ถ้า browser เล่นไม่ได้ */
  background:
    radial-gradient(800px 500px at 20% 20%, color-mix(in srgb, var(--highlight) 30%, transparent), transparent 60%),
    radial-gradient(700px 500px at 85% 70%, color-mix(in srgb, var(--accent) 24%, transparent), transparent 60%),
    linear-gradient(180deg, var(--bg), var(--bg-elev));
}
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  /* tint overlay ให้ข้อความบน hero อ่านได้ในทุกธีม */
  background:
    linear-gradient(180deg,
      color-mix(in srgb, var(--bg) 35%, transparent) 0%,
      color-mix(in srgb, var(--bg) 55%, transparent) 60%,
      color-mix(in srgb, var(--bg) 88%, transparent) 100%
    );
}
.hero__steam {
  position: absolute;
  right: 8vw; top: 22%;
  width: 60px; height: 200px;
  z-index: 1;
  opacity: 0.55;
}
.hero__steam span {
  position: absolute; bottom: 0; left: 50%;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent);
  filter: blur(8px);
  animation: steam 4s var(--ease) infinite;
}
.hero__steam span:nth-child(2) { left: 30%; animation-delay: 1.2s; }
.hero__steam span:nth-child(3) { left: 70%; animation-delay: 2.4s; }
@keyframes steam {
  0%   { transform: translate(-50%, 0) scale(1); opacity: 0; }
  20%  { opacity: 0.7; }
  100% { transform: translate(-50%, -180px) scale(2.2); opacity: 0; }
}
.hero__watermark {
  position: absolute;
  right: -3vw;
  bottom: -2vw;
  width: min(70vw, 900px);
  height: min(22vw, 280px);
  color: var(--accent);
  opacity: 0.08;
  z-index: 1;
  pointer-events: none;
}
[data-theme="dark"] .hero__watermark { opacity: 0.06; }

.hero__content {
  position: relative; z-index: 2;
  max-width: 880px;
}
.hero__title {
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  margin: 14px 0 24px;
}
.hero__line { display: block; }
.hero__sub {
  color: var(--text-soft);
  font-size: clamp(1rem, 1.2vw, 1.125rem);
  max-width: 520px;
  margin-bottom: 36px;
}
.hero__cta { display: flex; gap: 16px; flex-wrap: wrap; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  font-size: 14px;
  letter-spacing: 0.06em;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 300ms var(--ease), background 300ms var(--ease),
              color 300ms var(--ease), border-color 300ms var(--ease);
}
.btn--solid {
  background: var(--text);
  color: var(--bg);
}
.btn--solid:hover { background: var(--accent-deep); transform: translateY(-2px); }
.btn--ghost {
  border-color: var(--line);
  color: var(--text);
}
.btn--ghost:hover { border-color: var(--accent); color: var(--accent-deep); transform: translateY(-2px); }

.btn__icon {
  width: 16px;
  height: 16px;
  margin-right: 2px;
  transition: transform 350ms var(--ease);
}
.btn--ig:hover .btn__icon { transform: rotate(-8deg) scale(1.1); }

.hero__scroll {
  position: absolute;
  left: 6vw; bottom: 30px;
  z-index: 2;
  display: flex; align-items: center; gap: 14px;
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--text-soft);
}
.hero__scrollLine {
  display: inline-block;
  width: 60px; height: 1px;
  background: var(--text-soft);
  position: relative;
  overflow: hidden;
}
.hero__scrollLine::after {
  content: "";
  position: absolute; inset: 0;
  background: var(--accent-deep);
  transform: translateX(-100%);
  animation: scrollLine 2.2s var(--ease) infinite;
}
@keyframes scrollLine {
  0%   { transform: translateX(-100%); }
  50%  { transform: translateX(0); }
  100% { transform: translateX(100%); }
}

/* ============================================================
   About
   ============================================================ */
.about { padding: 120px 6vw; }
.about__grid {
  display: grid;
  grid-template-columns: 0.85fr 1fr;
  gap: 80px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}
.about__media {
  position: relative;
  aspect-ratio: 3 / 4;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}
.about__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 1400ms var(--ease), filter 600ms var(--ease);
}
.about__media:hover img {
  transform: scale(1.04);
  filter: brightness(1.04);
}
.about__media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 60%, color-mix(in srgb, var(--text) 35%, transparent));
  pointer-events: none;
  opacity: 0.6;
  transition: opacity 500ms var(--ease);
}
.about__media:hover::after { opacity: 0.4; }
.about__mediaTag {
  position: absolute;
  left: 18px; bottom: 16px;
  padding: 7px 14px;
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 999px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text);
  z-index: 2;
}
.about__text p { margin-bottom: 22px; color: var(--text-soft); }

.about__lead {
  font-size: 1.02rem;
  line-height: 1.75;
}
.about__verse {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.35rem;
  line-height: 1.6;
  color: var(--text);
  padding: 20px 0 20px 24px;
  margin: 8px 0 !important;
  border-left: 1px solid var(--accent);
  position: relative;
}
.about__verse span {
  color: var(--accent-deep);
  font-weight: 500;
  letter-spacing: 0.01em;
}
.about__signoff {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--accent-deep) !important;
  margin-top: 8px !important;
}
.about__signoff span {
  display: inline-block;
  margin-left: 4px;
  transform-origin: center;
  animation: signoffWink 4s ease-in-out infinite;
}
@keyframes signoffWink {
  0%, 85%, 100% { transform: rotate(0); }
  90%           { transform: rotate(-8deg); }
  95%           { transform: rotate(8deg); }
}
.about__meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.about__num {
  display: block;
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--accent-deep);
  margin-bottom: 4px;
}
.about__label {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
@media (max-width: 800px) {
  .about__grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ============================================================
   Menu
   ============================================================ */
.menu { padding: 120px 6vw; background: var(--bg-elev); }

.menu__tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 60px;
}
.menu__tab {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-soft);
  padding: 10px 22px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 13px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: all 350ms var(--ease);
}
.menu__tab:hover { color: var(--text); border-color: var(--accent); }
.menu__tab.is-active {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.menu__panels { max-width: 1080px; margin: 0 auto; }
.menu__list {
  list-style: none;
  display: none;
}
.menu__list.is-active {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 60px;
  row-gap: 0;
  align-content: start;
}
@media (max-width: 760px) {
  .menu__list.is-active { grid-template-columns: 1fr; column-gap: 0; }
}

/* Customization note — visible call-out */
.menu__custom {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 18px auto 0;
  padding: 10px 22px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  font-size: 14px;
  color: var(--text-soft);
}
.menu__custom em {
  color: var(--accent-deep);
  font-weight: 500;
  font-style: italic;
}
.menu__customMark {
  color: var(--accent);
  font-size: 14px;
  animation: customMarkSpin 6s linear infinite;
}
@keyframes customMarkSpin {
  to { transform: rotate(360deg); }
}

/* Tab badge — "soon" pill on the Food tab */
.menu__tab--soon {
  position: relative;
  padding-right: 14px;
}
.menu__tabBadge {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  font-size: 9px;
  font-family: var(--font-sans);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  border-radius: 999px;
  transition: color 250ms var(--ease), background 250ms var(--ease);
}
.menu__tab--soon.is-active .menu__tabBadge {
  color: var(--bg);
  background: color-mix(in srgb, var(--bg) 22%, transparent);
}

/* "Coming soon" panel — Food category */
.menu__coming {
  grid-column: 1 / -1;
  list-style: none;
  text-align: center;
  padding: 70px 24px 40px;
  border-bottom: none;
}
.menu__comingMark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin-bottom: 26px;
}
.menu__comingDot {
  width: 8px; height: 8px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-block;
  animation: comingPulse 2.2s ease-in-out infinite;
}
@keyframes comingPulse {
  0%, 100% { opacity: 0.35; transform: scale(0.9); box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 40%, transparent); }
  50%      { opacity: 1; transform: scale(1.15); box-shadow: 0 0 0 8px color-mix(in srgb, var(--accent) 0%, transparent); }
}
.menu__comingTitle {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(2.4rem, 6vw, 3.8rem);
  line-height: 1.05;
  margin-bottom: 26px;
  color: var(--text);
}
.menu__comingTitle em {
  color: var(--accent-deep);
  font-style: italic;
}
.menu__comingText {
  color: var(--text-soft);
  font-size: 1.05rem;
  max-width: 540px;
  margin: 0 auto 12px;
  line-height: 1.75;
}
.menu__comingText--th { color: var(--muted); }
.menu__comingTag {
  margin-top: 32px;
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: 0.12em;
}

/* Sub-section header inside a tab (e.g. "— Thai Tea —") */
.menu__sub {
  grid-column: 1 / -1;
  list-style: none;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  letter-spacing: 0.06em;
  color: var(--accent-deep);
  text-align: center;
  padding: 32px 0 10px;
  border-bottom: none;
}
.menu__sub:first-child { padding-top: 4px; }
.menu__item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-areas:
    "name dots price"
    "desc desc desc";
  gap: 6px 14px;
  align-items: baseline;
  padding: 22px 4px;
  border-bottom: 1px solid var(--line);
  transition: padding 300ms var(--ease), background 300ms var(--ease);
}
.menu__item:hover {
  padding-left: 14px;
  padding-right: 14px;
  background: color-mix(in srgb, var(--surface) 50%, transparent);
}
.menu__name {
  grid-area: name;
  font-family: var(--font-serif);
  font-size: 1.5rem;
}
.menu__dot {
  grid-area: dots;
  border-bottom: 1px dotted var(--muted);
  align-self: end;
  margin-bottom: 6px;
}
.menu__price {
  grid-area: price;
  font-variant-numeric: tabular-nums;
  font-size: 1.1rem;
  color: var(--accent-deep);
}
.menu__price::before { content: "฿ "; font-size: 0.8em; color: var(--muted); }
.menu__desc {
  grid-area: desc;
  font-size: 13px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* ============================================================
   Gallery
   ============================================================ */
.gallery { padding: 120px 6vw; }
.gallery__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 200px;
  gap: 16px;
  max-width: 1300px;
  margin: 0 auto;
}
.gallery__item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface);
  cursor: pointer;
  grid-row: span 1;
}
.gallery__item--tall { grid-row: span 2; grid-column: span 1; }
.gallery__item--wide { grid-column: span 2; }
.gallery__item .placeholder {
  height: 100%;
  transition: transform 900ms var(--ease);
}
.gallery__item:hover .placeholder { transform: scale(1.08); }
.gallery__item figcaption {
  position: absolute;
  left: 18px; bottom: 16px;
  padding: 6px 12px;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(6px);
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--text);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 400ms var(--ease), transform 400ms var(--ease);
}
.gallery__item:hover figcaption { opacity: 1; transform: translateY(0); }

@media (max-width: 800px) {
  .gallery__grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 160px;
  }
  .gallery__item--wide { grid-column: span 2; }
  .gallery__item--tall { grid-row: span 2; }
}

/* ============================================================
   Reviews
   ============================================================ */
.reviews {
  padding: 120px 6vw;
  background: var(--bg-elev);
}
.reviews__stars {
  letter-spacing: 0.12em;
  color: var(--accent-deep);
  margin-right: 10px;
  font-size: 1rem;
}
.reviews__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto 50px;
}
.review {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: transform 450ms var(--ease), box-shadow 450ms var(--ease), border-color 450ms var(--ease);
  position: relative;
  overflow: hidden;
}
.review::before {
  content: "”";
  position: absolute;
  top: -20px; right: 18px;
  font-family: var(--font-serif);
  font-size: 8rem;
  line-height: 1;
  color: var(--accent);
  opacity: 0.18;
  transition: opacity 400ms var(--ease), transform 500ms var(--ease);
}
.review:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
  border-color: var(--accent);
}
.review:hover::before { opacity: 0.32; transform: translateY(-6px); }
.review__stars {
  color: var(--accent-deep);
  letter-spacing: 0.18em;
  font-size: 1rem;
}
.review__text {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--text);
  font-style: italic;
}
.review__meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 13px;
}
.review__author { color: var(--text-soft); }
.review__when { color: var(--muted); font-size: 12px; }

.review__star--dim {
  color: var(--muted);
  opacity: 0.45;
}

/* Original / translation toggle */
.review__text--original { display: none; }
.review.is-original .review__text--translation { display: none; }
.review.is-original .review__text--original { display: block; }

.review__toggle {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: -6px 0 0;
  padding: 4px 0;
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 250ms var(--ease), letter-spacing 250ms var(--ease);
}
.review__toggle:hover {
  color: var(--accent-deep);
  letter-spacing: 0.2em;
}
.review__toggleIcon {
  display: inline-block;
  transition: transform 350ms var(--ease);
}
.review.is-original .review__toggleIcon { transform: rotate(180deg); }
.review__source {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: all 300ms var(--ease);
}
.review__source:hover {
  color: var(--accent-deep);
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}

.reviews__cta { text-align: center; }

/* ============================================================
   FAQ — collapsible <details>/<summary>
   ============================================================ */
.faq { padding: 120px 6vw; }
.faq__list {
  max-width: 820px;
  margin: 0 auto;
}
.faq__item {
  border-bottom: 1px solid var(--line);
}
.faq__item summary {
  cursor: pointer;
  list-style: none;
  padding: 26px 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  font-family: var(--font-serif);
  font-size: clamp(1.15rem, 1.6vw, 1.4rem);
  color: var(--text);
  transition: color 250ms var(--ease), padding 350ms var(--ease);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: "";
  flex-shrink: 0;
  width: 14px; height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 14px 1.5px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1.5px 14px no-repeat;
  color: var(--accent-deep);
  transition: transform 350ms var(--ease);
}
.faq__item[open] summary::after {
  transform: rotate(45deg);
}
.faq__item:hover summary {
  color: var(--accent-deep);
  padding-left: 10px;
}
.faq__answer {
  padding: 0 4px 26px;
}
.faq__answer p {
  color: var(--text-soft);
  font-size: 1rem;
  line-height: 1.75;
  max-width: 620px;
}

/* ============================================================
   Visit
   ============================================================ */
.visit { padding: 120px 6vw; background: var(--bg-elev); }
.visit__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 80px;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
}
.visit__block { margin-bottom: 36px; }
.visit__block h3 {
  font-size: 1.4rem;
  margin-bottom: 10px;
  color: var(--text);
}
.visit__block p { color: var(--text-soft); }

.hours {
  list-style: none;
  border-top: 1px solid var(--line);
}
.hours li {
  display: flex;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
  color: var(--text-soft);
}
.hours__note { color: var(--muted); font-size: 13px; }

.social {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.social a {
  color: var(--text-soft);
  transition: color 250ms var(--ease), letter-spacing 250ms var(--ease);
  display: inline-block;
}
.social a:hover { color: var(--accent-deep); letter-spacing: 0.03em; }

/* Delivery pill buttons */
.delivery {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.delivery__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text);
  background: transparent;
  transition: border-color 300ms var(--ease), background 300ms var(--ease), color 300ms var(--ease), transform 300ms var(--ease);
}
.delivery__btn:hover {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  color: var(--accent-deep);
  transform: translateY(-2px);
}
.delivery__arrow {
  font-size: 11px;
  color: var(--muted);
  transition: transform 300ms var(--ease), color 300ms var(--ease);
}
.delivery__btn:hover .delivery__arrow {
  color: var(--accent-deep);
  transform: translate(2px, -2px);
}

.visit__map {
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--line);
}
.visit__map iframe {
  width: 100%; height: 100%;
  border: 0;
  filter: saturate(0.85) contrast(0.95);
}
[data-theme="dark"] .visit__map iframe { filter: invert(0.9) hue-rotate(180deg) saturate(0.6); }

@media (max-width: 800px) {
  .visit__grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ============================================================
   Footer
   ============================================================ */
.footer {
  padding: 60px 6vw 40px;
  border-top: 1px solid var(--line);
  background: var(--bg);
}
.footer__grid {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 30px;
  flex-wrap: wrap;
}
.footer__mark {
  display: block;
  margin-bottom: 10px;
  color: var(--text);
}
.footer p { color: var(--text-soft); font-size: 14px; }

.footer__slogan {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.05rem !important;
  line-height: 1.55;
  letter-spacing: 0.01em;
  color: var(--text-soft) !important;
  max-width: 340px;
}
.footer__slogan em {
  color: var(--accent-deep);
  font-style: italic;
  font-weight: 500;
}
.footer__credits {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: right;
  font-size: 13px;
  color: var(--muted);
}

/* ============================================================
   Placeholders (decorative SVG-style backgrounds)
   ============================================================ */
.placeholder {
  width: 100%; height: 100%;
  background: var(--surface);
  display: grid;
  place-items: center;
  color: var(--accent);
  position: relative;
  overflow: hidden;
}
.placeholder::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--highlight) 50%, transparent), transparent 50%),
    radial-gradient(circle at 70% 75%, color-mix(in srgb, var(--accent) 35%, transparent), transparent 55%);
  opacity: 0.7;
}
.placeholder svg {
  width: 60%; height: 60%;
  position: relative;
  color: var(--accent-deep);
  opacity: 0.55;
}
.placeholder--portrait { background: linear-gradient(160deg, var(--surface), var(--bg-elev)); }

.placeholder--cup::after,
.placeholder--beans::after,
.placeholder--window::after,
.placeholder--pour::after,
.placeholder--croissant::after {
  position: absolute;
  font-family: var(--font-serif);
  font-size: 4rem;
  color: var(--accent-deep);
  opacity: 0.35;
}
.placeholder--cup::after      { content: "☕"; }
.placeholder--beans::after    { content: "❀"; }
.placeholder--window::after   { content: "▢"; font-size: 5rem; }
.placeholder--pour::after     { content: "≋"; font-size: 5rem; }
.placeholder--croissant::after{ content: "✦"; }
