
:root {
  --gold: #d6b36a;
  --malt: #c8953d;
  --deep: #3a281c;
  --barrel: #60452f;
  --cream: #f3e7cf;
  --paper: #fff8ec;
  --darkgold: #9d7435;
  --ink: #1d1713;
  --muted: #6e5844;
  --line: rgba(58, 40, 28, 0.16);
  --serif: "Cormorant Garamond", "Noto Serif TC", "Noto Serif SC", "Palatino Linotype", Palatino, "Songti SC", "PMingLiU", serif;
  --sans: "PingFang SC", "Hiragino Sans", "Noto Sans TC", "Microsoft YaHei", "Segoe UI", sans-serif;
  --header: 108px;
  --tab: calc(54px + env(safe-area-inset-bottom));
  --shell: 480px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  min-height: 100svh;
  background: #2a1a22;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  position: relative;
  z-index: 0;
  isolation: isolate;
}
body::before,
body::after {
  content: "";
  position: fixed;
  inset: -18%;
  z-index: -1;
  pointer-events: none;
}
body::before {
  background:
    radial-gradient(circle at 12% 18%, rgba(226, 122, 78, 0.55), transparent 34%),
    radial-gradient(circle at 86% 10%, rgba(214, 168, 62, 0.5), transparent 32%),
    radial-gradient(circle at 72% 78%, rgba(92, 122, 78, 0.38), transparent 30%),
    radial-gradient(circle at 24% 86%, rgba(176, 78, 92, 0.32), transparent 28%);
  animation: lamp-drift 16s ease-in-out infinite alternate;
}
body::after {
  background:
    radial-gradient(circle at 12% 70%, rgba(243, 231, 207, 0.16) 0 7px, transparent 8px),
    radial-gradient(circle at 28% 84%, rgba(214, 179, 106, 0.2) 0 4px, transparent 5px),
    radial-gradient(circle at 74% 76%, rgba(243, 231, 207, 0.14) 0 6px, transparent 7px),
    radial-gradient(circle at 88% 62%, rgba(200, 149, 61, 0.18) 0 3px, transparent 4px);
  animation: foam-rise 18s ease-in-out infinite;
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.2; margin: 0; }
p { margin: 0; }

