:root {
  color-scheme: dark;
  --bg: #07040e;
  --bg-deep: #040208;
  --surface: rgba(255, 255, 255, 0.055);
  --surface-strong: rgba(255, 255, 255, 0.085);
  --surface-purple: rgba(102, 63, 153, 0.18);
  --text: #fbf9ff;
  --muted: rgba(244, 238, 255, 0.62);
  --quiet: rgba(244, 238, 255, 0.42);
  --line: rgba(238, 222, 255, 0.10);
  --line-strong: rgba(222, 190, 255, 0.24);
  --lavender: #dcc2ff;
  --lavender-bright: #f0e2ff;
  --violet: #a67add;
  --violet-deep: #623d8e;
  --gold: #ddb86a;
  --ink: #170c22;
  --shell: 1160px;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "Avenir Next", Avenir, "SF Pro Display", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--text);
  font-family: var(--sans);
  background:
    radial-gradient(circle at 50% -10%, rgba(118, 72, 174, 0.33), transparent 34%),
    radial-gradient(circle at 8% 27%, rgba(64, 33, 108, 0.24), transparent 30%),
    linear-gradient(180deg, #10071e 0%, var(--bg) 42%, var(--bg-deep) 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  opacity: 0.34;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.75) 0 0.7px, transparent 0.9px),
    radial-gradient(circle, rgba(216, 183, 255, 0.62) 0 0.8px, transparent 1px);
  background-position: 0 0, 33px 29px;
  background-size: 67px 67px, 101px 101px;
  mask-image: linear-gradient(to bottom, black 0%, rgba(0, 0, 0, 0.7) 55%, transparent 100%);
}

body.modal-open {
  overflow: hidden;
}

button,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

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

img {
  display: block;
  max-width: 100%;
}

.shell {
  width: min(var(--shell), calc(100% - 40px));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  color: var(--ink);
  background: var(--lavender-bright);
  border-radius: 8px;
  transform: translateY(-150%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.ambient {
  position: absolute;
  z-index: -2;
  border-radius: 50%;
  filter: blur(10px);
  pointer-events: none;
}

.ambient-one {
  top: 118px;
  right: -230px;
  width: 640px;
  height: 640px;
  background: radial-gradient(circle, rgba(128, 79, 194, 0.19), transparent 68%);
}

.ambient-two {
  top: 1020px;
  left: -260px;
  width: 620px;
  height: 620px;
  background: radial-gradient(circle, rgba(87, 45, 143, 0.16), transparent 68%);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid rgba(255, 255, 255, 0.055);
  background: rgba(8, 4, 15, 0.69);
  backdrop-filter: blur(20px) saturate(1.25);
}

.header-inner {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand,
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand img,
.footer-brand img,
.dialog-icon,
.app-banner img {
  flex: 0 0 auto;
  border-radius: 22%;
  box-shadow: 0 12px 28px rgba(43, 24, 83, 0.52);
}

.brand-copy {
  display: grid;
  gap: 2px;
}

.brand-copy strong {
  font-size: 16px;
  letter-spacing: 0.01em;
}

.brand-copy small {
  color: var(--quiet);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.site-nav > a {
  transition: color 0.2s ease;
}

.site-nav > a:hover {
  color: var(--text);
}

.header-cta,
.primary-button,
.secondary-button,
.draw-button,
.new-reading-button,
.app-store-button {
  border: 0;
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.header-cta {
  padding: 10px 16px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--lavender-bright), #bd94ed);
  box-shadow: 0 10px 24px rgba(157, 112, 214, 0.22);
}

.header-cta:hover,
.primary-button:hover,
.draw-button:hover,
.app-store-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(157, 112, 214, 0.30);
}

.hero {
  min-height: 690px;
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(380px, 0.96fr);
  align-items: center;
  gap: 54px;
  padding-block: 86px 92px;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--lavender);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.19em;
  text-transform: uppercase;
}

.eyebrow span {
  color: var(--gold);
}

.hero h1 {
  max-width: 720px;
  margin: 22px 0 24px;
  font-family: var(--serif);
  font-size: clamp(54px, 6vw, 86px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.96;
}

.hero h1 em {
  color: var(--lavender);
  font-weight: 400;
}

.hero-copy > p {
  max-width: 590px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.75;
}

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

.primary-button,
.secondary-button {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 20px;
  border-radius: 16px;
  font-size: 13px;
  font-weight: 800;
}

.primary-button {
  color: var(--ink);
  background: linear-gradient(135deg, #f0e3ff, #bc91e9);
  box-shadow: 0 15px 34px rgba(151, 104, 209, 0.25);
}

.secondary-button {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, 0.055);
}

.secondary-button:hover,
.new-reading-button:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.09);
}

.trust-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  margin: 28px 0 0;
  padding: 0;
  color: var(--quiet);
  font-size: 11px;
  font-weight: 600;
  list-style: none;
}

