:root {
  --bg-deep: #070811;
  --bg-surface: #0e101f;
  --bg-card: #14172b;
  --bg-elevated: #1b1f38;
  --gold: #d4af37;
  --gold-light: #f3dc8b;
  --gold-dim: rgba(212, 175, 55, 0.24);
  --text-main: #f6f3ea;
  --text-muted: #b3b0c4;
  --text-soft: #85829a;
  --border-subtle: rgba(212, 175, 55, 0.18);
  --success: #58c492;
  --warning: #e5a93c;
  --danger: #e06c75;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --shadow-card: 0 14px 32px rgba(0, 0, 0, 0.55);
  --tarot-back-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 200'%3E%3Crect width='120' height='200' rx='8' fill='%2316122c'/%3E%3Crect x='6' y='6' width='108' height='188' rx='5' fill='none' stroke='%23d4af37' stroke-width='1.5' stroke-opacity='0.8'/%3E%3Crect x='12' y='12' width='96' height='176' rx='3' fill='none' stroke='%23d4af37' stroke-width='0.75' stroke-dasharray='3 3' stroke-opacity='0.55'/%3E%3Ccircle cx='60' cy='100' r='26' fill='none' stroke='%23d4af37' stroke-width='1.2' stroke-opacity='0.75'/%3E%3Cpath d='M60 66 L64 96 L94 100 L64 104 L60 134 L56 104 L26 100 L56 96 Z' fill='%23d4af37' fill-opacity='0.78'/%3E%3Ccircle cx='60' cy='34' r='4' fill='none' stroke='%23f3dc8b' stroke-width='1'/%3E%3Ccircle cx='60' cy='166' r='4' fill='none' stroke='%23f3dc8b' stroke-width='1'/%3E%3Cpath d='M18 22 L28 22 M22 18 L22 28 M102 22 L92 22 M98 18 L98 28 M18 178 L28 178 M22 172 L22 182 M102 178 L92 178 M98 172 L98 182' stroke='%23d4af37' stroke-width='0.9' stroke-opacity='0.6'/%3E%3C/svg%3E");
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(circle at 20% 0%, #16142c 0%, var(--bg-deep) 55%, #05060c 100%);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

.hidden {
  display: none !important;
}

.container {
  width: min(1380px, 95%);
  margin: 0 auto;
}

.gold-text {
  background: linear-gradient(120deg, var(--gold), var(--gold-light), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-gold {
  background: linear-gradient(135deg, #e0bd48, #c59b27);
  color: #111018;
  box-shadow: 0 6px 22px rgba(212, 175, 55, 0.28);
}

.btn-gold:hover {
  box-shadow: 0 8px 26px rgba(212, 175, 55, 0.42);
}

.btn-outline {
  background: rgba(212, 175, 55, 0.08);
  color: var(--gold-light);
  border-color: var(--border-subtle);
}

.btn-outline:hover {
  background: rgba(212, 175, 55, 0.16);
  border-color: var(--gold);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border-color: rgba(255, 255, 255, 0.12);
}

.btn-ghost:hover {
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.28);
}

.btn-lg {
  padding: 13px 24px;
  font-size: 0.98rem;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.84rem;
}

.btn-xs {
  padding: 5px 11px;
  font-size: 0.78rem;
}

.btn-block {
  width: 100%;
}

.link-btn {
  background: none;
  border: none;
  color: var(--gold-light);
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  padding: 0;
}

/* Topbar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(14px);
  background: rgba(7, 8, 17, 0.84);
  border-bottom: 1px solid var(--border-subtle);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
  padding: 8px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-main);
}

.brand-icon {
  border-radius: 10px;
}

.brand-name {
  display: block;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: 0.02em;
}

.brand-tag {
  display: block;
  font-size: 0.72rem;
  color: var(--text-soft);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.free-pill {
  font-size: 0.78rem;
  color: var(--gold-light);
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--gold-dim);
  padding: 6px 12px;
  border-radius: 999px;
}

/* Session Timer Pill & Alert Banner */
.timer-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(88, 196, 146, 0.14);
  border: 1px solid rgba(88, 196, 146, 0.4);
  color: #bdf2d9;
  font-size: 0.82rem;
}

.timer-pill.warn {
  background: rgba(229, 169, 60, 0.18);
  border-color: rgba(229, 169, 60, 0.55);
  color: #ffe3a3;
}

.timer-pill.urgent {
  background: rgba(224, 108, 117, 0.22);
  border-color: rgba(224, 108, 117, 0.65);
  color: #ffc5ca;
}

.timer-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
}

.timer-alert {
  position: sticky;
  top: 68px;
  z-index: 35;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 10px 18px;
  background: rgba(27, 31, 56, 0.96);
  border-bottom: 1px solid var(--gold);
  font-size: 0.88rem;
}

.icon-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
}

/* Hero Section */
.hero {
  padding: 46px 0 32px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: 40px;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 14px;
}

.hero h1 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.2rem, 4.4vw, 3.45rem);
  line-height: 1.12;
  margin: 0 0 18px;
}