.app-shell {
  width: min(var(--shell), 100%);
  margin: 0 auto;
  min-height: 100svh;
  background-color: #f6e2c4;
  background-image:
    radial-gradient(ellipse 85% 48% at 0% 0%, rgba(232, 126, 74, 0.72), transparent 62%),
    radial-gradient(ellipse 75% 42% at 100% 6%, rgba(214, 176, 52, 0.78), transparent 58%),
    radial-gradient(ellipse 70% 40% at 8% 72%, rgba(122, 150, 96, 0.42), transparent 56%),
    radial-gradient(ellipse 68% 38% at 96% 88%, rgba(196, 92, 108, 0.34), transparent 54%),
    linear-gradient(168deg, #fff3d8 0%, #f6d7a8 38%, #f3c98a 68%, #e7d3b0 100%);
  background-size: 170% 170%, 160% 160%, 150% 150%, 150% 150%, auto;
  animation: living-bg 8s ease-in-out infinite alternate;
  position: relative;
  padding-bottom: var(--tab);
  box-shadow: 0 0 0 1px rgba(196, 122, 58, 0.22);
}
.app-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 10%, rgba(255, 186, 92, 0.55), transparent 26%),
    radial-gradient(circle at 90% 22%, rgba(214, 96, 72, 0.28), transparent 24%),
    radial-gradient(circle at 64% 58%, rgba(154, 176, 98, 0.28), transparent 22%),
    radial-gradient(circle at 20% 84%, rgba(214, 154, 72, 0.34), transparent 24%);
  animation: page-glow 12s ease-in-out infinite alternate;
}
.app-shell > * { position: relative; z-index: 1; }
body.tone-stout .app-shell {
  background-color: #2a1814;
  background-image:
    radial-gradient(ellipse 80% 48% at 0% 0%, rgba(196, 92, 62, 0.55), transparent 58%),
    radial-gradient(ellipse 70% 42% at 100% 12%, rgba(168, 112, 48, 0.5), transparent 52%),
    radial-gradient(ellipse 60% 36% at 30% 100%, rgba(92, 64, 48, 0.65), transparent 50%),
    linear-gradient(180deg, #3a221c, #241410 55%, #1a100e);
  animation: living-bg 10s ease-in-out infinite alternate;
  color: var(--cream);
}
body.tone-stout::before {
  background:
    radial-gradient(circle at 20% 18%, rgba(200, 149, 61, 0.28), transparent 34%),
    radial-gradient(circle at 78% 30%, rgba(96, 69, 47, 0.45), transparent 36%),
    radial-gradient(circle at 40% 80%, rgba(214, 179, 106, 0.14), transparent 30%);
}
body.tone-stout { --muted: #d9c7aa; --line: rgba(243, 231, 207, 0.16); --paper: #3a281c; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: calc(8px + env(safe-area-inset-top)) 16px 10px;
  background: rgba(29, 23, 19, 0.96);
  color: var(--cream);
}
.topbar-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  min-height: 44px;
}
.brand img { width: 28px; height: 28px; border-radius: 7px; }
.brand-name {
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: 0.04em;
}
.lang-btn, .icon-btn, .btn, .menu-row, .choice, .star, .tab {
  min-height: 44px;
}
.lang-btn {
  border: 1px solid rgba(214, 179, 106, 0.45);
  background: transparent;
  color: var(--gold);
  border-radius: 999px;
  padding: 0 12px;
  letter-spacing: 0.04em;
}
.search-form { margin-top: 8px; }
.search-form input, .field input, .field textarea, .field select {
  width: 100%;
  min-height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(214, 179, 106, 0.35);
  background: rgba(243, 231, 207, 0.12);
  color: var(--cream);
  padding: 10px 12px;
  font-size: 16px;
}
.field input, .field textarea, .field select {
  background: var(--paper);
  color: var(--ink);
  border-color: var(--line);
}
.search-form input::placeholder { color: rgba(243, 231, 207, 0.62); }
body.is-home .topbar {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: min(var(--shell), 100%);
  background: linear-gradient(to bottom, rgba(29, 23, 19, 0.78), rgba(29, 23, 19, 0));
}

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  color: var(--cream);
  overflow: hidden;
  background: #1d1713;
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}
.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(20, 14, 10, 0.94) 0%, rgba(29, 23, 19, 0.62) 42%, rgba(29, 23, 19, 0.12) 68%, rgba(29, 23, 19, 0.38) 100%);
}
.hero::after,
.page-hero::after {
  content: "";
  position: absolute;
  inset: -10% -30%;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(105deg, transparent 36%, rgba(255, 226, 170, 0.2) 48%, transparent 60%);
  animation: warm-sheen 11s ease-in-out infinite;
}
.hero-copy {
  position: relative;
  z-index: 2;
  width: 100%;
  text-align: center;
  padding: 108px 22px calc(16px + var(--tab));
}
.kicker {
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--gold);
  margin-bottom: 10px;
}
.hero h1 {
  font-size: 34px;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.poem {
  margin: 16px auto 0;
  max-width: 18em;
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  line-height: 1.7;
  color: rgba(243, 231, 207, 0.9);
  white-space: pre-line;
}
.promise {
  margin: 14px auto 0;
  max-width: 16em;
  font-size: 15px;
  color: rgba(243, 231, 207, 0.84);
}
.hero-actions {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border-radius: 999px;
  padding: 0 18px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.18s ease, opacity 0.18s ease;
}
.btn:active { transform: scale(0.985); }
.btn.solid {
  background: linear-gradient(180deg, #e0c27a, #c8953d);
  color: #1d1713;
  font-family: var(--serif);
  font-size: 20px;
}
.btn.ghost {
  background: transparent;
  color: var(--cream);
  border-color: rgba(243, 231, 207, 0.55);
  font-family: var(--serif);
  font-size: 18px;
}
.btn.text {
  background: transparent;
  color: var(--gold);
  font-size: 15px;
}
.btn.ink {
  background: var(--deep);
  color: var(--cream);
  font-family: var(--serif);
  font-size: 18px;
}
.btn.line {
  background: transparent;
  border-color: rgba(58, 40, 28, 0.3);
  color: var(--ink);
}
body.tone-stout .btn.line { color: var(--cream); border-color: rgba(243, 231, 207, 0.3); }
.btn.small { width: auto; min-height: 44px; padding: 0 14px; font-size: 15px; }
.btn[disabled] { opacity: 0.45; }

.section { padding: 28px 16px 8px; }
.section-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.section-h h2 { font-size: 30px; }
.idx {
  font-family: var(--serif);
  color: var(--darkgold);
  letter-spacing: 0.14em;
  font-size: 13px;
}
.rule {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--malt), transparent);
  border: 0;
  margin: 8px 0 14px;
}
.lede { color: var(--muted); font-size: 15px; margin-bottom: 12px; }