.trust-list li::before {
  content: "·";
  margin-right: 8px;
  color: var(--gold);
}

.hero-visual {
  position: relative;
  min-height: 535px;
  display: grid;
  place-items: center;
  isolation: isolate;
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: 7% 2% 5%;
  z-index: -2;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(155, 100, 222, 0.23), rgba(78, 39, 123, 0.05) 48%, transparent 70%);
  filter: blur(8px);
}

.orbit {
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(211, 184, 244, 0.12);
  border-radius: 50%;
  transform: rotate(-18deg);
}

.orbit::after {
  content: "✦";
  position: absolute;
  top: 17%;
  right: 2%;
  color: var(--gold);
  font-size: 12px;
  text-shadow: 0 0 16px rgba(221, 184, 106, 0.7);
}

.orbit-large {
  width: 500px;
  height: 330px;
}

.orbit-small {
  width: 360px;
  height: 236px;
  transform: rotate(29deg);
}

.hero-card,
.preview-card,
.card-back-face {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 13px;
  color: #ead8ff;
  border: 1px solid rgba(240, 220, 255, 0.20);
  background: linear-gradient(145deg, #4b246c, #160b27 64%, #0d0618);
  box-shadow: inset 0 0 0 7px rgba(226, 195, 255, 0.08), 0 24px 55px rgba(0, 0, 0, 0.42);
}

.hero-card::before,
.preview-card::before,
.card-back-face::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(230, 202, 255, 0.38);
  border-radius: inherit;
  pointer-events: none;
}

.hero-card {
  position: absolute;
  width: 190px;
  aspect-ratio: 2 / 3;
  border-radius: 22px;
}

.hero-card-center {
  z-index: 3;
  transform: translateY(-14px);
  box-shadow: inset 0 0 0 7px rgba(226, 195, 255, 0.08), 0 30px 80px rgba(109, 60, 166, 0.42);
}

.hero-card-left {
  z-index: 1;
  transform: translate(-118px, 24px) rotate(-12deg);
  opacity: 0.58;
}

.hero-card-right {
  z-index: 2;
  transform: translate(118px, 20px) rotate(11deg);
  opacity: 0.76;
}

.card-star {
  font-size: 12px;
}

.card-moon,
.preview-card b,
.card-back-face b {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(240, 224, 255, 0.50);
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 42px;
  font-weight: 400;
  line-height: 1;
}

.visual-caption {
  position: absolute;
  bottom: 4px;
  left: 50%;
  z-index: 5;
  width: max-content;
  max-width: 90%;
  display: grid;
  gap: 5px;
  padding: 14px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  text-align: center;
  background: rgba(16, 8, 28, 0.78);
  backdrop-filter: blur(12px);
  transform: translateX(-50%);
}

.visual-caption span {
  color: var(--quiet);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.24em;
}

.visual-caption strong {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 500;
}

.reading-section {
  position: relative;
  padding-block: 72px 104px;
  border-block: 1px solid rgba(255, 255, 255, 0.055);
  background:
    radial-gradient(circle at 75% 35%, rgba(104, 62, 157, 0.14), transparent 35%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.018), rgba(255, 255, 255, 0.004));
}

