/* Tarot Reading - Optimized CSS (Modified - Box Shadows Removed) */

:root {
  --primary-color: #ff00ee;
  --secondary-color: #00ffff;
  --text-color: #e0e0e0;
  --bg-color: #FFFFFF0D;
  --border-radius: 15px;
  --transition: all 0.3s ease;
  --card-aspect-ratio: 3 / 5;
  --shadow-glow: 0 0 15px rgba(255, 0, 238, 0.7); /* Variable definition kept */
  --gradient-primary: linear-gradient(90deg, #8a2be2, #4169e1);
}

/* Base Container Styles */
#tarot-reading-container {
  max-width: 1000px;
  margin: 0 auto;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', Arial, sans-serif;
  padding: 0px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  border-radius: var(--border-radius);
  color: var(--text-color);
}

.combined-tarot-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
  position: relative;
  perspective: 1000px;
  background: #FFFFFF0D;
  border-radius: var(--border-radius);
  /* box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.1); <-- DELETED */
  margin-top: 10px;
  overflow: hidden;
  transition: min-height 0.5s ease;
  min-height: 240px;
}

/* Reading Type-specific Heights */
.combined-tarot-container[data-reading-type="daily"],
.combined-tarot-container[data-reading-type="yes_no"],
.combined-tarot-container[data-reading-type="daily_love"],
.combined-tarot-container[data-reading-type="daily_career"] {
  min-height: 340px;
}

.combined-tarot-container[data-reading-type="six_card"] {
  min-height: 640px;
}

.combined-tarot-container[data-reading-type="celtic_cross"] {
  min-height: 600px;
}

/* Card Area */
.card-area {
  width: 100%;
  height: 260px;
  position: relative;
  display: flex;
  align-items: center;
  overflow-x: auto;
  overflow-y: hidden;
  margin: 10px 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.5) transparent;
  -webkit-overflow-scrolling: touch;
  align-self: stretch;
}

.combined-tarot-container.small-spread .card-area {
  justify-content: center;
}

/* Scrollbar Styles */
.card-area::-webkit-scrollbar {
  height: 8px;
}

.card-area::-webkit-scrollbar-track {
  background: transparent;
}

.card-area::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.5);
  border-radius: 4px;
}

/* Card Wrapper */
.card-wrapper {
  display: inline-flex;
  align-items: center;
  min-width: 100%;
  height: 100%;
}

/* Spread Areas - Base Styles */
.spread-area {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  width: 100%;
  max-width: 600px;
  margin-bottom: 20px;
}

/* Three Card Spread */
.spread-area.three-card {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  max-width: 500px;
  margin: 10px;
}

.spread-area.three-card #present-wrapper {
  grid-column: 1;
  grid-row: 1;
}

.spread-area.three-card #future-wrapper {
  grid-column: 2;
  grid-row: 1;
}

.spread-area.three-card #past-wrapper {
  grid-column: 1 / span 2;
  grid-row: 2;
  justify-self: center;
}

/* Card Elements */
.tarot-card-back,
.tarot-card-front,
.spread-position {
  position: relative;
  display: inline-block;
  width: 100%;
  aspect-ratio: var(--card-aspect-ratio);
  max-width: 150px;
  transition: var(--transition);
  transform-style: preserve-3d;
  backface-visibility: hidden;
  /* box-shadow: none; <-- DELETED */
  border-radius: 3px;
  overflow: hidden;
  cursor: pointer;
}

.tarot-card-back svg,
.tarot-card-front img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.tarot-card-front {
  background: transparent;
  z-index: 30;
}

.tarot-card-back.arranged {
  position: absolute;
  transition: transform 0.3s ease;
}

/* Question & Button Container */
.question-button-container {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 30px;
  box-sizing: border-box;
  background: #FFFFFF0D;
  border-radius: var(--border-radius);
  /* box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.1); <-- DELETED */
}

