/* ==========================================================================
   Wenyue (問月) · Matte Borderless Editorial Design System
   Zero metallic frames, zero neon/gold rims. Depth through tonal surfaces,
   soft ambient shadow, mineral watercolor plates, and quiet print typography.
   ========================================================================== */

:root {
  color-scheme: dark;
  /* Matte Forest Charcoal & Mineral Paper Surfaces */
  --bg: #151613;
  --bg-deep: #11120f;
  --bg-elev: #1c1e1a;
  --surface: rgba(31, 33, 28, 0.56);
  --surface-strong: rgba(41, 44, 38, 0.82);

  /* Ultra-Quiet Neutral Print Hairlines (used only for page rules, never card cages) */
  --hairline: rgba(236, 230, 218, 0.09);
  --hairline-mid: rgba(236, 230, 218, 0.18);
  --hairline-soft: rgba(236, 230, 218, 0.3);

  /* Typography & Matte Earth Pigment Accent (text only, never metallic borders) */
  --ivory: #ece6da;
  --ivory-soft: #d5cfc2;
  --muted: #98948a;
  --ochre: #bfa37a;
  --ink-dark: #151410;

  /* Watercolor Mineral Washes */
  --mist-blue: rgba(132, 152, 178, 0.13);
  --mist-lilac: rgba(169, 155, 182, 0.12);
  --mist-rose: rgba(196, 160, 154, 0.11);
  --warn: #cbb08c;
  --err: #d18278;

  /* Editorial Type Stacks */
  --font-serif: "Cormorant Garamond", "Noto Serif TC", "Songti TC", "STSong", Baskerville, Georgia, serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "PingFang TC", "Noto Sans TC", "Segoe UI", system-ui, sans-serif;

  --radius-sm: 3px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --ease-quiet: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--bg); }

body {
  margin: 0;
  min-height: 100dvh;
  position: relative;
  overflow-x: hidden;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 64% 46% at 74% 8%, rgba(191, 163, 122, 0.06), transparent 66%),
    radial-gradient(ellipse 58% 48% at 14% 22%, rgba(166, 152, 184, 0.09), transparent 68%),
    radial-gradient(ellipse 62% 52% at 86% 62%, rgba(128, 154, 182, 0.09), transparent 70%),
    radial-gradient(ellipse 52% 44% at 24% 84%, rgba(196, 158, 152, 0.07), transparent 70%),
    linear-gradient(180deg, #171815 0%, #141512 52%, #181916 100%);
  color: var(--ivory);
  font: 400 15.5px/1.85 var(--font-sans);
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Tactile Matte Cotton Paper Grain Overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 90;
  opacity: 0.038;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
}

/* Whisper-soft Ambient Light Drift */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(520px circle at var(--mx, 68%) var(--my, 18%), rgba(236, 230, 218, 0.028), transparent 65%);
  transition: opacity 0.6s ease;
}

a {
  color: var(--ochre);
  text-decoration: none;
  transition: color 0.28s var(--ease-quiet), border-color 0.28s var(--ease-quiet);
}
a:hover { color: var(--ivory); }

.wrap {
  position: relative;
  z-index: 1;
  max-width: 1040px;
  margin: 0 auto;
  padding: 24px 28px 96px;
}

/* ==========================================================================
   Navigation — Quiet Print Masthead
   ========================================================================== */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 8px 0 22px;
  border-bottom: 1px solid var(--hairline);
  flex-wrap: wrap;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font: 400 22px/1 var(--font-serif);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ivory);
}
.brand svg {
  width: 22px;
  height: 22px;
  stroke: var(--ivory-soft);
  fill: none;
  stroke-width: 1.15;
  opacity: 0.86;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 12.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  flex-wrap: wrap;
}
.nav-links a {
  color: var(--muted);
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--ivory);
  border-bottom-color: var(--hairline-soft);
}
.lang-pill {
  padding: 5px 12px !important;
  border: 0 !important;
  border-radius: var(--radius-sm);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--ivory-soft) !important;
  background: rgba(236, 230, 218, 0.06);
}
.lang-pill:hover {
  background: rgba(236, 230, 218, 0.13);
  color: var(--ivory) !important;
}