.app-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 44px;
}

.arcana-mark {
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: var(--lavender);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.07);
}

.app-heading > div:nth-child(2) {
  display: grid;
  gap: 2px;
}

.app-heading span {
  color: var(--quiet);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.23em;
}

.app-heading h2 {
  margin: 0;
  font-size: 17px;
}

.app-heading time {
  margin-left: auto;
  color: var(--quiet);
  font-size: 12px;
  font-weight: 600;
}

.reading-intro {
  max-width: 700px;
  margin-bottom: 34px;
}

.reading-intro h3 {
  margin: 8px 0 10px;
  font-family: var(--serif);
  font-size: clamp(38px, 5vw, 58px);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1;
}

.reading-intro p,
.section-heading > p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.reading-grid {
  display: grid;
  grid-template-columns: minmax(300px, 0.72fr) minmax(0, 1.28fr);
  align-items: start;
  gap: 20px;
}

.question-panel,
.card-stage {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.question-panel {
  display: grid;
  gap: 22px;
  padding: 22px;
  border-radius: 24px;
}

.field-group {
  min-width: 0;
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  border: 0;
}

.field-group label,
.field-group legend {
  padding: 0;
  color: rgba(244, 238, 255, 0.57);
  font-size: 11px;
  font-weight: 700;
}

textarea,
select {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.085);
  outline: none;
  color: var(--text);
  background: rgba(0, 0, 0, 0.18);
}

textarea {
  min-height: 108px;
  resize: vertical;
  padding: 14px;
  border-radius: 15px;
  line-height: 1.5;
}

textarea::placeholder {
  color: rgba(244, 238, 255, 0.28);
}

textarea:focus,
select:focus {
  border-color: rgba(212, 178, 251, 0.48);
  box-shadow: 0 0 0 3px rgba(166, 122, 221, 0.12);
}

.field-note {
  color: rgba(244, 238, 255, 0.34);
  font-size: 10px;
  line-height: 1.45;
}

.spread-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.spread-option {
  min-width: 0;
  display: grid;
  gap: 3px;
  padding: 13px;
  border: 1px solid transparent;
  border-radius: 15px;
  cursor: pointer;
  text-align: left;
  background: rgba(255, 255, 255, 0.055);
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.spread-option:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.085);
}

.spread-option.is-active {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.30);
  background: linear-gradient(135deg, #e7d2ff, #b98ee6);
}

.spread-option strong {
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.spread-option span {
  overflow: hidden;
  font-size: 9px;
  opacity: 0.65;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.select-wrap {
  position: relative;
}

.select-wrap::after {
  content: "⌄";
  position: absolute;
  top: 50%;
  right: 14px;
  color: var(--lavender);
  pointer-events: none;
  transform: translateY(-58%);
}

select {
  min-height: 48px;
  padding: 0 42px 0 13px;
  border-radius: 14px;
  appearance: none;
  font-size: 12px;
  font-weight: 700;
}

.ritual-note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(220, 194, 255, 0.08);
  border-radius: 16px;
  background: rgba(63, 35, 95, 0.16);
}

.ritual-note > span {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: var(--lavender);
  border: 1px solid rgba(225, 203, 255, 0.18);
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 21px;
}

.ritual-note p {
  margin: 0;
  color: var(--quiet);
  font-size: 10px;
  line-height: 1.5;
}

.card-stage {
  min-height: 648px;
  padding: 24px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 50% 22%, rgba(115, 70, 168, 0.15), transparent 35%),
    rgba(255, 255, 255, 0.035);
}