#question-container {
  flex-grow: 1;
  display: flex;
  align-items: center;
  position: relative;
}

/* Tarot Question Input */
#tarot-question {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  border: 1px solid var(--primary-color);
  border-radius: 5px;
  background-color: #FFFFFF0D;
  color: white;
  min-height: 80px;
  resize: none;
  overflow-y: auto;
  white-space: pre-wrap;
  word-wrap: break-word;
  line-height: 1.5;
  text-align: left;
  vertical-align: top;
  box-sizing: border-box;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  padding-bottom: 25px;
}

#tarot-question::placeholder {
  color: rgba(255, 255, 255, 0.7);
  opacity: 1;
}

/* Action Button */
#draw-tarot-card {
  flex-shrink: 0;
  display: block;
  padding: 12px 24px;
  background: var(--gradient-primary);
  color: white;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font: bold 18px 'Cinzel', serif;
  border-radius: 30px;
  white-space: nowrap;
  margin: 20px auto;
  text-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
  /* box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); <-- DELETED */
  position: relative;
  overflow: hidden;
  min-width: 150px;
  height: 100%;
}

#draw-tarot-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: rotate(45deg);
  transition: var(--transition);
}

#draw-tarot-card:hover {
  transform: scale(1.05);
  /* box-shadow: 0 5px 20px rgba(255, 255, 255, 0.3); <-- DELETED */
}

#draw-tarot-card:hover::before {
  left: 100%;
}

#draw-tarot-card:active {
  transform: scale(0.95);
}

#draw-tarot-card:disabled {
  background: #cccccc;
  cursor: not-allowed;
  opacity: 0.7;
}

/* Interpretation Area */
#tarot-interpretation {
  display: none;
  text-align: left;
  margin-top: 20px;
  padding: 25px;
  background: #FFFFFF0D;
  border: 1px solid #FFFFFF00;
  border-radius: var(--border-radius);
  /* box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1); <-- DELETED */
  width: 100%;
  box-sizing: border-box;
  margin-left: auto;
  margin-right: auto;
  color: #fff;
  transition: var(--transition);
}

#tarot-card-name {
  margin: 0 0 20px;
  color: var(--primary-color);
  text-align: center;
  font: bold 28px 'Cinzel', serif;
  text-shadow: 0 0 10px rgba(255, 0, 238, 0.7);
  letter-spacing: 2px;
}

#tarot-card-meaning {
  color: var(--text-color);
  line-height: 1.8;
  font-size: 16px;
  text-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
}

/* Loading Animation */
.loading-spinner {
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-top-color: var(--primary-color);
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: mysticalSpin 1s linear infinite, glow 2s ease-in-out infinite alternate;
  margin: 30px auto;
  /* box-shadow: var(--shadow-glow); <-- DELETED */
}

@keyframes mysticalSpin {
  to { transform: rotate(360deg); }
}

/* Kept keyframes as animation relies on it */
@keyframes glow {
  from { box-shadow: 0 0 5px var(--primary-color); }
  to { box-shadow: 0 0 25px var(--primary-color), 0 0 50px var(--primary-color); }
}

@keyframes flipIn {
  from {
    transform: translate(-50%, -50%) rotateY(180deg);
    opacity: 0;
  }
  to {
    transform: translate(-50%, -50%) rotateY(0deg);
    opacity: 1;
  }
}

@keyframes flipOut {
  from {
    transform: translate(-50%, -50%) rotateY(0deg);
    opacity: 1;
  }
  to {
    transform: translate(-50%, -50%) rotateY(-180deg);
    opacity: 0;
  }
}

