.oddities-tarot {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background:
    radial-gradient(circle at 12% 18%, rgba(107, 61, 128, 0.2), transparent 30rem),
    radial-gradient(circle at 86% 72%, rgba(217, 139, 43, 0.16), transparent 28rem),
    linear-gradient(145deg, #040711 0%, #090817 48%, #03070d 100%);
}

.oddities-tarot::before,
.oddities-tarot::after {
  position: absolute;
  z-index: -1;
  pointer-events: none;
  content: "";
}

.oddities-tarot::before {
  inset: 0;
  opacity: 0.3;
  background-image:
    radial-gradient(circle at 16% 20%, #f6d6a0 0 1px, transparent 1.5px),
    radial-gradient(circle at 72% 32%, #e8c186 0 1px, transparent 1.5px),
    radial-gradient(circle at 48% 78%, #caa4db 0 1px, transparent 1.5px);
  background-size: 170px 170px, 230px 230px, 290px 290px;
}

.oddities-tarot::after {
  width: min(68vw, 760px);
  aspect-ratio: 1;
  right: -24%;
  bottom: -42%;
  border: 1px solid rgba(255, 192, 102, 0.09);
  border-radius: 50%;
  box-shadow:
    0 0 0 52px rgba(255, 192, 102, 0.025),
    0 0 0 104px rgba(130, 89, 154, 0.025);
}

.tarot-heading {
  display: grid;
  gap: 18px;
  margin-bottom: 42px;
}

.tarot-heading h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 8vw, 76px);
  font-weight: 400;
  line-height: 0.96;
  letter-spacing: -0.05em;
}

.tarot-heading > p:last-child {
  max-width: 610px;
  margin: 0;
  color: #aeb4bd;
  font-size: 14px;
  line-height: 1.76;
}

.tarot-nightline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 13px;
  margin-bottom: 26px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 192, 102, 0.25);
  border-radius: 3px;
  background: rgba(3, 7, 13, 0.62);
  backdrop-filter: blur(12px);
}

.tarot-nightline strong,
.tarot-nightline span {
  text-transform: uppercase;
}

.tarot-nightline strong {
  color: var(--amber-hot);
  font-family: var(--font-geist-mono), monospace;
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.18em;
}

.tarot-nightline span {
  color: #8f97a1;
  font-size: 8px;
  font-weight: 650;
  letter-spacing: 0.16em;
}

.tarot-nightline strong #tarot-date {
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
}

.tarot-grid {
  display: grid;
  gap: 34px;
}

.tarot-slot {
  min-width: 0;
}

.tarot-position {
  min-height: 43px;
  margin: 0 0 14px;
  text-align: center;
}

.tarot-position strong,
.tarot-position span {
  display: block;
}

.tarot-position strong {
  color: #f4ead9;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 21px;
  font-weight: 400;
}

.tarot-position span {
  margin-top: 6px;
  color: #8f97a1;
  font-size: 9px;
  line-height: 1.45;
}

.tarot-card {
  display: block;
  width: min(100%, 260px);
  aspect-ratio: 2 / 3.18;
  margin: 0 auto;
  padding: 0;
  border: 0;
  border-radius: 9px;
  background: transparent;
  cursor: pointer;
  perspective: 1200px;
}

.tarot-card:focus-visible {
  outline: 2px solid var(--amber-hot);
  outline-offset: 6px;
}

.tarot-card-inner {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  transition: transform 0.8s cubic-bezier(0.2, 0.75, 0.2, 1);
  transform-style: preserve-3d;
}

.tarot-card.is-revealed .tarot-card-inner {
  transform: rotateY(180deg);
}

.tarot-face {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid rgba(255, 192, 102, 0.52);
  border-radius: 9px;
  backface-visibility: hidden;
  box-shadow:
    0 25px 70px rgba(0, 0, 0, 0.54),
    inset 0 0 34px rgba(217, 139, 43, 0.07);
}

.tarot-face::before {
  position: absolute;
  inset: 8px;
  pointer-events: none;
  border: 1px solid rgba(255, 236, 200, 0.18);
  border-radius: 5px;
  content: "";
}

.tarot-back {
  gap: 17px;
  background:
    radial-gradient(circle at 50% 44%, rgba(126, 73, 148, 0.23), transparent 42%),
    linear-gradient(155deg, #0b0b1a, #03060c 70%);
  transition: border-color 0.18s, box-shadow 0.18s, transform 0.18s;
}

.tarot-card:hover .tarot-back,
.tarot-card:focus-visible .tarot-back {
  border-color: rgba(255, 192, 102, 0.88);
  transform: translateY(-3px);
  box-shadow:
    0 28px 78px rgba(0, 0, 0, 0.6),
    0 0 30px rgba(217, 139, 43, 0.2),
    inset 0 0 40px rgba(217, 139, 43, 0.1);
}

.tarot-back img {
  width: 74%;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 192, 102, 0.34);
  border-radius: 50%;
  object-fit: cover;
  opacity: 0.88;
  filter: saturate(0.9) contrast(1.05);
  box-shadow: 0 0 28px rgba(217, 139, 43, 0.12);
}

