@import url('./bottom-nav.css');

:root {
  /* Canonical token layer (Phase 1) */
  --color-bg: #0b102b;
  --color-surface: rgba(255, 255, 255, 0.06);
  --color-surface-soft: rgba(255, 255, 255, 0.04);
  --color-border-soft: rgba(255, 255, 255, 0.08);
  --color-text: #f8f9ff;
  --color-text-muted: #dfe4ff;
  --color-text-muted-soft: #c8cee3;
  --color-text-inverse: #fff;
  --color-brand: #c9b7ff;
  --color-brand-2: #8b7cff;

  --radius-sm: 10px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 28px;

  --shadow-sm: 0 10px 24px rgba(126, 96, 170, 0.28);
  --shadow-md: 0 18px 40px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 14px 34px rgba(70, 50, 105, 0.16);

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;

  --font-body: 'Space Grotesk', 'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Playfair Display', 'Cormorant Garamond', Georgia, serif;

  --nav-height: 72px;
  --app-vh: 100vh;
  --navy: var(--color-bg);
  --midnight: #0d1638;
  --panel: var(--color-surface-soft);
  --lavender: var(--color-brand);
  --gold: #f2dba6;
  --muted: #9fb0d6;
  --radius: var(--radius-lg);
  --shadow: var(--shadow-md);
}

@supports (height: 100svh) {
  :root {
    --app-vh: 100svh;
  }
}

html,
body {
  max-width: 100%;
  overflow-x: clip;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: radial-gradient(circle at 18% 10%, rgba(198, 183, 255, 0.12), transparent 28%),
    radial-gradient(circle at 80% 0%, rgba(242, 219, 166, 0.18), transparent 26%),
    linear-gradient(180deg, #060b22 0%, #0c1440 100%);
  color: #f8f9ff;
  min-height: 100vh;
  min-height: var(--app-vh, 100vh);
  scroll-behavior: smooth;
}

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

header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 32px;
  background: rgba(5, 9, 26, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: calc(18px + env(safe-area-inset-top, 0px));
}

.primary-nav {
  position: relative;
  gap: 8px;
}

.logo-text {
  font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 1.35rem;
  color: #fdfaff;
}

.nav-logo {
  display: none;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
}

.nav-panel {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.nav-meta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-link {
  padding: 10px 12px;
  border-radius: 12px;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-link.active,
.nav-link:hover {
  background: var(--color-border-soft);
  color: var(--lavender);
}

.mobile-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

.mobile-menu-toggle .bar {
  width: 18px;
  height: 2px;
  background: #f8f9ff;
  border-radius: 2px;
  display: block;
}

body.nav-open {
  overflow: hidden;
}

.page-card {
  background: var(--mystic-card);
  border: 1px solid rgba(197, 177, 220, 0.4);
  border-radius: var(--mystic-radius);
  box-shadow: var(--mystic-shadow);
  padding: var(--page-card-padding);
}

@media (max-width: 900px) {
  .site-header {
    padding: 14px 20px;
  }

  .nav-panel {
    position: absolute;
    inset: calc(100% + 4px) 12px auto 12px;
    background: rgba(5, 9, 26, 0.95);
    border: 1px solid var(--color-border-soft);
    border-radius: 14px;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 14px 16px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: max-height 0.25s ease, opacity 0.25s ease;
  }

  .nav-panel.is-open {
    max-height: 420px;
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .nav-link {
    width: 100%;
    border: 1px solid var(--color-border-soft);
    background: rgba(255, 255, 255, 0.04);
  }

  .nav-meta {
    width: 100%;
    justify-content: space-between;
    border-top: 1px solid var(--color-border-soft);
    padding-top: 8px;
  }

  .language-toggle {
    padding-left: 0;
    border-left: none;
  }

  .mobile-menu-toggle {
    display: flex;
  }
}

.language-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 14px;
  border-left: 1px solid var(--color-border-soft);
}

.lang-btn {
  background: transparent;
  border: none;
  color: #f5f7ff;
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.lang-btn.active {
  color: var(--lavender);
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  padding: 56px 24px 32px;
  align-items: center;
}

.hero--compact {
  row-gap: 12px;
}

.brand-title {
  font-family: 'Prata', serif;
  font-size: clamp(36px, 5vw, 56px);
  line-height: 1.05;
  margin: 0 0 10px;
}

.tagline {
  font-size: 18px;
  color: var(--gold);
  max-width: 520px;
  margin: 0 0 12px;
}

.intro {
  color: var(--color-text-muted);
  max-width: 640px;
  margin: 0 0 12px;
}

.eyebrow {
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--lavender);
  font-weight: 700;
  font-size: 12px;
  margin: 0 0 8px;
}

.fortune-pill {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
  padding: 18px;
  border-radius: 16px;
  max-width: 540px;
}

.pill-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  margin-bottom: 12px;
}

.pill-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--lavender);
}

.pill-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.cta-group {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 12px;
  margin: 14px 0 12px;
  max-width: 420px;
  flex-wrap: wrap;
}

.cta-group .btn {
  flex: 1;
  text-align: center;
  min-width: 140px;
}

.cta-row {
  display: inline-flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 12px;
}

.pill-link {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--color-border-soft);
  background: rgba(255, 255, 255, 0.04);
  text-align: center;
  transition: border 0.2s ease, transform 0.2s ease, color 0.2s ease;
}

.pill-link.active,
.pill-link:hover {
  border-color: var(--lavender);
  color: var(--lavender);
  transform: translateY(-2px);
}

.hero-visual {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.hero-visual-panel {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-radius: 18px;
  background: radial-gradient(circle at 20% 20%, rgba(207, 217, 255, 0.12), transparent 55%),
    linear-gradient(145deg, var(--color-border-soft), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--color-border-soft);
  box-shadow: var(--shadow);
}

.hero-visual-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02));
  font-size: 22px;
}

.hero-visual-title {
  margin: 0 0 4px;
  font-weight: 600;
  color: #f5f3ff;
}

.hero-note {
  margin: 0;
  color: #cfd9ff;
  font-size: 14px;
  max-width: 260px;
}