.flip-in {
  animation: flipIn 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

.flip-out {
  animation: flipOut 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

/* Spread Position Styles */
.spread-position-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.spread-label {
  font-size: 14px;
  color: #ffffff;
  margin-bottom: 3px;
  text-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
  text-align: center;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spread-position {
  border: 2px dashed rgba(255, 255, 255, 0.3);
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  aspect-ratio: var(--card-aspect-ratio);
  max-width: 150px;
  border-radius: 3px;
}

.spread-position:hover {
  border-color: rgba(255, 255, 255, 0.5);
  /* box-shadow: 0 0 15px rgba(255, 255, 255, 0.2); <-- DELETED */
}

/* Celtic Cross Spread Layout */
.spread-area.celtic-cross {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, auto);
  gap: 10px;
  max-width: 100%;
  padding: 0px;
  justify-items: center;
}

/* Celtic Cross Card Positions */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(1) { grid-area: 2 / 2 / 3 / 3; } /* Centre (1) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(2) { grid-area: 2 / 2 / 3 / 3; transform: rotate(90deg); } /* Crossing (2) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(3) { grid-area: 3 / 2 / 4 / 3; } /* Basis (3) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(4) { grid-area: 2 / 1 / 3 / 2; } /* Recent Past (4) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(5) { grid-area: 1 / 2 / 2 / 3; } /* Possible Outcome (5) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(6) { grid-area: 2 / 3 / 3 / 4; } /* Near Future (6) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(7) { grid-area: 4 / 4 / 5 / 5; } /* Self (7) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(8) { grid-area: 3 / 4 / 4 / 5; } /* Environment (8) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(9) { grid-area: 2 / 4 / 3 / 5; } /* Hopes and Fears (9) */
.spread-area.celtic-cross .spread-position-wrapper:nth-child(10) { grid-area: 1 / 4 / 2 / 5; } /* Outcome (10) */

/* Horseshoe Spread Layout */
.spread-area.horseshoe-spread {
  display: grid;
  grid-template-columns: repeat(15, 1fr);
  grid-template-rows: repeat(8, auto);
  gap: 10px;
  max-width: 100%;
  padding: 2px;
  justify-items: center;
}

.spread-area.horseshoe-spread .spread-position-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 180px;
}

/* Horseshoe Card Positions */
.spread-area.horseshoe-spread #past-wrapper { grid-area: 7 / 1 / 9 / 4; }
.spread-area.horseshoe-spread #present-wrapper { grid-area: 5 / 3 / 7 / 6; }
.spread-area.horseshoe-spread #future-wrapper { grid-area: 2 / 4 / 4 / 7; }
.spread-area.horseshoe-spread #advice-wrapper { grid-area: 1 / 7 / 3 / 10; }
.spread-area.horseshoe-spread #influences-wrapper { grid-area: 2 / 10 / 4 / 13; }
.spread-area.horseshoe-spread #obstacle-wrapper { grid-area: 5 / 11 / 7 / 14; }
.spread-area.horseshoe-spread #outcome-wrapper { grid-area: 7 / 13 / 9 / 16; }

/* Progress Bar */
.progress-bar-container {
  width: 100%;
  height: 20px;
  background-color: #f0f0f0;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 10px;
}

.progress-bar {
  width: 0;
  height: 100%;
  background-color: #4CAF50;
  transition: width 0.3s ease;
}

/* Yes/No Answer Styling */
.yes-no-answer {
  font-size: 1.5em !important;
  font-weight: bold !important;
  color: var(--primary-color) !important;
  text-shadow: 0 0 10px rgba(255, 0, 238, 0.7) !important;
  display: inline-block !important;
  margin-right: 5px !important;
}

/* Custom Confirm Modal */
.custom-confirm-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.custom-confirm-content {
  background-color: #FFFFFF0D;
  color: #e0e0e0;
  padding: 20px;
  border-radius: 5px;
  text-align: left;
  min-width: 300px;
  max-width: 40%;
  min-height: 200px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(255, 255, 255, 0.2);
  /* box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); <-- DELETED */
  overflow-y: auto;
  position: relative;
  padding-top: 20px;
}

.custom-confirm-content p {
  color: #e0e0e0;
  margin: 0;
}

.custom-confirm-buttons {
  display: flex;
  justify-content: space-between;
}

.custom-confirm-buttons button {
  padding: 10px 5px;
  margin: 10px 0;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  width: 45%;
  background: var(--gradient-primary);
  color: white;
  transition: opacity 0.3s ease;
}

.custom-confirm-buttons button:hover {
  opacity: 0.8;
}

.custom-confirm-close {
  position: absolute;
  right: 10px;
  top: -5px;
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
}

.custom-confirm-close:hover {
  color: #555;
}

/* Hyperlinks styling */
.custom-confirm-content a {
  color: #4169e1;
  text-decoration: underline;
}

.custom-confirm-content a:hover {
  color: #8a2be2;
}

/* Character Count */
#char-count {
  position: absolute;
  bottom: 5px;
  right: 10px;
  font-size: 12px;
  color: #888;
}