/* ==========================================================================
   Eyebrow / Editorial Host Signifier
   ========================================================================== */
.witch-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  font-size: 11.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.witch-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 0;
  background: var(--bg-elev);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.witch-avatar img { width: 100%; height: 100%; object-fit: cover; object-position: center top; display: block; }
.witch-avatar svg { width: 20px; height: 20px; stroke: var(--ivory-soft); fill: none; stroke-width: 1.2; }
.witch-badge strong { color: var(--ivory); font-weight: 500; }

.tag,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 10.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ochre);
  margin-bottom: 14px;
}
.tag::before {
  content: "";
  width: 14px;
  height: 1px;
  background: rgba(236, 230, 218, 0.24);
}

/* ==========================================================================
   Hero — Asymmetric Editorial Spread + Borderless Matte Portrait
   ========================================================================== */
.hero {
  padding: 64px 0 36px;
  text-align: center;
}
.hero h1 {
  font: 300 clamp(30px, 4.6vw, 52px)/1.22 var(--font-serif);
  letter-spacing: 0.03em;
  margin: 0 auto 18px;
  max-width: 740px;
  color: var(--ivory);
}
.hero p.lead {
  margin: 0 auto;
  max-width: 560px;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.9;
}

.hero-split {
  display: grid;
  grid-template-columns: 1.16fr 0.84fr;
  gap: 56px;
  align-items: center;
  padding: 58px 0 42px;
  text-align: left;
}
.hero-split h1 {
  font: 300 clamp(32px, 4.4vw, 52px)/1.2 var(--font-serif);
  letter-spacing: 0.025em;
  margin: 0 0 22px;
  color: var(--ivory);
}
.hero-split p.lead {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.92;
  max-width: 470px;
}
.hero-split .prompt-chips {
  justify-content: flex-start;
  margin: 8px 0 0;
}

/* Pure Borderless Editorial Portrait (Zero Concentric Metal Wireframes) */
.witch-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0;
}
.witch-portal {
  position: relative;
  width: 100%;
  max-width: 318px;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}
.witch-portal::before,
.witch-portal::after {
  content: none;
  display: none;
}
.witch-arch {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  border: 0;
  background: var(--bg-elev);
  box-shadow: 0 30px 68px rgba(0, 0, 0, 0.56);
}
.witch-arch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  filter: contrast(0.97) saturate(0.9);
  transition: transform 0.9s var(--ease-quiet);
}
.witch-portal:hover .witch-arch img { transform: scale(1.02); }
.witch-arch::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 92% 92% at 50% 46%, transparent 58%, rgba(21, 22, 19, 0.42) 100%),
    linear-gradient(180deg, rgba(21, 22, 19, 0.08) 0%, transparent 38%, rgba(21, 22, 19, 0.86) 100%);
}
.witch-caption {
  position: absolute;
  bottom: 16px;
  left: 16px;
  right: 16px;
  z-index: 2;
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(236, 230, 218, 0.76);
  text-align: center;
}

/* ==========================================================================
   Zero-Friction Mirror Draw ("Tonight's Quiet Mirror" above the form)
   ========================================================================== */