.menu { display: grid; gap: 10px; }
.menu-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  text-align: left;
  text-decoration: none;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 12px;
  box-shadow: 0 8px 20px rgba(29, 23, 19, 0.04);
}
.menu-no {
  font-family: var(--serif);
  color: var(--darkgold);
  font-size: 18px;
}
.menu-row strong { display: block; font-family: var(--serif); font-size: 20px; font-weight: 600; }
.menu-row span { color: var(--muted); font-size: 13px; }
.chev { color: var(--malt); }

.style-grid, .pair-grid, .world-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.style-card, .beer-card, .post, .paper, .country-card, .subcard {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 10px 24px rgba(29, 23, 19, 0.05);
}
.style-card { display: flex; flex-direction: column; min-height: 220px; }
.style-card .band, .beer-card .band {
  height: 156px;
  background: #3a281c center/cover no-repeat;
  position: relative;
}
.style-card .band::after, .photo-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(29, 23, 19, 0.35), transparent 55%);
}
.style-card .pad, .beer-card .pad, .subcard .pad, .post .pad { padding: 10px 12px 12px; }
.style-card h3, .beer-card h3, .subcard h3 { font-size: 22px; }
.tiny { color: var(--muted); font-size: 13px; line-height: 1.45; }

.hscroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 6px;
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
}
.hscroll::-webkit-scrollbar { display: none; }
.beer-card { flex: 0 0 86%; scroll-snap-align: start; }
.beer-card .band { height: 248px; }

.story-feature {
  display: block;
  padding: 18px 16px;
  background: #2a1d16;
  color: var(--cream);
  border-radius: 18px;
  text-decoration: none;
}
.story-feature p {
  font-family: var(--serif);
  font-size: 26px;
  line-height: 1.35;
  margin-top: 8px;
}
.list { display: grid; gap: 8px; margin-top: 10px; }
.list a, .text-link {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  min-height: 44px;
  align-items: center;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 18px;
}

.atlas-wrap {
  background: #2a1d16;
  border-radius: 18px;
  padding: 8px;
  margin-bottom: 12px;
}
.atlas { width: 100%; height: auto; display: block; }
.atlas a circle.hit { fill: transparent; }
.atlas text { font-size: 8px; fill: #f3e7cf; font-family: var(--sans); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip, .tag {
  border: 1px solid var(--line);
  background: transparent;
  color: inherit;
  border-radius: 999px;
  min-height: 36px;
  padding: 0 12px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.chip.on, .tag.on { background: var(--deep); color: var(--cream); border-color: var(--deep); }
body.tone-stout .chip.on { background: var(--gold); color: var(--ink); }

.panel {
  background: #2a1d16;
  color: var(--cream);
  border-radius: 18px;
  padding: 18px 16px;
}
.panel h2, .panel h3 { color: var(--cream); }
.seal {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  border: 1px dashed var(--gold);
  border-radius: 99px;
  color: var(--gold);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.page-hero {
  position: relative;
  min-height: 460px;
  display: flex;
  align-items: flex-end;
  color: var(--cream);
  background: #1d1713;
  margin: 0 0 8px;
  overflow: hidden;
}
.page-hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}
.page-hero .shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(20, 14, 10, 0.78) 0%, rgba(20, 14, 10, 0.08) 46%, rgba(20, 14, 10, 0.12) 100%);
}
.subcard-photo {
  width: 100%;
  height: 210px;
  object-fit: cover;
  display: block;
  background: #3a281c;
}
.page-hero .copy { position: relative; z-index: 2; padding: 22px 18px 18px; width: 100%; text-align: center; }
.page-hero h1 { font-size: 42px; }
.page-hero .sub { font-family: var(--serif); font-size: 22px; margin-top: 4px; }

.subcard { margin: 0 16px 12px; }
.subcard .pad h3 { font-size: 26px; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; margin-top: 10px; }
.facts div { font-size: 14px; }
.facts b { display: block; font-size: 12px; letter-spacing: 0.06em; color: var(--darkgold); font-weight: 600; }
.meters { display: grid; gap: 6px; margin-top: 10px; }
.meter { display: grid; grid-template-columns: 72px 1fr; gap: 8px; align-items: center; font-size: 13px; }
.dots { display: flex; gap: 4px; }
.dots i {
  width: 9px; height: 9px; border-radius: 50%;
  background: rgba(157, 116, 53, 0.25);
  display: block;
}
.dots i.on { background: var(--malt); }
.note {
  margin: 8px 16px 16px;
  color: var(--muted);
  font-size: 13px;
}