/* Example Questions */
.example-questions-container {
  width: 100%;
  padding: 10px 0 0;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.example-question {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  background: var(--bg-color);
  border-radius: var(--border-radius);
  /* box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.1); <-- DELETED */
  cursor: pointer;
  text-align: center;
  min-height: 40px;
}

/* User remaining readings display */
.um-field-remaining_tarot_readings .um-field-label {
  border-bottom: 1px solid #eee;
  padding-bottom: 5px;
  margin-bottom: 5px;
}

.um-field-remaining_tarot_readings .um-field-area {
  margin-top: 10px;
}

/* Responsive Design */
@media (min-width: 768px) {
  .example-questions-container {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: 1fr;
  }
}

@media (max-width: 1150px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position-wrapper {
    width: 90%;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 144px;
    height: 240px;
  }
}

@media (max-width: 1024px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position-wrapper {
    width: 90%;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 135px;
    height: 225px;
  }
}

@media (max-width: 768px) {
  .combined-tarot-container[data-reading-type] {
    min-height: 220px;
  }

  .combined-tarot-container[data-reading-type="three_card"] {
    min-height: 300px;
  }

  .combined-tarot-container[data-reading-type="six_card"] {
    min-height: 480px;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] {
    min-height: 600px;
  }

  .card-area {
    height: 180px;
    min-height: 180px;
  }

  .spread-area.six-card {
    gap: 8px;
  }

  .spread-label {
    font-size: 12px;
    height: 2.2em;
  }

  .tarot-card-back,
  .tarot-card-front,
  .spread-position {
    width: 108px;
    height: 180px;
  }

  .spread-area.three-card {
    max-width: 450px;
  }

  .spread-area.horseshoe-spread {
    grid-template-columns: repeat(17, 1fr);
    grid-template-rows: repeat(8, auto);
    gap: 5px;
    padding: 10px;
  }

  .spread-area.horseshoe-spread .spread-position-wrapper {
    max-width: 100%;
  }

  .spread-area.horseshoe-spread #past-wrapper { grid-area: 7 / 1 / 9 / 5; }
  .spread-area.horseshoe-spread #present-wrapper { grid-area: 5 / 2 / 7 / 6; }
  .spread-area.horseshoe-spread #future-wrapper { grid-area: 2 / 4 / 4 / 8; }
  .spread-area.horseshoe-spread #advice-wrapper { grid-area: 1 / 8 / 3 / 11; }
  .spread-area.horseshoe-spread #influences-wrapper { grid-area: 2 / 11 / 4 / 15; }
  .spread-area.horseshoe-spread #obstacle-wrapper { grid-area: 5 / 13 / 7 / 17; }
  .spread-area.horseshoe-spread #outcome-wrapper { grid-area: 7 / 14 / 9 / 18; }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position-wrapper {
    width: 90%;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 99px;
    height: 165px;
  }
}

