:root {
  color-scheme: dark;
  --bg: #15120d;
  --bg-soft: #211b13;
  --panel: rgba(250, 239, 213, 0.08);
  --panel-strong: rgba(250, 239, 213, 0.13);
  --paper: #f4ead4;
  --paper-muted: #cdbf9e;
  --ink: #17130d;
  --line: rgba(231, 209, 156, 0.22);
  --gold: #d1aa55;
  --gold-strong: #f1cf75;
  --jade: #7bb59b;
  --jade-deep: #1f5f50;
  --error: #e58e72;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
  --serif: "Noto Serif TC", "Cormorant Garamond", serif;
  --sans: "Inter", "Noto Serif TC", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 12% 12%, rgba(123, 181, 155, 0.22), transparent 26rem),
    radial-gradient(circle at 92% 10%, rgba(209, 170, 85, 0.18), transparent 28rem),
    linear-gradient(135deg, #100d09 0%, #1d1711 48%, #251d12 100%);
  color: var(--paper);
  font-family: var(--sans);
  overflow-x: hidden;
}

button,
textarea,
select {
  font: inherit;
}

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

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

.cosmos {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(244, 234, 212, 0.7) 0 1px, transparent 1.5px),
    linear-gradient(110deg, transparent 0 46%, rgba(209, 170, 85, 0.08) 47%, transparent 54%);
  background-size: 120px 120px, 100% 100%;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 82%);
  opacity: 0.28;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto auto;
  align-items: center;
  gap: 24px;
  padding: 18px clamp(18px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
  background: rgba(17, 13, 8, 0.82);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(209, 170, 85, 0.6);
  border-radius: 50%;
  background:
    radial-gradient(circle at 36% 28%, #f3d77c, #a77428 58%, #654417 100%);
  color: #17110a;
  font-family: var(--serif);
  font-weight: 800;
  box-shadow: inset 0 0 0 5px rgba(35, 22, 8, 0.28);
}

.brand strong {
  display: block;
  font-family: var(--serif);
  font-size: 18px;
  letter-spacing: 0;
}

.brand small,
.system-label {
  display: block;
  color: var(--gold);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav,
.language,
.ai-links,
.controls,
.history-actions,
.method-list {
  display: flex;
  align-items: center;
}

.nav {
  gap: 4px;
}

.nav a,
.language {
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--paper-muted);
  font-size: 14px;
  font-weight: 600;
}

.nav a {
  padding: 10px 12px;
  white-space: nowrap;
}

.nav a:hover,
.nav a:focus-visible {
  border-color: var(--line);
  color: var(--paper);
  outline: none;
}

.language {
  gap: 8px;
  padding: 10px 12px;
  background: rgba(244, 234, 212, 0.06);
}

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

.language a[aria-current="page"] {
  color: var(--paper);
}

main {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 34px;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 42px clamp(18px, 4vw, 56px) 72px;
}

.success-main {
  min-height: 100svh;
  place-items: center;
}

.success-shell {
  display: grid;
  width: min(100%, 680px);
  justify-items: center;
  gap: 16px;
  padding: clamp(28px, 5vw, 54px);
  border: 1px solid rgba(209, 170, 85, 0.3);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 20%, rgba(209, 170, 85, 0.18), transparent 18rem),
    linear-gradient(145deg, rgba(250, 239, 213, 0.12), rgba(250, 239, 213, 0.045)),
    rgba(18, 14, 9, 0.84);
  box-shadow: var(--shadow);
  text-align: center;
}

.success-mark {
  display: grid;
  width: 82px;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid rgba(247, 219, 140, 0.9);
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 28%, #f8dc84 0, #c88a2b 48%, #7a4614 100%);
  color: #170d05;
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 900;
  box-shadow:
    inset 0 0 0 8px rgba(57, 31, 7, 0.24),
    0 18px 42px rgba(0, 0, 0, 0.34);
}

.success-status {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(123, 181, 155, 0.3);
  border-radius: 8px;
  background: rgba(12, 39, 34, 0.32);
  color: #cbeedd;
  font-weight: 900;
}

.success-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.success-note {
  max-width: 520px;
  color: var(--paper-muted);
  font-size: 12px;
  line-height: 1.6;
}

.oracle-prep {
  position: relative;
  display: grid;
  min-height: calc(100svh - 154px);
  place-items: center;
  scroll-margin-top: 112px;
  overflow: hidden;
  border: 1px solid rgba(209, 170, 85, 0.28);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 38%, rgba(143, 46, 35, 0.22), transparent 16rem),
    radial-gradient(circle at 24% 80%, rgba(31, 95, 80, 0.24), transparent 24rem),
    linear-gradient(135deg, rgba(28, 14, 9, 0.96), rgba(10, 28, 24, 0.94) 48%, rgba(42, 30, 15, 0.96)),
    #17110a;
  color: var(--paper);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.34);
}