.card-back {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

button,
.primary,
.ghost,
.btn {
  font-family: var(--font-body);
  border: none;
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  text-align: center;
  border: 1px solid transparent;
}

.primary {
  background: linear-gradient(135deg, var(--color-brand), var(--color-brand-2));
  color: var(--color-bg);
  box-shadow: 0 10px 28px rgba(140, 123, 255, 0.45);
}

.primary:hover:not(:disabled),
.btn-primary:hover {
  transform: translateY(-2px);
}

.primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

.ghost,
.btn-secondary {
  background: var(--color-surface);
  color: var(--color-text);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-primary {
  background: linear-gradient(135deg, #c9b7ff, #8b7cff);
  color: var(--color-bg);
  box-shadow: 0 10px 28px rgba(140, 123, 255, 0.45);
}

.card-panel {
  background: var(--color-surface-soft);
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.ghost:hover {
  background: rgba(255, 255, 255, 0.12);
}

.large {
  width: 80%;
}

.section-block {
  padding: 64px 32px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: 28px;
  align-items: center;
}

.tarot-hero {
  display: grid;
  grid-template-columns: minmax(320px, 1.2fr) minmax(280px, 0.9fr);
  gap: 32px;
  align-items: center;
  padding: 56px 32px 40px;
}

.tarot-hero--single {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 56px 32px 40px;
}

.tarot-board-wrapper {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
}

.hero-board .board-inner {
  padding: 24px;
}

.hero-content {
  max-width: 520px;
  justify-self: end;
}

.hero-copy {
  color: var(--color-text-muted);
  margin: 0 0 12px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 10px;
}

.hero-link {
  color: var(--lavender);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
  align-self: center;
}

@media (max-width: 1024px) {
  .tarot-hero {
    grid-template-columns: 1fr;
    padding: 48px 24px 32px;
  }

  .hero-content {
    justify-self: center;
    text-align: center;
  }

  .tarot-board-wrapper {
    order: -1;
  }

  .hero-actions {
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .tarot-hero {
    padding: 36px 18px;
  }

  .hero-board .board-inner {
    padding: 16px;
  }

  .hero-actions {
    width: 100%;
  }
}

.daily-section {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.daily-section .section-heading {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 12px;
}

.daily-section .board {
  max-width: 1200px;
  margin: 0 auto;
}

.daily-section .card-grid {
  margin-left: auto;
  margin-right: auto;
}

.section-block.alt {
  background: rgba(255, 255, 255, 0.02);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.section-heading h2 {
  margin: 6px 0 10px;
  font-size: 32px;
}

.section-heading p {
  color: var(--color-text-muted);
}

.board {
  width: 100%;
}

.board-inner {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
  border: 1px solid var(--color-border-soft);
  border-radius: 20px;
  padding: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.board-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0.6) 60%);
  z-index: 2;
}

.overlay-icon {
  font-size: 48px;
}

.board-controls {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}

.board-message {
  text-align: center;
  flex: 1;
}

.instruction {
  margin: 0;
  font-weight: 700;
  color: var(--gold);
}

.sub-instruction {
  margin: 4px 0 0;
  color: var(--color-text-muted);
}

.board-controls .controls {
  margin-left: auto;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  justify-content: center;
  gap: 12px;
  margin: 18px 0;
  min-height: 240px;
}

.card {
  position: relative;
  width: 100%;
  aspect-ratio: 1568 / 2720;
  border-radius: 14px;
  transform-style: preserve-3d;
  transition: transform 0.4s ease, box-shadow 0.2s ease, outline 0.2s ease, opacity 0.3s ease;
  cursor: pointer;
}

@media (max-width: 600px) {
  .card-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card .face {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  backface-visibility: hidden;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.card .back {
  background-color: var(--color-bg);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
}

.card .front {
  transform: rotateY(180deg);
  background: linear-gradient(135deg, #1b1f4a, #2b2f63);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #f3e7ff;
}

.card.revealed {
  transform: rotateY(180deg) scale(1.02);
}

.card.revealed .back {
  transform: rotateY(180deg);
}

.card.revealed .front {
  transform: rotateY(0deg);
}

.card .front .icon {
  font-size: 26px;
}

.card.selected {
  outline: 2px solid var(--lavender);
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 20px 44px rgba(134, 119, 255, 0.5);
}

.card-grid.is-animating {
  pointer-events: none;
}

.card.is-shuffling-out {
  opacity: 0;
  transform: scale(0.85);
}

.card.is-shuffling-in {
  opacity: 0;
  transform: scale(0.85);
}

.continue-row {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.hint {
  color: var(--muted);
}

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

.count {
  padding: 4px 8px;
  background: var(--color-border-soft);
  border-radius: 10px;
  font-weight: 700;
}

.results {
  padding: 48px 32px 64px;
  display: none;
}

.results.show {
  display: block;
}

.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 20px 0;
}

.result-card {
  padding: 14px;
  border-radius: 14px;
  background: var(--panel);
  border: 1px solid var(--color-border-soft);
}

.result-card .label {
  color: var(--lavender);
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: 12px;
  text-transform: uppercase;
}

.result-card h5 {
  margin: 8px 0 6px;
  font-size: 18px;
}

.keywords {
  margin: 4px 0 8px;
  color: var(--muted);
  font-size: 14px;
}

.summary {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
  padding: 16px;
  border-radius: 14px;
}

.summary p {
  margin: 8px 0;
  color: #dfe5ff;
}

.result-actions {
  margin-top: 18px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.share-group {
  display: flex;
  gap: 10px;
}


@media (max-width: 900px) {
  .site-header {
    grid-template-columns: 38px 1fr 38px;
  }

  .nav-panel {
    position: absolute;
    width: 100%;
    max-width: 420px;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: max-height 0.25s ease, opacity 0.25s ease;
  }

  .nav-panel.is-open {
    max-height: 560px;
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .nav-link {
    width: 100%;
  }

  .nav-meta {
    justify-content: center;
    border-top: 1px solid rgba(168, 137, 196, 0.24);
    padding-top: 10px;
  }

  .language-toggle {
    border-left: none;
    padding-left: 0;
    gap: 10px;
  }
}

@media (min-width: 901px) {
  .mobile-menu-toggle {
    display: none;
  }

  .site-header {
    max-width: min(940px, calc(100% - 2rem));
    width: calc(100% - 2rem);
    grid-template-columns: 38px 1fr 38px;
  }

  .nav-panel {
    position: static;
    max-height: none;
    opacity: 1;
    pointer-events: auto;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    overflow: visible;
    transform: none;
    width: auto;
  }

  .header-title {
    text-align: left;
    margin-left: 6px;
  }

  .nav-links {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-end;
  }
}
.site-footer {
  padding: 22px 32px 28px;
  text-align: center;
  color: #cbd4ff;
  border-top: 1px solid var(--color-border-soft);
  background: rgba(0, 0, 0, 0.18);
}

.meaning-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.sample-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 12px;
}

.sample-card h5 {
  margin: 6px 0;
}

@media (max-width: 768px) {
  .hero {
    padding: 32px 20px 24px;
    gap: 18px;
  }

  .brand-title {
    font-size: 32px;
    line-height: 1.2;
    margin-bottom: 8px;
  }

  .tagline {
    font-size: 16px;
    margin: 0 0 10px;
  }

  .intro {
    font-size: 14px;
    margin: 0 0 10px;
  }

  .cta-group {
    margin: 14px auto 20px;
    max-width: 360px;
  }

  .board-controls { align-items: flex-start; }
}

@media (max-width: 720px) {
  .hero {
    padding: 38px 16px 18px;
  }

  .hero-copy {
    text-align: left;
  }

  .brand-title {
    font-size: clamp(28px, 8vw, 38px);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .tagline {
    font-size: 16px;
  }

  .hero-note {
    max-width: none;
  }

  .card-meanings-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .meanings-btn {
    width: 100%;
  }

  /* ✅ FIX: prevent the strip from stretching vertically on mobile */
  .card-strip {
    flex: 0 0 auto;
    width: 100%;
  }

  .meaning-card {
    min-width: 160px;
    height: 52px;
  }
}

.is-hidden { display: none !important; }

/* New layout helpers */
.page-shell {
  max-width: 640px;
  margin: 0 auto;
  padding: calc(var(--nav-height) + 20px) 18px 60px;
}

.section-block {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border-soft);
  border-radius: 18px;
  padding: 20px;
  box-shadow: var(--shadow);
}

body[data-page='home'] .page-shell {
  width: 100%;
  max-width: none;
  padding: calc(var(--nav-height) + 12px) 0 60px;
}

.home-grid {
  width: 100%;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}

body[data-page='home'] .hero,
body[data-page='home'] .section-block {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

body[data-page='home'] .section-block {
  margin-bottom: 18px;
}

body[data-page='home'] .section-block {
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: flex-start;
}

.section-meanings {
  background: radial-gradient(circle at 20% 20%, rgba(198, 183, 255, 0.12), transparent 35%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(198, 183, 255, 0.3);
}

.card-meanings-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: space-between;
}

/* ✅ FIX: stop vertical stretching + allow shrinking in flex */
.card-strip {
  display: flex;
  gap: 10px;
  padding: 10px 4px;
  overflow-x: auto;
  scrollbar-width: thin;

  flex: 1 1 auto;
  min-width: 0;
  align-items: center; /* IMPORTANT: prevents tall stretched cards */
}

.card-strip::-webkit-scrollbar {
  height: 6px;
}

.card-strip::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 10px;
}

/* ✅ FIX: compact pill height so it never becomes a tall bar */
.meaning-card {
  min-width: 110px;
  height: 54px;
  padding: 0 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-weight: 700;
  color: #f8f9ff;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.32);

  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

.meaning-card--fool {
  background: linear-gradient(145deg, rgba(198, 183, 255, 0.28), rgba(255, 255, 255, 0.02));
}

.meaning-card--star {
  background: linear-gradient(145deg, rgba(146, 213, 255, 0.2), rgba(255, 255, 255, 0.04));
}

.meaning-card--death {
  background: linear-gradient(145deg, rgba(149, 133, 255, 0.22), rgba(255, 255, 255, 0.03));
}

.meaning-card--sun {
  background: linear-gradient(145deg, rgba(242, 219, 166, 0.3), rgba(255, 255, 255, 0.04));
}

.meaning-card--moon {
  background: linear-gradient(145deg, rgba(132, 164, 255, 0.22), rgba(255, 255, 255, 0.03));
}

.meanings-btn {
  max-width: 220px;
}


.section-faq {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 12px 0 6px;
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-list details {
  border: 1px solid var(--color-border-soft);
  border-radius: 14px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.02);
}

.faq-list summary {
  cursor: pointer;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.faq-list p {
  margin: 10px 0 0;
  color: var(--color-text-muted);
}

.board-page .board-shell {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  padding: 16px;
  box-shadow: var(--shadow);
}

.board-header {
  text-align: center;
  margin-bottom: 12px;
}

.board-helper {
  color: rgba(255, 255, 255, 0.72);
  margin: 6px 0 0;
}

.card-board {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  padding: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  min-height: 240px;
  position: relative;
}

.board-start-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.board-start-overlay__inner {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  text-align: center;
  padding: 12px 16px;
}

.board-start-overlay__cta {
  min-width: 220px;
  padding: 16px 32px;
  font-size: 18px;
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.3),
    0 0 24px rgba(198, 183, 255, 0.5);
}

.board-start-overlay__hint {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
}

.card-board.is-locked {
  pointer-events: none;
}

.card-board.card-board--three {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  justify-items: center;
  gap: 10px;
  padding: 12px;
}

.board-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 10px 0 4px;
}

.board-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.board-controls {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.continue-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 220px;
  justify-content: center;
}


.ritual-cta {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1.25;
  gap: 2px;
  min-width: 220px;
}

.ritual-cta span:last-child {
  font-size: 0.92em;
}

.ritual-cta:active:not(:disabled) {
  transform: scale(0.98);
}

@media (max-width: 640px) {
  .board-topbar {
    justify-content: center;
  }

  .board-controls {
    width: 100%;
    justify-content: center;
  }
}

.continue-btn .counter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.selection-counter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 12px;
  background: var(--color-border-soft);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.board-actions {
  display: flex;
  gap: 10px;
  margin-top: 8px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.board-actions.board-actions--center {
  justify-content: center;
}

.board-actions button {
  flex: 1 1 220px;
}

.action-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.card-slot {
  width: 96px;
  height: 146px;
  aspect-ratio: 1568 / 2720;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
  position: relative;
  cursor: pointer;
  opacity: 0;
  transform: translateY(10px);
  transition: transform 0.2s ease, border-color 0.15s ease, box-shadow 0.15s ease, opacity 0.2s ease;
}

.card-board.card-board--three .card-slot {
  width: clamp(74px, 9vw, 110px);
  height: auto;
}

.card-slot.card-visible {
  opacity: 1;
  transform: translateY(0);
}

.card-slot.card-slot--dealable {
  transition: transform 0.2s ease, border-color 0.15s ease, box-shadow 0.15s ease, opacity 0.2s ease;
}

.card-slot:hover:not(:disabled) {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.32);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.25);
}

.card-slot:disabled {
  opacity: 0.6;
  cursor: default;
}

/* MUCH stronger selected state */
.card-slot.is-selected {
  transform: translateY(-10px) scale(1.07);
  border-color: transparent; /* ring will be clearer than border */
  box-shadow:
    0 0 0 4px rgba(198, 183, 255, 0.95),
    0 0 0 10px rgba(198, 183, 255, 0.22),
    0 22px 60px rgba(198, 183, 255, 0.42),
    0 16px 40px rgba(0, 0, 0, 0.35);
  z-index: 5; /* lift above neighbors */
}

/* Glow overlay ring (sits ABOVE the card back image) */
.card-slot.is-selected::after {
  content: "";
  position: absolute;
  inset: -10px;               /* ring outside the card */
  border-radius: 18px;
  pointer-events: none;
  z-index: 6;
  background: radial-gradient(circle at 30% 20%,
    rgba(198, 183, 255, 0.55),
    rgba(198, 183, 255, 0.0) 60%);
  box-shadow: 0 0 46px rgba(198, 183, 255, 0.75);
  animation: selectedPulse 1.05s ease-in-out infinite;
}

/* Check badge so you can’t miss it */
.card-slot.is-selected::before {
  content: "✓";
  position: absolute;
  top: 10px;
  left: 10px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-weight: 900;
  color: var(--color-bg);
  background: rgba(198, 183, 255, 0.98);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
  z-index: 7;
}

.card-slot.is-dimmed {
  opacity: 0.28;
  transform: scale(0.95);
  transition: opacity 0.12s ease, transform 0.12s ease;
}

@keyframes selectedPulse {
  0%   { opacity: 0.65; transform: scale(1); }
  50%  { opacity: 1;    transform: scale(1.02); }
  100% { opacity: 0.65; transform: scale(1); }
}

.card-slot { position: relative; }
.card-slot .card-back { position: relative; z-index: 1; }

.card-board.card-board--daily {
  display: grid;
  width: min(100%, 360px);
  min-height: 324px;
  margin: 16px auto;
  padding-bottom: 18px;
  grid-template-columns: repeat(3, 96px);
  grid-template-rows: repeat(2, 146px);
  justify-content: center;
  align-content: center;
  overflow: visible;
  justify-items: center;
}

.selection-badge {
  transition: opacity 0.14s ease, transform 0.14s ease;
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--lavender);
  color: #1a1a1a;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
}

.board-start {
  display: flex;
  justify-content: center;
  margin-top: 10px;
}

.board-start.is-hidden {
  display: none;
}

@media (max-width: 640px) {
  .card-board.card-board--three {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }

  .card-board.card-board--three .card-slot {
    width: 70px;
  }

  .card-board.card-board--daily {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .card-board.card-board--three .card-slot {
    width: 96px;
  }
}

.card-board { overflow: visible; }

.deck-stack {
  position: relative;
  width: clamp(112px, 15vw, 156px);
  aspect-ratio: 1568 / 2720;
  isolation: isolate;
}

body[data-page='full'] #overall-toolbar[hidden],
body[data-page='full'] #overall-actions[hidden] {
  display: none !important;
}

.deck-stack-card:nth-child(1) { transform: translate(-10px, 8px) rotate(-9deg); opacity: 0.78; }
.deck-stack-card:nth-child(2) { transform: translate(-6px, 5px) rotate(-6deg); opacity: 0.84; }
.deck-stack-card:nth-child(3) { transform: translate(-2px, 2px) rotate(-3deg); opacity: 0.9; }
.deck-stack-card:nth-child(4) { transform: translate(2px, -1px) rotate(2deg); opacity: 0.94; }
.deck-stack-card:nth-child(5) { transform: translate(4px, -3px) rotate(4deg); opacity: 0.97; }
.deck-stack-card:nth-child(6) { transform: translate(0, 0) rotate(0deg); opacity: 1; }

.deck-stack-card {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.28);
  background-image: var(--card-back-image, none);
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  background-color: rgba(15, 14, 31, 0.92);
  transition: opacity 0.14s ease;
  will-change: transform, opacity, box-shadow;
}

.overall-cta-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

.cta-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

#overall-result {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.card-result, .multi-card-result, .summary-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.reading-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.panel {
  padding: 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
}

.history-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.profile-history-item {
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--color-border-soft);
  background: rgba(255, 255, 255, 0.03);
}

.profile-history-item__title,
.profile-history-item__cards {
  margin: 0;
}

.profile-history-item__cards {
  color: var(--muted);
  margin-top: 4px;
}

.profile-history-item__actions {
  margin-top: 10px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-history-item__action {
  text-decoration: none;
  font-size: 14px;
  padding: 9px 12px;
}

.profile-empty-state {
  display: grid;
  gap: 8px;
}

.profile-empty-state__title,
.profile-empty-state__body {
  margin: 0;
}

.profile-empty-state__body {
  color: var(--muted);
}

.profile-empty-state__cta {
  justify-self: flex-start;
  text-decoration: none;
}

.streak-progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 4px;
  overflow: hidden;
  margin: 8px 0 4px;
}

.streak-progress-bar__fill {
  height: 100%;
  background: var(--color-accent, #b48be4);
  border-radius: 4px;
  transition: width 0.4s cubic-bezier(0.22, 0.65, 0.18, 1);
}

.streak-progress-label {
  font-size: 0.78rem;
  color: var(--color-text-muted, #888);
  margin: 0 0 12px;
}

.question-spread-chooser {
  display: flex;
  gap: 10px;
  margin: 0 0 20px;
}

.question-spread-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 8px;
  border: 2px solid rgba(0,0,0,0.10);
  border-radius: 12px;
  background: transparent;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.question-spread-btn--active {
  border-color: var(--color-accent, #b48be4);
  background: rgba(180, 139, 228, 0.08);
}

.question-spread-btn__label {
  font-size: 0.9rem;
  font-weight: 600;
}

.question-spread-btn__sub {
  font-size: 0.72rem;
  color: var(--color-text-muted, #888);
  margin-top: 2px;
}

.card-heading h2 {
  margin: 0 0 6px;
}

.card-heading p {
  margin: 0;
  color: var(--muted);
}

.lede {
  font-weight: 600;
  margin-top: 0;
}


.topic-copy {
  margin: 0;
  line-height: 1.65;
}

.topic-copy-lead {
  display: inline;
  font-size: 1.06em;
  font-weight: 600;
}

.topic-copy-rest {
  display: inline;
}

.meta-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  margin: 10px 0;
}

.meta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

body[data-page='reading'][data-reading-mode='full'] .meta-group--identity {
  display: none;
}

body[data-page='reading'][data-reading-mode='full'] .meta-row {
  margin: 0;
}

.meta-group--identity {
  gap: 8px;
}

.meta-group--lucky,
.meta-group--avoid {
  gap: 8px;
  align-content: flex-start;
}

.meta-badge {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  font-size: 14px;
  display: inline-flex;
  gap: 6px;
}

.color-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid var(--color-border-soft);
}

.swatch {
  width: 18px;
  height: 18px;
  border-radius: 6px;
  display: inline-block;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.chip-row,
.spread-toggle,
.topic-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0;
}

.topic-chips {
  overflow-x: auto;
  padding-bottom: 6px;
}

.question-intention {
  margin: 18px 0 10px;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(180deg, var(--color-border-soft) 0%, rgba(255, 255, 255, 0.03) 100%);
  display: grid;
  gap: 14px;
}

.question-intention__intro h2 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.question-intention__intro p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.question-intention__steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.question-step {
  margin: 0;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
  color: rgba(255, 255, 255, 0.92);
  line-height: 1.55;
  font-size: 0.96rem;
}

.chip {
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-text-inverse);
  cursor: pointer;
  white-space: nowrap;
}

.chip.active,
.chip.chip-active {
  border-color: var(--lavender);
  background: rgba(198, 183, 255, 0.12);
}

.question-actions {
  display: flex;
  justify-content: flex-end;
  margin: 4px 0 8px;
}

.input {
  width: 100%;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: var(--space-3);
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-text-inverse);
}

.input-label {
  display: block;
  margin: 10px 0 6px;
  color: var(--muted);
}

.details, details {
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  padding: 8px 12px;
}

details + details {
  margin-top: 10px;
}

details summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

details[open] {
  background: rgba(255, 255, 255, 0.06);
}

details summary::-webkit-details-marker {
  display: none;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 20px;
}

.feature-card {
  padding: 16px;
  border-radius: 14px;
  border: 1px solid var(--color-border-soft);
  background: rgba(255, 255, 255, 0.04);
}

.feature-card h3 {
  margin-top: 0;
}

.card-result details p,
.card-result details .color-chip {
  margin-left: 4px;
}

/* Reading card image (results page) */
.card-art {
  display: flex;
  justify-content: center;
  margin: 12px 0;
}

.card-art-img {
  width: min(320px, 100%);
  height: auto;
  display: block;
  border-radius: 14px;
  border: 1px solid var(--color-border-soft);
  box-shadow: var(--shadow);
  backface-visibility: hidden;
  will-change: transform;
}

.card-art.is-thumb .card-art-img {
  width: 100%;
  max-width: 120px;
  aspect-ratio: 3 / 5;
  object-fit: cover;
  margin-inline: auto;
}

body[data-page='reading'][data-reading-mode='full'] .reading-spread-card .card-art {
  width: 100%;
  padding: 2px 0;
}

body[data-page='reading'][data-reading-mode='full'] .card-art.is-thumb .card-art-img {
  max-width: 150px;
  object-fit: contain;
  object-position: center;
  background: transparent;
}

.reading-spread-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding-inline: 2px;
}

@media (max-width: 768px) {
  .full-summary-grid {
    grid-template-columns: 1fr;
  }
}

.reading-spread-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: 0;
  background: transparent;
  padding: 0;
  min-width: 0;
  white-space: normal;
}

.reading-spread-card .card-art {
  margin: 0;
}

.spread-caption {
  display: grid;
  gap: 4px;
  text-align: center;
  min-width: 0;
}

.spread-label,
.spread-orientation {
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}

.spread-orientation {
  font-size: 12px;
  color: var(--muted);
}

@media (min-width: 900px) {
  .reading-spread-grid {
    gap: 12px;
  }

  .card-art.is-thumb .card-art-img {
    max-width: 160px;
  }

  body[data-page='reading'][data-reading-mode='full'] .card-art.is-thumb .card-art-img {
    max-width: 188px;
  }

  .spread-caption {
    gap: 2px;
  }

  .full-summary-meta {
    display: grid;
    gap: 2px;
    margin-bottom: 8px;
  }

  .full-summary-meta__name {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #352b49;
    line-height: 1.35;
  }

  .full-summary-meta__archetype {
    margin: 0;
    font-size: 13px;
    color: #4a3f60;
    line-height: 1.35;
  }

  .full-summary-meta__imply {
    margin: 0;
    font-size: 11px;
    color: var(--muted);
    line-height: 1.35;
  }
}

.reading-card-hero,
.reading-card-thumb {
  display: flex;
  justify-content: center;
}

.tarot-card-img--hero {
  width: 100%;
  max-width: 340px;
  border-radius: 14px;
  display: block;
  box-shadow: var(--shadow);
  margin: 0 auto 12px;
}

.tarot-card-img--thumb {
  width: 100%;
  max-width: 180px;
  border-radius: 12px;
  display: block;
  box-shadow: var(--shadow);
  margin: 10px auto 8px;
}

/* Fix: keep spacing for the imply/keywords line inside the heading */
.card-heading .keywords {
  margin: 4px 0 8px;
  color: var(--muted);
  font-size: 14px;
}

/* Optional: if your HTML uses only id="reading-content" without class */
#reading-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Home meanings actions (no overlap) */
.section-meanings .meanings-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.section-meanings .meanings-btn {
  width: 100%;
  max-width: none;
}

.section-meanings .meanings-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.section-meanings .meanings-categories .chip {
  flex: 1 1 140px;
  text-align: center;
}

.card-slot {
  position: relative;
  overflow: hidden;
}

.card-slot .card-back {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: inherit;
  color: transparent; /* hides the 🐾 text */
}

/* Tarot meanings hub */
.page-meanings {
  max-width: 1200px;
  padding: 28px 22px 90px;
  margin: 0 auto;
}

.breadcrumbs {
  margin: 6px 0 18px;
  font-size: 14px;
  color: var(--muted);
}

.breadcrumbs ol {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.breadcrumbs li::after {
  content: '›';
  margin-left: 8px;
  color: rgba(255, 255, 255, 0.4);
}

.breadcrumbs li:last-child::after {
  display: none;
}

.meaning-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  background: radial-gradient(circle at 20% 20%, rgba(242, 219, 166, 0.16), transparent 40%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(242, 219, 166, 0.25);
}

.meaning-hero h1 {
  margin: 6px 0 10px;
  font-size: 42px;
}

.hero-subtext {
  color: var(--color-text-muted);
  margin: 0 0 16px;
  max-width: 620px;
  line-height: 1.5;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hero-highlights {
  padding: 0;
  margin: 4px 0 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-highlights li {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
  font-size: 14px;
  color: #e7ecff;
}

.meaning-hero .hero-visual {
  position: relative;
  display: grid;
  gap: 14px;
  align-content: start;
}

.hero-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 20%, rgba(198, 183, 255, 0.2), transparent 45%);
  filter: blur(28px);
  z-index: 0;
}

.stat-block {
  position: relative;
  z-index: 1;
  padding: 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
}

.stat-block.secondary {
  border-color: rgba(242, 219, 166, 0.3);
}

.stat-label {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.stat-value {
  margin: 6px 0 4px;
  font-size: 20px;
  font-weight: 700;
}

.stat-desc {
  margin: 0;
  color: #e7ecff;
}

.section-heading {
  margin-bottom: 12px;
}

.section-lead {
  color: var(--color-text-muted);
  margin: 0;
}

.meaning-categories .category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.category-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.category-card:hover,
.category-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(242, 219, 166, 0.45);
  background: rgba(242, 219, 166, 0.06);
}

.category-card.is-featured {
  grid-column: span 2;
  background: linear-gradient(135deg, rgba(242, 219, 166, 0.14), rgba(255, 255, 255, 0.02));
  border-color: rgba(242, 219, 166, 0.35);
}

.category-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--color-border-soft);
  font-size: 22px;
}

.category-title {
  margin: 0 0 4px;
  font-weight: 700;
  font-size: 18px;
}

.category-desc {
  margin: 0;
  color: var(--color-text-muted);
}

.count-badge {
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
  font-size: 13px;
  color: var(--gold);
}

.meaning-search .search-row {
  display: grid;
  gap: 12px;
}

.search-label {
  font-weight: 600;
  margin: 0;
}

.search-input {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-3);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border-soft);
}

.search-input input {
  background: transparent;
  border: none;
  color: var(--color-text-inverse);
  padding: 10px 6px;
  font-size: 16px;
  width: 100%;
}

.search-input input:focus {
  outline: none;
}

.quick-chips {
  gap: 8px;
  flex-wrap: wrap;
}

.filter-note {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--color-text-muted);
}

.chip-clear {
  border-color: rgba(242, 219, 166, 0.4);
  color: var(--color-text-inverse);
}

.search-results {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: grid;
  gap: 10px;
}

.search-result a {
  display: grid;
  gap: 4px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.search-result a:hover,
.search-result a:focus-visible {
  border-color: rgba(242, 219, 166, 0.4);
  background: rgba(255, 255, 255, 0.05);
}

.result-title {
  font-weight: 700;
  font-size: 18px;
}

.result-meta {
  color: var(--muted);
  font-size: 14px;
}

.result-summary {
  color: var(--color-text-muted);
  font-size: 14px;
}

.search-empty {
  padding: 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
  color: var(--color-text-muted);
}

.helper-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.helper-card {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.helper-card:hover,
.helper-card:focus-visible {
  border-color: rgba(242, 219, 166, 0.4);
  background: rgba(242, 219, 166, 0.05);
}

.helper-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--color-border-soft);
}

.helper-title {
  margin: 0 0 4px;
  font-weight: 700;
}

.helper-desc {
  margin: 0;
  color: var(--color-text-muted);
}

.featured-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.featured-link-item {
  border-radius: 14px;
  border: 1px solid var(--color-border-soft);
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.featured-link-item:hover,
.featured-link-item:focus-within {
  border-color: rgba(242, 219, 166, 0.4);
  transform: translateY(-2px);
}

.featured-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: inherit;
  padding: 12px 14px;
}

.featured-link h3 {
  margin: 4px 0;
}

.faq details {
  border-radius: 14px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--color-border-soft);
}

.faq summary {
  font-weight: 700;
  cursor: pointer;
}

.footer-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

@media (max-width: 960px) {
  .category-card.is-featured {
    grid-column: span 1;
  }

  .featured-link {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .page-meanings {
    padding: 22px 16px 70px;
  }

  .meaning-hero h1 {
    font-size: 32px;
  }

  .search-input {
    grid-template-columns: auto 1fr;
  }

  .search-input .btn-secondary {
    display: none;
  }
}

/* Suit pages */
.page-suit {
  color: var(--text-primary, #e9ecf5);
}

.page-suit .suit-hero {
  background: linear-gradient(135deg, rgba(22, 26, 52, 0.7), rgba(32, 36, 66, 0.6));
  border: 1px solid var(--color-border-soft);
  border-radius: 20px;
  display: grid;
  gap: 24px;
  grid-template-columns: 2fr 1fr;
  padding: 32px;
}

.page-suit .hero-copy h1 {
  margin-bottom: 12px;
}

.page-suit .hero-subtext {
  color: var(--text-secondary, var(--color-text-muted-soft));
  font-size: 1rem;
  line-height: 1.5;
  margin-bottom: 16px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.chip {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  color: var(--text-secondary, var(--color-text-muted-soft));
  font-size: 0.95rem;
  padding: 10px 14px;
}

.chip strong {
  color: var(--color-text-inverse);
  font-weight: 600;
  margin-right: 6px;
}

.hero-support {
  display: grid;
  gap: 12px;
  align-content: start;
}

.hero-card-count {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
  border-radius: 16px;
  padding: 16px;
}

.hero-card-count .label {
  color: var(--text-secondary, var(--color-text-muted-soft));
  font-size: 0.9rem;
  margin: 0 0 6px;
}

.hero-card-count .value {
  font-size: 2.2rem;
  font-weight: 700;
  margin: 0;
}

.hero-highlights {
  display: grid;
  gap: 10px;
}

.highlight-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: var(--text-secondary, var(--color-text-muted-soft));
  padding: 12px 14px;
}

.suit-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.view-toggle {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
  border-radius: 12px;
  display: inline-flex;
  padding: 4px;
}

.view-toggle .toggle {
  background: transparent;
  border: none;
  border-radius: 8px;
  color: var(--text-secondary, var(--color-text-muted-soft));
  cursor: pointer;
  font-weight: 600;
  padding: 10px 14px;
  transition: background 0.2s ease, color 0.2s ease;
}

.view-toggle .toggle.active {
  background: var(--color-text-inverse);
  color: #0f142e;
}

.suit-card-collection {
  display: grid;
  gap: 16px;
}

.suit-card-collection.is-grid {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.suit-card-collection.is-list {
  grid-template-columns: 1fr;
}

.suit-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--color-border-soft);
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.suit-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.18);
}

.suit-card-link {
  color: inherit;
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
  height: 100%;
  text-decoration: none;
}