@media (max-width: 767px) {
  .question-button-container {
    flex-direction: column;
    align-items: stretch;
    padding: 20px;
  }

  #tarot-reading-container {
    padding: 3px;
  }

  #draw-tarot-card,
  #tarot-question {
    width: 100%;
    height: auto;
  }

  #draw-tarot-card {
    margin: 5px auto;
  }

  #tarot-question {
    font-size: 14px;
    padding: 10px;
  }

  #tarot-question::placeholder {
    font-size: 14px;
  }
}

@media (max-width: 750px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 90px;
    height: 150px;
  }
}

@media (max-width: 690px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 81px;
    height: 135px;
  }
}

@media (max-width: 650px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 76.5px;
    height: 127.5px;
  }
}

@media (max-width: 600px) {
  #tarot-reading-container {
    padding: 3px;
  }

  .combined-tarot-container[data-reading-type] {
    min-height: 190px;
  }

  .combined-tarot-container[data-reading-type="three_card"] {
    min-height: 280px;
  }

  .combined-tarot-container[data-reading-type="six_card"] {
    min-height: 450px;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] {
    min-height: 550px;
  }

  .card-area {
    height: 150px;
    min-height: 150px;
  }

  .spread-area.six-card {
    gap: 6px;
  }

  .spread-label {
    font-size: 10px;
    height: 2em;
  }

  .tarot-card-back,
  .tarot-card-front,
  .spread-position {
    width: 90px;
    height: 150px;
  }

  .spread-area.three-card {
    max-width: 400px;
  }
}

@media (max-width: 576px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position-wrapper {
    width: 95%;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 58.5px;
    height: 98px;
  }
}

@media (max-width: 480px) {
  .combined-tarot-container[data-reading-type="three_card"] {
    min-height: 260px;
  }

  .spread-area.three-card {
    max-width: 350px;
    gap: 6px;
  }

  .tarot-card-back,
  .tarot-card-front,
  .spread-position {
    width: 81px;
    height: 135px;
  }

  .spread-area.horseshoe-spread {
    grid-template-columns: repeat(15, 1fr);
    grid-template-rows: repeat(8, auto);
  }

  .spread-area.horseshoe-spread #past-wrapper { grid-area: 7 / 1 / 9 / 4; }
  .spread-area.horseshoe-spread #present-wrapper { grid-area: 5 / 2 / 7 / 5; }
  .spread-area.horseshoe-spread #future-wrapper { grid-area: 2 / 3 / 4 / 6; }
  .spread-area.horseshoe-spread #advice-wrapper { grid-area: 1 / 7 / 3 / 10; }
  .spread-area.horseshoe-spread #influences-wrapper { grid-area: 2 / 11 / 4 / 14; }
  .spread-area.horseshoe-spread #obstacle-wrapper { grid-area: 5 / 12 / 7 / 15; }
  .spread-area.horseshoe-spread #outcome-wrapper { grid-area: 7 / 13 / 9 / 16; }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 54px;
    height: 90px;
  }
}

@media (max-width: 400px) {
  .combined-tarot-container[data-reading-type] {
    min-height: 160px;
  }

  .combined-tarot-container[data-reading-type="three_card"] {
    min-height: 240px;
  }

  .combined-tarot-container[data-reading-type="six_card"] {
    min-height: 420px;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] {
    min-height: 500px;
  }

  .card-area {
    height: 130px;
    min-height: 130px;
  }

  .spread-area.six-card {
    gap: 4px;
  }

  .spread-label {
    font-size: 8px;
    height: 1.8em;
  }

  .tarot-card-back,
  .tarot-card-front,
  .spread-position {
    width: 72px;
    height: 120px;
  }

  #draw-tarot-card {
    font-size: 14px;
    padding: 10px 20px;
  }

  #tarot-card-name {
    font-size: 20px;
  }

  #tarot-card-meaning {
    font-size: 14px;
  }

  #tarot-question {
    font-size: 14px;
    padding: 10px;
  }

  .spread-area.three-card {
    max-width: 300px;
    gap: 5px;
  }
}

@media (max-width: 380px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position-wrapper {
    width: 95%;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 49.5px;
    height: 82.5px;
  }
}