.oracle-prep::before,
.oracle-prep::after {
  position: absolute;
  pointer-events: none;
  content: "";
}

.oracle-prep::before {
  inset: 18px;
  border: 1px solid rgba(209, 170, 85, 0.16);
  background:
    linear-gradient(rgba(209, 170, 85, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(209, 170, 85, 0.06) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.82), transparent 72%);
}

.oracle-prep::after {
  right: clamp(22px, 5vw, 72px);
  bottom: clamp(22px, 5vw, 66px);
  width: 70px;
  height: 70px;
  border: 1px solid rgba(143, 46, 35, 0.58);
  background: rgba(143, 46, 35, 0.12);
  box-shadow: inset 0 0 0 8px rgba(143, 46, 35, 0.12);
}

.prep-inner {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  width: min(100%, 620px);
  padding: clamp(28px, 4vw, 42px) 22px;
  text-align: center;
}

.prep-symbol {
  position: relative;
  width: clamp(148px, 13vw, 176px);
  aspect-ratio: 1;
  margin-bottom: clamp(16px, 3vw, 24px);
  border-radius: 50%;
}

.prep-symbol::before,
.prep-symbol::after {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  content: "";
}

.prep-symbol::before {
  border: 1px solid rgba(209, 170, 85, 0.26);
  background:
    conic-gradient(from 22.5deg, rgba(209, 170, 85, 0.16) 0 7deg, transparent 7deg 45deg),
    radial-gradient(circle, transparent 0 42%, rgba(209, 170, 85, 0.12) 43% 44%, transparent 45%);
}

.prep-symbol::after {
  inset: 22px;
  border: 1px solid rgba(123, 181, 155, 0.22);
}

.prep-bagua span {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid rgba(209, 170, 85, 0.28);
  border-radius: 50%;
  color: rgba(244, 234, 212, 0.86);
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 800;
  background: rgba(18, 14, 9, 0.7);
}

.prep-bagua span:nth-child(1) {
  transform: translate(-50%, -50%) translateY(-76px);
}

.prep-bagua span:nth-child(2) {
  transform: translate(-50%, -50%) translate(54px, -54px);
}

.prep-bagua span:nth-child(3) {
  transform: translate(-50%, -50%) translateX(76px);
}

.prep-bagua span:nth-child(4) {
  transform: translate(-50%, -50%) translate(54px, 54px);
}

.prep-bagua span:nth-child(5) {
  transform: translate(-50%, -50%) translateY(76px);
}

.prep-bagua span:nth-child(6) {
  transform: translate(-50%, -50%) translate(-54px, 54px);
}

.prep-bagua span:nth-child(7) {
  transform: translate(-50%, -50%) translateX(-76px);
}

.prep-bagua span:nth-child(8) {
  transform: translate(-50%, -50%) translate(-54px, -54px);
}

.prep-coin-large {
  position: absolute;
  inset: 50%;
  z-index: 3;
  display: grid;
  width: clamp(74px, 9vw, 94px);
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid rgba(247, 219, 140, 0.9);
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 28%, #f8dc84 0, #c88a2b 48%, #7a4614 100%);
  color: #170d05;
  box-shadow:
    inset 0 0 0 8px rgba(57, 31, 7, 0.24),
    0 18px 42px rgba(0, 0, 0, 0.34);
  transform: translate(-50%, -50%);
}

.prep-coin-large span {
  display: grid;
  width: 42%;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid rgba(63, 33, 9, 0.62);
  font-family: var(--serif);
  font-size: clamp(22px, 3vw, 31px);
  font-weight: 800;
  line-height: 1;
}