.hero-sub {
  color: var(--text-muted);
  font-size: 1.03rem;
  max-width: 560px;
  margin: 0 0 26px;
}

.hero-cta-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.84rem;
  color: var(--text-soft);
}

/* Hero 3-Card Rotating Stack */
.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 330px;
}

.orb-glow {
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.24), transparent 70%);
  filter: blur(20px);
  pointer-events: none;
}

.hero-card-stack {
  position: relative;
  width: 340px;
  height: 310px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.preview-card {
  position: absolute;
  width: 176px;
  height: 286px;
  padding: 6px;
  border-radius: 14px;
  border: 1.5px solid rgba(212, 175, 55, 0.45);
  background: linear-gradient(155deg, #1b1734, #0c0e1c);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform 0.7s cubic-bezier(0.22, 0.8, 0.36, 1), opacity 0.6s ease, filter 0.6s ease, border-color 0.4s ease;
}

.preview-card.pos-left {
  transform: translateX(-88px) translateY(10px) rotate(-13deg) scale(0.88);
  opacity: 0.82;
  z-index: 1;
  filter: brightness(0.82);
}

.preview-card.pos-centre {
  transform: translateX(0) translateY(-4px) rotate(0deg) scale(1);
  opacity: 1;
  z-index: 3;
  border-color: var(--gold);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.7), 0 0 24px rgba(212, 175, 55, 0.22);
}

.preview-card.pos-right {
  transform: translateX(88px) translateY(10px) rotate(13deg) scale(0.88);
  opacity: 0.82;
  z-index: 2;
  filter: brightness(0.82);
}

.hero-card-stack:hover .preview-card.pos-centre {
  transform: translateX(0) translateY(-9px) scale(1.03);
}

.preview-inner {
  width: 100%;
  height: 100%;
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px;
  gap: 8px;
}

.preview-inner.has-art {
  display: none;
}

.preview-star {
  font-size: 2rem;
  color: var(--gold);
}

.preview-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.1rem;
  font-weight: 600;
}

.card-rws-img,
.hero-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

/* Sanctuary & Spread Tabs */
.sanctuary {
  padding: 18px 0 64px;
}

.sanctuary-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.spread-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.spread-tab {
  background: var(--bg-surface);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 9px 14px;
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  transition: all 0.18s ease;
}

.spread-tab small {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--gold-light);
  opacity: 0.9;
}

.spread-tab.active {
  background: rgba(212, 175, 55, 0.16);
  border-color: var(--gold);
  color: var(--text-main);
}

.spread-tab.locked {
  opacity: 0.78;
}

.table-controls {
  display: flex;
  gap: 8px;
}

/* Two-Column Workspace */
.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(380px, 0.96fr);
  gap: 22px;
  align-items: start;
}

.card-table-panel {
  background: rgba(14, 16, 31, 0.88);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  min-height: 680px;
  min-width: 0;
}

.table-instruction {
  background: rgba(212, 175, 55, 0.07);
  border: 1px solid rgba(212, 175, 55, 0.16);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.86rem;
  color: var(--text-muted);
}

/* Spread Board & Slots */
.spread-board {
  display: grid;
  gap: 18px;
  justify-items: center;
  align-items: start;
  padding: 10px 4px;
  flex: 1 1 auto;
  align-content: center;
}

.spread-board.spread-1_card {
  grid-template-columns: minmax(220px, 360px);
  justify-content: center;
}

.spread-board.spread-3_card {
  grid-template-columns: repeat(3, minmax(150px, 1fr));
}

