/* ─── Tarot page styles ─── */

/* Mode toggle */
.mode-toggle {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin: 0 auto 40px;
  padding: 4px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: 100px;
  width: fit-content;
}
.mode-btn {
  padding: 8px 24px;
  border-radius: 100px;
  border: none;
  background: transparent;
  color: rgba(237,232,220,0.4);
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.25s ease;
}
.mode-btn.mode-btn--active {
  background: rgba(232,168,56,0.15);
  color: var(--amber);
  box-shadow: 0 0 20px rgba(232,168,56,0.1);
}
.mode-btn:hover:not(.mode-btn--active) {
  color: rgba(237,232,220,0.7);
}

/* Card slot click label */
.card-read-label {
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(237,232,220,0.3);
  margin-top: 8px;
  transition: color 0.2s;
}
.card-slot:hover .card-read-label { color: rgba(232,168,56,0.6); }

/* Per-card readings */
.card-readings {
  width: 100%;
  max-width: 720px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}
.card-reading {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 28px 32px;
}
.cr-position {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--amber);
  opacity: 0.7;
  margin-bottom: 8px;
}
.cr-card {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  color: var(--cream);
  margin-bottom: 16px;
}
.cr-orient {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(232,168,56,0.5);
  font-family: 'DM Sans', sans-serif;
  margin-left: 8px;
}
.cr-text p {
  font-size: 15px;
  color: rgba(237,232,220,0.82);
  line-height: 1.8;
  margin-bottom: 12px;
}
.cr-text p:last-child { margin-bottom: 0; }

/* Back nav */
.tarot-nav {
  padding: 28px 48px 0;
}
.nav-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: rgba(237,232,220,0.5);
  text-decoration: none;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}
.nav-back:hover { color: var(--amber); }

/* Header */
.tarot-header {
  text-align: center;
  padding: 60px 24px 48px;
}
.tarot-eyebrow {
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--amber);
  opacity: 0.7;
  margin-bottom: 16px;
}
.tarot-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(48px, 6vw, 80px);
  font-weight: 300;
  color: var(--cream);
  line-height: 1.1;
  margin-bottom: 16px;
}
.tarot-title em { color: var(--amber); font-style: italic; }
.tarot-subtitle {
  font-size: 16px;
  color: rgba(237,232,220,0.5);
  font-style: italic;
}

/* Container */
.tarot-container {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

/* Question form */
.question-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  animation: fade-in 0.6s ease-out;
}

/* Candle orb */
.candle-orb {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.co-inner {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, rgba(232,168,56,0.6), rgba(232,168,56,0.2), transparent);
  animation: pulse-orb 3s ease-in-out infinite;
}
.co-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(232,168,56,0.2);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.co-ring-1 { width: 60px; height: 60px; animation: pulse-orb 4s ease-in-out infinite; }
.co-ring-2 { width: 80px; height: 80px; border-color: rgba(232,168,56,0.1); animation: pulse-orb 5s ease-in-out infinite 0.5s; }

/* Question input */
.input-wrapper {
  width: 100%;
  max-width: 600px;
}
.question-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 24px;
  color: var(--cream);
  font-family: 'DM Sans', sans-serif;
  font-size: 17px;
  resize: none;
  line-height: 1.6;
  transition: border-color 0.3s, box-shadow 0.3s;
  outline: none;
}
.question-input::placeholder { color: rgba(237,232,220,0.3); font-style: italic; }
.question-input:focus {
  border-color: rgba(232,168,56,0.5);
  box-shadow: 0 0 0 3px rgba(232,168,56,0.08);
}
.input-meta {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}
.char-count {
  font-size: 12px;
  color: rgba(237,232,220,0.25);
}

/* Draw button */
.draw-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 36px;
  background: linear-gradient(135deg, rgba(232,168,56,0.15), rgba(232,168,56,0.08));
  border: 1px solid rgba(232,168,56,0.4);
  border-radius: 100px;
  color: var(--amber);
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.05em;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.3s, transform 0.2s;
}
.draw-btn:hover:not(:disabled) {
  border-color: rgba(232,168,56,0.7);
  box-shadow: 0 0 30px rgba(232,168,56,0.15);
  transform: translateY(-2px);
}
.draw-btn:active:not(:disabled) { transform: translateY(0); }
.draw-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.btn-shimmer {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(232,168,56,0.15), transparent);
  background-size: 200% 100%;
  animation: shimmer 3s ease-in-out infinite;
}
.btn-text { position: relative; z-index: 1; }
.btn-icon { position: relative; z-index: 1; display: flex; }