.prep-kicker {
  margin: 0 0 14px;
  color: var(--gold-strong);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.prep-title {
  max-width: 520px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: clamp(42px, 4.6vw, 56px);
  font-weight: 800;
  line-height: 0.98;
  text-shadow: 0 14px 32px rgba(0, 0, 0, 0.32);
}

.prep-title span {
  display: block;
}

.prep-coin-row {
  display: flex;
  gap: 12px;
  margin: clamp(14px, 2vw, 20px) 0;
}

.prep-coin-row span {
  display: grid;
  width: 44px;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid rgba(247, 219, 140, 0.82);
  border-radius: 50%;
  color: #190f07;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 800;
  background:
    radial-gradient(circle at 36% 30%, #f6dd8b, #bd7b25 55%, #6b3f14 100%);
  box-shadow: inset 0 0 0 5px rgba(53, 32, 8, 0.2);
}

.prep-coin-row span:nth-child(2) {
  border-color: rgba(174, 231, 204, 0.76);
  background:
    radial-gradient(circle at 34% 28%, #c6f2d4, #679977 52%, #244e3e 100%);
}

.prep-copy {
  max-width: 430px;
  margin: 0;
  color: var(--paper-muted);
  font-size: 16px;
  line-height: 1.62;
}

.prep-start {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 220px;
  min-height: 48px;
  margin-top: clamp(16px, 2vw, 22px);
  border: 1px solid rgba(247, 219, 140, 0.72);
  color: #190f07;
  font-weight: 800;
  background: linear-gradient(135deg, #f1cf75, #b87425);
  box-shadow: 0 14px 34px rgba(169, 109, 34, 0.24);
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.prep-start:hover,
.prep-start:focus-visible {
  color: #100a05;
  background: linear-gradient(135deg, #f6db89, #c9892f);
  outline: none;
  transform: translateY(-1px);
}

.oracle-shell {
  display: grid;
  grid-template-columns: minmax(340px, 1.02fr) minmax(320px, 0.86fr) minmax(270px, 0.58fr);
  gap: 18px;
  align-items: stretch;
  scroll-margin-top: 112px;
}

.intro-panel,
.hexagram-panel,
.reading-panel,
.prompt-section,
.history-section,
.info-grid {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(250, 239, 213, 0.12), rgba(250, 239, 213, 0.045)),
    rgba(18, 14, 9, 0.7);
  box-shadow: var(--shadow);
}

.intro-panel {
  padding: clamp(22px, 3vw, 38px);
}

h1,
h2 {
  margin: 0;
  color: var(--paper);
  font-family: var(--serif);
  letter-spacing: 0;
}

h1 {
  max-width: 680px;
  margin-top: 12px;
  font-size: clamp(40px, 4.7vw, 66px);
  line-height: 1.02;
  overflow-wrap: anywhere;
}

h1 span {
  display: block;
}

h2 {
  font-size: clamp(28px, 3vw, 44px);
  line-height: 1.08;
}

.lead,
.info-grid p,
.history-actions p,
#castStatus {
  color: var(--paper-muted);
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.method-note {
  margin: 10px 0 0;
  color: rgba(203, 238, 221, 0.82);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.6;
}

.lead {
  max-width: 690px;
  margin: 18px 0 24px;
  font-size: 16px;
  word-break: break-all;
}

.usage-section {
  scroll-margin-top: 112px;
}

.usage-grid,
.risk-list {
  display: grid;
  gap: 14px;
}

.usage-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.usage-grid article,
.risk-list article {
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.045);
}

.usage-grid article {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 16px;
}

.usage-grid span {
  color: var(--gold-strong);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.usage-grid strong,
.risk-list strong {
  color: var(--paper);
  font-family: var(--serif);
  line-height: 1.2;
}

.usage-grid strong {
  font-size: 21px;
}

.usage-grid p,
.risk-list p {
  margin: 0;
  color: var(--paper-muted);
  line-height: 1.62;
}

.field-label {
  display: block;
  margin: 18px 0 9px;
  color: var(--gold-strong);
  font-size: 13px;
  font-weight: 700;
}

textarea,
select {
  width: 100%;
  border: 1px solid rgba(231, 209, 156, 0.28);
  border-radius: 8px;
  background: rgba(10, 8, 5, 0.54);
  color: var(--paper);
  outline: none;
}

textarea {
  min-height: 104px;
  resize: vertical;
  padding: 16px;
  line-height: 1.6;
}

textarea:focus,
select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(209, 170, 85, 0.13);
}

textarea::placeholder {
  color: rgba(205, 191, 158, 0.58);
}

.input-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  color: rgba(205, 191, 158, 0.75);
  font-size: 12px;
}

.scenario-entry {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(209, 170, 85, 0.24);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(209, 170, 85, 0.12), rgba(123, 181, 155, 0.08)),
    rgba(10, 8, 5, 0.32);
}

.scenario-entry strong {
  color: var(--gold-strong);
  font-size: 13px;
  font-weight: 900;
}

.scenario-entry-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.scenario-entry button {
  min-height: 42px;
  border: 1px solid rgba(247, 219, 140, 0.34);
  border-radius: 8px;
  background: rgba(28, 22, 13, 0.72);
  color: var(--paper);
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.scenario-entry button:hover,
.scenario-entry button:focus-visible {
  border-color: rgba(247, 219, 140, 0.78);
  background: rgba(65, 46, 20, 0.84);
  outline: none;
  transform: translateY(-1px);
}

.scenario-entry small {
  color: rgba(203, 238, 221, 0.82);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
}

.question-helper {
  margin-top: 12px;
  padding: 14px;
  border: 1px solid rgba(123, 181, 155, 0.24);
  border-radius: 8px;
  background: rgba(12, 39, 34, 0.28);
}

.question-helper strong {
  display: block;
  color: #cbeedd;
  font-size: 13px;
  font-weight: 900;
}

.question-helper ul {
  display: grid;
  gap: 6px;
  margin: 8px 0 0;
  padding-left: 18px;
}

.question-helper li {
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.55;
}

.text-button {
  border: 0;
  background: transparent;
  color: var(--jade);
  cursor: pointer;
  font-weight: 700;
}

.coin-stage {
  margin: 22px 0;
  padding: 16px;
  border: 1px solid rgba(123, 181, 155, 0.22);
  border-radius: 8px;
  background: rgba(19, 50, 43, 0.22);
}

.coin-tray {
  display: flex;
  gap: 12px;
  align-items: center;
  min-height: 76px;
}

.coin {
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  border: 1px solid rgba(248, 215, 127, 0.72);
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 28%, #ffe8a0, #c39138 54%, #694515 100%);
  color: #1c1308;
  cursor: default;
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 800;
  box-shadow:
    inset 0 0 0 8px rgba(53, 32, 8, 0.22),
    0 12px 26px rgba(0, 0, 0, 0.28);
  transform-style: preserve-3d;
}

.coin[data-face="背"] {
  background:
    radial-gradient(circle at 34% 28%, #c6f2d4, #679977 52%, #244e3e 100%);
  color: #071711;
}

.coin.is-tossing {
  animation: toss 0.62s ease-in-out;
}

@keyframes toss {
  0% {
    transform: translateY(0) rotateY(0) rotateX(0);
  }
  45% {
    transform: translateY(-20px) rotateY(440deg) rotateX(180deg);
  }
  100% {
    transform: translateY(0) rotateY(720deg) rotateX(360deg);
  }
}

.controls {
  flex-wrap: wrap;
  gap: 10px;
}

.gesture-panel {
  display: grid;
  gap: 14px;
  scroll-margin-top: 112px;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid rgba(123, 181, 155, 0.26);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(12, 39, 34, 0.52), rgba(10, 8, 5, 0.28));
}

.gesture-copy strong {
  display: block;
  margin-top: 6px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.18;
}

.gesture-copy p,
.gesture-status {
  margin: 8px 0 0;
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.65;
}

.camera-frame {
  position: relative;
  display: grid;
  min-height: 180px;
  overflow: hidden;
  place-items: center;
  border: 1px solid rgba(231, 209, 156, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(244, 234, 212, 0.05), transparent),
    rgba(5, 8, 6, 0.74);
}

.camera-frame video,
.camera-frame canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scaleX(-1);
}

.camera-frame:not(.is-active) video,
.camera-frame:not(.is-active) canvas {
  display: none;
}

.camera-frame span {
  position: relative;
  z-index: 2;
  padding: 9px 12px;
  border: 1px solid rgba(231, 209, 156, 0.2);
  border-radius: 999px;
  background: rgba(17, 13, 8, 0.72);
  color: var(--paper-muted);
  font-size: 12px;
  font-weight: 800;
}

.camera-frame.is-active span {
  position: absolute;
  right: 10px;
  bottom: 10px;
  color: #d1f1e3;
}

.camera-frame.is-triggered {
  border-color: rgba(241, 207, 117, 0.72);
  box-shadow: 0 0 0 4px rgba(209, 170, 85, 0.12);
}

.camera-frame.is-audio-hot span {
  border-color: rgba(241, 207, 117, 0.54);
  color: var(--gold-strong);
}

.gesture-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.sensitivity-control {
  display: grid;
  grid-template-columns: 1fr 150px;
  align-items: center;
  gap: 12px;
  color: var(--paper-muted);
  font-size: 12px;
  font-weight: 800;
}

.sensitivity-control select {
  min-height: 42px;
  border: 1px solid rgba(231, 209, 156, 0.28);
  border-radius: 8px;
  background: rgba(7, 6, 4, 0.52);
  color: var(--paper);
  font: inherit;
  padding: 0 12px;
}

.gesture-diagnostics {
  display: grid;
  gap: 10px;
  padding-top: 2px;
}

.signal-row {
  display: grid;
  grid-template-columns: 86px minmax(90px, 1fr) 88px;
  align-items: center;
  gap: 10px;
  color: var(--paper-muted);
  font-size: 12px;
  font-weight: 800;
}

.signal-track {
  height: 9px;
  overflow: hidden;
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 999px;
  background: rgba(7, 6, 4, 0.44);
}

.signal-track i {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--jade), var(--gold-strong));
  transition: width 0.08s linear;
}