.mirror-zone {
  margin: 12px 0 34px;
  text-align: center;
}
.mirror-invite {
  margin: 0 auto 14px;
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--muted);
}
.mirror-reveal {
  max-width: 780px;
  margin: 18px auto 8px;
  padding: 32px 34px;
  display: grid;
  grid-template-columns: 186px 1fr;
  gap: 36px;
  align-items: center;
  text-align: left;
  border: 0;
  border-radius: var(--radius-md);
  background:
    radial-gradient(ellipse 48% 80% at 15% 50%, var(--mist-lilac), transparent 72%),
    linear-gradient(155deg, rgba(31, 33, 28, 0.9), rgba(21, 22, 19, 0.96));
  box-shadow: 0 28px 64px rgba(0, 0, 0, 0.52);
  animation: mirrorFade 0.55s var(--ease-quiet);
}
.mirror-reveal[hidden] { display: none; }
.mirror-plate { max-width: 186px; }
.mirror-copy h3 {
  margin: 0 0 12px;
  font: 300 28px/1.25 var(--font-serif);
  color: var(--ivory);
  letter-spacing: 0.03em;
}
.mirror-copy p {
  margin: 0 0 22px;
  font: 300 17px/1.88 var(--font-serif);
  color: var(--ivory-soft);
}
.mirror-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
@keyframes mirrorFade {
  0% { opacity: 0; transform: translateY(10px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Fanned Borderless Tarot Deck (True Edge-to-Edge Matte Prints)
   ========================================================================== */
.fan-stage {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 22px auto 34px;
  min-height: 214px;
  position: relative;
}
.fan-card {
  width: 126px;
  height: 192px;
  border-radius: 8px;
  padding: 12px 10px;
  border: 0;
  background-color: #1f211c;
  background-size: cover;
  background-position: center;
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.56);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  margin: 0 -18px;
  color: var(--ivory);
  transition: transform 0.55s var(--ease-quiet), box-shadow 0.55s var(--ease-quiet);
}
.fan-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(21, 22, 19, 0.16) 0%, rgba(21, 22, 19, 0.04) 55%, rgba(21, 22, 19, 0.42) 100%);
  pointer-events: none;
}
.fan-card > * { position: relative; z-index: 1; }
.fan-card.has-art svg { opacity: 0; }
.fan-card:nth-child(1) { transform: rotate(-9deg) translateY(12px); z-index: 1; }
.fan-card:nth-child(2) { transform: translateY(-4px); z-index: 3; }
.fan-card:nth-child(3) { transform: rotate(9deg) translateY(12px); z-index: 2; }
.fan-card:hover {
  transform: translateY(-18px) scale(1.03) !important;
  z-index: 5;
  box-shadow: 0 32px 62px rgba(0, 0, 0, 0.72);
}
.fan-card svg { width: 64px; height: 92px; stroke: var(--ivory-soft); fill: none; stroke-width: 1; opacity: 0.65; }
.fan-card .mark {
  font: 400 10px/1 var(--font-serif);
  letter-spacing: 0.26em;
  color: rgba(236, 230, 218, 0.78);
}

/* ==========================================================================
   Buttons & Editorial Prompt Chips — Matte, Quiet, Zero Gold Rims
   ========================================================================== */
.cta-row {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 28px;
  flex-wrap: wrap;
}
.btn,
button {
  font: 400 13px/1.2 var(--font-sans);
  letter-spacing: 0.1em;
  color: var(--ivory);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  background: rgba(236, 230, 218, 0.07);
  border-radius: var(--radius-sm);
  padding: 12px 24px;
  transition: background 0.32s var(--ease-quiet), color 0.32s var(--ease-quiet), transform 0.25s var(--ease-quiet);
}
.btn:hover,
button:hover:not(:disabled) {
  background: rgba(236, 230, 218, 0.14);
  color: var(--ivory);
}
button:disabled { opacity: 0.42; cursor: default; }

.btn.primary,
button.primary {
  background: var(--ivory);
  color: var(--ink-dark);
  font-weight: 500;
}
.btn.primary:hover,
button.primary:hover:not(:disabled) {
  background: #dad2c2;
  color: var(--ink-dark);
}

.prompt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px auto 12px;
  justify-content: center;
  max-width: 720px;
}
.prompt-chips button {
  font-size: 13px;
  letter-spacing: 0.02em;
  padding: 9px 15px;
  color: var(--ivory-soft);
  border-radius: var(--radius-sm);
  background: rgba(236, 230, 218, 0.048);
  border: 0;
}
.prompt-chips button:hover {
  background: rgba(236, 230, 218, 0.11);
  color: var(--ivory);
}

/* ==========================================================================
   Ritual Table — Matte Linen Sanctuary (Tonal Depth, No Frame Box)
   ========================================================================== */
.ritual-table {
  margin: 24px 0 76px;
  padding: 38px 34px;
  border: 0;
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, rgba(28, 30, 26, 0.74) 0%, rgba(20, 22, 18, 0.86) 100%);
  box-shadow: 0 32px 72px rgba(0, 0, 0, 0.42);
}
.controls {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 0 0 22px;
  flex-wrap: wrap;
}
.controls button {
  font-size: 12px;
  letter-spacing: 0.1em;
  padding: 8px 16px;
  border: 0;
  background: rgba(236, 230, 218, 0.04);
  color: var(--muted);
}
.controls button:hover {
  background: rgba(236, 230, 218, 0.09);
  color: var(--ivory-soft);
}
.controls .on {
  background: rgba(236, 230, 218, 0.13);
  color: var(--ivory);
}