.suit-card-media {
  position: relative;
  aspect-ratio: 3 / 5;
  background: radial-gradient(circle at 20% 20%, var(--color-border-soft), rgba(255, 255, 255, 0.02));
}

.suit-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.suit-card-number {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(15, 20, 46, 0.9);
  border-radius: 999px;
  color: var(--color-text-inverse);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 6px 10px;
}

.suit-card-body {
  padding: 0 16px 16px;
}

.suit-card-order {
  color: var(--text-secondary, var(--color-text-muted-soft));
  font-weight: 700;
  letter-spacing: 0.05em;
  margin: 0 0 6px;
}

.suit-card h3 {
  margin: 0 0 8px;
}

.suit-card-summary {
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin: 0;
}

.suit-card-collection.is-list .suit-card-link {
  align-items: center;
  grid-template-columns: 120px 1fr;
}

.suit-card-collection.is-list .suit-card-media {
  aspect-ratio: 3 / 4;
}

.guide-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.guide-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--color-border-soft);
  border-radius: 14px;
  padding: 16px;
}

.guide-card h3 {
  margin-top: 0;
}

.guide-card p {
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin-bottom: 0;
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--color-border-soft);
  border-radius: 12px;
  padding: 12px 14px;
}

.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item p {
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin: 8px 0 0;
}

@media (max-width: 900px) {
  .page-suit .suit-hero {
    grid-template-columns: 1fr;
  }

  .suit-card-collection.is-list .suit-card-link {
    grid-template-columns: 96px 1fr;
  }
}

@media (max-width: 640px) {
  .suit-card-collection.is-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  }

  .chip {
    width: 100%;
    justify-content: space-between;
  }
}

/* Card meaning page */
.page-card-meaning {
  width: min(420px, calc(100vw - 32px));
  margin: 0 auto;
  padding: calc(var(--nav-height) + 18px) 0 calc(env(safe-area-inset-bottom, 0px) + 24px);
  display: grid;
  gap: 32px;
}

.page-card-meaning > article {
  display: grid;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.page-card-meaning .breadcrumbs ol {
  flex-wrap: wrap;
}

.card-hero {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 32px;
  align-items: center;
  position: relative;
  z-index: 0;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.card-visual {
  margin: 0;
  position: relative;
  display: flex;
  justify-content: center;
  min-width: 0;
}

.card-meta {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  overflow-wrap: break-word;
  word-break: normal;
}

.card-frame {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--color-border-soft);
  border-radius: 18px;
  padding: 16px;
  max-width: 320px;
}

.card-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
  position: relative;
  z-index: 0;
}

body[data-page='meanings'] header#site-header,
body[data-page='meanings'] #site-header .site-header {
  z-index: 400;
}

.card-orientation-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.card-meta h1 {
  margin: 8px 0;
}

.card-alias {
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin: 4px 0 12px;
}

.orientation-toggle {
  display: flex;
  gap: 8px;
  margin: 12px 0;
}

.orientation-toggle .chip {
  cursor: pointer;
}

.orientation-toggle .is-active {
  background: var(--brand-primary, #ff9b65);
  border-color: transparent;
  color: #0a0f24;
}

.orientation-toggle .chip.is-disabled,
.orientation-toggle .chip:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.keyword-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0;
}

.keyword-chips .chip.keyword {
  background: var(--color-border-soft);
  border-color: rgba(255, 255, 255, 0.16);
}

.card-summary {
  color: var(--text-secondary, var(--color-text-muted-soft));
  font-size: 16px;
  line-height: 1.6;
  overflow-wrap: break-word;
  word-break: normal;
}

.meaning-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.meaning-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border-soft);
  border-radius: 16px;
  padding: 20px;
}

.tarot-card-meaning-page .card-meaning-hero {
  align-items: stretch;
}

.card-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin: 0 0 8px;
}

.card-archetype {
  margin: 0 0 10px;
  color: var(--text-secondary, var(--color-text-muted-soft));
}

.symbolic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}

.symbolic-row {
  border: 1px solid var(--color-border-soft);
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  padding: 12px;
}

.symbolic-row dt {
  font-size: 12px;
  text-transform: uppercase;
  color: var(--text-secondary, var(--color-text-muted-soft));
}

.symbolic-row dd {
  margin: 4px 0 0;
  font-size: 16px;
  font-weight: 600;
}

.energy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.energy-meter {
  border: 1px solid var(--color-border-soft);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  padding: 10px 12px;
}

.energy-meter__top {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  text-transform: uppercase;
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin-bottom: 8px;
}

.energy-meter__track {
  width: 100%;
  height: 7px;
  border-radius: 999px;
  background: var(--color-border-soft);
  overflow: hidden;
}

.energy-meter__track span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #f8ad6a, #d6abff);
}

.card-meaning-footer-nav {
  display: grid;
  gap: 14px;
}

.footer-card-nav,
.reading-cta-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.footer-nav-pill {
  text-align: center;
  text-decoration: none;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: inherit;
  background: rgba(255, 255, 255, 0.04);
}

.footer-nav-pill.is-primary {
  background: var(--brand-primary, #ff9b65);
  color: #0a0f24;
  border-color: transparent;
  font-weight: 600;
}

.quick-spreads .spread-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.spread-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border-soft);
  border-radius: 14px;
  padding: 14px;
}

.spread-label {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--text-secondary, var(--color-text-muted-soft));
  margin-bottom: 6px;
}

.related-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.related-card a {
  display: block;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--color-border-soft);
  background: rgba(255, 255, 255, 0.04);
  text-decoration: none;
}

.related-title {
  font-weight: 700;
  margin: 0 0 4px;
}

.related-meta {
  margin: 0;
  color: var(--text-secondary, var(--color-text-muted-soft));
}

.faq-list details {
  border: 1px solid var(--color-border-soft);
  border-radius: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.04);
}

.faq-list summary {
  cursor: pointer;
  font-weight: 700;
}

.faq-list p {
  margin: 8px 0 0;
  color: var(--text-secondary, var(--color-text-muted-soft));
}

@media (max-width: 900px) {
  .card-hero {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .card-frame {
    width: min(100%, 260px);
    max-width: 260px;
  }
}

@media (min-width: 768px) {
  .page-card-meaning {
    width: min(980px, calc(100vw - 48px));
    padding-top: calc(var(--nav-height) + 22px);
    padding-bottom: 72px;
  }
}

@media (min-width: 1024px) {
  .page-card-meaning {
    width: min(1160px, calc(100vw - 64px));
    padding-top: calc(var(--nav-height) + 26px);
    padding-bottom: 92px;
  }
}

@media (min-width: 1280px) {
  .page-card-meaning {
    width: min(1200px, calc(100vw - 80px));
  }
}

/* -------------------------------------------------------------------------- */
/* Reading page: mobile-first premium ritual card                              */
/* -------------------------------------------------------------------------- */
body[data-page='reading'] {
  font-family: 'Inter', 'SF Pro Text', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #2b2b2b;
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0) 48%),
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.34) 0 1.2px, transparent 1.2px),
    radial-gradient(circle at 84% 24%, rgba(255, 255, 255, 0.34) 0 1px, transparent 1px),
    radial-gradient(circle at 38% 78%, rgba(255, 255, 255, 0.26) 0 1px, transparent 1px),
    linear-gradient(180deg, #cfa5e5 0%, #e7a7c8 52%, #a8c6f0 100%);
  background-size: auto, auto, auto, auto, auto;
  min-height: 100vh;
  min-height: var(--app-vh, 100vh);
  display: flex;
  flex-direction: column;
}

body[data-page='reading']::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.075;
  background-image: radial-gradient(rgba(255, 255, 255, 0.9) 0.5px, transparent 0.5px);
  background-size: 3px 3px;
}

body[data-page='reading'] > .page-shell {
  flex: 1 0 auto;
}

body[data-page='reading'] .section-block.results {
  display: block;
  grid-template-columns: none;
}

body[data-page='reading'] .reading-content {
  width: 100%;
  min-width: 0;
}

body[data-page='reading'] > #site-footer {
  margin-top: auto;
}

.reading-experience {
  min-height: 100vh;
  min-height: var(--app-vh, 100vh);
  display: flex;
  justify-content: center;
  padding: calc(env(safe-area-inset-top, 0px) + 20px) 24px calc(env(safe-area-inset-bottom, 0px) + 22px);
  animation: readingFadeIn 0.7s ease;
}

.reading-card {
  width: 100%;
  max-width: 420px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 16px 36px rgba(85, 52, 124, 0.22);
  padding: 24px;
  margin: 0;
  display: block;
  overflow: hidden;
}

.reading-top-nav {
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: center;
  margin-bottom: 20px;
}

.back-link {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #4a3d62;
  font-size: 22px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.back-link:hover {
  background: #f2edf8;
  transform: translateY(-1px);
}

.reading-nav-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-align: center;
  margin: 0;
  color: #3e3650;
}

.reading-intro {
  margin-bottom: 14px;
}

.reading-intro .eyebrow {
  color: #866f9f;
}

.reading-intro__context {
  margin: 10px 0 0;
  max-width: 58ch;
  color: rgba(51, 43, 71, 0.74);
  line-height: 1.7;
}

body[data-page='reading'] h1#readingTitle {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(28px, 7.6vw, 32px);
  margin: 0;
  color: #2b2b2b;
}

.meaning-accordion {
  margin-top: 18px;
  background: #f4f4f6;
  border-radius: 20px;
  box-shadow: 0 8px 18px rgba(64, 53, 86, 0.08);
  padding: 4px;
}

.accordion-trigger {
  width: 100%;
  border: 0;
  background: transparent;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  font-weight: 600;
  color: #3c3648;
  cursor: pointer;
}

.accordion-chevron {
  transition: transform 0.25s ease;
}

.accordion-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease;
}

.accordion-body p {
  overflow: hidden;
  margin: 0;
  padding: 0 16px;
  color: #63606c;
  line-height: 1.65;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.meaning-accordion.is-open .accordion-body {
  grid-template-rows: 1fr;
}

.meaning-accordion.is-open .accordion-body p {
  padding: 0 16px 16px;
  opacity: 1;
}

.meaning-accordion.is-open .accordion-chevron {
  transform: rotate(180deg);
}

body[data-page='reading'] .action-row {
  margin-top: 20px;
  display: grid;
  gap: 10px;
}

body[data-page='reading'] .primary {
  width: 100%;
  border-radius: 20px;
  border: 0;
  padding: 16px;
  color: var(--color-text-inverse);
  font-weight: 600;
  background: linear-gradient(120deg, #7ca7ff, #df88bc);
  box-shadow: 0 12px 24px rgba(137, 104, 181, 0.3);
  transition: transform 0.16s ease, box-shadow 0.22s ease;
}

body[data-page='reading'] .primary:hover:not(:disabled) {
  box-shadow: 0 16px 28px rgba(137, 104, 181, 0.35);
}

body[data-page='reading'] .primary:active:not(:disabled) {
  transform: scale(0.97);
}


.panel--spread {
  padding-inline: 10px;
}


.full-summary-panel {
  padding-inline: 10px;
}

.full-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.full-summary-box {
  border: 1px solid rgba(197, 177, 220, 0.4);
  border-radius: 14px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.5);
}

.full-summary-box h3 {
  margin: 0 0 6px;
  font-size: 14px;
}

.full-summary-meta {
  display: none;
}

.full-summary-box p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
}

.panel-kicker {
  margin: 0 0 8px;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8a719f;
}

.panel--question-topic h3,
.panel--question-story h3,
.panel--question-takeaway h3 {
  margin-bottom: 10px;
}

.question-story-item + .question-story-item {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(123, 98, 156, 0.14);
}

.question-story-item__label {
  margin: 0 0 6px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8a719f;
}

.question-story-item__body,
.question-takeaway__lead,
.question-takeaway__advice {
  margin: 0;
  line-height: 1.75;
}

.question-takeaway__lead {
  font-size: 1rem;
  color: #2d2740;
}

.question-takeaway__advice {
  margin-top: 10px;
  color: #5a4c74;
}

.energy-panel--subtle {
  max-width: 760px;
  margin-inline: auto;
}

.retention-panel {
  max-width: 760px;
  margin-inline: auto;
  text-align: center;
}

.retention-panel h3 {
  margin-bottom: 10px;
}

.retention-panel__stats {
  display: grid;
  gap: 4px;
}

.retention-panel__stat {
  margin: 0;
  color: #4e4565;
  font-weight: 600;
}

.retention-panel__soft,
.retention-panel__unlock,
.retention-panel__cta-copy {
  margin: 10px 0 0;
  color: #5d5175;
  line-height: 1.7;
}

.retention-panel__unlock {
  color: #4a3f67;
  font-weight: 600;
}

.retention-panel__cta {
  margin-top: 12px;
  display: grid;
  justify-items: center;
  gap: 10px;
}

.retention-panel__save-btn {
  min-width: 160px;
}

.phase-panel {
  max-width: 760px;
  margin-inline: auto;
  text-align: center;
}

.phase-panel h3 {
  margin-bottom: 10px;
}

.phase-panel__label {
  margin: 0;
  color: #4e4565;
  font-weight: 600;
}

.phase-panel__desc {
  margin: 10px 0 0;
  color: #5d5175;
  line-height: 1.7;
}

.energy-balance {
  display: grid;
  gap: 16px;
}

.energy-balance__title {
  margin: 0;
  text-align: center;
  color: #322e4d;
  letter-spacing: 0.01em;
}

.energy-balance__chart-card {
  position: relative;
  overflow: visible;
  border-radius: clamp(28px, 4vw, 34px);
  border: 1px solid rgba(255, 255, 255, 0.56);
  padding: clamp(16px, 3.6vw, 24px);
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.84) 0%, rgba(252, 251, 255, 0.78) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.66),
    inset 0 -14px 24px rgba(248, 244, 255, 0.34),
    0 18px 36px rgba(81, 66, 117, 0.12);
  backdrop-filter: blur(10px);
}

.energy-balance__chart-card::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.48) 0%, rgba(255, 255, 255, 0) 46%);
}

.energy-balance__chart-wrap {
  position: relative;
  width: min(100%, 560px);
  margin-inline: auto;
  aspect-ratio: 1;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 28px;
  padding: clamp(26px, 5vw, 38px) clamp(44px, 9vw, 62px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
  box-sizing: border-box;
}

.energy-radar {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}

.energy-radar__grid-ring {
  fill: none;
  stroke: rgba(125, 115, 160, 0.38);
  stroke-width: 0.72;
}

.energy-radar__axis {
  stroke: rgba(125, 115, 160, 0.3);
  stroke-width: 0.62;
}

#energyRadarGlow {
  fill: url(#energyRadarFillGradient);
  opacity: 0.34;
  filter: url(#energyRadarBlur);
  transition: points 0.42s ease;
}

#energyRadarShape {
  fill: url(#energyRadarFillGradient);
  stroke: rgba(255, 255, 255, 0.88);
  stroke-width: 1.05;
  opacity: 0.88;
  transition: points 0.42s ease;
}

.energy-radar__dot {
  fill: rgba(248, 246, 255, 0.95);
  stroke: rgba(188, 171, 233, 0.85);
  stroke-width: 1.2;
  filter: drop-shadow(0 0 6px rgba(219, 201, 255, 0.48));
  transition: cx 0.42s ease, cy 0.42s ease;
}

.energy-radar__label {
  position: absolute;
  color: #4e476a;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.45);
}

.energy-radar__label--top {
  top: 6px;
  left: 50%;
  transform: translate(-50%, 0);
}

.energy-radar__label--right {
  top: 50%;
  right: 8px;
  transform: translate(0, -50%);
}

.energy-radar__label--bottom {
  left: 50%;
  bottom: 6px;
  transform: translate(-50%, 0);
}

.energy-radar__label--left {
  top: 50%;
  left: 8px;
  transform: translate(0, -50%);
}

.energy-interpretation {
  margin-top: 18px;
  text-align: center;
  font-size: 15px;
  line-height: 1.55;
  color: rgba(40, 35, 70, 0.75);
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

@media (max-width: 560px) {
  .energy-balance__chart-card {
    padding: 14px 10px 18px;
  }

  .energy-balance__chart-wrap {
    border-radius: 22px;
    padding: 24px 34px;
  }

  .energy-radar__label {
    font-size: 0.79rem;
  }

  .energy-radar__label--top {
    top: 9px;
  }

  .energy-radar__label--bottom {
    bottom: 9px;
  }

  .energy-radar__label--right {
    right: 8px;
  }

  .energy-radar__label--left {
    left: 8px;
  }
}

.deeper-section + .deeper-section {
  margin-top: 14px;
}

body.is-modal-open {
  overflow: hidden;
}

.card-sheet-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  align-items: end;
  padding:
    max(10px, env(safe-area-inset-top, 0px))
    10px
    max(10px, env(safe-area-inset-bottom, 0px));
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.card-sheet-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.card-sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(14, 12, 26, 0.45);
}

.card-sheet {
  position: relative;
  border-radius: 20px 20px 0 0;
  width: min(100%, 520px);
  max-height: calc(100vh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 20px);
  max-height: calc(100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 20px);
  padding: 10px 14px 14px;
  background: linear-gradient(180deg, #f7f3ff 0%, #f5efff 100%);
  box-shadow: 0 -16px 30px rgba(31, 21, 52, 0.24);
  transform: translateY(16px);
  transition: transform 0.2s ease;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.card-sheet-overlay.is-open .card-sheet {
  transform: translateY(0);
}

.card-sheet-close {
  border: 0;
  background: rgba(65, 53, 91, 0.12);
  color: #40335b;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  margin-left: auto;
  display: grid;
  place-items: center;
}

.card-sheet-media-wrap {
  display: flex;
  justify-content: center;
  max-height: min(42dvh, 360px);
}

.card-sheet-media {
  width: auto;
  max-width: min(64vw, 260px);
  height: min(42dvh, 360px);
  aspect-ratio: 3 / 5;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.card-sheet-title {
  text-align: center;
  margin: 10px 0 8px;
  font-weight: 600;
  color: #3d3452;
}

.card-sheet-meaning-meta {
  margin: 0 0 8px;
  text-align: center;
  font-size: 0.86rem;
  color: rgba(61, 52, 82, 0.78);
}

.card-sheet-actions {
  display: grid;
  gap: 10px;
}

.card-sheet-actions .primary,
.card-sheet-actions .ghost {
  width: 100%;
  text-align: center;
}

body[data-page='reading'] .primary:disabled {
  opacity: 0.6;
}

body[data-page='reading'] .ghost {
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(81, 58, 111, 0.2);
  color: #54496a;
  background: rgba(255, 255, 255, 0.7);
}

@media (max-width: 768px) {
  .question-intention {
    padding: 16px;
  }

  .question-intention__steps {
    grid-template-columns: 1fr;
  }

  .question-step {
    font-size: 0.92rem;
  }

  body[data-page='reading'] .full-summary-grid {
    grid-template-columns: 1fr;
  }

  .reading-intro__context {
    font-size: 0.96rem;
  }

  .reading-spread-grid {
    gap: 14px 10px;
  }

  .spread-label {
    font-size: 0.83rem;
  }

  body[data-page='reading'] .action-row {
    justify-items: stretch;
  }

  body[data-page='reading'] #saveBtn {
    order: 1;
  }

  body[data-page='reading'] #shareBtn {
    order: 2;
  }

  body[data-page='reading'] #newReadingBtn {
    order: 3;
    width: 72px;
    height: 72px;
    border-radius: 999px;
    margin: 4px auto 0;
    padding: 0;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #4f4566;
    border: 1px solid rgba(188, 158, 220, 0.45);
    background: linear-gradient(135deg, #e8efff 0%, #eddfff 52%, #ffdced 100%);
    box-shadow:
      0 10px 22px rgba(126, 96, 170, 0.14),
      0 2px 6px rgba(255, 255, 255, 0.35) inset;
  }

  body[data-page='reading'] #newReadingBtn:hover:not(:disabled) {
    background: linear-gradient(135deg, #edf3ff 0%, #f1e5ff 52%, #ffe3f1 100%);
    box-shadow:
      0 12px 24px rgba(126, 96, 170, 0.18),
      0 2px 6px rgba(255, 255, 255, 0.42) inset;
    transform: translateY(-1px);
  }

  body[data-page='reading'] #newReadingBtn:active:not(:disabled) {
    background: linear-gradient(135deg, #dde7ff 0%, #e6d6fb 52%, #ffd3e8 100%);
    box-shadow:
      0 6px 14px rgba(126, 96, 170, 0.14),
      0 1px 3px rgba(255, 255, 255, 0.28) inset;
    transform: scale(0.97);
  }
}

@keyframes readingFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* -------------------------------------------------------------------------- */
/* Unified mobile-first mystical app shell                                     */
/* -------------------------------------------------------------------------- */
:root {
  --mystic-top: #cfa5e5;
  --mystic-mid: #e7a7c8;
  --mystic-bottom: #a8c6f0;
  --mystic-card: rgba(255, 255, 255, 0.95);
  --mystic-text: #332f42;
  --mystic-muted: #7f778f;
  --mystic-shadow: 0 14px 34px rgba(70, 50, 105, 0.16);
  --mystic-radius: 28px;
  --page-card-padding: 24px;
}

body {
  font-family: 'Inter', 'SF Pro Text', 'DM Sans', system-ui, -apple-system, sans-serif;
  color: var(--mystic-text);
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 255, 255, 0.42), rgba(255, 255, 255, 0) 46%),
    radial-gradient(circle at 10% 16%, rgba(255, 255, 255, 0.45) 0 1px, transparent 1px),
    radial-gradient(circle at 82% 18%, rgba(255, 255, 255, 0.36) 0 1px, transparent 1px),
    radial-gradient(circle at 35% 74%, rgba(255, 255, 255, 0.28) 0 1.2px, transparent 1.2px),
    linear-gradient(180deg, var(--mystic-top) 0%, var(--mystic-mid) 50%, var(--mystic-bottom) 100%);
  background-attachment: fixed;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: 0.06;
  background-image: radial-gradient(rgba(255, 255, 255, 0.92) 0.5px, transparent 0.5px);
  background-size: 3px 3px;
}

.site-header {
  max-width: 420px;
  width: calc(100% - 2rem);
  margin: calc(10px + env(safe-area-inset-top, 0px)) auto 0;
  border-radius: var(--mystic-radius);
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(197, 177, 220, 0.4);
  backdrop-filter: saturate(130%) blur(8px);
  box-shadow: var(--mystic-shadow);
  padding: 14px 16px;
  display: grid;
  grid-template-columns: 38px 1fr 38px;
  gap: 8px;
  z-index: 300;
}

.logo-text,
.header-title {
  font-family: 'Playfair Display', 'Cormorant Garamond', Georgia, serif;
}

.logo-text {
  letter-spacing: 0.04em;
  text-transform: none;
  color: #57496e;
  font-size: 20px;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.7);
}