.signal-row strong {
  color: var(--paper);
  font-size: 11px;
  text-align: right;
}

.primary-button,
.ghost-button,
.primary-link {
  min-height: 46px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 800;
}

.primary-button,
.primary-link {
  border: 1px solid rgba(247, 219, 140, 0.78);
  background: linear-gradient(135deg, #f2d57f, #b87a28);
  color: #191107;
  box-shadow: 0 14px 34px rgba(169, 109, 34, 0.26);
}

.primary-button,
.ghost-button {
  padding: 0 18px;
}

.primary-button:disabled,
.ghost-button:disabled {
  cursor: not-allowed;
  filter: grayscale(0.7);
  opacity: 0.45;
}

.ghost-button {
  border: 1px solid rgba(231, 209, 156, 0.28);
  background: rgba(244, 234, 212, 0.06);
  color: var(--paper);
}

.ghost-button:hover:not(:disabled),
.primary-button:hover:not(:disabled),
.primary-link:hover {
  transform: translateY(-1px);
}

.hexagram-panel,
.reading-panel {
  padding: 22px;
}

.panel-heading {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  color: var(--paper-muted);
  font-weight: 700;
}

.panel-heading strong {
  color: var(--gold-strong);
}

.line-stack {
  display: grid;
  gap: 14px;
  min-height: 438px;
  padding: 12px 4px;
}

.line-row {
  display: grid;
  grid-template-columns: 74px 1fr 74px;
  align-items: center;
  gap: 12px;
  min-height: 58px;
}

.line-row small,
.line-row .line-type {
  color: rgba(205, 191, 158, 0.72);
  font-size: 12px;
  font-weight: 700;
}

.line-row .line-type {
  text-align: right;
}

.yao {
  position: relative;
  height: 18px;
}

.yao::before,
.yao::after {
  position: absolute;
  top: 0;
  height: 18px;
  border-radius: 2px;
  content: "";
}

.yao.empty::before {
  right: 0;
  left: 0;
  border: 1px dashed rgba(205, 191, 158, 0.24);
  background: transparent;
}

.yao.yang::before {
  right: 0;
  left: 0;
  background: linear-gradient(90deg, #efe0ac, #bd8f3e);
}

.yao.yin::before,
.yao.yin::after {
  width: 43%;
  background: linear-gradient(90deg, #efe0ac, #bd8f3e);
}

.yao.yin::before {
  left: 0;
}

.yao.yin::after {
  right: 0;
}

.yao.moving {
  filter: drop-shadow(0 0 12px rgba(123, 181, 155, 0.44));
}

.yao.moving span {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 50%;
  background: var(--jade);
  color: #081711;
  font-size: 12px;
  font-weight: 900;
  transform: translate(-50%, -50%);
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--paper-muted);
  font-size: 12px;
}

.legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.legend i {
  display: inline-block;
  width: 24px;
  height: 8px;
  border-radius: 2px;
  background: var(--gold);
}

.legend-yin {
  background: linear-gradient(90deg, var(--gold) 0 42%, transparent 42% 58%, var(--gold) 58% 100%) !important;
}

.legend-moving {
  background: var(--jade) !important;
}

.reading-panel {
  display: grid;
  align-content: start;
  gap: 12px;
}

.result-card {
  padding: 16px;
  border: 1px solid rgba(231, 209, 156, 0.2);
  border-radius: 8px;
  background: rgba(7, 6, 4, 0.3);
}

.result-card span,
.result-card small {
  display: block;
  color: var(--paper-muted);
}

.result-card span {
  font-size: 12px;
  font-weight: 800;
}

.result-card strong {
  display: block;
  margin: 8px 0 6px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1.15;
}

.result-card small {
  font-size: 12px;
  line-height: 1.45;
}

.result-share-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(241, 207, 117, 0.42);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(241, 207, 117, 0.14), rgba(123, 181, 155, 0.1)),
    rgba(7, 6, 4, 0.34);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
}