/* ==========================================================================
   Sample Reading Showcase — Open Art Book Spread
   ========================================================================== */
.showcase {
  display: grid;
  grid-template-columns: 236px 1fr;
  gap: 44px;
  align-items: center;
  padding: 48px 12px;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  background:
    radial-gradient(ellipse 42% 70% at 16% 50%, var(--mist-blue), transparent 72%),
    radial-gradient(ellipse 44% 70% at 86% 45%, rgba(191, 163, 122, 0.04), transparent 72%);
}
.tarot-plate {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 9px;
  padding: 18px 14px;
  position: relative;
  overflow: hidden;
  border: 0;
  background:
    radial-gradient(circle at 46% 24%, rgba(226, 232, 240, 0.2), transparent 52%),
    radial-gradient(circle at 75% 76%, rgba(196, 160, 154, 0.24), transparent 56%),
    linear-gradient(160deg, #3c4657 0%, #2a2c38 48%, #212320 100%);
  background-size: cover;
  background-position: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  text-align: center;
  box-shadow: 0 26px 56px rgba(0, 0, 0, 0.56);
}
.tarot-plate::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 18, 15, 0.3) 0%, transparent 32%, transparent 62%, rgba(17, 18, 15, 0.78) 100%);
  pointer-events: none;
}
.tarot-plate > * { position: relative; z-index: 1; }
.tarot-plate.has-art svg { opacity: 0; }
.tarot-plate svg { width: 82px; height: 104px; stroke: rgba(236, 230, 218, 0.85); fill: none; stroke-width: 1; }
.tarot-plate .plate-title {
  font: 400 15px/1.35 var(--font-serif);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ivory);
}
.tarot-plate .plate-sub {
  font-size: 9.5px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(236, 230, 218, 0.78);
}
.showcase-quote {
  font: 300 21px/1.8 var(--font-serif);
  color: var(--ivory);
  margin: 12px 0 20px;
}
.showcase-meta {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

/* ==========================================================================
   Editorial Sections & Quiet Columns (No Boxy Frames)
   ========================================================================== */
.section { margin: 84px 0; }
.section-head {
  text-align: left;
  margin-bottom: 34px;
  max-width: 580px;
}
.section h2 {
  font: 300 clamp(24px, 3vw, 34px)/1.28 var(--font-serif);
  margin: 0 0 10px;
  letter-spacing: 0.025em;
  color: var(--ivory);
}
.section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 24px 0;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
  margin: 24px 0;
}

/* Hairline Architectural Pillars for Philosophy/Promises */
.editorial-pillars .panel {
  border: 0;
  border-top: 1px solid var(--hairline-mid);
  border-radius: 0;
  background: transparent;
  padding: 24px 4px 10px;
}
.editorial-pillars .panel:hover {
  background: transparent;
  transform: none;
  border-top-color: var(--hairline-soft);
}

.panel {
  display: block;
  padding: 28px 26px;
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ivory);
  position: relative;
  overflow: hidden;
  transition: background 0.35s var(--ease-quiet), transform 0.35s var(--ease-quiet);
}
a.panel:hover {
  background: var(--surface-strong);
  transform: translateY(-2px);
}
.panel h2,
.panel h3 {
  margin: 0 0 10px;
  font: 400 20px/1.35 var(--font-serif);
  letter-spacing: 0.02em;
  color: var(--ivory);
}
.panel p {
  margin: 0;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.82;
}

/* Whisper-soft Editorial Pricing Ribbon */
.soft-ribbon {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding: 34px 4px;
  border: 0;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  border-radius: 0;
  background: transparent;
}
.soft-ribbon p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  max-width: 620px;
}
.soft-ribbon strong { color: var(--ivory); font-weight: 500; }