.tarot-back strong {
  color: #f1d3a4;
  font-size: 9px;
  font-weight: 680;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.tarot-front {
  padding: 22px 18px 19px;
  background:
    radial-gradient(circle at 50% 45%, rgba(108, 67, 129, 0.22), transparent 45%),
    linear-gradient(160deg, #0b101b 0%, #060812 68%, #120b10 100%);
  transform: rotateY(180deg);
}

.tarot-roman {
  position: absolute;
  top: 19px;
  color: var(--amber-hot);
  font-family: var(--font-geist-mono), monospace;
  font-size: 9px;
  letter-spacing: 0.18em;
}

.tarot-art {
  width: 78%;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 192, 102, 0.28);
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 32px rgba(217, 139, 43, 0.14);
}

.tarot-card-name {
  max-width: 95%;
  margin-top: 20px;
  color: #f6ead8;
  text-align: center;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(18px, 5vw, 23px);
  font-weight: 400;
  line-height: 1.03;
}

.tarot-meaning {
  min-height: 128px;
  margin-top: 21px;
  padding: 18px 18px 20px;
  border-top: 1px solid rgba(226, 235, 241, 0.13);
  text-align: center;
}

.tarot-meaning h3 {
  margin: 0;
  color: #d7b378;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 19px;
  font-weight: 400;
}

.tarot-meaning p {
  margin: 10px 0 0;
  color: #929aa5;
  font-size: 11px;
  line-height: 1.68;
}

.tarot-slot.is-revealed .tarot-meaning {
  background: linear-gradient(180deg, rgba(217, 139, 43, 0.045), transparent);
}

.tarot-slot.is-revealed .tarot-meaning h3 {
  color: #f1d3a4;
}

.tarot-complete {
  display: none;
  margin-top: 30px;
  padding: clamp(24px, 4vw, 38px);
  border: 1px solid rgba(255, 192, 102, 0.3);
  border-radius: 3px;
  background:
    radial-gradient(circle at 12% 12%, rgba(217, 139, 43, 0.11), transparent 22rem),
    linear-gradient(115deg, rgba(217, 139, 43, 0.07), rgba(84, 51, 102, 0.1));
}

.tarot-status {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.tarot-complete.is-visible {
  display: block;
  animation: tarot-rise 0.55s ease both;
}

.tarot-complete strong {
  display: block;
  color: #f5e8d5;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(25px, 5vw, 34px);
  font-weight: 400;
  line-height: 1.08;
}

.tarot-reading-label {
  display: block;
  margin-bottom: 9px;
  color: var(--amber-hot);
  font-family: var(--font-geist-mono), monospace;
  font-size: 8px;
  font-weight: 650;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tarot-reading-copy {
  max-width: 760px;
  margin-top: 22px;
}

.tarot-reading-copy p,
.tarot-reading-keep {
  margin: 0;
  color: #9da5ae;
  font-size: 12px;
  line-height: 1.78;
}

.tarot-reading-copy p + p {
  margin-top: 15px;
  color: #c1b8ad;
}

.tarot-reading-copy strong {
  display: inline;
  color: #f1d3a4;
  font-family: inherit;
  font-size: inherit;
  font-weight: 650;
}

.tarot-reading-copy em {
  color: #e0c99f;
  font-style: normal;
}

.tarot-outcome {
  max-width: 760px;
  margin-top: 24px;
  padding: 18px 20px;
  border-left: 2px solid var(--amber-hot);
  background: rgba(2, 6, 12, 0.48);
  box-shadow: inset 18px 0 35px rgba(217, 139, 43, 0.045);
}

.tarot-outcome span {
  display: block;
  color: var(--amber-hot);
  font-family: var(--font-geist-mono), monospace;
  font-size: 8px;
  font-weight: 680;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.tarot-outcome p {
  margin: 9px 0 0;
  color: #f4e7d4;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(17px, 3.8vw, 22px);
  line-height: 1.45;
}

.tarot-reading-keep {
  max-width: 760px;
  margin-top: 20px;
  color: #7f8791;
  font-size: 9px;
  line-height: 1.65;
}

.tarot-note {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 22px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: #7f8791;
  font-size: 9px;
  line-height: 1.6;
}

.tarot-note span:last-child {
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.tarot-noscript {
  display: block;
  padding: 18px;
  border: 1px solid var(--line);
  color: #aeb4bd;
  font-size: 12px;
  line-height: 1.6;
}

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

@media (min-width: 760px) {
  .tarot-heading {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 0.55fr);
    align-items: end;
  }

  .tarot-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
  }

  .tarot-position {
    min-height: 62px;
  }

  .tarot-meaning {
    min-height: 165px;
  }
}

@media (min-width: 1040px) {
  .tarot-grid {
    gap: 34px;
  }

  .tarot-card {
    width: min(100%, 275px);
  }
}

@media (max-width: 759px) {
  .oddities-tarot.section {
    padding-block: 76px;
  }

  .tarot-grid {
    max-width: 430px;
    margin-inline: auto;
  }

  .tarot-slot + .tarot-slot {
    padding-top: 10px;
    border-top: 1px solid rgba(226, 235, 241, 0.09);
  }

  .tarot-card-name {
    font-size: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tarot-card-inner,
  .tarot-back {
    transition-duration: 0.01ms;
  }

  .tarot-complete.is-visible {
    animation: none;
  }
}