.spread-board.spread-5_card,
.spread-board.spread-7_card,
.spread-board.spread-10_card {
  grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
}

.spread-slot {
  width: 100%;
  max-width: 210px;
  aspect-ratio: 2 / 3.2;
  border: 1.5px dashed rgba(212, 175, 55, 0.45);
  border-radius: 14px;
  background: rgba(20, 23, 43, 0.65);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px 10px;
  gap: 6px;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.spread-board.spread-1_card .spread-slot:not(.filled) {
  max-width: 225px;
}

.spread-slot.drag-over {
  border-style: solid;
  border-color: var(--gold-light);
  background: rgba(212, 175, 55, 0.16);
  transform: scale(1.02);
}

.spread-slot.filled {
  max-width: 100%;
  border: none;
  background: transparent;
  padding: 0;
  aspect-ratio: auto;
  gap: 10px;
}

.slot-number {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--gold-light);
}

.slot-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
}

.slot-hint {
  font-size: 0.76rem;
  color: var(--text-soft);
}

/* 3D Flippable & Reversible Card */
.placed-card {
  width: 100%;
  max-width: 184px;
  aspect-ratio: 2 / 3.2;
  perspective: 900px;
  cursor: pointer;
}

.spread-board.spread-1_card .placed-card {
  max-width: 216px;
}

.card-face {
  width: 100%;
  height: 100%;
  border-radius: 12px;
  backface-visibility: hidden;
  transition: transform 0.55s cubic-bezier(0.22, 0.8, 0.36, 1);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.card-face-back {
  position: absolute;
  inset: 0;
  background-color: #16122c;
  background-image: var(--tarot-back-svg);
  background-size: cover;
  background-position: center;
  border: 1.5px solid var(--gold);
}

.card-face-front {
  position: relative;
  width: 100%;
  height: 100%;
  background: linear-gradient(160deg, #1d1936, #0d1020);
  border: 1.5px solid var(--gold);
  transform: rotateY(180deg);
}

.placed-card:not(.flipped) .card-face-front {
  transform: rotateY(180deg);
}

.placed-card.flipped .card-face-back {
  transform: rotateY(180deg);
}

.placed-card.flipped .card-face-front {
  transform: rotateY(0deg);
}

.placed-card.flipped.is-reversed .card-face-front {
  transform: rotateY(0deg) rotate(180deg);
}

.card-art-frame {
  width: 100%;
  height: 100%;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  text-align: center;
}

.card-numeral {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 0.85rem;
  color: var(--gold-light);
}

.card-emblem {
  font-size: 1.8rem;
  color: var(--gold);
}

.card-name {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.2;
}

.card-suit-tag {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Verbatim Card Text Directly Below Each Pulled Card */
.slot-reading-box {
  width: 100%;
  background: rgba(27, 31, 56, 0.78);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 12px;
  padding: 10px 12px;
  text-align: left;
}

.slot-reading-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.slot-pos-tag {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-soft);
}

.orientation-badge {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(88, 196, 146, 0.16);
  color: #a8f0cf;
}

.orientation-badge.reversed {
  background: rgba(229, 169, 60, 0.2);
  color: #ffe09e;
}

.slot-reading-title {
  margin: 0 0 4px;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 0.98rem;
  color: var(--gold-light);
  line-height: 1.25;
}

.slot-reading-text {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.48;
}

.pull-more-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(212, 175, 55, 0.09);
  border: 1px solid var(--border-subtle);
  font-size: 0.85rem;
}

.pull-more-bar p {
  margin: 0;
  color: var(--text-muted);
}

/* 78-Card Deck Fan with Ornate Tarot Backs & Right-to-Left Shuffle */
.deck-tray-wrap {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 14px;
}

.deck-tray-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.deck-tray-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.deck-count-label {
  margin-left: 10px;
  opacity: 0.85;
}

.deck-fan {
  display: flex;
  align-items: center;
  overflow-x: auto;
  padding: 14px 8px 16px;
  scrollbar-width: thin;
  scrollbar-color: rgba(212, 175, 55, 0.45) transparent;
}

.fan-card {
  flex: 0 0 auto;
  width: 60px;
  height: 100px;
  margin-left: -30px;
  border-radius: 8px;
  border: 1px solid rgba(212, 175, 55, 0.65);
  background-color: #16122c;
  background-image: var(--tarot-back-svg);
  background-size: cover;
  background-position: center;
  box-shadow: -4px 5px 14px rgba(0, 0, 0, 0.52);
  cursor: grab;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.fan-card:first-child {
  margin-left: 0;
}

.fan-card:hover:not(.drawn) {
  transform: translateY(-12px) scale(1.04);
  border-color: var(--gold-light);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.65), 0 0 12px rgba(212, 175, 55, 0.3);
  z-index: 4;
}

.fan-card.drawn {
  opacity: 0.18;
  pointer-events: none;
  cursor: default;
}

@keyframes silkenCardRiffleRTL {
  0% {
    transform: translateX(0) translateY(0) rotate(0deg);
  }
  30% {
    transform: translateX(22px) translateY(-6px) rotate(3deg);
  }
  65% {
    transform: translateX(-34px) translateY(-12px) rotate(-5deg);
  }
  100% {
    transform: translateX(0) translateY(0) rotate(0deg);
  }
}

.deck-fan.shuffling .fan-card {
  animation: silkenCardRiffleRTL 0.55s cubic-bezier(0.35, 0.05, 0.25, 1) both;
  animation-delay: calc((77 - var(--i, 0)) * 6ms);
}

/* Balanced & Sticky Desktop Chat Consultation Panel */
.chat-panel {
  position: sticky;
  top: 84px;
  background: rgba(14, 16, 31, 0.92);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  height: calc(100vh - 104px);
  min-height: 640px;
  max-height: 820px;
  min-width: 0;
  overflow: hidden;
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-subtle);
  background: rgba(212, 175, 55, 0.06);
}