/* Card Meanings Page Elements */
.answer-box {
  margin: 26px 0;
  padding: 24px 28px;
  border-left: 1px solid var(--hairline-soft);
  background: rgba(31, 33, 28, 0.52);
  font: 300 20px/1.8 var(--font-serif);
  color: var(--ivory);
}
.faq-item {
  padding: 20px 0;
  border-bottom: 1px solid var(--hairline);
}
.faq-item h3 {
  margin: 0 0 8px;
  font: 400 18px/1.45 var(--font-serif);
  color: var(--ivory);
}
.faq-item p { margin: 0; color: var(--muted); font-size: 14.5px; }

/* ==========================================================================
   Interactive Cards — Borderless Painterly Dreamscape Reveals
   ========================================================================== */
.cards {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  margin: 22px 0 12px;
  min-height: 20px;
  perspective: 1000px;
}
.slot { display: flex; flex-direction: column; align-items: center; }

.card {
  width: 154px;
  height: 232px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 16px 12px;
  border: 0;
  border-radius: 9px;
  position: relative;
  overflow: hidden;
  background-color: #1f211c;
  background-size: cover;
  background-position: center;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.52);
  transition: transform 0.55s var(--ease-quiet), box-shadow 0.45s var(--ease-quiet);
}
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 19, 16, 0.24) 0%, rgba(18, 19, 16, 0.06) 48%, rgba(18, 19, 16, 0.64) 100%);
  pointer-events: none;
}
.card > * { position: relative; z-index: 1; }
.card:hover:not(:disabled) {
  transform: translateY(-7px);
  box-shadow: 0 28px 56px rgba(0, 0, 0, 0.66);
}