.empty-reading {
  min-height: 598px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.deck-preview {
  position: relative;
  width: 240px;
  height: 284px;
  margin-bottom: 22px;
}

.preview-card {
  position: absolute;
  top: 14px;
  left: 50%;
  width: 142px;
  aspect-ratio: 2 / 3;
  border-radius: 18px;
}

.preview-card-left {
  transform: translateX(-69%) rotate(-8deg);
  opacity: 0.52;
}

.preview-card-right {
  transform: translateX(-31%) rotate(7deg);
  opacity: 0.70;
}

.preview-card-front {
  z-index: 2;
  transform: translateX(-50%);
  box-shadow: inset 0 0 0 7px rgba(226, 195, 255, 0.08), 0 24px 60px rgba(115, 62, 176, 0.34);
}

.preview-card b {
  width: 58px;
  height: 58px;
  font-size: 32px;
}

.preview-card span {
  font-size: 9px;
}

.empty-copy h3,
.reading-status h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
}

.empty-copy p,
.reading-status p {
  margin: 7px 0 0;
  color: var(--quiet);
  font-size: 11px;
}

.draw-button {
  width: min(100%, 410px);
  min-height: 52px;
  margin-top: 24px;
  border-radius: 16px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
  background: linear-gradient(135deg, #f0e0ff, #aa7bd8);
  box-shadow: 0 16px 35px rgba(152, 101, 209, 0.24);
}

.reflection-note {
  max-width: 400px;
  margin: 14px 0 0;
  color: rgba(244, 238, 255, 0.28);
  font-size: 9px;
  line-height: 1.5;
}

.active-reading {
  min-height: 598px;
}

.reading-status {
  display: grid;
  justify-items: center;
  margin: 8px 0 25px;
  text-align: center;
}

.reading-status > span {
  margin-bottom: 7px;
  color: var(--lavender);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.23em;
}

.drawn-cards {
  width: 100%;
  display: grid;
  justify-content: center;
  gap: 14px;
}

.drawn-cards.one-card {
  grid-template-columns: minmax(170px, 220px);
}

.drawn-cards.three-cards {
  grid-template-columns: repeat(3, minmax(132px, 190px));
}

.drawn-card-shell {
  min-width: 0;
  opacity: 0;
  filter: blur(3px);
  transform: translateY(110px) scale(0.56) rotate(-9deg);
  transition: opacity 0.28s ease, filter 0.42s ease, transform 0.70s cubic-bezier(0.2, 0.78, 0.18, 1.12);
}

.drawn-card-shell:nth-child(2) {
  transform: translateY(120px) scale(0.56) rotate(8deg);
}

.drawn-card-shell:nth-child(3) {
  transform: translateY(112px) scale(0.56) rotate(13deg);
}

.drawn-card-shell.is-dealt {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) scale(1) rotate(0);
}

.reading-card-button {
  width: 100%;
  display: grid;
  gap: 8px;
  padding: 0;
  border: 0;
  outline: none;
  cursor: pointer;
  text-align: left;
  background: transparent;
  perspective: 1100px;
}

.reading-card-button:disabled {
  cursor: wait;
}

.reading-card-button:focus-visible .card-inner {
  outline: 3px solid rgba(230, 202, 255, 0.72);
  outline-offset: 4px;
}

.card-inner {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 16px;
  box-shadow: 0 19px 42px rgba(0, 0, 0, 0.40);
  transform-style: preserve-3d;
  transition: transform 0.72s cubic-bezier(0.2, 0.76, 0.23, 1);
}

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

.card-back-face,
.card-front-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 16px;
  backface-visibility: hidden;
}

.card-back-face {
  position: absolute;
}

.card-back-face b {
  width: 56px;
  height: 56px;
  font-size: 31px;
}

.card-back-face span {
  font-size: 9px;
}

.card-front-face {
  border: 1px solid rgba(221, 184, 106, 0.72);
  background: #0d0812;
  transform: rotateY(180deg);
}

.card-front-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-front-face img.is-reversed {
  transform: rotate(180deg);
}