.result-share-panel[hidden] {
  display: none;
}

.result-share-panel span {
  color: var(--gold-strong);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.result-share-panel strong {
  display: block;
  margin-top: 5px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 23px;
  line-height: 1.16;
}

.result-share-panel p {
  margin: 6px 0 0;
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.58;
}

.result-share-panel .primary-button {
  flex: 1 1 160px;
}

.result-share-panel .ghost-button {
  flex: 1 1 110px;
}

.prompt-tuning-card {
  display: grid;
  gap: 10px;
  padding: 15px;
  border: 1px solid rgba(231, 209, 156, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(123, 181, 155, 0.09), rgba(241, 207, 117, 0.06)),
    rgba(7, 6, 4, 0.28);
}

.prompt-tuning-head {
  display: grid;
  gap: 4px;
}

.prompt-tuning-head span,
.prompt-mode-summary > span {
  color: var(--gold-strong);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.prompt-tuning-head strong {
  color: var(--paper);
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.16;
}

.prompt-tuning-card .field-label {
  margin: 7px 0 0;
}

.prompt-style-note {
  color: var(--paper-muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

select {
  height: 44px;
  padding: 0 12px;
}

.ai-links {
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.ai-links a {
  padding: 9px 10px;
  border: 1px solid rgba(123, 181, 155, 0.34);
  border-radius: 8px;
  color: #bde8d5;
  font-size: 13px;
  font-weight: 800;
}

.prompt-section,
.history-section,
.info-grid {
  padding: clamp(22px, 3vw, 34px);
}

.section-heading {
  margin-bottom: 18px;
}

.section-heading .system-label {
  margin-bottom: 8px;
}

.prompt-mode-summary {
  display: grid;
  grid-template-columns: minmax(120px, 0.24fr) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid rgba(123, 181, 155, 0.25);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(31, 95, 80, 0.24), rgba(241, 207, 117, 0.06)),
    rgba(7, 6, 4, 0.24);
}

.prompt-mode-summary strong {
  display: block;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.2;
}

.prompt-mode-summary p {
  margin: 5px 0 0;
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.55;
}

.prompt-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 18px;
}

.prompt-card,
.pro-card,
.share-card-panel {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 8px;
  background: rgba(8, 9, 6, 0.45);
}

.prompt-card {
  grid-row: span 2;
}

.mini-heading {
  display: grid;
  gap: 5px;
}

.mini-heading span {
  color: var(--gold-strong);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.mini-heading strong {
  color: var(--paper);
  font-family: var(--serif);
  font-size: 22px;
}

#promptOutput,
#proPromptOutput {
  min-height: 330px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 13px;
  white-space: pre-wrap;
}

#proPromptOutput {
  min-height: 260px;
}

.pro-copy,
.pro-card small {
  margin: 0;
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.6;
}

.pro-preview {
  padding: 14px;
  border: 1px dashed rgba(241, 207, 117, 0.34);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(241, 207, 117, 0.1), rgba(123, 181, 155, 0.08));
  color: var(--paper);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.55;
}

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

.pro-compare div,
.fulfillment-grid article,
.price-card {
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.045);
}