/* Flipped Cards: Soft Borderless Mineral Watercolor Washes */
.card.flipped {
  border: 0;
  background-image:
    radial-gradient(circle at 28% 24%, rgba(196, 168, 178, 0.34), transparent 56%),
    radial-gradient(circle at 76% 74%, rgba(132, 152, 178, 0.34), transparent 58%),
    radial-gradient(circle at 50% 48%, rgba(236, 230, 218, 0.14), transparent 50%),
    linear-gradient(162deg, #3c4252 0%, #2a2c33 52%, #222320 100%);
  animation: cardReveal 0.55s var(--ease-quiet);
}
.slot:nth-child(2) .card.flipped {
  background-image:
    radial-gradient(circle at 68% 22%, rgba(191, 163, 122, 0.3), transparent 52%),
    radial-gradient(circle at 30% 78%, rgba(169, 155, 182, 0.34), transparent 58%),
    linear-gradient(155deg, #433c48 0%, #2d2a2d 52%, #1f201c 100%);
}
.slot:nth-child(3) .card.flipped {
  background-image:
    radial-gradient(circle at 36% 26%, rgba(145, 174, 186, 0.34), transparent 54%),
    radial-gradient(circle at 72% 76%, rgba(196, 160, 154, 0.28), transparent 56%),
    linear-gradient(168deg, #36454d 0%, #272d31 54%, #1e201d 100%);
}
/* Elemental Mineral Watercolor Washes for all 78 cards (Fire / Water / Air / Earth / Major) */
.card.flipped:not(.has-front-art)[data-element="fire"] {
  background-image:
    radial-gradient(circle at 32% 24%, rgba(206, 156, 118, 0.36), transparent 56%),
    radial-gradient(circle at 74% 76%, rgba(176, 126, 114, 0.28), transparent 58%),
    linear-gradient(160deg, #43342c 0%, #2c2521 54%, #1f1d1a 100%);
}
.card.flipped:not(.has-front-art)[data-element="water"] {
  background-image:
    radial-gradient(circle at 28% 26%, rgba(132, 164, 186, 0.38), transparent 56%),
    radial-gradient(circle at 76% 74%, rgba(169, 155, 186, 0.3), transparent 58%),
    linear-gradient(162deg, #2d3d4a 0%, #242b33 54%, #1c1f21 100%);
}
.card.flipped:not(.has-front-art)[data-element="air"] {
  background-image:
    radial-gradient(circle at 66% 24%, rgba(188, 196, 206, 0.3), transparent 54%),
    radial-gradient(circle at 28% 76%, rgba(138, 152, 172, 0.3), transparent 58%),
    linear-gradient(164deg, #373d47 0%, #262930 54%, #1d1f20 100%);
}
.card.flipped:not(.has-front-art)[data-element="earth"] {
  background-image:
    radial-gradient(circle at 34% 28%, rgba(168, 174, 146, 0.32), transparent 56%),
    radial-gradient(circle at 72% 74%, rgba(186, 162, 128, 0.28), transparent 58%),
    linear-gradient(160deg, #353a30 0%, #262922 54%, #1c1e1a 100%);
}
.card.flipped:not(.has-front-art)[data-arcana="major"] {
  background-image:
    radial-gradient(circle at 50% 24%, rgba(202, 182, 148, 0.32), transparent 52%),
    radial-gradient(circle at 30% 76%, rgba(154, 142, 178, 0.34), transparent 58%),
    linear-gradient(162deg, #3a3446 0%, #26242d 54%, #1c1c1e 100%);
}
@keyframes cardReveal {
  0% { opacity: 0.5; transform: rotateY(-18deg) scale(0.96); }
  100% { opacity: 1; transform: rotateY(0) scale(1); }
}

.card.has-back-art .art svg,
.card.has-front-art .art svg { opacity: 0; }
.card.has-front-art {
  background-size: cover;
  background-position: center;
}
.card.has-front-art .name {
  text-shadow: 0 2px 14px rgba(15, 16, 13, 0.85);
}

/* ==========================================================================
   Moon Phase Divider & Borderless Watercolor Tarot Art Gallery
   ========================================================================== */
.moon-phases {
  display: flex;
  justify-content: center;
  margin: 0 auto 26px;
  color: var(--ivory-soft);
  opacity: 0.42;
}
.moon-phases svg { width: 176px; height: 15px; display: block; }

.tarot-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 38px 28px;
  margin: 34px 0 24px;
}
.tarot-gallery-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  color: var(--ivory);
  text-decoration: none;
}
.tarot-art-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 9px;
  overflow: hidden;
  background-color: #22252a;
  background-size: cover;
  background-position: center;
  border: 0;
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.54);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 18px 14px;
  transition: transform 0.6s var(--ease-quiet), box-shadow 0.6s var(--ease-quiet);
}
.tarot-art-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16, 17, 14, 0.22) 0%, transparent 28%, transparent 66%, rgba(16, 17, 14, 0.72) 100%);
  pointer-events: none;
}
.tarot-art-frame::after {
  content: none;
  display: none;
}
.tarot-roman,
.tarot-en-cap {
  position: relative;
  z-index: 1;
  font: 400 10.5px/1 var(--font-serif);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(244, 240, 232, 0.88);
  text-shadow: 0 1px 10px rgba(14, 15, 12, 0.72);
}
.tarot-en-cap {
  font-size: 11.5px;
  letter-spacing: 0.24em;
}
.tarot-gallery-card:hover .tarot-art-frame {
  transform: translateY(-8px);
  box-shadow: 0 34px 68px rgba(0, 0, 0, 0.7);
}
.tarot-card-meta {
  padding: 2px 4px 0;
}
.tarot-card-meta .tag {
  margin-bottom: 8px;
}
.tarot-card-meta h2,
.tarot-card-meta h3 {
  margin: 0 0 8px;
  font: 400 22px/1.3 var(--font-serif);
  letter-spacing: 0.03em;
  color: var(--ivory);
  transition: color 0.3s ease;
}
.tarot-gallery-card:hover .tarot-card-meta h2,
.tarot-gallery-card:hover .tarot-card-meta h3 {
  color: var(--ochre);
}
.tarot-card-meta p {
  margin: 0;
  font-size: 14px;
  line-height: 1.82;
  color: var(--muted);
}

/* Open Art-Book Spread for Individual Card Pages */
.card-detail-hero {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 48px;
  align-items: center;
  padding: 46px 0 24px;
  text-align: left;
}
.card-detail-hero h1 {
  font: 300 clamp(32px, 4.4vw, 48px)/1.2 var(--font-serif);
  margin: 0 0 18px;
  color: var(--ivory);
}
.card-detail-hero .detail-plate {
  max-width: 270px;
}
.card .word {
  font: 400 9.5px/1.4 var(--font-serif);
  letter-spacing: 0.28em;
  color: rgba(236, 230, 218, 0.72);
}
.card .art svg {
  width: 60px;
  height: 78px;
  stroke: rgba(236, 230, 218, 0.85);
  fill: none;
  stroke-width: 1;
}
.card .name {
  font: 400 15px/1.3 var(--font-serif);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  color: var(--ivory);
}
.card .meta {
  font-size: 9.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(236, 230, 218, 0.78);
}
.card .rev {
  color: var(--ivory-soft);
  border: 0;
  background: rgba(17, 18, 15, 0.55);
  border-radius: 2px;
  padding: 2px 8px;
  font-size: 9.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.pos {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 10px;
}
.card-link {
  font-size: 11px;
  letter-spacing: 0.08em;
  margin-top: 4px;
  color: var(--ochre);
}
.hint {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin: 12px 0 20px;
}
.hint button { font-size: 11.5px; padding: 6px 14px; margin-left: 10px; }

/* ==========================================================================
   Dialogue Thread & Composer — Calm Literary Correspondence
   ========================================================================== */
.thread { display: flex; flex-direction: column; gap: 18px; margin: 24px 0; }
.row {
  padding: 22px 24px;
  border-radius: var(--radius-sm);
  background: rgba(26, 28, 24, 0.76);
  border: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.row.user {
  background: rgba(42, 44, 38, 0.62);
  margin-left: 10%;
}
.row-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.row-head b {
  font: 400 11px/1 var(--font-sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ochre);
}
.row p { margin: 0; line-height: 1.92; color: var(--ivory-soft); }
.feedback {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
  font-size: 12px;
  color: var(--muted);
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.feedback button { font-size: 11.5px; padding: 4px 12px; background: rgba(236, 230, 218, 0.05); }

.compose {
  margin-top: 14px;
  padding: 18px 20px;
  border: 1px solid rgba(236, 230, 218, 0.09);
  border-radius: var(--radius-sm);
  background: rgba(16, 17, 14, 0.78);
  transition: border-color 0.3s ease;
}
.compose:focus-within { border-color: rgba(236, 230, 218, 0.26); }
textarea {
  display: block;
  width: 100%;
  min-height: 82px;
  max-height: 220px;
  resize: vertical;
  background: transparent;
  border: 0;
  outline: none;
  color: var(--ivory);
  font: 400 15.5px/1.8 var(--font-sans);
}
textarea::placeholder { color: rgba(152, 148, 138, 0.75); }
.foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
  font-size: 12px;
  color: var(--muted);
  flex-wrap: wrap;
}

/* Post-Reading Paywall — Quiet Atelier Invitation (No Gold Box) */
.paywall {
  margin: 26px 0;
  padding: 28px;
  border: 0;
  border-radius: var(--radius-sm);
  background: rgba(26, 28, 24, 0.88);
}
.paywall h3 {
  margin: 0 0 8px;
  font: 400 22px/1.35 var(--font-serif);
  color: var(--ivory);
}
.paywall-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}
.sku {
  padding: 22px 18px;
  border: 0;
  border-radius: var(--radius-sm);
  background: rgba(17, 18, 15, 0.78);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
}
.sku.rec {
  background: rgba(236, 230, 218, 0.065);
}
.sku .price {
  font: 300 26px/1.1 var(--font-serif);
  color: var(--ivory);
  margin: 6px 0;
}
.sku strong { font-weight: 500; color: var(--ivory); }
.sku p { margin: 6px 0 0; font-size: 13px; color: var(--muted); }
.err { color: var(--err); font-size: 13px; margin: 10px 0; }
.status { color: var(--muted); font-size: 12.5px; letter-spacing: 0.04em; text-align: center; margin: 8px 0; }

/* Local Topic History Bar & Quiet Beta Wish Wall */
.history-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--hairline);
}
.history-label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-right: 4px;
}
.history-chip {
  font-size: 12px;
  padding: 5px 11px;
  background: rgba(236, 230, 218, 0.045);
  color: var(--ivory-soft);
}
.history-chip.active {
  background: rgba(236, 230, 218, 0.14);
  color: var(--ivory);
}
.history-clear {
  font-size: 11px;
  padding: 4px 10px;
  margin-left: auto;
  color: var(--muted);
  background: transparent;
}
.wish-wrap {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--hairline);
  text-align: center;
}
.wish-toggle {
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--muted);
  background: transparent;
  padding: 6px 12px;
}
.wish-toggle:hover { color: var(--ivory-soft); background: rgba(236, 230, 218, 0.04); }
.wish-panel {
  margin-top: 12px;
  padding: 16px;
  border-radius: var(--radius-sm);
  background: rgba(16, 17, 14, 0.72);
  text-align: left;
}
.wish-input {
  min-height: 64px;
  font-size: 14px;
}
.wish-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--hairline);
  flex-wrap: wrap;
}
.wish-select {
  background: rgba(236, 230, 218, 0.07);
  color: var(--ivory-soft);
  border: 0;
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font: 400 12.5px/1.2 var(--font-sans);
}