.header-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  color: #413755;
  letter-spacing: 0.02em;
  text-align: center;
  align-self: center;
  white-space: normal;
  overflow-wrap: anywhere;
}

.header-menu-toggle {
  display: inline-flex;
}

.header-menu-toggle,
.mobile-menu-toggle {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(160, 132, 196, 0.28);
}

.mobile-menu-toggle .bar {
  background: #544873;
}

.nav-panel {
  inset: calc(100% + 10px) 0 auto;
  border-radius: var(--mystic-radius);
  border: 1px solid rgba(168, 137, 196, 0.24);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--mystic-shadow);
  z-index: 350;
}

.nav-link,
.nav-link.active,
.nav-link:hover {
  color: #4a3f61;
  background: rgba(238, 230, 248, 0.7);
  border-color: rgba(161, 136, 196, 0.22);
}

.lang-btn,
.nav-meta,
.divider {
  color: #655a79;
}

.page-shell,
.page-meanings {
  width: 100%;
  margin: 0 auto;
  padding: calc(var(--nav-height) + 22px) 14px calc(env(safe-area-inset-bottom, 0px) + 22px);
}

.section-block,
.board-page .board-shell,
.panel,
.feature-card,

.faq-list details,
.hero-visual-panel,
.result-card,
.summary,
.search-result a,
.featured-link-item,
.category-card,
.helper-card,
.suit-card,
.guide-card,
.faq-item,
.related-card a,
.stat-block,
.hero-card-count,
.highlight-card,
.spread-card,
.meaning-card {
  background: var(--mystic-card);
  border: 1px solid rgba(197, 177, 220, 0.4);
  color: var(--mystic-text);
  border-radius: var(--mystic-radius);
  box-shadow: var(--mystic-shadow);
  padding: var(--page-card-padding);
}


.brand-title,
.section-heading h2,
h1,
h2,
h3,
.reading-nav-title,
body[data-page='reading'] h1#readingTitle,
.category-title,
.result-title {
  font-family: 'Playfair Display', 'Cormorant Garamond', Georgia, serif;
  color: #3d344f;
  letter-spacing: 0.03em;
}

p,
.tagline,
.intro,
.section-heading p,
.hero-subtext,
.card-summary,
.category-desc,
.helper-desc,
.faq-list p,
.result-summary,
.board-helper,
.sub-instruction,
.hint,
.meta-badge,
.keywords,
.breadcrumbs,
.stat-desc,
.stat-label {
  color: var(--mystic-muted);
}

.btn,
.primary,
.btn-primary,
body[data-page='reading'] .primary {
  border-radius: 22px;
  background: linear-gradient(120deg, #7ca7ff, #df88bc);
  color: var(--color-text-inverse);
  border: 0;
  box-shadow: 0 10px 24px rgba(126, 96, 170, 0.28);
}

.btn:hover,
.primary:hover,
.btn-primary:hover {
  transform: translateY(-2px);
}

.btn:active,
.primary:active,
.btn-primary:active {
  transform: scale(0.97);
}

.ghost,
.btn-secondary,
.chip,
.input,
.search-input,
details,
.details,
body[data-page='reading'] .ghost {
  background: rgba(255, 255, 255, 0.75);
  color: #54496a;
  border: 1px solid rgba(168, 137, 196, 0.3);
  border-radius: 20px;
}

.input:focus,
.search-input:focus-within {
  outline: none;
  border-color: #bc9edc;
  box-shadow: 0 0 0 3px rgba(189, 158, 220, 0.2);
}

.card,
.card-slot,
.featured-card img,
.tarot-card-img--hero,
.tarot-card-img--thumb,
.card-art-img {
  border-radius: 18px;
  box-shadow: 0 12px 22px rgba(74, 56, 102, 0.2);
}

.site-footer {
  margin: 14px auto 0;
  border-radius: 24px 24px 0 0;
  border: 0;
  background: rgba(255, 255, 255, 0.7);
  color: #665b7b;
}

@media (min-width: 421px) {
  .reading-experience {
    padding-left: 16px;
    padding-right: 16px;
  }
}

@media (min-width: 768px) {
  .reading-experience {
    padding-left: 24px;
    padding-right: 24px;
  }

  .reading-card {
    max-width: 900px;
    padding: 28px;
  }

  .tarot-card-img--hero,
  .card-art-img {
    width: min(420px, 100%);
    max-width: 100%;
    height: auto;
  }
}

@media (min-width: 1024px) {
  .reading-experience {
    padding-top: calc(env(safe-area-inset-top, 0px) + 28px);
    padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 32px);
  }

  .reading-card {
    max-width: 1100px;
    padding: 34px;
  }

  .reading-content {
    gap: 16px;
  }

  body[data-page='reading'] h1#readingTitle {
    font-size: 40px;
  }
}


@media (min-width: 768px) {
  .meta-row {
    gap: 13px;
  }
}

@media (min-width: 1024px) {
  .meta-row {
    gap: 14px;
  }

  .meta-group--identity {
    flex-wrap: nowrap;
  }
}


@media (min-width: 768px) {
  .topic-copy-lead {
    font-size: 1.12em;
  }
}

@media (min-width: 1024px) {
  .topic-copy {
    line-height: 1.72;
  }

  .topic-copy-lead {
    font-size: 1.16em;
    font-weight: 700;
  }
}

/* cohesive floating nav card layout */
header {
  padding-top: calc(env(safe-area-inset-top, 0px) + 8px);
}

.site-header {
  width: min(1200px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  height: auto;
  overflow: visible;
}

.nav-card-top {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 38px;
  align-items: center;
  gap: 8px;
}

.nav-panel {
  position: static;
  inset: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  padding: 0;
  margin: 0;
  border: 0;
  box-shadow: none;
  background: transparent;
  max-height: none;
  opacity: 1;
  pointer-events: auto;
  overflow: visible;
}

.nav-links {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.nav-link {
  display: block;
  width: 100%;
}

.nav-meta {
  display: flex;
  align-items: center;
  justify-content: center;
}

.language-toggle {
  padding-left: 0;
  border-left: 0;
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(168, 137, 196, 0.3);
}

.lang-btn {
  border: 0;
  border-radius: 999px;
  padding: 6px 10px;
  min-width: 44px;
}

.lang-btn.active {
  background: rgba(124, 167, 255, 0.25);
  color: #453c5b;
}

.lang-btn:focus-visible,
.mobile-menu-toggle:focus-visible,
.nav-link:focus-visible {
  outline: 2px solid #7a66a4;
  outline-offset: 2px;
}

@media (max-width: 1023px) {
  .header-menu-toggle {
    display: inline-flex;
  }

  .nav-panel {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 12px;
    z-index: 70;
    border-top: 1px solid rgba(168, 137, 196, 0.24);
    padding: 10px;
    background: var(--mystic-card);
    border: 1px solid rgba(197, 177, 220, 0.4);
    border-radius: var(--mystic-radius);
    box-shadow: var(--mystic-shadow);
    max-height: calc(100vh - var(--nav-height, 72px) - 24px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav-panel.is-open {
    display: grid;
  }

  body.nav-open {
    overflow: auto;
  }
}

@media (min-width: 1024px) {
  .header-menu-toggle {
    display: none;
  }

  .nav-panel {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 12px;
  }

  .nav-meta {
    justify-content: flex-end;
    align-self: start;
  }
}

.header-title {
  overflow-wrap: normal;
  word-break: keep-all;
}

.mobile-menu-toggle {
  flex-direction: column;
}

@media (max-width: 1023px) {
  .nav-panel {
    inset: auto;
    width: 100%;
  }
}

@media (max-width: 1023px) {
  .site-header {
    position: relative;
    z-index: 60;
    grid-template-columns: none;
  }

  .nav-panel,
  .nav-panel.is-open {
    transform: none;
    max-width: none;
    opacity: 1;
    pointer-events: auto;
    transition: none;
  }
}

@media (min-width: 1024px) {
  .site-header {
    max-width: none;
    width: min(1200px, calc(100vw - 32px));
  }
}

/* -------------------------------------------------------------------------- */
/* Responsive shell tokens + desktop/tablet expansion                         */
/* -------------------------------------------------------------------------- */
:root {
  --bp-sm: 480px;
  --bp-md: 768px;
  --bp-lg: 1024px;
  --bp-xl: 1280px;
}

/* mobile first */
.site-header,
.page-shell,
.page-meanings,
.site-footer {
  width: min(420px, calc(100vw - 32px));
}

.page-shell,
.page-meanings {
  max-width: 420px;
  padding: calc(var(--nav-height) + 18px) 16px calc(env(safe-area-inset-bottom, 0px) + 22px);
}

/* tablet */
@media (min-width: 768px) {
  .site-header,
  .page-shell,
  .page-meanings,
  .site-footer {
    width: min(980px, calc(100vw - 48px));
  }

  body[data-page='home'] .page-shell {
    width: 100%;
    max-width: none;
    padding-left: 0;
    padding-right: 0;
  }

  .home-grid {
    max-width: 980px;
    padding-left: 24px;
    padding-right: 24px;
  }

  .page-shell,
  .page-meanings {
    max-width: 980px;
    padding: calc(var(--nav-height) + 22px) 22px 72px;
  }

  .section-block {
    padding: 24px;
    margin-bottom: 20px;
  }

  .brand-title {
    font-size: clamp(2.45rem, 4vw, 3.5rem);
    line-height: 1.08;
  }

  .section-heading h2,
  h1 {
    font-size: clamp(2rem, 2.8vw, 2.5rem);
  }
}

/* desktop */
@media (min-width: 1024px) {
  .site-header,
  .page-shell,
  .page-meanings,
  .site-footer {
    width: min(1160px, calc(100vw - 64px));
  }

  body[data-page='home'] .page-shell {
    width: 100%;
    max-width: none;
    padding-left: 0;
    padding-right: 0;
  }

  .home-grid {
    max-width: 1160px;
    padding-left: 32px;
    padding-right: 32px;
  }

  .site-header {
    padding: 12px 18px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
  }

  .nav-card-top {
    display: none;
  }

  .nav-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex: 0 0 auto;
  }

  .nav-panel,
  .nav-panel.is-open {
    display: flex;
    align-items: center;
    flex: 1;
    gap: 14px;
  }

  .nav-links {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    flex: 1;
  }

  .nav-link {
    width: auto;
    text-align: center;
    white-space: nowrap;
    padding: 9px 12px;
  }

  .nav-meta {
    justify-content: flex-end;
    flex: 0 0 auto;
  }

  .page-shell,
  .page-meanings {
    max-width: 1160px;
    padding: calc(var(--nav-height) + 26px) 28px 92px;
  }

  body[data-page='home'] .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
    padding-top: 26px;
  }

  body[data-page='home'] .hero-copy {
    max-width: 980px;
    margin: 0 auto;
    text-align: center;
    align-items: center;
  }

  body[data-page='home'] .brand-title {
    font-size: clamp(3.1rem, 4.2vw, 4.2rem);
    line-height: 1.03;
    max-width: 24ch;
    margin-left: auto;
    margin-right: auto;
  }

  body[data-page='home'] .tagline,
  body[data-page='home'] .intro {
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
  }

  body[data-page='home'] .cta-group {
    justify-content: center;
    margin-left: auto;
    margin-right: auto;
    max-width: 520px;
  }

  .section-block {
    padding: 28px;
    margin-bottom: 24px;
  }
}

@media (min-width: 1280px) {
  .site-header,
  .page-shell,
  .page-meanings,
  .site-footer {
    width: min(1200px, calc(100vw - 80px));
  }

  .home-grid {
    max-width: 1200px;
    padding-left: 36px;
    padding-right: 36px;
  }

  .page-shell,
  .page-meanings {
    max-width: 1200px;
    padding-left: 34px;
    padding-right: 34px;
  }

  .section-block {
    padding: 30px;
  }
}

/* -------------------------------------------------------------------------- */
/* Thai locale typography + spacing normalization                               */
/* -------------------------------------------------------------------------- */
html[lang='th'] body {
  font-family: 'Noto Sans Thai', 'Sarabun', 'Prompt', 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  line-height: 1.68;
  word-break: normal;
}

html[lang='th'] .brand-title,
html[lang='th'] .section-heading h2,
html[lang='th'] h1,
html[lang='th'] h2,
html[lang='th'] h3,
html[lang='th'] .reading-nav-title,
html[lang='th'] body[data-page='reading'] h1#readingTitle,
html[lang='th'] .category-title,
html[lang='th'] .result-title,
html[lang='th'] .header-title,
html[lang='th'] .logo-text {
  font-family: 'Noto Sans Thai', 'Sarabun', 'Prompt', 'Inter', system-ui, sans-serif;
  letter-spacing: 0;
  line-height: 1.3;
}

html[lang='th'] .tagline,
html[lang='th'] .intro,
html[lang='th'] .topic-copy,
html[lang='th'] .card-summary,
html[lang='th'] .result-summary,
html[lang='th'] .section-heading p,
html[lang='th'] .faq-list p {
  line-height: 1.75;
}

html[lang='th'] .eyebrow,
html[lang='th'] .lang-btn,
html[lang='th'] .chip,
html[lang='th'] .meta-badge,
html[lang='th'] .keywords,
html[lang='th'] .stat-label {
  letter-spacing: 0;
}

html[lang='th'] .eyebrow {
  text-transform: none;
}

html[lang='th'] .nav-link,
html[lang='th'] .btn,
html[lang='th'] .btn-primary,
html[lang='th'] .btn-secondary,
html[lang='th'] .chip,
html[lang='th'] .color-chip,
html[lang='th'] .meta-badge,
html[lang='th'] .lang-btn {
  line-height: 1.35;
}

html[lang='th'] .meta-group {
  align-items: stretch;
}

html[lang='th'] .topic-copy-lead {
  line-height: 1.65;
}

@media (min-width: 768px) {
  html[lang='th'] .brand-title {
    line-height: 1.2;
  }
}

@media (min-width: 1024px) {
  html[lang='th'] .topic-copy {
    line-height: 1.75;
  }
}

/* mobile navbar compaction + always-visible language switcher */
@media (max-width: 1023px) {
  .site-header {
    padding: 10px 12px;
    gap: 8px;
  }

  .nav-card-top {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 6px;
    min-width: 0;
  }

  .header-menu-toggle,
  .mobile-menu-toggle {
    width: 34px;
    height: 34px;
  }

  .header-title {
    flex: 1 1 auto;
    min-width: 0;
    margin-right: auto;
    font-size: clamp(15px, 4.1vw, 17px);
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .language-toggle--mobile {
    display: inline-flex;
    align-items: center;
    flex-wrap: nowrap;
    margin-left: 0;
    padding: 2px 4px;
    gap: 4px;
    white-space: nowrap;
  }

  .language-toggle--mobile .lang-btn {
    min-width: 32px;
    padding: 4px 7px;
    font-size: 12px;
    line-height: 1;
  }

  .language-toggle--mobile .divider {
    font-size: 11px;
  }

  .nav-meta {
    display: none;
  }

  .language-toggle--menu {
    display: none;
  }

  .nav-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    border: 0;
    padding: 0;
    background: rgba(0, 0, 0, 0.15);
    z-index: 55;
  }

  .nav-backdrop.is-open {
    display: block;
  }
}

@media (max-width: 420px) {
  .site-header {
    width: calc(100vw - 20px);
    padding: 8px 10px;
  }

  .header-title {
    font-size: clamp(14px, 4vw, 16px);
  }

  .language-toggle--mobile {
    padding: 1px 3px;
    gap: 2px;
  }

  .language-toggle--mobile .lang-btn {
    min-width: 28px;
    padding: 3px 5px;
    font-size: 11px;
  }
}

@media (min-width: 1024px) {
  .language-toggle--mobile {
    display: none;
  }

  .language-toggle--menu {
    display: inline-flex;
  }
}

/* mobile layout guardrails: full page card content fit + single-row navbar brand */
body[data-page='full'] .section-block,
body[data-page='overall'] .section-block {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

body[data-page='full'] .section-block > *,
body[data-page='overall'] .section-block > * {
  min-width: 0;
}

body[data-page='full'] h1,
body[data-page='overall'] h1 {
  margin: 0;
  overflow-wrap: break-word;
}

body[data-page='full'] #overall-flow,
body[data-page='overall'] #overall-flow {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

body[data-page='full'] .overall-cta-wrapper,
body[data-page='overall'] .overall-cta-wrapper,
body[data-page='full'] .board-actions,
body[data-page='overall'] .board-actions {
  width: 100%;
  margin: 0;
}

body[data-page='full'] #overall-deal-shuffle,
body[data-page='overall'] #overall-deal-shuffle,
body[data-page='full'] #overall-continue,
body[data-page='overall'] #overall-continue {
  width: 100%;
}

body[data-page='full'] .board-toolbar,
body[data-page='overall'] .board-toolbar {
  width: 100%;
  min-width: 0;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 12px;
}

body[data-page='full'] #overall-toolbar,
body[data-page='overall'] #overall-toolbar {
  justify-content: center;
}

body[data-page='full'] #overall-counter,
body[data-page='overall'] #overall-counter {
  min-width: 80px;
}