.chat-header-meta {
  flex: 1 1 auto;
  min-width: 0;
}

.chat-summary-btn {
  margin-left: auto;
  white-space: nowrap;
}

.reader-avatar-wrap {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  padding: 2px;
  border: 1.5px solid var(--gold);
  background: #121024;
  flex-shrink: 0;
  overflow: hidden;
  transition: box-shadow 0.3s ease;
}

.reader-avatar-wrap.is-typing {
  box-shadow: 0 0 18px rgba(212, 175, 55, 0.55);
}

.reader-avatar-wrap.is-speaking {
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.7);
}

.reader-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 20%;
  display: block;
}

.chat-header h2 {
  margin: 0;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.12rem;
  color: var(--gold-light);
}

.reader-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.online-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
}

.chat-voice-btn {
  margin-left: auto;
  white-space: nowrap;
}

.chat-voice-btn.voice-active {
  border-color: var(--gold);
  color: var(--gold-light);
  background: rgba(212, 175, 55, 0.14);
}

.chat-messages {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  scrollbar-width: thin;
  scrollbar-color: rgba(212, 175, 55, 0.3) transparent;
}

.msg-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
}

.msg-row.assistant {
  justify-content: flex-start;
}

.msg-row.user {
  justify-content: flex-end;
}

.msg-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(212, 175, 55, 0.65);
  object-fit: cover;
  object-position: center 20%;
  flex-shrink: 0;
  margin-top: 2px;
}

.msg {
  max-width: 84%;
  padding: 12px 15px;
  border-radius: 16px;
  font-size: 0.92rem;
  line-height: 1.6;
  text-align: left;
}

.msg.assistant {
  position: relative;
  padding-right: 36px;
  background: linear-gradient(160deg, rgba(28, 32, 58, 0.96), rgba(20, 23, 44, 0.96));
  border: 1px solid rgba(212, 175, 55, 0.16);
  border-top-left-radius: 4px;
  color: var(--text-main);
}

.msg.user {
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.22), rgba(168, 134, 40, 0.14));
  border: 1px solid rgba(212, 175, 55, 0.42);
  border-top-right-radius: 4px;
  color: #fffaf0;
  text-align: left;
}

.msg-audio-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid rgba(212, 175, 55, 0.25);
  background: rgba(14, 16, 31, 0.65);
  color: var(--text-muted);
  font-size: 0.72rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all 0.16s ease;
}

.msg-audio-btn:hover,
.msg-audio-btn.speaking {
  border-color: var(--gold);
  color: var(--gold-light);
  background: rgba(212, 175, 55, 0.16);
}