.card-caption {
  min-width: 0;
  min-height: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
  padding-inline: 3px;
  color: rgba(244, 238, 255, 0.70);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.card-caption span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-caption span:last-child {
  flex: 0 0 auto;
  color: var(--quiet);
  font-size: 7px;
}

.basic-reading {
  display: grid;
  gap: 13px;
  margin-top: 28px;
  padding: 18px;
  border: 1px solid rgba(212, 177, 255, 0.18);
  border-radius: 20px;
  background: rgba(88, 51, 130, 0.17);
}

.basic-question {
  padding-bottom: 13px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.basic-question span,
.basic-header span {
  display: block;
  margin-bottom: 5px;
  color: var(--lavender);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.basic-question p {
  margin: 0;
  color: rgba(251, 249, 255, 0.84);
  font-size: 12px;
  line-height: 1.5;
}

.basic-header {
  display: grid;
  gap: 3px;
}

.basic-header h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
}

.meaning-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.15);
}

.meaning-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.meaning-meta strong {
  color: var(--lavender);
  font-size: 9px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.meaning-meta span {
  color: var(--quiet);
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
}

.meaning-card h4 {
  margin: 0;
  font-size: 14px;
}

.meaning-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.basic-disclaimer {
  margin: 1px 0 0;
  color: rgba(244, 238, 255, 0.34);
  font-size: 9px;
  line-height: 1.5;
}

.detail-invite {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  margin-top: 3px;
  padding: 15px;
  border: 1px solid rgba(220, 189, 255, 0.18);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(106, 64, 156, 0.30), rgba(49, 26, 76, 0.26));
}

.detail-spark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--lavender-bright);
  background: rgba(207, 174, 246, 0.14);
}

.detail-copy h4 {
  margin: 0 0 3px;
  font-size: 13px;
}

.detail-copy p {
  margin: 0;
  color: var(--quiet);
  font-size: 9px;
  line-height: 1.45;
}

.detail-button {
  grid-column: 1 / -1;
  min-height: 46px;
  border: 0;
  border-radius: 14px;
  cursor: pointer;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  background: linear-gradient(135deg, #efddff, #aa7ad9);
}

.new-reading-button {
  width: 100%;
  min-height: 46px;
  margin-top: 15px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: rgba(251, 249, 255, 0.78);
  font-size: 12px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.05);
}

.tarot-guide {
  padding-block: 108px;
  border-block: 1px solid rgba(255, 255, 255, 0.055);
  background:
    radial-gradient(circle at 12% 18%, rgba(146, 95, 208, 0.13), transparent 31%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), rgba(0, 0, 0, 0.08));
}

.guide-heading {
  max-width: 820px;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.guide-grid article {
  min-height: 260px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.022));
}

.guide-number {
  display: block;
  margin-bottom: 46px;
  color: var(--lavender);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.guide-grid h3,
.guide-reflection h3 {
  margin: 0 0 11px;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.1;
}

.guide-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.75;
}

.guide-reflection {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 24px;
  margin-top: 16px;
  padding: 25px 27px;
  border: 1px solid rgba(220, 190, 255, 0.16);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(94, 52, 140, 0.28), rgba(255, 255, 255, 0.035));
}

.guide-reflection span {
  display: block;
  margin-bottom: 7px;
  color: var(--lavender);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.guide-reflection h3 {
  margin: 0;
}

.inside-app {
  padding-block: 112px 108px;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 42px;
}

.section-heading h2 {
  margin: 14px 0 14px;
  font-family: var(--serif);
  font-size: clamp(40px, 5vw, 64px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1;
}

.benefit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.benefit-grid article {
  position: relative;
  min-height: 274px;
  padding: 25px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.025));
}

.benefit-number {
  position: absolute;
  top: 19px;
  right: 22px;
  color: rgba(244, 238, 255, 0.19);
  font-family: var(--serif);
  font-size: 34px;
}

.benefit-icon {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  margin: 42px 0 27px;
  border: 1px solid rgba(223, 195, 255, 0.15);
  border-radius: 50%;
  color: var(--lavender);
  background: rgba(116, 72, 169, 0.13);
}

.benefit-grid h3 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 500;
}

