:root {
  --bg-image: url("./assets/bg-home-oracle-room.png");
  --bg-mobile-image: url("./assets/bg-home-oracle-room-mobile.webp");
  --bg-position: center;
  --bg-mobile-position: center center;
  --text: #fff8ea;
  --soft: rgba(255, 248, 234, .78);
  --muted: rgba(255, 248, 234, .58);
  --line: rgba(255, 255, 255, .14);
  --line-strong: rgba(255, 231, 179, .32);
  --glass: rgba(14, 11, 14, .22);
  --glass-strong: rgba(14, 11, 14, .34);
  --surface: rgba(255, 255, 255, .055);
  --surface-strong: rgba(255, 255, 255, .092);
  --accent: #d7b46c;
  --accent-2: #fff0bf;
  --accent-deep: #3b2f20;
  --ink: #20160d;
  --motif-opacity: .18;
  --shadow: 0 28px 90px rgba(0, 0, 0, .38);
  color-scheme: dark;
  font-family: Pretendard, "Apple SD Gothic Neo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body[data-service="oracle"] {
  --bg-image: url("./assets/bg-home-oracle-room.png");
  --bg-mobile-image: url("./assets/bg-home-oracle-room-mobile.webp");
  --bg-position: center center;
  --bg-mobile-position: center center;
  --accent: #d8b76f;
  --accent-2: #fff1c3;
  --accent-deep: #3b2f20;
  --motif-opacity: .16;
}

body[data-service="tarot"] {
  --bg-image: url("./assets/tarot/fate-vintage-oracle/draw-scene-hands.png");
  --bg-mobile-image: url("./assets/tarot/fate-vintage-oracle/draw-scene-hands-mobile.webp");
  --bg-position: center center;
  --bg-mobile-position: center center;
  --accent: #d4ad63;
  --accent-2: #ffe8af;
  --accent-deep: #153d34;
  --motif-opacity: .2;
}

body[data-service="saju"] {
  --bg-image: url("./assets/bg-saju-paper.png");
  --bg-mobile-image: url("./assets/bg-saju-paper-mobile.webp");
  --bg-position: center center;
  --bg-mobile-position: center center;
  --accent: #d5a05e;
  --accent-2: #ffe4ad;
  --accent-deep: #50351f;
  --motif-opacity: .26;
}

body[data-service="palm"] {
  --bg-image: url("./assets/bg-palm-hand.png");
  --bg-mobile-image: url("./assets/bg-palm-hand-mobile.webp");
  --bg-position: 62% center;
  --bg-mobile-position: center center;
  --accent: #c98b61;
  --accent-2: #ffdcc1;
  --accent-deep: #633d2a;
  --motif-opacity: .22;
}

body[data-service="face"] {
  --bg-image: url("./assets/bg-face-gwansang.png");
  --bg-mobile-image: url("./assets/bg-face-gwansang-mobile.webp");
  --bg-position: 64% center;
  --bg-mobile-position: center center;
  --accent: #cd8f93;
  --accent-2: #ffd9df;
  --accent-deep: #57333c;
  --glass: rgba(16, 10, 13, .16);
  --motif-opacity: .22;
}

body[data-service="astrology"] {
  --bg-image: url("./assets/bg-astro-sky.png");
  --bg-mobile-image: url("./assets/bg-astro-sky-mobile.webp");
  --bg-position: center center;
  --bg-mobile-position: center center;
  --accent: #9fc5de;
  --accent-2: #ddf1ff;
  --accent-deep: #1d4263;
  --motif-opacity: .34;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  overflow-x: hidden;
  background: #080609;
}

body {
  width: 100%;
  max-width: 100%;
  min-width: 320px;
  height: 100dvh;
  margin: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: var(--text);
  font-family: Pretendard, "Apple SD Gothic Neo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #080609;
  text-rendering: geometricPrecision;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
  contain: paint;
  opacity: .07;
  background-image: radial-gradient(circle, rgba(255, 255, 255, .62) .55px, transparent 1px);
  background-size: 106px 106px;
}

button,
a {
  font: inherit;
}

button {
  cursor: pointer;
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid rgba(255, 238, 195, .92);
  outline-offset: 3px;
}

.scene-bg,
.scene-shade {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.scene-bg {
  z-index: 0;
  background-image: var(--bg-image);
  background-position: var(--bg-position);
  background-size: cover;
  overflow: hidden;
  contain: paint;
  filter: saturate(1.08) contrast(1.05) brightness(1.08);
  transition: background-image .22s ease, filter .22s ease;
}

@media (max-width: 820px) {
  .scene-bg {
    background-image: var(--bg-mobile-image);
    background-position: var(--bg-mobile-position);
  }
}

.scene-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: var(--motif-opacity);
}

body[data-service="oracle"] .scene-bg::after {
  background:
    radial-gradient(circle at 50% 44%, transparent 0 18%, rgba(255, 231, 168, .7) 18.4% 18.8%, transparent 19.2%),
    radial-gradient(circle at 50% 44%, transparent 0 31%, rgba(255, 231, 168, .48) 31.4% 31.7%, transparent 32.1%),
    linear-gradient(90deg, transparent 49.9%, rgba(255, 231, 168, .46) 50%, transparent 50.1%);
}

body[data-service="tarot"] .scene-bg::after {
  background:
    radial-gradient(circle at 50% 50%, transparent 0 9%, rgba(255, 222, 150, .76) 9.4% 9.8%, transparent 10.2%),
    radial-gradient(circle at 50% 50%, transparent 0 22%, rgba(255, 222, 150, .62) 22.4% 22.8%, transparent 23.2%),
    linear-gradient(90deg, transparent 49.88%, rgba(255, 222, 150, .5) 50%, transparent 50.12%),
    linear-gradient(0deg, transparent 49.88%, rgba(255, 222, 150, .5) 50%, transparent 50.12%);
}

body[data-service="saju"] .scene-bg::after {
  background:
    linear-gradient(90deg, transparent 0 9%, rgba(32, 14, 7, .62) 9.1% 9.28%, transparent 9.4%),
    linear-gradient(0deg, transparent 0 12%, rgba(32, 14, 7, .45) 12.1% 12.28%, transparent 12.4%),
    radial-gradient(circle at 82% 74%, transparent 0 4.2%, rgba(157, 25, 22, .82) 4.4% 5.1%, transparent 5.3%);
  background-size: 142px 142px, 142px 142px, 100% 100%;
}

body[data-service="palm"] .scene-bg::after {
  background:
    radial-gradient(ellipse at 76% 55%, transparent 0 17%, rgba(238, 184, 104, .72) 17.4% 18%, transparent 18.3%),
    radial-gradient(ellipse at 77% 64%, transparent 0 10%, rgba(238, 184, 104, .5) 10.4% 10.9%, transparent 11.2%),
    linear-gradient(136deg, transparent 58%, rgba(238, 184, 104, .26), transparent 66%);
}

body[data-service="face"] .scene-bg::after {
  background:
    radial-gradient(ellipse at 77% 51%, rgba(255, 230, 211, .16) 0 14%, transparent 14.4%),
    radial-gradient(ellipse at 77% 51%, transparent 0 22%, rgba(230, 184, 132, .68) 22.3% 22.8%, transparent 23.1%),
    radial-gradient(ellipse at 78% 46%, transparent 0 9%, rgba(255, 255, 255, .42) 9.3% 9.6%, transparent 10%);
}

body[data-service="astrology"] .scene-bg::after {
  background:
    radial-gradient(circle at 78% 70%, transparent 0 14%, rgba(185, 218, 255, .74) 14.3% 14.8%, transparent 15.1%),
    linear-gradient(90deg, transparent 77.9%, rgba(185, 218, 255, .48) 78%, transparent 78.1%),
    linear-gradient(0deg, transparent 69.9%, rgba(185, 218, 255, .42) 70%, transparent 70.1%),
    radial-gradient(circle at 19% 22%, rgba(220, 238, 255, .78) 0 1px, transparent 1.6px),
    radial-gradient(circle at 44% 15%, rgba(220, 238, 255, .58) 0 1px, transparent 1.7px);
  background-size: 100% 100%, 100% 100%, 100% 100%, 180px 180px, 230px 230px;
}

.scene-shade {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(5, 5, 7, .54), rgba(5, 5, 7, .08) 34%, rgba(5, 5, 7, .1) 67%, rgba(5, 5, 7, .5)),
    linear-gradient(180deg, rgba(5, 5, 7, .34), rgba(5, 5, 7, 0) 42%, rgba(5, 5, 7, .52)),
    radial-gradient(circle at 50% 40%, rgba(255, 228, 172, .14), transparent 38%);
}

.app-shell {
  position: relative;
  z-index: 2;
  width: min(1500px, calc(100% - 32px));
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 16px;
  margin-inline: auto;
  padding: 18px 0 22px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 6px;
}

/* Soft top scrim so the pinned title + action cluster stay readable over scrolling content. */
.topbar::before {
  content: "";
  position: absolute;
  left: -24px;
  right: -24px;
  top: -16px;
  bottom: -12px;
  background: linear-gradient(180deg, rgba(8, 6, 10, .72), rgba(8, 6, 10, .3) 58%, transparent);
  pointer-events: none;
  z-index: -1;
}

.topbar-actions { flex-wrap: nowrap; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 1.06rem;
  font-weight: 950;
  text-decoration: none;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border: 0;
  border-radius: 0;
  background: url("./assets/brand/oracluna-mark.png") center / contain no-repeat;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .34));
}

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

.topbar-link {
  position: relative;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid rgba(255, 231, 179, .2);
  border-radius: 8px;
  background: rgba(255, 255, 255, .048);
  color: var(--accent-2);
  font-size: .82rem;
  font-weight: 900;
  text-decoration: none;
}

button.topbar-link {
  cursor: pointer;
}

.topbar-link:hover {
  border-color: color-mix(in srgb, var(--accent) 60%, white 40%);
  background: rgba(255, 255, 255, .078);
}

/* Top-right back button (replaces the in-header 카테고리 link). */
.top-back-button {
  min-height: 44px;
  width: 44px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255, 231, 179, .22);
  border-radius: 10px;
  background: rgba(255, 255, 255, .048);
  color: var(--accent-2);
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease;
}

.top-back-button:hover,
.top-back-button:focus-visible {
  border-color: color-mix(in srgb, var(--accent) 60%, white 40%);
  background: rgba(255, 255, 255, .085);
  outline: none;
}

.top-back-button[hidden] { display: none; }
.top-back-button .ui-icon { width: 20px; height: 20px; }

.topbar-link.has-new-saved {
  border-color: rgba(255, 231, 174, .38);
  color: var(--accent-2);
  box-shadow: inset 0 0 0 1px rgba(255, 231, 174, .05), 0 0 20px rgba(255, 222, 149, .08);
}

.topbar-link.has-new-saved::after {
  content: "";
  position: absolute;
  inset: -5px;
  border: 1px solid rgba(255, 231, 174, .28);
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  animation: savedSealPulse 1.05s ease both;
}

.audio-toggle {
  min-width: 76px;
  white-space: nowrap;
}

.audio-toggle.is-audio-on {
  border-color: rgba(255, 231, 174, .34);
  color: var(--accent-2);
  background: rgba(255, 231, 174, .09);
  box-shadow: inset 0 0 0 1px rgba(255, 231, 174, .06), 0 0 18px rgba(255, 222, 149, .08);
}

.topbar-status {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 2px;
  color: var(--soft);
  font-size: .82rem;
  font-weight: 850;
}

.topbar-status span {
  color: var(--accent-2);
}

.topbar-status strong {
  color: var(--muted);
}

.experience-grid {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr) 370px;
  gap: 16px;
  align-items: stretch;
}

.glass-panel {
  position: relative;
  min-width: 0;
  border-radius: 8px;
}

.glass-panel::before {
  content: none;
}

.service-rail,
.studio,
.result-panel {
  min-height: calc(100vh - 112px);
  padding: 18px;
}

.service-rail {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
}

h1,
h2,
h3,
p {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  margin-top: 8px;
  font-size: 1.42rem;
  line-height: 1.25;
  font-weight: 950;
  word-break: keep-all;
}

h2 {
  font-size: 2.25rem;
  line-height: 1.08;
  font-weight: 950;
  word-break: keep-all;
}

h3 {
  font-size: 1.06rem;
  line-height: 1.35;
  font-weight: 950;
  word-break: keep-all;
}

.eyebrow {
  color: var(--accent);
  font-size: .74rem;
  font-weight: 950;
}

.service-list {
  min-height: 0;
  display: grid;
  gap: 10px;
  align-content: start;
  overflow: auto;
  padding-right: 2px;
}

.service-button {
  min-height: 76px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 8px;
  background: rgba(255, 255, 255, .043);
  color: var(--text);
  text-align: left;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.service-button:hover,
.service-button.is-active {
  border-color: color-mix(in srgb, var(--accent) 72%, white 28%);
  background: color-mix(in srgb, var(--accent-deep) 52%, rgba(255, 255, 255, .12) 48%);
}

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

.service-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 8px;
  color: var(--accent-2);
  background: rgba(255, 255, 255, .06);
  font-size: .96rem;
  font-weight: 950;
}

.service-button strong,
.service-button small {
  display: block;
}

.service-button strong {
  font-size: 1rem;
  font-weight: 950;
}

.service-button small {
  margin-top: 4px;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.38;
  word-break: keep-all;
}

body[data-service="tarot"] .topbar-link {
  border-color: rgba(255, 231, 174, .13);
  background: rgba(7, 6, 8, .22);
  color: rgba(255, 248, 234, .74);
}

body[data-service="tarot"] .topbar-link:hover,
body[data-service="tarot"] .topbar-link.has-new-saved {
  border-color: rgba(255, 231, 174, .24);
  background: rgba(255, 231, 174, .055);
  color: rgba(255, 248, 234, .9);
}

body[data-service="tarot"] .service-rail,
body[data-service="tarot"] .result-panel {
  color: rgba(255, 248, 234, .78);
}

body[data-service="tarot"] .service-button {
  border-color: rgba(255, 255, 255, .075);
  background: rgba(255, 255, 255, .018);
  color: rgba(255, 248, 234, .76);
}

body[data-service="tarot"] .service-button:hover,
body[data-service="tarot"] .service-button.is-active {
  border-color: rgba(255, 231, 174, .24);
  background: rgba(255, 231, 174, .07);
}

body[data-service="tarot"] .service-icon {
  border-color: rgba(255, 255, 255, .1);
  background: rgba(255, 255, 255, .036);
  color: rgba(255, 231, 174, .82);
}

body[data-service="tarot"] .result-head .eyebrow {
  color: rgba(255, 231, 174, .72);
}

body[data-service="tarot"] .result-head h2 {
  color: rgba(255, 248, 234, .9);
}

body[data-service="tarot"] .result-head h3,
body[data-service="tarot"] .reading-copy h3 {
  color: rgba(255, 231, 174, .78);
}

@media (min-width: 1221px) {
  body[data-service="tarot"] .experience-grid {
    grid-template-columns: 84px minmax(640px, 1fr) 330px;
    gap: 12px;
  }

  body[data-service="tarot"] .service-rail {
    grid-template-rows: 1fr;
    padding: 18px 4px;
  }

  body[data-service="tarot"] .rail-copy {
    display: none;
  }

  body[data-service="tarot"] .service-list {
    gap: 8px;
    justify-items: center;
    overflow: visible;
    padding-right: 0;
  }

  body[data-service="tarot"] .service-button {
    width: 56px;
    min-height: 54px;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 0;
    padding: 6px;
    border-color: rgba(255, 255, 255, .07);
    background: rgba(255, 255, 255, .018);
  }

  body[data-service="tarot"] .service-icon {
    width: 36px;
    height: 36px;
    font-size: .82rem;
  }

  body[data-service="tarot"] .service-button strong,
  body[data-service="tarot"] .service-button small {
    display: none;
  }

  body[data-service="tarot"] .result-panel {
    padding-inline: 14px 18px;
    gap: 12px;
  }

  body[data-service="tarot"] .result-head h2 {
    font-size: 1.34rem;
  }

  body[data-service="tarot"] .reading-copy p {
    color: rgba(255, 248, 234, .7);
  }

  body[data-service="tarot"] .system-status {
    gap: 5px;
    padding-top: 8px;
    opacity: .72;
  }

  body[data-service="tarot"] .status-line strong {
    color: var(--muted);
    font-size: .7rem;
  }

  body[data-service="tarot"] .status-line button {
    min-height: 24px;
    padding-inline: 7px;
    font-size: .62rem;
  }

  body[data-service="tarot"] .status-chips {
    gap: 4px;
    max-height: 22px;
    overflow: hidden;
  }

  body[data-service="tarot"] .status-chip {
    min-height: 19px;
    padding-inline: 6px;
    font-size: .58rem;
  }

  body[data-service="tarot"] .system-status p {
    display: -webkit-box;
    overflow: hidden;
    font-size: .64rem;
    line-height: 1.25;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
  }
}

.studio {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 14px;
}

.studio-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.selection-count {
  min-width: 92px;
  min-height: 70px;
  display: grid;
  place-items: center;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 231, 174, .14);
}

.selection-count strong {
  color: var(--accent-2);
  font-size: 2rem;
  line-height: 1;
}

.selection-count span {
  color: var(--muted);
  font-size: .78rem;
  font-weight: 850;
}

.topic-row,
.mode-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

body[data-service="tarot"] .topic-row {
  display: none;
}

body[data-service="saju"] .topic-row,
body[data-service="astrology"] .topic-row,
body[data-service="palm"] .topic-row,
body[data-service="face"] .topic-row {
  display: none !important;
}

.topic-button,
.mode-button,
.chip-button,
.ghost-button,
.gold-button {
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, .05);
  font-weight: 900;
}

.topic-button,
.mode-button,
.chip-button {
  padding: 0 14px;
}

.topic-button.is-active,
.mode-button.is-active,
.chip-button.is-active {
  border-color: color-mix(in srgb, var(--accent) 70%, white 30%);
  background: color-mix(in srgb, var(--accent-deep) 56%, rgba(255, 255, 255, .13) 44%);
  color: var(--accent-2);
}

.service-stage {
  min-height: 0;
  display: grid;
}

.tool-layout {
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 14px;
}

.tool-caption {
  max-width: 72ch;
  color: var(--muted);
  font-size: .9rem;
  line-height: 1.62;
  word-break: keep-all;
}

.stage-split {
  min-height: 430px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
  align-items: start;
  gap: 14px;
}

body[data-service="tarot"] .stage-split {
  grid-template-columns: minmax(0, 1fr);
}

.visual-canvas,
.side-panel,
.option-canvas {
  border-radius: 8px;
}

.visual-canvas {
  position: relative;
  align-self: start;
  min-height: 430px;
  overflow: hidden;
}

.side-panel {
  height: clamp(500px, calc(100vh - 240px), 760px);
  overflow: hidden;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 10px;
  padding: 14px;
}

.side-title {
  color: var(--soft);
  font-size: .82rem;
  font-weight: 950;
}

.option-list {
  min-height: 0;
  display: grid;
  gap: 8px;
  align-content: start;
  overflow: auto;
  padding-right: 4px;
}

.tarot-deck-panel {
  height: clamp(260px, 30vh, 360px);
  padding: 12px;
}

.tarot-deck-groups {
  min-height: 0;
  display: grid;
  gap: 14px;
  align-content: start;
  overflow: auto;
  padding-right: 4px;
}

.tarot-deck-group {
  display: grid;
  gap: 8px;
}

.tarot-deck-heading {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 4px 2px 7px;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
  background: var(--bg);
  color: var(--accent-2);
}

.tarot-deck-heading span {
  font-size: .76rem;
  font-weight: 950;
}

.tarot-deck-heading small {
  color: var(--muted);
  font-size: .68rem;
  font-weight: 900;
}

.tarot-mini-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: 8px;
}

.pool-card,
.mini-card {
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 8px;
  background: rgba(255, 255, 255, .044);
}

.pool-card {
  min-height: 62px;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 9px;
  color: var(--text);
  text-align: left;
}

.pool-card.is-tarot {
  min-height: 0;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  justify-items: center;
  gap: 7px;
  padding: 7px;
  text-align: center;
}

.pool-card.is-active {
  border-color: color-mix(in srgb, var(--accent) 66%, white 34%);
  background: color-mix(in srgb, var(--accent-deep) 48%, rgba(255, 255, 255, .13) 52%);
}

.pool-mark {
  width: 40px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: 7px;
  color: var(--accent-2);
  background: rgba(0, 0, 0, .16);
  font-size: .78rem;
  font-weight: 950;
}

.pool-thumb {
  width: 42px;
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 5px;
  background-color: rgba(0, 0, 0, .18);
  background-position: center;
  background-size: cover;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .25);
}

.pool-card strong,
.pool-card small {
  display: block;
}

.pool-card strong {
  font-size: .92rem;
}

.pool-card small {
  margin-top: 3px;
  color: var(--muted);
  font-size: .73rem;
  line-height: 1.36;
}

.pool-card.is-tarot .pool-thumb {
  width: 100%;
  max-width: 74px;
  justify-self: center;
}

.pool-card.is-tarot strong {
  width: 100%;
  overflow: hidden;
  font-size: .72rem;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pool-card.is-tarot small {
  width: 100%;
  overflow: hidden;
  margin-top: 2px;
  font-size: .62rem;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.room-canvas {
  display: grid;
  place-items: center;
  padding: 24px;
}

.room-table {
  width: min(550px, 100%);
  min-height: 340px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(135px, 1fr));
  gap: 12px;
}

.room-station {
  position: relative;
  display: grid;
  align-content: end;
  gap: 8px;
  min-height: 132px;
  padding: 15px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 18%, color-mix(in srgb, var(--accent) 46%, transparent), transparent 23%),
    rgba(0, 0, 0, .12);
  color: var(--text);
  text-align: left;
}

.room-station::before {
  content: "";
  width: 42px;
  height: 42px;
  border: 1px solid color-mix(in srgb, var(--accent) 58%, white 42%);
  border-radius: 50%;
  background: rgba(255, 255, 255, .06);
}

.room-station.is-active,
.room-station:hover {
  border-color: color-mix(in srgb, var(--accent) 72%, white 28%);
  background:
    radial-gradient(circle at 50% 18%, color-mix(in srgb, var(--accent) 62%, transparent), transparent 25%),
    color-mix(in srgb, var(--accent-deep) 44%, rgba(255, 255, 255, .1) 56%);
}

.tarot-canvas {
  isolation: isolate;
  display: grid;
  align-content: start;
  justify-items: stretch;
  gap: 10px;
  padding: 20px 18px 18px;
  background: transparent;
}

.tarot-canvas.is-revealing-card::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: 1;
  width: min(760px, 96%);
  height: min(520px, 76%);
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 50% 50%, rgba(255, 238, 190, .34), rgba(255, 238, 190, .08) 38%, transparent 68%),
    conic-gradient(from -28deg, transparent 0 12%, rgba(255, 232, 178, .38) 15%, transparent 20% 42%, rgba(255, 232, 178, .26) 45%, transparent 50% 74%, rgba(255, 232, 178, .32) 77%, transparent 82% 100%);
  opacity: 0;
  filter: blur(.2px);
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.62) rotate(-20deg);
  animation: tarotRevealSweep 1.08s cubic-bezier(.16, .78, .18, 1) both;
}

.tarot-settings {
  position: relative;
  z-index: 6;
  display: grid;
  gap: 8px;
}

.tarot-settings-summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px 7px;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .16);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.tarot-settings-summary span {
  min-width: 0;
  overflow: hidden;
  color: var(--soft);
  font-size: .78rem;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tarot-settings-summary strong {
  color: var(--accent-2);
  font-size: .72rem;
  font-weight: 950;
}

.tarot-settings-panel {
  display: grid;
  gap: 9px;
  padding: 0 0 6px;
}

.tarot-setting-group {
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.tarot-setting-group > span {
  padding-top: 9px;
  color: var(--muted);
  font-size: .68rem;
  font-weight: 950;
}

.tarot-setting-options {
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tarot-settings .topic-button,
.tarot-settings .mode-button {
  min-height: 34px;
  padding-inline: 10px;
  font-size: .74rem;
}

.tarot-ritual,
.tarot-cut,
.tarot-deck-surface {
  position: relative;
  z-index: 3;
}

.tarot-ritual {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.tarot-question {
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 8px;
  align-items: center;
}

.tarot-question-summary {
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: baseline;
  padding-bottom: 7px;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
}

.tarot-question span,
.tarot-question-summary span,
.tarot-step-copy strong {
  color: var(--accent-2);
  font-size: .74rem;
  font-weight: 950;
}

.tarot-question-summary strong {
  min-width: 0;
  overflow: hidden;
  color: var(--soft);
  font-size: .76rem;
  font-weight: 900;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tarot-question input {
  width: 100%;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(255, 231, 174, .14);
  border-radius: 8px;
  background: rgba(5, 4, 7, .26);
  color: var(--text);
  font: inherit;
  font-weight: 850;
}

.tarot-question input:focus {
  outline: 2px solid color-mix(in srgb, var(--accent) 48%, transparent);
  outline-offset: 2px;
}

.tarot-question small,
.tarot-step-copy span {
  color: var(--muted);
  font-size: .68rem;
  font-weight: 850;
  line-height: 1.35;
}

.tarot-question small {
  grid-column: 2;
}

.tarot-ritual-actions,
.tarot-deck-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.tarot-ritual-actions .ghost-button,
.tarot-deck-actions .ghost-button,
.tarot-deck-actions .gold-button {
  min-height: 36px;
}

.tarot-ritual-actions .ghost-button,
.tarot-deck-actions .ghost-button {
  background: rgba(255, 255, 255, .035);
  color: var(--soft);
}

.tarot-ritual.is-compact {
  gap: 8px;
}

.tarot-ritual.is-compact .tarot-ritual-actions .ghost-button {
  min-height: 32px;
}

.tarot-shuffle-bridge {
  position: relative;
  min-height: clamp(560px, 72vh, 760px);
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  isolation: isolate;
}

.tarot-shuffle-bridge::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 44%;
  z-index: -1;
  width: min(520px, 94%);
  height: 128px;
  border-radius: 50%;
  background:
    radial-gradient(ellipse at center, rgba(255, 226, 158, .19), rgba(255, 226, 158, .045) 46%, transparent 74%),
    linear-gradient(90deg, transparent 0 24%, rgba(255, 231, 174, .13) 44%, transparent 68% 100%);
  opacity: .72;
  filter: blur(.45px);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.tarot-shuffle-bridge .tarot-step-copy {
  justify-items: center;
  text-align: center;
}

.tarot-shuffle-deck {
  position: relative;
  width: min(960px, 96vw);
  height: clamp(520px, 66vh, 720px);
  perspective: 900px;
  transform: translateZ(0);
}

.tarot-shuffle-shadow {
  position: absolute;
  left: 50%;
  top: 68%;
  width: min(420px, 78%);
  height: 48px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, .42), rgba(0, 0, 0, .18) 48%, transparent 76%);
  opacity: .5;
  transform: translate(-50%, -50%) scale(.82);
  filter: blur(5px);
  animation: tarotShuffleShadow 2.24s cubic-bezier(.18, .72, .18, 1) both;
}

.tarot-shuffle-card {
  --shuffle-start-x: -118px;
  --shuffle-start-y: 0px;
  --shuffle-start-r: -16deg;
  --shuffle-riffle-x: 22px;
  --shuffle-riffle-y: -28px;
  --shuffle-riffle-r: -8deg;
  --shuffle-bridge-x: 0px;
  --shuffle-bridge-y: -42px;
  --shuffle-bridge-r: 0deg;
  --shuffle-lift-y: -18px;
  --shuffle-counter-r: 0deg;
  --shuffle-settle-x: 0px;
  --shuffle-settle-y: 6px;
  --shuffle-settle-r: 0deg;
  --shuffle-overshoot-x: 0px;
  --shuffle-overshoot-y: -4px;
  --shuffle-overshoot-r: 0deg;
  --shuffle-end-x: 0px;
  --shuffle-end-y: 0px;
  --shuffle-end-r: 0deg;
  --shuffle-delay: 0ms;
  --shuffle-z: 1;
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: var(--shuffle-z);
  width: clamp(272px, 35vw, 376px);
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(255, 231, 174, .38);
  border-radius: 8px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  box-shadow: 0 20px 30px rgba(0, 0, 0, .3), 0 0 18px rgba(255, 226, 156, .07);
  opacity: .94;
  backface-visibility: hidden;
  animation: tarotShuffleWeave 2.24s cubic-bezier(.18, .72, .18, 1) both;
  animation-delay: var(--shuffle-delay);
  transform-origin: 50% 118%;
  will-change: transform, filter, opacity;
}

.tarot-shuffle-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    linear-gradient(112deg, transparent 0 34%, rgba(255, 246, 213, .18) 42%, transparent 52% 100%),
    linear-gradient(180deg, rgba(255, 255, 255, .06), transparent 46%, rgba(0, 0, 0, .14));
  opacity: .48;
  pointer-events: none;
}

.tarot-cut {
  display: grid;
  gap: 10px;
}

.tarot-cut-recombine {
  min-height: clamp(520px, 66vh, 720px);
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 8px;
}

.tarot-cut-recombine .tarot-step-copy {
  justify-items: center;
  text-align: center;
}

.tarot-recombine-stage {
  position: relative;
  width: min(960px, 96vw);
  height: clamp(500px, 62vh, 680px);
}

.tarot-recombine-pile {
  --recombine-from-x: 0px;
  --recombine-from-y: 0px;
  --recombine-from-r: 0deg;
  --recombine-mid-x: 0px;
  --recombine-mid-r: 0deg;
  --recombine-end-x: 0px;
  --recombine-end-r: 0deg;
  position: absolute;
  left: 50%;
  top: 50%;
  width: clamp(232px, 30vw, 296px);
  aspect-ratio: 2 / 3;
  transform-origin: 50% 118%;
  animation: tarotCutRecombine .76s cubic-bezier(.18, .82, .2, 1) both;
  animation-delay: calc(var(--recombine-i, 0) * 90ms);
}

.tarot-recombine-pile::after {
  content: var(--pile-number);
  position: absolute;
  right: -7px;
  top: -7px;
  z-index: 4;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .38);
  border-radius: 999px;
  background: rgba(7, 6, 8, .76);
  color: var(--accent-2);
  font-size: .7rem;
  font-weight: 950;
}

.tarot-recombine-pile span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 7px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  box-shadow: 0 18px 26px rgba(0, 0, 0, .28);
}

.tarot-recombine-pile span:nth-child(1) {
  transform: rotate(-7deg) translate(-8px, 5px);
  opacity: .62;
}

.tarot-recombine-pile span:nth-child(2) {
  transform: rotate(5deg) translate(7px, 3px);
  opacity: .76;
}

.tarot-recombine-pile span:nth-child(3) {
  transform: rotate(0deg);
}

.tarot-recombine-pile:nth-child(1) {
  --recombine-from-x: -94px;
  --recombine-from-y: 10px;
  --recombine-from-r: -12deg;
  --recombine-mid-x: -22px;
  --recombine-mid-r: -4deg;
  --recombine-end-x: -3px;
  --recombine-end-r: -1deg;
  z-index: 3;
}

.tarot-recombine-pile:nth-child(2) {
  --recombine-from-x: 92px;
  --recombine-from-y: -4px;
  --recombine-from-r: 10deg;
  --recombine-mid-x: 22px;
  --recombine-mid-r: 4deg;
  --recombine-end-x: 0px;
  --recombine-end-r: 0deg;
  z-index: 2;
}

.tarot-recombine-pile:nth-child(3) {
  --recombine-from-x: 0px;
  --recombine-from-y: 26px;
  --recombine-from-r: 2deg;
  --recombine-mid-x: 0px;
  --recombine-mid-r: 1deg;
  --recombine-end-x: 3px;
  --recombine-end-r: 1deg;
  z-index: 1;
}

.tarot-step-copy {
  display: grid;
  gap: 3px;
}

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

.tarot-cut-pile {
  position: relative;
  min-height: clamp(360px, 48vh, 460px);
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  padding: 10px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  transform-origin: 50% 100%;
  isolation: isolate;
  transition: filter .18s ease, transform .18s ease;
}

.tarot-cut-pile::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 48%;
  z-index: -1;
  width: min(330px, 28vw);
  height: min(270px, 22vw);
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(255, 226, 158, .16), rgba(255, 226, 158, 0) 72%);
  opacity: .72;
  transform: translate(-50%, -50%) scale(.92);
  transition: opacity .18s ease, transform .18s ease;
  pointer-events: none;
}

.tarot-canvas.tarot-stage-cut .tarot-cut-pile {
  animation: tarotCutPileIn .54s cubic-bezier(.18, .84, .24, 1.06) both;
  animation-delay: calc(var(--pile-i, 0) * 95ms);
}

.tarot-cut-pile:hover {
  filter: brightness(1.1) saturate(1.04);
  transform: translateY(-7px);
}

.tarot-cut-pile:hover::before,
.tarot-cut-pile:focus-visible::before {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.16);
}

.tarot-cut-pile:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 64%, white 36%);
  outline-offset: 4px;
}

.cut-stack {
  position: relative;
  width: clamp(220px, 26vw, 272px);
  aspect-ratio: 2 / 3;
}

.cut-stack span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 6px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  box-shadow: 0 14px 22px rgba(0, 0, 0, .3), inset 0 0 0 1px rgba(255, 255, 255, .06);
}

.tarot-cut-pile strong {
  min-width: 24px;
  min-height: 24px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .32);
  border-radius: 999px;
  background: rgba(7, 6, 8, .72);
  color: var(--accent-2);
  font-size: .7rem;
  font-weight: 950;
}

.tarot-cut-pile small {
  color: var(--muted);
  font-size: .64rem;
  font-weight: 900;
}

.cut-stack span:nth-child(1) { transform: rotate(-8deg) translate(-8px, 5px); opacity: .62; }
.cut-stack span:nth-child(2) { transform: rotate(5deg) translate(7px, 3px); opacity: .76; }
.cut-stack span:nth-child(3) { transform: rotate(0deg); }

.tarot-canvas.tarot-stage-cut .cut-stack span:nth-child(1) {
  animation: tarotCutCardFanLeft .7s ease both;
  animation-delay: calc(var(--pile-i, 0) * 95ms + 120ms);
}

.tarot-canvas.tarot-stage-cut .cut-stack span:nth-child(2) {
  animation: tarotCutCardFanRight .72s ease both;
  animation-delay: calc(var(--pile-i, 0) * 95ms + 140ms);
}

.tarot-table-state {
  display: none;
}

.tarot-table-state span {
  color: var(--muted);
  font-size: .66rem;
  font-weight: 900;
}

.tarot-table-state strong {
  color: var(--accent-2);
  font-size: .78rem;
  font-weight: 950;
}

.tarot-canvas-reset {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 8;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(255, 231, 174, .18);
  border-radius: 999px;
  background: rgba(7, 6, 8, .24);
  color: color-mix(in srgb, var(--soft) 84%, white 16%);
  font-size: .76rem;
  font-weight: 900;
  line-height: 1;
  box-shadow: none;
}

.tarot-canvas-reset:hover,
.tarot-canvas-reset:focus-visible {
  border-color: rgba(255, 231, 174, .36);
  color: var(--accent-2);
  background: rgba(255, 231, 174, .07);
}

.tarot-progress {
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-items: start;
  gap: 5px;
  padding: 0 4px 2px;
}

.tarot-progress::before,
.tarot-progress::after {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  top: 10px;
  height: 1px;
  border-radius: 999px;
  pointer-events: none;
}

.tarot-progress::before {
  background: rgba(255, 231, 174, .12);
}

.tarot-progress::after {
  right: auto;
  width: calc(var(--ritual-progress, 0%) * .98);
  background: linear-gradient(90deg, rgba(255, 231, 174, .18), rgba(255, 231, 174, .86));
  box-shadow: 0 0 18px rgba(255, 222, 149, .12);
  transition: width .42s cubic-bezier(.18, .8, .22, 1);
}

.tarot-progress-step {
  position: relative;
  z-index: 1;
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 4px;
  color: var(--muted);
}

.tarot-progress-step i {
  width: 20px;
  aspect-ratio: 1;
  display: block;
  border: 1px solid rgba(255, 231, 174, .2);
  border-radius: 999px;
  background: rgba(7, 6, 8, .72);
  box-shadow: inset 0 0 0 4px rgba(255, 231, 174, .025);
}

.tarot-progress-step b {
  max-width: 100%;
  overflow: hidden;
  font-size: .58rem;
  font-weight: 950;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tarot-progress-step.is-complete {
  color: rgba(255, 231, 174, .76);
}

.tarot-progress-step.is-complete i {
  border-color: rgba(255, 231, 174, .48);
  background:
    radial-gradient(circle, rgba(255, 231, 174, .88), rgba(255, 231, 174, .36) 38%, transparent 42%),
    rgba(7, 6, 8, .76);
  box-shadow: 0 0 18px rgba(255, 222, 149, .12);
}

.tarot-progress-step.is-active {
  color: var(--accent-2);
}

.tarot-progress-step.is-active i {
  border-color: rgba(255, 231, 174, .72);
  background:
    radial-gradient(circle, rgba(255, 246, 213, .96), rgba(255, 231, 174, .46) 42%, transparent 46%),
    rgba(7, 6, 8, .78);
  box-shadow: 0 0 22px rgba(255, 222, 149, .2);
  animation: tarotProgressPulse 1.45s ease-in-out infinite;
}

.tarot-canvas::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, .13) 42%, rgba(0, 0, 0, .3));
}

.tarot-offer {
  position: absolute;
  top: 22px;
  left: 50%;
  z-index: 3;
  width: min(270px, 52%);
  min-height: 248px;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 8px;
  padding: 0 0 14px;
  border: 0;
  background: transparent;
  color: var(--text);
  text-align: center;
  transform: translateX(-50%);
  transition: transform .2s ease, opacity .2s ease, filter .2s ease;
}

.tarot-offer:not(:disabled):hover {
  transform: translateX(-50%) translateY(3px);
  filter: brightness(1.08);
}

.tarot-canvas.is-drawing .tarot-offer {
  z-index: 1;
  opacity: .18;
  pointer-events: none;
  transform: translateX(-50%) translateY(-36px) scale(.62);
}

.tarot-canvas.is-drawing .card-spread {
  z-index: 4;
}

.tarot-canvas.is-drawing .tarot-offer:not(:disabled):hover {
  opacity: .28;
  transform: translateX(-50%) translateY(-32px) scale(.64);
}

.tarot-offer:disabled {
  cursor: default;
}

.offer-hands {
  position: relative;
  width: 210px;
  height: 76px;
  opacity: .88;
}

.offer-hands span {
  position: absolute;
  top: -10px;
  width: 74px;
  height: 126px;
  border: 1px solid rgba(255, 221, 184, .24);
  background:
    linear-gradient(180deg, rgba(255, 222, 190, .9), rgba(174, 113, 82, .72)),
    rgba(198, 142, 105, .8);
  box-shadow: 0 18px 28px rgba(0, 0, 0, .24);
}

.offer-hands span:first-child {
  left: 30px;
  border-radius: 38px 30px 44px 28px;
  transform: rotate(18deg);
}

.offer-hands span:last-child {
  right: 30px;
  border-radius: 30px 38px 28px 44px;
  transform: rotate(-18deg);
}

.offer-deck {
  position: relative;
  width: 112px;
  aspect-ratio: 2 / 3;
  margin-top: -24px;
}

.offer-deck span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 231, 174, .58);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .06), rgba(0, 0, 0, .08)),
    url("./assets/tarot/fate-vintage-oracle/deck-back.png");
  background-size: cover;
  background-position: center;
  box-shadow: 0 18px 36px rgba(0, 0, 0, .38);
}

.offer-deck span:nth-child(1) { transform: rotate(-10deg) translate(-18px, 8px); opacity: .48; }
.offer-deck span:nth-child(2) { transform: rotate(-5deg) translate(-9px, 4px); opacity: .62; }
.offer-deck span:nth-child(3) { transform: rotate(0deg); opacity: .98; }
.offer-deck span:nth-child(4) { transform: rotate(5deg) translate(9px, 4px); opacity: .62; }
.offer-deck span:nth-child(5) { transform: rotate(10deg) translate(18px, 8px); opacity: .48; }

.offer-caption {
  display: inline-grid;
  gap: 2px;
  min-width: 128px;
  padding: 8px 0 0;
}

.offer-caption strong {
  color: var(--accent-2);
  font-size: .84rem;
  font-weight: 950;
}

.offer-caption small {
  color: var(--muted);
  font-size: .7rem;
  font-weight: 850;
}

.card-spread {
  position: relative;
  z-index: 2;
  isolation: isolate;
  justify-self: center;
  width: min(680px, 100%);
  min-height: 560px;
  display: grid;
  grid-template-columns: repeat(7, minmax(64px, 1fr));
  grid-template-rows: repeat(3, 178px);
  gap: 10px;
  align-items: center;
}

.tarot-canvas.tarot-stage-ready .card-spread::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 48%;
  z-index: -1;
  width: min(640px, 94%);
  height: min(340px, 72%);
  border-radius: 50%;
  background:
    radial-gradient(ellipse at center, rgba(255, 229, 157, .22), rgba(255, 229, 157, .06) 42%, rgba(255, 229, 157, 0) 70%),
    conic-gradient(from 0deg, transparent 0 14%, rgba(255, 232, 178, .22) 16%, transparent 18% 48%, rgba(255, 232, 178, .18) 50%, transparent 53% 100%);
  opacity: 0;
  transform: translate(-50%, -50%) scale(.72) rotate(-8deg);
  filter: blur(.2px);
  pointer-events: none;
  animation: tarotTableAwake .96s cubic-bezier(.16, .78, .18, 1) both;
}

.tarot-canvas.is-receiving-card:not(.tarot-stage-ready) .card-spread::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 48%;
  z-index: -1;
  width: min(580px, 92%);
  height: min(300px, 68%);
  border-radius: 50%;
  background:
    radial-gradient(ellipse at center, rgba(255, 227, 151, .24), rgba(255, 227, 151, .07) 42%, rgba(255, 227, 151, 0) 72%);
  opacity: 0;
  transform: translate(-50%, -50%) scale(.64);
  pointer-events: none;
  animation: tarotTableReceivePulse .72s cubic-bezier(.16, .86, .2, 1) both;
}

.tarot-slot {
  --card-final-rotate: 0deg;
  --deal-x: 0px;
  --deal-y: 108px;
  --deal-r: 0deg;
  appearance: none;
  position: relative;
  isolation: isolate;
  min-height: 168px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  justify-items: center;
  gap: 3px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--soft);
  perspective: 900px;
  text-align: center;
  transition: opacity .65s ease;
}

.tarot-slot:disabled {
  cursor: default;
  opacity: 1;
}

.tarot-slot.is-filled {
  color: var(--text);
}

.tarot-slot.is-facedown {
  color: var(--soft);
}

.tarot-slot:not(.is-filled) {
  min-height: 88px;
  grid-template-rows: auto;
  align-content: center;
  color: color-mix(in srgb, var(--soft) 70%, transparent);
}

.tarot-slot.is-fresh-deal::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: -1;
  width: min(168px, 88%);
  aspect-ratio: 1.25 / 1;
  border-radius: 50%;
  background:
    radial-gradient(ellipse at center, rgba(255, 228, 157, .32), rgba(255, 228, 157, .09) 42%, rgba(255, 228, 157, 0) 72%);
  opacity: 0;
  transform: translate(-50%, -50%) scale(.52);
  animation: tarotDealLanding .7s cubic-bezier(.16, .86, .2, 1) both;
  animation-delay: calc(var(--slot-i, 0) * 42ms + 70ms);
  pointer-events: none;
}

.tarot-slot.is-fresh-reveal::after {
  display: none;
}

.tarot-card-image {
  position: relative;
  overflow: hidden;
  width: min(94px, 100%);
  aspect-ratio: 2 / 3;
  border: 1px solid color-mix(in srgb, var(--accent) 48%, white 30%);
  border-radius: 7px;
  background-color: rgba(0, 0, 0, .22);
  background-position: center;
  background-size: cover;
  box-shadow: 0 12px 28px rgba(0, 0, 0, .34), inset 0 0 0 1px rgba(255, 255, 255, .07);
  transform: rotate(var(--card-final-rotate));
  transform-origin: center;
  transform-style: preserve-3d;
  backface-visibility: hidden;
  will-change: transform, opacity, filter;
}

.tarot-card-image::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 238, 190, .28), rgba(255, 238, 190, 0) 42%),
    linear-gradient(145deg, rgba(255, 255, 255, .16), transparent 34% 68%, rgba(0, 0, 0, .1));
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
}

.tarot-card-image::after {
  content: "";
  position: absolute;
  inset: -14% -52%;
  background: linear-gradient(104deg, transparent 34%, rgba(255, 244, 204, .72) 49%, transparent 64%);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-72%) rotate(8deg);
}

.tarot-slot:not(.is-filled) .tarot-card-image {
  display: none;
}

.tarot-slot:not(.is-filled) .tarot-slot-caption strong,
.tarot-slot:not(.is-filled) .tarot-slot-caption small {
  display: none;
}

.tarot-slot.is-filled .tarot-card-image {
  width: min(132px, 100%);
  border-color: color-mix(in srgb, var(--accent) 62%, white 38%);
  box-shadow: 0 14px 30px rgba(0, 0, 0, .36);
}

.tarot-slot.is-filled.is-facedown:not(:disabled) {
  cursor: pointer;
}

.tarot-slot.is-filled.is-facedown:not(:disabled) .tarot-card-image {
  transition: transform .2s ease, filter .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.tarot-slot.is-filled.is-facedown:not(:disabled) .tarot-card-image::before {
  opacity: .26;
  animation: tarotRevealCue 2.4s ease-in-out infinite;
  animation-delay: calc(var(--slot-i, 0) * 130ms);
}

.tarot-slot.is-filled.is-facedown:not(:disabled):hover .tarot-card-image,
.tarot-slot.is-filled.is-facedown:not(:disabled):focus-visible .tarot-card-image {
  border-color: color-mix(in srgb, var(--accent) 74%, white 26%);
  box-shadow: 0 20px 34px rgba(0, 0, 0, .38), 0 0 24px rgba(255, 219, 143, .13);
  filter: brightness(1.08) saturate(1.04);
  transform: translateY(-6px) rotate(var(--card-final-rotate)) scale(1.025);
}

.tarot-slot.is-filled.is-facedown:not(:disabled):hover .tarot-card-image::before,
.tarot-slot.is-filled.is-facedown:not(:disabled):focus-visible .tarot-card-image::before {
  opacity: .92;
  animation: none;
}

.tarot-slot.is-filled.is-facedown:not(:disabled):active .tarot-card-image {
  transform: translateY(-10px) rotate(var(--card-final-rotate)) scale(1.04);
}

.tarot-slot.is-filled.is-facedown:not(:disabled):hover .tarot-slot-caption small,
.tarot-slot.is-filled.is-facedown:not(:disabled):focus-visible .tarot-slot-caption small {
  color: var(--accent-2);
}

.tarot-slot.is-fresh-deal.is-facedown .tarot-card-image {
  animation: tarotCardDeal .68s cubic-bezier(.16, .86, .2, 1.08) both;
  animation-delay: calc(var(--slot-i, 0) * 42ms);
}

.tarot-slot.is-fresh-deal.is-facedown .tarot-card-image::after {
  animation: tarotDealGlimmer .58s ease both;
  animation-delay: calc(var(--slot-i, 0) * 42ms + 80ms);
}

.tarot-slot.is-revealed .tarot-card-image {
  filter: saturate(1.06) brightness(1.04);
}

.tarot-slot.is-fresh-reveal .tarot-card-image {
  animation: tarotCardReveal 3.35s cubic-bezier(.2, .68, .12, 1) both;
  animation-delay: calc(var(--slot-i, 0) * 80ms);
  box-shadow: 0 22px 42px rgba(0, 0, 0, .42), 0 0 38px rgba(255, 226, 156, .24);
}

.tarot-slot.is-reversed.is-fresh-reveal .tarot-card-image {
  animation-name: tarotCardRevealReversed;
}

.tarot-slot.is-fresh-reveal .tarot-card-image::after {
  animation: none;
}

.tarot-slot.is-fresh-reveal .tarot-card-image::before {
  opacity: 1;
  z-index: 2;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .16), transparent 34% 68%, rgba(0, 0, 0, .16)),
    url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08);
  animation: tarotRevealBackCover 3.35s cubic-bezier(.2, .68, .12, 1) both;
  animation-delay: calc(var(--slot-i, 0) * 80ms);
}

.tarot-slot.is-filled.is-fresh-reveal .tarot-slot-caption {
  animation: tarotCaptionReveal 2.38s cubic-bezier(.16, .82, .18, 1) both;
  animation-delay: calc(var(--slot-i, 0) * 80ms + 650ms);
}

.tarot-canvas.is-reading-open .tarot-slot.is-revealed .tarot-card-image {
  box-shadow: 0 18px 36px rgba(0, 0, 0, .4), 0 0 24px rgba(255, 222, 149, .1);
}

.tarot-canvas.is-reading-open .tarot-slot.is-revealed .tarot-slot-caption strong {
  text-shadow: 0 0 16px rgba(255, 231, 174, .16);
}

.tarot-slot.is-reversed .tarot-card-image {
  --card-final-rotate: 180deg;
}

.service-stage.is-tarot-flight-landing .tarot-slot {
  opacity: 0;
  pointer-events: none;
}

.service-stage.is-tarot-flight-landing .tarot-slot,
.service-stage.is-tarot-flight-landing .tarot-slot::before,
.service-stage.is-tarot-flight-landing .tarot-slot::after,
.service-stage.is-tarot-flight-landing .tarot-card-image,
.service-stage.is-tarot-flight-landing .tarot-card-image::before,
.service-stage.is-tarot-flight-landing .tarot-card-image::after,
.service-stage.is-tarot-flight-landing .tarot-slot-caption {
  animation: none !important;
  transition: none !important;
}

.tarot-slot.is-filled .tarot-slot-caption {
  animation: tarotCaptionSettle .42s ease both;
  animation-delay: calc(var(--slot-i, 0) * 36ms + 80ms);
}

.tarot-slot-caption {
  width: min(132px, 100%);
  min-width: 0;
  max-width: 100%;
  display: grid;
  gap: 1px;
  justify-items: center;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.tarot-deck-surface {
  display: grid;
  gap: 10px;
}

.tarot-deck-surface.is-compact {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 8px 12px;
  padding-top: 2px;
  border-top: 1px solid rgba(255, 231, 174, .12);
}

.tarot-deck-surface .tarot-step-copy {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
}

.tarot-deck-surface.is-compact .tarot-step-copy {
  grid-template-columns: 1fr;
}

.tarot-deck-surface.is-compact .tarot-deck-actions {
  align-self: center;
}

.tarot-deck-surface.is-compact .tarot-deck-actions button:disabled {
  display: none;
}

.tarot-picked-strip {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-height: 48px;
}

.tarot-picked-strip > span {
  color: var(--muted);
  font-size: .68rem;
  font-weight: 950;
}

.tarot-picked-token {
  position: relative;
  width: 30px;
  height: 45px;
  display: block;
  transform: rotate(var(--picked-r, 0deg)) translateY(-1px);
  transform-origin: 50% 88%;
  filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .26));
  animation: tarotPickedTokenIn .42s cubic-bezier(.18, .84, .24, 1.08) both;
}

.tarot-picked-token span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 231, 174, .3);
  border-radius: 5px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .07);
}

.tarot-picked-token b {
  position: absolute;
  right: -5px;
  bottom: -5px;
  min-width: 20px;
  min-height: 20px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .4);
  border-radius: 999px;
  background: rgba(7, 6, 8, .82);
  color: var(--accent-2);
  font-size: .58rem;
  font-weight: 950;
  line-height: 1;
}

.tarot-arc-shell {
  position: relative;
  min-height: clamp(380px, 52vh, 520px);
  overflow: hidden;
  isolation: isolate;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.tarot-arc-shell::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -54px;
  z-index: 0;
  width: min(760px, 126%);
  height: 156px;
  border: 1px solid rgba(255, 231, 174, .13);
  border-bottom-color: rgba(255, 231, 174, .28);
  border-radius: 0 0 50% 50%;
  opacity: .62;
  pointer-events: none;
  transform: translateX(-50%);
  filter: drop-shadow(0 10px 18px rgba(255, 205, 111, .08));
}

.tarot-arc-shell::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 24px;
  z-index: 0;
  width: min(360px, 76%);
  height: 28px;
  border-radius: 999px;
  background: radial-gradient(ellipse at center, rgba(255, 224, 154, .22), rgba(255, 224, 154, 0) 68%);
  opacity: .8;
  pointer-events: none;
  transform: translateX(-50%);
}

.tarot-arc-shell.is-grabbing {
  cursor: grabbing;
}

.tarot-arc-shell.is-grabbing .tarot-back-card {
  transition-duration: .04s;
}

.tarot-arc-shell.is-snapping .tarot-back-card {
  transition-timing-function: cubic-bezier(.16, .82, .22, 1);
  transition-duration: .52s;
}

.tarot-arc-shell.is-snapping .tarot-arc-stage::after {
  width: 96px;
  opacity: 1;
  box-shadow: 0 0 24px rgba(255, 214, 133, .46);
}

.tarot-arc-shell.has-picked .tarot-back-card:not(.is-picked):not(.is-centered) .tarot-back-face {
  filter: brightness(.88) saturate(.94);
}

.tarot-back-grid {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 16px;
  overscroll-behavior-x: contain;
  pointer-events: none;
  scrollbar-width: none;
}

.tarot-arc-spacer {
  height: 100%;
}

.tarot-arc-stage {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.tarot-arc-stage::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 16px;
  z-index: 0;
  width: min(300px, 74%);
  height: 150px;
  border-radius: 0 0 50% 50%;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255, 229, 159, .28), rgba(255, 229, 159, 0) 58%),
    linear-gradient(90deg, transparent 0 46%, rgba(255, 231, 174, .2) 50%, transparent 54% 100%);
  opacity: .72;
  pointer-events: none;
  transform: translateX(-50%);
}

.tarot-arc-stage::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 34px;
  z-index: 0;
  width: 74px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(255, 231, 174, .8), transparent);
  box-shadow: 0 0 18px rgba(255, 214, 133, .34);
  opacity: .82;
  pointer-events: none;
  transform: translateX(-50%);
}

.tarot-draw-gate {
  position: absolute;
  left: 50%;
  bottom: 2px;
  z-index: 1102;
  width: min(154px, 44vw);
  height: 136px;
  opacity: .88;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity .18s ease, transform .18s ease;
}

.tarot-draw-gate::before {
  content: "";
  position: absolute;
  inset: 11px 18px 29px;
  border-top: 1px solid rgba(255, 232, 178, .74);
  border-right: 1px solid rgba(255, 232, 178, .24);
  border-left: 1px solid rgba(255, 232, 178, .24);
  border-radius: 999px 999px 0 0;
  background: radial-gradient(ellipse at 50% 100%, rgba(255, 221, 139, .18), rgba(255, 221, 139, 0) 66%);
  box-shadow: 0 -12px 30px rgba(255, 215, 126, .13);
  animation: tarotDrawGatePulse 1.7s ease-in-out infinite;
}

.tarot-draw-gate::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 22px;
  width: 2px;
  height: 64px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 241, 202, 0), rgba(255, 241, 202, .82), rgba(255, 241, 202, 0));
  opacity: .78;
  transform: translateX(-50%);
}

.tarot-draw-gate i {
  position: absolute;
  left: 50%;
  bottom: 18px;
  width: 9px;
  height: 9px;
  border: 1px solid rgba(255, 236, 188, .84);
  border-left: 0;
  border-top: 0;
  box-shadow: 0 0 16px rgba(255, 218, 132, .42);
  transform: translateX(-50%) rotate(45deg);
  animation: tarotDrawGateNeedle 1.7s ease-in-out infinite;
}

.tarot-arc-shell.is-grabbing .tarot-draw-gate {
  opacity: .36;
  transform: translateX(-50%) scale(.96);
}

.tarot-back-grid::-webkit-scrollbar {
  display: none;
}

.tarot-back-grid::-webkit-scrollbar-track {
  background: transparent;
}

.tarot-back-grid::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(255, 231, 174, .28);
}

.tarot-back-card {
  position: absolute;
  left: var(--arc-x, 50%);
  top: var(--arc-y, 50%);
  z-index: var(--arc-z, 1);
  width: clamp(132px, 13vw, 184px);
  aspect-ratio: 2 / 3;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255, 231, 174, .12);
  border-radius: 7px;
  background: transparent;
  cursor: pointer;
  opacity: var(--arc-opacity, 0);
  pointer-events: auto;
  transform: translate(-50%, -50%) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  transform-origin: 50% -28%;
  box-shadow: 0 18px 26px rgba(0, 0, 0, calc(.1 + var(--arc-focus, 0) * .18));
  transition: transform .18s ease, border-color .18s ease, filter .18s ease, opacity .18s ease, box-shadow .18s ease;
  will-change: transform;
}

.tarot-back-card::before {
  content: "";
  position: absolute;
  inset: -6px;
  border: 1px solid rgba(255, 231, 174, .3);
  border-radius: 12px;
  opacity: calc(var(--arc-focus, 0) * .72);
  pointer-events: none;
  transform: scale(1.02);
}

.tarot-back-card.is-centered:not(.is-picked) {
  border-color: color-mix(in srgb, var(--accent) 58%, white 42%);
  box-shadow: 0 24px 34px rgba(0, 0, 0, .3), 0 0 26px rgba(255, 214, 133, .16);
  filter: brightness(1.08) saturate(1.04);
  z-index: 1140;
}

.tarot-back-card.is-centered:not(.is-picked)::before {
  border-color: rgba(255, 232, 178, .58);
  opacity: .86;
}

.tarot-back-card.is-centered:not(.is-picked)::after {
  content: "";
  position: absolute;
  inset: -12px;
  z-index: -1;
  border-radius: 15px;
  background: radial-gradient(circle at 50% 44%, rgba(255, 226, 154, .28), rgba(255, 226, 154, 0) 66%);
  opacity: .62;
  pointer-events: none;
  animation: tarotCenterCardHalo 1.7s ease-in-out infinite;
}

.tarot-canvas.tarot-stage-draw.is-waiting .tarot-back-card {
  animation: none;
}

.tarot-back-card:not(:disabled):hover {
  border-color: color-mix(in srgb, var(--accent) 62%, white 38%);
  box-shadow: 0 24px 34px rgba(0, 0, 0, .34), 0 0 28px rgba(255, 214, 133, .14);
  filter: brightness(1.1) saturate(1.04);
  transform: translate(-50%, calc(-50% - var(--arc-hover-lift, 18px))) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  z-index: 1120;
}

.tarot-back-card:not(:disabled):active {
  transform: translate(-50%, calc(-50% - var(--arc-active-lift, 28px))) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
}

.tarot-back-card:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 70%, white 30%);
  outline-offset: 4px;
}

.tarot-back-card:disabled:not(.is-picked) {
  opacity: .38;
  cursor: default;
}

.tarot-back-card.is-picked {
  border-color: color-mix(in srgb, var(--accent) 70%, white 30%);
  box-shadow: 0 34px 44px rgba(0, 0, 0, .44), 0 0 42px rgba(255, 214, 133, .26);
  filter: brightness(1.2) saturate(1.08);
  transform: translate(-50%, calc(-50% - var(--arc-picked-lift, 24px))) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  z-index: 1160;
  animation: tarotPickRise .42s cubic-bezier(.2, .9, .22, 1.12);
}

.tarot-back-card.is-picked:not(:disabled):hover {
  transform: translate(-50%, calc(-50% - calc(var(--arc-picked-lift, 24px) + 12px))) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
}

.tarot-back-card.is-picked::after {
  content: "";
  position: absolute;
  inset: -12px;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 14px;
  background: radial-gradient(circle at 50% 12%, rgba(255, 230, 166, .42), rgba(255, 230, 166, 0) 64%);
  opacity: .84;
  pointer-events: none;
  z-index: -1;
}

.tarot-back-card.is-picked .tarot-back-face {
  animation: tarotDeckPickFlash .46s ease both;
  filter: brightness(1.1) saturate(1.05);
  transform: scale(1.018);
}

.tarot-back-face {
  position: absolute;
  inset: 3px;
  border-radius: 5px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  transition: filter .18s ease, transform .18s ease;
}

.tarot-back-card.is-centered:not(.is-picked) .tarot-back-face {
  filter: brightness(1.06) saturate(1.04);
  transform: scale(1.018);
  animation: tarotCenterCardBreathe 1.7s ease-in-out infinite;
}

.tarot-back-card strong {
  position: relative;
  z-index: 1;
  min-width: 24px;
  min-height: 24px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 999px;
  background: rgba(7, 6, 8, .76);
  color: var(--accent-2);
  font-size: .72rem;
  font-weight: 950;
}

.tarot-deal-flight {
  position: fixed;
  z-index: 80;
  display: block;
  border: 0;
  border-radius: 7px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  overflow: hidden;
  box-shadow: 0 26px 42px rgba(0, 0, 0, .42), 0 0 36px rgba(255, 222, 149, .2);
  pointer-events: none;
  transform-origin: center;
  animation: tarotDealFlight .78s cubic-bezier(.16, .86, .16, 1) both;
  animation-delay: var(--flight-delay, 0ms);
  will-change: transform, opacity, filter;
}

.tarot-deal-flight::before {
  content: "";
  position: absolute;
  inset: -10px;
  z-index: -1;
  border-radius: 13px;
  background: radial-gradient(circle at 50% 36%, rgba(255, 231, 174, .38), rgba(255, 231, 174, 0) 68%);
  opacity: 0;
  animation: tarotDealFlightAura .78s ease both;
  animation-delay: var(--flight-delay, 0ms);
}

.tarot-deal-flight::after {
  content: "";
  position: absolute;
  inset: -12% -58%;
  background: linear-gradient(104deg, transparent 34%, rgba(255, 246, 213, .78) 49%, transparent 64%);
  opacity: 0;
  transform: translateX(-70%) rotate(8deg);
  animation: tarotDealFlightSheen .5s ease both;
  animation-delay: calc(var(--flight-delay, 0ms) + 120ms);
}

@keyframes tarotArcBloom {
  0% {
    opacity: 0;
    transform: translate(-50%, 20px) rotate(calc(var(--arc-angle, 0deg) - 8deg)) scale(.72);
    filter: blur(2px) brightness(.8);
  }
  64% {
    opacity: var(--arc-opacity, 1);
    transform: translate(-50%, calc(-50% - 6px)) rotate(var(--arc-angle, 0deg)) scale(var(--arc-bloom-scale, 1.025));
    filter: blur(0) brightness(1.08);
  }
  100% {
    opacity: var(--arc-opacity, 1);
    transform: translate(-50%, -50%) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
    filter: blur(0) brightness(1);
  }
}

@keyframes tarotShuffleWeave {
  0% {
    opacity: 0;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-start-x), var(--shuffle-start-y))
      rotate(var(--shuffle-start-r))
      rotateX(0deg)
      scale(.88);
    filter: blur(2.4px) brightness(.78);
  }
  10% {
    opacity: .96;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-start-x), var(--shuffle-start-y))
      rotate(var(--shuffle-start-r))
      rotateX(0deg)
      scale(.99);
    filter: blur(.4px) brightness(1.03);
  }
  24% {
    opacity: 1;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-riffle-x), var(--shuffle-riffle-y))
      rotate(var(--shuffle-riffle-r))
      rotateX(7deg)
      scale(1.035);
    filter: blur(0) brightness(1.1);
  }
  39% {
    opacity: 1;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-bridge-x), var(--shuffle-bridge-y))
      rotate(var(--shuffle-bridge-r))
      rotateX(18deg)
      scale(1.045);
    filter: blur(0) brightness(1.15);
  }
  55% {
    opacity: .98;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-end-x), var(--shuffle-lift-y))
      rotate(var(--shuffle-counter-r))
      rotateX(-8deg)
      scale(1.03);
    filter: blur(0) brightness(1.08);
  }
  72% {
    opacity: .98;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-settle-x), var(--shuffle-settle-y))
      rotate(var(--shuffle-settle-r))
      rotateX(0deg)
      scale(.985);
    filter: blur(0) brightness(.98);
  }
  86% {
    opacity: .99;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-overshoot-x), var(--shuffle-overshoot-y))
      rotate(var(--shuffle-overshoot-r))
      rotateX(0deg)
      scale(1.015);
    filter: blur(0) brightness(1.05);
  }
  100% {
    opacity: .96;
    transform:
      translate(-50%, -50%)
      translate(var(--shuffle-end-x), var(--shuffle-end-y))
      rotate(var(--shuffle-end-r))
      rotateX(0deg)
      scale(1);
    filter: blur(0) brightness(1);
  }
}

@keyframes tarotShuffleShadow {
  0% {
    opacity: .18;
    transform: translate(-50%, -50%) scale(.58);
  }
  24% {
    opacity: .38;
    transform: translate(-50%, -50%) scale(1.04);
  }
  42% {
    opacity: .56;
    transform: translate(-50%, -50%) scale(.88);
  }
  70% {
    opacity: .42;
    transform: translate(-50%, -50%) scale(.72);
  }
  100% {
    opacity: .5;
    transform: translate(-50%, -50%) scale(.78);
  }
}

@keyframes tarotCutPileIn {
  0% {
    opacity: 0;
    transform: translateY(18px) rotate(-2deg) scale(.92);
    filter: blur(2px) brightness(.84);
  }
  70% {
    opacity: 1;
    transform: translateY(-5px) rotate(1deg) scale(1.025);
    filter: blur(0) brightness(1.08);
  }
  100% {
    opacity: 1;
    transform: translateY(0) rotate(0deg) scale(1);
    filter: blur(0) brightness(1);
  }
}

@keyframes tarotCutCardFanLeft {
  0% {
    transform: rotate(0deg) translate(0, 0);
  }
  100% {
    transform: rotate(-8deg) translate(-8px, 5px);
  }
}

@keyframes tarotCutCardFanRight {
  0% {
    transform: rotate(0deg) translate(0, 0);
  }
  100% {
    transform: rotate(5deg) translate(7px, 3px);
  }
}

@keyframes tarotCutRecombine {
  0% {
    opacity: 0;
    transform:
      translate(-50%, -50%)
      translate(var(--recombine-from-x, 0), var(--recombine-from-y, 0))
      rotate(var(--recombine-from-r, 0deg))
      scale(.92);
    filter: blur(2px) brightness(.82);
  }
  50% {
    opacity: 1;
    transform:
      translate(-50%, -50%)
      translate(var(--recombine-mid-x), -14px)
      rotate(var(--recombine-mid-r))
      scale(1.04);
    filter: blur(0) brightness(1.12);
  }
  100% {
    opacity: 1;
    transform:
      translate(-50%, -50%)
      translate(var(--recombine-end-x), 0)
      rotate(var(--recombine-end-r))
      scale(1);
    filter: blur(0) brightness(1);
  }
}

@keyframes tarotCardDeal {
  0% {
    opacity: 0;
    transform:
      translate3d(var(--deal-x, 0px), var(--deal-y, 108px), 0)
      rotate(calc(var(--card-final-rotate) + var(--deal-r, 0deg)))
      scale(.58);
    filter: blur(3px) brightness(.72) saturate(.86);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .18);
  }
  44% {
    opacity: 1;
    transform:
      translate3d(0, -14px, 0)
      rotate(var(--card-final-rotate))
      scale(1.075);
    filter: blur(0) brightness(1.16) saturate(1.08);
    box-shadow: 0 24px 38px rgba(0, 0, 0, .42), 0 0 26px rgba(255, 218, 139, .18);
  }
  72% {
    transform:
      translate3d(0, 5px, 0)
      rotate(var(--card-final-rotate))
      scale(.985);
    filter: blur(0) brightness(1.02) saturate(1);
  }
  100% {
    opacity: 1;
    transform:
      translate3d(0, 0, 0)
      rotate(var(--card-final-rotate))
      scale(1);
    filter: blur(0) brightness(1);
  }
}

@keyframes tarotDealFlight {
  0% {
    opacity: 0;
    transform:
      translate3d(0, 0, 0)
      rotate(var(--flight-start-r, -8deg))
      scale(.94);
    filter: blur(1.8px) brightness(.86) saturate(.9);
  }
  10% {
    opacity: 1;
  }
  48% {
    opacity: 1;
    transform:
      translate3d(var(--flight-mid-x, 0px), var(--flight-mid-y, -54px), 0)
      rotate(var(--flight-mid-r, 4deg))
      scale(1.12);
    filter: blur(0) brightness(1.2) saturate(1.08);
  }
  78% {
    opacity: .98;
    transform:
      translate3d(var(--flight-x, 0px), calc(var(--flight-y, 0px) - 7px), 0)
      rotate(var(--flight-end-r, 0deg))
      scale(var(--flight-pop-scale, 1.04));
    filter: blur(0) brightness(1.08) saturate(1.04);
  }
  100% {
    opacity: 0;
    transform:
      translate3d(var(--flight-x, 0px), var(--flight-y, 0px), 0)
      rotate(var(--flight-end-r, 0deg))
      scale(var(--flight-end-scale, 1));
    filter: blur(.8px) brightness(1.04) saturate(1);
  }
}

@keyframes tarotDealFlightAura {
  0% {
    opacity: 0;
    transform: scale(.68);
  }
  46% {
    opacity: .86;
    transform: scale(1.14);
  }
  100% {
    opacity: 0;
    transform: scale(1.42);
  }
}

@keyframes tarotDealFlightSheen {
  0% {
    opacity: 0;
    transform: translateX(-72%) rotate(8deg);
  }
  45% {
    opacity: .78;
  }
  100% {
    opacity: 0;
    transform: translateX(72%) rotate(8deg);
  }
}

@keyframes tarotDealLanding {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(.52);
    filter: blur(3px);
  }
  36% {
    opacity: .9;
    transform: translate(-50%, -50%) scale(1.08);
    filter: blur(0);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.34);
    filter: blur(2px);
  }
}

@keyframes tarotTableReceivePulse {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(.64);
    filter: blur(8px);
  }
  38% {
    opacity: .86;
    transform: translate(-50%, -50%) scale(1.03);
    filter: blur(1px);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.28);
    filter: blur(6px);
  }
}

@keyframes tarotDealGlimmer {
  0% {
    opacity: 0;
    transform: translateX(-78%) rotate(8deg);
  }
  42% {
    opacity: .8;
  }
  100% {
    opacity: 0;
    transform: translateX(76%) rotate(8deg);
  }
}

@keyframes tarotCardReveal {
  0% {
    opacity: 1;
    transform: rotateY(0deg) rotate(var(--card-final-rotate)) scale(1);
    filter: brightness(.92) saturate(.94);
  }
  42% {
    opacity: 1;
    transform: rotateY(-82deg) rotate(var(--card-final-rotate)) scale(.99);
    filter: brightness(.82) saturate(.9);
  }
  50% {
    opacity: 1;
    transform: rotateY(-90deg) rotate(var(--card-final-rotate)) scale(.985);
    filter: brightness(.78) saturate(.88);
  }
  64% {
    opacity: 1;
    transform: rotateY(-58deg) rotate(var(--card-final-rotate)) scale(.99);
    filter: brightness(1) saturate(1.02);
  }
  84% {
    transform: rotateY(-14deg) rotate(var(--card-final-rotate)) scale(1.004);
    filter: brightness(1.05) saturate(1.05);
  }
  100% {
    opacity: 1;
    transform: rotateY(0deg) rotate(var(--card-final-rotate)) scale(1);
    filter: brightness(1.04) saturate(1.06);
  }
}

@keyframes tarotCardRevealReversed {
  0% {
    opacity: 1;
    transform: rotateY(0deg) rotate(0deg) scale(1);
    filter: brightness(.92) saturate(.94);
  }
  42% {
    opacity: 1;
    transform: rotateY(-82deg) rotate(0deg) scale(.99);
    filter: brightness(.82) saturate(.9);
  }
  50% {
    opacity: 1;
    transform: rotateY(-90deg) rotate(0deg) scale(.985);
    filter: brightness(.78) saturate(.88);
  }
  64% {
    opacity: 1;
    transform: rotateY(-58deg) rotate(70deg) scale(.99);
    filter: brightness(1) saturate(1.02);
  }
  84% {
    transform: rotateY(-14deg) rotate(156deg) scale(1.004);
    filter: brightness(1.05) saturate(1.05);
  }
  100% {
    opacity: 1;
    transform: rotateY(0deg) rotate(180deg) scale(1);
    filter: brightness(1.04) saturate(1.06);
  }
}

@keyframes tarotRevealBackCover {
  0% {
    opacity: 1;
    filter: brightness(1.02) saturate(.98);
  }
  48% {
    opacity: 1;
    filter: brightness(.96) saturate(.96);
  }
  52% {
    opacity: 0;
    filter: brightness(1) saturate(1);
  }
  100% {
    opacity: 0;
    filter: brightness(1) saturate(1);
  }
}

@keyframes tarotCardGlimmer {
  0% {
    opacity: 0;
    transform: translateX(-72%) rotate(8deg);
  }
  34% {
    opacity: .72;
  }
  100% {
    opacity: 0;
    transform: translateX(72%) rotate(8deg);
  }
}

@keyframes tarotRevealBloom {
  0% {
    opacity: 0;
    transform: scale(.96);
  }
  36% {
    opacity: .88;
    transform: scale(1.02);
  }
  100% {
    opacity: 0;
    transform: scale(1.08);
  }
}

@keyframes tarotRevealSweep {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(.62) rotate(-20deg);
    filter: blur(7px);
  }
  34% {
    opacity: .92;
    transform: translate(-50%, -50%) scale(1.02) rotate(8deg);
    filter: blur(.2px);
  }
  68% {
    opacity: .62;
    transform: translate(-50%, -50%) scale(1.14) rotate(20deg);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.34) rotate(32deg);
    filter: blur(6px);
  }
}

@keyframes tarotCaptionReveal {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(.94);
    filter: blur(3px);
  }
  54% {
    opacity: 1;
    transform: translateY(-2px) scale(1.035);
    filter: blur(0);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes tarotRevealAura {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(.6) rotate(-18deg);
    filter: blur(5px);
  }
  34% {
    opacity: .85;
    transform: translate(-50%, -50%) scale(1.02) rotate(0deg);
    filter: blur(0);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.35) rotate(16deg);
    filter: blur(6px);
  }
}

@keyframes tarotTableAwake {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(.72) rotate(-8deg);
    filter: blur(10px);
  }
  28% {
    opacity: .88;
    transform: translate(-50%, -50%) scale(1.04) rotate(0deg);
    filter: blur(1px);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.26) rotate(10deg);
    filter: blur(10px);
  }
}

@keyframes tarotProgressPulse {
  0%,
  100% {
    filter: brightness(1);
    transform: scale(1);
  }
  50% {
    filter: brightness(1.2);
    transform: scale(1.12);
  }
}

@keyframes tarotConstellationAwake {
  0% {
    opacity: 0;
    transform: scale(.9) rotate(-4deg);
    filter: blur(6px);
  }
  42% {
    opacity: .86;
    transform: scale(1.035) rotate(1deg);
    filter: blur(.3px);
  }
  100% {
    opacity: .72;
    transform: scale(1) rotate(0deg);
    filter: blur(.2px);
  }
}

@keyframes tarotRevealCue {
  0%,
  100% {
    opacity: .18;
  }
  50% {
    opacity: .42;
  }
}

@keyframes tarotCaptionSettle {
  0% {
    opacity: 0;
    transform: translateY(6px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes tarotPickedTokenIn {
  0% {
    opacity: 0;
    transform: rotate(var(--picked-r, 0deg)) translateY(9px) scale(.82);
  }
  62% {
    opacity: 1;
    transform: rotate(var(--picked-r, 0deg)) translateY(-4px) scale(1.06);
  }
  100% {
    opacity: 1;
    transform: rotate(var(--picked-r, 0deg)) translateY(-1px) scale(1);
  }
}

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

@keyframes readingAuraIn {
  0% {
    opacity: 0;
    transform: scaleX(.68);
  }
  100% {
    opacity: 1;
    transform: scaleX(1);
  }
}

@keyframes readingResultSweep {
  0% {
    opacity: 0;
    transform: translateX(-42%) skewX(-8deg);
    filter: blur(5px);
  }
  32% {
    opacity: .88;
    filter: blur(.3px);
  }
  100% {
    opacity: 0;
    transform: translateX(42%) skewX(-8deg);
    filter: blur(5px);
  }
}

@keyframes readingResultAura {
  0% {
    opacity: 0;
    transform: translateX(-50%) scale(.74);
    filter: blur(10px);
  }
  42% {
    opacity: .92;
    transform: translateX(-50%) scale(1.06);
    filter: blur(2px);
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) scale(1.28);
    filter: blur(12px);
  }
}

@keyframes readingFinalIn {
  0% {
    opacity: 0;
    transform: translateY(14px);
    filter: blur(3px) brightness(.82);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0) brightness(1);
  }
}

@keyframes readingTextRise {
  0% {
    opacity: 0;
    transform: translateY(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes readingTokenIn {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(.94);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes readingCardThumbSheen {
  0% {
    opacity: .18;
    transform: translateX(-18%);
    filter: brightness(.9);
  }
  36% {
    opacity: .92;
    filter: brightness(1.28);
  }
  100% {
    opacity: .72;
    transform: translateX(0);
    filter: brightness(1);
  }
}

@keyframes readingCardResultIn {
  0% {
    opacity: 0;
    transform: translateY(14px) scale(.92);
    filter: blur(3px) brightness(.78);
  }
  58% {
    opacity: 1;
    transform: translateY(-3px) scale(1.035);
    filter: blur(0) brightness(1.12);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0) brightness(1);
  }
}

@keyframes readingRitualPulse {
  0%,
  100% {
    opacity: .76;
    transform: scale(.88);
  }
  50% {
    opacity: 1;
    transform: scale(1.08);
  }
}

@keyframes readingRitualGate {
  0%,
  100% {
    opacity: .44;
    transform: scale(.88) rotate(-8deg);
    filter: blur(.4px);
  }
  50% {
    opacity: .9;
    transform: scale(1.04) rotate(8deg);
    filter: blur(0);
  }
}

@keyframes readingRitualCardDraw {
  0%,
  100% {
    transform:
      rotate(var(--ritual-angle, 0deg))
      translateY(-82px)
      rotate(var(--ritual-counter-angle, 0deg))
      translate(-50%, -50%)
      scale(.98);
    filter: brightness(.96) saturate(1);
  }
  50% {
    transform:
      rotate(var(--ritual-angle, 0deg))
      translateY(-68px)
      rotate(var(--ritual-counter-angle, 0deg))
      translate(-50%, -50%)
      scale(1.06);
    filter: brightness(1.2) saturate(1.08);
  }
}

@keyframes readingRitualCardOrbitUpright {
  0% {
    transform:
      rotate(var(--ritual-angle, 0deg))
      translateY(-82px)
      rotate(var(--ritual-counter-angle, 0deg))
      translate(-50%, -50%);
    filter: brightness(.98) saturate(1);
  }
  50% {
    transform:
      rotate(calc(var(--ritual-angle, 0deg) + 180deg))
      translateY(-82px)
      rotate(calc(var(--ritual-counter-angle, 0deg) - 180deg))
      translate(-50%, -50%);
    filter: brightness(1.1) saturate(1.04);
  }
  100% {
    transform:
      rotate(calc(var(--ritual-angle, 0deg) + 360deg))
      translateY(-82px)
      rotate(calc(var(--ritual-counter-angle, 0deg) - 360deg))
      translate(-50%, -50%);
    filter: brightness(.98) saturate(1);
  }
}

@keyframes readingRitualCardSheen {
  0%,
  28% {
    opacity: 0;
    transform: translateX(-72%) rotate(8deg);
  }
  48% {
    opacity: .78;
  }
  70%,
  100% {
    opacity: 0;
    transform: translateX(72%) rotate(8deg);
  }
}

@keyframes readingRitualCoreRing {
  0%,
  100% {
    transform: scale(.82) rotate(-10deg);
    opacity: .28;
  }
  50% {
    transform: scale(1.12) rotate(10deg);
    opacity: .84;
  }
}

@keyframes readingRitualStep {
  0%,
  100% {
    color: var(--muted);
  }
  50% {
    color: var(--accent-2);
  }
}

@keyframes saveButtonPulse {
  0%,
  100% {
    filter: brightness(1);
  }
  50% {
    filter: brightness(1.12);
  }
}

@keyframes savedSealPulse {
  0% {
    opacity: 0;
    transform: scale(.94);
  }
  32% {
    opacity: .88;
    transform: scale(1.05);
  }
  100% {
    opacity: 0;
    transform: scale(1.16);
  }
}

@keyframes savedItemArchiveGlow {
  0% {
    opacity: 0;
    transform: translateX(-10px);
    filter: blur(5px);
  }
  38% {
    opacity: 1;
    transform: translateX(0);
    filter: blur(.3px);
  }
  100% {
    opacity: .36;
    transform: translateX(0);
    filter: blur(0);
  }
}

@keyframes savedMiniCardFresh {
  0% {
    opacity: 0;
    transform: translateY(12px) rotate(calc(var(--saved-r, 0deg) - 5deg)) scale(.82);
    filter: blur(2px) brightness(.8);
  }
  58% {
    opacity: 1;
    transform: translateY(-6px) rotate(var(--saved-r, 0deg)) scale(1.08);
    filter: blur(0) brightness(1.18);
  }
  100% {
    opacity: 1;
    transform: translateY(calc((var(--saved-i, 0) % 2) * -3px)) rotate(var(--saved-r, 0deg)) scale(1);
    filter: blur(0) brightness(1);
  }
}

@keyframes savedSealSettle {
  0% {
    opacity: 0;
    transform: translateY(6px) scale(.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes tarotPickRise {
  0% {
    transform: translate(-50%, -50%) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  }
  58% {
    transform: translate(-50%, calc(-50% - var(--arc-picked-pop-lift, 46px))) rotate(var(--arc-angle, 0deg)) scale(var(--arc-pick-scale, 1.08));
  }
  100% {
    transform: translate(-50%, calc(-50% - var(--arc-picked-lift, 24px))) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  }
}

@keyframes tarotDeckPickFlash {
  0% {
    filter: brightness(1) saturate(1);
    transform: scale(1);
  }
  40% {
    filter: brightness(1.28) saturate(1.08);
    transform: scale(1.035);
  }
  100% {
    filter: brightness(1.08) saturate(1.04);
    transform: scale(1.012);
  }
}

@keyframes tarotDrawGatePulse {
  0%,
  100% {
    opacity: .56;
    transform: scaleX(.94);
  }
  50% {
    opacity: 1;
    transform: scaleX(1.05);
  }
}

@keyframes tarotDrawGateNeedle {
  0%,
  100% {
    opacity: .58;
    transform: translateX(-50%) translateY(0) rotate(45deg);
  }
  50% {
    opacity: 1;
    transform: translateX(-50%) translateY(-5px) rotate(45deg);
  }
}

@keyframes tarotCenterCardHalo {
  0%,
  100% {
    opacity: .44;
    transform: scale(.96);
  }
  50% {
    opacity: .78;
    transform: scale(1.04);
  }
}

@keyframes tarotCenterCardBreathe {
  0%,
  100% {
    filter: brightness(1.04) saturate(1.03);
    transform: scale(1.01);
  }
  50% {
    filter: brightness(1.12) saturate(1.06);
    transform: scale(1.035);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tarot-shuffle-card,
  .tarot-recombine-pile,
  .tarot-draw-gate::before,
  .tarot-draw-gate i,
  .tarot-back-card.is-centered:not(.is-picked)::after,
  .tarot-back-card.is-centered:not(.is-picked) .tarot-back-face,
  .tarot-canvas.tarot-stage-draw.is-waiting .tarot-back-card,
  .tarot-back-card.is-picked,
  .tarot-back-card.is-picked .tarot-back-face,
  .tarot-canvas.is-revealing-card::before,
  .tarot-progress-step.is-active i,
  .tarot-canvas.tarot-stage-cut .tarot-cut-pile,
  .tarot-canvas.tarot-stage-cut .cut-stack span,
  .tarot-canvas.tarot-stage-ready .card-spread::before,
  .tarot-canvas.is-receiving-card:not(.tarot-stage-ready) .card-spread::before,
  .tarot-canvas.is-reading-open .card-spread.is-spread-7::after,
  .tarot-slot.is-revealed .tarot-card-image::after,
  .tarot-slot.is-filled.is-facedown:not(:disabled) .tarot-card-image::before,
  .tarot-slot.is-fresh-deal::before,
  .tarot-slot.is-fresh-deal.is-facedown .tarot-card-image::after,
  .tarot-slot.is-fresh-reveal::after,
  .tarot-slot.is-fresh-reveal .tarot-card-image::before,
  .tarot-slot.is-filled.is-fresh-reveal .tarot-slot-caption,
  .tarot-slot.is-fresh-deal.is-facedown .tarot-card-image,
  .tarot-slot.is-revealed .tarot-card-image,
  .tarot-slot.is-filled .tarot-slot-caption,
  .tarot-picked-token,
  .reading-ritual,
  .reading-ritual-orbit,
  .reading-ritual-orbit::before,
  .reading-ritual-card,
  .reading-ritual-card::after,
  .reading-ritual-core::before,
  .reading-ritual-core::after,
  .reading-ritual-core span,
  .reading-ritual-steps span,
  .reading-final,
  body[data-service="tarot"] .reading-copy.is-new-reading::after,
  body[data-service="tarot"] .reading-copy.is-new-reading .reading-final::before,
  body[data-service="tarot"] .reading-copy.is-new-reading .reading-result-seal span,
  .reading-final h3,
  .reading-final .reading-meta,
  .reading-final .reading-paragraphs p,
  .reading-card-token,
  body[data-service="tarot"] .reading-copy.is-new-reading .reading-card-thumb::before,
  body[data-service="tarot"] .reading-card-token,
  #makeReadingButton.is-loading::after,
  #saveReadingButton.is-saved::after,
  .topbar-link.has-new-saved::after,
  .saved-item.is-fresh-saved::before,
  .saved-item.is-fresh-saved .saved-mini-card,
  .reading-status,
  .saved-mini-card,
  #saveReadingButton.is-saving {
    animation: none;
  }

  .tarot-back-card,
  .tarot-card-image,
  .tarot-cut-pile {
    transition-duration: .01ms;
  }
}

.tarot-slot:nth-child(1) { grid-column: 4; grid-row: 2; }
.tarot-slot:nth-child(2) { grid-column: 3; grid-row: 1; transform: rotate(-6deg); }
.tarot-slot:nth-child(3) { grid-column: 5; grid-row: 1; transform: rotate(6deg); }
.tarot-slot:nth-child(4) { grid-column: 2; grid-row: 2; transform: rotate(-9deg); }
.tarot-slot:nth-child(5) { grid-column: 6; grid-row: 2; transform: rotate(9deg); }
.tarot-slot:nth-child(6) { grid-column: 3; grid-row: 3; transform: rotate(5deg); }
.tarot-slot:nth-child(7) { grid-column: 5; grid-row: 3; transform: rotate(-5deg); }

.tarot-slot:nth-child(1) { --deal-x: 0px; --deal-y: 126px; --deal-r: -2deg; }
.tarot-slot:nth-child(2) { --deal-x: 64px; --deal-y: 118px; --deal-r: -10deg; }
.tarot-slot:nth-child(3) { --deal-x: -64px; --deal-y: 118px; --deal-r: 10deg; }
.tarot-slot:nth-child(4) { --deal-x: 118px; --deal-y: 86px; --deal-r: -14deg; }
.tarot-slot:nth-child(5) { --deal-x: -118px; --deal-y: 86px; --deal-r: 14deg; }
.tarot-slot:nth-child(6) { --deal-x: 76px; --deal-y: 132px; --deal-r: 8deg; }
.tarot-slot:nth-child(7) { --deal-x: -76px; --deal-y: 132px; --deal-r: -8deg; }

.card-spread.is-spread-1 {
  width: min(340px, 100%);
  min-height: 390px;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: 378px;
}

.card-spread.is-spread-3 {
  width: min(560px, 100%);
  min-height: 350px;
  grid-template-columns: repeat(3, minmax(142px, 1fr));
  grid-template-rows: 320px;
}

.card-spread.is-spread-7 {
  width: min(730px, 100%);
  min-height: 548px;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(162px, auto));
  grid-auto-rows: 162px;
  gap: 18px 6px;
}

.card-spread.is-spread-7::after {
  content: "";
  position: absolute;
  inset: 7% 9% 8%;
  z-index: -1;
  background:
    linear-gradient(26deg, transparent 0 31%, rgba(255, 231, 174, .18) 32%, transparent 34% 100%),
    linear-gradient(154deg, transparent 0 31%, rgba(255, 231, 174, .16) 32%, transparent 34% 100%),
    linear-gradient(90deg, transparent 0 16%, rgba(255, 231, 174, .16) 17%, transparent 18% 82%, rgba(255, 231, 174, .14) 83%, transparent 84% 100%),
    radial-gradient(ellipse at 50% 50%, rgba(255, 224, 154, .2), rgba(255, 224, 154, .04) 44%, transparent 70%);
  border-radius: 50%;
  opacity: .72;
  filter: blur(.2px);
  pointer-events: none;
}

.tarot-canvas.is-reading-open .card-spread.is-spread-7::after {
  animation: tarotConstellationAwake 1.16s cubic-bezier(.16, .78, .18, 1) both;
}

.card-spread.is-spread-1 .tarot-slot.is-filled .tarot-card-image,
.card-spread.is-spread-1 .tarot-slot-caption {
  width: min(206px, 100%);
}

.card-spread.is-spread-1 .tarot-slot.is-filled .tarot-card-image {
  box-shadow: 0 24px 42px rgba(0, 0, 0, .42), 0 0 34px rgba(255, 219, 143, .12);
}

.card-spread.is-spread-1 .tarot-slot.is-revealed .tarot-card-image {
  filter: saturate(1.08) brightness(1.06);
}

.card-spread.is-spread-3 .tarot-slot.is-filled .tarot-card-image,
.card-spread.is-spread-3 .tarot-slot-caption {
  width: min(146px, 100%);
}

.card-spread.is-spread-7 .tarot-slot.is-filled .tarot-card-image,
.card-spread.is-spread-7 .tarot-slot-caption {
  width: min(98px, 100%);
}

.card-spread.is-spread-1 .tarot-slot,
.card-spread.is-spread-3 .tarot-slot,
.card-spread.is-spread-7 .tarot-slot {
  grid-column: auto;
  grid-row: auto;
}

.card-spread.is-spread-3 .tarot-slot:nth-child(1) { transform: rotate(-4deg) translateY(12px); }
.card-spread.is-spread-3 .tarot-slot:nth-child(2) { transform: translateY(-10px); }
.card-spread.is-spread-3 .tarot-slot:nth-child(3) { transform: rotate(4deg) translateY(12px); }

.card-spread.is-spread-7 .tarot-slot:nth-child(1),
.card-spread.is-spread-7 .tarot-slot:nth-child(5) { transform: none; }
.card-spread.is-spread-7 .tarot-slot:nth-child(3),
.card-spread.is-spread-7 .tarot-slot:nth-child(7) { transform: none; }

.card-spread.is-spread-7 .tarot-slot:nth-child(1) {
  grid-column: 4;
  grid-row: 2;
  transform: translateY(-6px);
}

.card-spread.is-spread-7 .tarot-slot:nth-child(2) {
  grid-column: 3;
  grid-row: 1;
  transform: rotate(-5deg) translateY(6px);
}

.card-spread.is-spread-7 .tarot-slot:nth-child(3) {
  grid-column: 5;
  grid-row: 1;
  transform: rotate(5deg) translateY(6px);
}

.card-spread.is-spread-7 .tarot-slot:nth-child(4) {
  grid-column: 2;
  grid-row: 2;
  transform: rotate(-7deg);
}

.card-spread.is-spread-7 .tarot-slot:nth-child(5) {
  grid-column: 6;
  grid-row: 2;
  transform: rotate(7deg);
}

.card-spread.is-spread-7 .tarot-slot:nth-child(6) {
  grid-column: 3;
  grid-row: 3;
  transform: rotate(4deg) translateY(-4px);
}

.card-spread.is-spread-7 .tarot-slot:nth-child(7) {
  grid-column: 5;
  grid-row: 3;
  transform: rotate(-4deg) translateY(-4px);
}

.tarot-canvas.is-drawing .card-spread.is-spread-7 {
  margin-top: 18px;
}

.tarot-canvas.tarot-stage-draw .card-spread {
  min-height: 210px;
  align-items: end;
}

.tarot-canvas.tarot-stage-draw .card-spread.is-spread-1 {
  min-height: 300px;
  grid-template-rows: 292px;
}

.tarot-canvas.tarot-stage-draw .card-spread.is-spread-3 {
  min-height: 215px;
  grid-template-rows: 200px;
}

.tarot-canvas.tarot-stage-draw .card-spread.is-spread-7 {
  min-height: 220px;
  grid-template-columns: repeat(4, minmax(72px, 1fr));
  grid-auto-rows: 104px;
  gap: 6px 8px;
  align-items: start;
}

.tarot-canvas.tarot-stage-draw .card-spread.is-spread-7 .tarot-slot {
  min-height: 92px;
}

.tarot-canvas.tarot-stage-draw .card-spread.is-spread-7 .tarot-slot:not(.is-filled) {
  min-height: 36px;
  align-content: center;
}

.tarot-canvas.tarot-stage-draw .card-spread.is-spread-7 .tarot-slot.is-filled .tarot-card-image,
.tarot-canvas.tarot-stage-draw .card-spread.is-spread-7 .tarot-slot-caption {
  width: min(72px, 100%);
}

.tarot-canvas.tarot-stage-draw .tarot-deck-surface {
  margin-top: -8px;
}

.tarot-slot span,
.room-station span,
.pillar-card span,
.zone-button span,
.astro-choice span {
  color: var(--accent);
  font-size: .74rem;
  font-weight: 950;
}

.tarot-slot span {
  max-width: 100%;
  overflow: hidden;
  color: var(--accent-2);
  font-size: .58rem;
  line-height: 1.12;
  text-overflow: ellipsis;
  text-shadow: 0 1px 5px rgba(0, 0, 0, .7);
  white-space: nowrap;
}

.tarot-slot strong,
.room-station strong,
.pillar-card strong,
.zone-button strong,
.astro-choice strong {
  font-size: .94rem;
  line-height: 1.25;
  word-break: keep-all;
}

.tarot-slot strong {
  width: 100%;
  max-width: 100%;
  display: -webkit-box;
  overflow: hidden;
  color: var(--text);
  font-size: .82rem;
  line-height: 1.12;
  overflow-wrap: anywhere;
  text-shadow: 0 1px 7px rgba(0, 0, 0, .78);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.tarot-slot small,
.room-station small,
.pillar-card small,
.zone-button small,
.astro-choice small {
  color: var(--muted);
  font-size: .7rem;
  font-weight: 800;
  line-height: 1.35;
}

.tarot-slot small {
  width: 100%;
  max-width: 100%;
  display: -webkit-box;
  overflow: hidden;
  overflow-wrap: anywhere;
  font-size: .56rem;
  line-height: 1.18;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .74);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.tarot-orientation-label,
.tarot-english-label {
  display: inline;
}

.tarot-english-label::before {
  content: " · ";
}

.card-spread.is-spread-7 .tarot-slot strong {
  -webkit-line-clamp: 1;
}

.card-spread.is-spread-7 .tarot-english-label {
  display: none;
}

.card-spread.is-spread-7 .tarot-english-label::before {
  content: "";
}

.saju-layout {
  min-height: 430px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 245px;
  gap: 14px;
}

.saju-tool {
  grid-template-rows: auto minmax(0, 1fr);
  gap: 18px;
}

.saju-stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  opacity: .72;
}

.saju-stepper li {
  min-width: 0;
  display: block;
  align-items: center;
  padding-bottom: 5px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  color: var(--muted);
}

.saju-stepper span {
  display: none;
}

.saju-stepper strong {
  min-width: 0;
  overflow: hidden;
  color: inherit;
  font-size: .76rem;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.saju-stepper li.is-active {
  border-color: rgba(255, 231, 174, .48);
  color: var(--accent-2);
}

.saju-stepper li.is-complete {
  color: color-mix(in srgb, var(--soft) 78%, transparent);
}

/* The step indicator (e.g. "1 출생 정보 입력") read as a residual header strip under the
   topbar title; hidden so saju/astrology/palm/face match tarot's clean header. */
.stage-indicator {
  display: none;
}

.stage-indicator span {
  width: 22px;
  height: 22px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .18);
  border-radius: 999px;
  color: var(--accent-2);
  background: rgba(0, 0, 0, .14);
  font-size: .68rem;
}

.stage-indicator strong {
  min-width: 0;
  color: var(--soft);
  overflow-wrap: anywhere;
}

.saju-stage {
  min-height: 0;
}

.saju-stage-input {
  display: grid;
  grid-template-columns: minmax(0, 720px);
  justify-content: center;
  gap: 26px;
  align-content: start;
}

.saju-input-form {
  display: grid;
  gap: 16px;
}

.saju-form-section,
.saju-form-grid label,
.saju-chart-copy,
.saju-basis {
  min-width: 0;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  padding-bottom: 14px;
}

.saju-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.saju-form-grid label {
  display: grid;
  gap: 8px;
  color: var(--soft);
  font-size: .82rem;
  font-weight: 900;
}

.saju-field-title,
.saju-form-grid span,
.saju-basis strong {
  display: block;
  margin-bottom: 8px;
  color: var(--soft);
  font-size: .82rem;
  font-weight: 950;
}

.saju-form-grid input,
.saju-form-grid select {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  background: rgba(7, 6, 8, .24);
  color: var(--text);
  padding-inline: 12px;
  font: inherit;
}

.saju-form-grid select option {
  background: #17100c;
  color: var(--text);
}

.saju-segmented {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.saju-segmented label {
  position: relative;
  min-height: 38px;
  display: inline-grid;
  place-items: center;
  padding: 0 13px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  color: var(--soft);
  background: rgba(255, 255, 255, .04);
  font-size: .82rem;
  font-weight: 900;
  cursor: pointer;
}

.saju-segmented label.is-active {
  border-color: color-mix(in srgb, var(--accent) 64%, white 36%);
  color: var(--accent-2);
  background: color-mix(in srgb, var(--accent-deep) 46%, rgba(255, 255, 255, .1) 54%);
}

.saju-segmented input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.saju-warning,
.saju-input-note,
.saju-chart-copy p,
.saju-basis p {
  color: var(--muted);
  font-size: .84rem;
  line-height: 1.58;
  word-break: keep-all;
}

.saju-warning {
  margin-top: 10px;
  color: color-mix(in srgb, var(--accent-2) 82%, #ff8170 18%);
}

.saju-chart-stage,
.saju-reading-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.16fr) minmax(280px, .84fr);
  gap: 22px;
  align-items: start;
}

.saju-canvas {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  padding: 18px;
}

.saju-canvas.is-compact {
  min-height: 360px;
}

.saju-reference-board {
  min-height: 420px;
  display: grid;
  grid-template-columns: minmax(240px, .95fr) minmax(220px, 1.05fr);
  gap: 22px;
  align-items: center;
}

.saju-reference-stack {
  min-width: 0;
  display: grid;
  gap: 16px;
  align-content: center;
}

.saju-reference-title {
  display: grid;
  gap: 7px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 231, 174, .14);
}

.saju-reference-title span {
  color: var(--accent-2);
  font-size: clamp(2rem, 5vw, 3.6rem);
  font-weight: 950;
  line-height: .9;
}

.saju-reference-title strong {
  color: var(--soft);
  font-size: .94rem;
  font-weight: 900;
}

.saju-reference-stack p {
  color: var(--muted);
  font-size: .84rem;
  line-height: 1.58;
  word-break: keep-all;
}

.saju-branch-wheel {
  position: relative;
  width: min(100%, 390px);
  aspect-ratio: 1;
  margin-inline: auto;
  border-radius: 50%;
  color: var(--soft);
  background:
    repeating-conic-gradient(from -90deg, rgba(255, 231, 174, .2) 0 1deg, transparent 1deg 30deg),
    radial-gradient(circle, transparent 0 30%, rgba(255, 231, 174, .11) 30.4% 30.8%, transparent 31.2% 49%, rgba(255, 231, 174, .16) 49.4% 49.8%, transparent 50.2% 66%, rgba(255, 231, 174, .22) 66.3% 66.8%, transparent 67.2%),
    radial-gradient(circle at 50% 50%, rgba(255, 231, 174, .045), transparent 68%);
  border: 1px solid rgba(255, 231, 174, .22);
}

.saju-branch-wheel.is-waiting {
  animation: sajuWheelBreathe 7s ease-in-out infinite;
}

.saju-branch-wheel.has-chart {
  background:
    repeating-conic-gradient(from -90deg, rgba(255, 231, 174, .24) 0 1deg, transparent 1deg 30deg),
    radial-gradient(circle, transparent 0 30%, rgba(255, 231, 174, .14) 30.4% 30.8%, transparent 31.2% 49%, rgba(255, 231, 174, .2) 49.4% 49.8%, transparent 50.2% 66%, rgba(255, 231, 174, .28) 66.3% 66.8%, transparent 67.2%),
    radial-gradient(circle at 50% 50%, rgba(255, 231, 174, .065), transparent 68%);
}

.saju-branch-wheel::before,
.saju-branch-wheel::after {
  content: "";
  position: absolute;
  inset: 8%;
  border: 1px solid rgba(255, 231, 174, .13);
  border-radius: 50%;
  pointer-events: none;
}

.saju-branch-wheel::after {
  inset: 21%;
  border-style: dashed;
  opacity: .72;
}

.saju-wheel-core {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 28%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 2px;
  border-radius: 50%;
  border: 1px solid rgba(255, 231, 174, .28);
  background: rgba(10, 8, 7, .28);
  transform: translate(-50%, -50%);
}

.saju-wheel-core strong {
  color: var(--accent-2);
  font-size: clamp(1.8rem, 5vw, 3rem);
  line-height: .9;
}

.saju-wheel-core span {
  color: var(--muted);
  font-size: .68rem;
  font-weight: 900;
}

.saju-compass {
  position: absolute;
  z-index: 1;
  color: rgba(255, 231, 174, .52);
  font-size: .68rem;
  font-weight: 950;
}

.saju-n { left: 50%; top: 33%; transform: translate(-50%, -50%); }
.saju-e { right: 33%; top: 50%; transform: translate(50%, -50%); }
.saju-s { left: 50%; bottom: 33%; transform: translate(-50%, 50%); }
.saju-w { left: 33%; top: 50%; transform: translate(-50%, -50%); }

.saju-branch-mark {
  position: absolute;
  left: var(--branch-x);
  top: var(--branch-y);
  z-index: 3;
  width: clamp(38px, 8vw, 54px);
  min-height: 44px;
  display: grid;
  place-items: center;
  gap: 1px;
  color: var(--muted);
  text-align: center;
  transform: translate(-50%, -50%);
}

.saju-branch-mark b {
  color: color-mix(in srgb, var(--soft) 78%, var(--accent-2) 22%);
  font-size: clamp(1.12rem, 3vw, 1.6rem);
  line-height: .95;
  font-weight: 950;
}

.saju-branch-mark small {
  max-width: 6.8em;
  overflow: hidden;
  color: var(--muted);
  font-size: .58rem;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.saju-branch-mark.is-active b {
  color: var(--accent-2);
  text-shadow: 0 0 16px rgba(255, 231, 174, .22);
}

.saju-branch-mark.is-active::before {
  content: "";
  position: absolute;
  inset: -4px 2px;
  border: 1px solid color-mix(in srgb, var(--accent) 56%, transparent);
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255, 231, 174, .1), transparent 62%);
  pointer-events: none;
  animation: sajuMarkPulse 3.4s ease-in-out infinite;
}

.saju-branch-mark[data-pillar="day"].is-active::before {
  border-color: color-mix(in srgb, var(--accent-2) 68%, transparent);
  background: radial-gradient(circle, rgba(255, 231, 174, .18), transparent 64%);
}

@keyframes sajuWheelBreathe {
  0%, 100% { filter: brightness(.94); }
  50% { filter: brightness(1.08); }
}

@keyframes sajuMarkPulse {
  0%, 100% { opacity: .5; transform: scale(.96); }
  50% { opacity: .95; transform: scale(1.05); }
}

.saju-pillar-board {
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(255, 231, 174, .18);
  border-bottom: 1px solid rgba(255, 231, 174, .14);
}

.saju-pillar-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 62px repeat(4, minmax(0, 1fr));
  align-items: stretch;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.saju-pillar-row:last-child {
  border-bottom: 0;
}

.saju-pillar-row > * {
  min-width: 0;
  display: grid;
  place-items: center;
  padding: 9px 7px;
  border-right: 1px solid rgba(255, 255, 255, .07);
  text-align: center;
}

.saju-pillar-row > *:last-child {
  border-right: 0;
}

.saju-pillar-row > span {
  color: var(--accent);
  font-size: .72rem;
  font-weight: 950;
}

.saju-pillar-row strong,
.saju-pillar-row i {
  color: var(--soft);
  font-style: normal;
  font-size: .78rem;
  font-weight: 900;
  line-height: 1.35;
  word-break: keep-all;
}

.saju-pillar-row.is-ganji b {
  gap: 4px;
}

.saju-pillar-row.is-ganji em {
  color: var(--accent-2);
  font-style: normal;
  font-size: clamp(1.55rem, 4vw, 2.7rem);
  font-weight: 950;
  line-height: .92;
}

.saju-pillar-row.is-ganji small {
  color: var(--muted);
  font-size: .66rem;
  font-weight: 900;
}

.saju-pillar-row .is-day-master {
  color: var(--accent-2);
  background: rgba(255, 231, 174, .055);
}

.saju-chart-map {
  display: grid;
  grid-template-columns: minmax(230px, .9fr) minmax(260px, 1.1fr);
  gap: 18px;
  align-items: center;
}

.element-board {
  display: grid;
  gap: 12px;
}

.element-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 36px;
  gap: 9px;
  align-items: center;
  color: var(--soft);
  font-size: .8rem;
  font-weight: 850;
}

.element-row span {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
}

.element-row em {
  color: var(--muted);
  font-style: normal;
  font-size: .68rem;
}

.element-row[data-element="목"] .element-fill { background: linear-gradient(90deg, #67c58f, #c4ffd9); }
.element-row[data-element="화"] .element-fill { background: linear-gradient(90deg, #e66f62, #ffd0a0); }
.element-row[data-element="토"] .element-fill { background: linear-gradient(90deg, #d3a35b, #ffe2a3); }
.element-row[data-element="금"] .element-fill { background: linear-gradient(90deg, #bcc8d6, #ffffff); }
.element-row[data-element="수"] .element-fill { background: linear-gradient(90deg, #64a6d8, #c8eaff); }

.element-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, .08);
}

.element-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
}

.saju-element-cycle {
  position: relative;
  width: min(100%, 310px);
  aspect-ratio: 1;
  margin-inline: auto;
  color: var(--soft);
}

.saju-element-cycle svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.saju-element-cycle line {
  stroke: rgba(255, 231, 174, .44);
  stroke-width: .8;
  vector-effect: non-scaling-stroke;
  marker-end: url(#sajuArrowSoft);
}

.saju-element-cycle marker path {
  fill: rgba(255, 231, 174, .72);
}

.saju-element-cycle line.is-control {
  stroke: rgba(255, 118, 96, .4);
  stroke-dasharray: 3 3;
}

.saju-element-node {
  position: absolute;
  left: var(--node-x);
  top: var(--node-y);
  width: clamp(48px, 9vw, 64px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 1px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--node-color, var(--accent)) 70%, rgba(255, 255, 255, .18) 30%);
  color: var(--text);
  background: color-mix(in srgb, var(--node-color, var(--accent)) calc(24% + var(--node-force) * 18%), rgba(12, 9, 8, .42));
  transform: translate(-50%, -50%) scale(var(--node-scale, 1));
  transition: transform .45s ease, background .45s ease, border-color .45s ease, filter .45s ease;
}

.saju-branch-wheel.has-chart + .saju-element-board .saju-element-node,
.saju-chart-map .saju-element-node {
  filter: brightness(var(--node-brightness, 1));
}

.saju-element-node b {
  color: var(--node-ink, var(--accent-2));
  font-size: clamp(1.12rem, 3vw, 1.45rem);
  line-height: .92;
  font-weight: 950;
}

.saju-element-node small {
  color: var(--soft);
  font-size: .62rem;
  font-weight: 950;
}

.saju-cycle-label {
  position: absolute;
  bottom: 4%;
  color: var(--muted);
  font-style: normal;
  font-size: .62rem;
  font-weight: 950;
}

.saju-cycle-label.is-generate {
  left: 8%;
}

.saju-cycle-label.is-control {
  right: 8%;
  color: color-mix(in srgb, #ff9b81 70%, var(--muted) 30%);
}

.saju-element-node[data-element="목"] { --node-color: #67c58f; --node-ink: #cdf6d9; }
.saju-element-node[data-element="화"] { --node-color: #e66f62; --node-ink: #ffd2bd; }
.saju-element-node[data-element="토"] { --node-color: #d3a35b; --node-ink: #ffe2a3; }
.saju-element-node[data-element="금"] { --node-color: #cbd3de; --node-ink: #f4f6f8; }
.saju-element-node[data-element="수"] { --node-color: #64a6d8; --node-ink: #d6edff; }

.saju-chart-copy {
  display: grid;
  gap: 13px;
  padding-bottom: 0;
}

.saju-chart-copy h3 {
  color: var(--accent-2);
}

.saju-key-facts {
  display: grid;
  gap: 10px;
  margin: 0;
}

.saju-key-facts div {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 10px;
  padding-block: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.saju-key-facts dt {
  color: var(--accent);
  font-size: .74rem;
  font-weight: 950;
}

.saju-key-facts dd {
  margin: 0;
  color: var(--soft);
  font-size: .84rem;
  line-height: 1.5;
  word-break: keep-all;
}

.saju-assumption-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.saju-assumption {
  min-width: 0;
  display: grid;
  gap: 2px;
  padding-block: 7px;
  border-bottom: 1px solid rgba(255, 255, 255, .09);
}

.saju-assumption b {
  color: var(--accent);
  font-size: .72rem;
}

.saju-assumption em {
  color: var(--soft);
  font-style: normal;
  font-size: .78rem;
  line-height: 1.35;
  word-break: keep-all;
}

.saju-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  padding-top: 4px;
}

.saju-actions .icon-button {
  min-width: 132px;
}

.saju-empty-state {
  display: grid;
  gap: 10px;
  align-content: start;
  color: var(--soft);
}

.saju-result-snapshot {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.saju-result-pillars,
.saju-result-elements,
.saved-saju-mini-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.saved-astro-mini-strip,
.saved-palm-mini-strip,
.saved-face-mini-strip {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding-block: 4px 2px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.saved-astro-mini-strip {
  justify-content: center;
}

.saved-astro-mini-strip span,
.saved-palm-mini-strip span,
.saved-face-mini-strip span {
  position: relative;
  width: 28px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .18);
  border-radius: 999px;
  color: var(--accent-2);
  background: transparent;
  box-shadow: none;
}

.saved-astro-mini-strip span {
  transform: translateY(calc((var(--saved-orbit-i, 0) - 2) * 2px));
}

.saved-astro-mini-strip span::before {
  content: "";
  position: absolute;
  inset: -5px;
  border: 1px solid rgba(221, 241, 255, .06);
  border-radius: 999px;
}

.saved-palm-mini-strip span {
  width: 34px;
  height: 16px;
  border-radius: 999px;
  border-color: transparent;
}

.saved-palm-mini-strip span::before {
  content: "";
  position: absolute;
  left: 4px;
  right: 4px;
  top: 50%;
  height: 2px;
  border-radius: 999px;
  background: rgba(255, 231, 174, .62);
  transform: translateY(-50%) rotate(-10deg);
}

.saved-palm-mini-strip span.is-soft::before {
  background: #bfe2ff;
  opacity: .86;
}

.saved-face-mini-strip span {
  border-radius: 48% 48% 42% 42%;
}

.saved-astro-mini-strip b,
.saved-palm-mini-strip b,
.saved-face-mini-strip b {
  position: relative;
  z-index: 1;
  color: inherit;
  font-size: .68rem;
  font-weight: 950;
  line-height: 1;
}

.saju-result-pillars span,
.saved-saju-mini-strip span {
  min-width: 0;
  display: grid;
  gap: 3px;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, .11);
  border-radius: 8px;
  background: rgba(255, 255, 255, .035);
}

.saju-result-pillars small,
.saved-saju-mini-strip small {
  color: var(--muted);
  font-size: .62rem;
  font-weight: 900;
}

.saju-result-pillars strong,
.saved-saju-mini-strip strong {
  overflow: hidden;
  color: var(--accent-2);
  font-size: 1.18rem;
  line-height: 1;
  text-overflow: ellipsis;
}

.saju-result-pillars em {
  overflow: hidden;
  color: var(--soft);
  font-style: normal;
  font-size: .68rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.saju-result-elements {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.saju-result-elements span {
  min-height: 28px;
  display: grid;
  place-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, .11);
  color: var(--soft);
  font-size: .72rem;
  font-weight: 900;
}

.saju-result-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
}

.saju-result-facts span {
  min-width: 0;
  color: var(--muted);
  font-size: .76rem;
  font-weight: 850;
  word-break: keep-all;
}

.saved-saju-mini-strip {
  margin: 8px 0 2px;
}

.option-canvas {
  min-height: 430px;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 18px;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.option-card {
  min-height: 112px;
  display: grid;
  align-content: end;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 8px;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .025)),
    rgba(0, 0, 0, .08);
  color: var(--text);
  text-align: left;
}

.option-card.is-active,
.option-card:hover {
  border-color: color-mix(in srgb, var(--accent) 68%, white 32%);
  background:
    linear-gradient(160deg, color-mix(in srgb, var(--accent-deep) 56%, rgba(255, 255, 255, .12) 44%), rgba(255, 255, 255, .04)),
    rgba(0, 0, 0, .12);
}

.option-card span {
  color: var(--accent);
  font-size: .74rem;
  font-weight: 950;
}

.option-card strong {
  font-size: .98rem;
  line-height: 1.25;
}

.option-card small {
  color: var(--muted);
  font-size: .76rem;
  line-height: 1.42;
}

.palm-layout,
.face-layout,
.astro-layout {
  min-height: 430px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 14px;
}

.palm-canvas,
.face-canvas,
.astro-canvas {
  display: grid;
  place-items: center;
  padding: 18px;
}

.hand-map {
  position: relative;
  width: min(390px, 82%);
  aspect-ratio: 3 / 4;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 44% 44% 38% 38%;
  background:
    radial-gradient(ellipse at 50% 38%, rgba(255, 229, 201, .18), transparent 54%),
    linear-gradient(180deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .02));
  box-shadow: inset 0 0 70px rgba(255, 210, 174, .08);
}

.hand-map::before {
  content: "";
  position: absolute;
  left: 19%;
  right: 19%;
  bottom: -17%;
  height: 33%;
  border: 1px solid rgba(255, 255, 255, .09);
  border-top: 0;
  border-radius: 0 0 34% 34%;
  background: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .01));
}

.palm-line {
  position: absolute;
  height: 2px;
  border: 0;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 72%, white 28%);
  box-shadow: 0 0 18px rgba(255, 218, 171, .22);
}

.palm-line.life { width: 58%; left: 24%; top: 57%; transform: rotate(-22deg); }
.palm-line.heart { width: 56%; left: 24%; top: 34%; transform: rotate(8deg); }
.palm-line.head { width: 54%; left: 26%; top: 46%; transform: rotate(-4deg); }
.palm-line.fate { width: 44%; left: 38%; top: 55%; transform: rotate(84deg); }

.zone-button {
  position: absolute;
  min-width: 120px;
  min-height: 56px;
  display: grid;
  gap: 3px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: 8px;
  background: rgba(12, 8, 7, .48);
  color: var(--text);
  text-align: left;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.zone-button.is-active,
.zone-button:hover {
  border-color: color-mix(in srgb, var(--accent) 70%, white 30%);
  background: color-mix(in srgb, var(--accent-deep) 58%, rgba(255, 255, 255, .12) 42%);
}

.zone-life { left: 7%; bottom: 18%; }
.zone-heart { right: 6%; top: 21%; }
.zone-head { left: 8%; top: 42%; }
.zone-fate { right: 8%; bottom: 33%; }
.zone-balance { left: 34%; top: 5%; }
.zone-shape { left: 34%; bottom: 5%; }

.face-map {
  position: relative;
  width: min(380px, 84%);
  aspect-ratio: 5 / 6;
  border: 1px solid color-mix(in srgb, var(--accent) 38%, white 62%);
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 50% 42%, rgba(255, 231, 222, .2), transparent 45%),
    linear-gradient(180deg, rgba(255, 255, 255, .1), rgba(255, 255, 255, .02));
  box-shadow: inset 0 0 70px rgba(255, 214, 221, .08);
}

.face-map::before,
.face-map::after {
  content: "";
  position: absolute;
  left: 20%;
  right: 20%;
  height: 1px;
  background: rgba(255, 226, 211, .32);
}

.face-map::before { top: 37%; }
.face-map::after { top: 62%; }

.face-zone-forehead { left: 31%; top: 11%; }
.face-zone-eyes { left: 9%; top: 34%; }
.face-zone-nose { right: 8%; top: 46%; }
.face-zone-mouth { left: 14%; bottom: 23%; }
.face-zone-jaw { right: 12%; bottom: 9%; }
.face-zone-mood { left: 35%; bottom: 43%; }

.astro-map {
  --astro-device-image: url("./assets/bg-astrology-celestial.png");
  position: relative;
  width: min(420px, 88%);
  aspect-ratio: 1;
  isolation: isolate;
  overflow: hidden;
  border: 0;
  border-radius: 50%;
  background: transparent;
}

.astro-map::before,
.astro-map::after {
  content: "";
  position: absolute;
  inset: 2.5%;
  z-index: 2;
  border-radius: 50%;
  pointer-events: none;
}

.astro-map::before {
  border: 1px solid rgba(255, 231, 174, .18);
  background:
    radial-gradient(circle, rgba(255, 231, 174, .11) 0 8%, transparent 8.4%),
    radial-gradient(circle, transparent 0 33%, rgba(255, 231, 174, .16) 33.3% 33.7%, transparent 34.1%),
    radial-gradient(circle, transparent 0 48%, rgba(255, 231, 174, .22) 48.3% 48.7%, transparent 49.1%),
    linear-gradient(90deg, transparent 49.84%, rgba(255, 231, 174, .18) 50%, transparent 50.16%),
    linear-gradient(0deg, transparent 49.84%, rgba(255, 231, 174, .16) 50%, transparent 50.16%);
  opacity: .62;
}

.astro-map::after {
  inset: -3%;
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 231, 174, .18), transparent 24%),
    radial-gradient(circle at 50% 50%, transparent 0 72%, rgba(255, 231, 174, .24) 72.4% 72.8%, transparent 73.2%),
    radial-gradient(circle at 50% 50%, transparent 0 88%, rgba(255, 231, 174, .15) 88.4% 88.8%, transparent 89.2%);
  opacity: .5;
}

.astro-device-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 50%;
  background-image: var(--astro-device-image);
  background-position: 62% 50%;
  background-size: 194%;
  pointer-events: none;
}

.astro-device-layer.is-ghost {
  inset: -12%;
  opacity: .18;
  filter: blur(2px) brightness(.8) saturate(.8);
  transform: scale(1.04);
}

.astro-device-layer.is-plate {
  opacity: .64;
  filter: brightness(1.02) contrast(1.05) saturate(.94);
  mask: radial-gradient(circle, #000 0 72%, transparent 74%);
}

.astro-device-layer.is-orbit {
  opacity: .48;
  filter: brightness(1.18) contrast(1.18);
  mask: radial-gradient(circle, transparent 0 34%, #000 36% 66%, transparent 68%);
  animation: astroDeviceTurn 56s linear infinite;
}

.astro-device-layer.is-zodiac {
  opacity: .5;
  filter: brightness(1.12) contrast(1.2);
  mask: radial-gradient(circle, transparent 0 52%, #000 54% 82%, transparent 84%);
  animation: astroDeviceTurnReverse 84s linear infinite;
}

.astro-device-layer.is-align {
  z-index: 3;
  opacity: .18;
  background-image:
    conic-gradient(from 0deg, transparent 0 14deg, rgba(255, 231, 174, .42) 14.2deg 14.55deg, transparent 14.8deg 44deg, rgba(255, 231, 174, .3) 44.2deg 44.5deg, transparent 44.8deg 360deg),
    radial-gradient(circle, transparent 0 44%, rgba(255, 231, 174, .16) 44.4% 44.8%, transparent 45.2% 72%, rgba(255, 231, 174, .2) 72.4% 72.8%, transparent 73.2%);
  background-position: center;
  background-size: 100% 100%;
  mix-blend-mode: screen;
}

.astro-map.is-empty:not(.is-ready) .astro-device-layer.is-plate,
.astro-map.is-empty:not(.is-ready) .astro-device-layer.is-orbit,
.astro-map.is-empty:not(.is-ready) .astro-device-layer.is-zodiac {
  opacity: .26;
  filter: blur(.5px) brightness(.78) saturate(.76);
}

.astro-map.is-ready .astro-device-layer.is-plate {
  opacity: .72;
}

.astro-map.is-calculating .astro-device-layer.is-orbit {
  opacity: .72;
  animation-duration: 14s;
}

.astro-map.is-calculating .astro-device-layer.is-zodiac {
  opacity: .68;
  animation-duration: 22s;
}

.astro-map.is-calculating .astro-device-layer.is-align {
  opacity: .38;
  animation: astroDevicePulse 2.4s ease-in-out infinite;
}

.astro-map.has-selection .astro-device-layer.is-ghost {
  opacity: .22;
}

.astro-map.has-selection .astro-device-layer.is-plate {
  opacity: .78;
}

.astro-map.is-reading {
  width: min(380px, 84%);
}

.astro-map.is-reading .astro-device-layer.is-orbit,
.astro-map.is-reading .astro-device-layer.is-zodiac {
  animation-play-state: paused;
}

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

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

@keyframes astroDevicePulse {
  0%, 100% { opacity: .18; transform: scale(.98); }
  50% { opacity: .44; transform: scale(1.02); }
}

@keyframes astroFocusPulse {
  0%, 100% { opacity: .34; transform: scale(.94); }
  50% { opacity: .82; transform: scale(1.06); }
}

.astro-choice {
  position: absolute;
  min-width: 112px;
  min-height: 58px;
  display: grid;
  gap: 3px;
  padding: 8px 10px;
  border: 1px solid rgba(221, 241, 255, .16);
  border-radius: 8px;
  background: rgba(9, 15, 28, .5);
  color: var(--text);
  text-align: left;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.astro-choice.is-active,
.astro-choice:hover {
  border-color: color-mix(in srgb, var(--accent) 68%, white 32%);
  background: color-mix(in srgb, var(--accent-deep) 58%, rgba(255, 255, 255, .13) 42%);
}

.astro-sun { left: 36%; top: 6%; }
.astro-moon { right: 3%; top: 36%; }
.astro-rising { left: 36%; bottom: 6%; }
.astro-venus { left: 3%; top: 36%; }
.astro-mars { left: 15%; bottom: 18%; }
.astro-house { right: 13%; bottom: 18%; }

.result-panel {
  display: grid;
  grid-template-rows: auto minmax(120px, 1fr) minmax(0, 168px) auto auto;
  gap: 14px;
  height: 100%;
  overflow: hidden;
}

.result-head h2 {
  margin-top: 7px;
  font-size: 1.34rem;
}

.reading-copy {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 2px 4px 2px 0;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

/* 세로 스크롤 대신 카드형 페이지네이션 — 리딩 본문을 영역 높이에 맞춰 페이지로 나눈다. */
.reading-copy .card-pager {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}
.card-pager-viewport {
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.card-pager-viewport > .reading-final {
  display: flex;
  flex-direction: column;
  gap: 12px;
  height: 100%;
}
.card-pager-viewport > .reading-final > p {
  margin: 0; /* 페이지 간격은 gap이 담당 */
}
.rc-hidden {
  display: none !important;
}
.rc-fit-shrink {
  font-size: .86em;
  line-height: 1.5;
}
.card-pager-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding-top: 10px;
  flex: none;
}
.card-pager[data-pages="1"] .card-pager-nav {
  display: none;
}
.card-pager-arrow {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .28);
  border-radius: 999px;
  background: transparent;
  color: var(--accent, #d7b46c);
  font-size: 1rem;
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease;
}
.card-pager-arrow:hover:not(:disabled) {
  border-color: var(--accent, #d7b46c);
  color: var(--accent-2, #fff0bf);
}
.card-pager-arrow:disabled {
  opacity: .32;
  cursor: default;
}
.card-pager-dots {
  display: flex;
  align-items: center;
  gap: 7px;
}
.card-pager-dot {
  width: 7px;
  height: 7px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 231, 174, .26);
  cursor: pointer;
  transition: background .15s ease, transform .15s ease;
}
.card-pager-dot.is-active {
  background: var(--accent, #d7b46c);
  transform: scale(1.25);
}

body[data-service="tarot"] .reading-copy.is-loading-reading,
body[data-service="tarot"] .reading-copy.is-committed-reading,
body[data-service="tarot"] .reading-copy.is-restored-reading {
  overflow-x: hidden;
}

body[data-service="tarot"] .reading-copy.is-new-reading::after {
  content: "";
  position: absolute;
  inset: 0 -8px;
  z-index: 2;
  border-radius: 0;
  background:
    linear-gradient(104deg, transparent 0 28%, rgba(255, 244, 204, .2) 42%, rgba(255, 231, 174, .36) 50%, rgba(255, 244, 204, .16) 58%, transparent 72% 100%),
    radial-gradient(ellipse at 50% 18%, rgba(255, 227, 164, .2), rgba(255, 227, 164, 0) 62%);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-36%) skewX(-8deg);
  animation: readingResultSweep 1.2s cubic-bezier(.16, .82, .18, 1) both;
}

body[data-service="tarot"] .reading-copy.is-committed-reading::before,
body[data-service="tarot"] .reading-copy.is-restored-reading::before {
  content: "";
  position: sticky;
  top: 0;
  z-index: -1;
  display: block;
  height: 1px;
  margin-bottom: -1px;
  background: radial-gradient(circle at 50% 0, rgba(255, 227, 164, .28), rgba(255, 227, 164, 0) 66%);
  filter: blur(14px);
  animation: readingAuraIn .9s ease both;
}

.reading-copy h3 {
  margin-bottom: 12px;
  color: var(--accent-2);
  font-size: 1.06rem;
}

.reading-copy p {
  color: var(--soft);
  font-size: .94rem;
  line-height: 1.64;
  word-break: keep-all;
}

.reading-copy .reading-meta {
  margin: -4px 0 12px;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 850;
}

.reading-copy p + p {
  margin-top: 12px;
}

.reading-draft-state {
  display: grid;
  gap: 9px;
  align-content: start;
}

.reading-draft-kicker {
  width: fit-content;
  color: var(--muted);
  font-size: .68rem;
  font-weight: 950;
}

body[data-service="tarot"] .reading-draft-state h3 {
  margin-bottom: 0;
}

body[data-service="tarot"] .reading-draft-state p {
  color: color-mix(in srgb, var(--soft) 86%, transparent);
}

.reading-ritual {
  display: grid;
  align-content: center;
  gap: 12px;
  min-height: 188px;
  animation: readingFinalIn .56s ease both;
}

.tarot-reading-ritual {
  grid-template-columns: minmax(148px, .86fr) minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  min-height: 260px;
}

.reading-ritual-focus {
  position: relative;
  min-height: 210px;
  display: grid;
  place-items: center;
  isolation: isolate;
}

.reading-ritual-orbit {
  position: relative;
  width: min(210px, 82%);
  aspect-ratio: 1;
  margin: 0 auto 2px;
  border: 1px solid rgba(255, 231, 174, .16);
  border-radius: 999px;
  background:
    radial-gradient(circle at center, rgba(255, 226, 158, .18), rgba(255, 226, 158, 0) 60%),
    conic-gradient(from 14deg, transparent, rgba(255, 231, 174, .2), transparent 42%, rgba(255, 231, 174, .12), transparent 74%);
  box-shadow: inset 0 0 26px rgba(255, 219, 143, .06);
}

.reading-ritual-orbit::before {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: inherit;
  background:
    conic-gradient(from 0deg, transparent 0 10%, rgba(255, 231, 174, .48) 12%, transparent 16% 32%, rgba(255, 231, 174, .28) 35%, transparent 39% 62%, rgba(255, 231, 174, .34) 65%, transparent 70% 100%),
    radial-gradient(circle at center, rgba(255, 231, 174, .14), transparent 64%);
  opacity: .62;
  pointer-events: none;
  transform: scale(.92);
  animation: readingRitualGate 2.2s ease-in-out infinite;
}

.reading-ritual-orbit::after {
  content: "";
  position: absolute;
  inset: 34%;
  border-radius: inherit;
  background: radial-gradient(circle, rgba(255, 230, 166, .34), rgba(255, 230, 166, 0) 70%);
}

.reading-ritual-card {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 42px;
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 5px;
  background-color: rgba(0, 0, 0, .24);
  background-position: center;
  background-size: cover;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .32);
  overflow: hidden;
  transform:
    rotate(var(--ritual-angle, 0deg))
    translateY(-82px)
    rotate(var(--ritual-counter-angle, 0deg))
    translate(-50%, -50%);
  animation: readingRitualCardOrbitUpright 6.8s linear infinite;
  animation-delay: calc(var(--ritual-i, 0) * -240ms);
}

.reading-ritual-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 14%, rgba(255, 244, 204, .38), rgba(255, 244, 204, 0) 42%),
    linear-gradient(145deg, rgba(255, 255, 255, .18), transparent 38% 70%, rgba(0, 0, 0, .16));
  opacity: .64;
  pointer-events: none;
}

.reading-ritual-card::after {
  content: "";
  position: absolute;
  inset: -18% -58%;
  background: linear-gradient(104deg, transparent 34%, rgba(255, 244, 204, .68) 49%, transparent 64%);
  opacity: 0;
  transform: translateX(-72%) rotate(8deg);
  pointer-events: none;
  animation: readingRitualCardSheen 2.2s ease-in-out infinite;
  animation-delay: calc(var(--ritual-i, 0) * 120ms + 180ms);
}

.reading-ritual-core {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.reading-ritual-core span {
  width: 64px;
  aspect-ratio: 1;
  border-radius: 999px;
  background:
    radial-gradient(circle, rgba(255, 235, 184, .4), rgba(255, 235, 184, 0) 62%),
    radial-gradient(circle, rgba(255, 221, 144, .2), rgba(255, 221, 144, 0) 72%);
  filter: blur(.2px);
  animation: readingRitualPulse 1.52s ease-in-out infinite;
}

.reading-ritual-core::before,
.reading-ritual-core::after {
  content: "";
  position: absolute;
  width: 96px;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 231, 174, .18);
  border-radius: 999px;
  opacity: .72;
  pointer-events: none;
}

.reading-ritual-core::before {
  animation: readingRitualCoreRing 2.2s ease-in-out infinite;
}

.reading-ritual-core::after {
  width: 122px;
  opacity: .42;
  animation: readingRitualCoreRing 2.2s ease-in-out infinite reverse;
}

.reading-ritual-core strong {
  position: absolute;
  color: var(--accent-2);
  font-size: .66rem;
  font-weight: 950;
  letter-spacing: 0;
}

.reading-ritual-copy {
  display: grid;
  gap: 9px;
  min-width: 0;
}

.reading-ritual-kicker,
.reading-source-note {
  color: var(--accent-2);
  font-size: .68rem;
  font-weight: 950;
}

.reading-ritual-question {
  color: var(--text);
  font-size: .86rem;
  font-weight: 850;
  line-height: 1.5;
}

.reading-ritual-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.reading-ritual-tags span,
.reading-ritual-steps span {
  color: var(--soft);
  font-size: .66rem;
  font-weight: 900;
}

.reading-ritual-tags span {
  border-bottom: 1px solid rgba(255, 231, 174, .18);
  animation: readingTokenIn .42s ease both;
  animation-delay: calc(var(--ritual-i, 0) * 72ms);
}

.reading-ritual-steps {
  display: grid;
  gap: 5px;
  margin-top: 4px;
}

.reading-ritual-steps span {
  position: relative;
  padding-left: 14px;
  color: var(--muted);
  animation: readingRitualStep 1.6s ease-in-out infinite;
}

.reading-ritual-steps span::before {
  content: "";
  position: absolute;
  left: 0;
  top: .55em;
  width: 7px;
  height: 2px;
  border-radius: 999px;
  background: rgba(255, 231, 174, .42);
}

.reading-ritual-steps span:nth-child(2) { animation-delay: 180ms; }
.reading-ritual-steps span:nth-child(3) { animation-delay: 360ms; }
.reading-ritual-steps span:nth-child(4) { animation-delay: 540ms; }

body[data-service="tarot"] .reading-final {
  position: relative;
  isolation: isolate;
  animation: readingFinalIn .7s cubic-bezier(.18, .8, .22, 1) both;
}

body[data-service="tarot"] .reading-copy.is-new-reading .reading-final::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 12px;
  z-index: -1;
  width: min(330px, 96%);
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(255, 227, 164, .28), rgba(255, 227, 164, .06) 42%, transparent 70%);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) scale(.74);
  animation: readingResultAura .92s ease both;
}

body[data-service="tarot"] .reading-final h3,
body[data-service="tarot"] .reading-final .reading-meta,
body[data-service="tarot"] .reading-final .reading-paragraphs p {
  animation: readingTextRise .55s ease both;
}

body[data-service="tarot"] .reading-final .reading-meta { animation-delay: 70ms; }
body[data-service="tarot"] .reading-final .reading-paragraphs p:nth-child(1) { animation-delay: 140ms; }
body[data-service="tarot"] .reading-final .reading-paragraphs p:nth-child(2) { animation-delay: 210ms; }
body[data-service="tarot"] .reading-final .reading-paragraphs p:nth-child(3) { animation-delay: 280ms; }
body[data-service="tarot"] .reading-final .reading-paragraphs p:nth-child(4) { animation-delay: 350ms; }

.reading-result-seal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px 10px;
  margin: 0 0 12px;
  padding: 0 0 10px;
  border-bottom: 1px solid rgba(255, 231, 174, .14);
}

.reading-result-seal span {
  min-width: 0;
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  color: var(--muted);
  font-size: .66rem;
  font-weight: 950;
  line-height: 1.2;
  white-space: nowrap;
}

.reading-result-seal span::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 231, 174, .36);
  box-shadow: 0 0 12px rgba(255, 226, 156, .14);
}

.reading-result-seal b {
  color: var(--accent-2);
  font-size: .76rem;
  font-weight: 950;
}

.reading-result-seal .is-ready,
.reading-result-seal .is-saved {
  color: var(--accent-2);
}

.reading-result-seal .is-saved::before {
  background: var(--accent-2);
  box-shadow: 0 0 16px rgba(255, 226, 156, .36);
}

body[data-service="tarot"] .reading-copy.is-new-reading .reading-result-seal span {
  animation: readingTokenIn .46s ease both;
  animation-delay: calc(var(--seal-i, 0) * 56ms + 90ms);
}

.reading-result-seal span:nth-child(1) { --seal-i: 0; }
.reading-result-seal span:nth-child(2) { --seal-i: 1; }
.reading-result-seal span:nth-child(3) { --seal-i: 2; }
.reading-result-seal span:nth-child(4) { --seal-i: 3; }

.reading-source-note {
  margin: 2px 0 10px;
  padding-left: 10px;
  border-left: 2px solid rgba(255, 231, 174, .3);
  animation: readingTextRise .5s ease both;
  animation-delay: 110ms;
}

@media (max-width: 820px) {
  .tarot-reading-ritual {
    grid-template-columns: 1fr;
    gap: 12px;
    min-height: 0;
  }

  .reading-ritual-focus {
    min-height: 174px;
  }

  .reading-ritual-orbit {
    width: min(164px, 70%);
  }

  .reading-ritual-card {
    width: 34px;
    transform:
      rotate(var(--ritual-angle, 0deg))
      translateY(-64px)
      rotate(var(--ritual-counter-angle, 0deg))
      translate(-50%, -50%);
  }

  .reading-ritual-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.reading-quote {
  margin: 14px 0;
  padding: 8px 0 8px 14px;
  border-left: 3px solid var(--accent);
  color: var(--text);
  font-weight: 850;
  line-height: 1.62;
  word-break: keep-all;
}

.reading-card-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 8px;
  margin: 12px 0 14px;
}

.reading-card-token {
  min-width: 0;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
}

.reading-card-thumb {
  width: 34px;
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(255, 231, 174, .32);
  border-radius: 5px;
  background-color: rgba(0, 0, 0, .22);
  background-position: center;
  background-size: cover;
}

.reading-card-token small,
.reading-card-token em {
  display: block;
  overflow: hidden;
  color: var(--muted);
  font-size: .64rem;
  font-style: normal;
  font-weight: 850;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reading-card-token strong {
  display: block;
  overflow: hidden;
  margin: 1px 0;
  color: var(--text);
  font-size: .82rem;
  line-height: 1.24;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-service="tarot"] .reading-card-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  overflow: visible;
  margin: 12px 0 18px;
  padding: 2px 0 8px;
}

body[data-service="tarot"] .reading-card-token {
  --result-tilt: 0deg;
  position: relative;
  min-height: 124px;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 4px 0 12px;
  border-bottom-color: rgba(255, 231, 174, .14);
  animation: readingCardResultIn .62s cubic-bezier(.18, .8, .22, 1) both;
  animation-delay: calc(var(--result-i, 0) * 58ms + 70ms);
}

body[data-service="tarot"] .reading-card-token:nth-child(3n + 1),
body[data-service="tarot"] .reading-card-token:nth-child(3n + 2),
body[data-service="tarot"] .reading-card-token:nth-child(3n) {
  --result-tilt: 0deg;
}

body[data-service="tarot"] .reading-card-token::before {
  content: "";
  position: absolute;
  left: 37px;
  top: 54px;
  z-index: -1;
  width: 86px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 227, 164, .18), rgba(255, 227, 164, 0) 68%);
  opacity: .42;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

body[data-service="tarot"] .reading-card-strip.is-count-7 {
  gap: 8px;
}

body[data-service="tarot"] .reading-card-strip.is-count-7 .reading-card-token {
  min-height: 102px;
  grid-template-columns: 58px minmax(0, 1fr);
}

body[data-service="tarot"] .reading-card-strip.is-count-7 .reading-card-thumb {
  width: 58px;
}

body[data-service="tarot"] .reading-card-thumb {
  position: relative;
  overflow: hidden;
  width: 74px;
  border-radius: 5px;
  transform: rotate(var(--result-tilt));
  transform-origin: center;
  box-shadow: 0 12px 24px rgba(0, 0, 0, .34), 0 0 20px rgba(255, 226, 156, .09);
}

body[data-service="tarot"] .reading-card-token.is-reversed .reading-card-thumb {
  transform: rotate(calc(var(--result-tilt) + 180deg));
}

body[data-service="tarot"] .reading-card-thumb::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 16%, rgba(255, 244, 204, .34), rgba(255, 244, 204, 0) 42%),
    linear-gradient(145deg, rgba(255, 255, 255, .16), transparent 40% 70%, rgba(0, 0, 0, .16));
  opacity: .72;
  pointer-events: none;
}

body[data-service="tarot"] .reading-copy.is-new-reading .reading-card-thumb::before {
  animation: readingCardThumbSheen .86s ease both;
  animation-delay: calc(var(--result-i, 0) * 66ms + 160ms);
}

body[data-service="tarot"] .reading-card-thumb::after {
  content: attr(data-card-index);
  position: absolute;
  right: -5px;
  bottom: -5px;
  min-width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .28);
  border-radius: 999px;
  background: rgba(7, 6, 8, .82);
  color: var(--accent-2);
  font-size: .54rem;
  font-weight: 950;
}

body[data-service="tarot"] .reading-card-body {
  min-width: 0;
  align-self: start;
  display: grid;
  gap: 3px;
  padding-top: 1px;
}

body[data-service="tarot"] .reading-card-body::before {
  display: none;
}

body[data-service="tarot"] .reading-card-token small,
body[data-service="tarot"] .reading-card-token em {
  font-size: .6rem;
  white-space: normal;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

body[data-service="tarot"] .reading-card-token strong {
  font-size: .78rem;
  line-height: 1.18;
  white-space: normal;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

body[data-service="tarot"] .reading-card-meaning {
  display: -webkit-box;
  margin-top: 6px;
  overflow: hidden;
  color: rgba(248, 238, 210, .76);
  font-size: .68rem;
  font-weight: 760;
  line-height: 1.42;
  overflow-wrap: anywhere;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

body[data-service="tarot"] .reading-card-strip.is-count-7 .reading-card-meaning {
  margin-top: 3px;
  font-size: .62rem;
  line-height: 1.34;
  -webkit-line-clamp: 2;
}

.evidence-stack {
  min-height: 0;
  max-height: 168px;
  display: grid;
  gap: 8px;
  overflow: visible;
  padding: 0 2px 2px;
}

.evidence-stack:empty {
  display: none;
}

.visual-evidence-board {
  position: relative;
  min-height: 118px;
  display: grid;
  align-items: center;
  overflow: visible;
}

.visual-evidence-map {
  position: relative;
  min-height: 112px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(6px, 1.1vw, 12px);
  padding: 12px 4px 22px;
  overflow: visible;
}

.visual-evidence-map::before {
  content: "";
  position: absolute;
  inset: 18px 6px 20px;
  border-top: 1px solid rgba(255, 231, 174, .12);
  border-bottom: 1px solid rgba(255, 231, 174, .06);
  opacity: .82;
  pointer-events: none;
}

.visual-evidence-node {
  position: relative;
  z-index: calc(12 + var(--evidence-i, 0));
  display: grid;
  place-items: center;
}

.visual-evidence-node summary {
  width: 48px;
  height: 64px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  list-style: none;
  outline: 0;
}

.visual-evidence-node summary::-webkit-details-marker {
  display: none;
}

.visual-evidence-node summary:focus-visible .visual-evidence-symbol {
  outline: 1px solid rgba(255, 231, 174, .72);
  outline-offset: 5px;
}

.visual-evidence-symbol {
  position: relative;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: var(--accent-2);
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, .38));
  transition: transform .18s ease, filter .18s ease, opacity .18s ease;
}

.visual-evidence-node:hover .visual-evidence-symbol,
.visual-evidence-node:focus-within .visual-evidence-symbol,
.visual-evidence-node[open] .visual-evidence-symbol {
  filter: drop-shadow(0 14px 22px rgba(0, 0, 0, .46)) brightness(1.1);
  transform: translateY(-3px) scale(1.04);
}

.visual-evidence-popover {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  z-index: 40;
  width: min(230px, 74vw);
  padding: 10px 11px;
  border: 1px solid rgba(255, 231, 174, .2);
  border-radius: 8px;
  background: rgba(8, 7, 8, .94);
  box-shadow: 0 18px 34px rgba(0, 0, 0, .42);
  color: var(--text);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 6px);
  transition: opacity .16s ease, transform .16s ease;
}

.visual-evidence-node:hover .visual-evidence-popover,
.visual-evidence-node:focus-within .visual-evidence-popover,
.visual-evidence-node[open] .visual-evidence-popover {
  opacity: 1;
  transform: translate(-50%, 0);
}

.visual-evidence-popover strong,
.visual-evidence-popover span,
.visual-evidence-popover p {
  display: block;
}

.visual-evidence-popover strong {
  font-size: .82rem;
  line-height: 1.28;
}

.visual-evidence-popover span {
  margin-top: 4px;
  color: var(--accent);
  font-size: .66rem;
  font-weight: 900;
}

.visual-evidence-popover p {
  margin-top: 6px;
  color: var(--soft);
  font-size: .7rem;
  line-height: 1.38;
}

.visual-card-symbol {
  width: 38px;
  height: 58px;
  border: 1px solid rgba(255, 231, 174, .36);
  border-radius: 5px;
  background-position: center;
  background-size: cover;
  box-shadow: 0 13px 22px rgba(0, 0, 0, .36);
}

.visual-card-symbol.is-reversed {
  transform: rotate(180deg);
}

.visual-pillar-symbol {
  width: 34px;
  height: 70px;
  border-top: 1px solid rgba(255, 231, 174, .5);
  border-bottom: 1px solid rgba(255, 231, 174, .42);
  color: rgba(255, 240, 197, .96);
}

.visual-pillar-symbol::before,
.visual-pillar-symbol::after {
  content: "";
  position: absolute;
  inset-block: 8px;
  width: 1px;
  background: linear-gradient(transparent, rgba(255, 231, 174, .5), transparent);
}

.visual-pillar-symbol::before { left: 5px; }
.visual-pillar-symbol::after { right: 5px; }

.visual-pillar-symbol b {
  font-size: 1.2rem;
  line-height: 1;
}

.visual-pillar-symbol i {
  display: none;
}

.visual-element-symbol,
.visual-planet-symbol,
.visual-source-symbol {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 231, 174, .26);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 231, 174, .18), rgba(255, 231, 174, .02) 68%),
    rgba(255, 255, 255, .018);
}

.visual-element-symbol::after,
.visual-planet-symbol::after,
.visual-source-symbol::after {
  content: "";
  position: absolute;
  inset: -7px;
  border: 1px solid rgba(255, 231, 174, .1);
  border-radius: inherit;
}

.visual-element-symbol b,
.visual-planet-symbol b,
.visual-source-symbol b {
  font-size: .94rem;
  line-height: 1;
}

.visual-line-symbol {
  width: 58px;
  height: 38px;
}

.visual-line-symbol i {
  width: 52px;
  height: 24px;
  border-top: 2px solid rgba(255, 231, 174, .72);
  border-radius: 50%;
  transform: rotate(calc(var(--evidence-angle, 0deg) * .08));
}

.visual-line-symbol.is-soft i {
  border-top-style: dashed;
  opacity: .7;
}

.visual-face-symbol {
  width: 46px;
  height: 58px;
  border: 1px solid rgba(255, 231, 174, .28);
  border-radius: 48% 48% 44% 44%;
}

.visual-face-symbol::before,
.visual-face-symbol::after {
  content: "";
  position: absolute;
  left: 50%;
  border-radius: 999px;
  transform: translateX(-50%);
}

.visual-face-symbol::before {
  top: 18px;
  width: 22px;
  height: 1px;
  background: rgba(255, 231, 174, .5);
  box-shadow: 0 12px 0 rgba(255, 231, 174, .36), 0 24px 0 rgba(255, 231, 174, .26);
}

.visual-face-symbol::after {
  top: 28px;
  width: 5px;
  height: 5px;
  background: rgba(255, 231, 174, .76);
}

body[data-service="tarot"] .visual-evidence-map {
  align-items: flex-end;
}

body[data-service="tarot"] .visual-evidence-node {
  transform: rotate(calc(var(--evidence-angle, 0deg) * .08)) translateY(calc((var(--evidence-i, 0) % 2) * -5px));
}

body[data-service="tarot"] .visual-evidence-popover {
  transform: translate(-50%, 6px) rotate(calc(var(--evidence-angle, 0deg) * -.08));
}

body[data-service="tarot"] .visual-evidence-node:hover .visual-evidence-popover,
body[data-service="tarot"] .visual-evidence-node:focus-within .visual-evidence-popover,
body[data-service="tarot"] .visual-evidence-node[open] .visual-evidence-popover {
  transform: translate(-50%, 0) rotate(calc(var(--evidence-angle, 0deg) * -.08));
}

body[data-service="saju"] .visual-evidence-map::before {
  inset: 14px 18%;
  border: 1px solid rgba(255, 231, 174, .11);
  border-radius: 50%;
}

body[data-service="astrology"] .visual-evidence-map::before {
  inset: 11px 11%;
  border: 1px solid rgba(202, 224, 255, .16);
  border-radius: 50%;
  box-shadow: inset 0 0 0 18px rgba(202, 224, 255, .025);
}

body[data-service="astrology"] .visual-planet-symbol,
body[data-service="astrology"] .visual-source-symbol {
  border-color: rgba(202, 224, 255, .28);
  color: rgba(229, 241, 255, .96);
}

body[data-service="palm"] .visual-evidence-map::before,
body[data-service="face"] .visual-evidence-map::before {
  border-top-color: rgba(255, 231, 174, .08);
  border-bottom-color: transparent;
}

.visual-evidence-board.is-saju .visual-evidence-map,
.visual-evidence-board.is-astrology .visual-evidence-map,
.visual-evidence-board.is-palm .visual-evidence-map,
.visual-evidence-board.is-face .visual-evidence-map {
  isolation: isolate;
}

.visual-evidence-board.is-saju .visual-evidence-map {
  min-height: 146px;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px clamp(8px, 1.8vw, 18px);
  padding-block: 14px 18px;
}

.visual-evidence-board.is-saju .visual-evidence-map::before {
  inset: 38px 18%;
  border: 1px solid rgba(255, 231, 174, .13);
  border-radius: 50%;
  box-shadow:
    inset 0 0 0 18px rgba(255, 231, 174, .018),
    inset 0 0 0 36px rgba(255, 231, 174, .01);
}

.visual-evidence-board.is-saju .visual-evidence-map::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 54%;
  z-index: -1;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 231, 174, .12);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 231, 174, .16) 0 5px, transparent 6px),
    linear-gradient(90deg, rgba(255, 231, 174, .08), transparent 52%);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.visual-evidence-board.is-saju .visual-evidence-node.is-pillar {
  flex: 0 0 38px;
  align-self: flex-start;
}

.visual-evidence-board.is-saju .visual-evidence-node.is-element {
  flex: 0 0 44px;
  align-self: flex-end;
  transform: translateY(4px);
}

.visual-evidence-board.is-saju .visual-evidence-node.is-element:nth-child(even) {
  transform: translateY(-2px);
}

.visual-evidence-board.is-astrology .visual-evidence-map {
  min-height: 156px;
  padding: 0;
}

.visual-evidence-board.is-astrology .visual-evidence-map::before {
  inset: 14px 17%;
  border: 1px solid rgba(202, 224, 255, .18);
  border-radius: 50%;
  box-shadow:
    inset 0 0 0 16px rgba(202, 224, 255, .024),
    inset 0 0 0 34px rgba(202, 224, 255, .014);
}

.visual-evidence-board.is-astrology .visual-evidence-map::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: -1;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(255, 231, 174, .24) 0 5px, transparent 6px),
    radial-gradient(circle, rgba(202, 224, 255, .08), transparent 64%);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.visual-evidence-board.is-astrology .visual-evidence-node {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: rotate(var(--evidence-angle, 0deg)) translateY(-58px) rotate(var(--evidence-counter-angle, 0deg));
}

.visual-evidence-board.is-astrology .visual-evidence-node.is-aspect {
  transform: rotate(var(--evidence-angle, 0deg)) translateY(-30px) rotate(var(--evidence-counter-angle, 0deg));
}

.visual-evidence-board.is-palm .visual-evidence-map {
  min-height: 136px;
  gap: 0;
  padding-block: 18px;
}

.visual-evidence-board.is-palm .visual-evidence-map::before {
  left: 50%;
  top: 50%;
  right: auto;
  bottom: auto;
  width: 118px;
  height: 132px;
  border: 1px solid rgba(255, 231, 174, .12);
  border-radius: 48% 48% 40% 42%;
  background:
    radial-gradient(ellipse at 50% 88%, rgba(255, 231, 174, .04), transparent 64%),
    linear-gradient(180deg, rgba(255, 231, 174, .025), transparent);
  transform: translate(-50%, -50%);
}

.visual-evidence-board.is-palm .visual-evidence-node {
  margin-inline: -8px;
  transform: translateY(0);
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(2) {
  transform: translateY(-8px);
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(3) {
  transform: translateY(8px);
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(4) {
  transform: translateY(-3px);
}

.visual-evidence-board.is-palm .visual-line-symbol {
  width: 66px;
  height: 52px;
}

.visual-evidence-board.is-palm .visual-line-symbol i {
  width: 62px;
  height: 34px;
  transform: rotate(-24deg);
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(2) .visual-line-symbol i {
  transform: rotate(-8deg);
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(3) .visual-line-symbol i {
  transform: rotate(10deg);
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(4) .visual-line-symbol i {
  transform: rotate(24deg);
}

.visual-evidence-board.is-face .visual-evidence-map {
  min-height: 142px;
  gap: 0;
  padding-block: 10px 18px;
}

.visual-evidence-board.is-face .visual-evidence-map::before {
  left: 50%;
  top: 50%;
  right: auto;
  bottom: auto;
  width: 96px;
  height: 122px;
  border: 1px solid rgba(255, 231, 174, .14);
  border-radius: 48% 48% 43% 43%;
  background:
    linear-gradient(180deg, transparent 0 34%, rgba(255, 231, 174, .1) 34% calc(34% + 1px), transparent calc(34% + 1px) 60%, rgba(255, 231, 174, .08) 60% calc(60% + 1px), transparent calc(60% + 1px)),
    radial-gradient(ellipse at 50% 72%, rgba(255, 231, 174, .04), transparent 58%);
  transform: translate(-50%, -50%);
}

.visual-evidence-board.is-face .visual-evidence-node {
  margin-inline: -4px;
  transform: translateY(-7px);
}

.visual-evidence-board.is-face .visual-evidence-node:nth-child(3n+2) {
  transform: translateY(0);
}

.visual-evidence-board.is-face .visual-evidence-node:nth-child(3n) {
  transform: translateY(7px);
}

.visual-face-symbol i {
  position: absolute;
  left: 50%;
  width: 25px;
  height: 8px;
  border-top: 2px solid rgba(255, 231, 174, .74);
  border-radius: 50%;
  transform: translateX(-50%);
}

.visual-face-symbol.is-forehead i { top: 13px; }
.visual-face-symbol.is-eyes i { top: 24px; }
.visual-face-symbol.is-nose i {
  top: 30px;
  width: 8px;
  height: 13px;
  border-top: 0;
  border-left: 2px solid rgba(255, 231, 174, .72);
  border-radius: 0 0 0 50%;
}
.visual-face-symbol.is-mouth i { top: 39px; }
.visual-face-symbol.is-jaw i {
  top: 45px;
  width: 28px;
  height: 10px;
  border-top: 0;
  border-bottom: 2px solid rgba(255, 231, 174, .74);
}

/* Stronger object maps for final-result evidence. Text stays in hover/focus/click popovers. */
.visual-aspect-symbol {
  width: 58px;
  height: 28px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.visual-aspect-symbol i {
  width: 52px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(202, 224, 255, .74), transparent);
  box-shadow: 0 0 14px rgba(202, 224, 255, .2);
  transform: rotate(18deg);
}

.visual-aspect-symbol b {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 7px;
  height: 7px;
  overflow: hidden;
  border: 1px solid rgba(255, 231, 174, .5);
  border-radius: 50%;
  color: transparent;
  background: rgba(255, 231, 174, .2);
  transform: translate(-50%, -50%);
}

.visual-evidence-board.is-astrology .visual-aspect-symbol {
  color: rgba(202, 224, 255, .74);
}

.visual-evidence-board.is-saju .visual-evidence-map {
  min-height: 158px;
  display: grid;
  grid-template-columns: repeat(5, minmax(34px, 48px));
  grid-auto-rows: minmax(58px, auto);
  align-content: center;
  justify-content: center;
  gap: 2px clamp(6px, 1.2vw, 14px);
}

.visual-evidence-board.is-saju .visual-evidence-map::before {
  inset: auto;
  left: 50%;
  top: 62%;
  width: 154px;
  height: 72px;
  border: 1px solid rgba(255, 231, 174, .12);
  border-radius: 50%;
  box-shadow:
    inset 0 0 0 18px rgba(255, 231, 174, .018),
    inset 0 0 0 34px rgba(255, 231, 174, .01);
  transform: translate(-50%, -50%);
}

.visual-evidence-board.is-saju .visual-evidence-map::after {
  top: 62%;
}

.visual-evidence-board.is-saju .visual-evidence-node {
  transform: none !important;
}

.visual-evidence-board.is-saju .visual-evidence-node.is-pillar {
  grid-row: 1;
  align-self: end;
}

.visual-evidence-board.is-saju .visual-evidence-node.is-element {
  grid-row: 2;
  align-self: start;
}

.visual-evidence-board.is-saju .visual-pillar-symbol {
  width: 36px;
  height: 72px;
  border: 0;
}

.visual-evidence-board.is-saju .visual-pillar-symbol::before,
.visual-evidence-board.is-saju .visual-pillar-symbol::after {
  inset-block: 10px;
  background: linear-gradient(transparent, rgba(255, 231, 174, .46), transparent);
}

.visual-evidence-board.is-saju .visual-pillar-symbol b::before,
.visual-evidence-board.is-saju .visual-pillar-symbol b::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 36px;
  height: 1px;
  background: rgba(255, 231, 174, .42);
  transform: translateX(-50%);
}

.visual-evidence-board.is-saju .visual-pillar-symbol b::before {
  top: 5px;
}

.visual-evidence-board.is-saju .visual-pillar-symbol b::after {
  bottom: 5px;
}

.visual-evidence-board.is-saju .visual-element-symbol {
  background:
    radial-gradient(circle, rgba(255, 231, 174, .2), rgba(255, 231, 174, .02) 68%),
    conic-gradient(from 0deg, rgba(255, 231, 174, .18), transparent 34%, rgba(255, 231, 174, .12), transparent 70%);
}

.visual-evidence-board.is-astrology .visual-evidence-map {
  min-height: 166px;
}

.visual-evidence-board.is-astrology .visual-evidence-node {
  transform: rotate(var(--evidence-angle, 0deg)) translateY(-64px) rotate(var(--evidence-counter-angle, 0deg));
}

.visual-evidence-board.is-astrology .visual-evidence-node.is-aspect {
  z-index: 9;
  transform: rotate(calc(var(--evidence-angle, 0deg) * .72)) translateY(-7px) rotate(calc(var(--evidence-counter-angle, 0deg) * .72));
}

.visual-evidence-board.is-astrology .visual-evidence-node.is-aspect summary {
  width: 68px;
  height: 32px;
}

.visual-evidence-board.is-astrology .visual-planet-symbol {
  background:
    radial-gradient(circle at 48% 42%, rgba(255, 247, 216, .28), rgba(202, 224, 255, .08) 42%, transparent 70%),
    rgba(255, 255, 255, .012);
}

.visual-evidence-board.is-palm .visual-evidence-map {
  min-height: 152px;
  display: block;
}

.visual-evidence-board.is-palm .visual-evidence-map::before {
  width: 118px;
  height: 138px;
}

.visual-evidence-board.is-palm .visual-evidence-map::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 28px;
  z-index: -1;
  width: 84px;
  height: 52px;
  border-radius: 46px 46px 20px 20px;
  background:
    linear-gradient(90deg, rgba(255, 231, 174, .12) 0 1px, transparent 1px 18px, rgba(255, 231, 174, .12) 18px 19px, transparent 19px 36px, rgba(255, 231, 174, .12) 36px 37px, transparent 37px 54px, rgba(255, 231, 174, .12) 54px 55px, transparent 55px),
    radial-gradient(ellipse at 50% 100%, rgba(255, 231, 174, .04), transparent 70%);
  transform: translateX(-50%);
  pointer-events: none;
}

.visual-evidence-board.is-palm .visual-evidence-node {
  position: absolute;
  left: 50%;
  top: 50%;
  margin: 0;
  transform: translate(-52%, -52%) rotate(-26deg) !important;
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(2) {
  transform: translate(-36%, -78%) rotate(-8deg) !important;
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(3) {
  transform: translate(-70%, -18%) rotate(12deg) !important;
}

.visual-evidence-board.is-palm .visual-evidence-node:nth-child(4) {
  transform: translate(-12%, -18%) rotate(26deg) !important;
}

.visual-evidence-board.is-face .visual-evidence-map {
  min-height: 152px;
  display: block;
}

.visual-evidence-board.is-face .visual-evidence-map::before {
  width: 104px;
  height: 130px;
}

.visual-evidence-board.is-face .visual-evidence-map::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: -1;
  width: 76px;
  height: 1px;
  background: rgba(255, 231, 174, .12);
  box-shadow: 0 -30px 0 rgba(255, 231, 174, .09), 0 30px 0 rgba(255, 231, 174, .08);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.visual-evidence-board.is-face .visual-evidence-node {
  position: absolute;
  left: 50%;
  top: 50%;
  margin: 0;
  transform: translate(-50%, -105%) !important;
}

.visual-evidence-board.is-face .visual-evidence-node:nth-child(2) {
  transform: translate(-86%, -50%) !important;
}

.visual-evidence-board.is-face .visual-evidence-node:nth-child(3) {
  transform: translate(-14%, -48%) !important;
}

.visual-evidence-board.is-face .visual-evidence-node:nth-child(4) {
  transform: translate(-50%, 8%) !important;
}

.visual-evidence-board.is-face .visual-evidence-node:nth-child(5) {
  transform: translate(-50%, 52%) !important;
}

.result-actions {
  display: grid;
  grid-template-columns: .9fr .8fr 1.1fr;
  gap: 8px;
}

.ghost-button,
.gold-button {
  min-height: 46px;
  padding: 0 14px;
}

.ghost-button {
  background: rgba(255, 255, 255, .052);
}

.gold-button {
  border-color: rgba(255, 239, 198, .28);
  color: var(--ink);
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  box-shadow: 0 14px 34px rgba(0, 0, 0, .22), inset 0 1px rgba(255, 255, 255, .44);
}

.ghost-button:hover,
.gold-button:hover {
  filter: brightness(1.04);
}

#makeReadingButton.is-loading {
  position: relative;
  padding-right: 38px;
}

#makeReadingButton.is-loading::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 14px;
  aspect-ratio: 1;
  border: 2px solid rgba(12, 10, 10, .28);
  border-top-color: rgba(12, 10, 10, .84);
  border-radius: 999px;
  transform: translateY(-50%);
  animation: readingOrbitTurn .72s linear infinite;
}

#saveReadingButton.is-saving {
  color: var(--accent-2);
  border-color: rgba(255, 231, 174, .22);
  animation: saveButtonPulse 1s ease-in-out infinite;
}

#saveReadingButton.is-saved {
  position: relative;
  color: var(--accent-2);
  border-color: transparent;
  background: transparent !important;
  box-shadow: none !important;
}

#saveReadingButton.is-saved::after {
  content: "";
  position: absolute;
  inset: -5px;
  border: 1px solid rgba(255, 231, 174, .22);
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  animation: savedSealPulse .9s ease both;
}

.ghost-button:disabled,
.gold-button:disabled,
.topic-button:disabled,
.mode-button:disabled,
.pool-card:disabled {
  cursor: not-allowed;
  opacity: .52;
}

.reading-status {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 28px;
  margin-top: 12px;
  padding: 0 11px 0 8px;
  border: 1px solid rgba(255, 231, 174, .22);
  border-radius: 999px;
  color: var(--accent-2);
  font-size: .74rem;
  font-weight: 950;
  animation: savedSealSettle .42s ease both;
}

.reading-status::before {
  content: "";
  width: 16px;
  aspect-ratio: 1;
  border-radius: 999px;
  background:
    radial-gradient(circle, rgba(255, 231, 174, .92), rgba(255, 231, 174, .3) 46%, transparent 48%),
    conic-gradient(from 0deg, rgba(255, 231, 174, .9), transparent 24%, rgba(255, 231, 174, .78), transparent 58%, rgba(255, 231, 174, .9));
  box-shadow: 0 0 18px rgba(255, 231, 174, .2);
}

.reading-error-state {
  display: grid;
  gap: 10px;
  animation: readingFinalIn .45s ease both;
}

.reading-error-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 195, 160, .34);
  border-radius: 999px;
  color: #ffe0d0;
  font-size: .7rem;
  font-weight: 950;
  letter-spacing: 0;
  background: rgba(72, 30, 22, .18);
  box-shadow: 0 0 24px rgba(255, 142, 97, .12);
}

.reading-error-state h3 {
  margin-bottom: 0;
}

.reading-error {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #ffe0d0;
  line-height: 1.58;
  word-break: keep-all;
}

.reading-error-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.reading-error-actions span {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 1px solid rgba(255, 231, 174, .14);
  border-radius: 999px;
  color: var(--muted);
  font-size: .64rem;
  font-weight: 900;
}

.reading-error-refresh {
  justify-self: start;
  min-height: 32px;
  padding-inline: 10px;
}

.orientation-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 21px;
  padding: 0 7px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  color: var(--accent-2);
  background: rgba(0, 0, 0, .18);
  font-size: .68rem;
  font-weight: 950;
}

.system-status {
  display: grid;
  gap: 9px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, .1);
}

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

.status-line strong {
  color: var(--soft);
  font-size: .82rem;
  font-weight: 950;
}

.status-line button {
  min-height: 30px;
  padding: 0 9px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 7px;
  background: rgba(255, 255, 255, .05);
  color: var(--accent-2);
  font-size: .72rem;
  font-weight: 900;
}

.status-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.status-chip {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 999px;
  font-size: .68rem;
  font-weight: 950;
}

.status-chip.is-ok {
  color: #e6ffd3;
  background: rgba(54, 91, 54, .28);
  border-color: rgba(204, 255, 190, .18);
}

.status-chip.is-warn {
  color: #ffe2bf;
  background: rgba(105, 67, 32, .28);
  border-color: rgba(255, 218, 171, .2);
}

.system-status p {
  margin: 0;
  color: var(--muted);
  font-size: .74rem;
  line-height: 1.45;
  word-break: keep-all;
}

.setup-details {
  display: grid;
  gap: 6px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.setup-details summary {
  cursor: pointer;
  color: rgba(255, 231, 174, .72);
  font-size: .7rem;
  font-weight: 950;
  list-style-position: inside;
}

.setup-details p {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.setup-details code {
  padding: 2px 5px;
  border: 1px solid rgba(255, 231, 174, .13);
  border-radius: 5px;
  color: var(--accent-2);
  background: rgba(0, 0, 0, .18);
  font-size: .68rem;
}

body[data-service="tarot"] .system-status {
  gap: 5px;
  padding-top: 8px;
  opacity: .72;
}

body[data-service="tarot"] .status-line strong {
  color: var(--muted);
  font-size: .7rem;
}

body[data-service="tarot"] .status-line button {
  min-height: 24px;
  padding-inline: 7px;
  font-size: .62rem;
}

body[data-service="tarot"] .status-chips {
  gap: 4px;
  max-height: 22px;
  overflow: hidden;
}

body[data-service="tarot"] .status-chip {
  min-height: 19px;
  padding-inline: 6px;
  font-size: .58rem;
}

body[data-service="tarot"] .system-status p {
  display: -webkit-box;
  overflow: hidden;
  font-size: .64rem;
  line-height: 1.25;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.saved-drawer {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 470px);
}

.saved-drawer[hidden] {
  display: none;
}

.saved-backdrop {
  border: 0;
  background: rgba(0, 0, 0, .44);
  cursor: pointer;
}

.saved-panel {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 16px;
  padding: 22px;
  border-radius: 0;
  border-left: 1px solid rgba(255, 231, 174, .09);
  border-right: 0;
  border-top: 0;
  border-bottom: 0;
  background: rgba(13, 10, 14, .84);
  overflow: hidden;
}

.saved-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.saved-head h2 {
  margin-top: 7px;
  font-size: 1.72rem;
}

.saved-close {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: 8px;
  background: rgba(255, 255, 255, .055);
  color: var(--accent-2);
  font-weight: 900;
}

.saved-list {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow: auto;
  padding-right: 2px;
}

.saved-item {
  position: relative;
  isolation: isolate;
  display: grid;
  gap: 8px;
  padding: 2px 0 16px;
  border-bottom: 1px solid rgba(255, 231, 174, .1);
  background: transparent;
  animation: readingTokenIn .42s ease both;
}

.saved-item.is-fresh-saved::before {
  content: "";
  position: absolute;
  inset: -4px -2px 0 -12px;
  z-index: -1;
  border-left: 2px solid rgba(255, 231, 174, .36);
  background:
    linear-gradient(90deg, rgba(255, 231, 174, .12), rgba(255, 231, 174, 0) 58%),
    radial-gradient(ellipse at 24% 18%, rgba(255, 231, 174, .18), rgba(255, 231, 174, 0) 62%);
  opacity: 0;
  pointer-events: none;
  animation: savedItemArchiveGlow 1.18s ease both;
}

.saved-item.is-fresh-saved .saved-mini-card {
  animation-name: savedMiniCardFresh;
  animation-duration: .72s;
  animation-timing-function: cubic-bezier(.18, .8, .22, 1);
  animation-fill-mode: both;
  animation-delay: calc(var(--saved-i, 0) * 55ms + 120ms);
}

.saved-item:nth-child(2) { animation-delay: 60ms; }
.saved-item:nth-child(3) { animation-delay: 120ms; }
.saved-item:nth-child(4) { animation-delay: 180ms; }
.saved-item:nth-child(5) { animation-delay: 240ms; }

.saved-item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.saved-item strong,
.saved-item small,
.saved-item p {
  display: block;
}

.saved-item strong {
  color: var(--text);
  font-size: .94rem;
  line-height: 1.38;
}

.saved-item small {
  color: var(--muted);
  font-size: .68rem;
  line-height: 1.34;
}

.saved-item p {
  color: rgba(255, 248, 234, .72);
  font-size: .76rem;
  line-height: 1.5;
  word-break: keep-all;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.saved-summary {
  display: none !important;
}

.saved-item:hover .saved-summary,
.saved-item:focus-within .saved-summary {
  display: -webkit-box !important;
  opacity: .86;
}

.saved-question {
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--text);
  font-size: .94rem;
  font-weight: 900;
  line-height: 1.38;
  word-break: keep-all;
}

.saved-item-meta {
  margin-top: -3px;
  color: rgba(255, 248, 234, .54);
  font-size: .68rem;
  font-weight: 850;
  line-height: 1.34;
  word-break: keep-all;
}

.saved-card-mini-strip {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  min-height: 64px;
  overflow: visible;
  padding: 5px 0 2px;
}

.saved-mini-card {
  position: relative;
  width: 42px;
  aspect-ratio: 2 / 3;
  flex: 0 0 auto;
  display: block;
  transform: translateY(calc((var(--saved-i, 0) % 2) * -3px)) rotate(var(--saved-r, 0deg));
  transform-origin: 50% 92%;
  filter: drop-shadow(0 9px 12px rgba(0, 0, 0, .28));
  animation: readingCardResultIn .46s ease both;
  animation-delay: calc(var(--saved-i, 0) * 45ms);
}

.saved-mini-card i {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 231, 174, .22);
  border-radius: 4px;
  background-color: rgba(0, 0, 0, .22);
  background-position: center;
  background-size: cover;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
}

.saved-mini-card i::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 244, 204, .28), transparent 42%),
    linear-gradient(145deg, rgba(255, 255, 255, .14), transparent 40% 72%, rgba(0, 0, 0, .12));
  pointer-events: none;
}

.saved-mini-card.is-reversed i {
  transform: rotate(180deg);
}

.saved-mini-card b {
  position: absolute;
  right: -5px;
  bottom: -5px;
  min-width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .24);
  border-radius: 999px;
  background: rgba(7, 6, 8, .86);
  color: var(--accent-2);
  font-size: .52rem;
  font-weight: 950;
  line-height: 1;
}

.saved-item-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 8px;
}

.saved-action {
  min-height: 34px;
  min-width: 34px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: color-mix(in srgb, var(--soft) 76%, transparent);
  font-size: .72rem;
  font-weight: 900;
}

.saved-action.is-primary {
  color: rgba(255, 231, 174, .86);
  background: transparent;
}

.saved-action.is-primary:hover {
  color: var(--accent-2);
  background: transparent;
}

.saved-action.is-danger {
  color: var(--muted);
  border-color: transparent;
  background: transparent;
}

.saved-action.is-danger:hover {
  color: var(--text);
  border-color: transparent;
  background: transparent;
}

.saved-empty {
  min-height: 220px;
  display: grid;
  place-items: center;
  padding: 22px;
  color: var(--muted);
  font-weight: 900;
  text-align: center;
  line-height: 1.55;
  word-break: keep-all;
}

@media (max-width: 1220px) {
  .experience-grid {
    grid-template-columns: 1fr;
  }

  .service-rail,
  .studio,
  .result-panel {
    height: auto;
    min-height: auto;
    overflow: visible;
  }

  .service-rail {
    grid-template-rows: auto auto;
  }

  .service-list {
    grid-template-columns: repeat(6, minmax(150px, 1fr));
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .service-button {
    min-width: 150px;
  }

  .result-panel {
    grid-template-columns: minmax(0, 1fr) 310px;
    grid-template-rows: auto minmax(0, 1fr) auto;
  }

  .result-head,
  .reading-copy {
    grid-column: 1;
  }

  .evidence-stack,
  .result-actions {
    grid-column: 2;
  }
}

@media (max-width: 820px) {
  .app-shell {
    width: min(100% - 22px, 1500px);
    padding-top: 14px;
  }

  .topbar {
    align-items: center;
  }

  .topbar-actions {
    width: auto;
    justify-content: flex-end;
    gap: 8px;
  }

  .topbar-link,
  .topbar-status {
    flex: 0 0 auto;
    justify-content: center;
  }

  body[data-service="tarot"] .topbar {
    min-height: 0;
    gap: 8px;
  }

  body[data-service="tarot"] .topbar-actions {
    justify-content: flex-end;
  }

  body[data-service="tarot"] .topbar-link {
    flex: 0 0 auto;
    min-height: 34px;
    padding-inline: 10px;
    font-size: .76rem;
  }

  body[data-service="tarot"] .audio-toggle {
    min-width: 68px;
    padding-inline: 8px;
  }

  body[data-service="tarot"] .topbar-status {
    display: none;
  }

  body[data-service="tarot"] .tarot-progress {
    gap: 2px;
    padding-inline: 0;
  }

  body[data-service="tarot"] .tarot-progress::before,
  body[data-service="tarot"] .tarot-progress::after {
    left: 10px;
    right: 10px;
  }

  body[data-service="tarot"] .tarot-progress-step i {
    width: 16px;
  }

  body[data-service="tarot"] .tarot-progress-step b {
    font-size: .5rem;
  }

  h1 {
    font-size: 1.24rem;
  }

  h2 {
    font-size: 1.78rem;
  }

  .service-rail,
  .studio,
  .result-panel {
    padding: 14px;
  }

  .service-list {
    grid-template-columns: repeat(6, minmax(132px, 1fr));
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 4px;
  }

  .service-button {
    min-width: 132px;
    min-height: 70px;
  }

  .service-button small {
    font-size: .72rem;
  }

  body[data-service="tarot"] .service-rail {
    gap: 8px;
    padding-block: 0;
  }

  body[data-service="tarot"] .rail-copy {
    display: none;
  }

  body[data-service="tarot"] .service-list {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0 0 3px;
    scrollbar-width: none;
  }

  body[data-service="tarot"] .service-list::-webkit-scrollbar {
    display: none;
  }

  body[data-service="tarot"] .service-button {
    min-width: 44px;
    min-height: 42px;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 0;
    padding: 5px;
  }

  body[data-service="tarot"] .service-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    font-size: .76rem;
  }

  body[data-service="tarot"] .service-button strong,
  body[data-service="tarot"] .service-button small {
    display: none;
  }

  .studio-head,
  .stage-split,
  .saju-layout,
  .palm-layout,
  .face-layout,
  .astro-layout,
  .result-panel {
    grid-template-columns: 1fr;
  }

  .studio-head {
    display: grid;
  }

  body[data-service="tarot"] .studio {
    gap: 10px;
  }

  body[data-service="tarot"] .studio-head {
    display: flex;
    align-items: end;
  }

  body[data-service="tarot"] .studio-head h2 {
    font-size: 1.28rem;
  }

  body[data-service="tarot"] .selection-count {
    min-width: 58px;
    min-height: 34px;
    padding: 0;
    border-bottom: 0;
  }

  body[data-service="tarot"] .selection-count strong {
    font-size: 1.42rem;
  }

  .selection-count {
    min-height: 58px;
    display: flex;
    justify-content: center;
    gap: 8px;
  }

  .visual-canvas,
  .option-canvas {
    min-height: 360px;
  }

  .side-panel {
    height: 340px;
    min-height: 260px;
  }

  .tarot-deck-panel {
    height: 360px;
  }

  .tarot-ritual,
  .tarot-deck-surface .tarot-step-copy {
    grid-template-columns: 1fr;
  }

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

  .tarot-question small {
    grid-column: auto;
  }

  .tarot-ritual-actions,
  .tarot-deck-actions {
    justify-content: stretch;
  }

  .tarot-ritual-actions > *,
  .tarot-deck-actions > * {
    flex: 1 1 140px;
  }

  .tarot-arc-shell {
    min-height: 248px;
  }

  .tarot-back-card {
    width: 80px;
  }

  .tarot-deck-surface.is-compact {
    grid-template-columns: 1fr;
  }

  .tarot-setting-group {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .tarot-setting-group > span {
    padding-top: 0;
  }

  .tarot-mini-grid {
    grid-template-columns: repeat(auto-fill, minmax(64px, 1fr));
  }

  .option-grid,
  .pillar-board {
    grid-template-columns: 1fr;
  }

  .room-table {
    grid-template-columns: 1fr;
    grid-template-rows: none;
  }

  .card-spread,
  .card-spread.is-spread-1,
  .card-spread.is-spread-3,
  .card-spread.is-spread-7 {
    min-height: auto;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: auto;
    gap: 8px;
  }

  .tarot-slot,
  .tarot-slot:nth-child(1),
  .tarot-slot:nth-child(2),
  .tarot-slot:nth-child(3),
  .tarot-slot:nth-child(4),
  .tarot-slot:nth-child(5),
  .tarot-slot:nth-child(6),
  .tarot-slot:nth-child(7) {
    grid-column: auto;
    grid-row: auto;
    transform: none;
  }

  .card-spread.is-spread-3 .tarot-slot:nth-child(1),
  .card-spread.is-spread-3 .tarot-slot:nth-child(2),
  .card-spread.is-spread-3 .tarot-slot:nth-child(3),
  .card-spread.is-spread-7 .tarot-slot:nth-child(1),
  .card-spread.is-spread-7 .tarot-slot:nth-child(2),
  .card-spread.is-spread-7 .tarot-slot:nth-child(3),
  .card-spread.is-spread-7 .tarot-slot:nth-child(4),
  .card-spread.is-spread-7 .tarot-slot:nth-child(5),
  .card-spread.is-spread-7 .tarot-slot:nth-child(6),
  .card-spread.is-spread-7 .tarot-slot:nth-child(7) {
    grid-column: auto;
    grid-row: auto;
    transform: none;
  }

  .card-spread.is-spread-7::after {
    display: none;
  }

  .tarot-canvas.is-drawing .card-spread.is-spread-7 {
    margin-top: 0;
  }

  .card-spread.is-spread-1 {
    width: min(268px, 100%);
    grid-template-columns: minmax(0, 1fr);
  }

  .card-spread.is-spread-3 {
    width: min(358px, 100%);
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .card-spread.is-spread-7 {
    width: min(366px, 100%);
    grid-template-columns: repeat(6, minmax(0, 1fr));
    grid-auto-rows: 156px;
    gap: 8px 6px;
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(1) {
    grid-column: 2 / span 2;
    grid-row: 1;
    transform: rotate(-2deg) translateY(2px);
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(2) {
    grid-column: 4 / span 2;
    grid-row: 1;
    transform: rotate(2deg) translateY(2px);
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(3) {
    grid-column: 1 / span 2;
    grid-row: 2;
    transform: rotate(-3deg);
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(4) {
    grid-column: 3 / span 2;
    grid-row: 2;
    transform: translateY(-4px);
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(5) {
    grid-column: 5 / span 2;
    grid-row: 2;
    transform: rotate(3deg);
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(6) {
    grid-column: 2 / span 2;
    grid-row: 3;
    transform: rotate(2deg) translateY(-2px);
  }

  .card-spread.is-spread-7 .tarot-slot:nth-child(7) {
    grid-column: 4 / span 2;
    grid-row: 3;
    transform: rotate(-2deg) translateY(-2px);
  }

  .hand-map,
  .face-map,
  .astro-map {
    width: min(100%, 360px);
  }

  .zone-button,
  .astro-choice {
    min-width: 104px;
  }

  .result-head,
  .reading-copy,
  .evidence-stack,
  .result-actions {
    grid-column: auto;
  }

  .result-actions {
    grid-template-columns: 1fr;
  }

  .saved-drawer {
    grid-template-columns: 1fr;
  }

  .saved-backdrop {
    display: none;
  }

  .saved-panel {
    min-height: 100vh;
    border-left: 0;
  }
}

@media (max-width: 460px) {
  .topic-button,
  .mode-button,
  .chip-button {
    flex: 1 1 calc(50% - 8px);
    padding-inline: 8px;
  }

  .palm-canvas,
  .face-canvas,
  .astro-canvas,
  .tarot-canvas,
  .room-canvas {
    padding: 12px;
  }

  .tarot-settings-summary {
    min-height: 34px;
  }

  .tarot-settings-summary span {
    font-size: .76rem;
  }

  .tarot-settings .topic-button,
  .tarot-settings .mode-button {
    flex: 0 0 auto;
    min-height: 32px;
    min-width: 38px;
    padding-inline: 7px;
  }

  .tarot-offer {
    top: 16px;
    width: min(220px, 62%);
    min-height: 210px;
  }

  .offer-hands {
    width: 170px;
    height: 60px;
  }

  .offer-hands span {
    width: 58px;
    height: 102px;
  }

  .offer-deck {
    width: 88px;
  }

  .tarot-cut-piles {
    gap: 8px;
  }

  .tarot-cut-pile {
    min-height: min(360px, 46vh);
    padding: 8px;
  }

  .cut-stack {
    width: min(30vw, 168px);
  }

  .tarot-arc-shell {
    min-height: 230px;
  }

  .tarot-back-card {
    width: 74px;
  }

  .tarot-table-state {
    left: 12px;
    top: 12px;
    padding: 7px 9px;
  }

  .tarot-canvas-reset {
    top: 12px;
    right: 12px;
    min-height: 32px;
    padding-inline: 10px;
    font-size: .7rem;
  }

  .tarot-slot {
    min-height: 170px;
  }

  .tarot-card-image,
  .tarot-slot.is-filled .tarot-card-image {
    width: min(92px, 100%);
  }

  .tarot-slot-caption {
    width: min(100px, 100%);
  }

  .card-spread.is-spread-1 .tarot-slot {
    min-height: 270px;
  }

.card-spread.is-spread-1 .tarot-slot.is-filled .tarot-card-image,
  .card-spread.is-spread-1 .tarot-slot-caption {
    width: min(172px, 100%);
  }

  .card-spread.is-spread-3 .tarot-slot {
    min-height: 190px;
  }

  .card-spread.is-spread-3 .tarot-slot.is-filled .tarot-card-image,
  .card-spread.is-spread-3 .tarot-slot-caption {
    width: min(106px, 100%);
  }

  .card-spread.is-spread-7 .tarot-slot {
    min-height: 152px;
  }

  .card-spread.is-spread-7 .tarot-slot.is-filled .tarot-card-image,
  .card-spread.is-spread-7 .tarot-slot-caption {
    width: min(84px, 100%);
  }

  .card-spread.is-spread-7 .tarot-slot small {
    display: none;
  }

  .tarot-slot-caption {
    gap: 0;
  }

  .tarot-slot span {
    font-size: .5rem;
  }

  .tarot-slot strong {
    font-size: .68rem;
    line-height: 1.08;
    -webkit-line-clamp: 1;
  }

  .tarot-slot small {
    margin-top: 1px;
    font-size: .5rem;
    line-height: 1.08;
    -webkit-line-clamp: 1;
  }

  .tarot-english-label {
    display: none;
  }

  .zone-button,
  .astro-choice {
    min-width: 96px;
    min-height: 52px;
    padding: 7px 8px;
  }

  .zone-button small,
  .astro-choice small {
    display: none;
  }

  .saved-panel {
    padding: 16px;
  }

  .saved-item-actions {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .001ms !important;
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
  }
}

body[data-service="home"] {
  --bg-image: url("./assets/bg-home-oracle-room.png");
  --bg-position: center center;
  --accent: #d8b76f;
  --accent-2: #fff1c3;
  --accent-deep: #3b2f20;
  --motif-opacity: .08;
}

body[data-service="home"] .scene-bg::after {
  background:
    radial-gradient(circle at 50% 44%, transparent 0 18%, rgba(255, 231, 168, .36) 18.4% 18.7%, transparent 19.1%),
    radial-gradient(circle at 50% 44%, transparent 0 31%, rgba(255, 231, 168, .18) 31.4% 31.65%, transparent 32%);
}

body[data-service="home"] .scene-bg {
  filter: none;
}

[hidden] {
  display: none !important;
}

.category-home {
  min-height: 0;
  height: 100%;
  display: grid;
  align-content: center;
  gap: 28px;
  width: min(980px, 100%);
  margin-inline: auto;
  padding-block: clamp(32px, 8vh, 96px);
}

.category-home-head {
  display: grid;
  gap: 10px;
  max-width: 620px;
}

.category-home h1 {
  max-width: 10em;
  font-size: clamp(2.1rem, 5vw, 4.8rem);
  line-height: 1.02;
}

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

.category-card {
  min-height: 132px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 14px;
  align-items: end;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .035);
  color: var(--text);
  text-align: left;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.category-card:hover,
.category-card:focus-visible,
.category-card.is-active {
  border-color: color-mix(in srgb, var(--accent) 70%, white 30%);
  background: rgba(255, 231, 174, .07);
  transform: translateY(-1px);
}

.category-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-bottom: 1px solid rgba(255, 231, 174, .3);
  color: var(--accent-2);
  font-size: 1.05rem;
  font-weight: 950;
}

.category-card strong,
.category-card small {
  display: block;
}

.category-card strong {
  font-size: 1.16rem;
}

.category-card small {
  margin-top: 7px;
  color: var(--muted);
  font-size: .82rem;
  line-height: 1.35;
}

.service-workspace {
  min-height: 0;
  height: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  align-content: start;
}

.service-workspace.has-result {
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  align-items: start;
}

.service-workspace .studio,
.service-workspace .result-panel {
  min-height: 0;
  padding: 0;
}

.service-workspace .studio {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
}

.service-workspace .studio-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid rgba(255, 231, 174, .13);
  padding-bottom: 12px;
}

.service-workspace.is-result-focus .studio-head,
.service-workspace.is-tarot-deck-theater .studio-head {
  display: none;
}

.service-workspace.is-result-focus .studio,
.service-workspace.is-tarot-deck-theater .studio {
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
}

.service-workspace.has-result.is-result-focus {
  grid-template-columns: minmax(320px, min(900px, 100%));
  justify-content: center;
}

.service-workspace.is-result-focus .studio {
  display: none;
}

.service-workspace.is-result-focus .result-panel {
  justify-self: center;
  width: min(900px, 100%);
}

body[data-tarot-view="deck-theater"] .app-shell {
  width: 100%;
}

body[data-tarot-view="deck-theater"] .scene-bg::after {
  opacity: 0;
}

body[data-tarot-view="deck-theater"] .topbar {
  width: min(1500px, calc(100% - 32px));
  margin-inline: auto;
}

.service-workspace.is-tarot-deck-theater {
  width: 100%;
  min-height: calc(100vh - 90px);
  margin-inline: 0;
}

.service-workspace.is-tarot-deck-theater .service-stage,
.service-workspace.is-tarot-deck-theater .tool-layout,
.service-workspace.is-tarot-deck-theater .stage-split {
  min-height: calc(100vh - 98px);
}

.service-workspace.is-tarot-deck-theater .tarot-canvas {
  min-height: calc(100vh - 98px);
  overflow: visible;
  padding-inline: 0;
}

.service-workspace.is-tarot-deck-theater .tarot-deck-surface {
  position: relative;
  display: block;
  min-height: calc(100vh - 98px);
  gap: 0;
}

.service-workspace.is-tarot-deck-theater .tarot-deck-surface .tarot-step-copy {
  display: none;
}

.service-workspace.is-tarot-deck-theater .tarot-deck-actions {
  position: absolute;
  left: 50%;
  bottom: clamp(14px, 3vh, 30px);
  z-index: 30;
  width: auto;
  max-width: calc(100vw - 32px);
  margin-inline: 0;
  justify-content: center;
  pointer-events: none;
  transform: translateX(-50%);
}

.service-workspace.is-tarot-deck-theater .tarot-deck-actions > button:not(:disabled) {
  pointer-events: auto;
}

body[data-tarot-view="deck-theater"] .tarot-deck-actions {
  pointer-events: none;
}

body[data-tarot-view="deck-theater"] .tarot-deck-actions > button:not(:disabled) {
  pointer-events: auto;
}

.service-workspace.is-tarot-deck-theater .tarot-arc-shell {
  width: 100%;
  min-height: calc(100vh - 98px);
  margin-inline: 0;
  overflow: hidden;
  clip-path: none;
}

.service-workspace.is-tarot-deck-theater .tarot-arc-shell::before {
  display: none;
}

.service-workspace.is-tarot-deck-theater .tarot-arc-shell::after {
  display: none;
}

.service-workspace.is-tarot-deck-theater .tarot-arc-stage::before {
  width: min(520px, 78vw);
}

.studio-title {
  min-width: 0;
  flex: 1 1 auto;
}

.back-home {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding-inline: 12px;
  border: 1px solid rgba(255, 255, 255, .11);
  border-radius: 8px;
  color: var(--soft);
  background: rgba(255, 255, 255, .03);
  font-size: .78rem;
  font-weight: 900;
  text-decoration: none;
}

.back-home:hover {
  border-color: rgba(255, 231, 174, .24);
  color: var(--accent-2);
}

.service-workspace.is-minimal-workspace .selection-count {
  display: none;
}

.service-workspace .result-panel {
  height: auto;
  overflow: visible;
  grid-template-rows: auto auto auto auto;
  gap: 14px;
}

.service-workspace .reading-copy {
  max-height: calc(100vh - 260px);
}

.service-workspace .result-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

#makeReadingButton[hidden] {
  display: none !important;
}

.tarot-stage-actions {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 10px 0 2px;
}

.tarot-stage-actions .gold-button {
  min-width: min(260px, 100%);
}

.tarot-ready-actions {
  padding-top: 2px;
}

.tarot-ready-actions .gold-button,
.tarot-ready-actions .ghost-button {
  min-width: min(210px, 100%);
}

body[data-service="tarot"] .tarot-arc-shell {
  min-height: clamp(390px, 54vh, 540px);
}

body[data-service="tarot"] .tarot-back-card {
  width: clamp(132px, 13vw, 184px);
}

.minimal-tool {
  grid-template-rows: minmax(0, 1fr);
}

.minimal-tool.saju-tool {
  grid-template-rows: auto minmax(0, 1fr);
}

.astrology-tool {
  display: grid;
  gap: 14px;
}

.astrology-stage {
  min-height: min(640px, calc(100vh - 190px));
}

.astrology-observatory {
  min-height: min(650px, calc(100vh - 190px));
  display: grid;
  grid-template-columns: minmax(250px, 360px) minmax(0, 1fr);
  gap: clamp(18px, 4vw, 54px);
  align-items: center;
}

.astrology-input-stack,
.astrology-chart-stage,
.astrology-reading-stage,
.astrology-empty-stage {
  display: grid;
  gap: 14px;
  align-content: start;
}

.astrology-instrument-stage {
  min-width: 0;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 12px;
}

.astrology-mode-row .mode-button {
  flex: 1 1 96px;
}

.astrology-phase-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  opacity: .72;
}

.astro-phase {
  min-height: 24px;
  display: block;
  padding: 0 0 5px;
  border: 0;
  border-bottom: 1px solid rgba(221, 241, 255, .09);
  border-radius: 0;
  color: var(--muted);
  background: transparent;
  font-size: .7rem;
  font-weight: 850;
}

.astro-phase b {
  display: none;
}

.astro-phase.is-active {
  border-bottom-color: rgba(255, 231, 174, .48);
  color: var(--accent-2);
  background: transparent;
}

.astro-phase.is-complete {
  color: color-mix(in srgb, var(--soft) 78%, transparent);
}

.astrology-calibration-readout {
  width: min(100%, 430px);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
  padding-block: 10px 0;
  border-top: 1px solid rgba(221, 241, 255, .12);
  color: var(--muted);
  font-size: .68rem;
  font-weight: 900;
}

.astrology-calibration-readout > span {
  grid-column: 1 / -1;
  color: var(--accent-2);
  letter-spacing: .02em;
}

.astrology-calibration-readout b {
  min-width: 0;
  display: grid;
  gap: 3px;
  color: color-mix(in srgb, var(--soft) 82%, transparent);
}

.astrology-calibration-readout em {
  overflow: hidden;
  color: var(--text);
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mvp-layout {
  min-height: min(640px, calc(100vh - 190px));
  display: grid;
  grid-template-columns: minmax(230px, 320px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.mvp-form,
.mvp-upload {
  display: grid;
  gap: 12px;
  align-content: start;
}

.mvp-form label,
.mvp-upload {
  display: grid;
  gap: 8px;
  padding-block: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  color: var(--soft);
  font-size: .82rem;
  font-weight: 900;
}

.mvp-form input,
.mvp-form select,
.mvp-upload input {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  background: rgba(7, 6, 8, .28);
  color: var(--text);
  padding-inline: 12px;
}

.mvp-form select {
  appearance: none;
}

.astrology-check-row {
  min-height: 42px;
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 10px !important;
  padding-block: 10px !important;
}

.astrology-check-row input {
  width: 18px;
  min-height: 18px;
  flex: 0 0 18px;
  accent-color: var(--accent);
}

.astrology-field-hint {
  color: color-mix(in srgb, var(--muted) 88%, transparent);
  font-size: .72rem;
  font-weight: 800;
  line-height: 1.42;
}

.astrology-coordinate-details {
  display: grid;
  gap: 10px;
  padding-block: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  color: var(--soft);
  font-size: .82rem;
  font-weight: 900;
}

.astrology-coordinate-details summary {
  min-height: 28px;
  cursor: pointer;
  color: var(--accent-2);
}

.astrology-coordinate-details label {
  padding-block: 0;
  border-bottom: 0;
}

.mvp-canvas {
  min-height: min(620px, calc(100vh - 190px));
  overflow: visible;
}

.palm-mvp {
  grid-template-columns: minmax(210px, 280px) minmax(0, 1fr);
  gap: 18px;
}

.palm-workflow {
  display: grid;
  gap: 12px;
  align-content: start;
}

.palm-stage-shell {
  min-width: 0;
}

.palm-input-stage,
.palm-review-stage,
.face-review-stage {
  min-height: min(540px, calc(100vh - 190px));
  display: grid;
  gap: 16px;
  align-content: center;
}

.palm-input-stage {
  align-content: start;
}

.palm-step-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  opacity: .72;
}

.palm-step {
  min-width: 0;
  min-height: 22px;
  display: grid;
  place-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  color: var(--muted);
  font-size: .66rem;
  font-weight: 850;
}

.palm-step b {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.palm-step.is-done {
  color: color-mix(in srgb, var(--soft) 78%, transparent);
  border-bottom-color: rgba(255, 255, 255, .12);
}

.palm-step.is-active {
  color: var(--accent-2);
  border-bottom-color: rgba(255, 231, 174, .5);
}

.palm-input {
  position: relative;
  min-height: 118px;
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 8px 16px;
  align-items: center;
  padding: 8px 0 16px;
  border-bottom: 1px solid rgba(255, 231, 174, .09) !important;
}

.palm-input input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.palm-input strong {
  display: block;
  color: var(--text);
  font-size: .98rem;
  font-weight: 950;
  line-height: 1.18;
}

.palm-mode-row,
.palm-workflow-actions,
.palm-status-options,
.palm-stage-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.palm-mode-row .mode-button {
  flex: 1 1 86px;
  min-height: 34px;
  padding-inline: 8px;
}

.palm-workflow-actions .palm-tool-button {
  flex: 1 1 42px;
}

.palm-file-button {
  position: relative;
  overflow: hidden;
}

.palm-file-button input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.palm-canvas.mvp-canvas {
  display: grid;
  gap: 10px;
  justify-items: center;
  align-content: start;
  padding: 0;
  min-height: min(650px, calc(100vh - 174px));
}

.palm-image-stage {
  position: relative;
  width: min(100%, 620px);
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .012)),
    rgba(7, 6, 8, .34);
}

.palm-photo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: var(--palm-fit, contain);
  transform: rotate(var(--palm-rotate, 0deg));
  transform-origin: center;
  background: rgba(0, 0, 0, .22);
}

.palm-empty-photo {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  gap: 6px;
  align-content: center;
  color: var(--muted);
  background:
    linear-gradient(rgba(8, 7, 8, .42), rgba(8, 7, 8, .54)),
    url("./assets/bg-palm-hand.png") center / cover;
  text-align: center;
}

.palm-empty-photo strong {
  color: var(--soft);
  font-size: .96rem;
}

.palm-empty-photo span {
  max-width: 220px;
  font-size: .78rem;
  line-height: 1.45;
  word-break: keep-all;
}

.palm-overlay,
.palm-line-tags {
  position: absolute;
  inset: 0;
}

.palm-overlay {
  pointer-events: none;
}

.palm-guide-line {
  pointer-events: auto;
  cursor: pointer;
}

.palm-hit-path,
.palm-visual-path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.palm-hit-path {
  stroke: transparent;
  stroke-width: 22;
}

.palm-visual-path {
  stroke: rgba(255, 240, 204, .62);
  stroke-width: 1.6;
  stroke-dasharray: 4 4;
  filter: drop-shadow(0 0 6px rgba(0, 0, 0, .52));
}

.palm-guide-line.is-observed .palm-visual-path {
  stroke: color-mix(in srgb, var(--accent) 76%, white 24%);
  stroke-width: 2.2;
  stroke-dasharray: none;
}

.palm-guide-line.is-soft .palm-visual-path {
  stroke: rgba(190, 222, 255, .86);
  stroke-width: 1.8;
  stroke-dasharray: 2 5;
}

.palm-guide-line.is-exclude .palm-visual-path,
.palm-guide-line.is-pending .palm-visual-path {
  opacity: .48;
}

.palm-guide-line.is-active .palm-visual-path {
  filter: drop-shadow(0 0 10px rgba(255, 225, 170, .5));
}

.palm-line-tags {
  pointer-events: none;
}

.palm-line-tag {
  position: absolute;
  min-width: 88px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .16);
  border-radius: 0;
  color: var(--soft);
  background: transparent;
  font: inherit;
  text-align: left;
  pointer-events: auto;
}

.palm-line-tag span {
  width: 30px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--bg);
  background: color-mix(in srgb, var(--accent) 76%, white 24%);
  font-size: .76rem;
  font-weight: 950;
}

.palm-line-tag strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .72rem;
  font-weight: 950;
}

.palm-line-tag.is-active {
  border-color: color-mix(in srgb, var(--accent) 72%, white 28%);
  color: var(--accent-2);
  background: transparent;
}

.palm-line-tag.is-soft span {
  background: #bfe2ff;
}

.palm-line-tag.is-exclude,
.palm-line-tag.is-pending {
  opacity: .72;
}

.palm-tag-heart { left: 8%; top: 15%; }
.palm-tag-head { right: 6%; top: 39%; }
.palm-tag-life { left: 8%; bottom: 18%; }
.palm-tag-fate { right: 8%; bottom: 28%; }

.palm-status-bar {
  width: min(100%, 620px);
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding-block: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.palm-status-bar > div:first-child {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.palm-status-bar span {
  color: var(--accent-2);
  font-size: .76rem;
  font-weight: 950;
}

.palm-status-bar strong {
  overflow: hidden;
  color: var(--muted);
  font-size: .76rem;
  font-weight: 850;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.palm-status-button {
  min-height: 42px;
  min-width: 52px;
  padding-inline: 6px;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
  border-radius: 0;
  color: var(--soft);
  background: transparent;
  font: inherit;
  font-size: .74rem;
  font-weight: 950;
}

.palm-status-button.is-active,
.palm-status-button:hover {
  border-color: color-mix(in srgb, var(--accent) 66%, white 34%);
  color: var(--accent-2);
}

.palm-observation-strip {
  width: min(100%, 620px);
  min-height: 34px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 8px;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 850;
}

.palm-observation-strip > span {
  min-width: 0;
  flex: 1 1 170px;
  line-height: 1.35;
  word-break: keep-all;
}

.palm-observation-strip > div {
  display: flex;
  flex: 1 1 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.palm-observation-chip {
  min-height: 25px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
  border-radius: 0;
  background: transparent;
  color: var(--soft);
}

.palm-observation-chip small {
  color: var(--accent-2);
  font-size: .62rem;
  font-weight: 950;
}

.palm-observation-chip.is-soft small {
  color: #bfe2ff;
}

.palm-stage-actions {
  width: min(100%, 620px);
  justify-content: flex-end;
}

.palm-review-list,
.face-review-list {
  width: min(100%, 620px);
  display: grid;
  gap: 8px;
}

.palm-review-item,
.face-review-item {
  min-height: 48px;
  display: grid;
  gap: 4px;
  padding-block: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
}

.palm-review-item b,
.face-review-item b {
  color: var(--soft);
  font-size: .9rem;
}

.palm-review-item small,
.face-review-item small {
  color: var(--muted);
  font-size: .76rem;
  line-height: 1.45;
}

.palm-review-map,
.face-review-map {
  width: min(100%, 620px);
  display: grid;
  justify-items: center;
  gap: 12px;
  padding-block: 4px 8px;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.palm-review-hand {
  width: min(220px, 58vw);
  aspect-ratio: 100 / 130;
  overflow: visible;
  filter: drop-shadow(0 18px 26px rgba(0, 0, 0, .28));
}

.palm-review-outline {
  fill: rgba(255, 231, 174, .028);
  stroke: rgba(255, 231, 174, .28);
  stroke-width: 1.15;
}

.palm-review-line {
  fill: none;
  opacity: .18;
  stroke: rgba(255, 231, 174, .34);
  stroke-width: 1.35;
  stroke-dasharray: 2.5 5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.palm-review-line.is-selected {
  opacity: 1;
  stroke: var(--accent-2);
  stroke-width: 2.35;
  stroke-dasharray: none;
  filter: drop-shadow(0 0 7px rgba(255, 224, 156, .34));
}

.palm-review-line.is-soft.is-selected {
  stroke: #bfe2ff;
  stroke-dasharray: 3 4;
}

.palm-review-nodes,
.face-review-nodes {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 12px;
}

.palm-review-node,
.face-review-node {
  min-width: 52px;
  display: grid;
  justify-items: center;
  gap: 3px;
  padding: 0 0 5px;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
  color: color-mix(in srgb, var(--soft) 82%, transparent);
  outline: 0;
}

.palm-review-node:focus-visible,
.face-review-node:focus-visible {
  outline: 1px solid rgba(255, 231, 174, .42);
  outline-offset: 4px;
}

.palm-review-node b,
.face-review-node b {
  width: 28px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--bg);
  background: color-mix(in srgb, var(--accent) 76%, white 24%);
  font-size: .68rem;
  font-weight: 950;
}

.palm-review-node small,
.face-review-node small {
  color: color-mix(in srgb, var(--soft) 82%, transparent);
  font-size: .62rem;
  font-weight: 950;
}

.palm-review-node.is-soft b {
  background: #bfe2ff;
}

.face-review-mask {
  position: relative;
  width: min(210px, 54vw);
  aspect-ratio: 82 / 108;
  border: 1px solid rgba(255, 231, 174, .26);
  border-radius: 48% 48% 42% 42%;
  background:
    radial-gradient(circle at 50% 38%, rgba(255, 231, 174, .06), transparent 36%),
    linear-gradient(180deg, rgba(255, 231, 174, .03), transparent 54%);
  filter: drop-shadow(0 18px 26px rgba(0, 0, 0, .3));
}

.face-review-mask::before,
.face-review-mask::after,
.face-review-third {
  content: "";
  position: absolute;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 231, 174, .28), transparent);
}

.face-review-mask::before { top: 36%; }
.face-review-mask::after { top: 62%; }
.face-review-third { opacity: .28; }
.face-review-third.is-upper { top: 22%; }
.face-review-third.is-middle { top: 49%; }
.face-review-third.is-lower { top: 76%; }

.face-review-region {
  position: absolute;
  width: 42%;
  height: 12%;
  display: grid;
  place-items: center;
  opacity: .16;
  transform: translate(-50%, -50%);
}

.face-review-region i {
  width: 100%;
  height: 100%;
  border: 1px solid rgba(255, 231, 174, .26);
  border-radius: 999px;
  background: rgba(255, 231, 174, .035);
}

.face-review-region.is-observed {
  opacity: 1;
}

.face-review-region.is-observed i {
  border-color: rgba(255, 231, 174, .7);
  background: radial-gradient(circle, rgba(255, 231, 174, .18), rgba(255, 231, 174, .02) 72%);
  filter: drop-shadow(0 0 12px rgba(255, 224, 156, .28));
}

.face-review-region.is-forehead { left: 50%; top: 22%; width: 46%; }
.face-review-region.is-eyes { left: 50%; top: 39%; width: 52%; height: 9%; }
.face-review-region.is-nose { left: 50%; top: 52%; width: 24%; height: 16%; }
.face-review-region.is-mouth { left: 50%; top: 66%; width: 34%; height: 9%; }
.face-review-region.is-jaw { left: 50%; top: 80%; width: 48%; height: 14%; }

.palm-review-map.is-compact .palm-review-hand,
.face-review-map.is-compact .face-review-mask {
  width: min(180px, 48vw);
}

.palm-read-button {
  min-width: min(180px, 100%);
}

.palm-draft-state p,
.face-draft-state p,
body[data-service="palm"] .reading-paragraphs p {
  word-break: keep-all;
}

body[data-service="face"] .topic-row {
  display: none;
}

.face-tool {
  min-width: 0;
  display: grid;
  gap: 16px;
}

.face-step-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  opacity: .72;
}

.face-entry {
  min-height: min(620px, calc(100vh - 190px));
  display: grid;
  place-items: center;
  gap: 18px;
  align-content: center;
  padding: clamp(10px, 4vw, 34px);
  text-align: center;
}

.face-local-note span,
.face-inline-hint span,
.face-observation-sheet header span {
  color: var(--accent-2);
  font-size: .76rem;
  font-weight: 950;
}

.face-entry-actions,
.face-action-row,
.face-choice-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.face-input-action,
.face-action-button {
  position: relative;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border-radius: 8px;
  overflow: hidden;
  font-weight: 950;
}

.face-input-action input,
.face-action-button input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.face-stage {
  min-width: 0;
  display: grid;
  gap: 12px;
  justify-items: center;
}

.face-stage-main {
  min-width: 0;
  width: 100%;
  display: grid;
  justify-items: center;
  gap: 10px;
}

.face-canvas.mvp-canvas {
  width: 100%;
  min-height: 0;
  display: grid;
  justify-items: center;
  align-content: start;
  padding: 0;
  overflow: visible;
}

.face-image-shell {
  position: relative;
  width: min(100%, 540px, calc((100vh - 248px) * .8));
  min-width: 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .015)),
    rgba(8, 6, 8, .46);
}

.face-photo,
.face-photo-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.face-photo {
  display: block;
  object-fit: contain;
  background: rgba(0, 0, 0, .24);
}

.face-photo.is-mesh {
  background: #0b0814;
}

/* 자동 측정 보조(MediaPipe) — 배경 패널 없이 인라인 텍스트 + 토글 버튼만. */
.face-vision-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 8px 2px 0;
}
.face-vision-bar.is-loading { opacity: .7; }
.face-vision-status {
  font-size: .78rem;
  color: var(--muted);
  letter-spacing: .02em;
}
/* 촬영 품질 안내 — 배경 패널 없이 인라인 텍스트(비차단 권유). */
.face-capture-hint,
.palm-capture-hint {
  width: min(100%, 620px);
  margin: 8px 2px 0;
  font-size: .78rem;
  line-height: 1.45;
  color: var(--accent-2);
  letter-spacing: .01em;
  word-break: keep-all;
}
.face-measure {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin: 2px 0 10px;
  font-size: .84rem;
  color: var(--text);
}
.face-measure span {
  font-size: .7rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: .04em;
}
.face-measure small { color: var(--muted); font-size: .7rem; }
.face-mesh-toggle.is-active { color: var(--accent-2); }

.face-photo-placeholder {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  padding: 20px;
  color: var(--muted);
  text-align: center;
  background:
    linear-gradient(rgba(8, 6, 8, .42), rgba(8, 6, 8, .58)),
    url("./assets/bg-face-gwansang.png") center / cover;
}

.face-photo-placeholder strong {
  color: var(--soft);
  font-size: .96rem;
}

.face-photo-placeholder span {
  max-width: 220px;
  font-size: .78rem;
  line-height: 1.45;
}

.face-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.face-frame-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.face-frame-overlay::before,
.face-frame-overlay::after {
  content: "";
  position: absolute;
  left: 14%;
  right: 14%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 231, 174, .48), transparent);
}

.face-frame-overlay::before {
  top: 36%;
}

.face-frame-overlay::after {
  top: 62%;
}

.face-third {
  position: absolute;
  right: 8%;
  min-width: 38px;
  color: rgba(255, 231, 174, .72);
  font-size: .62rem;
  font-weight: 950;
  text-align: right;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .48);
}

.face-third-upper { top: 22%; }
.face-third-middle { top: 47%; }
.face-third-lower { top: 72%; }

.face-hotspot {
  position: absolute;
  min-width: 84px;
  min-height: 36px;
  display: inline-grid;
  grid-template-columns: auto auto;
  align-items: center;
  gap: 6px;
  padding: 4px 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .2);
  border-radius: 0;
  color: var(--soft);
  background: transparent;
  font: inherit;
  font-size: .72rem;
  font-weight: 950;
  pointer-events: auto;
  transform: translate(-50%, -50%);
  text-shadow: 0 2px 8px rgba(0, 0, 0, .62);
}

.face-hotspot small {
  color: var(--muted);
  font-size: .62rem;
  font-weight: 950;
}

.face-hotspot:hover,
.face-hotspot:focus-visible,
.face-hotspot.is-active,
.face-hotspot.is-observed {
  border-color: color-mix(in srgb, var(--accent) 68%, white 32%);
  color: var(--accent-2);
  background: transparent;
}

.face-hotspot.is-observed small {
  color: var(--accent-2);
}

.face-canvas.has-restored-observations .face-hotspot:not(.is-observed) {
  display: none;
}

.face-canvas.has-restored-observations .face-hotspot {
  background: transparent;
}

.face-hotspot-forehead { left: 50%; top: 22%; }
.face-hotspot-eyes { left: 50%; top: 39%; }
.face-hotspot-nose { left: 50%; top: 52%; }
.face-hotspot-mouth { left: 50%; top: 66%; }
.face-hotspot-jaw { left: 50%; top: 80%; }

.face-observation-sheet,
.face-inline-hint,
.face-stage-actions {
  width: min(100%, 620px);
}

.face-observation-sheet {
  display: grid;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 231, 174, .1);
}

.face-observation-sheet header {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 8px;
  align-items: center;
}

.face-observation-sheet header span {
  grid-column: 1;
}

.face-observation-sheet header strong {
  grid-column: 1;
  font-size: .98rem;
}

.face-sheet-close {
  grid-column: 2;
  grid-row: 1 / span 2;
}

.face-choice-row {
  justify-content: flex-start;
}

.face-choice-row .chip-button {
  min-height: 34px;
  padding-inline: 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
  border-radius: 0;
  background: transparent;
  font-size: .74rem;
}

.face-note {
  display: grid;
  gap: 6px;
  color: var(--soft);
  font-size: .76rem;
  font-weight: 900;
}

.face-note textarea {
  width: 100%;
  min-height: 62px;
  resize: vertical;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  color: var(--text);
  background: rgba(7, 6, 8, .28);
  padding: 10px 12px;
  font: inherit;
  line-height: 1.45;
}

.face-inline-hint,
.face-stage-actions {
  display: grid;
  gap: 8px;
  padding-block: 8px;
  border-top: 1px solid rgba(255, 255, 255, .1);
}

.face-inline-hint strong,
.face-local-note strong {
  color: var(--soft);
  font-size: .82rem;
  line-height: 1.42;
  word-break: keep-all;
}

.face-stage-actions {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.face-local-note {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.face-local-note strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.face-action-row {
  justify-content: flex-end;
}

.face-read-button {
  min-width: min(180px, 100%);
}

body[data-service="face"] .reading-paragraphs p {
  word-break: keep-all;
}

.mvp-canvas .pillar-card.is-placeholder {
  background: rgba(255, 255, 255, .025);
  color: color-mix(in srgb, var(--soft) 76%, transparent);
}

.mvp-canvas .element-board.is-empty .element-track {
  background: rgba(255, 255, 255, .055);
}

.mvp-canvas .hand-map,
.mvp-canvas .face-map,
.mvp-canvas .astro-map {
  max-width: 100%;
}

.minimal-tool .zone-button,
.minimal-tool .astro-choice {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.astro-canvas.mvp-canvas {
  grid-template-columns: minmax(260px, 420px) minmax(260px, 1fr);
  align-items: start;
  align-content: start;
  gap: 22px;
  overflow: hidden;
}

.astrology-chart-view {
  min-height: 0;
}

.astrology-instrument-stage .astro-canvas.mvp-canvas,
.astrology-empty-stage .astro-canvas.mvp-canvas {
  width: 100%;
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 12px;
  padding: 0;
  overflow: hidden;
}

.astrology-chart-empty {
  align-content: center;
}

.astrology-chart-status {
  max-width: 280px;
  display: grid;
  gap: 8px;
  color: var(--soft);
  font-size: .82rem;
  font-weight: 900;
  line-height: 1.45;
}

.astrology-chart-status strong {
  color: var(--text);
  font-size: 1rem;
}

.astro-marker {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 5;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .24);
  border-radius: 999px;
  color: var(--accent-2);
  background: rgba(8, 7, 8, .42);
  font-size: .72rem;
  font-weight: 950;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .24);
  transform:
    rotate(var(--astro-angle, calc(var(--astro-i) * 60deg)))
    translateY(calc(var(--astro-ring, 150px) * -1))
    rotate(var(--astro-counter-angle, calc(var(--astro-i) * -60deg)))
    translate(-50%, -50%);
}

.astro-marker.is-chart-point {
  width: 38px;
  height: 38px;
  border-color: rgba(255, 231, 174, .34);
  background: rgba(12, 9, 8, .66);
  box-shadow: 0 10px 20px rgba(0, 0, 0, .3), 0 0 16px rgba(255, 231, 174, .12);
  cursor: pointer;
}

.astro-marker.is-focused {
  border-color: rgba(255, 231, 174, .88);
  color: #fff2be;
  background: rgba(45, 32, 16, .78);
  box-shadow:
    0 12px 24px rgba(0, 0, 0, .38),
    0 0 0 1px rgba(255, 231, 174, .18),
    0 0 26px rgba(255, 218, 126, .28);
}

.astro-marker.is-focused::after {
  content: "";
  position: absolute;
  inset: -8px;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 999px;
  opacity: .8;
  animation: astroFocusPulse 2.8s ease-in-out infinite;
}

.astro-map.is-ready .astro-marker {
  border-color: rgba(255, 231, 174, .3);
  filter: brightness(1.08);
}

.astro-map.is-calculating .astro-marker {
  filter: brightness(1.2);
}

.astro-map.has-selection .astro-marker {
  filter: brightness(1.12);
}

.astro-angle-marker {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 6;
  min-width: 44px;
  min-height: 24px;
  display: grid;
  place-items: center;
  padding-inline: 8px;
  border: 1px solid rgba(255, 231, 174, .28);
  border-radius: 999px;
  color: var(--bg);
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  font-size: .68rem;
  font-weight: 950;
  transform:
    rotate(var(--astro-angle))
    translateY(-160px)
    rotate(var(--astro-counter-angle))
    translate(-50%, -50%);
}

.astro-angle-marker.is-mc {
  background: linear-gradient(180deg, rgba(221, 241, 255, .92), rgba(154, 185, 238, .86));
}

.planet-list {
  width: min(100%, 280px);
  display: grid;
  gap: 8px;
  align-content: center;
}

.astrology-position-list {
  width: 100%;
  align-content: start;
}

.planet-list div,
.astro-point-row {
  width: 100%;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 54px;
  gap: 9px;
  align-items: center;
  padding-block: 8px;
  border: 0;
  border-bottom: 1px solid rgba(221, 241, 255, .13);
  color: var(--soft);
  background: transparent;
  font: inherit;
  font-size: .78rem;
  text-align: left;
}

.astro-point-row {
  cursor: pointer;
}

.astro-point-row.is-active,
.astro-point-row:not(.is-static):hover {
  color: var(--text);
  border-bottom-color: color-mix(in srgb, var(--accent) 62%, rgba(221, 241, 255, .2) 38%);
}

.astro-point-row.is-static {
  cursor: default;
}

.planet-list span {
  color: var(--accent-2);
  font-weight: 950;
}

.planet-list strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.planet-list small {
  color: var(--muted);
  font-weight: 900;
  text-align: right;
}

.astrology-chart-panels {
  width: 100%;
  display: grid;
  gap: 12px;
  align-content: start;
  align-self: start;
}

.astrology-focus-panel {
  display: grid;
  gap: 11px;
  padding-block: 2px 12px;
  border-bottom: 1px solid rgba(221, 241, 255, .13);
}

.astrology-focus-head {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.astrology-focus-head > span {
  width: 42px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .42);
  border-radius: 999px;
  color: var(--accent-2);
  background: rgba(7, 6, 8, .32);
  font-size: 1.05rem;
  font-weight: 950;
}

.astrology-focus-head strong {
  display: block;
  color: var(--text);
  font-size: .96rem;
  font-weight: 950;
}

.astrology-focus-head small {
  color: var(--soft);
  font-size: .73rem;
  font-weight: 850;
}

.astrology-focus-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}

.astrology-focus-facts div {
  min-width: 0;
  display: grid;
  gap: 3px;
  padding-bottom: 7px;
  border-bottom: 1px solid rgba(221, 241, 255, .1);
}

.astrology-focus-facts dt {
  color: var(--muted);
  font-size: .65rem;
  font-weight: 900;
}

.astrology-focus-facts dd {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  color: var(--accent-2);
  font-size: .74rem;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.astrology-focus-aspects {
  display: grid;
  gap: 6px;
}

.astrology-focus-aspects button,
.astrology-note-list button {
  width: 100%;
  display: grid;
  gap: 2px;
  padding: 6px 0;
  border: 0;
  border-bottom: 1px solid rgba(221, 241, 255, .08);
  color: var(--soft);
  background: transparent;
  font: inherit;
  font-size: .74rem;
  font-weight: 850;
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
}

.astrology-focus-aspects button:hover,
.astrology-note-list button:hover {
  color: var(--text);
  border-bottom-color: rgba(255, 231, 174, .28);
}

.astrology-focus-aspects span {
  color: var(--accent-2);
  font-size: .62rem;
  font-weight: 950;
  text-transform: uppercase;
}

.astrology-focus-aspects strong {
  overflow: hidden;
  color: inherit;
  font-size: .76rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.astrology-note-list {
  display: grid;
  gap: 6px;
  padding-block: 4px 10px;
  border-bottom: 1px solid rgba(221, 241, 255, .12);
  color: var(--soft);
  font-size: .77rem;
  font-weight: 850;
  line-height: 1.4;
}

.astrology-note-list strong {
  color: var(--accent-2);
  font-size: .72rem;
  text-transform: uppercase;
}

.astrology-note-list.is-warning {
  color: color-mix(in srgb, var(--accent-2) 62%, var(--soft) 38%);
}

.astrology-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.astrology-selection-summary {
  min-height: 46px;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding-block: 6px;
  border: 0;
  border-bottom: 1px solid rgba(221, 241, 255, .12);
  border-radius: 0;
  color: var(--soft);
  background: transparent;
  font-size: .82rem;
  font-weight: 900;
}

.astrology-selection-summary span {
  color: var(--accent-2);
  font-weight: 950;
}

.astrology-selection-summary strong {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.astrology-read-button {
  min-width: min(230px, 100%);
}

.astrology-read-button.is-loading,
.astrology-calc-button.is-loading {
  position: relative;
  padding-right: 38px;
}

.astrology-read-button.is-loading::after,
.astrology-calc-button.is-loading::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 14px;
  aspect-ratio: 1;
  border: 2px solid rgba(12, 10, 10, .28);
  border-top-color: rgba(12, 10, 10, .84);
  border-radius: 999px;
  transform: translateY(-50%);
  animation: readingOrbitTurn .72s linear infinite;
}

@media (max-height: 760px) and (min-width: 721px) {
  .face-image-shell {
    width: min(100%, 430px, calc((100vh - 228px) * .8));
  }

  .face-entry {
    min-height: min(500px, calc(100vh - 170px));
  }
}

@media (max-width: 1100px) {
  .service-workspace.has-result,
  .mvp-layout,
  .astrology-observatory,
  .saju-stage-input,
  .saju-chart-stage,
  .saju-reading-stage {
    grid-template-columns: 1fr;
  }

  .saju-reference-board,
  .saju-chart-map {
    grid-template-columns: 1fr;
  }

  .service-workspace .reading-copy {
    max-height: none;
  }

  .astro-canvas.mvp-canvas {
    grid-template-columns: 1fr;
  }

  .astrology-instrument-stage {
    order: -1;
  }

  .face-stage-actions {
    grid-template-columns: 1fr;
  }

  .face-action-row {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .category-home {
    min-height: calc(100vh - 126px);
    gap: 20px;
    padding-block: 24px;
  }

  .category-home h1 {
    max-width: 9em;
    font-size: 2.35rem;
  }

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

  .category-card {
    min-height: 94px;
    align-items: center;
  }

  .service-workspace .studio-head {
    align-items: start;
  }

  .service-workspace .studio-head h2 {
    font-size: 1.5rem;
  }

  .back-home {
    min-width: 0;
    padding-inline: 10px;
  }

  body[data-service="tarot"] .tarot-arc-shell {
    min-height: 410px;
  }

  body[data-service="tarot"] .tarot-back-card {
    width: clamp(118px, 33vw, 136px);
  }

  .mvp-layout {
    gap: 16px;
  }

  .face-entry {
    min-height: calc(100vh - 190px);
    padding: 18px 4px;
  }

  .face-entry-actions,
  .face-action-row {
    width: 100%;
  }

  .face-input-action,
  .face-action-row > * {
    flex: 1 1 122px;
  }

  .face-image-shell {
    width: min(100%, calc(100vw - 44px));
  }

  .face-hotspot {
    min-width: 70px;
    min-height: 32px;
    gap: 4px;
    padding: 4px 7px;
    font-size: .66rem;
  }

  .face-hotspot small {
    font-size: .56rem;
  }

  .face-choice-row .chip-button {
    flex: 1 1 132px;
  }

  .saju-tool {
    gap: 14px;
  }

  .saju-stepper {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .saju-stepper strong {
    font-size: .62rem;
  }

  .saju-form-grid,
  .saju-assumption-list,
  .pillar-board,
  .saju-result-pillars,
  .saved-saju-mini-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .saju-assumption-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .saju-canvas {
    padding: 12px;
  }

  .saju-reference-board {
    min-height: 0;
    gap: 18px;
  }

  .saju-branch-wheel {
    width: min(100%, 330px);
  }

  .saju-branch-mark {
    width: 38px;
  }

  .saju-branch-mark b {
    font-size: 1.08rem;
  }

  .saju-branch-mark small {
    font-size: .52rem;
  }

  .saju-pillar-row {
    grid-template-columns: 44px repeat(4, minmax(0, 1fr));
  }

  .saju-pillar-row > * {
    padding: 8px 4px;
  }

  .saju-pillar-row > span {
    font-size: .62rem;
  }

  .saju-pillar-row strong,
  .saju-pillar-row i {
    font-size: .65rem;
  }

  .saju-pillar-row.is-ganji em {
    font-size: 1.55rem;
  }

  .saju-element-cycle {
    width: min(100%, 270px);
  }

  .saju-result-elements {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .saju-actions .icon-button {
    flex: 1 1 138px;
  }

  .mvp-canvas {
    min-height: 380px;
  }

  .astrology-stage,
  .astrology-observatory {
    min-height: 0;
  }

  .astrology-calibration-readout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .astrology-focus-facts {
    grid-template-columns: 1fr;
  }

  .astrology-focus-head {
    grid-template-columns: 40px minmax(0, 1fr);
  }

  .astrology-focus-head > span {
    width: 36px;
  }

  .planet-list small {
    white-space: normal;
  }

  .astro-marker {
    transform:
      rotate(var(--astro-angle, calc(var(--astro-i) * 60deg)))
      translateY(calc(var(--astro-ring-mobile, 118px) * -1))
      rotate(var(--astro-counter-angle, calc(var(--astro-i) * -60deg)))
      translate(-50%, -50%);
  }

  .astro-angle-marker {
    transform:
      rotate(var(--astro-angle))
      translateY(-128px)
      rotate(var(--astro-counter-angle))
      translate(-50%, -50%);
  }
}

.service-workspace.is-result-focus .studio-head,
.service-workspace.is-tarot-deck-theater .studio-head {
  display: none;
}

@media (max-width: 720px) {
  .service-workspace.is-tarot-deck-theater {
    min-height: calc(100vh - 82px);
  }

  .service-workspace.is-tarot-deck-theater .service-stage,
  .service-workspace.is-tarot-deck-theater .tool-layout,
  .service-workspace.is-tarot-deck-theater .stage-split,
  .service-workspace.is-tarot-deck-theater .tarot-canvas {
    min-height: calc(100vh - 90px);
  }

  .service-workspace.is-tarot-deck-theater .tarot-arc-shell {
    min-height: calc(100vh - 90px);
  }
}

/* Benchmark layout polish: category choice first, one tarot stage at a time. */
body[data-service="home"] .category-home {
  width: min(1120px, 100%);
  gap: clamp(22px, 4vh, 34px);
  padding-block: clamp(18px, 4vh, 46px);
}

body[data-service="home"] .category-home-head {
  max-width: 760px;
}

body[data-service="home"] .category-home h1 {
  max-width: 11em;
  font-size: clamp(2.25rem, 5.1vw, 4.55rem);
}

body[data-service="home"] .category-grid {
  grid-template-columns: minmax(320px, 1.18fr) repeat(2, minmax(0, .86fr));
  grid-auto-rows: minmax(108px, auto);
  gap: 12px;
}

.category-card.is-featured {
  min-height: 228px;
  grid-row: span 2;
  grid-template-columns: 1fr;
  align-content: end;
  gap: 18px;
  padding: clamp(20px, 3vw, 28px);
  border-color: rgba(255, 231, 174, .2);
  background:
    linear-gradient(180deg, rgba(255, 231, 174, .085), rgba(255, 255, 255, .025)),
    rgba(7, 6, 8, .12);
}

.category-card.is-featured .category-icon {
  width: 64px;
  height: 64px;
  border-bottom-color: rgba(255, 231, 174, .42);
  font-size: 1.38rem;
}

.category-card.is-featured strong {
  font-size: clamp(1.7rem, 2.8vw, 2.35rem);
  letter-spacing: 0;
}

.category-card.is-featured small {
  max-width: 19em;
  font-size: .94rem;
  line-height: 1.45;
}

.category-card.is-secondary {
  min-height: 108px;
  background: rgba(255, 255, 255, .028);
}

.category-card.is-secondary:not(:hover):not(:focus-visible):not(.is-active) {
  border-color: rgba(255, 255, 255, .09);
  color: color-mix(in srgb, var(--text) 88%, transparent);
}

.category-card.is-secondary:not(:hover):not(:focus-visible):not(.is-active) .category-icon,
.category-card.is-secondary:not(:hover):not(:focus-visible):not(.is-active) small {
  opacity: .76;
}

.category-card.is-archive {
  min-height: 76px;
  grid-column: 1 / -1;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
}

.category-card.is-archive .category-icon {
  width: 42px;
  height: 42px;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) {
  min-height: calc(100vh - 98px);
  gap: 8px;
}

body[data-service="tarot"]:not([data-tarot-view]) .app-shell {
  gap: 8px;
  padding-block: 14px 12px;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio {
  gap: 8px;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-head {
  min-height: 42px;
  align-items: center;
  padding-bottom: 0;
  border-bottom: 0;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-title .eyebrow {
  font-size: .64rem;
  opacity: .78;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-title h2 {
  font-size: clamp(1.58rem, 3vw, 2.55rem);
  line-height: .96;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .back-home {
  min-height: 32px;
  padding-inline: 11px;
  background: rgba(7, 6, 8, .16);
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .selection-count {
  min-width: auto;
  min-height: auto;
  display: flex;
  align-items: baseline;
  gap: 5px;
  padding: 0;
  border: 0;
  color: color-mix(in srgb, var(--soft) 72%, transparent);
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .selection-count strong {
  font-size: clamp(1.15rem, 2.7vw, 1.9rem);
  line-height: 1;
}

body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .selection-count span {
  font-size: .68rem;
}

body[data-service="tarot"] .tool-layout {
  gap: 8px;
}

body[data-service="tarot"] .tarot-settings {
  width: min(620px, 100%);
  justify-self: center;
}

body[data-service="tarot"] .tarot-settings-summary {
  min-height: 32px;
  justify-content: center;
  gap: 10px;
  padding: 0;
  border-bottom: 0;
}

body[data-service="tarot"] .tarot-settings-summary span {
  flex: 0 1 auto;
  max-width: min(70vw, 420px);
  color: color-mix(in srgb, var(--soft) 82%, transparent);
  font-size: .74rem;
  text-align: center;
}

body[data-service="tarot"] .tarot-settings-summary strong {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding-inline: 10px;
  border: 1px solid rgba(255, 231, 174, .14);
  border-radius: 999px;
  background: rgba(7, 6, 8, .15);
  color: color-mix(in srgb, var(--accent-2) 88%, transparent);
}

body[data-service="tarot"] .tarot-settings-panel {
  padding-top: 5px;
}

body[data-service="tarot"] .stage-split,
body[data-service="tarot"] .visual-canvas {
  min-height: clamp(470px, calc(100vh - 192px), 720px);
}

body[data-service="tarot"] .tarot-canvas {
  align-content: center;
  padding: clamp(14px, 2.2vw, 28px);
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question {
  align-content: end;
  justify-items: center;
  padding-block: clamp(24px, 8vh, 76px) clamp(34px, 9vh, 88px);
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-ritual {
  width: min(720px, calc(100% - 32px));
  grid-template-columns: 1fr;
  align-items: center;
  justify-items: center;
  gap: 14px;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question input {
  min-height: 52px;
  padding-inline: 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .44);
  border-radius: 0;
  background: transparent;
  caret-color: var(--accent-2);
  font-size: clamp(1.02rem, 2vw, 1.36rem);
  text-align: center;
  transition: border-bottom-color .16s ease;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question input:hover {
  border-bottom-color: rgba(255, 231, 174, .66);
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question {
  width: 100%;
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 8px;
  text-align: center;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question small {
  grid-column: auto;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-ritual-actions {
  justify-content: center;
  gap: 10px;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-start-button {
  flex: 0 0 auto;
  min-width: 156px;
  min-height: 42px;
  justify-content: center;
  padding-inline: 18px;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-ritual-actions > .icon-button.is-icon-only {
  flex: 0 0 42px;
  width: 42px;
  min-width: 42px;
  min-height: 42px;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-shuffle .tarot-shuffle-bridge,
body[data-service="tarot"] .tarot-canvas.tarot-stage-cut .tarot-cut,
body[data-service="tarot"] .tarot-canvas.tarot-stage-cutting .tarot-cut-recombine {
  min-height: clamp(560px, 72vh, 760px);
  align-content: center;
}

@media (max-width: 520px) {
  body[data-service="tarot"] .tarot-canvas.tarot-stage-shuffle .tarot-shuffle-bridge,
  body[data-service="tarot"] .tarot-canvas.tarot-stage-cut .tarot-cut,
  body[data-service="tarot"] .tarot-canvas.tarot-stage-cutting .tarot-cut-recombine {
    min-height: min(560px, 68vh);
  }

  .tarot-shuffle-deck {
    width: 100%;
    height: min(520px, 62vh);
  }

  .tarot-shuffle-card {
    width: min(58vw, 232px);
  }

  .tarot-recombine-stage {
    width: 100%;
    height: min(500px, 60vh);
  }

  .tarot-recombine-pile {
    width: min(56vw, 232px);
  }
}

body[data-service="tarot"] .service-workspace.is-result-focus .result-panel {
  width: min(780px, 100%);
}

body[data-service="tarot"] .service-workspace.is-final-result .system-status {
  display: none;
}

body[data-service="tarot"] .service-workspace.is-final-result .result-head {
  text-align: center;
}

body[data-service="tarot"] .service-workspace.is-final-result .reading-copy {
  max-height: calc(100vh - 222px);
  padding-right: 8px;
}

body[data-service="tarot"] .service-workspace.is-final-result .reading-card-token {
  min-height: 136px;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
}

body[data-service="tarot"] .service-workspace.is-final-result .reading-card-thumb {
  width: 88px;
  justify-self: center;
}

body[data-tarot-view="deck-theater"] .app-shell {
  width: 100%;
  padding-block: 0;
  gap: 0;
}

body[data-tarot-view="deck-theater"] {
  overflow-y: hidden;
}

body[data-tarot-view="deck-theater"] .topbar {
  display: none;
}

body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater,
body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .service-stage,
body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tool-layout,
body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .stage-split,
body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tarot-canvas {
  min-height: 100vh;
}

body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tarot-canvas {
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
  padding-block: 0;
}

body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tarot-deck-surface {
  min-height: 100vh;
  max-height: none;
}

body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tarot-arc-shell {
  min-height: 100vh;
}

body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tarot-canvas-reset {
  position: fixed;
  top: auto !important;
  right: auto !important;
  left: 16px;
  bottom: 16px;
  z-index: 32;
}

@media (max-width: 900px) {
  body[data-service="home"] .category-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .category-card.is-featured {
    grid-column: 1 / -1;
    grid-row: auto;
    min-height: 190px;
  }
}

@media (max-width: 720px) {
  body[data-service="home"] .category-home {
    width: 100%;
    min-height: calc(100vh - 102px);
    padding-block: 18px 28px;
  }

  body[data-service="home"] .category-home h1 {
    max-width: 9.8em;
    font-size: clamp(2.18rem, 12vw, 3.12rem);
  }

  body[data-service="home"] .category-grid {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .category-card.is-featured,
  .category-card.is-secondary,
  .category-card.is-archive {
    min-height: 96px;
    grid-column: auto;
    grid-template-columns: 50px minmax(0, 1fr);
    align-items: center;
    align-content: center;
    gap: 13px;
    padding: 14px;
  }

  .category-card.is-featured .category-icon {
    width: 50px;
    height: 50px;
    font-size: 1.08rem;
  }

  .category-card.is-featured strong {
    font-size: 1.26rem;
  }

  .category-card.is-featured small {
    font-size: .82rem;
  }

  body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) {
    min-height: calc(100vh - 88px);
  }

  body[data-service="tarot"]:not([data-tarot-view]) .app-shell {
    padding-block: 6px 0;
  }

  body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-head {
    min-height: 38px;
    gap: 9px;
  }

  body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-title {
    display: grid;
    gap: 0;
  }

  body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .studio-title h2 {
    font-size: 1.36rem;
  }

  body[data-service="tarot"] .service-workspace:not(.is-result-focus):not(.is-tarot-deck-theater) .selection-count {
    display: none;
  }

  body[data-service="tarot"] .stage-split,
  body[data-service="tarot"] .visual-canvas {
    min-height: calc(100vh - 196px);
  }

  body[data-service="tarot"] .tarot-settings-summary {
    justify-content: space-between;
  }

  body[data-service="tarot"] .tarot-settings-summary span {
    max-width: calc(100vw - 138px);
    text-align: left;
  }

  body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-ritual {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  body[data-service="tarot"] .service-workspace.is-result-focus .result-panel {
    width: 100%;
  }

  body[data-service="tarot"] .service-workspace.is-final-result .reading-copy {
    max-height: none;
  }

  body[data-service="tarot"] .service-workspace.is-final-result .reading-card-token {
    min-height: 116px;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 12px;
  }

  body[data-service="tarot"] .service-workspace.is-final-result .reading-card-thumb {
    width: 72px;
  }

  .astrology-actions {
    grid-template-columns: 1fr;
  }

  .astrology-phase-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .astro-phase {
    min-height: 20px;
  }

  .astrology-selection-summary strong {
    white-space: normal;
  }

  body[data-tarot-view="deck-theater"] .topbar {
    left: 10px;
    right: 10px;
    top: 10px;
  }

  body[data-tarot-view="deck-theater"] .service-workspace.is-tarot-deck-theater .tarot-canvas {
    padding-block: 0;
  }
}

/* Icon-first command controls. */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
  clip-path: inset(50%) !important;
}

.ui-icon {
  width: 1.08em;
  height: 1.08em;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.icon-button.is-icon-only {
  width: 42px;
  min-width: 42px;
  padding-inline: 0;
}

.icon-button.is-icon-only .ui-icon {
  font-size: 1.04rem;
}

.icon-button .button-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.icon-badge {
  position: absolute;
  right: -6px;
  top: -6px;
  min-width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  padding-inline: 5px;
  border: 1px solid rgba(255, 231, 174, .34);
  border-radius: 999px;
  background: rgba(7, 6, 8, .86);
  color: var(--accent-2);
  font-size: .58rem;
  font-weight: 950;
  line-height: 1;
}

.topbar-link.icon-button.is-icon-only,
.audio-toggle.icon-button.is-icon-only {
  flex: 0 0 40px;
  width: 40px;
  min-width: 40px;
  min-height: 40px;
  padding: 0;
}

body[data-service="home"] .topbar-link.icon-button.is-icon-only,
body[data-service="home"] .audio-toggle.icon-button.is-icon-only {
  width: 38px;
  min-width: 38px;
  min-height: 38px;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

body[data-service="home"] .topbar-link.icon-button.is-icon-only:hover,
body[data-service="home"] .topbar-link.icon-button.is-icon-only:focus-visible,
body[data-service="home"] .audio-toggle.icon-button.is-icon-only:hover,
body[data-service="home"] .audio-toggle.icon-button.is-icon-only:focus-visible {
  border-color: rgba(255, 231, 174, .26);
  background: rgba(255, 231, 174, .045);
}

@media (max-width: 820px) {
  body[data-service="home"] .topbar {
    min-height: 44px;
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }

  body[data-service="home"] .brand {
    min-width: 0;
    gap: 8px;
    font-size: .98rem;
  }

  body[data-service="home"] .brand-mark {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
  }

  body[data-service="home"] .topbar-actions {
    width: auto;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
    margin-left: auto;
    gap: 6px;
  }

  body[data-service="home"] .topbar-link,
  body[data-service="home"] .topbar-status {
    flex: 0 0 auto;
  }
}

.back-home.icon-button.is-icon-only,
.saved-close.icon-button.is-icon-only {
  width: 38px;
  min-width: 38px;
  min-height: 38px;
  padding: 0;
}

.ghost-button.icon-button.is-icon-only,
.gold-button.icon-button.is-icon-only {
  width: 46px;
  min-width: 46px;
  min-height: 46px;
  padding: 0;
}

.result-actions {
  grid-template-columns: repeat(3, minmax(46px, 54px));
  justify-content: center;
}

.tarot-ritual-actions .icon-button.is-icon-only,
.tarot-deck-actions .icon-button.is-icon-only,
.tarot-stage-actions .icon-button.is-icon-only {
  flex: 0 0 46px;
}

.tarot-settings-summary .settings-icon {
  width: 32px;
  min-width: 32px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.tarot-settings-summary .settings-icon .ui-icon {
  font-size: .94rem;
}

.tarot-canvas-reset.icon-button.is-icon-only {
  width: 36px;
  min-width: 36px;
  min-height: 36px;
  padding: 0;
}

.status-icon-button {
  width: 30px;
  min-width: 30px;
  min-height: 28px;
  padding: 0;
}

.status-icon-button .ui-icon {
  font-size: .78rem;
}

.saved-item-actions {
  justify-content: flex-start;
}

.saved-action.icon-button.is-icon-only {
  width: 34px;
  min-width: 34px;
  min-height: 34px;
  padding: 0;
}

.saved-action.icon-button.is-icon-only .ui-icon {
  font-size: .82rem;
}

@media (max-width: 720px) {
  .topbar-actions {
    gap: 8px;
  }

  .tarot-ritual-actions > .icon-button.is-icon-only,
  .tarot-deck-actions > .icon-button.is-icon-only {
    flex: 0 0 44px;
  }

  .result-actions {
    grid-template-columns: repeat(2, minmax(46px, 54px));
  }
}

/* Pentagon category selector. */
body[data-service="home"] .category-home {
  width: 100%;
  min-height: 0;
  height: 100%;
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
  gap: 0;
  padding-block: 0;
}

body[data-service="home"] .category-home-head {
  display: none;
}

body[data-service="home"] .category-home h1 {
  max-width: 8.4em;
  font-size: clamp(2.1rem, 4.2vw, 3.95rem);
  letter-spacing: 0;
}

body[data-service="home"] .category-grid {
  --category-orbit-size: min(620px, 72vw, calc(100dvh - 120px));
  position: relative;
  display: block;
  width: var(--category-orbit-size);
  height: var(--category-orbit-size);
  aspect-ratio: 1;
  min-height: 0;
  margin-inline: auto;
  overflow: visible;
  transform: translateY(clamp(-24px, -3vh, -10px));
}

.category-pentagon-lines {
  display: none;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}

.category-pentagon-lines polygon,
.category-pentagon-lines line,
.category-pentagon-lines circle {
  fill: none;
  stroke: rgba(255, 231, 174, .26);
  stroke-width: .5;
  vector-effect: non-scaling-stroke;
}

.category-pentagon-lines line {
  stroke: rgba(255, 231, 174, .17);
}

.category-pentagon-lines circle {
  fill: rgba(255, 231, 174, .5);
  stroke: rgba(255, 231, 174, .4);
  filter: drop-shadow(0 0 3px rgba(255, 231, 174, .6));
}

.category-symbol-card {
  --symbol-size: clamp(148px, 13.6vw, 198px);
  position: absolute;
  left: calc(var(--symbol-x) * 1%);
  top: calc(var(--symbol-y) * 1%);
  z-index: 2;
  width: var(--symbol-size);
  height: var(--symbol-size);
  min-height: 0;
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  align-content: center;
  gap: 7px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: color-mix(in srgb, var(--text) 88%, transparent);
  text-align: center;
  transform: translate(-50%, -50%);
  overflow: visible;
  transition: transform .18s ease, color .18s ease, filter .18s ease;
}

.category-card.category-symbol-card,
.category-card.category-symbol-card.is-featured,
.category-card.category-symbol-card.is-secondary {
  grid-template-columns: 1fr;
  align-items: center;
  align-content: center;
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.category-symbol-card::before {
  display: none;
}

.category-symbol-card:hover,
.category-symbol-card:focus-visible,
.category-symbol-card.is-active {
  border: 0;
  background: transparent;
  box-shadow: none;
  color: var(--accent-2);
  filter: brightness(1.08);
  transform: translate(-50%, -50%) translateY(-3px);
}

.category-symbol-card.is-disabled,
.category-symbol-card.is-disabled:hover,
.category-symbol-card.is-disabled:focus-visible {
  color: color-mix(in srgb, var(--soft) 34%, transparent);
  cursor: default;
  filter: none;
  transform: translate(-50%, -50%);
}

.category-symbol-card.is-disabled .category-symbol-shell,
.category-symbol-card.is-disabled:hover .category-symbol-shell,
.category-symbol-card.is-disabled:focus-visible .category-symbol-shell {
  opacity: .34;
  transform: none;
  filter: blur(1.2px) saturate(.55) brightness(.68);
}

.category-symbol-card.is-disabled .category-symbol-art {
  filter: grayscale(.65) brightness(.62) blur(.8px) drop-shadow(0 8px 16px rgba(0, 0, 0, .18));
}

.category-symbol-card:hover::before,
.category-symbol-card:focus-visible::before,
.category-symbol-card.is-active::before {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.category-symbol-card:focus-visible {
  outline: 0;
}

.category-symbol-card:focus-visible .category-symbol-shell {
  outline: 1px solid rgba(255, 231, 174, .68);
  outline-offset: 7px;
}

.category-symbol-shell {
  width: var(--symbol-size);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
  transition: transform .18s ease;
}

.category-symbol-card:hover .category-symbol-shell,
.category-symbol-card:focus-visible .category-symbol-shell,
.category-symbol-card.is-active .category-symbol-shell {
  transform: scale(1.045);
}

.category-symbol-card.is-symbol-example {
  --symbol-size: clamp(148px, 13.6vw, 198px);
  width: var(--symbol-size);
  height: var(--symbol-size);
  color: color-mix(in srgb, var(--text) 88%, transparent);
}

.category-symbol-card.is-symbol-example .category-symbol-shell {
  border: 0;
  background: transparent;
}

.category-symbol-svg {
  width: 74%;
  height: 74%;
  overflow: visible;
}

.category-symbol-art {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  overflow: visible;
  pointer-events: none;
  user-select: none;
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, .3));
}

.category-symbol-card[data-service="face"] .category-symbol-art {
  transform: scale(1.08);
  transform-origin: center;
}

.category-symbol-svg .symbol-line,
.category-symbol-svg .symbol-card {
  fill: none;
  stroke: currentColor;
  stroke-width: 2.3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.category-symbol-svg .symbol-card {
  fill: transparent;
}

.category-symbol-svg .shadow-card {
  opacity: .34;
}

.category-symbol-svg .accent-star,
.category-symbol-svg .symbol-dot {
  color: var(--accent);
}

.category-symbol-svg .symbol-dot {
  fill: currentColor;
  stroke: none;
}

.category-symbol-card::after {
  content: "";
  position: absolute;
  left: 50%;
  top: calc(50% + var(--symbol-size) * .48);
  width: 0;
  max-width: 0;
  height: 0;
  margin: 0;
  overflow: hidden;
  color: color-mix(in srgb, var(--soft) 80%, transparent);
  font-size: .64rem;
  line-height: 1.22;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, 0);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
  text-align: center;
  text-shadow: 0 4px 14px rgba(0, 0, 0, .8), 0 0 4px rgba(0, 0, 0, .6);
}

.category-symbol-card:hover::after,
.category-symbol-card:focus-visible::after {
  content: attr(data-lead);
  width: max-content;
  max-width: 11em;
  height: auto;
  overflow: visible;
  opacity: .86;
  visibility: visible;
  transform: translate(-50%, 0);
}

.category-symbol-card.is-disabled:hover::after,
.category-symbol-card.is-disabled:focus-visible::after {
  content: "";
  width: 0;
  max-width: 0;
  height: 0;
  opacity: 0;
  visibility: hidden;
}

@media (min-width: 820px) {
  body[data-service="home"] .category-home {
    grid-template-columns: 1fr;
    justify-items: center;
  }
}

@media (max-width: 819px) {
  body[data-service="home"] .app-shell {
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr);
    gap: clamp(4px, 1.4vh, 10px);
    padding-block: max(10px, env(safe-area-inset-top)) max(10px, env(safe-area-inset-bottom));
    overflow: visible;
  }

  body[data-service="home"] .topbar {
    min-height: 48px;
    padding-block: 2px;
  }

  body[data-service="home"] .category-home {
    width: 100%;
    min-height: 0;
    height: 100%;
    align-content: center;
    overflow: visible;
  }

  body[data-service="home"] .category-home-head {
    max-width: 620px;
  }

  body[data-service="home"] .category-grid {
    --category-orbit-size: min(480px, 90vw, calc(100dvh - 112px));
    width: var(--category-orbit-size);
    height: var(--category-orbit-size);
  }
}

@media (max-width: 520px) {
  body[data-service="home"] .category-home h1 {
    font-size: clamp(1.9rem, 9vw, 2.65rem);
  }

  body[data-service="home"] .category-grid {
    --category-orbit-size: min(342px, calc(100vw - 48px), calc(100dvh - 128px));
    width: var(--category-orbit-size);
    height: var(--category-orbit-size);
    transform: translateY(-2px);
  }

  .category-card.category-symbol-card {
    --symbol-size: clamp(102px, 26vw, 132px);
    width: var(--symbol-size);
    height: var(--symbol-size);
    gap: 6px;
    grid-template-columns: 1fr;
    padding: 0;
  }

  .category-card.category-symbol-card.is-symbol-example {
    --symbol-size: clamp(102px, 26vw, 132px);
    width: var(--symbol-size);
    height: var(--symbol-size);
  }

  .category-symbol-card:hover::after,
  .category-symbol-card:focus-visible::after {
    font-size: .56rem;
    max-width: 8em;
  }

}

.tarot-fate-button {
  min-width: 168px;
  justify-content: center;
  padding-inline: 18px;
}

.tarot-fate-button:disabled {
  opacity: .42;
  filter: saturate(.72);
}

.tarot-canvas.tarot-stage-draw .tarot-arc-shell.has-picked .tarot-back-card:not(.is-picked):not(.is-centered) .tarot-back-face {
  filter: none;
}

.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked {
  border-color: rgba(255, 231, 174, .34);
  box-shadow: 0 20px 28px rgba(0, 0, 0, .32);
  filter: none;
  transform: translate(-50%, calc(-50% - 44px)) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  animation: none;
}

.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked:not(:disabled):hover {
  box-shadow: 0 22px 30px rgba(0, 0, 0, .34);
  filter: none;
  transform: translate(-50%, calc(-50% - 50px)) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
}

.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked::after,
.tarot-canvas.tarot-stage-draw .tarot-back-card.is-centered:not(.is-picked)::after {
  display: none;
}

.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked .tarot-back-face {
  animation: none;
  filter: none;
  transform: none;
}

.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked strong {
  box-shadow: none;
}

.tarot-canvas.tarot-stage-draw .tarot-back-card:disabled:not(.is-picked) {
  opacity: .5;
}

.tarot-slot.is-fresh-reveal .tarot-card-image {
  animation-duration: 3.35s;
  animation-timing-function: cubic-bezier(.2, .68, .12, 1);
}

.tarot-slot.is-fresh-reveal .tarot-card-image::before {
  animation-duration: 3.35s;
  animation-timing-function: cubic-bezier(.2, .68, .12, 1);
}

.tarot-slot.is-filled.is-fresh-reveal .tarot-slot-caption {
  animation-duration: 2.8s;
  animation-delay: calc(var(--slot-i, 0) * 80ms + 1050ms);
}

@media (max-width: 520px) {
  .tarot-fate-button {
    min-width: 142px;
    padding-inline: 14px;
  }

  .tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked {
    transform: translate(-50%, calc(-50% - 34px)) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  }

  .tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked:not(:disabled):hover {
    transform: translate(-50%, calc(-50% - 38px)) rotate(var(--arc-angle, 0deg)) scale(var(--arc-scale, 1));
  }
}

/* Tarot deck pivot hierarchy: the ring moves, individual cards keep their pose. */
.tarot-arc-shell {
  --deck-radius: 880px;
  --deck-center-y: -460px;
  --deck-rotation: 0deg;
  --deck-picked-offset: clamp(46px, 6vw, 78px);
}

.tarot-arc-shell.has-picked .tarot-back-card:not(.is-picked) .tarot-back-face,
.tarot-canvas.tarot-stage-draw .tarot-arc-shell.has-picked .tarot-back-card:not(.is-picked):not(.is-centered) .tarot-back-face {
  filter: none;
}

.tarot-arc-shell.is-grabbing .tarot-back-card,
.tarot-arc-shell.is-snapping .tarot-back-card {
  transition-duration: .16s;
}

.tarot-arc-shell.is-snapping .tarot-arc-ring {
  transition: transform .58s cubic-bezier(.16, .82, .22, 1);
}

.tarot-back-grid {
  z-index: 1;
}

.tarot-arc-stage {
  z-index: 2;
  overflow: visible;
}

.tarot-arc-ring {
  position: absolute;
  left: 50%;
  top: var(--deck-center-y);
  z-index: 2;
  width: 0;
  height: 0;
  pointer-events: none;
  transform: rotate(var(--deck-rotation));
  transform-origin: 0 0;
  transition: transform .11s linear;
  will-change: transform;
}

.tarot-arc-shell.is-grabbing .tarot-arc-ring {
  transition: none;
}

.tarot-card-orbit {
  position: absolute;
  left: 0;
  top: 0;
  z-index: var(--deck-i, 1);
  width: 0;
  height: 0;
  pointer-events: none;
  transform: rotate(var(--card-angle)) translateY(var(--deck-radius));
  transform-origin: 0 0;
  transition: transform .24s cubic-bezier(.2, .72, .18, 1);
  will-change: transform;
}

.tarot-card-orbit.is-picked {
  z-index: 1200;
  transform: rotate(var(--card-angle)) translateY(calc(var(--deck-radius) + var(--deck-picked-offset)));
}

.tarot-card-orbit.is-flight-hidden {
  visibility: hidden;
}

.tarot-card-orbit .tarot-back-card {
  position: absolute;
  left: 0;
  top: 0;
  z-index: auto;
  width: clamp(136px, 13vw, 188px);
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  transform-origin: center;
  animation: none;
  pointer-events: auto;
  box-shadow: 0 20px 30px rgba(0, 0, 0, .34);
  transition: transform .14s ease, border-color .14s ease, box-shadow .14s ease, filter .14s ease, opacity .14s ease;
}

.tarot-card-orbit .tarot-back-card::before,
.tarot-card-orbit .tarot-back-card::after,
.tarot-card-orbit .tarot-back-card.is-centered:not(.is-picked)::before,
.tarot-card-orbit .tarot-back-card.is-centered:not(.is-picked)::after,
.tarot-card-orbit .tarot-back-card.is-picked::after {
  display: none;
}

.tarot-card-orbit .tarot-back-card:not(:disabled):hover,
.tarot-card-orbit .tarot-back-card:not(:disabled):active,
.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked:not(:disabled):hover {
  transform: translate(-50%, -50%) scale(1.012);
  box-shadow: 0 23px 33px rgba(0, 0, 0, .38);
  filter: brightness(1.04);
}

.tarot-card-orbit .tarot-back-card.is-picked,
.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked {
  border-color: rgba(255, 231, 174, .42);
  box-shadow: 0 24px 34px rgba(0, 0, 0, .4);
  filter: none;
  transform: translate(-50%, -50%) scale(1.018);
  animation: none;
}

.tarot-card-orbit .tarot-back-card:disabled:not(.is-picked),
.tarot-canvas.tarot-stage-draw .tarot-back-card:disabled:not(.is-picked) {
  opacity: .5;
  cursor: default;
}

.tarot-card-orbit .tarot-back-face,
.tarot-card-orbit .tarot-back-card.is-picked .tarot-back-face,
.tarot-card-orbit .tarot-back-card.is-centered:not(.is-picked) .tarot-back-face,
.tarot-canvas.tarot-stage-draw .tarot-back-card.is-picked .tarot-back-face {
  animation: none;
  filter: none;
  transform: none;
}

.tarot-card-orbit .tarot-back-card strong {
  box-shadow: none;
}

.tarot-flight-layer {
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
}

.tarot-flight-card {
  position: fixed;
  display: block;
  border: 1px solid rgba(255, 231, 174, .42);
  border-radius: 7px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  box-shadow: 0 26px 42px rgba(0, 0, 0, .42), 0 0 30px rgba(255, 222, 149, .16);
  overflow: hidden;
  pointer-events: none;
  transform-origin: center;
  will-change: transform, opacity, filter;
}

.tarot-flight-card.is-result-flight {
  border: 0;
  background: transparent;
  box-shadow: 0 24px 36px rgba(0, 0, 0, .42);
}

.tarot-flight-card.is-result-flight .tarot-flight-face {
  background-position: center;
  background-size: cover;
}

.tarot-flight-card[hidden] {
  display: none;
}

.tarot-flight-face {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
}

body.is-tarot-result-flight-active [data-result-flight-target],
body.is-tarot-result-flight-active [data-loading-flight-target] {
  opacity: 0;
}

body.is-tarot-result-flight-active:not(.is-tarot-result-orbit-following) [data-loading-flight-target] {
  animation-play-state: paused !important;
}

body.is-tarot-result-flight-active .reading-card-token {
  animation: none !important;
}

/* Tarot reveal flip: only this wrapper rotates on its own Y axis. */
.tarot-card-image,
.tarot-slot.is-filled .tarot-card-image,
.tarot-slot.is-revealed .tarot-card-image,
.tarot-slot.is-reversed .tarot-card-image,
.tarot-canvas.is-reading-open .tarot-slot.is-revealed .tarot-card-image {
  position: relative;
  overflow: visible;
  border: 0;
  background: transparent;
  box-shadow: none;
  transform: none;
  transform-style: preserve-3d;
  backface-visibility: visible;
  will-change: auto;
}

.tarot-card-image::before,
.tarot-card-image::after,
.tarot-slot.is-fresh-reveal .tarot-card-image::before,
.tarot-slot.is-fresh-reveal .tarot-card-image::after,
.tarot-slot.is-revealed .tarot-card-image::after,
.tarot-slot.is-filled.is-facedown:not(:disabled) .tarot-card-image::before {
  display: none !important;
  animation: none !important;
}

.tarot-flip-card {
  position: absolute;
  inset: 0;
  border-radius: 7px;
  transform: rotateY(0deg);
  transform-style: preserve-3d;
  transform-origin: 50% 50%;
  transition: transform 1.65s cubic-bezier(.2, .72, .12, 1);
  will-change: transform;
}

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

.tarot-slot.is-fresh-reveal .tarot-flip-card {
  animation: tarotSlotFlipOnce 1.65s cubic-bezier(.2, .72, .12, 1) both;
}

.tarot-card-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 0;
  border-radius: 7px;
  background-color: transparent;
  background-clip: padding-box;
  clip-path: inset(0 round 7px);
  box-shadow: none;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform-style: preserve-3d;
}

.tarot-card-back {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .12), transparent 34% 68%, rgba(0, 0, 0, .16)),
    url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
}

.tarot-card-front {
  transform: rotateY(180deg);
}

.tarot-card-art {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background-position: center;
  background-size: cover;
  clip-path: inset(0 round 6px);
  transform: rotate(var(--card-art-rotate, 0deg));
  transform-origin: 50% 50%;
}

.tarot-slot.is-reversed {
  --card-art-rotate: 180deg;
  --card-final-rotate: 0deg;
}

.tarot-slot.is-filled.is-facedown:not(:disabled) .tarot-card-image {
  transition: filter .2s ease;
}

.tarot-slot.is-filled.is-facedown:not(:disabled):hover .tarot-card-image,
.tarot-slot.is-filled.is-facedown:not(:disabled):focus-visible .tarot-card-image,
.tarot-slot.is-filled.is-facedown:not(:disabled):active .tarot-card-image {
  filter: brightness(1.06) saturate(1.03);
  transform: none;
}

.tarot-slot.is-filled.is-facedown:not(:disabled):hover .tarot-card-face,
.tarot-slot.is-filled.is-facedown:not(:disabled):focus-visible .tarot-card-face {
  box-shadow: none;
}

.tarot-slot.is-fresh-deal.is-facedown .tarot-card-image,
.tarot-slot.is-fresh-reveal .tarot-card-image,
.tarot-slot.is-reversed.is-fresh-reveal .tarot-card-image {
  animation: none !important;
}

.service-stage.is-tarot-flight-landing .tarot-flip-card,
.service-stage.is-tarot-flight-landing .tarot-card-face,
.service-stage.is-tarot-flight-landing .tarot-card-art {
  animation: none !important;
  transition: none !important;
}

@keyframes tarotSlotFlipOnce {
  0% {
    transform: rotateY(0deg);
  }
  100% {
    transform: rotateY(180deg);
  }
}

@media (max-width: 520px) {
  .tarot-arc-shell {
    --deck-picked-offset: clamp(36px, 10vw, 58px);
  }

  .tarot-card-orbit .tarot-back-card {
    width: clamp(118px, 34vw, 146px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tarot-arc-ring,
  .tarot-card-orbit,
  .tarot-card-orbit .tarot-back-card {
    transition: none !important;
  }
}

/* Tarot zoom/pan deck table: cards are fixed on the table, only the camera moves. */
.tarot-arc-shell {
  --deck-camera-x: 0px;
  --deck-camera-y: 0px;
  --deck-camera-scale: 1;
  min-height: clamp(430px, 62vh, 620px);
  overflow: hidden;
  cursor: grab;
}

.tarot-arc-shell::before,
.tarot-arc-shell::after,
.tarot-arc-stage::before,
.tarot-arc-stage::after,
.tarot-draw-gate {
  display: none;
}

.tarot-arc-stage {
  position: absolute;
  inset: 0;
  z-index: 2;
  overflow: hidden;
  pointer-events: auto;
}

.tarot-deck-camera {
  position: absolute;
  inset: 0;
  z-index: 2;
  transform: translate3d(var(--deck-camera-x), var(--deck-camera-y), 0) scale(var(--deck-camera-scale));
  transform-origin: 50% 50%;
  will-change: transform;
}

.tarot-arc-shell.is-grabbing .tarot-deck-camera {
  transition: none;
}

.tarot-deck-table {
  position: absolute;
  left: 50%;
  top: 34%;
  width: var(--deck-table-width, 7600px);
  height: var(--deck-table-height, 760px);
  pointer-events: none;
  transform: translate(-50%, -50%);
  transform-origin: 50% 50%;
}

.tarot-deck-table::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 0;
  width: clamp(118px, 16vw, 176px);
  aspect-ratio: 2 / 3;
  border: 0;
  border-radius: 8px;
  background: url("./assets/tarot/fate-vintage-oracle/deck-back.png") center / cover;
  overflow: hidden;
  box-shadow: 0 22px 42px rgba(0, 0, 0, .42), 0 0 34px rgba(255, 221, 142, .16);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.82);
}

.tarot-canvas.tarot-stage-draw.is-deck-entering .tarot-deck-table::before {
  animation: tarotDeckStackDeal 4.6s cubic-bezier(.16, .82, .18, 1) both;
}

.tarot-card-node {
  position: absolute;
  left: calc(50% + var(--deck-card-x, 0px));
  top: calc(50% + var(--deck-card-y, 0px));
  z-index: var(--deck-z, 1);
  width: clamp(136px, 13vw, 188px);
  height: auto;
  pointer-events: none;
  transform:
    translate(-50%, -50%)
    translate3d(0, 0, 0)
    rotate(var(--deck-card-rotate, 0deg));
  transform-origin: center center;
  transition: transform .32s cubic-bezier(.18, .76, .18, 1), filter .18s ease;
  will-change: transform;
}

.tarot-canvas.tarot-stage-draw.is-deck-entering .tarot-card-node:not(.is-picked) {
  animation: tarotDeckSpreadCard 5.36s cubic-bezier(.16, .82, .18, 1) both;
  animation-delay: var(--deck-entry-delay, 0ms);
}

.tarot-canvas.tarot-stage-draw.is-deck-entering .tarot-card-node:not(.is-picked) .tarot-back-card {
  animation: tarotDeckSpreadFace 5.36s cubic-bezier(.16, .82, .18, 1) both;
  animation-delay: var(--deck-entry-delay, 0ms);
}

.tarot-card-node.is-picked {
  transform:
    translate(-50%, -50%)
    translate3d(var(--deck-pick-x, 0px), var(--deck-pick-y, -68px), 0)
    rotate(var(--deck-card-rotate, 0deg));
}

.tarot-card-node.is-flight-hidden {
  visibility: hidden;
}

.tarot-card-node .tarot-back-card,
.tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card {
  position: relative;
  left: auto;
  top: auto;
  z-index: auto;
  width: 100%;
  aspect-ratio: 2 / 3;
  opacity: 1;
  border: 0;
  background: transparent;
  overflow: hidden;
  transform: none;
  transform-origin: center;
  animation: none;
  pointer-events: auto;
  box-shadow: 0 22px 32px rgba(0, 0, 0, .36);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease, filter .18s ease, opacity .18s ease;
}

.tarot-card-node .tarot-back-card::before,
.tarot-card-node .tarot-back-card::after,
.tarot-card-node .tarot-back-card.is-picked::after,
.tarot-card-node .tarot-back-card.is-centered:not(.is-picked)::before,
.tarot-card-node .tarot-back-card.is-centered:not(.is-picked)::after {
  display: none;
}

.tarot-card-node .tarot-back-card:not(:disabled):hover,
.tarot-card-node .tarot-back-card:not(:disabled):active,
.tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card.is-picked:not(:disabled):hover {
  transform: scale(1.012);
  box-shadow: 0 25px 36px rgba(0, 0, 0, .42);
  filter: brightness(1.035);
}

.tarot-card-node .tarot-back-card.is-picked,
.tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card.is-picked {
  border-color: transparent;
  box-shadow: 0 26px 38px rgba(0, 0, 0, .45);
  filter: none;
  transform: scale(1.018);
  animation: none;
}

.tarot-card-node .tarot-back-card:disabled:not(.is-picked),
.tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card:disabled:not(.is-picked) {
  opacity: .52;
  cursor: default;
}

.tarot-card-node .tarot-back-face,
.tarot-card-node .tarot-back-card.is-picked .tarot-back-face,
.tarot-card-node .tarot-back-card.is-centered:not(.is-picked) .tarot-back-face,
.tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card.is-picked .tarot-back-face {
  inset: 0;
  border-radius: inherit;
  clip-path: inset(0 round 7px);
  animation: none;
  filter: none;
  transform: none;
}

.tarot-card-node .tarot-back-card strong {
  box-shadow: none;
}

.tarot-view-reset-button {
  min-width: 44px;
}

@keyframes tarotDeckStackDeal {
  0% {
    opacity: 0;
    filter: blur(3px) brightness(1.08);
    transform: translate(-50%, -50%) scale(.72) rotate(-2deg);
  }
  18%,
  54% {
    opacity: .84;
    filter: blur(0) brightness(1.06);
    transform: translate(-50%, -50%) scale(.98) rotate(0deg);
  }
  100% {
    opacity: 0;
    filter: blur(4px) brightness(1.2);
    transform: translate(-50%, -56%) scale(1.18) rotate(3deg);
  }
}

@keyframes tarotDeckSpreadCard {
  0% {
    opacity: 0;
    filter: blur(2px) brightness(1.16);
    transform:
      translate(-50%, -50%)
      translate3d(var(--deck-entry-x, 0px), var(--deck-entry-y, 72px), 0)
      rotate(var(--deck-entry-spin, 0deg))
      scale(.58);
  }
  44% {
    opacity: 1;
    filter: blur(.3px) brightness(1.08);
    transform:
      translate(-50%, -50%)
      translate3d(var(--deck-entry-mid-x, 0px), var(--deck-entry-mid-y, -24px), 0)
      rotate(var(--deck-entry-mid-rotate, var(--deck-card-rotate, 0deg)))
      scale(1.035);
  }
  72% {
    opacity: 1;
    filter: blur(0) brightness(1.02);
    transform:
      translate(-50%, -50%)
      translate3d(0, -8px, 0)
      rotate(var(--deck-card-rotate, 0deg))
      scale(1.012);
  }
  100% {
    opacity: 1;
    filter: none;
    transform:
      translate(-50%, -50%)
      translate3d(0, 0, 0)
      rotate(var(--deck-card-rotate, 0deg))
      scale(1);
  }
}

@keyframes tarotDeckSpreadFace {
  0% {
    box-shadow: 0 8px 14px rgba(0, 0, 0, .18);
  }
  50% {
    box-shadow: 0 30px 46px rgba(0, 0, 0, .46), 0 0 22px rgba(255, 226, 158, .18);
  }
  100% {
    box-shadow: 0 22px 32px rgba(0, 0, 0, .36);
  }
}

@media (max-width: 520px) {
  .tarot-arc-shell {
    min-height: min(560px, 66vh);
  }

  .tarot-card-node {
    width: clamp(118px, 34vw, 146px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tarot-deck-camera,
  .tarot-card-node,
  .tarot-card-node .tarot-back-card,
  .tarot-flip-card {
    animation: none !important;
    transition: none !important;
  }

  .tarot-deck-table::before {
    display: none;
  }
}

body[data-service="tarot"] .tarot-card-node .tarot-back-card,
body[data-service="tarot"] .tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card {
  border: 0 !important;
  outline: 0 !important;
  background: transparent !important;
  overflow: hidden !important;
  box-shadow: 0 22px 32px rgba(0, 0, 0, .36) !important;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-draw.is-deck-entering .tarot-card-node:not(.is-picked) .tarot-back-card {
  animation: none !important;
  box-shadow: 0 22px 32px rgba(0, 0, 0, .36) !important;
}

body[data-service="tarot"] .tarot-card-node .tarot-back-face,
body[data-service="tarot"] .tarot-card-node .tarot-back-card.is-picked .tarot-back-face,
body[data-service="tarot"] .tarot-card-node .tarot-back-card.is-centered:not(.is-picked) .tarot-back-face,
body[data-service="tarot"] .tarot-canvas.tarot-stage-draw .tarot-card-node .tarot-back-card.is-picked .tarot-back-face {
  inset: 0 !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  border-radius: inherit !important;
  clip-path: inset(0 round 7px) !important;
}

body[data-service="tarot"] .tarot-shuffle-card,
body[data-service="tarot"] .tarot-recombine-pile span,
body[data-service="tarot"] .tarot-cut-pile,
body[data-service="tarot"] .tarot-cut-pile::before,
body[data-service="tarot"] .tarot-cut-pile strong,
body[data-service="tarot"] .cut-stack span,
body[data-service="tarot"] .offer-deck span,
body[data-service="tarot"] .tarot-deck-table::before,
body[data-service="tarot"] .tarot-deal-flight,
body[data-service="tarot"] .tarot-flight-face,
body[data-service="tarot"] .tarot-card-back {
  border: 0 !important;
  outline: 0 !important;
  overflow: hidden !important;
}

body[data-service="tarot"] .tarot-shuffle-card,
body[data-service="tarot"] .tarot-recombine-pile span,
body[data-service="tarot"] .cut-stack span,
body[data-service="tarot"] .offer-deck span,
body[data-service="tarot"] .tarot-deck-table::before,
body[data-service="tarot"] .tarot-deal-flight {
  box-shadow: 0 22px 32px rgba(0, 0, 0, .36) !important;
}

body[data-service="tarot"] .tarot-flight-face,
body[data-service="tarot"] .tarot-card-back {
  box-shadow: none !important;
}

body[data-service="tarot"] .tarot-shuffle-card::after,
body[data-service="tarot"] .tarot-recombine-pile::after,
body[data-service="tarot"] .tarot-recombine-pile span::after,
body[data-service="tarot"] .cut-stack span::after,
body[data-service="tarot"] .offer-deck span::after,
body[data-service="tarot"] .tarot-deal-flight::after {
  border: 0 !important;
  display: none !important;
}

@media (max-width: 820px) {
  body[data-service="palm"] .palm-mvp {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  body[data-service="palm"] .palm-workflow {
    gap: 10px;
  }

  body[data-service="palm"] .palm-step-strip {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    overflow-x: visible;
    padding-bottom: 0;
  }

  body[data-service="palm"] .palm-input {
    min-height: 92px;
  }

  body[data-service="palm"] .palm-canvas.mvp-canvas {
    min-height: auto;
  }

  body[data-service="palm"] .palm-image-stage {
    width: min(100%, 520px);
    aspect-ratio: 4 / 5;
  }

  body[data-service="palm"] .palm-status-bar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  body[data-service="palm"] .palm-status-bar strong {
    white-space: normal;
  }

  body[data-service="palm"] .palm-status-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  body[data-service="palm"] .palm-observation-strip {
    align-items: flex-start;
  }

  body[data-service="palm"] .palm-observation-strip > div {
    justify-content: flex-start;
  }

  body[data-service="palm"] .palm-stage-actions {
    justify-content: stretch;
  }

  body[data-service="palm"] .palm-read-button {
    width: 100%;
  }
}

@media (max-width: 460px) {
  body[data-service="palm"] .palm-step {
    min-height: 20px;
    font-size: .56rem;
  }

  body[data-service="palm"] .palm-mode-row .mode-button {
    flex: 0 0 86px;
    min-width: 86px;
    font-size: .7rem;
  }

  body[data-service="palm"] .palm-workflow-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

body[data-service="palm"] .palm-line-tag {
    min-width: 54px;
    min-height: 42px;
    gap: 0;
    padding: 4px;
    justify-content: center;
  }

  body[data-service="palm"] .palm-line-tag strong {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }

  body[data-service="palm"] .palm-line-tag span {
    width: 30px;
    font-size: .72rem;
  }

  body[data-service="palm"] .palm-tag-heart { left: 6%; top: 12%; }
  body[data-service="palm"] .palm-tag-head { right: 5%; top: 37%; }
  body[data-service="palm"] .palm-tag-life { left: 6%; bottom: 16%; }
  body[data-service="palm"] .palm-tag-fate { right: 6%; bottom: 25%; }

  body[data-service="palm"] .palm-status-button {
    min-height: 42px;
    min-width: 54px;
    padding-inline: 8px;
    font-size: .72rem;
  }
}

/* Global depth flattening: layout containers should not become extra panels. */
.glass-panel,
.studio,
.result-panel,
.service-stage,
.tool-surface,
.tool-layout,
.minimal-tool,
.stage-split,
.visual-canvas,
.side-panel,
.option-canvas,
.tarot-canvas,
.tarot-settings-panel,
.tarot-deck-panel,
.tarot-deck-surface,
.tarot-arc-shell,
.tarot-arc-stage,
.saju-stage,
.saju-canvas,
.saju-reference-board,
.saju-reference-stack,
.saju-chart-copy,
.saju-basis,
.saju-pillar-board,
.element-board,
.saju-element-cycle,
.palm-mvp,
.palm-workflow,
.palm-stage-shell,
.palm-input-stage,
.palm-review-stage,
.palm-canvas,
.palm-image-stage,
.face-tool,
.face-entry,
.face-stage,
.face-stage-main,
.face-canvas,
.face-image-shell,
.face-observation-sheet,
.face-inline-hint,
.face-stage-actions,
.astrology-tool,
.astrology-stage,
.astrology-observatory,
.astrology-input-stack,
.astrology-instrument-stage,
.astrology-empty-stage,
.astrology-chart-stage,
.astrology-chart-view,
.astrology-chart-panels,
.astrology-focus-panel,
.astro-canvas,
.room-canvas {
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.glass-panel::before,
.glass-panel::after,
.visual-canvas::before,
.visual-canvas::after,
.side-panel::before,
.side-panel::after,
.option-canvas::before,
.option-canvas::after,
.tarot-canvas::before,
.tarot-canvas::after,
.tarot-deck-surface::before,
.tarot-deck-surface::after,
.tarot-arc-shell::before,
.tarot-arc-shell::after,
.tarot-arc-stage::before,
.tarot-arc-stage::after,
.saju-canvas::before,
.saju-canvas::after,
.palm-canvas::before,
.palm-canvas::after,
.face-canvas::before,
.face-canvas::after,
.astro-canvas::before,
.astro-canvas::after {
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.system-status,
.setup-details,
.saju-form-section,
.saju-form-grid label,
.saju-chart-copy,
.saju-basis,
.palm-status-bar,
.palm-review-item,
.face-review-item,
.face-observation-sheet,
.face-inline-hint,
.face-stage-actions,
.astrology-coordinate-details,
.astrology-focus-panel,
.astro-point-row,
.planet-list div {
  border-color: rgba(255, 255, 255, .08) !important;
}

/* Saju and astrology should read as instruments on the surface, not stacked panels. */
body[data-service="saju"] .saju-form-section,
body[data-service="saju"] .saju-form-grid label,
body[data-service="saju"] .saju-chart-copy,
body[data-service="saju"] .saju-basis,
body[data-service="astrology"] .mvp-form label,
body[data-service="astrology"] .astrology-coordinate-details,
body[data-service="astrology"] .astrology-focus-panel {
  border-bottom-color: rgba(255, 231, 174, .075) !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .saju-stage-input {
  grid-template-columns: minmax(280px, min(100%, 560px));
  justify-content: center;
  align-content: center;
}

body[data-service="saju"] .saju-input-note {
  display: none !important;
}

body[data-service="astrology"] .astrology-stage-input .object-field small {
  display: none;
}

body[data-service="astrology"] .astrology-stage-input .object-field:hover small,
body[data-service="astrology"] .astrology-stage-input .object-field:focus-within small {
  display: block;
}

body[data-service="saju"] .saju-form-grid input,
body[data-service="saju"] .saju-form-grid select,
body[data-service="astrology"] .mvp-form input,
body[data-service="astrology"] .mvp-form select,
body[data-service="astrology"] .astrology-coordinate-details input {
  border-color: rgba(255, 231, 174, .14) !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .saju-form-grid input:focus,
body[data-service="saju"] .saju-form-grid select:focus,
body[data-service="astrology"] .mvp-form input:focus,
body[data-service="astrology"] .mvp-form select:focus,
body[data-service="astrology"] .astrology-coordinate-details input:focus {
  border-color: rgba(255, 231, 174, .42) !important;
  outline: 1px solid rgba(255, 231, 174, .34);
  outline-offset: 2px;
}

body[data-service="saju"] .saju-segmented label {
  border-color: rgba(255, 231, 174, .14) !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .saju-segmented label.is-active {
  border-color: rgba(255, 231, 174, .42) !important;
  background: rgba(255, 231, 174, .04) !important;
}

body[data-service="saju"] .saju-pillar-board {
  border-top-color: rgba(255, 231, 174, .12);
  border-bottom-color: rgba(255, 231, 174, .09);
}

body[data-service="saju"] .saju-pillar-row {
  border-bottom-color: rgba(255, 255, 255, .055);
}

body[data-service="saju"] .saju-pillar-row > * {
  border-right-color: rgba(255, 255, 255, .045);
}

body[data-service="saju"] .saju-pillar-row .is-day-master,
body[data-service="saju"] .saju-result-pillars span,
body[data-service="saju"] .saved-saju-mini-strip span {
  border-color: transparent !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .saju-result-pillars span,
body[data-service="saju"] .saved-saju-mini-strip span {
  padding-inline: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .09) !important;
}

body[data-service="saju"] .element-track {
  background: rgba(255, 231, 174, .045) !important;
}

body[data-service="astrology"] .astro-marker,
body[data-service="astrology"] .astro-marker.is-chart-point,
body[data-service="astrology"] .astro-marker.is-focused,
body[data-service="astrology"] .astro-angle-marker,
body[data-service="astrology"] .astro-angle-marker.is-mc {
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="astrology"] .astro-marker.is-focused {
  color: #fff2be;
  border-color: rgba(255, 231, 174, .76);
}

body[data-service="astrology"] .astro-angle-marker {
  color: var(--accent-2);
}

body[data-service="astrology"] .astro-point-row,
body[data-service="astrology"] .planet-list div,
body[data-service="astrology"] .astrology-focus-facts div,
body[data-service="astrology"] .astrology-focus-aspects button,
body[data-service="astrology"] .astrology-note-list button,
body[data-service="astrology"] .astrology-selection-summary {
  border-bottom-color: rgba(221, 241, 255, .075) !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="astrology"] .astro-point-row.is-active,
body[data-service="astrology"] .astro-point-row:not(.is-static):hover,
body[data-service="astrology"] .astrology-focus-aspects button:hover,
body[data-service="astrology"] .astrology-note-list button:hover {
  border-bottom-color: rgba(255, 231, 174, .28) !important;
  background: transparent !important;
}

/* Object input grammar: the divination tool is the control surface. */
.object-field,
.mvp-form label.object-field,
.saju-form-grid label.object-field,
.astrology-coordinate-details label.object-field {
  min-width: 0;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 8px 0 12px;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .095) !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* Subtitle / helper / label texts under the title removed for a clean, objects-only stage
   (objects keep aria-labels for screen readers; values, choice chips and the CTA stay). */
.object-field small,
.saju-input-note,
.astrology-field-hint,
.face-inline-hint,
.palm-status-hint,
.saju-field-title,
.date-wheel-field .object-field-label,
.time-dial-field .object-field-label,
.world-map-field .object-field-label,
.object-field.is-timezone .object-field-label {
  display: none !important;
}

/* Inline validation hint — names what's still missing before the reading can run. */
.readiness-hint {
  margin: 6px 0 0;
  font-size: .8rem;
  font-weight: 800;
  color: color-mix(in srgb, var(--accent-2) 90%, white);
  text-align: center;
}

.readiness-hint[hidden] { display: none; }

body[data-service="saju"] .readiness-hint {
  paint-order: stroke fill;
  -webkit-text-stroke: 2px rgba(8, 5, 2, .8);
  text-shadow: 0 0 5px rgba(8, 5, 2, .5);
}

/* Contextual trust copy — shown only at the upload step / inside the saved drawer. */
.upload-privacy-note,
.saved-storage-note {
  margin: 0;
  font-size: .74rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--soft) 66%, transparent);
  text-align: center;
}

.upload-privacy-note {
  margin-top: 12px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, .75);
}

.saved-storage-note {
  margin: -4px 0 14px;
}

.object-field-body {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.object-field-label {
  color: color-mix(in srgb, var(--soft) 84%, transparent);
  font-size: .74rem;
  font-weight: 950;
  line-height: 1.2;
}

.object-field-value {
  min-height: 1.1em;
  color: color-mix(in srgb, var(--accent-2) 82%, transparent);
  font-size: .84rem;
  font-weight: 920;
  line-height: 1.25;
}

.object-field input,
.object-field select {
  width: 100%;
  min-height: 30px;
  padding: 0;
  border: 0 !important;
  border-radius: 0 !important;
  border-bottom: 1px solid rgba(255, 231, 174, .2) !important;
  background: transparent !important;
  box-shadow: none !important;
  color: color-mix(in srgb, var(--text) 78%, transparent);
  font-size: .86rem;
}

.object-field input:focus,
.object-field select:focus {
  border-bottom-color: rgba(255, 231, 174, .58) !important;
  outline: 0;
}

.object-field small {
  color: color-mix(in srgb, var(--muted) 86%, transparent);
  font-size: .68rem;
  font-weight: 800;
  line-height: 1.38;
}

/* Interactive birth-time dial — drag the clock hands to set the time. */
.time-dial-field {
  grid-template-columns: 104px minmax(0, 1fr);
  align-items: center;
}

.time-dial {
  place-self: center;
  width: 144px;
  height: 144px;
  display: block;
}

.time-dial-face {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 1px solid rgba(255, 231, 174, .5);
  background: radial-gradient(circle at 50% 38%, rgba(36, 28, 18, .55), rgba(8, 6, 8, .35) 70%);
  box-shadow: inset 0 0 16px rgba(0, 0, 0, .45), 0 6px 16px rgba(0, 0, 0, .3);
  cursor: grab;
  touch-action: none;
  display: grid;
  place-items: center;
}

.time-dial-field.is-dialing .time-dial-face { cursor: grabbing; }
.time-dial-face:hover { border-color: rgba(255, 231, 174, .72); }

.time-dial-ticks {
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, rgba(255, 231, 174, .55) 0deg 1.4deg, transparent 1.4deg 30deg);
  -webkit-mask: radial-gradient(circle, transparent 0 40%, #000 42% 49%, transparent 51%);
  mask: radial-gradient(circle, transparent 0 40%, #000 42% 49%, transparent 51%);
}

.time-dial-hand {
  position: absolute;
  left: 50%;
  bottom: 50%;
  transform-origin: 50% 100%;
  border-radius: 999px;
  background: linear-gradient(var(--accent-2), rgba(255, 231, 174, .68));
  transition: transform .14s cubic-bezier(.2, .8, .2, 1);
  outline-offset: 3px;
}

.time-dial-hand.is-hour {
  width: 3px;
  height: 24%;
  transform: translateX(-50%) rotate(var(--clock-hour, 0deg));
}

.time-dial-hand.is-minute {
  width: 2px;
  height: 36%;
  transform: translateX(-50%) rotate(var(--clock-minute, 0deg));
}

/* invisible padded hit area so the thin hands are easy to grab */
.time-dial-hand::before {
  content: "";
  position: absolute;
  inset: -10px -9px 0;
}

.time-dial-field.is-dialing .time-dial-hand { transition: none; }
.time-dial-hand:focus-visible { outline: 2px solid var(--accent-2); }

.time-dial-cap {
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent-2);
  box-shadow: 0 0 7px rgba(255, 231, 174, .6);
}

.time-dial-meridiem {
  display: inline-flex;
  width: max-content;
  border: 1px solid rgba(255, 231, 174, .3);
  border-radius: 999px;
  overflow: hidden;
}

.time-meridiem {
  appearance: none;
  border: 0;
  padding: 3px 11px;
  font-size: .7rem;
  font-weight: 900;
  letter-spacing: .02em;
  color: color-mix(in srgb, var(--soft) 66%, transparent);
  background: transparent;
  cursor: pointer;
  transition: background .16s ease, color .16s ease;
}

.time-meridiem + .time-meridiem { border-left: 1px solid rgba(255, 231, 174, .22); }
.time-meridiem.is-on { background: rgba(255, 231, 174, .16); color: var(--accent-2); }
.time-meridiem:focus-visible { outline: 2px solid var(--accent-2); outline-offset: -2px; }

.time-dial-field input[type="time"] {
  color: color-mix(in srgb, var(--text) 92%, transparent);
  font-variant-numeric: tabular-nums;
  letter-spacing: .04em;
}

@media (max-width: 520px) {
  .time-dial-field { grid-template-columns: 86px minmax(0, 1fr); }
  .time-dial { width: 78px; height: 78px; }
}

@media (prefers-reduced-motion: reduce) {
  .time-dial-hand { transition: none; }
}

/* Spinning birth-date wheel — drag year / month / day columns to set the date. */
.date-wheel-field {
  grid-template-columns: 168px minmax(0, 1fr);
  align-items: center;
}

.date-wheel {
  place-self: center;
  position: relative;
  width: 232px;
  height: 132px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid rgba(255, 231, 174, .32);
  border-radius: 12px;
  background: radial-gradient(circle at 50% 50%, rgba(20, 16, 12, .5), rgba(8, 6, 8, .3));
  box-shadow: inset 0 0 16px rgba(0, 0, 0, .4);
  overflow: hidden;
}

.date-wheel-col {
  position: relative;
  overflow: hidden;
  touch-action: none;
  cursor: grab;
  -webkit-mask: linear-gradient(transparent, #000 28%, #000 72%, transparent);
  mask: linear-gradient(transparent, #000 28%, #000 72%, transparent);
}

.date-wheel-col + .date-wheel-col { box-shadow: inset 1px 0 0 rgba(255, 231, 174, .12); }
.date-wheel-field.is-wheeling .date-wheel-col { cursor: grabbing; }

.date-wheel-track {
  display: flex;
  flex-direction: column;
  transition: transform .2s cubic-bezier(.2, .8, .2, 1);
  will-change: transform;
}

.date-wheel-field.is-wheeling .date-wheel-track { transition: none; }

.date-wheel-item {
  appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
  height: 44px;
  display: grid;
  place-items: center;
  font-size: 1rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: color-mix(in srgb, var(--soft) 42%, transparent);
  transition: color .14s ease, transform .14s ease;
}

.date-wheel-item.is-selected {
  color: var(--accent-2);
  font-weight: 950;
  transform: scale(1.05);
}

.date-wheel-field:not(.has-date) .date-wheel-item.is-selected {
  color: color-mix(in srgb, var(--accent-2) 58%, transparent);
}

.date-wheel-band {
  position: absolute;
  left: 6px;
  right: 6px;
  top: 44px;
  height: 44px;
  border-top: 1px solid rgba(255, 231, 174, .42);
  border-bottom: 1px solid rgba(255, 231, 174, .42);
  pointer-events: none;
}

.date-wheel-col:focus-visible { outline: 2px solid var(--accent-2); outline-offset: -2px; }

@media (max-width: 520px) {
  .date-wheel-field { grid-template-columns: 150px minmax(0, 1fr); }
  .date-wheel { width: 150px; }
}

@media (prefers-reduced-motion: reduce) {
  .date-wheel-track,
  .date-wheel-item { transition: none; }
}

/* Tappable equirectangular world plate (성도반) — tap/drag to set birth place + coords. */
.world-map-field {
  grid-template-columns: 168px minmax(0, 1fr);
  align-items: center;
}

.world-map {
  place-self: center;
  width: 264px;
  height: 142px;
  display: block;
}

.world-map-plate {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  border: 1px solid rgba(255, 231, 174, .6);
  background: radial-gradient(circle at 50% 42%, rgba(46, 36, 22, .62), rgba(12, 9, 10, .4) 74%);
  box-shadow: inset 0 0 16px rgba(0, 0, 0, .42), 0 6px 16px rgba(0, 0, 0, .3);
  cursor: crosshair;
  touch-action: none;
  overflow: hidden;
}

.world-map-plate:hover { border-color: rgba(255, 231, 174, .82); }

.wm-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.wm-graticule line { stroke: rgba(255, 231, 174, .2); stroke-width: .5; }
.wm-land { fill: rgba(255, 231, 174, .16); stroke: rgba(255, 231, 174, .6); stroke-width: .7; stroke-linejoin: round; }

.wm-star {
  position: absolute;
  left: var(--star-x);
  top: var(--star-y);
  width: 4.5px;
  height: 4.5px;
  margin: -2.25px 0 0 -2.25px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 231, 174, .62);
  box-shadow: 0 0 3px rgba(255, 231, 174, .45);
  cursor: pointer;
  transition: background .14s ease, box-shadow .14s ease, transform .14s ease;
}

/* invisible padded hit-target — kept small so dense cities don't swallow nearby taps */
.wm-star::before { content: ""; position: absolute; inset: -5px; border-radius: 50%; }

.wm-star:hover,
.wm-star:focus-visible,
.wm-star.is-active {
  background: var(--accent-2);
  box-shadow: 0 0 7px rgba(255, 231, 174, .7);
  transform: scale(1.25);
  outline: none;
}

.wm-cap {
  position: absolute;
  left: var(--map-x, 50%);
  top: var(--map-y, 50%);
  width: 9px;
  height: 9px;
  margin: -4.5px 0 0 -4.5px;
  border-radius: 50%;
  background: var(--accent-2);
  box-shadow: 0 0 8px rgba(255, 231, 174, .75);
  opacity: 0;
  pointer-events: none;
}

.world-map-field.has-place .wm-cap { opacity: 1; }
.wm-cap:focus-visible { opacity: 1; outline: 2px solid var(--accent-2); outline-offset: 2px; }

.wm-crosshair {
  position: absolute;
  left: var(--map-x, 50%);
  top: var(--map-y, 50%);
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.wm-crosshair::before,
.wm-crosshair::after { content: ""; position: absolute; background: rgba(255, 231, 174, .5); }
.wm-crosshair::before { left: -120px; width: 240px; height: 1px; top: 0; }
.wm-crosshair::after { top: -120px; height: 240px; width: 1px; left: 0; }
.world-map-field.is-mapping .wm-crosshair { opacity: .8; }

@media (max-width: 520px) {
  .world-map-field { grid-template-columns: 132px minmax(0, 1fr); }
  .world-map { width: 118px; height: 54px; }

  /* Mobile: keep the whole input on one screen (no scroll) — tighten the object cards
     and drop the rarely-used manual-coordinate panel (the map already sets coords). */
  body[data-service="saju"] .object-field.date-wheel-field,
  body[data-service="saju"] .object-field.time-dial-field,
  body[data-service="saju"] .object-field.world-map-field,
  body[data-service="astrology"] .object-field.date-wheel-field,
  body[data-service="astrology"] .object-field.time-dial-field,
  body[data-service="astrology"] .object-field.world-map-field {
    gap: 4px;
    padding-block: 2px 4px;
    min-height: 0;
  }

  body[data-service="astrology"] .astrology-birth-form,
  body[data-service="saju"] .saju-input-form { gap: 4px; }

  body[data-service="astrology"] .astrology-coordinate-details { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .wm-star { transition: none; }
  .world-map-field.is-mapping .wm-crosshair { opacity: 0; }
}

.object-choice-group {
  display: grid;
  gap: 10px;
}

.object-choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.object-choice {
  position: relative;
  min-width: 82px;
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 0;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: color-mix(in srgb, var(--soft) 78%, transparent);
  cursor: pointer;
}

.object-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.object-choice-label,
.object-choice > span:not(.object-glyph) {
  font-size: .72rem;
  font-weight: 900;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity .16s ease, transform .16s ease;
}

.object-choice.is-active .object-choice-label,
.object-choice:hover .object-choice-label,
.object-choice:focus-within .object-choice-label {
  opacity: .9;
  transform: translateY(0);
}

.object-check-label {
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity .16s ease, transform .16s ease;
}

.object-check.is-active .object-check-label,
.object-check:has(input:checked) .object-check-label,
.object-check:hover .object-check-label,
.object-check:focus-within .object-check-label {
  opacity: .9;
  transform: translateY(0);
}

.object-choice.is-active,
.object-choice:hover,
.object-choice:focus-within {
  color: var(--accent-2);
}

.object-choice.is-active .object-glyph,
.object-choice:hover .object-glyph,
.object-choice:focus-within .object-glyph,
.palm-hand-choice.is-active .object-glyph,
.palm-hand-choice:hover .object-glyph,
.palm-hand-choice:focus-visible .object-glyph {
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .32)) brightness(1.12);
  transform: translateY(-2px);
}

.object-glyph {
  position: relative;
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  color: var(--accent-2);
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .24));
  transition: transform .18s ease, filter .18s ease, opacity .18s ease;
}

.object-glyph.is-right { --glyph-art: url("./assets/ui-icons/hand-right.png"); }
.object-glyph.is-left { --glyph-art: url("./assets/ui-icons/hand-left.png"); }
.object-glyph.is-both { --glyph-art: url("./assets/ui-icons/hands-both.png"); }
.object-glyph.is-upload { --glyph-art: url("./assets/ui-icons/palm-upload.png"); }
.object-glyph.is-camera { --glyph-art: url("./assets/ui-icons/camera-lens.png"); }
.object-glyph.is-face { --glyph-art: url("./assets/ui-icons/face-frame.png"); }
.object-glyph.is-date,
.object-glyph.is-calendar { --glyph-art: url("./assets/ui-icons/lunar-calendar.png"); }
.object-glyph.is-time,
.object-glyph.is-clock,
.object-glyph.is-unknownTime { --glyph-art: url("./assets/ui-icons/moon-clock.png"); }
.object-glyph.is-place,
.object-glyph.is-map,
.object-glyph.is-timezone,
.object-glyph.is-meridian { --glyph-art: url("./assets/ui-icons/compass-pin.png"); }

.object-glyph[style*="--glyph-art"],
.object-glyph.is-right,
.object-glyph.is-left,
.object-glyph.is-both,
.object-glyph.is-upload,
.object-glyph.is-camera,
.object-glyph.is-face,
.object-glyph.is-date,
.object-glyph.is-calendar,
.object-glyph.is-time,
.object-glyph.is-clock,
.object-glyph.is-unknownTime,
.object-glyph.is-place,
.object-glyph.is-map,
.object-glyph.is-timezone,
.object-glyph.is-meridian {
  background: var(--glyph-art) center / contain no-repeat;
}

.object-glyph.is-right .object-glyph-core,
.object-glyph.is-left .object-glyph-core,
.object-glyph.is-both .object-glyph-core,
.object-glyph.is-upload .object-glyph-core,
.object-glyph.is-camera .object-glyph-core,
.object-glyph.is-face .object-glyph-core,
.object-glyph.is-date .object-glyph-core,
.object-glyph.is-calendar .object-glyph-core,
.object-glyph.is-time .object-glyph-core,
.object-glyph.is-clock .object-glyph-core,
.object-glyph.is-unknownTime .object-glyph-core,
.object-glyph.is-place .object-glyph-core,
.object-glyph.is-map .object-glyph-core,
.object-glyph.is-timezone .object-glyph-core,
.object-glyph.is-meridian .object-glyph-core,
.object-glyph.is-right::before,
.object-glyph.is-left::before,
.object-glyph.is-both::before,
.object-glyph.is-upload::before,
.object-glyph.is-camera::before,
.object-glyph.is-face::before,
.object-glyph.is-date::before,
.object-glyph.is-calendar::before,
.object-glyph.is-time::before,
.object-glyph.is-clock::before,
.object-glyph.is-unknownTime::before,
.object-glyph.is-place::before,
.object-glyph.is-map::before,
.object-glyph.is-timezone::before,
.object-glyph.is-meridian::before,
.object-glyph.is-right::after,
.object-glyph.is-left::after,
.object-glyph.is-both::after,
.object-glyph.is-upload::after,
.object-glyph.is-camera::after,
.object-glyph.is-face::after,
.object-glyph.is-date::after,
.object-glyph.is-calendar::after,
.object-glyph.is-time::after,
.object-glyph.is-clock::after,
.object-glyph.is-unknownTime::after,
.object-glyph.is-place::after,
.object-glyph.is-map::after,
.object-glyph.is-timezone::after,
.object-glyph.is-meridian::after {
  display: none;
}

.object-glyph-core,
.object-glyph::before,
.object-glyph::after {
  content: "";
  position: absolute;
  box-sizing: border-box;
}

.object-glyph.is-date .object-glyph-core,
.object-glyph.is-calendar .object-glyph-core {
  inset: 6px 5px 4px;
  border: 1px solid rgba(255, 231, 174, .62);
  border-radius: 4px;
  background:
    linear-gradient(rgba(255, 231, 174, .34), rgba(255, 231, 174, .34)) 0 9px / 100% 1px no-repeat,
    repeating-linear-gradient(90deg, transparent 0 8px, rgba(255, 231, 174, .16) 8px 9px),
    repeating-linear-gradient(0deg, transparent 0 8px, rgba(255, 231, 174, .13) 8px 9px);
}

.object-glyph.is-date::after,
.object-glyph.is-calendar::after {
  left: 18px;
  bottom: 10px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 231, 174, .72);
}

.object-glyph.is-date[data-object-day]::after,
.object-glyph.is-calendar[data-object-day]::after {
  content: attr(data-object-day);
  left: 12px;
  bottom: 8px;
  width: 18px;
  height: 14px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 231, 174, .38);
  border-radius: 3px;
  background: rgba(7, 6, 8, .28);
  color: var(--accent-2);
  font-size: .48rem;
  font-weight: 950;
  line-height: 1;
}

.object-glyph.is-time .object-glyph-core,
.object-glyph.is-clock .object-glyph-core,
.object-glyph.is-unknownTime .object-glyph-core {
  inset: 5px;
  border: 1px solid rgba(255, 231, 174, .62);
  border-radius: 50%;
}

.object-glyph.is-time::before,
.object-glyph.is-clock::before,
.object-glyph.is-unknownTime::before {
  left: 20px;
  top: 12px;
  width: 1px;
  height: 11px;
  background: rgba(255, 231, 174, .72);
  transform-origin: 50% 100%;
  transform: rotate(var(--clock-hour, 12deg));
}

.object-glyph.is-time::after,
.object-glyph.is-clock::after,
.object-glyph.is-unknownTime::after {
  left: 20px;
  top: 21px;
  width: 10px;
  height: 1px;
  background: rgba(255, 231, 174, .72);
  transform-origin: 0 50%;
  transform: rotate(var(--clock-minute, -34deg));
}

.object-glyph.is-unknownTime {
  opacity: .58;
}

.object-glyph.is-unknownTime .object-glyph-core::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 21px;
  width: 20px;
  height: 1px;
  background: rgba(255, 231, 174, .74);
  transform: rotate(-34deg);
}

.object-glyph.is-place .object-glyph-core,
.object-glyph.is-map .object-glyph-core {
  left: 15px;
  top: 6px;
  width: 14px;
  height: 20px;
  border: 1px solid rgba(255, 231, 174, .62);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
}

.object-glyph.is-place::after,
.object-glyph.is-map::after {
  left: 11px;
  bottom: 7px;
  width: 22px;
  height: 8px;
  border: 1px solid rgba(255, 231, 174, .22);
  border-radius: 50%;
}

.object-glyph.is-timezone .object-glyph-core,
.object-glyph.is-meridian .object-glyph-core {
  inset: 5px;
  border: 1px solid rgba(255, 231, 174, .62);
  border-radius: 50%;
}

.object-glyph.is-timezone::before,
.object-glyph.is-meridian::before {
  left: 20px;
  top: 6px;
  width: 1px;
  height: 30px;
  background: rgba(255, 231, 174, .56);
}

.object-glyph.is-timezone::after,
.object-glyph.is-meridian::after {
  left: 11px;
  top: 13px;
  width: 20px;
  height: 14px;
  border: 1px solid rgba(255, 231, 174, .28);
  border-left-color: transparent;
  border-right-color: transparent;
  border-radius: 50%;
}

.object-glyph.is-solar .object-glyph-core {
  inset: 11px;
  border: 1px solid rgba(255, 231, 174, .7);
  border-radius: 50%;
  background: rgba(255, 231, 174, .22);
  box-shadow: 0 0 0 7px rgba(255, 231, 174, .05);
}

.object-glyph.is-lunar .object-glyph-core {
  inset: 8px;
  border-radius: 50%;
  box-shadow: inset 9px 0 0 rgba(255, 231, 174, .62);
}

.object-glyph.is-private .object-glyph-core,
.object-glyph.is-female .object-glyph-core,
.object-glyph.is-male .object-glyph-core {
  inset: 8px;
  border: 1px solid rgba(255, 231, 174, .52);
  border-radius: 50%;
}

.object-glyph.is-female::after {
  left: 20px;
  top: 25px;
  width: 1px;
  height: 9px;
  background: rgba(255, 231, 174, .58);
  box-shadow: -4px 5px 0 -3px rgba(255, 231, 174, .58), 4px 5px 0 -3px rgba(255, 231, 174, .58);
}

.object-glyph.is-male::after {
  right: 6px;
  top: 7px;
  width: 12px;
  height: 12px;
  border-top: 1px solid rgba(255, 231, 174, .58);
  border-right: 1px solid rgba(255, 231, 174, .58);
}

.object-glyph.is-right .object-glyph-core,
.object-glyph.is-left .object-glyph-core,
.object-glyph.is-both .object-glyph-core {
  left: 13px;
  top: 12px;
  width: 17px;
  height: 22px;
  border: 1px solid rgba(255, 231, 174, .58);
  border-radius: 9px 9px 7px 7px;
}

.object-glyph.is-right::before,
.object-glyph.is-left::before,
.object-glyph.is-both::before {
  left: 12px;
  top: 5px;
  width: 4px;
  height: 16px;
  border-radius: 999px;
  background: rgba(255, 231, 174, .46);
  box-shadow:
    6px -2px 0 rgba(255, 231, 174, .56),
    12px -1px 0 rgba(255, 231, 174, .46),
    18px 2px 0 rgba(255, 231, 174, .38);
}

.object-glyph.is-left {
  transform: none;
}

.object-glyph.is-both::after {
  inset: 6px 6px auto auto;
  width: 16px;
  height: 22px;
  border: 1px solid rgba(255, 231, 174, .28);
  border-radius: 9px 9px 7px 7px;
  transform: translateX(7px) scaleX(-1);
}

.object-glyph.is-upload .object-glyph-core {
  inset: 6px 5px;
  border: 1px solid rgba(255, 231, 174, .42);
  border-radius: 5px;
}

.object-glyph.is-upload::before {
  left: 14px;
  top: 12px;
  width: 14px;
  height: 16px;
  border: 1px solid rgba(255, 231, 174, .5);
  border-radius: 7px 7px 5px 5px;
}

.object-glyph.is-upload::after {
  left: 12px;
  bottom: 9px;
  width: 18px;
  height: 1px;
  background: rgba(255, 231, 174, .4);
}

.object-glyph.is-camera .object-glyph-core {
  left: 7px;
  top: 12px;
  width: 28px;
  height: 20px;
  border: 1px solid rgba(255, 231, 174, .5);
  border-radius: 7px;
}

.object-glyph.is-camera::before {
  left: 14px;
  top: 8px;
  width: 14px;
  height: 6px;
  border: 1px solid rgba(255, 231, 174, .42);
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
}

.object-glyph.is-camera::after {
  left: 17px;
  top: 17px;
  width: 9px;
  height: 9px;
  border: 1px solid rgba(255, 231, 174, .58);
  border-radius: 50%;
  box-shadow: 12px -5px 0 -4px rgba(255, 231, 174, .4);
}

.object-glyph.is-face .object-glyph-core {
  left: 10px;
  top: 7px;
  width: 22px;
  height: 28px;
  border: 1px solid rgba(255, 231, 174, .5);
  border-radius: 48% 48% 42% 42%;
}

.object-glyph.is-face::before {
  left: 16px;
  top: 17px;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: rgba(255, 231, 174, .56);
  box-shadow: 9px 0 0 rgba(255, 231, 174, .56);
}

.object-glyph.is-face::after {
  left: 17px;
  bottom: 12px;
  width: 9px;
  height: 4px;
  border-bottom: 1px solid rgba(255, 231, 174, .42);
  border-radius: 50%;
}

.object-glyph.is-question .object-glyph-core {
  inset: 6px 8px;
  border: 1px solid rgba(255, 231, 174, .46);
  border-radius: 5px 5px 7px 7px;
  background:
    linear-gradient(90deg, transparent 0 8px, rgba(255, 231, 174, .14) 8px 9px, transparent 9px),
    repeating-linear-gradient(0deg, transparent 0 8px, rgba(255, 231, 174, .13) 8px 9px);
}

.object-glyph.is-question::before {
  left: 15px;
  top: 10px;
  width: 12px;
  height: 1px;
  background: rgba(255, 231, 174, .5);
  box-shadow:
    0 7px 0 rgba(255, 231, 174, .34),
    0 14px 0 rgba(255, 231, 174, .24);
}

.object-glyph.is-question::after {
  right: 10px;
  bottom: 8px;
  width: 8px;
  height: 8px;
  border: 1px solid rgba(255, 231, 174, .38);
  border-radius: 50%;
}

.palm-hand-choice {
  min-height: 124px;
  min-width: 132px;
  width: 132px;
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 0;
  border: 0 !important;
  background: transparent !important;
}

body[data-service="palm"] .palm-mode-row {
  justify-content: center;
}

body[data-service="palm"] .palm-mode-row .palm-hand-choice {
  flex: 0 0 132px;
  min-width: 132px;
  min-height: 124px;
  width: 132px;
}

.palm-hand-choice .object-glyph {
  width: 104px;
  height: 104px;
}

.palm-hand-choice > span:not(.object-glyph) {
  font-size: .72rem;
}

body[data-service="palm"] .palm-status-bar strong,
body[data-service="palm"] .palm-observation-strip > span,
body[data-service="palm"] .palm-review-item small,
body[data-service="face"] .face-inline-hint strong,
body[data-service="face"] .face-local-note strong,
body[data-service="face"] .face-review-item small {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transform: translateY(-2px);
  transition: max-height .18s ease, opacity .18s ease, transform .18s ease;
}

body[data-service="palm"] .palm-status-bar:hover strong,
body[data-service="palm"] .palm-status-bar:focus-within strong,
body[data-service="palm"] .palm-observation-strip:hover > span,
body[data-service="palm"] .palm-observation-strip:focus-within > span,
body[data-service="palm"] .palm-review-item:hover small,
body[data-service="palm"] .palm-review-item:focus-within small,
body[data-service="face"] .face-inline-hint:hover strong,
body[data-service="face"] .face-inline-hint:focus-within strong,
body[data-service="face"] .face-stage-actions:hover .face-local-note strong,
body[data-service="face"] .face-stage-actions:focus-within .face-local-note strong,
body[data-service="face"] .face-review-item:hover small,
body[data-service="face"] .face-review-item:focus-within small {
  max-height: 4.8em;
  opacity: .88;
  overflow: visible;
  white-space: normal;
  transform: translateY(0);
}

.palm-input.object-action {
  position: relative;
  width: clamp(132px, 22vw, 156px);
  height: clamp(132px, 22vw, 156px);
  min-width: 0;
  min-height: 0;
  display: grid;
  place-items: center;
  align-content: center;
  justify-self: center;
  padding: 0;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  cursor: pointer;
}

.palm-input.object-action > .object-glyph {
  width: 112px;
  height: 112px;
}

.palm-input.object-action input,
.face-capture-object input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  background: transparent !important;
  box-shadow: none !important;
}

.palm-input.object-action:hover .object-glyph,
.palm-input.object-action:focus-within .object-glyph {
  filter: brightness(1.12);
  transform: translateY(-2px);
}

.face-entry-actions.is-object-entry {
  gap: clamp(22px, 5vw, 54px);
}

.face-capture-object {
  position: relative;
  min-width: 94px;
  min-height: 94px;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 8px;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: color-mix(in srgb, var(--soft) 78%, transparent);
  cursor: pointer;
}

.face-capture-object input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.face-capture-object .object-glyph {
  width: 58px;
  height: 58px;
}

.face-capture-object:hover,
.face-capture-object:focus-within {
  color: var(--accent-2);
}

.face-capture-object:hover .object-glyph,
.face-capture-object:focus-within .object-glyph {
  filter: drop-shadow(0 12px 20px rgba(0, 0, 0, .34)) brightness(1.12);
  transform: translateY(-2px);
}

.palm-image-stage,
.face-image-shell {
  border-radius: 8px;
}

.palm-photo,
.face-photo {
  background: transparent !important;
}

.palm-empty-photo,
.face-photo-placeholder {
  border-radius: 8px;
}

.stage-indicator span,
.astrology-focus-head > span,
.astro-marker,
.palm-observation-chip {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.stage-indicator span {
  width: auto;
  height: auto;
  min-width: 1.4em;
}

/* Action grammar: object first, icon tools second, one primary text action per step. */
.primary-action {
  min-height: 46px;
  padding-inline: 18px;
  border-radius: 999px;
  font-weight: 950;
  letter-spacing: 0;
}

.gold-button.primary-action {
  border-color: rgba(255, 239, 198, .32);
  color: var(--ink);
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  box-shadow: 0 10px 22px rgba(0, 0, 0, .18), inset 0 1px rgba(255, 255, 255, .42);
}

.tool-action,
.ghost-button.tool-action,
.gold-button.tool-action,
label.tool-action {
  border-color: transparent !important;
  background: transparent !important;
  box-shadow: none !important;
  color: color-mix(in srgb, var(--soft) 78%, transparent);
}

.tool-action:hover,
.tool-action:focus-visible,
.ghost-button.tool-action:hover,
.ghost-button.tool-action:focus-visible,
label.tool-action:hover,
label.tool-action:focus-within {
  color: var(--accent-2);
  background: rgba(255, 231, 174, .07) !important;
}

.tool-action:focus-visible,
label.tool-action:focus-within {
  outline: 1px solid rgba(255, 231, 174, .5);
  outline-offset: 3px;
}

.choice-control,
.topic-button.choice-control,
.mode-button.choice-control,
.chip-button.choice-control,
.palm-status-button.choice-control {
  min-height: 34px;
  min-width: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding-inline: 8px;
  border-color: rgba(255, 255, 255, .09);
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
  color: color-mix(in srgb, var(--soft) 82%, transparent);
  font-weight: 850;
}

.choice-mark {
  min-width: 1.6em;
  min-height: 1.6em;
  display: inline-grid;
  place-items: center;
  color: color-mix(in srgb, var(--accent-2) 72%, transparent);
  font-size: .78rem;
  font-weight: 950;
  line-height: 1;
}

.choice-label {
  max-width: 0;
  overflow: hidden;
  opacity: 0;
  white-space: nowrap;
  transform: translateX(-3px);
  transition: max-width .18s ease, opacity .16s ease, transform .16s ease;
}

.choice-control:hover,
.choice-control:focus-visible {
  color: var(--accent-2);
  border-color: rgba(255, 231, 174, .28);
  background: transparent;
}

.choice-control:hover .choice-label,
.choice-control:focus-visible .choice-label,
.choice-control.is-active .choice-label {
  max-width: 9em;
  opacity: .88;
  transform: translateX(0);
}

@media (max-width: 520px) {
  .choice-control.is-active .choice-label {
    max-width: 0;
    opacity: 0;
    transform: translateX(-3px);
  }

  .choice-control:hover .choice-label,
  .choice-control:focus-visible .choice-label {
    max-width: 8em;
    opacity: .88;
    transform: translateX(0);
  }
}

/* Touch has no hover and unreliable :focus-visible — keep the SELECTED chip's label
   visible so users can always read/recall what they chose. */
@media (hover: none) {
  .choice-control.is-active .choice-label,
  .object-choice.is-active .object-choice-label {
    max-width: 9em;
    opacity: .9;
    transform: translateX(0);
  }
}

.choice-control.is-active,
.topic-button.choice-control.is-active,
.mode-button.choice-control.is-active,
.chip-button.choice-control.is-active,
.palm-status-button.choice-control.is-active {
  color: var(--accent-2);
  border-color: rgba(255, 231, 174, .38);
  background: transparent;
  box-shadow: none;
}

body[data-service="palm"] .palm-status-button.choice-control,
body[data-service="face"] .face-choice-row .chip-button.choice-control {
  padding-inline: 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .12);
  border-radius: 0;
  background: transparent !important;
}

body[data-service="palm"] .palm-status-button.choice-control {
  min-width: 54px;
  min-height: 42px;
  padding-inline: 8px;
}

body[data-service="palm"] .palm-status-button.choice-control:hover,
body[data-service="palm"] .palm-status-button.choice-control:focus-visible,
body[data-service="palm"] .palm-status-button.choice-control.is-active,
body[data-service="face"] .face-choice-row .chip-button.choice-control:hover,
body[data-service="face"] .face-choice-row .chip-button.choice-control:focus-visible,
body[data-service="face"] .face-choice-row .chip-button.choice-control.is-active {
  border-bottom-color: rgba(255, 231, 174, .42);
  background: transparent !important;
}

.object-action,
.zone-button.object-action,
.astro-choice.object-action,
.astro-point-row.object-action,
.astro-aspect-link.object-action,
.tarot-cut-pile.object-action {
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.zone-button.object-action,
.astro-choice.object-action,
.astro-point-row.object-action,
.astro-aspect-link.object-action {
  border-color: rgba(255, 255, 255, .1);
}

.zone-button.object-action:hover,
.zone-button.object-action:focus-visible,
.zone-button.object-action.is-active,
.astro-choice.object-action:hover,
.astro-choice.object-action:focus-visible,
.astro-choice.object-action.is-active,
.astro-point-row.object-action:hover,
.astro-point-row.object-action:focus-visible,
.astro-point-row.object-action.is-active,
.astro-aspect-link.object-action:hover,
.astro-aspect-link.object-action:focus-visible {
  border-color: rgba(255, 231, 174, .38);
  color: var(--accent-2);
  background: rgba(255, 231, 174, .045) !important;
}

.tarot-cut-pile.object-action:hover,
.tarot-cut-pile.object-action:focus-visible {
  background: rgba(255, 231, 174, .045) !important;
}

.saju-actions,
.astrology-actions,
.palm-workflow-actions,
.palm-stage-actions,
.face-entry-actions,
.face-action-row,
.tarot-ritual-actions,
.tarot-deck-actions,
.tarot-stage-actions {
  align-items: center;
  justify-content: center;
}

body[data-service="saju"] .saju-actions .tool-action,
body[data-service="astrology"] .astrology-actions .tool-action {
  width: 46px;
  min-width: 46px;
  min-height: 46px;
  padding: 0;
}

body[data-service="saju"] .saju-actions .primary-action,
body[data-service="astrology"] .astrology-actions .primary-action {
  width: fit-content;
  min-width: min(190px, 100%);
  justify-self: center;
}

body[data-service="astrology"] .astrology-stage-input .astrology-actions,
body[data-service="astrology"] .astrology-empty-stage .astrology-actions {
  display: flex;
}

body[data-service="saju"] .saju-wheel-core,
body[data-service="saju"] .saju-branch-mark.is-active::before,
body[data-service="saju"] .saju-element-node,
body[data-service="astrology"] .astrology-check-row,
body[data-service="astrology"] .astrology-note-list,
body[data-service="astrology"] .astrology-focus-facts div,
body[data-service="astrology"] .astrology-calibration-readout {
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .saju-wheel-core {
  border-color: rgba(255, 231, 174, .18);
}

body[data-service="saju"] .saju-element-node {
  border-color: color-mix(in srgb, var(--node-color, var(--accent)) 58%, transparent);
}

body[data-service="astrology"] .astrology-check-row {
  border-bottom: 1px solid rgba(255, 231, 174, .075) !important;
}

body[data-service="astrology"] .astrology-note-list {
  border-bottom-color: rgba(221, 241, 255, .06) !important;
  padding-block: 2px 8px;
}

body[data-service="astrology"] .astrology-chart-panels {
  gap: 8px;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage,
body[data-service="saju"] .saju-reading-stage.is-object-stage {
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 14px;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-canvas,
body[data-service="saju"] .saju-reading-stage.is-object-stage .saju-canvas {
  width: min(100%, 940px);
  padding-inline: 0;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-canvas {
  grid-template-columns: minmax(0, 1fr) minmax(170px, .3fr);
  grid-template-rows: auto minmax(0, 1fr);
  grid-template-areas:
    "pillars pillars"
    "map summary";
  gap: clamp(10px, 1.4vw, 16px) clamp(14px, 2vw, 24px);
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-pillar-board {
  grid-area: pillars;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-chart-map {
  grid-area: map;
  grid-template-columns: minmax(210px, 260px) minmax(210px, 260px);
  justify-content: center;
  gap: clamp(14px, 2vw, 26px);
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-branch-wheel {
  width: min(100%, 260px);
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-element-cycle {
  width: min(100%, 232px);
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-summary {
  grid-area: summary;
  width: 100%;
  grid-template-columns: minmax(0, 1fr);
  align-content: center;
  justify-self: stretch;
  gap: 6px;
  padding-top: 0;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-node {
  justify-items: start;
  padding-block: 4px 6px;
  text-align: left;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-node b {
  font-size: clamp(1.02rem, 2.1vw, 1.32rem);
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-node em {
  white-space: normal;
}

body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-actions {
  position: fixed;
  left: 50%;
  bottom: clamp(16px, 3vh, 30px);
  z-index: 24;
  width: max-content;
  max-width: calc(100vw - 32px);
  flex-wrap: nowrap;
  transform: translateX(-50%);
  padding-top: 0;
}

@media (max-height: 760px) and (min-width: 761px) {
  body[data-service="saju"] .saju-chart-stage.is-object-stage {
    gap: 8px;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-canvas {
    width: min(100%, 900px);
    gap: 8px 18px;
    grid-template-columns: minmax(0, 1fr) 190px;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-chart-map {
    grid-template-columns: minmax(180px, 220px) minmax(180px, 220px);
    gap: 16px;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-branch-wheel {
    width: min(100%, 220px);
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-element-cycle {
    width: min(100%, 200px);
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-pillar-row > * {
    padding-block: 5px;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-pillar-row.is-ganji em {
    font-size: clamp(1.35rem, 3vw, 2.15rem);
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-summary {
    gap: 3px;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-node {
    padding-block: 2px 4px;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-node b {
    font-size: 1.04rem;
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-node em {
    font-size: .66rem;
  }
}

.saju-object-summary {
  width: min(100%, 760px);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 1.8vw, 18px);
  justify-self: center;
  padding-top: 4px;
}

.saju-object-node {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 3px;
  padding: 6px 0 8px;
  border: 0;
  border-bottom: 1px solid rgba(255, 231, 174, .1);
  color: color-mix(in srgb, var(--soft) 78%, transparent);
  text-align: center;
  outline: 0;
}

.saju-object-node:focus-visible {
  outline: 1px solid rgba(255, 231, 174, .44);
  outline-offset: 4px;
}

.saju-object-node b {
  color: var(--accent-2);
  font-size: clamp(1.16rem, 3vw, 1.76rem);
  font-weight: 950;
  line-height: 1;
}

.saju-object-node small {
  color: color-mix(in srgb, var(--muted) 84%, transparent);
  font-size: .62rem;
  font-weight: 950;
}

.saju-object-node em {
  max-width: 100%;
  overflow: hidden;
  color: color-mix(in srgb, var(--soft) 88%, transparent);
  font-size: .72rem;
  font-style: normal;
  font-weight: 880;
  line-height: 1.22;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.astrology-orbit-details {
  justify-self: end;
  width: min(100%, 360px);
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.astrology-orbit-details summary {
  width: 42px;
  min-height: 42px;
  margin-left: auto;
  display: grid;
  place-items: center;
  border: 0;
  border-bottom: 1px solid rgba(221, 241, 255, .1);
  border-radius: 0;
  color: color-mix(in srgb, var(--soft) 76%, transparent);
  cursor: pointer;
  list-style: none;
}

.astrology-orbit-details summary::-webkit-details-marker {
  display: none;
}

.astrology-orbit-details summary:hover,
.astrology-orbit-details summary:focus-visible {
  color: var(--accent-2);
  outline: 1px solid rgba(255, 231, 174, .42);
  outline-offset: 3px;
}

.astrology-orbit-details summary svg {
  width: 18px;
  height: 18px;
}

.astrology-orbit-detail-body {
  display: grid;
  gap: 8px;
  padding-top: 8px;
}

.astrology-orbit-details:not([open]) .astrology-orbit-detail-body {
  display: none !important;
}

body[data-service="astrology"] .astrology-orbit-detail-body .astrology-position-list,
body[data-service="astrology"] .astrology-orbit-detail-body .astrology-note-list {
  opacity: .9;
}

body[data-service="astrology"] .astrology-chart-view .astrology-focus-panel {
  max-width: 360px;
  justify-self: end;
}

@media (max-width: 760px) {
  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-canvas {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "pillars"
      "map"
      "summary";
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-chart-map {
    grid-template-columns: minmax(0, 1fr);
  }

  .saju-object-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-service="saju"] .saju-chart-stage.is-object-stage .saju-object-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .astrology-orbit-details,
  body[data-service="astrology"] .astrology-chart-view .astrology-focus-panel {
    width: 100%;
    max-width: none;
    justify-self: stretch;
  }
}

.face-input-action.tool-action,
.face-action-button.tool-action,
.palm-file-button.tool-action {
  width: 46px;
  min-width: 46px;
  min-height: 46px;
  padding: 0;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question.is-object-question {
  width: min(680px, 100%);
  grid-template-columns: 54px minmax(0, 1fr);
  justify-items: stretch;
  align-items: center;
  text-align: left;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question.is-object-question .object-glyph {
  grid-row: 1 / span 3;
  align-self: center;
  width: 48px;
  height: 48px;
}

body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question.is-object-question small {
  grid-column: 2;
}

/* Object-first input pass: keep the field as a ritual object, not a settings panel. */
body[data-service="saju"] .saju-stage-input {
  align-content: start;
}

body[data-service="saju"] .saju-input-form,
body[data-service="astrology"] .astrology-birth-form {
  gap: clamp(8px, 1.2vw, 12px);
}

body[data-service="saju"] .saju-form-section {
  padding-bottom: 8px;
}

body[data-service="saju"] .saju-form-grid {
  gap: 8px clamp(14px, 2vw, 22px);
}

body[data-service="saju"] .object-field,
body[data-service="astrology"] .object-field {
  grid-template-columns: 58px minmax(0, 1fr);
  min-height: 78px;
  gap: 10px;
  padding-block: 4px 7px;
}

/* Birth-input objects become centered hero cards: the operated object on top, its
   label/value/controls stacked beneath. Wheel + clock pair side by side; map spans full. */
body[data-service="saju"] .object-field.time-dial-field,
body[data-service="astrology"] .object-field.time-dial-field,
body[data-service="saju"] .object-field.date-wheel-field,
body[data-service="astrology"] .object-field.date-wheel-field,
body[data-service="saju"] .object-field.world-map-field,
body[data-service="astrology"] .object-field.world-map-field {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding-block: 12px 16px;
  border-bottom: 0 !important;
}

body[data-service="saju"] .object-field.time-dial-field .object-field-body,
body[data-service="astrology"] .object-field.time-dial-field .object-field-body,
body[data-service="saju"] .object-field.date-wheel-field .object-field-body,
body[data-service="astrology"] .object-field.date-wheel-field .object-field-body,
body[data-service="saju"] .object-field.world-map-field .object-field-body,
body[data-service="astrology"] .object-field.world-map-field .object-field-body {
  width: min(100%, 360px);
  justify-items: center;
  text-align: center;
  gap: 6px;
}

body[data-service="saju"] .object-field.time-dial-field .time-dial-meridiem,
body[data-service="astrology"] .object-field.time-dial-field .time-dial-meridiem {
  margin-inline: auto;
}

/* Date wheel + clock sit as a side-by-side pair; the world map spans the full row. */
body[data-service="saju"] .saju-form-grid .world-map-field {
  grid-column: 1 / -1;
}

body[data-service="saju"] .object-field.time-dial-field input[type="time"],
body[data-service="astrology"] .object-field.time-dial-field input[type="time"],
body[data-service="saju"] .object-field.date-wheel-field input[type="date"],
body[data-service="astrology"] .object-field.date-wheel-field input[type="date"] {
  color: color-mix(in srgb, var(--text) 90%, transparent);
  min-height: 26px;
}

body[data-service="saju"] .object-field input,
body[data-service="saju"] .object-field select,
body[data-service="astrology"] .object-field input,
body[data-service="astrology"] .object-field select {
  min-height: 24px;
  color: color-mix(in srgb, var(--text) 68%, transparent);
  font-size: .8rem;
}

/* Saju renders on bright parchment where cream text drops to ~2:1. Lift contrast
   with a dark text halo (not a panel) + more solid glyphs. */
body[data-service="saju"] .object-field-label,
body[data-service="saju"] .object-field-value,
body[data-service="saju"] .object-field small,
body[data-service="saju"] .object-field input,
body[data-service="saju"] .object-field select,
body[data-service="saju"] .saju-field-title,
body[data-service="saju"] .saju-input-note,
body[data-service="saju"] .object-choice-label,
body[data-service="saju"] .choice-label,
body[data-service="saju"] .time-meridiem,
body[data-service="saju"] .stage-indicator span {
  /* A true dark glyph outline (drawn behind the fill) so cream/gold text reads on the
     variably-bright parchment — a blur shadow can't outline thin glyphs. */
  paint-order: stroke fill;
  -webkit-text-stroke: 2.2px rgba(8, 5, 2, .82);
  text-shadow: 0 0 5px rgba(8, 5, 2, .55);
}

body[data-service="saju"] .object-field input,
body[data-service="saju"] .object-field select {
  color: color-mix(in srgb, var(--text) 94%, transparent);
}

body[data-service="saju"] .object-field-label,
body[data-service="saju"] .saju-field-title {
  color: color-mix(in srgb, var(--soft) 97%, transparent);
}

body[data-service="saju"] .object-field-value {
  color: var(--accent-2);
}

body[data-service="saju"] .object-field small,
body[data-service="saju"] .saju-input-note {
  color: color-mix(in srgb, var(--soft) 88%, transparent);
}

body[data-service="saju"] .object-field .object-glyph,
body[data-service="astrology"] .object-field .object-glyph {
  width: 50px;
  height: 50px;
  align-self: center;
}

body[data-service="saju"] .object-choice-row {
  justify-content: center;
  gap: clamp(18px, 3vw, 34px);
}

body[data-service="saju"] .object-choice {
  min-width: 74px;
}

body[data-service="saju"] .saju-actions {
  padding-top: 0;
}

/* Astrology input: a single centered hero axis (operated objects + CTA up top, the sky
   preview a modest centered element below) — not a small form beside a dominating orbit. */
body[data-service="astrology"] .astrology-observatory {
  min-height: min(540px, calc(100vh - 180px));
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  align-content: start;
  gap: clamp(18px, 3vw, 44px);
}

body[data-service="astrology"] .astrology-input-stack {
  align-content: start;
  width: min(600px, 100%);
}

body[data-service="astrology"] .astrology-mvp-input .astrology-instrument-stage {
  width: min(440px, 90%);
  opacity: .9;
}

body[data-service="astrology"] .astrology-birth-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

body[data-service="astrology"] .astrology-check-row,
body[data-service="astrology"] .astrology-coordinate-details {
  grid-column: 1 / -1;
}

/* Give the rich birth-input objects the full input-stack width instead of a
   cramped half-column (mirrors the check-row / coordinate-details span above). */
body[data-service="astrology"] .astrology-birth-form .world-map-field {
  grid-column: 1 / -1;
}

body[data-service="astrology"] .astrology-check-row {
  min-height: 42px;
  padding-block: 0 8px;
}

body[data-service="astrology"] .astrology-coordinate-details {
  padding-top: 0;
  opacity: .72;
}

body[data-service="astrology"] .astrology-coordinate-details[open] {
  opacity: 1;
}

body[data-service="astrology"] .astrology-coordinate-details .object-field {
  min-height: 66px;
}

body[data-service="astrology"] .astrology-chart-empty {
  align-content: center;
}

body[data-service="astrology"] .astrology-chart-status {
  margin-top: -4px;
}

@media (max-width: 560px) {
  body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question.is-object-question {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question.is-object-question .object-glyph {
    grid-row: auto;
  }

  body[data-service="tarot"] .tarot-canvas.tarot-stage-question .tarot-question.is-object-question small {
    grid-column: auto;
  }
}

@media (max-width: 820px) {
  body[data-service="saju"] .saju-stage-input,
  body[data-service="astrology"] .astrology-observatory {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
  }

  body[data-service="astrology"] .astrology-birth-form {
    grid-template-columns: minmax(0, 1fr);
  }

  body[data-service="astrology"] .astrology-instrument-stage {
    display: none;
  }

  body[data-service="astrology"] .astrology-stage-input {
    padding-bottom: 0;
  }

  body[data-service="astrology"] .astrology-stage-input .astro-map {
    width: min(320px, 92vw);
  }

  body[data-service="astrology"] .astrology-stage-input .astrology-actions {
    position: static;
    width: 100%;
    transform: none;
  }

  body[data-service="astrology"] .astrology-stage-input .astrology-actions .primary-action {
    width: 100%;
  }

body[data-service="astrology"] .astrology-check-row,
body[data-service="astrology"] .astrology-coordinate-details {
  grid-column: auto;
}
}

/* Quiet saju/astrology surfaces: objects stay touchable, backgrounds do not stack. */
body[data-service="saju"] .saju-input-form,
body[data-service="saju"] .saju-form-section,
body[data-service="saju"] .saju-form-grid,
body[data-service="saju"] .object-choice-group,
body[data-service="astrology"] .astrology-birth-form,
body[data-service="astrology"] .astrology-coordinate-details,
body[data-service="astrology"] .astrology-orbit-detail-body {
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .object-field,
body[data-service="astrology"] .object-field {
  border-bottom-color: rgba(255, 231, 174, .055) !important;
  background: transparent !important;
}

body[data-service="saju"] .object-field:hover,
body[data-service="saju"] .object-field:focus-within,
body[data-service="astrology"] .object-field:hover,
body[data-service="astrology"] .object-field:focus-within {
  border-bottom-color: rgba(255, 231, 174, .22) !important;
}

body[data-service="saju"] .object-field input,
body[data-service="saju"] .object-field select,
body[data-service="astrology"] .object-field input,
body[data-service="astrology"] .object-field select,
body[data-service="astrology"] .astrology-coordinate-details input {
  border-bottom-color: rgba(255, 231, 174, .115) !important;
  background: transparent !important;
}

body[data-service="saju"] .object-field input:hover,
body[data-service="saju"] .object-field select:hover,
body[data-service="astrology"] .object-field input:hover,
body[data-service="astrology"] .object-field select:hover {
  border-bottom-color: rgba(255, 231, 174, .28) !important;
}

body[data-service="saju"] .object-choice,
body[data-service="astrology"] .astrology-check-row {
  border: 0 !important;
  border-bottom: 1px solid rgba(255, 231, 174, .055) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="saju"] .object-choice.is-active,
body[data-service="saju"] .object-choice:hover,
body[data-service="saju"] .object-choice:focus-within,
body[data-service="astrology"] .astrology-check-row:hover,
body[data-service="astrology"] .astrology-check-row:focus-within {
  border-bottom-color: rgba(255, 231, 174, .24) !important;
}

body[data-service="saju"] .object-glyph,
body[data-service="astrology"] .object-glyph {
  border-color: rgba(255, 231, 174, .16);
  background: transparent;
  box-shadow: none;
}

body[data-service="saju"] .object-choice.is-active .object-glyph,
body[data-service="saju"] .object-choice:hover .object-glyph,
body[data-service="saju"] .object-field:hover .object-glyph,
body[data-service="saju"] .object-field:focus-within .object-glyph,
body[data-service="astrology"] .object-field:hover .object-glyph,
body[data-service="astrology"] .object-field:focus-within .object-glyph,
body[data-service="astrology"] .astrology-check-row:hover .object-glyph,
body[data-service="astrology"] .astrology-check-row:focus-within .object-glyph {
  border-color: rgba(255, 231, 174, .32);
  filter: brightness(1.08);
}

body[data-service="astrology"] .astrology-focus-head > span,
body[data-service="astrology"] .astrology-focus-facts div,
body[data-service="astrology"] .astrology-selection-summary,
body[data-service="astrology"] .astrology-note-list,
body[data-service="astrology"] .astro-point-row,
body[data-service="astrology"] .astro-aspect-link {
  background: transparent !important;
  box-shadow: none !important;
}

body[data-service="astrology"] .astrology-focus-head > span {
  border-color: rgba(255, 231, 174, .24);
}

body[data-service="astrology"] .astrology-focus-panel {
  padding-block: 0 8px;
  border-bottom-color: rgba(221, 241, 255, .06) !important;
}

body[data-service="astrology"] .astrology-selection-summary {
  min-height: 38px;
  padding-block: 2px 7px;
  border-bottom-color: rgba(221, 241, 255, .06) !important;
}

/* Mobile service screens: the page itself must not scroll. Each category owns a
   single stage inside the viewport; dense birth inputs compact on short screens. */
@media (max-width: 820px) {
  body:not([data-service="home"]) .app-shell {
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr);
    overflow: hidden;
  }

  body:not([data-service="home"]) .topbar::before {
    left: 0;
    right: 0;
  }

  body:not([data-service="home"]) .service-workspace {
    min-height: 0;
    height: 100%;
    overflow: hidden;
    align-content: stretch;
  }

  body:not([data-service="home"]) .service-workspace .studio,
  body:not([data-service="home"]) .service-workspace .result-panel,
  body:not([data-service="home"]) .service-stage,
  body:not([data-service="home"]) .minimal-tool,
  body:not([data-service="home"]) .astrology-tool,
  body:not([data-service="home"]) .palm-mvp,
  body:not([data-service="home"]) .face-tool {
    min-height: 0;
    height: 100%;
    overflow: hidden;
  }

  body:not([data-service="home"]) .service-workspace .result-panel {
    grid-template-rows: auto minmax(0, 1fr) auto auto;
  }

  body:not([data-service="home"]) .service-workspace .reading-copy {
    max-height: none;
    min-height: 0;
    overflow: hidden;
  }
}

@media (max-width: 820px) and (max-height: 720px) {
  body:not([data-service="home"]) .app-shell {
    gap: 6px;
    padding-block: max(6px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-bottom));
  }

  body:not([data-service="home"]) .topbar {
    min-height: 46px;
    padding-block: 0;
  }

  body:not([data-service="home"]) .brand {
    gap: 8px;
    font-size: .95rem;
  }

  body:not([data-service="home"]) .brand-mark {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  body:not([data-service="home"]) .topbar-link,
  body:not([data-service="home"]) .audio-toggle,
  body:not([data-service="home"]) .top-back-button {
    min-height: 34px;
    padding-inline: 8px;
    font-size: .72rem;
  }

  body:not([data-service="home"]) .service-workspace {
    gap: 0;
  }

  body[data-service="saju"] .saju-stage-input,
  body[data-service="astrology"] .astrology-observatory {
    min-height: 0;
    height: 100%;
    align-content: start;
    overflow: hidden;
  }

  body[data-service="saju"] .saju-input-form,
  body[data-service="astrology"] .astrology-input-stack,
  body[data-service="astrology"] .astrology-birth-form {
    min-height: 0;
    height: 100%;
    gap: 2px;
    overflow: hidden;
  }

  body[data-service="astrology"] .astrology-birth-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-content: start;
  }

  body[data-service="astrology"] .astrology-birth-form .world-map-field,
  body[data-service="astrology"] .astrology-check-row,
  body[data-service="astrology"] .astrology-coordinate-details {
    grid-column: 1 / -1;
  }

  body[data-service="saju"] .saju-form-section,
  body[data-service="saju"] .saju-form-grid {
    min-height: 0;
    gap: 2px 10px;
  }

  body[data-service="saju"] .saju-form-section {
    height: 46px;
    padding-bottom: 0;
    overflow: hidden;
  }

  body[data-service="saju"] .object-choice-group {
    gap: 2px;
  }

  body[data-service="saju"] .object-choice-row {
    gap: 8px;
    justify-content: center;
  }

  body[data-service="saju"] .object-choice {
    min-width: 54px;
    gap: 0;
  }

  body[data-service="saju"] .object-choice .object-glyph {
    width: 34px;
    height: 34px;
  }

  body[data-service="saju"] .object-choice-label {
    display: none !important;
  }

  body[data-service="saju"] .object-field.time-dial-field,
  body[data-service="astrology"] .object-field.time-dial-field,
  body[data-service="saju"] .object-field.date-wheel-field,
  body[data-service="astrology"] .object-field.date-wheel-field,
  body[data-service="saju"] .object-field.world-map-field,
  body[data-service="astrology"] .object-field.world-map-field {
    gap: 2px;
    padding-block: 2px 4px;
    min-height: 0;
  }

  body[data-service="saju"] .object-field.time-dial-field,
  body[data-service="astrology"] .object-field.time-dial-field,
  body[data-service="saju"] .object-field.date-wheel-field,
  body[data-service="astrology"] .object-field.date-wheel-field {
    min-height: 148px;
  }

  body[data-service="saju"] .object-field.world-map-field,
  body[data-service="astrology"] .object-field.world-map-field {
    min-height: 108px;
  }

  body[data-service="saju"] .object-field.time-dial-field .object-field-body,
  body[data-service="astrology"] .object-field.time-dial-field .object-field-body,
  body[data-service="saju"] .object-field.date-wheel-field .object-field-body,
  body[data-service="astrology"] .object-field.date-wheel-field .object-field-body,
  body[data-service="saju"] .object-field.world-map-field .object-field-body,
  body[data-service="astrology"] .object-field.world-map-field .object-field-body {
    gap: 2px;
  }

  body[data-service="saju"] .saju-actions,
  body[data-service="astrology"] .astrology-actions {
    min-height: 42px;
    height: 42px;
    padding-top: 0;
  }

  body[data-service="saju"] .saju-actions .primary-action,
  body[data-service="astrology"] .astrology-actions .primary-action {
    min-height: 40px;
    min-width: min(172px, 100%);
    padding-block: 0;
  }

  body[data-service="astrology"] .astrology-check-row {
    min-height: 38px;
    padding-block: 0;
  }

  body[data-service="astrology"] .astrology-check-row .object-glyph {
    width: 34px;
    height: 34px;
  }
}

/* Birth inputs: date + clock belong to one row; place selection owns the next row.
   Keep the map large enough to feel like the operated object, not a tiny setting. */
@media (max-width: 820px) {
  body[data-service="saju"] .saju-form-grid,
  body[data-service="astrology"] .astrology-birth-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }

  body[data-service="saju"] .saju-form-grid .date-wheel-field,
  body[data-service="saju"] .saju-form-grid .time-dial-field,
  body[data-service="astrology"] .astrology-birth-form .date-wheel-field,
  body[data-service="astrology"] .astrology-birth-form .time-dial-field {
    grid-column: auto;
  }

  body[data-service="saju"] .saju-form-grid .world-map-field,
  body[data-service="astrology"] .astrology-birth-form .world-map-field,
  body[data-service="astrology"] .astrology-check-row,
  body[data-service="astrology"] .astrology-coordinate-details {
    grid-column: 1 / -1;
  }

  body[data-service="saju"] .world-map,
  body[data-service="astrology"] .world-map {
    width: min(330px, 88vw);
    height: clamp(118px, 32vw, 150px);
  }

  body[data-service="saju"] .object-field.world-map-field,
  body[data-service="astrology"] .object-field.world-map-field {
    width: 100%;
  }

  body[data-service="saju"] .date-wheel,
  body[data-service="astrology"] .date-wheel {
    height: 132px;
  }

  body[data-service="saju"] .time-dial,
  body[data-service="astrology"] .time-dial {
    width: 132px;
    height: 132px;
  }

  body[data-service="saju"] .object-field.date-wheel-field,
  body[data-service="astrology"] .object-field.date-wheel-field,
  body[data-service="saju"] .object-field.time-dial-field,
  body[data-service="astrology"] .object-field.time-dial-field {
    min-height: 196px;
    justify-content: start;
  }

  body[data-service="saju"] .object-field.date-wheel-field .object-field-body,
  body[data-service="astrology"] .object-field.date-wheel-field .object-field-body,
  body[data-service="saju"] .object-field.time-dial-field .object-field-body,
  body[data-service="astrology"] .object-field.time-dial-field .object-field-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 48px;
    justify-content: flex-start;
  }

  body[data-service="saju"] .object-field.date-wheel-field input[type="date"],
  body[data-service="astrology"] .object-field.date-wheel-field input[type="date"],
  body[data-service="saju"] .object-field.time-dial-field input[type="time"],
  body[data-service="astrology"] .object-field.time-dial-field input[type="time"] {
    order: 0;
    align-self: start;
  }

  body[data-service="saju"] .object-field.time-dial-field .time-dial-meridiem,
  body[data-service="astrology"] .object-field.time-dial-field .time-dial-meridiem {
    order: 1;
  }

  body[data-service="saju"] .object-field.time-dial-field .object-field-body {
    transform: translateY(-8px);
  }
}

@media (max-width: 820px) and (max-height: 720px) {
  body[data-service="saju"] .world-map,
  body[data-service="astrology"] .world-map {
    width: min(306px, 84vw);
    height: clamp(104px, 29vw, 132px);
  }

  body[data-service="saju"] .object-field.time-dial-field,
  body[data-service="astrology"] .object-field.time-dial-field,
  body[data-service="saju"] .object-field.date-wheel-field,
  body[data-service="astrology"] .object-field.date-wheel-field {
    min-height: 182px;
  }

  body[data-service="saju"] .object-field.world-map-field,
  body[data-service="astrology"] .object-field.world-map-field {
    min-height: 142px;
  }
}

/* ── 안내 다이얼로그(출생 정보 필요 등) ───────────────────────── */
.app-dialog { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 24px; }
.app-dialog[hidden] { display: none; }
.app-dialog-backdrop { position: absolute; inset: 0; border: 0; padding: 0; background: rgba(6, 5, 12, .62); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); cursor: pointer; }
.app-dialog-panel { position: relative; z-index: 1; width: min(420px, 100%); padding: 26px 24px 22px; border-radius: 18px; text-align: left; }
.app-dialog-panel h2 { margin: 6px 0 10px; }
.app-dialog-message { color: var(--soft); line-height: 1.7; margin: 0 0 22px; }
.app-dialog-actions { display: flex; gap: 10px; justify-content: flex-end; }
.auth-dialog-panel { width: min(380px, 100%); padding: 22px; }
.auth-dialog-body { display: grid; gap: 12px; margin-top: 0; }
.auth-dialog-note { margin: 0; color: var(--soft); line-height: 1.6; font-size: .92rem; }
.auth-dialog-note.is-muted { color: var(--muted); font-size: .82rem; }
.auth-provider-list { display: grid; gap: 8px; }
.auth-provider-button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(255, 231, 179, .22);
  border-radius: 10px;
  background: rgba(255, 255, 255, .045);
  color: var(--text);
  font-weight: 900;
  cursor: pointer;
}
.auth-provider-button:hover,
.auth-provider-button:focus-visible {
  border-color: rgba(255, 231, 179, .42);
  background: rgba(255, 231, 179, .07);
  outline: none;
}
.auth-provider-button:disabled {
  cursor: not-allowed;
  opacity: .38;
}
.auth-user-line {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}
.auth-user-line img,
.auth-user-line > .ui-icon {
  width: 42px;
  height: 42px;
  border-radius: 999px;
}
.auth-user-line strong,
.auth-user-line span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.auth-user-line span { color: var(--muted); font-size: .82rem; }

/* ── 사이트 푸터(약관·정책 링크) ─────────────────────────────── */
.site-footer { position: relative; z-index: 2; flex: none; width: min(1500px, calc(100% - 32px)); margin: 0 auto; padding: 8px 0 10px; text-align: center; }
.site-footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: center; }
.site-footer-links a { color: var(--muted); text-decoration: none; font-size: .8rem; letter-spacing: .02em; }
.site-footer-links a:hover { color: var(--accent); }
.site-footer-note { color: var(--muted); font-size: .72rem; opacity: .68; margin: 5px 0 0; letter-spacing: .03em; }
/* 약관·정책 푸터는 메인(홈) 화면에만 — 서비스 화면은 푸터 숨김(공간 확보 + 중복 제거). */
body:not([data-service="home"]) .site-footer { display: none; }

/* Publishing home selector: desktop row, mobile loop carousel. */
body[data-service="home"] .category-grid {
  --home-drag-x: 0px;
  width: min(1080px, 92vw);
  height: auto;
  aspect-ratio: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 3.2vw, 40px);
  margin-inline: auto;
  overflow: visible;
  transform: none;
}

body[data-service="home"] .category-symbol-card {
  --symbol-size: clamp(160px, 12vw, 220px);
  position: relative;
  left: auto;
  top: auto;
  flex: 0 0 var(--symbol-size);
  width: var(--symbol-size);
  height: var(--symbol-size);
  transform: none;
}

body[data-service="home"] .category-symbol-card:hover,
body[data-service="home"] .category-symbol-card:focus-visible,
body[data-service="home"] .category-symbol-card.is-active {
  transform: translateY(-4px);
}

body[data-service="home"] .category-symbol-card.is-disabled,
body[data-service="home"] .category-symbol-card.is-disabled:hover,
body[data-service="home"] .category-symbol-card.is-disabled:focus-visible {
  transform: none;
}

.home-oracle-object {
  position: absolute;
  left: 50%;
  top: clamp(-72px, -5vw, -48px);
  z-index: 8;
  width: clamp(52px, 5.2vw, 72px);
  height: clamp(52px, 5.2vw, 72px);
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--accent-2);
  cursor: pointer;
  transform: translateX(-50%);
  transition: filter .2s ease, transform .2s ease;
}

.home-oracle-object:hover,
.home-oracle-object:focus-visible {
  outline: none;
  filter: brightness(1.15);
  transform: translateX(-50%) translateY(-2px) scale(1.04);
}

.home-oracle-object:focus-visible::before {
  content: "";
  position: absolute;
  inset: -7px;
  border-radius: 999px;
  border: 1px solid rgba(255, 231, 174, .58);
}

.home-oracle-moon {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background:
    radial-gradient(circle at 42% 42%, rgba(255, 245, 204, .95), rgba(220, 174, 84, .84) 44%, rgba(82, 57, 24, .92) 74%, rgba(9, 7, 10, .96) 76%);
  box-shadow: 0 0 18px rgba(241, 205, 125, .28), inset 0 0 0 1px rgba(255, 237, 178, .42);
}

.home-oracle-moon::before {
  content: "";
  position: absolute;
  inset: 11%;
  border-radius: 999px;
  border: 1px solid rgba(255, 235, 164, .42);
}

.home-oracle-moon::after {
  content: "";
  position: absolute;
  inset: 18% 14% 18% 36%;
  border-radius: 999px;
  background: rgba(8, 6, 10, .94);
  box-shadow: inset 10px 0 12px rgba(255, 231, 174, .08);
}

.category-lock {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  width: clamp(34px, 4.4vw, 46px);
  height: clamp(34px, 4.4vw, 46px);
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: color-mix(in srgb, var(--accent-2) 78%, transparent);
  background: rgba(8, 6, 8, .52);
  box-shadow: 0 10px 24px rgba(0, 0, 0, .28), inset 0 0 0 1px rgba(255, 231, 174, .26);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.category-lock .ui-icon {
  width: 56%;
  height: 56%;
  stroke-width: 2.2;
}

/* 카테고리 이름 라벨 — 모바일 캐러셀의 현재(중앙) 카드에서만 아이콘 밑에 노출(아래 미디어쿼리). */
.category-symbol-label {
  display: none;
}

@media (max-width: 819px) {
  body[data-service="home"] .home-oracle-object {
    left: auto;
    right: max(12px, env(safe-area-inset-right));
    top: max(4px, env(safe-area-inset-top));
    width: 54px;
    height: 54px;
    transform: none;
  }

  body[data-service="home"] .home-oracle-object:hover,
  body[data-service="home"] .home-oracle-object:focus-visible {
    transform: translateY(-1px) scale(1.04);
  }

  body[data-service="home"] .category-grid {
    position: relative;
    display: block;
    width: 100%;
    height: min(540px, calc(100dvh - 112px));
    min-height: 300px;
    margin-inline: auto;
    touch-action: pan-y;
    user-select: none;
  }

  body[data-service="home"] .category-grid.is-dragging {
    cursor: grabbing;
  }

  body[data-service="home"] .category-symbol-card,
  body[data-service="home"] .category-symbol-card.is-disabled,
  body[data-service="home"] .category-symbol-card:hover,
  body[data-service="home"] .category-symbol-card:focus-visible,
  body[data-service="home"] .category-symbol-card.is-active {
    --symbol-size: clamp(280px, 88vw, 420px);
    position: absolute;
    left: 50%;
    top: 50%;
    width: var(--symbol-size);
    height: var(--symbol-size);
    flex-basis: var(--symbol-size);
    opacity: .48;
    z-index: 2;
    transform:
      translate(calc(-50% + (var(--carousel-offset) * min(70vw, 284px)) + var(--home-drag-x, 0px)), -50%)
      scale(.66);
    transition: transform .28s cubic-bezier(.2, .74, .22, 1), opacity .22s ease, filter .22s ease;
  }

  body[data-service="home"] .category-grid.is-dragging .category-symbol-card {
    transition: opacity .18s ease, filter .18s ease;
  }

  body[data-service="home"] .category-symbol-card.is-carousel-current,
  body[data-service="home"] .category-symbol-card.is-disabled.is-carousel-current,
  body[data-service="home"] .category-symbol-card.is-carousel-current:hover,
  body[data-service="home"] .category-symbol-card.is-carousel-current:focus-visible {
    opacity: 1;
    z-index: 5;
    transform: translate(calc(-50% + var(--home-drag-x, 0px)), -50%) scale(1);
  }

  /* 현재 카드 이름을 아이콘 밑에 표시(모바일 한정). 카드에 앵커돼 scale·드래그와 함께 움직인다. */
  body[data-service="home"] .category-symbol-card.is-carousel-current .category-symbol-label {
    display: block;
    position: absolute;
    left: 50%;
    top: calc(100% + clamp(12px, 4vw, 28px));
    transform: translateX(-50%);
    white-space: nowrap;
    font-size: clamp(1.4rem, 7vw, 2.1rem);
    letter-spacing: .16em;
    color: var(--accent-2, #fff0bf);
    text-shadow: 0 2px 14px rgba(0, 0, 0, .62);
    pointer-events: none;
  }

  body[data-service="home"] .category-symbol-card.is-carousel-near {
    opacity: .36;
    z-index: 3;
  }

  body[data-service="home"] .category-symbol-card.is-carousel-far {
    opacity: 0;
    pointer-events: none;
  }

  body[data-service="home"] .category-lock {
    width: 52px;
    height: 52px;
  }
}

/* ── 종합오라클 중심 심볼 ─────────────────────────────────────── */
/* ponytail: 중심 오라클은 메달리온 PNG로 채워 다른 5개와 동질감을 준다. 꼭짓점(최대 198px)보다는 작게 두되
   빈약해 보이지 않게 상향. 정확한 값은 실제 oracle.png로 브라우저에서 미세 조정 필요. */
.category-center-card { --symbol-size: clamp(124px, 11.4vw, 168px); z-index: 3; }

/* ── 오늘의 종합오라클 (배경 패널 없이 평문 + 금색 강조) ─────────────── */
.oracle-daily {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
  padding: 10px 0 4px;
}
.oracle-daily-date {
  margin: 0;
  font-size: .82rem;
  letter-spacing: .08em;
  color: color-mix(in srgb, var(--text) 66%, transparent);
}
.oracle-daily-ganji {
  margin: 0;
  font-size: 1.5rem;
  color: var(--accent, #d7b46c);
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
}
.oracle-daily-hanja {
  font-size: 1.02rem;
  letter-spacing: .12em;
  color: color-mix(in srgb, var(--accent, #d7b46c) 78%, var(--text));
}
.oracle-daily-relation {
  margin: 0;
  font-size: .98rem;
  color: color-mix(in srgb, var(--text) 88%, transparent);
}
.oracle-daily-lede {
  margin: 2px 0 0;
  max-width: 32ch;
  font-size: .9rem;
  line-height: 1.65;
  color: color-mix(in srgb, var(--text) 70%, transparent);
}
.oracle-daily-action {
  margin-top: 6px;
}

/* 운명 산물 이미지 내보내기 버튼 */
.reading-export {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

/* 짧은 높이(가로 모드 등): 근거·헤더·네비를 줄여 리딩 카드에 공간을 준다(스크롤 대신).
   base .evidence-stack(위)보다 뒤에 와야 이긴다. */
@media (max-height: 600px) {
  .result-panel { gap: 8px; }
  .result-head h2 { margin-top: 2px; font-size: 1.02rem; }
  .result-head .eyebrow { font-size: .64rem; }
  .evidence-stack { display: none; }
  .card-pager-nav { padding-top: 6px; gap: 10px; }
  .card-pager-arrow { width: 28px; height: 28px; font-size: .9rem; }
}