.slider-block, .block { margin: 8px 16px 16px; padding: 14px; background: var(--paper); border-radius: 16px; border: 1px solid var(--line); }
.slider-block input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 99px;
  background: linear-gradient(90deg, #efe2c8, #c8953d);
  margin: 16px 0;
}
.slider-block input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--deep);
  border: 2px solid var(--gold);
}
.ends { display: flex; justify-content: space-between; color: var(--muted); font-size: 13px; }

.letter {
  margin: 18px 16px;
  background: #f7f1e4;
  color: var(--ink);
  border-radius: 6px 18px 18px 6px;
  padding: 26px 18px 20px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(214, 179, 106, 0.4);
}
body:not(.tone-stout) .ritual-stage { background: #1d1713; margin: -8px 0 0; padding: 12px 0 24px; color: var(--cream); }
.letter p { font-family: var(--serif); font-size: 20px; line-height: 1.55; white-space: pre-line; }
.disclaimer { font-family: var(--sans); font-size: 12px; color: var(--muted); margin-top: 14px; }

.tabbar {
  position: fixed;
  z-index: 30;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: min(var(--shell), 100%);
  height: var(--tab);
  padding-bottom: env(safe-area-inset-bottom);
  background: #1d1713;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-top: 1px solid rgba(214, 179, 106, 0.35);
}
.tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  text-decoration: none;
  color: #cdb89a;
  font-size: 10px;
  letter-spacing: 0.04em;
}
.tab svg { width: 22px; height: 22px; }
.tab.on { color: var(--gold); }

.ritual-chip {
  text-decoration: none;
  position: fixed;
  z-index: 34;
  right: max(12px, calc((100vw - min(var(--shell), 100vw)) / 2 + 12px));
  bottom: calc(62px + env(safe-area-inset-bottom));
  max-width: calc(min(var(--shell), 100vw) - 24px);
  border: 0;
  border-radius: 999px;
  background: #1d1713;
  color: var(--gold);
  min-height: 36px;
  padding: 0 12px;
  font-size: 12px;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}