body[data-page='full'] #overall-counter,
body[data-page='overall'] #overall-counter {
  flex: 0 0 auto;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .nav-brand {
    text-decoration: none;
    white-space: nowrap;
  }

  .nav-logo {
    display: none;
  }
}


@media (min-width: 768px) {
  .card-sheet-overlay {
    align-items: center;
    padding: max(16px, env(safe-area-inset-top, 0px));
  }

  .card-sheet {
    width: min(420px, 92vw);
    margin: 0 auto;
    border-radius: 20px;
    padding-bottom: 20px;
    max-height: min(90vh, 760px);
    max-height: min(90dvh, 760px);
  }
}

/* Navbar action layout */
.site-header {
  position: relative;
}

.nav-actions {
  display: inline-flex;
  align-items: center;
  gap: 0;
}

.nav-backdrop {
  display: none;
}

.nav-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Meanings page layout regrouping */
.meaning-arcana {
  display: grid;
  gap: 14px;
}

.major-arcana-feature {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: var(--mystic-radius);
  background: var(--mystic-card);
  border: 1px solid rgba(197, 177, 220, 0.4);
  box-shadow: var(--mystic-shadow);
}

.major-arcana-feature h1 {
  margin: 0;
}

.major-arcana-preview {
  width: 100%;
  max-width: 320px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.major-arcana-desc {
  margin: 0;
  color: var(--color-text-muted);
}

.minor-arcana-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.minor-arcana-heading h2 {
  margin: 0;
}

.minor-arcana-heading .eyebrow {
  margin: 0;
}

.minor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.minor-grid .category-card {
  grid-template-columns: 1fr;
  align-items: start;
  gap: 10px;
}

.minor-grid .category-icon {
  width: 42px;
  height: 42px;
}

.minor-grid .category-title {
  font-size: 16px;
}

.minor-grid .category-desc {
  font-size: 14px;
}

.minor-cta {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gold);
}