/* ==========================================================================
   Footer — Print Colophon
   ========================================================================== */
.site-footer {
  margin-top: 84px;
  padding-top: 28px;
  border-top: 1px solid var(--hairline);
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.9;
}
.site-footer .links {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 11.5px;
}
.site-footer .links a { color: var(--ivory-soft); }
.site-footer .links a:hover { color: var(--ivory); }

/* ==========================================================================
   Motion & Responsive
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  .card, .fan-card, .btn, button, .panel, .witch-arch img { transition: none !important; transform: none !important; animation: none !important; }
}
@media (max-width: 780px) {
  .wrap { padding: 18px 18px 68px; }
  .hero-split { grid-template-columns: 1fr; text-align: center; gap: 28px; padding: 34px 0 24px; }
  .hero-split .witch-stage { order: -1; padding-top: 8px; }
  .witch-portal { max-width: 248px; }
  .hero-split p.lead { margin: 0 auto 20px; }
  .hero-split .prompt-chips { justify-content: center; }
  .showcase { grid-template-columns: 1fr; gap: 24px; padding: 28px 6px; }
  .tarot-plate { max-width: 196px; margin: 0 auto; }
  .grid-3, .paywall-grid, .tarot-gallery { grid-template-columns: 1fr; }
  .tarot-gallery { gap: 36px; }
  .tarot-art-frame { max-width: 280px; margin: 0 auto; }
  .card-detail-hero { grid-template-columns: 1fr; gap: 28px; padding-top: 28px; }
  .card-detail-hero .detail-plate { max-width: 220px; margin: 0 auto; }
  .mirror-reveal { grid-template-columns: 1fr; gap: 22px; padding: 24px 20px; text-align: center; }
  .mirror-plate { max-width: 164px; margin: 0 auto; }
  .mirror-actions { justify-content: center; }
  .fan-card { width: 100px; height: 152px; margin: 0 -12px; }
  .card { width: 108px; height: 164px; padding: 11px 7px; }
  .card .name { font-size: 12.5px; letter-spacing: 0.1em; }
  .cards { gap: 10px; }
  .ritual-table { padding: 22px 16px; margin-bottom: 52px; }
  .section { margin: 56px 0; }
}

/* ==========================================================================
   Lunelex v1.0 Additions — Language Hint, GEO Comparison Table & Gap Box
   ========================================================================== */
.zh-hint-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 9px 14px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
  font-size: 12.5px;
  color: var(--muted);
}
.zh-hint-bar a {
  color: var(--ivory);
  text-decoration: underline;
  text-underline-offset: 4px;
}
.zh-hint-bar button {
  background: transparent;
  border: 0;
  color: var(--muted);
  cursor: pointer;
  padding: 2px 6px;
  font-size: 15px;
}
.table-wrap {
  width: 100%;
  overflow-x: auto;
  margin-top: 16px;
}
.compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.65;
}
.compare-table th,
.compare-table td {
  text-align: left;
  padding: 13px 14px;
  border-bottom: 1px solid var(--hairline);
  vertical-align: top;
}
.compare-table th {
  color: var(--ivory);
  font-weight: 500;
  letter-spacing: 0.04em;
  background: rgba(236, 230, 218, 0.04);
}
.compare-table td:last-child,
.compare-table th:last-child {
  color: var(--ivory);
  background: rgba(210, 173, 68, 0.06);
}
.gap-box {
  border-left: 2px solid rgba(210, 173, 68, 0.55);
}