.pro-compare div {
  display: grid;
  gap: 6px;
  padding: 12px;
}

.pro-compare span,
.price-card span {
  color: var(--gold-strong);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pro-compare strong {
  color: var(--paper);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.2;
}

.pro-compare p {
  margin: 0;
  color: var(--paper-muted);
  font-size: 12px;
  line-height: 1.55;
}

.unlock-row,
.pro-actions,
.result-cta-actions,
.cta-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.conversion-path {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.conversion-path article {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 16px;
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.045);
}

.conversion-path article.is-paid {
  border-color: rgba(241, 207, 117, 0.42);
  background:
    linear-gradient(145deg, rgba(241, 207, 117, 0.14), rgba(123, 181, 155, 0.08)),
    rgba(244, 234, 212, 0.05);
}

.conversion-path span,
.result-cta-bar span {
  color: var(--gold-strong);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.conversion-path strong {
  color: var(--paper);
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.18;
}

.conversion-path p {
  margin: 0;
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.58;
}

.conversion-path .primary-link,
.conversion-path .ghost-link,
.conversion-path .ghost-button {
  width: 100%;
  min-height: 44px;
}

.prompt-delivery-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(123, 181, 155, 0.28);
  border-radius: 8px;
  background: rgba(12, 39, 34, 0.26);
}

.prompt-delivery-strip strong {
  flex: 1 1 120px;
  color: #cbeedd;
  font-family: var(--serif);
  font-size: 17px;
}

.prompt-delivery-strip span {
  padding: 7px 9px;
  border: 1px solid rgba(123, 181, 155, 0.28);
  border-radius: 8px;
  color: var(--paper-muted);
  font-size: 12px;
  font-weight: 800;
}

.result-cta-bar {
  position: sticky;
  bottom: 12px;
  z-index: 18;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-top: 18px;
  padding: 14px;
  border: 1px solid rgba(241, 207, 117, 0.36);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(31, 95, 80, 0.72), rgba(28, 14, 9, 0.92)),
    rgba(17, 13, 8, 0.94);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(16px);
}

.result-cta-bar strong {
  display: block;
  margin-top: 4px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.2;
}

.result-cta-actions {
  justify-content: flex-end;
}

.unlock-row input {
  min-width: 0;
  flex: 1 1 150px;
  height: 46px;
}

.share-card-panel {
  align-content: start;
}

#shareCanvas {
  width: 100%;
  max-width: 300px;
  border: 1px solid rgba(231, 209, 156, 0.2);
  border-radius: 8px;
  background: #10130d;
}