/* Error */
.error-msg {
  font-size: 13px;
  color: rgba(220, 100, 80, 0.9);
  text-align: center;
  min-height: 20px;
}

/* Reading section */
.reading-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
  animation: fade-in 0.6s ease-out;
}

/* Cards display */
.cards-display { width: 100%; }
.cards-row {
  display: flex;
  justify-content: center;
  gap: 24px;
}
.card-slot {
  position: relative;
  perspective: 800px;
}
.card-face {
  width: 130px;
  height: 200px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cormorant Garamond', serif;
  font-size: 48px;
  color: rgba(232,168,56,0.4);
}

/* Card back (shown during flip) */
.card-face.card-flip {
  background: var(--bg-card);
  border: 1px solid var(--border);
}

/* Card drawn states */
.card-face.card-drawn {
  background: var(--bg-card);
  border: 1px solid rgba(232,168,56,0.3);
  animation: card-draw 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  opacity: 0;
  font-size: unset;
  color: unset;
}

/* Single-card (Daily Draw) layout — widens the lone slot for a centered, full-width feel. */
.cards-row.is-single .card-face {
  width: 200px;
  height: 320px;
}
.cards-row.is-single .card-read-label { display: none; }
.position-labels.is-single span {
  width: 200px;
}
.card-face.card-drawn.delay-0 { animation-delay: 0.2s; }
.card-face.card-drawn.delay-1 { animation-delay: 0.5s; }
.card-face.card-drawn.delay-2 { animation-delay: 0.8s; }

.card-inner {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px;
}
.card-back-pattern {
  position: absolute;
  inset: 0;
  padding: 12px;
  opacity: 0.6;
}
.card-back-pattern svg {
  width: 100%;
  height: 100%;
}
.card-front {
  position: relative;
  z-index: 1;
  text-align: center;
}
.card-arcana-mark {
  font-size: 14px;
  color: rgba(232,168,56,0.6);
  margin-bottom: 4px;
}
.card-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--cream);
  line-height: 1.3;
}
.card-orientation {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(232,168,56,0.5);
  margin-top: 6px;
}

/* Position labels */
.position-labels {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 16px;
}
.position-labels span {
  width: 130px;
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(237,232,220,0.35);
}

/* Reading content */
.reading-content {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 40px;
  max-width: 720px;
}
.reading-loading {
  text-align: center;
  padding: 40px 0;
}
.loading-stars {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}
.loading-stars span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--amber);
  animation: twinkle 1.5s ease-in-out infinite;
}
.loading-stars span:nth-child(2) { animation-delay: 0.3s; }
.loading-stars span:nth-child(3) { animation-delay: 0.6s; }
.loading-stars p {
  font-size: 14px;
  font-style: italic;
  color: rgba(237,232,220,0.4);
}
.reading-label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--amber);
  opacity: 0.6;
  margin-bottom: 12px;
}
.reading-question {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px;
  font-style: italic;
  color: rgba(237,232,220,0.5);
  margin-bottom: 24px;
  line-height: 1.5;
}
.reading-text p {
  font-size: 15px;
  color: rgba(237,232,220,0.85);
  line-height: 1.85;
  margin-bottom: 16px;
}
.reading-text p:last-child { margin-bottom: 0; }

/* Draw again */
.draw-again-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 100px;
  color: rgba(237,232,220,0.5);
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.draw-again-btn:hover {
  border-color: rgba(232,168,56,0.4);
  color: var(--amber);
}

/* Responsive */
@media (max-width: 600px) {
  .tarot-nav { padding: 20px 24px 0; }
  .tarot-header { padding: 40px 24px 32px; }
  .cards-row { gap: 12px; }
  .card-face { width: 100px; height: 154px; font-size: 36px; }
  .position-labels { gap: 12px; }
  .position-labels span { width: 100px; font-size: 10px; }
  .reading-content { padding: 28px 20px; }
  .cards-row.is-single .card-face { width: 160px; height: 256px; }
  .position-labels.is-single span { width: 160px; }
}