.ritual-cta--deal {
  min-width: 250px;
  font-size: 1.08rem;
  padding: 14px 28px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-deck-stack {
  position: relative;
  width: min(44vw, 190px);
  aspect-ratio: 1568 / 2720;
  min-width: 118px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-deck-stack--center {
  margin: 0 auto;
  pointer-events: none;
  z-index: 2;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-deck-stack.is-shuffling {
  animation: dailyDeckShuffle 0.2s cubic-bezier(0.32, 0.72, 0.16, 1);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-deck-layer {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  transform: translate(var(--dx, 0), var(--dy, 0)) rotate(var(--dr, 0deg));
  z-index: var(--z, 1);
  background:
    radial-gradient(130% 95% at 20% 16%, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.04) 35%, transparent 66%),
    var(--daily-deck-back-url, linear-gradient(160deg, rgba(35, 46, 85, 0.92), rgba(52, 44, 86, 0.95)));
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow:
    0 10px 24px rgba(10, 16, 42, 0.25),
    0 3px 10px rgba(10, 16, 42, 0.2);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-entry-helper {
  margin: 0;
  text-align: center;
  color: rgba(58, 56, 92, 0.8);
  font-size: 0.95rem;
  line-height: 1.45;
  width: 100%;
  max-width: 100%;
  padding: 0 8px;
  box-sizing: border-box;
  overflow-wrap: anywhere;
}

body[data-page='reading'][data-reading-mode='daily'][data-daily-phase='idle'] .action-row,
body[data-page='reading'][data-reading-mode='daily'][data-daily-phase='gathering'] .action-row,
body[data-page='reading'][data-reading-mode='daily'][data-daily-phase='stacked'] .action-row,
body[data-page='reading'][data-reading-mode='daily'][data-daily-phase='dealing'] .action-row,
body[data-page='reading'][data-reading-mode='daily'] .action-row[aria-busy='true'] {
  display: none;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-reading-stage {
  display: grid;
  gap: 12px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-reading-stage--motion {
  gap: 16px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-board {
  position: relative;
  min-height: clamp(300px, 58vw, 440px);
  display: grid;
  place-items: center;
  padding: clamp(10px, 2vw, 18px);
  overflow: hidden;
  perspective: 800px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-board--single {
  min-height: clamp(360px, 68vw, 540px);
  padding-block: clamp(18px, 4vw, 34px);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-board--triple {
  min-height: clamp(280px, 46vw, 380px);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-layout {
  position: relative;
  z-index: 1;
  width: min(100%, 900px);
  display: grid;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 2.4vw, 24px);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-layout--single {
  width: min(100%, 420px);
  grid-template-columns: minmax(0, min(66vw, 360px));
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-layout--triple {
  width: min(100%, 660px);
  grid-template-columns: repeat(3, minmax(0, min(24vw, 188px)));
  gap: clamp(10px, 2vw, 18px);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-slot {
  position: relative;
  aspect-ratio: 1568 / 2720;
  width: 100%;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-slot-label {
  position: absolute;
  left: 50%;
  bottom: -30px;
  transform: translateX(-50%);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(58, 56, 92, 0.72);
  white-space: nowrap;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-card {
  position: absolute;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: hidden;
  border-radius: 16px;
  box-shadow:
    0 18px 34px rgba(10, 16, 42, 0.2),
    0 6px 18px rgba(10, 16, 42, 0.16);
  transform:
    translate(-50%, -50%)
    translate(calc(var(--deal-x, 0px) + var(--stack-offset-x, 0px)), calc(var(--deal-y, 0px) + var(--stack-offset-y, 0px)))
    rotate(var(--deal-rotation-current, 0deg))
    scale(var(--deal-scale, 1));
  transition:
    transform 0.21s cubic-bezier(0.22, 0.65, 0.18, 1),
    opacity 0.22s ease;
  z-index: 3;
  will-change: transform, opacity;
  transform-style: preserve-3d;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-card--single {
  border-radius: 18px;
  box-shadow:
    0 22px 42px rgba(10, 16, 42, 0.22),
    0 8px 22px rgba(10, 16, 42, 0.14);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-card.is-dealt {
  z-index: 4;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-face {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  transition: transform 0.5s cubic-bezier(0.34, 1.4, 0.64, 1);
  backface-visibility: hidden;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-face--back {
  transform: rotateY(0deg);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-face--front {
  transform: rotateY(180deg);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-card.is-revealed .daily-motion-face--back {
  transform: rotateY(-180deg);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-card.is-revealed .daily-motion-face--front {
  transform: rotateY(0deg);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-face .card-back,
body[data-page='reading'][data-reading-mode='daily'] .daily-motion-art,
body[data-page='reading'][data-reading-mode='daily'] .daily-motion-art .card-art-img {
  width: 100%;
  height: 100%;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-face .card-back,
body[data-page='reading'][data-reading-mode='daily'] .daily-motion-art .card-art-img {
  object-fit: cover;
  border-radius: inherit;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-art {
  min-height: 0;
  margin: 0;
  display: block;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-board-panel {
  width: min(100%, 760px);
  margin: 0 auto;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-board-panel .daily-result-art {
  min-height: clamp(220px, 54vw, 360px);
  margin: 4px 0 10px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-board-panel .daily-result-art .card-art-img {
  width: min(320px, 100%);
  aspect-ratio: 1568 / 2720;
  object-fit: cover;
  background: rgba(26, 33, 67, 0.12);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-reading-details {
  display: grid;
  gap: 12px;
  animation: dailyReadingFadeIn 0.15s ease both;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-reading-details--multi {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-reading-details--multi .daily-board-panel {
  width: 100%;
}

/* Daily result page polish: premium surface, clearer hierarchy, mobile readability */
body[data-page='reading'][data-reading-mode='daily'] .reading-card {
  border: 1px solid rgba(255, 255, 255, 0.58);
  box-shadow:
    0 22px 48px rgba(76, 54, 110, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

body[data-page='reading'][data-reading-mode='daily'] .reading-intro {
  margin-bottom: 18px;
  text-align: center;
}

body[data-page='reading'][data-reading-mode='daily'] h1#readingTitle {
  font-size: clamp(30px, 8.6vw, 38px);
  line-height: 1.15;
  letter-spacing: 0.01em;
}

body[data-page='reading'][data-reading-mode='daily'] .reading-intro__context {
  margin-top: 12px;
  font-size: clamp(0.98rem, 3.7vw, 1.06rem);
  line-height: 1.76;
  color: rgba(58, 48, 80, 0.82);
}

body[data-page='reading'][data-reading-mode='daily'] .reading-content {
  gap: 14px;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-motion-board {
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.52);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, rgba(252, 249, 255, 0.34) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 14px 32px rgba(64, 45, 98, 0.14);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-board-panel {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  background: linear-gradient(170deg, rgba(255, 255, 255, 0.82) 0%, rgba(250, 247, 255, 0.74) 100%);
  box-shadow: 0 12px 26px rgba(73, 50, 109, 0.1);
}

body[data-page='reading'][data-reading-mode='daily'] .daily-board-panel h2 {
  margin: 0;
  font-size: clamp(1.18rem, 4.9vw, 1.5rem);
  line-height: 1.34;
  color: #2e2740;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-board-panel .keywords {
  margin: 8px 0 0;
  color: rgba(73, 63, 97, 0.82);
  line-height: 1.55;
}

body[data-page='reading'][data-reading-mode='daily'] .daily-reading-details .panel p {
  line-height: 1.78;
  color: #3e3555;
}

body[data-page='reading'][data-reading-mode='daily'] .panel--internal-links {
  border-radius: 18px;
}

body[data-page='reading'][data-reading-mode='daily'] .panel--internal-links h3 {
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 0.98rem;
  letter-spacing: 0.03em;
  color: #3c3253;
}

body[data-page='reading'][data-reading-mode='daily'] .panel--internal-links ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

body[data-page='reading'][data-reading-mode='daily'] .panel--internal-links li a,
body[data-page='reading'][data-reading-mode='daily'] .panel--internal-links > p a {
  color: #4a3772;
  text-decoration: underline;
  text-decoration-color: rgba(74, 55, 114, 0.4);
  text-underline-offset: 3px;
}

body[data-page='reading'][data-reading-mode='daily'] #shareBtn {
  border-color: rgba(122, 92, 177, 0.4);
  background: linear-gradient(135deg, rgba(244, 237, 255, 0.96), rgba(255, 237, 245, 0.96));
  box-shadow: 0 10px 22px rgba(107, 79, 158, 0.14);
}

body[data-page='reading'][data-reading-mode='daily'] #reading-content > * + .panel--internal-links {
  margin-top: 4px;
}

@keyframes dailyDeckShuffle {
  0% {
    transform: translateX(0) rotate(0deg);
  }
  25% {
    transform: translateX(-4px) rotate(-0.7deg);
  }
  55% {
    transform: translateX(5px) rotate(0.7deg);
  }
  100% {
    transform: translateX(0) rotate(0deg);
  }
}

@keyframes dailyReadingFadeIn {
  from {
    opacity: 0;
    transform: translateY(3px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  body[data-page='reading'][data-reading-mode='daily'] .daily-deck-stack.is-shuffling {
    animation: none;
  }

  body[data-page='reading'][data-reading-mode='daily'] .daily-motion-card,
  body[data-page='reading'][data-reading-mode='daily'] .daily-motion-face {
    transition: none;
  }
}

@media (max-width: 720px) {
  body[data-page='reading'][data-reading-mode='daily'] .daily-motion-board {
    padding-inline: 6px;
  }

  body[data-page='reading'][data-reading-mode='daily'] .daily-motion-board--single {
    min-height: clamp(340px, 82vw, 500px);
  }

  body[data-page='reading'][data-reading-mode='daily'] .daily-motion-layout--triple {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: min(100%, 560px);
    gap: 8px;
  }

  body[data-page='reading'][data-reading-mode='daily'] .daily-motion-slot-label {
    bottom: -20px;
    font-size: 0.68rem;
    letter-spacing: 0.06em;
  }

  body[data-page='reading'][data-reading-mode='daily'] .daily-reading-details--multi {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  body[data-page='reading'][data-reading-mode='daily'] .action-row {
    margin-top: 22px;
    gap: 12px;
  }

  body[data-page='reading'][data-reading-mode='daily'] #shareBtn {
    order: 1;
  }

  body[data-page='reading'][data-reading-mode='daily'] #saveBtn {
    order: 2;
  }

  body[data-page='reading'][data-reading-mode='daily'] #newReadingBtn {
    order: 3;
  }
}

body[data-page='daily'] .board-topbar {
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

body[data-page='daily'] .board-header--daily {
  display: grid;
  justify-items: center;
  gap: 4px;
  margin-bottom: 4px;
}

body[data-page='daily'] .board-header--daily .eyebrow {
  margin: 0;
  letter-spacing: 0.08em;
  font-size: clamp(1.35rem, 2.4vw, 1.9rem);
  color: var(--mystic-text);
}

body[data-page='daily'] .board-header--daily .board-helper {
  margin: 0;
  font-size: clamp(0.8rem, 1.7vw, 0.92rem);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--mystic-muted);
}

body[data-page='daily'] .board-actions--daily {
  justify-content: center;
  width: min(100%, 440px);
  margin-inline: auto;
  gap: 12px;
}

body[data-page='daily'] .board-actions--daily .action-btn {
  min-width: 0;
  min-height: 46px;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 0.94rem;
  font-weight: 700;
  flex: 1 1 0;
}

body[data-page='daily'] .board-actions--daily .ritual-cta {
  line-height: 1;
  gap: 0;
}

body[data-page='daily'] #daily-deal-shuffle {
  color: #54496a;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(168, 137, 196, 0.3);
}

body[data-page='daily'] #daily-continue {
  color: var(--color-text-inverse);
  transition: all 0.3s ease;
}

body[data-page='daily'] #daily-continue:not(:disabled) {
  opacity: 1;
  background: linear-gradient(120deg, #7ca7ff 0%, #df88bc 100%);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 12px 30px rgba(126, 96, 170, 0.42);
  filter: saturate(1.1) brightness(1.02);
}

body[data-page='daily'] #daily-continue:disabled {
  opacity: 1;
  color: #958aa9;
  background: linear-gradient(135deg, #cbc5d5 0%, #c2bccf 100%);
  border: 1px solid rgba(122, 108, 156, 0.13);
  box-shadow: none;
}

body[data-page='daily'] #daily-board .card-slot {
  transition: transform 300ms ease-out, border-color 0.15s ease, box-shadow 0.15s ease, opacity 300ms ease-out;
}

body[data-page='daily'] #daily-board .card-slot.daily-appearing {
  opacity: 0;
}

body[data-page='full'] .full-board-shell {
  max-width: 980px;
  margin: 0 auto;
}

body[data-page='full'] .board-header,
body[data-page='full'] .full-flow,
body[data-page='full'] .overall-cta-wrapper,
body[data-page='full'] .board-actions {
  justify-content: center;
  text-align: center;
}

body[data-page='full'] .board-toolbar {
  justify-content: center;
  text-align: center;
}

body[data-page='full'] #overall-flow {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
  position: relative;
  min-height: 420px;
}

body[data-page='full'] .full-stage-copy,
body[data-page='full'] .full-selection-shell,
body[data-page='full'] #overall-toolbar,
body[data-page='full'] #overall-actions {
  width: min(100%, 820px);
}

body[data-page='full'] .full-stage-copy {
  display: grid;
  gap: 6px;
}

body[data-page='full'] .full-stage-copy h2 {
  margin: 0;
  font-size: clamp(1.5rem, 2.6vw, 2.15rem);
}

body[data-page='full'] .full-stage-copy p:last-child {
  margin: 0;
  color: rgba(247, 241, 255, 0.98);
  font-weight: 500;
}

body[data-page='full'] .full-selection-shell {
  display: grid;
  gap: 16px;
  position: relative;
  overflow: hidden;
}

body[data-page='full'] .full-stage-panel {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 28px;
  background:
    radial-gradient(circle at top, rgba(214, 195, 255, 0.2), rgba(214, 195, 255, 0) 38%),
    rgba(9, 14, 38, 0.64);
  box-shadow: 0 22px 60px rgba(7, 7, 16, 0.22);
}

body[data-page='full'] .full-stage-panel--deal {
  padding: 14px;
}

body[data-page='full'] .full-deal-orbit {
  min-height: 0;
  margin-bottom: 10px;
}

body[data-page='full'] .full-draw-board {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  align-items: start;
}

body[data-page='full'] .full-draw-board__slot {
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  padding: 4px;
  background: rgba(15, 22, 52, 0.68);
  width: 100%;
  aspect-ratio: 1568 / 2720;
  min-height: 0;
  display: block;
}

body[data-page='full'] .full-draw-board__slot:focus-visible,
body[data-page='full'] .full-draw-board__slot:hover {
  border-color: rgba(221, 191, 255, 0.62);
}

body[data-page='full'] .full-draw-board.is-picking .full-draw-board__slot {
  pointer-events: none;
}

body[data-page='full'] .full-draw-board.is-shuffling .full-draw-board__slot {
  pointer-events: none;
}

body[data-page='full'] .full-draw-board.is-clearing-spread .full-draw-board__slot {
  animation: fullSpreadClear 160ms cubic-bezier(0.32, 0, 0.66, 0.18) forwards;
  animation-delay: var(--clear-delay, 0ms);
}

body[data-page='full'] .full-draw-board.is-redealing-spread .full-draw-board__slot {
  opacity: 0;
  transform: translate3d(0, calc(var(--redeal-lift, 16px) * -1), 0) scale(0.965);
  animation: fullSpreadRedeal var(--redeal-duration, 300ms) cubic-bezier(0.18, 0.88, 0.24, 1) forwards;
  animation-delay: var(--redeal-delay, 0ms);
}

body[data-page='full'] .full-draw-board__slot.is-picked-confirm {
  animation: fullPickConfirm 200ms cubic-bezier(0.2, 0.9, 0.28, 1) forwards;
}

@media (prefers-reduced-motion: reduce) {
  body[data-page='full'] .full-draw-board.is-clearing-spread .full-draw-board__slot {
    animation-duration: 70ms;
  }

  body[data-page='full'] .full-draw-board.is-redealing-spread .full-draw-board__slot {
    animation-duration: 80ms;
    transform: translate3d(0, calc(var(--redeal-lift, 6px) * -1), 0) scale(0.99);
  }

  body[data-page='full'] .full-draw-board__slot.is-picked-confirm {
    animation-duration: 70ms;
  }
}

body[data-page='full'] .full-draw-board__img,
body[data-page='full'] .full-arrange-item__img {
  width: 100%;
  height: auto;
  aspect-ratio: 1568 / 2720;
  object-fit: contain;
  display: block;
}

body[data-page='full'] .full-deck-area {
  display: grid;
  gap: 10px;
  justify-items: center;
}

body[data-page='full'] .full-deck-area__hint {
  margin: 0;
  color: rgba(230, 222, 245, 0.82);
  font-size: 0.82rem;
}

body[data-page='full'] .full-draw-summary {
  display: block;
}

body[data-page='full'] .full-celtic-preview {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(4, minmax(36px, auto));
  gap: 6px;
}

body[data-page='full'] .full-celtic-preview__slot {
  border-radius: 10px;
  border: 1px solid rgba(208, 197, 238, 0.34);
  background: linear-gradient(165deg, rgba(34, 33, 58, 0.72), rgba(23, 27, 52, 0.72));
  min-height: 36px;
  display: grid;
  place-items: center;
  color: rgba(226, 216, 245, 0.82);
  box-shadow:
    inset 0 0 0 1px rgba(223, 206, 250, 0.12),
    0 4px 14px rgba(7, 8, 22, 0.24);
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease, background 220ms ease;
}

body[data-page='full'] .full-celtic-preview__slot.is-filled {
  border-color: rgba(226, 193, 255, 0.88);
  background: linear-gradient(160deg, rgba(112, 76, 171, 0.78), rgba(84, 53, 145, 0.74));
  box-shadow:
    inset 0 0 0 1px rgba(238, 214, 255, 0.34),
    0 10px 26px rgba(10, 10, 28, 0.34),
    0 0 0 1px rgba(209, 158, 255, 0.2);
}

body[data-page='full'] .full-celtic-preview__slot.is-latest {
  transform: translateY(-1px) scale(1.02);
  border-color: rgba(241, 221, 255, 0.96);
  background: linear-gradient(162deg, rgba(94, 50, 166, 0.94), rgba(66, 34, 130, 0.92));
  box-shadow:
    inset 0 0 0 1px rgba(244, 225, 255, 0.54),
    0 14px 30px rgba(11, 10, 30, 0.46),
    0 0 0 3px rgba(181, 129, 255, 0.2),
    0 0 24px rgba(173, 118, 255, 0.36);
}

body[data-page='full'] .full-celtic-preview__slot.is-next {
  border-color: rgba(244, 231, 255, 0.88);
  box-shadow:
    inset 0 0 0 1px rgba(243, 228, 255, 0.4),
    0 0 0 4px rgba(178, 137, 255, 0.12);
}

body[data-page='full'] .full-celtic-preview__slot.is-awaiting-card {
  transform: scale(1.04);
  border-color: rgba(244, 231, 255, 0.92);
  box-shadow:
    inset 0 0 0 1px rgba(243, 228, 255, 0.5),
    0 0 0 6px rgba(178, 137, 255, 0.16);
}

body[data-page='full'] .full-celtic-preview__order {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.96;
  font-weight: 600;
  color: rgba(244, 236, 255, 0.96);
}

body[data-page='full'] .full-celtic-preview__slot--present { grid-area: 2 / 2; }
body[data-page='full'] .full-celtic-preview__slot--challenge { grid-area: 2 / 2; transform: rotate(-8deg); }
body[data-page='full'] .full-celtic-preview__slot--above { grid-area: 1 / 2; }
body[data-page='full'] .full-celtic-preview__slot--past { grid-area: 2 / 1; }
body[data-page='full'] .full-celtic-preview__slot--below { grid-area: 3 / 2; }
body[data-page='full'] .full-celtic-preview__slot--future { grid-area: 2 / 3; }
body[data-page='full'] .full-celtic-preview__slot--advice { grid-area: 4 / 4; }
body[data-page='full'] .full-celtic-preview__slot--external { grid-area: 3 / 4; }
body[data-page='full'] .full-celtic-preview__slot--hopes { grid-area: 2 / 4; }
body[data-page='full'] .full-celtic-preview__slot--outcome { grid-area: 1 / 4; }

body[data-page='full'] .full-draw-flight-card {
  position: absolute;
  z-index: 6;
  border-radius: 12px;
  border: 1px solid rgba(240, 225, 255, 0.8);
  box-shadow:
    0 12px 32px rgba(7, 8, 24, 0.48),
    0 0 0 1px rgba(248, 239, 255, 0.5),
    0 0 30px rgba(178, 136, 255, 0.28);
  transform: translate3d(0, 0, 0) scale(1);
  opacity: 0;
  pointer-events: none;
  will-change: transform, opacity;
  overflow: hidden;
}

body[data-page='full'] .full-draw-flight-card.is-active {
  animation: fullCardFlight var(--flight-duration, 1000ms) cubic-bezier(0.22, 0.84, 0.22, 1) forwards;
}

body[data-page='full'] .full-draw-flight-card__img {
  width: 100%;
  height: 100%;
  display: block;
}

@keyframes fullCardFlight {
  0% {
    opacity: 0;
    transform: translate3d(0, 0, 0) scale(0.98) rotate(-1.5deg);
  }
  18% {
    opacity: 1;
    transform: translate3d(0, -10px, 0) scale(1.04) rotate(1deg);
  }
  100% {
    opacity: 0.2;
    transform: translate3d(var(--flight-x, 0), var(--flight-y, 0), 0) scale(var(--flight-scale, 0.8)) rotate(3deg);
  }
}

@keyframes fullSpreadClear {
  0% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
  }
  100% {
    opacity: 0.08;
    transform: translate3d(var(--clear-shift-x, 0), var(--clear-shift-y, 18px), 0) scale(0.9) rotate(1.8deg);
  }
}

@keyframes fullSpreadRedeal {
  0% {
    opacity: 0;
    transform: translate3d(0, calc(var(--redeal-lift, 16px) * -1), 0) scale(0.96);
  }
  70% {
    opacity: 1;
    transform: translate3d(0, 2px, 0) scale(1.008);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes fullPickConfirm {
  0% {
    transform: scale(1);
    border-color: rgba(221, 191, 255, 0.62);
    box-shadow: none;
  }
  45% {
    transform: scale(1.05);
    border-color: rgba(246, 232, 255, 0.96);
    box-shadow:
      0 0 0 1px rgba(246, 232, 255, 0.7),
      0 0 0 6px rgba(198, 149, 255, 0.22),
      0 9px 18px rgba(17, 11, 40, 0.34);
  }
  100% {
    transform: scale(1);
    border-color: rgba(221, 191, 255, 0.62);
    box-shadow: none;
  }
}

body[data-page='full'] .full-draw-summary__note,
body[data-page='full'] .full-arrange-item__order-label,
body[data-page='full'] .full-arrange-item__orientation {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  color: rgba(220, 211, 241, 0.72);
}

body[data-page='full'] .full-arrange-item__position {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 600;
  color: rgba(239, 232, 252, 0.96);
}

body[data-page='full'] .full-stage-panel--arrange {
  padding: 16px;
}

body[data-page='full'] .full-arrange-copy {
  margin-bottom: 14px;
}

body[data-page='full'] .full-arrange-note {
  margin: 0;
  color: rgba(232, 226, 245, 0.86);
}

body[data-page='full'] .full-arrange-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body[data-page='full'] .full-arrange-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas:
    'order image'
    'meta meta';
  gap: 8px;
  align-items: start;
  padding: 8px;
  border-radius: 14px;
  background: rgba(17, 21, 49, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  cursor: pointer;
}

body[data-page='full'] .full-arrange-item.is-dragging,
body[data-page='full'] .full-arrange-item:hover {
  border-color: rgba(222, 198, 255, 0.48);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.24);
  transform: translateY(-1px);
}

body[data-page='full'] .full-arrange-item.is-dragging {
  background:
    linear-gradient(180deg, rgba(82, 59, 122, 0.42), rgba(17, 21, 49, 0.92)),
    rgba(17, 21, 49, 0.92);
  border-color: rgba(233, 213, 255, 0.72);
  box-shadow:
    0 18px 42px rgba(7, 7, 16, 0.28),
    0 0 0 1px rgba(233, 213, 255, 0.24);
}

body[data-page='full'] .full-arrange-item__order {
  grid-area: order;
  display: flex;
  justify-items: start;
  min-width: 48px;
}

body[data-page='full'] .full-arrange-item__order-index {
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #d5bcfa 0%, #f1d0df 100%);
  color: #241635;
  font-weight: 800;
}

body[data-page='full'] .full-arrange-item__img {
  grid-area: image;
  width: 100%;
  aspect-ratio: 1568 / 2720;
}

body[data-page='full'] .full-arrange-item__meta {
  grid-area: meta;
  display: block;
}

body[data-page='full'] #overall-toolbar {
  display: flex;
  width: min(100%, 820px);
  justify-content: center;
  align-items: center;
  gap: 10px;
}

body[data-page='full'] #overall-toolbar button {
  flex: 0 0 auto;
  min-width: 140px;
}

body[data-page='full'] #overall-counter {
  min-width: 0;
  padding-inline: 14px;
}

body[data-page='full'] #overall-continue {
  color: var(--color-text-inverse);
  background: linear-gradient(135deg, #afc2f7 0%, #e1b8d7 100%);
  border: 1px solid rgba(255, 255, 255, 0.28);
}

body[data-page='full'] #overall-continue:disabled {
  background: #e7e3ee;
  color: #a79db8;
  border: 1px solid rgba(122, 108, 156, 0.10);
  box-shadow: none;
}

/* Keep board card backs uncropped by preserving the source back-art aspect ratio. */
body[data-page='daily'] #daily-board .card-slot {
  height: auto;
  aspect-ratio: 1568 / 2720;
}

body[data-page='daily'] #daily-board .card-back {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}


.card-slot.is-clearing .selection-badge {
  opacity: 0;
  transform: scale(0.84);
}


.card-board.is-phase-placeholder {
  visibility: hidden;
  pointer-events: none;
}

@media (max-width: 640px) {
  body[data-page='daily'] {
    height: 100dvh;
    overflow: hidden;
  }


  body[data-page='daily'] #site-footer {
    display: none;
  }

  body[data-page='daily'] .page-shell.board-page {
    height: 100dvh;
    padding: calc(var(--nav-height) + 8px) 12px calc(env(safe-area-inset-bottom, 0px) + 8px);
  }

  body[data-page='daily'] .board-page .board-shell {
    height: calc(100dvh - var(--nav-height) - var(--bottom-nav-height) - env(safe-area-inset-bottom, 0px) - 16px);
    padding: 12px;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: 10px;
  }

  body[data-page='daily'] .board-actions--daily {
    position: relative;
    z-index: 8;
  }

  body[data-page='daily'] .board-header--daily {
    gap: 3px;
    margin-bottom: 0;
  }

  body[data-page='daily'] .board-header--daily .eyebrow {
    font-size: clamp(1.7rem, 7vw, 2rem);
    letter-spacing: 0.04em;
  }

  body[data-page='daily'] .board-header--daily .board-helper {
    font-size: 0.82rem;
    letter-spacing: 0.04em;
  }

  body[data-page='daily'] .selection-counter {
    margin-top: 0;
    padding: 0;
    border-radius: 0;
    background: transparent;
    font-size: 1rem;
    letter-spacing: 0.03em;
    color: var(--mystic-muted);
    font-weight: 600;
  }

  body[data-page='daily'] .card-board {
    margin: 0;
    min-height: 0;
    padding: 6px 10px 10px;
  }

  body[data-page='daily'] .card-board.card-board--daily {
    --daily-mobile-board-max-height: calc(100dvh - var(--nav-height) - var(--bottom-nav-height) - env(safe-area-inset-bottom, 0px) - 236px);
    width: min(100%, 274px);
    max-height: clamp(304px, var(--daily-mobile-board-max-height), 420px);
    margin-inline: auto;
    padding-bottom: 14px;
    grid-template-columns: repeat(2, 120px);
    grid-template-rows: repeat(3, auto);
    justify-content: center;
    align-content: start;
    gap: clamp(8px, 1.8vh, 12px);
    overflow: clip;
  }

  body[data-page='daily'] #daily-board .card-slot.is-selected {
    transform: translateY(-6px) scale(1.03);
    transform-origin: 50% 18%;
  }

  body[data-page='daily'] #daily-board .card-slot {
    width: 114px;
    max-height: 100%;
    place-self: center;
  }

  body[data-page='daily'] .board-actions--daily {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-top: 2px;
  }

  body[data-page='daily'] .board-actions--daily .action-btn {
    width: 100%;
    min-height: 48px;
    flex: none;
  }

  body[data-page='daily'] #daily-deal-shuffle {
    order: 1;
  }

  body[data-page='daily'] #daily-continue {
    order: 2;
  }
}




@media (max-width: 480px) {
  body[data-page='daily'] {
    height: 100dvh;
    overflow: hidden;
  }

  body[data-page='daily'] .page-shell.board-page {
    height: 100dvh;
  }

  body[data-page='daily'] .board-page .board-shell {
    height: calc(100dvh - var(--nav-height) - var(--bottom-nav-height) - env(safe-area-inset-bottom, 0px) - 16px);
    overflow: hidden;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: 8px;
  }

  body[data-page='daily'] .board-header--daily .eyebrow {
    font-size: clamp(1.54rem, 8vw, 1.9rem);
  }

  body[data-page='daily'] .board-header--daily .board-helper {
    font-size: 0.78rem;
  }

  body[data-page='daily'] .card-board.card-board--daily {
    --daily-mobile-board-max-height: calc(100dvh - var(--nav-height) - var(--bottom-nav-height) - env(safe-area-inset-bottom, 0px) - 236px);
    width: min(100%, 272px);
    max-height: clamp(304px, var(--daily-mobile-board-max-height), 420px);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(3, minmax(0, 1fr));
    gap: clamp(8px, 1.4dvh, 12px);
    justify-content: center;
    justify-items: center;
    align-content: stretch;
    padding-bottom: 10px;
  }

  body[data-page='daily'] #daily-board .card-slot {
    position: relative;
    top: 0;
    left: 0;
    width: min(100%, 108px);
    height: 100%;
    max-height: calc((var(--daily-mobile-board-max-height) - (2 * clamp(8px, 1.4dvh, 12px))) / 3);
    aspect-ratio: 1568 / 2720;
  }

  body[data-page='daily'] #daily-board .card-slot:not(.is-selected) {
    transform: translateY(0) rotate(0deg) scale(1);
  }

  body[data-page='daily'] #daily-board .card-slot.is-selected {
    transform: translateY(-4px) scale(1.02);
  }
}

body[data-page='daily'] #daily-board .card-slot.card-visible {
  opacity: 1;
  filter: none;
}

body[data-page='daily'] #daily-board .card-slot.card-visible .card-back {
  opacity: 1;
  filter: none;
}

body[data-page='daily'] #daily-board .card-slot {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  border-radius: 0;
  padding: 0;
}

body[data-page='daily'] #daily-board .card-slot:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: transparent;
  box-shadow: none;
}


body[data-page='daily'] #daily-board .card-slot {
  overflow: visible;
}

body[data-page='daily'] #daily-board .card-slot .selection-badge {
  top: 6px;
  right: 6px;
  width: 24px;
  height: 24px;
  font-size: 12px;
  z-index: 9;
  border: 1px solid rgba(236, 225, 255, 0.9);
  background: rgba(206, 182, 245, 0.96);
  color: #23163a;
  box-shadow: 0 4px 10px rgba(31, 19, 49, 0.28);
}


body[data-page='daily'] #daily-board.has-selection .card-slot:not(.is-selected) {
  opacity: 0.72;
  filter: saturate(0.74) contrast(0.92);
}

body[data-page='daily'] #daily-board.has-selection .card-slot:not(.is-selected):hover:not(:disabled) {
  opacity: 0.85;
  filter: saturate(0.82) contrast(0.96);
}

body[data-page='daily'] #daily-board .card-slot .selection-badge {
  font-size: 0;
  color: transparent;
}

body[data-page='daily'] #daily-board .card-slot .selection-badge::before {
  content: '✓';
  font-size: 13px;
  line-height: 1;
  color: #23163a;
  font-weight: 800;
}

body[data-page='daily'] #daily-board .card-slot.is-selected::before {
  content: none;
}

body[data-page='daily'] #daily-board .card-slot.is-selected .card-back {
  filter: brightness(1.05) saturate(1.06);
}

body[data-page='daily'] #daily-board .card-slot.is-selected,
body[data-page='daily'] #daily-board .card-slot.is-selected:hover:not(:disabled) {
  transform: translateY(-4px) scale(1.04);
  border-color: transparent;
  box-shadow:
    0 6px 12px rgba(18, 12, 34, 0.12),
    0 0 10px rgba(188, 157, 248, 0.4),
    0 0 14px rgba(198, 172, 255, 0.18);
  z-index: 2;
}

body[data-page='daily'] #daily-board .card-slot.is-selected::after {
  inset: -2px;
  border-radius: 11px;
  background: radial-gradient(circle at 38% 20%, rgba(220, 202, 255, 0.3), rgba(214, 192, 255, 0.05) 44%, rgba(214, 192, 255, 0) 60%);
  box-shadow:
    0 0 9px rgba(188, 157, 248, 0.32),
    0 0 12px rgba(198, 172, 255, 0.16);
}

#overall-flow {
  min-height: unset;
}

body {
  background-attachment: fixed;
}

/* ── Daily board small-screen tweaks (from main) ─────────────────── */
@media (max-width: 480px) {
  body[data-page='daily'] #daily-board .card-slot .selection-badge {
    top: 5px;
    right: 5px;
    width: 20px;
    height: 20px;
    border: 1px solid rgba(241, 233, 255, 0.82);
    background: rgba(212, 191, 247, 0.88);
    box-shadow: 0 2px 6px rgba(31, 19, 49, 0.2);
  }

  body[data-page='daily'] #daily-board .card-slot .selection-badge::before {
    font-size: 11px;
    font-weight: 700;
    color: rgba(35, 22, 58, 0.9);
  }

  body[data-page='daily'] #daily-board .card-slot.is-selected,
  body[data-page='daily'] #daily-board .card-slot.is-selected:hover:not(:disabled) {
    transform: none;
    box-shadow:
      0 5px 10px rgba(18, 12, 34, 0.12),
      0 0 14px rgba(188, 157, 248, 0.24),
      0 0 22px rgba(198, 172, 255, 0.12);
  }

  body[data-page='daily'] #daily-board .card-slot.is-selected::after {
    inset: 0;
    border-radius: inherit;
    background: transparent;
    box-shadow:
      0 0 10px rgba(186, 152, 244, 0.2),
      0 0 18px rgba(168, 131, 237, 0.12);
  }
}
body[data-page='reading'][data-reading-mode='full'] .panel--celtic-cross {
  overflow: visible;
}