.share-actions,
.social-share-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.share-actions .primary-button,
.share-actions .ghost-button {
  min-height: 42px;
}

.social-share-links a {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid rgba(123, 181, 155, 0.28);
  border-radius: 8px;
  background: rgba(12, 39, 34, 0.28);
  color: #cbeedd;
  font-size: 12px;
  font-weight: 900;
}

.share-note {
  color: var(--paper-muted);
  font-size: 12px;
  line-height: 1.55;
}

.library-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
}

.fulfillment-grid,
.pricing-grid {
  display: grid;
  gap: 14px;
}

.fulfillment-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.fulfillment-grid article {
  padding: 16px;
}

.fulfillment-grid strong,
.price-card strong {
  display: block;
  color: var(--paper);
  font-family: var(--serif);
  line-height: 1.18;
}

.fulfillment-grid strong {
  font-size: 21px;
}

.fulfillment-grid p,
.price-card p,
.price-card li {
  color: var(--paper-muted);
  line-height: 1.62;
}

.fulfillment-grid p,
.price-card p {
  margin: 10px 0 0;
}

.fulfillment-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.payment-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid rgba(123, 181, 155, 0.26);
  border-radius: 8px;
  background: rgba(12, 39, 34, 0.28);
}

.payment-checklist strong {
  flex: 1 1 210px;
  color: #cbeedd;
  font-family: var(--serif);
  font-size: 18px;
}

.payment-checklist span {
  padding: 8px 10px;
  border: 1px solid rgba(123, 181, 155, 0.28);
  border-radius: 8px;
  color: var(--paper-muted);
  font-size: 13px;
  font-weight: 800;
}

.pricing-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.tier-disclaimer {
  display: grid;
  gap: 8px;
  margin: -4px 0 16px;
  padding: 16px;
  border: 1px solid rgba(123, 181, 155, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(31, 95, 80, 0.23), rgba(241, 207, 117, 0.07)),
    rgba(7, 6, 4, 0.28);
}

.tier-disclaimer strong {
  color: #cbeedd;
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.2;
}

.tier-disclaimer p {
  max-width: 980px;
  margin: 0;
  color: var(--paper-muted);
  font-size: 15px;
  line-height: 1.78;
}

.price-card {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 18px;
}

.price-card.is-featured {
  border-color: rgba(241, 207, 117, 0.46);
  background:
    linear-gradient(145deg, rgba(241, 207, 117, 0.13), rgba(123, 181, 155, 0.08)),
    rgba(244, 234, 212, 0.045);
}

.price-card strong {
  font-size: 24px;
}

.price {
  color: var(--gold-strong);
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
}

.price-card ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding-left: 19px;
}

.price-card .primary-link {
  width: 100%;
  margin-top: 2px;
}

.library-intro p {
  margin: 0;
  color: var(--paper-muted);
}

.history-actions {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.history-actions p {
  margin: 0;
}

.history-list {
  display: grid;
  gap: 10px;
}

.history-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.045);
}

.history-item strong {
  display: block;
  margin-bottom: 4px;
  font-family: var(--serif);
  font-size: 18px;
}

.history-item span {
  display: block;
  color: var(--paper-muted);
  font-size: 13px;
  line-height: 1.45;
}

.history-item button {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(231, 209, 156, 0.18);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.06);
  color: var(--paper);
  cursor: pointer;
  font-weight: 800;
}

.history-empty {
  padding: 24px;
  border: 1px dashed rgba(231, 209, 156, 0.24);
  border-radius: 8px;
  color: var(--paper-muted);
  text-align: center;
}

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

.info-grid p {
  max-width: 760px;
  margin: 14px 0 0;
}

.primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  white-space: nowrap;
}

.ghost-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid rgba(231, 209, 156, 0.28);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.06);
  color: var(--paper);
  font-weight: 800;
  white-space: nowrap;
}