.ritual-chip.ready { background: var(--malt); color: #1d1713; }

.overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  isolation: isolate;
}
.backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 14, 10, 0.62);
  z-index: 0;
}
.sheet, .agegate, .modal {
  position: absolute;
  z-index: 1;
  left: 50%;
  transform: translateX(-50%);
  width: min(var(--shell), 100%);
  background: var(--cream);
  color: var(--ink);
}
.sheet {
  bottom: 0;
  max-height: min(92svh, 820px);
  overflow: auto;
  border-radius: 18px 18px 0 0;
  padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
  animation: sheetIn 0.28s ease;
}
@keyframes sheetIn { from { transform: translateX(-50%) translateY(16px); opacity: 0.6; } to { transform: translateX(-50%); opacity: 1; } }
html[dir="rtl"] .hero-copy,
html[dir="rtl"] .page-hero .copy { text-align: center; }
html[dir="rtl"] .tabbar { direction: rtl; }
.agegate, .modal {
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(420px, calc(100% - 28px));
  border-radius: 18px;
  padding: 22px 18px;
  text-align: center;
}
.sheet h2, .agegate h2, .modal h2 { font-size: 32px; text-align: center; }
.sheet .sub, .center { text-align: center; white-space: pre-line; }
.grab {
  width: 42px; height: 4px; border-radius: 4px; background: rgba(58, 40, 28, 0.25);
  margin: 4px auto 10px;
}
.ritual-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0; }
.ritual-card {
  padding: 0;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 14px;
  overflow: hidden;
  text-align: left;
  min-height: 44px;
}
.ritual-card img { height: 156px; width: 100%; object-fit: cover; background: #3a281c; }
.ritual-card div { padding: 8px 10px 10px; }
.ritual-card strong { display: block; font-family: var(--serif); font-size: 18px; }
.choice {
  width: 100%;
  text-align: left;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--paper);
  margin-top: 8px;
  padding: 0 14px;
  font-family: var(--serif);
  font-size: 18px;
}
.choice.on { border-color: var(--malt); background: #f3e2c0; }
.agegate p, .modal p { margin: 10px 0 16px; white-space: pre-line; }
.stack { display: grid; gap: 8px; }

.stars { display: flex; gap: 4px; }
.star {
  width: 44px;
  border: 0;
  background: transparent;
  font-size: 22px;
  color: rgba(157, 116, 53, 0.35);
}
.star.on { color: var(--malt); }
.post img { width: 100%; height: 280px; object-fit: cover; border-radius: 12px; margin-top: 8px; }
.post-top, .row-between { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.avatar {
  width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center;
  background: #3a281c; color: var(--gold);
  font-family: var(--serif);
}
.who { display: flex; gap: 8px; align-items: center; }
.actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.actions button, .actions a {
  min-height: 36px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  padding: 0 10px;
  text-decoration: none;
  color: inherit;
  font-size: 13px;
}
.comment { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); font-size: 14px; }
.check-card {
  margin-top: 12px;
  border: 1px solid var(--malt);
  border-radius: 16px;
  overflow: hidden;
  background: #2a1d16;
  color: var(--cream);
}
.check-card img { width: 100%; max-height: 320px; object-fit: cover; }
.check-card .pad { padding: 12px; }

.q-card { margin: 12px 16px; padding: 16px; background: var(--paper); border-radius: 16px; border: 1px solid var(--line); }
.progress { height: 3px; background: rgba(157, 116, 53, 0.25); border-radius: 99px; margin: 10px 16px; }
.progress span { display: block; height: 100%; background: var(--malt); }

.dna { display: grid; gap: 8px; }
.bar { height: 8px; background: rgba(157, 116, 53, 0.2); border-radius: 99px; overflow: hidden; }
.bar span { display: block; height: 100%; background: linear-gradient(90deg, #9d7435, #d6b36a); }

.toast {
  position: fixed;
  z-index: 80;
  left: 50%;
  bottom: calc(76px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  background: var(--deep);
  color: var(--cream);
  border-radius: 999px;
  padding: 10px 14px;
  font-size: 14px;
  max-width: calc(min(var(--shell), 100%) - 32px);
}

.colophon { padding: 18px 16px 28px; color: var(--muted); font-size: 12px; text-align: center; }
.hidden { display: none !important; }
html.lock-age .app-shell,
html.lock-age .tabbar,
html.lock-age .ritual-chip { visibility: hidden; }
.subcard.is-dim { opacity: 0.38; }
.mood-copy { margin-top: 10px; font-family: var(--serif); font-size: 20px; }
button, a, input, select, textarea { touch-action: manipulation; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

@media (max-width: 359px) {
  .hero h1 { font-size: 34px; }
  .style-grid, .ritual-grid, .pair-grid { grid-template-columns: 1fr; }
}
@media (min-width: 390px) {
  .hero h1 { font-size: 38px; }
}
@media (max-height: 760px) {
  .hero h1 { font-size: 32px; }
  .poem { font-size: 14px; line-height: 1.55; margin-top: 10px; }
  .promise { margin-top: 8px; font-size: 14px; }
  .hero-actions { margin-top: 12px; gap: 8px; }
  .hero-copy { padding-top: 96px; }
}
@media (min-width: 430px) {
  .section { padding-left: 18px; padding-right: 18px; }
}
@keyframes living-bg {
  0% { background-position: 0% 0%, 100% 0%, 0% 100%, 100% 100%, 0 0; }
  100% { background-position: 80% 40%, 10% 60%, 70% 20%, 20% 30%, 0 0; }
}
@keyframes lamp-drift {
  from { transform: translate3d(-2.5%, -1.5%, 0) scale(1); }
  to { transform: translate3d(3%, 2.5%, 0) scale(1.06); }
}
@keyframes page-glow {
  from { transform: translate3d(0, 0, 0) scale(1); opacity: 0.72; }
  to { transform: translate3d(-2%, 3%, 0) scale(1.05); opacity: 1; }
}
@keyframes foam-rise {
  0% { transform: translate3d(0, 6%, 0); opacity: 0.25; }
  50% { opacity: 0.55; }
  100% { transform: translate3d(1.5%, -12%, 0); opacity: 0.2; }
}
@keyframes warm-sheen {
  0%, 100% { transform: translate3d(-18%, 0, 0); opacity: 0.25; }
  50% { transform: translate3d(18%, 0, 0); opacity: 0.7; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
:focus-visible {
  outline: 2px solid var(--malt);
  outline-offset: 2px;
}