@media (max-width: 360px) {
  .combined-tarot-container[data-reading-type="celtic_cross"] .spread-area.celtic-cross .spread-position,
  .combined-tarot-container[data-reading-type="celtic_cross"] .tarot-card-back.celtic-cross-card {
    width: 45px;
    height: 75px;
  }
}

@media (max-width: 320px) {
  .combined-tarot-container[data-reading-type] {
    min-height: 140px;
  }

  .combined-tarot-container[data-reading-type="three_card"] {
    min-height: 220px;
  }

  .combined-tarot-container[data-reading-type="six_card"] {
    min-height: 380px;
  }

  .combined-tarot-container[data-reading-type="celtic_cross"] {
    min-height: 450px;
  }

  .spread-area.six-card {
    gap: 3px;
  }

  .spread-label {
    font-size: 7px;
    height: 1.6em;
  }

  .tarot-card-back,
  .tarot-card-front,
  .spread-position {
    width: 63px;
    height: 105px;
  }

  #draw-tarot-card {
    font-size: 12px;
    padding: 8px 16px;
  }

  .spread-area.three-card {
    max-width: 250px;
    gap: 4px;
  }
}
/* 替换原来的圆形按钮样式 */
.tarot-help-button {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 8px 15px;
    background: linear-gradient(90deg, #8a2be2, #4169e1);
    color: white;
    font-size: 14px;
    text-align: center;
    cursor: pointer;
    z-index: 100;
    box-shadow: 0 0 10px rgba(255, 0, 238, 0.7);
    transition: all 0.3s ease;
    border-radius: 20px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tarot-help-button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 0, 238, 0.9);
}

/* 可以添加一个小图标 */
.tarot-help-button::before {
    content: "?";
    display: inline-block;
    width: 16px;
    height: 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    margin-right: 6px;
    line-height: 16px;
    font-size: 12px;
}

/* 响应式样式 */
@media (max-width: 768px) {
    .tarot-help-button {
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .tarot-help-button::before {
        width: 14px;
        height: 14px;
        line-height: 14px;
        font-size: 10px;
        margin-right: 4px;
    }
}

/* 使用说明模态框样式 */
.tarot-help-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    overflow-y: auto;
}

.tarot-help-content {
    position: relative;
    background-color: rgba(0, 0, 0, 0.9);
    color: #fff;
    margin: 5% auto;
    padding: 20px;
    width: 80%;
    max-width: 700px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(255, 0, 238, 0.7);
    max-height: 80vh;
    overflow-y: auto;
}

.tarot-help-close {
    position: absolute;
    top: 10px;
    right: 15px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.tarot-help-close:hover {
    color: #fff;
}

.tarot-help-content h2 {
    color: #ff00ee;
    text-align: center;
    margin-bottom: 20px;
    font-size: 24px;
}

.tarot-help-content h3 {
    color: #00ffff;
    margin-top: 20px;
    margin-bottom: 10px;
    font-size: 18px;
}

.tarot-help-content p {
    line-height: 1.6;
    margin-bottom: 15px;
}

.tarot-help-step {
    border-left: 3px solid #8a2be2;
    padding-left: 15px;
    margin-bottom: 25px;
}

.tarot-help-step-number {
    display: inline-block;
    width: 24px;
    height: 24px;
    background: linear-gradient(90deg, #8a2be2, #4169e1);
    border-radius: 50%;
    color: white;
    text-align: center;
    line-height: 24px;
    margin-right: 10px;
}

.tarot-help-image {
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    margin: 10px 0;
    max-width: 100%;
    height: auto;
}


/* 响应式样式 */
@media (max-width: 768px) {
    .tarot-help-button-container {
        padding: 5px 20px;
    }
    
    .tarot-help-button {
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .tarot-help-button::before {
        width: 14px;
        height: 14px;
        line-height: 14px;
        font-size: 10px;
        margin-right: 4px;
    }
}