body[data-page='reading'][data-reading-mode='full'] .celtic-cross-layout {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(4, auto);
  gap: 8px;
  position: relative;
  align-items: center;
  justify-items: center;
}

body[data-page='reading'][data-reading-mode='full'] .celtic-cross-slot,
body[data-page='reading'][data-reading-mode='full'] .celtic-slot {
  width: 100%;
  max-width: 190px;
}

body[data-page='reading'][data-reading-mode='full'] .celtic-slot--focus { grid-area: 1 / 2; }
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--past { grid-area: 2 / 1; }
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--center {
  grid-area: 2 / 2;
  position: relative;
  min-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--nearfuture { grid-area: 2 / 3; }
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--recentpast { grid-area: 3 / 2; }

body[data-page='reading'][data-reading-mode='full'] .celtic-slot--situation {
  position: relative;
  z-index: 1;
}

body[data-page='reading'][data-reading-mode='full'] .celtic-slot--challenge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(90deg);
  z-index: 2;
}

body[data-page='reading'][data-reading-mode='full'] .celtic-slot--outcome { grid-area: 1 / 4; }
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--hopes { grid-area: 2 / 4; }
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--environment { grid-area: 3 / 4; }
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--power { grid-area: 4 / 4; }

body[data-page='reading'][data-reading-mode='full'] .celtic-slot--center .card-art.is-thumb .card-art-img,
body[data-page='reading'][data-reading-mode='full'] .celtic-slot--challenge .card-art.is-thumb .card-art-img {
  max-width: 170px;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box {
  min-height: 100%;
  position: relative;
  border-radius: 20px;
  padding: 16px 16px 15px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background:
    linear-gradient(155deg, rgba(255, 249, 255, 0.76) 0%, rgba(233, 236, 255, 0.56) 56%, rgba(238, 225, 255, 0.62) 100%);
  box-shadow:
    0 10px 26px rgba(95, 70, 130, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(8px) saturate(1.08);
  -webkit-backdrop-filter: blur(8px) saturate(1.08);
  overflow: hidden;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(125% 92% at 8% 0%, rgba(255, 255, 255, 0.34) 0%, rgba(255, 255, 255, 0) 56%),
    radial-gradient(115% 90% at 100% 100%, rgba(202, 177, 255, 0.2) 0%, rgba(202, 177, 255, 0) 62%);
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-tag,
body[data-page='reading'][data-reading-mode='full'] .full-interpretation-title,
body[data-page='reading'][data-reading-mode='full'] .full-summary-meta,
body[data-page='reading'][data-reading-mode='full'] .full-interpretation-body {
  position: relative;
  z-index: 1;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-tag {
  margin: 0 0 10px;
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.6);
  color: #70548d;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-title {
  margin: 0 0 8px;
  font-size: clamp(1.02rem, 3vw, 1.15rem);
  line-height: 1.3;
  font-family: 'Playfair Display', Georgia, serif;
  color: #2f2343;
}

body[data-page='reading'][data-reading-mode='full'] .full-summary-meta {
  display: grid;
  gap: 2px;
  margin-bottom: 10px;
}

body[data-page='reading'][data-reading-mode='full'] .full-summary-meta__name {
  margin: 0;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(92, 67, 123, 0.88);
}

body[data-page='reading'][data-reading-mode='full'] .full-summary-meta__archetype {
  margin: 0;
  font-size: 0.83rem;
  line-height: 1.45;
  color: rgba(71, 50, 101, 0.9);
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-body {
  margin: 0;
  color: #35264b;
  line-height: 1.74;
  font-size: 0.93rem;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--present,
body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--advice,
body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--outcome {
  border-color: rgba(255, 255, 255, 0.66);
  box-shadow:
    0 14px 30px rgba(96, 66, 140, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--present .full-interpretation-tag {
  background: linear-gradient(135deg, rgba(237, 226, 255, 0.88), rgba(221, 234, 255, 0.82));
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--advice .full-interpretation-tag {
  background: linear-gradient(135deg, rgba(255, 236, 243, 0.92), rgba(240, 229, 255, 0.82));
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--outcome .full-interpretation-tag {
  background: linear-gradient(135deg, rgba(255, 243, 213, 0.95), rgba(255, 232, 248, 0.84));
  color: #765123;
}

body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box--outcome::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(238, 195, 120, 0.26);
}

body[data-page='reading'][data-reading-mode='full'] .full-integration-panel > h3 {
  margin-bottom: 14px;
}

body[data-page='reading'][data-reading-mode='full'] .full-integration-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

body[data-page='reading'][data-reading-mode='full'] .full-integration-box {
  min-height: 100%;
}

body[data-page='reading'][data-reading-mode='full'] .full-integration-box h4 {
  margin: 0 0 6px;
  font-size: 0.95rem;
  color: #2f2940;
}

body[data-page='reading'][data-reading-mode='full'] .full-integration-box__source {
  margin: 0 0 8px;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8a719f;
}

body[data-page='reading'][data-reading-mode='full'] .full-integration-box > p:last-child {
  margin: 0;
  color: #3d3252;
  line-height: 1.6;
}

@media (max-width: 640px) {
  body[data-page='reading'][data-reading-mode='full'] .celtic-cross-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  body[data-page='reading'][data-reading-mode='full'] .celtic-slot--center {
    min-height: 0;
  }

  body[data-page='reading'][data-reading-mode='full'] .celtic-slot--challenge {
    position: static;
    transform: none;
  }

  body[data-page='reading'][data-reading-mode='full'] .celtic-cross-slot,
  body[data-page='reading'][data-reading-mode='full'] .celtic-slot {
    max-width: 220px;
  }

  body[data-page='reading'][data-reading-mode='full'] .full-interpretation-grid {
    grid-template-columns: 1fr;
  }

  body[data-page='reading'][data-reading-mode='full'] .full-interpretation-box {
    padding: 15px 14px 14px;
    border-radius: 18px;
  }

  body[data-page='reading'][data-reading-mode='full'] .full-interpretation-title {
    font-size: 1.04rem;
  }

  body[data-page='reading'][data-reading-mode='full'] .full-interpretation-body {
    font-size: 0.92rem;
    line-height: 1.68;
  }

  body[data-page='reading'][data-reading-mode='full'] .full-integration-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  body[data-page='full'] {
    --full-mobile-vh: 100dvh;
    min-height: var(--full-mobile-vh);
    height: auto;
    overflow-x: clip;
    overflow-y: auto;
  }
  @supports (height: 100svh) {
    body[data-page='full'] {
      --full-mobile-vh: 100svh;
    }
  }
  body[data-page='full'] #site-footer {
    display: none;
  }
  body[data-page='full'] .page-shell.board-page {
    min-height: var(--full-mobile-vh);
    height: auto;
    padding: calc(var(--nav-height) + 6px) 10px calc(env(safe-area-inset-bottom, 0px) + 8px);
  }
  body[data-page='full'] .board-shell {
    min-height: calc(var(--full-mobile-vh) - var(--nav-height) - env(safe-area-inset-bottom, 0px) - 14px);
    height: auto;
    max-height: none;
    padding: 10px;
    overflow: visible;
  }
  body[data-page='full'] #overall-flow {
    height: auto;
    min-height: 0;
    max-height: none;
    gap: 8px;
    overflow: visible;
    padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 92px);
  }
  body[data-page='full'] .full-stage-copy p:last-child {
    font-size: 0.86rem;
  }
  body[data-page='full'] .full-selection-shell {
    min-height: 0;
    flex: 1;
  }
  body[data-page='full'] #overall-deal-stage,
  body[data-page='full'] #overall-arrange-stage {
    min-height: 0;
  }
  body[data-page='full'] .full-stage-panel--arrange {
    padding: 10px;
  }
  body[data-page='full'] .full-arrange-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-height: none;
    overflow: visible;
  }
  body[data-page='full'] .full-arrange-item__order-index {
    width: 30px;
    height: 30px;
  }
  body[data-page='full'] .full-draw-board {
    width: min(100%, 360px);
    margin-inline: auto;
    gap: clamp(4px, 1.5vw, 6px);
  }
  body[data-page='full'] .full-draw-board__slot {
    padding: clamp(2px, 0.8vw, 3px);
    border-radius: 10px;
  }
  body[data-page='full'] .full-draw-board__img {
    height: 100%;
  }
  body[data-page='full'] .full-stage-panel--deal {
    padding: 10px;
  }
  body[data-page='full'] #overall-actions {
    position: sticky;
    bottom: 0;
    z-index: 3;
    margin-top: 2px;
    padding: 8px 6px calc(env(safe-area-inset-bottom, 0px) + 6px);
    background: linear-gradient(180deg, rgba(8, 12, 31, 0) 0%, rgba(8, 12, 31, 0.9) 46%);
  }
  body[data-page='full'] #overall-toolbar {
    gap: 8px;
  }
  body[data-page='full'] #overall-toolbar button {
    min-width: 132px;
  }
}

.page-shell.home-page,
.page-shell.question-page-shell {
  width: min(1120px, calc(100% - clamp(20px, 6vw, 32px)));
  margin: 0 auto;
}

.page-shell.question-draw-shell {
  width: min(980px, calc(100% - clamp(20px, 6vw, 32px)));
  margin: 0 auto;
}

.home-page {
  display: grid;
  gap: 28px;
  padding-top: clamp(110px, 14vw, 148px);
  padding-bottom: 64px;
}

body[data-page='home'] {
  background:
    radial-gradient(ellipse at 12% 8%, rgba(196, 168, 240, 0.22) 0%, transparent 38%),
    radial-gradient(ellipse at 88% 6%, rgba(240, 168, 200, 0.18) 0%, transparent 35%),
    radial-gradient(ellipse at 50% 85%, rgba(148, 204, 248, 0.15) 0%, transparent 42%),
    linear-gradient(165deg, #fcf5ff 0%, #fff5fb 45%, #f0f8ff 100%);
  overflow-x: clip;
}

body[data-page='home'] .home-page {
  gap: clamp(16px, 2.8vw, 28px);
}

body[data-page='home'] .home-hero-card {
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(172, 130, 210, 0.18);
  box-shadow: 0 6px 24px rgba(120, 80, 180, 0.09);
}

body[data-page='home'] .home-hero-card--chooser {
  border-color: rgba(172, 130, 210, 0.2);
  background:
    radial-gradient(circle at 50% -12%, rgba(196, 168, 240, 0.24), transparent 52%),
    rgba(255, 255, 255, 0.84);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    0 10px 30px rgba(132, 99, 189, 0.14);
}

body[data-page='home'] .home-hero-card::before {
  background: radial-gradient(circle, rgba(224, 168, 216, 0.28), transparent 70%);
}

body[data-page='home'] .home-hero-title,
body[data-page='home'] .reading-path-card__label {
  color: #3d2c58;
  text-shadow: none;
}

body[data-page='home'] .home-hero-copy--centered .eyebrow {
  border: 1px solid rgba(172, 130, 210, 0.28);
  background: rgba(255, 255, 255, 0.62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
  color: #9270d0;
}

body[data-page='home'] .home-hero-copy,
body[data-page='home'] .home-hero-body,
body[data-page='home'] .home-hero-note,
body[data-page='home'] .reading-path-card__meta {
  color: #7a5f99;
}

body[data-page='home'] .reading-path-card {
  background: rgba(255, 255, 255, 0.84);
  border-color: rgba(172, 130, 210, 0.18);
  box-shadow: 0 6px 24px rgba(120, 80, 180, 0.09);
}

body[data-page='home'] .reading-path-card--chooser {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 10px 24px rgba(129, 90, 180, 0.14);
}

body[data-page='home'] .reading-path-card__media {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(246, 237, 255, 0.7));
  box-shadow:
    inset 0 0 0 1px rgba(172, 130, 210, 0.16),
    0 10px 20px rgba(126, 96, 171, 0.16);
}

body[data-page='home'] .home-secondary-cta {
  border-color: rgba(172, 130, 210, 0.34);
  background: linear-gradient(135deg, #c4a8f0 0%, #e0a8d8 100%);
  color: #2a1e42;
  box-shadow: 0 10px 24px rgba(126, 84, 174, 0.2);
}

@media (hover: hover) {
  body[data-page='home'] .home-secondary-cta:hover,
  body[data-page='home'] .home-secondary-cta:focus-visible {
    border-color: rgba(146, 112, 208, 0.48);
    background: linear-gradient(135deg, #b897ee 0%, #d995cf 100%);
    color: #2a1e42;
  }

  body[data-page='home'] .reading-path-card:hover,
  body[data-page='home'] .reading-path-card:focus-visible {
    transform: translateY(-3px);
    border-color: rgba(146, 112, 208, 0.4);
    background: rgba(255, 255, 255, 0.94);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.8),
      0 12px 28px rgba(124, 92, 178, 0.2);
  }
}

body[data-page='home'] .home-secondary-cta:focus-visible,
body[data-page='home'] .reading-path-card:focus-visible {
  outline: 2px solid rgba(146, 112, 208, 0.6);
  outline-offset: 2px;
}

.home-hero-card,
.question-flow-card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.09), rgba(141, 108, 255, 0.08));
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 28px;
  box-shadow: 0 24px 80px rgba(3, 6, 24, 0.45);
}

.home-hero-card {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.9fr);
  gap: 24px;
  padding: clamp(28px, 4vw, 52px);
}

.home-hero-card--chooser {
  grid-template-columns: 1fr;
  justify-items: center;
  gap: clamp(20px, 3vw, 30px);
  padding: clamp(28px, 4vw, 44px);
  text-align: center;
  border-color: rgba(222, 213, 255, 0.28);
  background:
    radial-gradient(circle at 50% -12%, rgba(242, 219, 166, 0.18), transparent 45%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(141, 108, 255, 0.09));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 30px 90px rgba(3, 6, 24, 0.52);
}

.home-hero-card::before,
.question-flow-card::before {
  content: '';
  position: absolute;
  inset: auto -60px -90px auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(242, 219, 166, 0.28), transparent 70%);
  pointer-events: none;
}

.home-hero-copy,
.home-hero-aside,
.question-flow-intro,
.question-flow-layout,
.question-draw-panel {
  position: relative;
  z-index: 1;
}

.hero-brand {
  margin: 0 0 10px;
  color: rgba(248, 249, 255, 0.78);
  font-size: 0.98rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.home-hero-title {
  margin: 0;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  line-height: 0.96;
  max-width: 11ch;
}

.home-hero-copy--centered {
  display: grid;
  justify-items: center;
  gap: 10px;
}

.home-hero-copy--centered .eyebrow {
  margin-bottom: 0;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
  color: #f4e6c2;
  letter-spacing: 0.13em;
}

.home-hero-copy--centered .home-hero-title {
  max-width: 14ch;
  font-size: clamp(2.1rem, 5vw, 3.8rem);
  letter-spacing: -0.012em;
  text-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
  text-wrap: balance;
}

.home-hero-body,
.home-hero-note,
.hero-spotlight-card p,
.reading-path-card p,
.topic-card__body,
.question-selected-label {
  color: #d7ddff;
}

.home-hero-body {
  margin: 18px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.22rem);
  line-height: 1.7;
  max-width: 56ch;
}

.home-hero-actions {
  margin-top: 28px;
}

.home-hero-actions--subtle {
  margin-top: 0;
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-items: stretch;
}

.home-primary-cta {
  min-width: min(100%, 260px);
  justify-content: center;
}

.home-secondary-cta {
  min-width: 0;
  width: 100%;
  min-height: 46px;
  padding: 11px 14px;
  justify-content: center;
  text-align: center;
  line-height: 1.24;
  border-color: rgba(242, 219, 166, 0.44);
  background: linear-gradient(140deg, rgba(51, 39, 98, 0.84), rgba(20, 22, 60, 0.92));
  color: #fff3cf;
  box-shadow: 0 12px 28px rgba(17, 13, 42, 0.48);
}

.home-secondary-cta:hover,
.home-secondary-cta:focus-visible {
  border-color: rgba(242, 219, 166, 0.65);
  background: linear-gradient(140deg, rgba(65, 47, 121, 0.95), rgba(30, 27, 78, 0.96));
}

.home-secondary-cta:focus-visible,
body[data-page='home'] .reading-path-card:focus-visible {
  outline: 2px solid rgba(242, 219, 166, 0.82);
  outline-offset: 2px;
}

.home-hero-note {
  margin: 18px 0 0;
  font-size: 0.96rem;
}

html[lang='th'] body[data-page='home'] .home-hero-copy--centered .home-hero-title {
  font-family: 'Noto Sans Thai', 'Sarabun', 'Prompt', 'Inter', system-ui, sans-serif;
  line-height: 1.14;
  letter-spacing: 0;
  max-width: 13ch;
}

html[lang='th'] body[data-page='home'] .reading-path-card__label {
  font-family: 'Noto Sans Thai', 'Sarabun', 'Prompt', 'Inter', system-ui, sans-serif;
  line-height: 1.28;
  letter-spacing: 0;
}

html[lang='th'] body[data-page='home'] .reading-path-card__meta {
  line-height: 1.44;
  letter-spacing: 0;
}

html[lang='th'] body[data-page='home'] .home-secondary-cta {
  min-width: 210px;
}

.home-hero-aside {
  display: flex;
  align-items: stretch;
}

.hero-spotlight-card,
.reading-path-card,
.topic-card,
.question-intention,
.question-draw-panel,
.topic-selection-panel {
  background: rgba(7, 12, 34, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
}

.hero-spotlight-card {
  width: 100%;
  padding: 24px;
  align-self: center;
}

.hero-spotlight-card h2,
.section-heading h2,
.topic-selection-panel h2,
.question-draw-header h2 {
  margin: 0;
  font-family: 'Playfair Display', serif;
}

.hero-spotlight-card h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 12px;
}

.hero-spotlight-list {
  margin: 18px 0 0;
  padding-left: 18px;
  color: #f8f9ff;
  display: grid;
  gap: 10px;
}

.secondary-reading-section {
  display: grid;
  gap: 18px;
}

.section-heading--tight p:last-child {
  max-width: 56ch;
  margin: 10px 0 0;
  color: #d7ddff;
}

.secondary-reading-grid,
.topic-card-grid {
  display: grid;
  gap: 16px;
}

.secondary-reading-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.reading-path-card {
  padding: 22px;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

body[data-page='home'] .reading-path-card {
  background: linear-gradient(170deg, rgba(12, 18, 48, 0.9), rgba(9, 13, 36, 0.92));
  border-color: rgba(214, 203, 255, 0.24);
}

.home-path-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.reading-path-card--chooser {
  display: grid;
  grid-template-rows: auto minmax(2.4em, auto) minmax(2.9em, auto);
  gap: 14px;
  align-content: start;
  justify-items: center;
  text-align: center;
  padding: 18px;
  height: 100%;
}

body[data-page='home'] .reading-path-card--chooser {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    0 16px 34px rgba(5, 9, 27, 0.38);
}

.reading-path-card__media {
  position: relative;
  display: block;
  width: min(100%, 180px);
  aspect-ratio: 3 / 5;
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02));
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.12),
    0 14px 28px rgba(4, 7, 22, 0.44);
}