.benefit-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.app-banner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 22px;
  margin-top: 18px;
  padding: 24px;
  border: 1px solid var(--line-strong);
  border-radius: 24px;
  background:
    radial-gradient(circle at 74% 20%, rgba(151, 100, 215, 0.26), transparent 30%),
    linear-gradient(135deg, rgba(80, 45, 120, 0.32), rgba(255, 255, 255, 0.045));
}

.app-banner span {
  color: var(--lavender);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.app-banner h3 {
  margin: 5px 0 0;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
}

.site-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.16);
}

.footer-inner {
  min-height: 160px;
  display: grid;
  grid-template-columns: 1fr 1.3fr auto;
  align-items: center;
  gap: 28px;
}

.footer-brand > div {
  display: grid;
  gap: 3px;
}

.footer-brand strong {
  font-size: 14px;
}

.footer-brand span,
.footer-inner > p,
.footer-links {
  color: var(--quiet);
  font-size: 10px;
  line-height: 1.5;
}

.footer-inner > p {
  margin: 0;
  text-align: center;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-links a:hover,
.text-button:hover {
  color: var(--text);
}

.text-button {
  padding: 0;
  border: 0;
  cursor: pointer;
  color: inherit;
  background: none;
}

.app-dialog {
  width: min(470px, calc(100% - 28px));
  max-height: calc(100vh - 28px);
  padding: 0;
  overflow: visible;
  border: 1px solid rgba(231, 209, 255, 0.22);
  border-radius: 28px;
  color: var(--text);
  background: #160b25;
  box-shadow: 0 36px 110px rgba(0, 0, 0, 0.72);
}

.app-dialog::backdrop {
  background: rgba(4, 2, 8, 0.80);
  backdrop-filter: blur(10px);
}

.dialog-content {
  position: relative;
  max-height: calc(100vh - 28px);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 34px 38px 30px;
  overflow-y: auto;
  border-radius: inherit;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(156, 103, 220, 0.29), transparent 36%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), transparent 38%);
}

.dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 0 0 3px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 50%;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.72);
  font-size: 24px;
  background: rgba(255, 255, 255, 0.06);
}

.dialog-icon {
  margin-bottom: 16px;
}

.dialog-kicker,
.scan-label {
  color: var(--lavender);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.21em;
}

.app-dialog h2 {
  max-width: 360px;
  margin: 10px 0 10px;
  font-family: var(--serif);
  font-size: 31px;
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.05;
}

.app-dialog p {
  max-width: 360px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.qr-link {
  width: 190px;
  margin: 20px 0 9px;
  padding: 10px;
  border-radius: 18px;
  background: white;
  box-shadow: 0 17px 35px rgba(0, 0, 0, 0.28);
}

.qr-link img {
  width: 100%;
  height: auto;
}

.app-store-button {
  min-width: 205px;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 17px;
  padding: 8px 20px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 13px;
  color: white;
  background: #050505;
}

.app-store-button > span:first-child {
  font-size: 26px;
  line-height: 1;
}

.app-store-button > span:last-child {
  display: grid;
  text-align: left;
}

.app-store-button small {
  font-size: 8px;
}

.app-store-button strong {
  font-size: 17px;
  line-height: 1.05;
}

.app-dialog .dialog-footnote {
  margin-top: 12px;
  color: rgba(244, 238, 255, 0.32);
  font-size: 8px;
}

button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(230, 202, 255, 0.82);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr 0.82fr;
    gap: 20px;
  }

  .hero-card {
    width: 154px;
  }

  .hero-card-left {
    transform: translate(-88px, 24px) rotate(-12deg);
  }

  .hero-card-right {
    transform: translate(88px, 20px) rotate(11deg);
  }

  .orbit-large {
    width: 410px;
    height: 280px;
  }

  .reading-grid {
    grid-template-columns: minmax(260px, 0.74fr) minmax(0, 1.26fr);
  }

  .card-stage {
    padding: 20px;
  }
}