.method-list {
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.method-list span {
  padding: 10px 12px;
  border: 1px solid rgba(123, 181, 155, 0.32);
  border-radius: 8px;
  color: #cbeedd;
  font-size: 13px;
  font-weight: 800;
}

.trust-grid {
  scroll-margin-top: 112px;
}

.trust-list {
  max-width: 430px;
}

.risk-section {
  scroll-margin-top: 112px;
}

.risk-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.risk-list article {
  padding: 16px;
}

.risk-list strong {
  display: block;
  margin-bottom: 8px;
  font-size: 20px;
}

.seo-main {
  max-width: 1120px;
}

.seo-page h1 {
  margin: 0 0 18px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.08;
}

.seo-page h2 {
  margin: 24px 0 10px;
  color: var(--gold-strong);
  font-family: var(--serif);
  font-size: 26px;
}

.seo-page textarea {
  min-height: 210px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 13px;
}

.hexagram-directory {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.hexagram-directory a,
.seo-facts {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid rgba(231, 209, 156, 0.16);
  border-radius: 8px;
  background: rgba(244, 234, 212, 0.045);
}

.hexagram-directory strong,
.seo-facts span {
  color: var(--gold-strong);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hexagram-directory span,
.seo-facts strong {
  color: var(--paper);
  font-family: var(--serif);
  font-size: 20px;
}

.seo-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 40;
  max-width: min(380px, calc(100vw - 48px));
  padding: 13px 16px;
  border: 1px solid rgba(231, 209, 156, 0.24);
  border-radius: 8px;
  background: rgba(17, 13, 8, 0.92);
  color: var(--paper);
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1180px) {
  .oracle-shell {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.72fr);
  }

  .reading-panel {
    grid-column: 1 / -1;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .reading-panel .field-label,
  .reading-panel select,
  .prompt-tuning-card,
  .ai-links {
    grid-column: 1 / -1;
  }
}

@media (max-width: 820px) {
  .site-header {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }

  .nav {
    grid-column: 1 / -1;
    order: 3;
    overflow-x: auto;
  }

  .oracle-prep {
    min-height: calc(100svh - 172px);
  }

  .oracle-shell {
    grid-template-columns: 1fr;
  }

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

  .line-stack {
    min-height: 392px;
  }

  .line-row {
    grid-template-columns: 58px 1fr 62px;
    gap: 8px;
  }

  .info-grid,
  .history-item,
  .conversion-path,
  .prompt-mode-summary,
  .prompt-layout,
  .library-intro,
  .fulfillment-grid,
  .pricing-grid,
  .usage-grid,
  .risk-list,
  .pro-compare {
    grid-template-columns: 1fr;
  }

  .prompt-card {
    grid-row: auto;
  }

  .method-list {
    justify-content: flex-start;
  }

  .result-cta-bar {
    grid-template-columns: 1fr;
  }

  .result-cta-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  main {
    padding: 24px 14px 56px;
  }

  .site-header {
    padding: 14px;
  }

  .brand small,
  .language {
    display: none;
  }

  h1 {
    font-size: 36px;
    line-height: 1.08;
  }

  .oracle-prep {
    min-height: calc(100svh - 164px);
  }

  .prep-inner {
    padding: 38px 18px 44px;
  }

  .prep-symbol {
    width: 152px;
    margin-bottom: 26px;
  }

  .prep-bagua span {
    width: 29px;
    height: 29px;
    font-size: 15px;
  }

  .prep-bagua span:nth-child(1) {
    transform: translate(-50%, -50%) translateY(-68px);
  }

  .prep-bagua span:nth-child(2) {
    transform: translate(-50%, -50%) translate(48px, -48px);
  }

  .prep-bagua span:nth-child(3) {
    transform: translate(-50%, -50%) translateX(68px);
  }

  .prep-bagua span:nth-child(4) {
    transform: translate(-50%, -50%) translate(48px, 48px);
  }

  .prep-bagua span:nth-child(5) {
    transform: translate(-50%, -50%) translateY(68px);
  }

  .prep-bagua span:nth-child(6) {
    transform: translate(-50%, -50%) translate(-48px, 48px);
  }

  .prep-bagua span:nth-child(7) {
    transform: translate(-50%, -50%) translateX(-68px);
  }

  .prep-bagua span:nth-child(8) {
    transform: translate(-50%, -50%) translate(-48px, -48px);
  }

  .prep-title {
    font-size: 50px;
    line-height: 0.98;
  }

  .prep-copy {
    font-size: 15px;
    line-height: 1.8;
  }

  .prep-start {
    width: min(100%, 220px);
  }

  .scenario-entry-buttons {
    grid-template-columns: 1fr;
  }

  .intro-panel,
  .hexagram-panel,
  .reading-panel,
  .prompt-section,
  .history-section,
  .info-grid {
    padding: 18px;
  }

  .coin-tray {
    display: grid;
    grid-template-columns: repeat(3, 58px);
    justify-content: start;
    gap: 20px;
  }

  .coin {
    width: 58px;
    height: 58px;
  }

  .controls {
    display: grid;
    grid-template-columns: 1fr;
  }

  .gesture-controls {
    display: grid;
    grid-template-columns: 1fr;
  }

  .sensitivity-control {
    grid-template-columns: 1fr;
  }

  .sensitivity-control select {
    width: 100%;
  }

  .signal-row {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .signal-row strong {
    text-align: left;
  }

  .primary-button,
  .ghost-button,
  .result-cta-actions .primary-link,
  .result-cta-actions .ghost-link {
    width: 100%;
  }

  .camera-frame {
    min-height: 170px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