.reading-path-card__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.18s ease;
}

.reading-path-card__image--default {
  opacity: 1;
}

.reading-path-card__image--active {
  opacity: 0;
}

.reading-path-card__label {
  margin: 0;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.28rem, 2.15vw, 1.68rem);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: 0.01em;
  max-width: 15ch;
  text-wrap: balance;
  color: #f8f9ff;
  text-shadow: 0 6px 20px rgba(7, 10, 27, 0.55);
}

.reading-path-card__meta {
  margin: 2px 0 0;
  font-size: clamp(0.86rem, 1.15vw, 0.95rem);
  font-weight: 500;
  line-height: 1.52;
  letter-spacing: 0.012em;
  color: #d7ddff;
  max-width: 31ch;
  text-wrap: pretty;
}

.reading-path-card:hover,
.reading-path-card:focus-visible,
.topic-card:hover,
.topic-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(198, 183, 255, 0.5);
  background: rgba(13, 22, 56, 0.82);
}

body[data-page='home'] .reading-path-card:hover,
body[data-page='home'] .reading-path-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(242, 219, 166, 0.55);
  background: linear-gradient(170deg, rgba(23, 28, 72, 0.94), rgba(12, 17, 48, 0.94));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    0 22px 42px rgba(6, 9, 28, 0.46);
}

.reading-path-card:hover .reading-path-card__image--active,
.reading-path-card:focus-visible .reading-path-card__image--active,
.reading-path-card:active .reading-path-card__image--active {
  opacity: 1;
}

.reading-path-card:hover .reading-path-card__image--default,
.reading-path-card:focus-visible .reading-path-card__image--default,
.reading-path-card:active .reading-path-card__image--default {
  opacity: 0;
}

.reading-path-card__eyebrow,
.topic-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-width: 42px;
  min-height: 42px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(198, 183, 255, 0.12);
  color: var(--gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.74rem;
}

.reading-path-card h3 {
  margin: 18px 0 10px;
  font-size: 1.3rem;
}

.question-page-shell {
  padding-top: clamp(108px, 14vw, 142px);
  padding-bottom: 64px;
}

.question-draw-shell {
  padding-top: clamp(108px, 14vw, 142px);
  padding-bottom: 64px;
}

.question-flow-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  padding: clamp(24px, 4vw, 40px);
  align-items: stretch;
}

.question-flow-intro {
  max-width: 70ch;
}

.question-flow-intro .eyebrow {
  margin-bottom: 6px;
}

.question-flow-intro h1 {
  margin: 0;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 3.4rem);
}

.question-flow-intro .lede {
  margin: 12px 0 0;
  max-width: 58ch;
}

.question-flow-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  align-items: start;
}

.topic-selection-panel,
.question-draw-panel {
  padding: 24px;
  min-width: 0;
}

.topic-card-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin-top: 20px;
}

.topic-card {
  appearance: none;
  width: 100%;
  color: inherit;
  text-align: left;
  padding: clamp(16px, 3vw, 20px);
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  min-width: 0;
}

.question-page-shell .topic-card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.question-page-shell .topic-card {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 92px;
  padding: 12px 13px;
}

.topic-card.is-active {
  border-color: rgba(242, 219, 166, 0.6);
  background: linear-gradient(180deg, rgba(46, 33, 86, 0.95), rgba(18, 17, 51, 0.92));
  box-shadow: 0 18px 50px rgba(18, 15, 46, 0.45);
}

.topic-card__icon {
  width: 54px;
  min-width: 54px;
  height: 54px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(230, 220, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.24), 0 6px 14px rgba(5, 8, 24, 0.24);
  font-size: 1.5rem;
  line-height: 1;
}

.topic-card__title {
  display: block;
  margin-top: 0;
  font-size: 1.02rem;
  font-weight: 600;
  color: #f8faff;
}

.topic-card__body {
  display: none;
  margin-top: 0;
  font-size: 0.93rem;
  line-height: 1.45;
  color: #e9eeff;
  text-wrap: pretty;
}

.question-intention__intro h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
}

.question-intention__intro p {
  margin: 0;
  color: #d7ddff;
  line-height: 1.65;
}

.question-intention__steps {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.question-step {
  margin: 0;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  color: #f6f8ff;
}

.question-draw-panel {
  display: grid;
  gap: 18px;
}

.question-draw-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.question-selected-label {
  margin: 0 0 6px;
  font-size: 0.88rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.question-draw-header #question-selected-topic-title {
  color: #f3ddab;
  text-shadow: 0 1px 0 rgba(8, 9, 22, 0.3);
}

.question-spread-chip {
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .page-shell.home-page,
  .page-shell.question-page-shell {
    width: min(1120px, calc(100% - clamp(16px, 5.2vw, 24px)));
  }

  .page-shell.question-draw-shell {
    width: min(980px, calc(100% - clamp(16px, 5.2vw, 24px)));
  }

  .home-hero-card,
  .question-flow-layout,
  .secondary-reading-grid {
    grid-template-columns: 1fr;
  }

  .question-page-shell .question-flow-card,
  .question-page-shell .question-flow-layout,
  .question-page-shell .topic-selection-panel,
  .question-page-shell .topic-card-grid {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .question-page-shell .question-flow-card {
    gap: 20px;
    padding: 20px 18px;
  }

  .question-page-shell .question-flow-intro {
    max-width: 62ch;
  }

  .question-page-shell .question-flow-intro h1 {
    font-size: clamp(1.82rem, 6.2vw, 2.4rem);
  }

  .question-page-shell .topic-selection-panel {
    padding: 18px;
  }

  .question-page-shell .topic-selection-panel .section-heading--tight p:last-child {
    margin-top: 6px;
  }

  .question-page-shell .topic-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
    margin-top: 10px;
  }

  .question-page-shell .topic-card {
    min-height: 86px;
    padding: 11px 12px;
  }

  .question-page-shell .topic-card__title {
    margin-top: 0;
    font-size: 0.98rem;
    line-height: 1.2;
  }

  .home-hero-title {
    max-width: none;
  }

  body[data-page='home'] .home-path-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px;
    overflow: visible;
    padding: 2px 0 4px;
  }

  body[data-page='home'] .reading-path-card--chooser {
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 12px 10px;
    min-height: 0;
  }

  body[data-page='home'] .reading-path-card__media {
    width: min(100%, 116px);
    aspect-ratio: 3 / 4;
  }

  body[data-page='home'] .reading-path-card__label {
    font-size: clamp(1rem, 2.4vw, 1.2rem);
    max-width: 13ch;
  }

  body[data-page='home'] .reading-path-card__meta {
    font-size: clamp(0.76rem, 2.05vw, 0.86rem);
    line-height: 1.36;
  }

  body[data-page='home'] .home-hero-copy--centered .home-hero-title {
    max-width: 100%;
    font-size: clamp(1.84rem, 5.8vw, 2.4rem);
    line-height: 1.06;
    overflow-wrap: anywhere;
  }

  body[data-page='home'] .home-hero-actions--subtle {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .question-draw-header {
    align-items: flex-start;
  }
}

@media (max-width: 768px) {
  .question-page-shell .question-flow-intro {
    margin-inline: auto;
    text-align: center;
  }

  .question-page-shell .topic-selection-panel .section-heading {
    text-align: center;
  }

  .question-page-shell .topic-selection-panel .section-heading--tight p:last-child {
    margin-left: auto;
    margin-right: auto;
  }
}

@media (max-width: 640px) {
  .home-page,
  .question-page-shell {
    padding-top: clamp(86px, 18vw, 108px);
    padding-bottom: 40px;
  }

  body[data-page='home'] .home-page {
    gap: 12px;
    padding-top: clamp(88px, 19vw, 108px);
    padding-bottom: 36px;
  }

  body[data-page='home'] .home-hero-card--chooser {
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.2),
      0 18px 38px rgba(3, 7, 24, 0.5);
  }

  .question-draw-shell {
    padding-top: clamp(84px, 17vw, 102px);
    padding-bottom: 24px;
  }

  .question-flow-intro {
    margin-inline: auto;
    text-align: center;
  }

  .question-page-shell .question-flow-intro .eyebrow {
    margin-bottom: 4px;
  }

  .question-page-shell .question-flow-intro h1 {
    font-size: clamp(1.62rem, 7.2vw, 2rem);
    line-height: 1.1;
  }

  .question-page-shell .question-flow-intro .lede {
    display: none;
  }

  .topic-selection-panel .section-heading {
    text-align: center;
  }

  .topic-selection-panel .section-heading--tight p:last-child {
    margin-left: auto;
    margin-right: auto;
  }

  .question-page-shell .question-flow-card {
    gap: 12px;
    padding: 14px 12px;
  }

  .question-page-shell .topic-selection-panel {
    padding: 12px;
  }

  .question-page-shell .topic-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 8px;
    padding: 0;
  }

  .question-page-shell .topic-card {
    min-height: 82px;
    padding: 9px 10px;
    gap: 10px;
  }

  .question-page-shell .topic-card__icon {
    min-width: 48px;
    width: 48px;
    height: 48px;
    font-size: 1.35rem;
  }

  .question-page-shell .topic-card__title {
    font-size: 0.95rem;
    line-height: 1.25;
  }

  .home-hero-card,
  .question-flow-card,
  .topic-selection-panel,
  .question-intention,
  .question-draw-panel,
  .hero-spotlight-card,
  .reading-path-card,
  .topic-card {
    border-radius: 20px;
  }

  .home-primary-cta {
    width: 100%;
  }

  .home-secondary-cta {
    width: 100%;
  }

  .topic-card-grid {
    grid-template-columns: 1fr;
  }

  body[data-page='home'] .home-hero-copy--centered {
    gap: 6px;
  }

  body[data-page='home'] .home-hero-copy--centered .home-hero-title {
    font-size: clamp(1.58rem, 8vw, 2rem);
    line-height: 1.08;
  }

  body[data-page='home'] .home-hero-card--chooser {
    gap: 12px;
    padding: 16px 12px;
  }

  body[data-page='home'] .home-path-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
    overflow: visible;
    padding: 2px 0 4px;
  }

  body[data-page='home'] .reading-path-card--chooser {
    grid-template-rows: auto minmax(2.2em, auto) minmax(2.6em, auto);
    align-content: start;
    gap: 5px;
    padding: 9px 7px;
    min-height: 0;
  }

  body[data-page='home'] .reading-path-card__media {
    width: min(100%, 100px);
    aspect-ratio: 7 / 10;
    border-radius: 12px;
  }

  body[data-page='home'] .reading-path-card__label {
    font-size: clamp(0.86rem, 2.9vw, 0.94rem);
    line-height: 1.14;
    max-width: 11ch;
  }

  body[data-page='home'] .reading-path-card__meta {
    margin-top: 0;
    font-size: clamp(0.72rem, 2.6vw, 0.82rem);
    line-height: 1.3;
    color: #7a5f99;
  }

  body[data-page='home'] .home-hero-actions--subtle {
    width: 100%;
    margin-top: 4px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  body[data-page='home'] .home-secondary-cta {
    min-height: 44px;
    padding: 10px 12px;
    font-size: 0.9rem;
    letter-spacing: 0;
  }

  body[data-page='home'] .site-header .nav-brand {
    min-width: 0;
    max-width: calc(100vw - 126px);
  }

  body[data-page='home'] .site-header .logo-text {
    overflow-wrap: anywhere;
  }

  body[data-page='question-draw'] .question-draw-panel {
    gap: 10px;
    padding: 12px;
  }

  body[data-page='question-draw'] .question-draw-header {
    gap: 6px;
  }

  body[data-page='question-draw'] .question-selected-label {
    margin-bottom: 2px;
    font-size: 0.72rem;
  }

  body[data-page='question-draw'] .question-draw-header h2 {
    font-size: clamp(1.32rem, 5.6vw, 1.72rem);
    line-height: 1.08;
  }

  body[data-page='question-draw'] .board-toolbar {
    margin: 2px 0 0;
    gap: 8px;
  }

  body[data-page='question-draw'] .board-toolbar button {
    padding: 9px 12px;
    border-radius: 14px;
    font-size: 0.9rem;
    line-height: 1.1;
  }

  body[data-page='question-draw'] .selection-counter {
    padding: 6px 10px;
    font-size: 0.86rem;
  }

  body[data-page='question-draw'] #question-card-board.card-board--three {
    gap: 6px;
    margin: 0;
    padding: 8px 6px;
    min-height: 0;
  }

  body[data-page='question-draw'] #question-card-board.card-board--three .card-slot {
    width: clamp(60px, 17.2vw, 68px);
  }

  body[data-page='question-draw'] #question-actions {
    margin-top: 2px;
  }

  body[data-page='question-draw'] #question-actions button {
    flex-basis: 100%;
    min-height: 42px;
    padding: 10px 14px;
  }
}

@media (max-width: 480px) {
  .card-board.card-board--three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  body[data-page='question-draw'] #question-card-board.card-board--three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
    padding: 8px 4px;
  }
}

@media (max-width: 380px) {
  body[data-page='home'] .home-path-grid,
  body[data-page='home'] .home-hero-actions--subtle {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .site-header {
    padding-left: calc(env(safe-area-inset-left, 0px) + 14px);
    padding-right: calc(env(safe-area-inset-right, 0px) + 14px);
  }

  .question-flow-card {
    padding: 18px;
  }

  .topic-selection-panel,
  .question-intention,
  .question-draw-panel {
    padding: 16px;
  }
}

.daily-card-page {
  display: flex;
  justify-content: center;
  padding: calc(var(--nav-height) + 36px) 20px 64px;
}

.daily-card-hero {
  width: min(760px, 100%);
  text-align: center;
}

.daily-card-hero h1 {
  margin: 8px 0 10px;
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.8vw, 2.8rem);
}

.daily-card-intro {
  margin: 0 auto 24px;
  max-width: 62ch;
  color: var(--color-text-muted);
}

.daily-card-feature {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border-soft);
  border-radius: 24px;
  padding: 20px;
  box-shadow: var(--shadow-md);
}

.daily-card-date {
  margin: 0 0 12px;
  color: var(--color-text-muted-soft);
}

.daily-card-image {
  width: min(220px, 60vw);
  height: auto;
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
}

.daily-card-name {
  margin: 16px 0 8px;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 1.8rem);
}

.daily-card-orientation {
  margin: 0 0 10px;
  color: var(--gold);
  font-weight: 600;
}

.daily-card-meaning {
  margin: 0 auto;
  max-width: 60ch;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.daily-card-actions {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

/* Quiz: Tarot card personality */
.quiz-personality-page {
  width: min(100%, 760px);
}

.quiz-personality-card {
  background: linear-gradient(165deg, rgba(31, 22, 61, 0.9), rgba(17, 12, 34, 0.95));
  border: 1px solid rgba(248, 201, 112, 0.22);
  border-radius: 1.25rem;
  padding: clamp(1rem, 3vw, 2rem);
  box-shadow: 0 1.25rem 2.5rem rgba(5, 5, 14, 0.35);
}

.quiz-personality-intro {
  color: var(--text-soft);
  margin: 0.8rem 0 1.5rem;
}

.quiz-panel,
.quiz-result {
  margin-top: 0.75rem;
}

.quiz-progress {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.95rem;
}

.quiz-prompt {
  margin: 0.5rem 0 1rem;
  font-size: clamp(1.15rem, 4vw, 1.6rem);
}

.quiz-answers {
  display: grid;
  gap: 0.75rem;
}

.quiz-answer-btn {
  width: 100%;
  border: 1px solid rgba(248, 201, 112, 0.4);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-main);
  border-radius: 0.85rem;
  font: inherit;
  text-align: left;
  padding: 0.85rem 0.95rem;
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, background-color 140ms ease;
}

.quiz-answer-btn:hover,
.quiz-answer-btn:focus-visible {
  border-color: rgba(248, 201, 112, 0.8);
  background: rgba(248, 201, 112, 0.08);
  transform: translateY(-1px);
  outline: none;
}

.quiz-result {
  text-align: center;
}

.quiz-result-lead {
  margin: 0;
  color: var(--text-soft);
}

.quiz-result-title {
  margin: 0.45rem 0 0.9rem;
}

.quiz-result-image {
  width: min(58vw, 220px);
  height: auto;
  border-radius: 0.75rem;
  border: 1px solid rgba(248, 201, 112, 0.28);
  box-shadow: 0 1rem 2rem rgba(5, 5, 14, 0.45);
}

.quiz-result-summary {
  margin: 0.95rem auto 0;
  max-width: 48ch;
  color: var(--text-soft);
}

.quiz-result-actions {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.1rem;
}

.quiz-share-status {
  margin: 0.65rem 0 0;
  min-height: 1.2rem;
  color: var(--text-soft);
  font-size: 0.92rem;
}

@media (min-width: 720px) {
  .quiz-result-actions {
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  }
}

.today-page {
  display: grid;
  gap: 16px;
}

.today-card {
  background: var(--color-surface-soft);
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius-lg);
  padding: 18px;
}

.today-streak {
  margin: 0 0 8px;
  font-weight: 600;
  color: var(--gold);
}

.today-empty-copy,
.today-meaning {
  color: var(--color-text-muted);
}

.today-card__figure {
  margin: 0;
}

.today-card__figure img {
  width: min(280px, 100%);
  border-radius: var(--radius-md);
  display: block;
  margin: 0 auto 12px;
}

.today-keywords {
  font-size: 14px;
  color: var(--color-text-muted-soft);
  margin-bottom: 14px;
}

.today-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ─── Ladder B daily popup ───────────────────────────────────────────── */
#mt-ladder-b-popup {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9000;
  background: rgba(0, 0, 0, 0.35);
  animation: mt-lbp-fadein 300ms ease forwards;
  cursor: pointer;
}
#mt-ladder-b-popup.mt-lbp-fade-out {
  animation: mt-lbp-fadeout 400ms ease forwards;
}
@keyframes mt-lbp-fadein {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes mt-lbp-fadeout {
  from { opacity: 1; }
  to   { opacity: 0; }
}
.mt-lbp-card {
  background: #fff8f3;
  border-radius: 20px;
  padding: 2rem 2.5rem;
  text-align: center;
  max-width: 280px;
  width: 90vw;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
}
.mt-lbp-ring-wrap {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 0 auto 1rem;
}
.mt-lbp-ring {
  width: 120px;
  height: 120px;
  transform: rotate(-90deg);
}
.mt-lbp-ring-bg {
  fill: none;
  stroke: #f0e6d8;
  stroke-width: 8;
}
.mt-lbp-ring-fill {
  fill: none;
  stroke: #c9a26d;
  stroke-width: 8;
  stroke-linecap: round;
}
.mt-lbp-counter {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.mt-lbp-count {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  color: #3d2c1e;
  line-height: 1;
  font-family: 'DM Sans', sans-serif;
}
.mt-lbp-label {
  display: block;
  font-size: 0.7rem;
  color: #9c7b5a;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.2rem;
  font-family: 'DM Sans', sans-serif;
}
.mt-lbp-affirmation {
  font-size: 0.95rem;
  color: #5c3d1e;
  margin: 0.75rem 0 0;
  line-height: 1.6;
  font-family: 'Sarabun', sans-serif;
}
/* ─────────────────────────────────────────────────────────────────────── */