@media (max-width: 820px) {
  .site-nav > a:not(:last-of-type) {
    display: none;
  }

  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    padding-block: 74px 76px;
  }

  .hero-copy {
    max-width: 670px;
  }

  .hero-visual {
    min-height: 500px;
  }

  .reading-grid {
    grid-template-columns: 1fr;
  }

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

  .question-panel .field-group:first-child,
  .ritual-note {
    grid-column: 1 / -1;
  }

  .benefit-grid {
    grid-template-columns: 1fr;
  }

  .guide-grid {
    grid-template-columns: 1fr;
  }

  .guide-grid article {
    min-height: 0;
  }

  .benefit-grid article {
    min-height: 230px;
  }

  .app-banner {
    grid-template-columns: auto 1fr;
  }

  .app-banner .primary-button {
    grid-column: 1 / -1;
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
    padding-block: 28px;
  }

  .footer-inner > p {
    grid-column: 1 / -1;
    grid-row: 2;
    text-align: left;
  }

  .footer-links {
    justify-content: flex-end;
  }
}

@media (max-width: 620px) {
  .shell {
    width: min(100% - 28px, var(--shell));
  }

  .header-inner {
    min-height: 68px;
  }

  .brand img {
    width: 41px;
    height: 41px;
  }

  .brand-copy small,
  .site-nav > a {
    display: none;
  }

  .site-nav {
    gap: 8px;
  }

  .header-cta {
    padding: 9px 13px;
  }

  .hero {
    gap: 26px;
    padding-block: 58px 68px;
  }

  .hero h1 {
    margin-top: 18px;
    font-size: clamp(48px, 15vw, 67px);
  }

  .hero-copy > p {
    font-size: 15px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-button,
  .secondary-button {
    width: 100%;
  }

  .trust-list {
    display: grid;
    gap: 9px;
  }

  .hero-visual {
    min-height: 380px;
    transform: scale(0.88);
    transform-origin: center;
  }

  .hero-card {
    width: 145px;
  }

  .visual-caption {
    bottom: -20px;
  }

  .reading-section {
    padding-block: 52px 76px;
  }

  .app-heading {
    margin-bottom: 36px;
  }

  .app-heading time {
    max-width: 90px;
    text-align: right;
  }

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

  .reading-intro h3 {
    font-size: 40px;
  }

  .question-panel {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .question-panel .field-group:first-child,
  .ritual-note {
    grid-column: auto;
  }

  .card-stage {
    min-height: 590px;
    padding: 20px 16px;
  }

  .empty-reading,
  .active-reading {
    min-height: 548px;
  }

  .deck-preview {
    transform: scale(0.90);
  }

  .drawn-cards.three-cards {
    width: calc(100% + 32px);
    display: flex;
    justify-content: flex-start;
    gap: 12px;
    margin-inline: -16px;
    padding: 4px max(16px, calc((100vw - 224px) / 2)) 12px;
    overflow-x: auto;
    scroll-padding-inline: max(16px, calc((100vw - 224px) / 2));
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .drawn-cards.three-cards::-webkit-scrollbar {
    display: none;
  }

  .drawn-cards.three-cards .drawn-card-shell {
    min-width: 208px;
    scroll-snap-align: center;
  }

  .drawn-cards.one-card {
    grid-template-columns: minmax(175px, 215px);
  }

  .basic-reading {
    padding: 15px;
  }

  .inside-app {
    padding-block: 78px 74px;
  }

  .tarot-guide {
    padding-block: 76px;
  }

  .guide-reflection {
    grid-template-columns: 1fr;
    padding: 22px;
  }

  .guide-reflection .secondary-button {
    width: 100%;
  }

  .section-heading h2 {
    font-size: 42px;
  }

  .app-banner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .app-banner img {
    margin-inline: auto;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .footer-inner > p {
    grid-column: auto;
    grid-row: auto;
  }

  .footer-links {
    justify-content: flex-start;
  }

  .dialog-content {
    padding: 30px 22px 26px;
  }

  .app-dialog h2 {
    font-size: 28px;
  }

  .qr-link {
    width: 176px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