.msg-heading {
  margin: 0 0 8px;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--gold-light);
  letter-spacing: 0.01em;
}

.msg.assistant strong {
  color: #f3dc8b;
  font-weight: 600;
}

.msg p {
  margin: 0 0 11px;
}

.msg p:last-child {
  margin-bottom: 0;
}

.msg-bullet {
  padding-left: 10px;
}

.quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 14px 10px;
}

.chip {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 5px 11px;
  font-size: 0.76rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.chip:hover {
  border-color: var(--gold);
  color: var(--gold-light);
}

.turnstile-wrap {
  padding: 0 14px 8px;
}

.chat-input-bar {
  display: flex;
  gap: 8px;
  padding: 12px 14px;
  border-top: 1px solid var(--border-subtle);
  background: rgba(8, 10, 20, 0.88);
}

.chat-input-bar input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: var(--bg-surface);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.9rem;
}

.chat-input-bar input:focus {
  outline: none;
  border-color: var(--gold);
}

.btn-mic {
  width: 40px;
  height: 40px;
  padding: 0;
  flex-shrink: 0;
  font-size: 1rem;
}

.btn-mic.listening {
  border-color: var(--danger);
  background: rgba(224, 108, 117, 0.2);
  color: #ffd0d4;
}

.btn-mic:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  transform: none;
}

.btn-send {
  padding: 10px 18px;
}

.chat-footer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 14px 10px;
  background: rgba(8, 10, 20, 0.94);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.chat-footer-note {
  font-size: 0.74rem;
  color: var(--text-soft);
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(4, 5, 11, 0.78);
  backdrop-filter: blur(6px);
  display: grid;
  place-items: center;
  padding: 18px;
}

.modal-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  background: var(--bg-surface);
  border: 1px solid var(--gold-dim);
  border-radius: var(--radius-lg);
  padding: 26px 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.75);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
}

.modal-eyebrow {
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--gold-light);
  margin-bottom: 6px;
}

.modal-card h3 {
  margin: 0 0 8px;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.4rem;
}

.modal-sub {
  margin: 0 0 16px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.currency-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.curr-btn {
  padding: 10px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: var(--bg-card);
  color: var(--text-muted);
  font-family: inherit;
  cursor: pointer;
}

.curr-btn.active {
  border-color: var(--gold);
  background: rgba(212, 175, 55, 0.14);
  color: var(--text-main);
}

.modal-perks {
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
  font-size: 0.85rem;
  color: var(--text-muted);
  display: grid;
  gap: 6px;
}

.checkout-form {
  display: grid;
  gap: 10px;
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.checkout-form input,
.promo-box input {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: var(--bg-card);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.88rem;
}

.promo-box {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.82rem;
}

.promo-row {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.promo-status {
  display: block;
  margin-top: 6px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.promo-status.ok {
  color: var(--success);
}

.modal-footnote {
  margin: 14px 0 0;
  font-size: 0.76rem;
  color: var(--text-soft);
  text-align: center;
}

/* Footer with Crisp Gold/Cream Links */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 30px 0 36px;
  background: rgba(6, 7, 14, 0.94);
}

.footer-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-note {
  max-width: 720px;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 8px 0 0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 0.86rem;
  align-items: center;
}

.footer-links a,
.footer-links a:visited {
  color: #e4dec9;
  text-decoration: none;
  transition: color 0.18s ease;
}

.footer-links a:hover,
.footer-links a:focus {
  color: var(--gold-light);
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 980px) {
  .hero-grid,
  .workspace-grid {
    grid-template-columns: 1fr;
  }

  .card-table-panel {
    min-height: auto;
  }

  .chat-panel {
    position: static;
    top: auto;
    height: 620px;
    min-height: 0;
    max-height: 82vh;
  }
}

@media (max-width: 600px) {
  .form-row-2 {
    grid-template-columns: 1fr;
  }

  .spread-board.spread-3_card {
    grid-template-columns: 1fr;
  }

  .preview-card.pos-left {
    transform: translateX(-56px) translateY(8px) rotate(-11deg) scale(0.84);
  }

  .preview-card.pos-right {
    transform: translateX(56px) translateY(8px) rotate(11deg) scale(0.84);
  }
}