:root {
  --bg: #07111e;
  --bg-soft: #0b1928;
  --surface: rgba(10, 25, 40, 0.88);
  --surface-solid: #0d2032;
  --text: #f6eddc;
  --muted: #a9a391;
  --accent: #d3a34f;
  --accent-strong: #f0ca7b;
  --line: rgba(211, 163, 79, 0.28);
  --shadow: rgba(0, 0, 0, 0.45);
  --hero-image: url("assets/images/dubai-night.jpg");
  --display: "Cormorant Garamond", "Noto Naskh Arabic", serif;
  --body: "Noto Sans SC", "Noto Naskh Arabic", sans-serif;
  color-scheme: dark;
}

body[data-theme="desert"] {
  --bg: #f2eadb;
  --bg-soft: #e7dcc7;
  --surface: rgba(250, 245, 235, 0.92);
  --surface-solid: #f8f1e4;
  --text: #26382f;
  --muted: #6f7163;
  --accent: #a95f3f;
  --accent-strong: #c17a50;
  --line: rgba(68, 92, 73, 0.22);
  --shadow: rgba(79, 55, 34, 0.2);
  --hero-image: url("assets/images/desert-sunrise.jpg");
  color-scheme: light;
}

body[data-theme="celestial"] {
  --bg: #150f25;
  --bg-soft: #211634;
  --surface: rgba(31, 20, 51, 0.9);
  --surface-solid: #25183b;
  --text: #f3eaf4;
  --muted: #b8a7bd;
  --accent: #b67b62;
  --accent-strong: #d2a085;
  --line: rgba(112, 181, 176, 0.28);
  --shadow: rgba(0, 0, 0, 0.48);
  --hero-image: url("assets/images/desert-night.jpg");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  line-height: 1.7;
  transition: background .5s ease, color .5s ease;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-image: url("assets/images/islamic-geometric-pattern.png");
  background-size: 720px;
  opacity: .035;
  mix-blend-mode: screen;
}
body[data-theme="desert"]::before { opacity: .055; mix-blend-mode: multiply; }
body[data-theme="celestial"]::before { opacity: .05; }
body.modal-open { overflow: hidden; }
button, textarea, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.ambient {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .55;
  z-index: -1;
  background-image: radial-gradient(circle at 15% 20%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 30%),
    radial-gradient(circle at 85% 70%, color-mix(in srgb, var(--accent) 8%, transparent), transparent 34%);
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  height: 76px;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(22px, 5vw, 80px);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: var(--display);
  font-size: 21px;
  font-weight: 700;
  letter-spacing: .14em;
  color: var(--accent-strong);
}
.brand-star { font-size: 15px; }
.desktop-nav { display: flex; gap: clamp(24px, 3vw, 48px); font-size: 14px; color: var(--muted); }
.desktop-nav a { position: relative; transition: color .2s; }
.desktop-nav a:hover { color: var(--text); }
.desktop-nav a::after { content: ""; position: absolute; inset: auto 0 -12px; height: 1px; background: var(--accent); transform: scaleX(0); transition: transform .2s; }
.desktop-nav a:hover::after { transform: scaleX(1); }
.header-actions, .language-switch { display: flex; align-items: center; }
.header-actions { gap: 22px; }
.language-switch { gap: 9px; color: var(--muted); font-size: 12px; }
.language-switch button {
  color: inherit;
  border: 0;
  padding: 3px;
  background: transparent;
  cursor: pointer;
}
.language-switch button.active { color: var(--accent-strong); }
.theme-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  color: var(--text);
  background: transparent;
  cursor: pointer;
}
.theme-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.menu-trigger { display: none; border: 0; background: transparent; color: var(--text); font-size: 24px; }

.hero {
  min-height: 100svh;
  position: relative;
  display: grid;
  align-items: center;
  overflow: hidden;
  padding: 130px clamp(24px, 8vw, 130px) 80px;
}
.hero-media {
  position: absolute;
  inset: 0;
  background-image: var(--hero-image);
  background-size: cover;
  background-position: center;
  transition: background-image .5s ease;
  transform: scale(1.015);
}
.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, color-mix(in srgb, var(--bg) 96%, transparent) 0%, color-mix(in srgb, var(--bg) 80%, transparent) 45%, color-mix(in srgb, var(--bg) 25%, transparent) 100%),
    linear-gradient(0deg, var(--bg), transparent 38%);
}
.heritage-frame {
  position: absolute;
  z-index: 1;
  inset: 105px clamp(18px, 3vw, 48px) 38px;
  pointer-events: none;
  border: 1px solid color-mix(in srgb, var(--accent) 34%, transparent);
  border-radius: 220px 220px 12px 12px;
  opacity: .58;
}
.heritage-frame::before,
.heritage-frame::after {
  content: "";
  position: absolute;
  top: -1px;
  width: 17%;
  height: 36%;
  border-top: 1px solid var(--accent);
  opacity: .55;
}
.heritage-frame::before { left: 12%; border-radius: 100% 0 0; }
.heritage-frame::after { right: 12%; border-radius: 0 100% 0 0; }
body[data-theme="desert"] .hero-shade { background: linear-gradient(90deg, rgba(242,234,219,.96), rgba(242,234,219,.74) 48%, rgba(242,234,219,.12)), linear-gradient(0deg, var(--bg), transparent 38%); }
.hero-content { position: relative; z-index: 2; width: min(640px, 55vw); }
.eyebrow { color: var(--accent-strong); letter-spacing: .22em; font-size: 11px; font-weight: 600; text-transform: uppercase; }
h1, h2, h3 { font-family: var(--display); line-height: 1.08; margin-top: 0; }
h1 { font-size: clamp(54px, 5.6vw, 88px); margin-bottom: 25px; font-weight: 600; letter-spacing: .04em; }
.hero-copy { max-width: 590px; color: var(--muted); font-size: clamp(16px, 1.35vw, 20px); }
.hero-actions { display: flex; gap: 14px; margin-top: 36px; flex-wrap: wrap; }
.button {
  min-height: 49px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border: 1px solid var(--accent);
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 10px 28px var(--shadow); }
.button:disabled { cursor: wait; opacity: .72; transform: none; box-shadow: none; }
.button.primary { color: #17120b; background: var(--accent-strong); }
body[data-theme="desert"] .button.primary { color: #fff; }
.button.ghost { color: var(--text); background: color-mix(in srgb, var(--bg) 48%, transparent); }
.trust-row { display: flex; gap: 25px; margin-top: 48px; color: var(--muted); font-size: 12px; }
.trust-row span::before { content: "◇"; color: var(--accent); margin-inline-end: 8px; }
.hero-cards { position: absolute; z-index: 2; right: 8vw; top: 50%; width: min(35vw, 500px); height: 440px; transform: translateY(-42%); }
[dir="rtl"] .hero-cards { right: auto; left: 8vw; }
.hero-cards img {
  position: absolute;
  width: 205px;
  height: 355px;
  object-fit: cover;
  border: 1px solid var(--accent);
  border-radius: 8px;
  box-shadow: 0 24px 60px rgba(0,0,0,.55);
}
.hero-cards img:nth-child(1) { left: 5%; top: 10%; transform: rotate(-13deg); }
.hero-cards img:nth-child(2) { left: 32%; top: 0; z-index: 2; }
.hero-cards img:nth-child(3) { left: 58%; top: 10%; transform: rotate(13deg); }
.scroll-cue { position: absolute; z-index: 3; bottom: 30px; left: 50%; transform: translateX(-50%); color: var(--muted); font-size: 11px; letter-spacing: .15em; }

.section { padding: clamp(80px, 10vw, 150px) clamp(24px, 8vw, 130px); }
.section-heading { text-align: center; max-width: 760px; margin: 0 auto 52px; }
.section-heading h2, .journey-copy h2, .result-heading h2 { font-size: clamp(38px, 4vw, 65px); margin-bottom: 18px; }
.section-heading > p:last-child, .journey-copy > p:last-child { color: var(--muted); }

.reading-section { background: var(--bg); }
.topic-tabs { display: flex; justify-content: center; gap: 8px; margin-bottom: 28px; flex-wrap: wrap; }
.topic-tabs button {
  border: 1px solid var(--line);
  color: var(--muted);
  background: transparent;
  padding: 9px 20px;
  cursor: pointer;
}
.topic-tabs button.active { color: var(--text); border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); }
.reading-workspace {
  display: grid;
  grid-template-columns: minmax(320px, .78fr) minmax(460px, 1.22fr);
  min-height: 650px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 30px 80px var(--shadow);
}
.question-panel { padding: clamp(28px, 4vw, 58px); border-inline-end: 1px solid var(--line); }
.question-panel > label, .spread-picker legend { display: block; color: var(--accent-strong); font-size: 13px; letter-spacing: .12em; margin-bottom: 12px; }
textarea {
  width: 100%;
  min-height: 130px;
  resize: vertical;
  color: var(--text);
  background: color-mix(in srgb, var(--bg) 60%, transparent);
  border: 1px solid var(--line);
  padding: 17px;
  outline: none;
}
textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 12%, transparent); }
textarea::placeholder { color: var(--muted); }
.field-meta { display: flex; justify-content: space-between; gap: 15px; margin-top: 8px; color: var(--muted); font-size: 10px; }
.spread-picker { border: 0; padding: 0; margin: 34px 0 26px; }
.spread-option {
  position: relative;
  display: flex;
  margin-top: 10px;
  border: 1px solid var(--line);
  padding: 14px 46px 14px 16px;
  cursor: pointer;
  transition: border .2s, background .2s;
}
[dir="rtl"] .spread-option { padding: 14px 16px 14px 46px; }
.spread-option.selected { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.spread-option input { margin-inline-end: 13px; accent-color: var(--accent); }
.spread-option strong, .spread-option small { display: block; }
.spread-option small { color: var(--muted); margin-top: 2px; }
.spread-help {
  position: absolute;
  top: 11px;
  right: 13px;
  z-index: 5;
  display: inline-grid;
  place-items: center;
  cursor: help;
  outline: none;
}
[dir="rtl"] .spread-help { right: auto; left: 13px; }
.help-icon {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 1px solid color-mix(in srgb, var(--accent) 68%, transparent);
  border-radius: 999px;
  color: var(--accent-strong);
  background: color-mix(in srgb, var(--surface-solid) 86%, transparent);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}
.help-popover {
  position: absolute;
  top: 28px;
  right: 0;
  width: min(260px, 72vw);
  padding: 13px 14px;
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  background: color-mix(in srgb, var(--surface-solid) 96%, #000 4%);
  color: var(--text);
  box-shadow: 0 18px 40px var(--shadow);
  font-size: 12px;
  line-height: 1.65;
  letter-spacing: normal;
  opacity: 0;
  transform: translateY(-4px);
  visibility: hidden;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}
[dir="rtl"] .help-popover { right: auto; left: 0; }
.spread-help:hover .help-popover,
.spread-help:focus .help-popover,
.spread-help:focus-within .help-popover {
  opacity: 1;
  transform: translateY(0);
  visibility: visible;
}
.spread-help:hover .help-icon,
.spread-help:focus .help-icon {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent);
}
.draw-button { width: 100%; }
.card-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 620px;
  padding: 45px 30px;
  overflow: hidden;
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 15%, transparent), transparent 55%);
}
.stage-intro { text-align: center; max-width: 330px; color: var(--muted); }
.stage-intro h3 { color: var(--text); font-size: 31px; margin: 18px 0 10px; }
.stage-back-row {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 170px;
  margin-bottom: 20px;
  perspective: 900px;
}
.stage-back-card {
  width: 86px;
  aspect-ratio: 0.583;
  object-fit: cover;
  border: 1px solid var(--accent);
  border-radius: 7px;
  box-shadow: 0 18px 36px rgba(0,0,0,.4);
}
.stage-back-card:nth-child(1) { transform: translateX(26px) rotate(-12deg); }
.stage-back-card:nth-child(2) { z-index: 2; transform: translateY(-8px); }
.stage-back-card:nth-child(3) { transform: translateX(-26px) rotate(12deg); }
.drawn-cards {
  width: min(100%, 620px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  justify-content: center;
  justify-items: center;
  align-items: start;
  gap: 24px 20px;
  perspective: 1200px;
}
.drawn-cards.draw-count-1 { width: min(100%, 210px); grid-template-columns: minmax(0, 1fr); }
.drawn-cards.draw-count-4,
.drawn-cards.draw-count-5 { width: min(100%, 760px); grid-template-columns: repeat(3, minmax(0, 1fr)); }
.drawn-cards.draw-count-7 { width: min(100%, 820px); grid-template-columns: repeat(4, minmax(0, 1fr)); }
.drawn-cards.draw-count-10 { width: min(100%, 820px); grid-template-columns: repeat(4, minmax(0, 1fr)); }
.drawn-cards.shuffling .drawn-card { animation: shuffleCard .58s ease-in-out infinite alternate; }
.drawn-cards.shuffling .drawn-card:nth-child(2) { animation-delay: .08s; }
.drawn-cards.shuffling .drawn-card:nth-child(3) { animation-delay: .16s; }
.drawn-card {
  width: 100%;
  max-width: 132px;
  display: grid;
  grid-template-rows: 232px minmax(34px, auto) minmax(34px, auto);
  justify-items: center;
  align-items: start;
  text-align: center;
}
.drawn-cards.draw-count-1 .drawn-card,
.drawn-cards.draw-count-3 .drawn-card { max-width: 170px; grid-template-rows: 298px minmax(34px, auto) minmax(34px, auto); }
.card-flip {
  position: relative;
  width: 100%;
  aspect-ratio: 0.57;
  align-self: start;
  transform-style: preserve-3d;
  transition: transform .86s cubic-bezier(.2,.72,.18,1);
}
.drawn-card.revealed .card-flip { transform: rotateY(180deg); }
.card-face {
  position: absolute;
  inset: 0;
  margin: 0;
  backface-visibility: hidden;
  border: 1px solid var(--accent);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 22px 48px rgba(0,0,0,.5);
  background: var(--surface-solid);
}
.card-face img { width: 100%; height: 100%; object-fit: cover; }
.card-front { transform: rotateY(180deg); }
.drawn-card.reversed .card-front img { transform: rotate(180deg); }
.drawn-card strong {
  display: block;
  color: var(--text);
  margin-top: 12px;
  font-family: var(--display);
  font-size: 20px;
  line-height: 1.15;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .35s ease, transform .35s ease;
}
.drawn-card small {
  display: block;
  color: var(--accent-strong);
  font-size: 12px;
  line-height: 1.45;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .35s ease, transform .35s ease;
}
.drawn-card.revealed strong,
.drawn-card.revealed small { opacity: 1; transform: none; }
@keyframes shuffleCard {
  from { transform: translateX(-8px) rotate(-3deg); }
  to { transform: translateX(8px) rotate(3deg); }
}

.reading-result { margin-top: 60px; border-top: 1px solid var(--line); padding-top: 55px; }
.result-heading { text-align: center; }
.result-heading p:last-child { color: var(--muted); }
.result-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 34px 28px; margin: 42px 0; align-items: stretch; }
.result-card {
  display: grid;
  justify-items: center;
  align-items: stretch;
  padding: 26px 0;
  border-top: 1px solid var(--accent);
}
.result-card-inner {
  width: min(100%, 320px);
  display: grid;
  justify-items: center;
  align-content: start;
  grid-template-rows: 250px 20px minmax(68px, auto) auto;
  row-gap: 10px;
  height: 100%;
}
.result-card-image {
  width: 145px;
  height: 250px;
  margin: 0 auto;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface-solid) 72%, transparent);
  box-shadow: 0 18px 36px var(--shadow);
  display: grid;
  place-items: center;
}
.result-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.result-card-image.reversed img { transform: rotate(180deg); }
.result-card .position { color: var(--accent-strong); font-size: 11px; letter-spacing: .15em; }
.result-card .position,
.result-card h3 {
  display: block;
  width: 100%;
  max-width: 100%;
  margin-inline: auto;
  text-align: center;
  justify-self: center;
  align-self: center;
  grid-column: 1 / -1;
}
.result-card > .position,
.result-card > h3 { place-self: center stretch; }
.result-card h3 {
  font-size: 28px;
  line-height: 1.2;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.result-card p { width: 100%; color: var(--muted); text-align: start; margin: 0; }
.result-grid.single-result {
  grid-template-columns: minmax(260px, 420px);
  justify-content: center;
}
.result-grid.single-result .result-card-inner {
  width: min(100%, 360px);
}
.result-grid.single-result .result-card p {
  text-align: center;
}
.synthesis { max-width: 850px; margin: 0 auto; padding: 35px; border-inline-start: 2px solid var(--accent); background: color-mix(in srgb, var(--surface-solid) 70%, transparent); }
.synthesis h3 { font-size: 30px; }
.synthesis .key-insight {
  display: inline-block;
  margin: 4px 0 14px;
  padding: 7px 11px;
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  color: var(--accent-strong);
  font-size: 15px;
  line-height: 1.5;
}
.synthesis p { color: var(--muted); }
.synthesis-block {
  margin: 0 0 18px;
  padding: 0 0 16px;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
}
.synthesis-block:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: 0;
}
.synthesis-block h4 {
  margin: 0 0 8px;
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.4;
  letter-spacing: .06em;
}
.synthesis-block p {
  margin: 0 0 8px;
  line-height: 1.8;
}
.synthesis-block ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding-inline-start: 20px;
  color: var(--muted);
  line-height: 1.75;
}
.synthesis-block li::marker {
  color: var(--accent-strong);
}
.synthesis-paragraph {
  display: block;
  margin: 0 0 12px;
}
.synthesis-paragraph:last-child { margin-bottom: 0; }
.synthesis strong {
  display: block;
  margin-top: 20px;
  padding: 14px 16px;
  border-inline-start: 2px solid var(--accent);
  background: color-mix(in srgb, var(--accent) 9%, transparent);
  color: var(--accent-strong);
  line-height: 1.8;
}
.synthesis strong.action-guide {
  color: var(--text);
}
.action-guide-title,
.action-guide-body {
  display: block;
}
.action-guide-title {
  margin-bottom: 6px;
  color: var(--accent-strong);
  font-size: 15px;
  letter-spacing: .08em;
}
.action-guide-body {
  color: var(--muted);
}
.action-guide ul {
  display: grid;
  gap: 6px;
  margin: 10px 0 0;
  padding-inline-start: 20px;
  color: var(--text);
}
.action-guide li::marker {
  color: var(--accent-strong);
}
.synthesis .action-hw {
  margin: 13px 0 0;
  color: var(--text);
  font-size: 14px;
}
.agency-note { text-align: center; color: var(--muted); font-size: 12px; margin-top: 28px; }

.journey-section {
  display: block;
  background: var(--bg-soft);
  position: relative;
  overflow: hidden;
}
.journey-section::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: url("assets/images/islamic-geometric-pattern.png") center / 620px;
  opacity: .035;
}
.journey-section > * { position: relative; z-index: 1; }
.journey-shell {
  width: min(1120px, 100%);
  margin: 0 auto;
}
.journey-copy {
  max-width: 720px;
  margin: 0 auto clamp(42px, 6vw, 70px);
  text-align: center;
}
.journey-copy h2 {
  font-size: clamp(42px, 5.4vw, 72px);
  line-height: 1.05;
  margin: 10px 0 18px;
}
.journey-copy > p:last-child {
  max-width: 620px;
  margin: 0 auto;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.9;
}
.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  padding: 0;
  margin: 0 0 clamp(54px, 7vw, 88px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.steps li {
  min-height: 190px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 22px;
  padding: clamp(26px, 3vw, 38px);
  border-inline-end: 1px solid var(--line);
}
.steps li:last-child { border-inline-end: 0; }
.steps li > span {
  color: var(--accent);
  font-family: var(--display);
  font-size: 26px;
  line-height: 1;
}
.steps h3 {
  font-size: clamp(24px, 2.4vw, 32px);
  margin: 0 0 10px;
}
.steps p {
  color: var(--muted);
  margin: 0;
  line-height: 1.8;
}
.about-contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(52px, 7vw, 86px);
  align-items: stretch;
}
.about-note {
  width: min(920px, 100%);
  padding: clamp(28px, 4vw, 42px) 0 clamp(8px, 2vw, 18px) clamp(24px, 3vw, 34px);
  border-inline-start: 2px solid var(--accent);
  background: transparent;
}
.about-note h3 {
  font-size: clamp(30px, 3.3vw, 42px);
  margin: 8px 0 18px;
}
.about-note p {
  max-width: 760px;
  color: var(--muted);
  line-height: 2;
}
.message-board {
  width: min(920px, 100%);
  margin-top: 0;
  padding: clamp(28px, 4vw, 42px) 0 0 clamp(24px, 3vw, 34px);
  border: 0;
  border-inline-start: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
  background: transparent;
  box-shadow: none;
}
.message-board h3 {
  font-size: clamp(30px, 3vw, 40px);
  margin: 7px 0 14px;
}
.message-board > p:not(.eyebrow):not(.message-status),
.message-board label,
.message-meta {
  max-width: 760px;
  color: var(--muted);
}
.message-board label {
  display: block;
  margin: 20px 0 8px;
  font-size: 13px;
}
.message-board textarea {
  max-width: 760px;
  width: 100%;
  min-height: 150px;
  resize: vertical;
  box-sizing: border-box;
  padding: 15px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  color: var(--text);
  font: inherit;
  line-height: 1.7;
}
.message-board textarea:focus {
  outline: 1px solid var(--accent);
  border-color: var(--accent);
}
.message-meta {
  max-width: 760px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 8px 0 18px;
  font-size: 12px;
}
.message-status {
  min-height: 22px;
  margin: 14px 0 0;
  color: var(--accent-strong);
}
.message-status.error { color: #d76d6d; }
.message-board button[disabled] {
  opacity: .62;
  cursor: not-allowed;
}
.guides-section { background: var(--bg); }
.guide-list { max-width: 1080px; margin: 0 auto; }
.guide-list article { display: grid; grid-template-columns: 70px 1fr; gap: 20px; padding: 34px 0; border-top: 1px solid var(--line); }
.guide-list article > span { color: var(--accent); font-family: var(--display); font-size: 25px; }
.guide-list p { color: var(--accent-strong); text-transform: uppercase; font-size: 10px; letter-spacing: .18em; }
.guide-list h3 { font-size: clamp(24px, 2.5vw, 38px); margin: 8px 0 18px; }
.guide-list a { color: var(--muted); font-size: 13px; }
.guide-list a:hover { color: var(--accent-strong); }
footer { padding: 70px clamp(24px, 8vw, 130px); text-align: center; border-top: 1px solid var(--line); background: var(--bg-soft); color: var(--muted); font-size: 12px; }
footer .brand { justify-content: center; margin-bottom: 25px; }
footer .disclaimer { max-width: 700px; margin: 22px auto; }

.theme-modal[hidden], .guide-modal[hidden], .mobile-menu[hidden] { display: none; }
.theme-modal,
.guide-modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 24px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(2, 8, 14, .74); backdrop-filter: blur(9px); }
.theme-dialog {
  position: relative;
  width: min(1080px, 96vw);
  max-height: 94vh;
  overflow: auto;
  padding: clamp(30px, 4vw, 56px);
  background: #0a1928;
  color: #f6eddc;
  border: 1px solid #b98a42;
  box-shadow: 0 35px 100px rgba(0,0,0,.62);
}
.modal-close { position: absolute; inset: 17px 21px auto auto; border: 0; background: transparent; color: #dcb469; font-size: 31px; cursor: pointer; }
[dir="rtl"] .modal-close { right: auto; left: 21px; }
.modal-heading { text-align: center; margin-bottom: 30px; }
.modal-heading h2 { font-size: clamp(35px, 4vw, 56px); margin: 7px 0 10px; }
.modal-heading > p:last-child { color: #a9a391; }
.theme-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.theme-option { padding: 0; text-align: start; border: 1px solid rgba(211,163,79,.35); background: #0d2032; color: #f6eddc; cursor: pointer; overflow: hidden; }
.theme-option.selected { border-color: #e3b963; box-shadow: 0 0 0 2px rgba(227,185,99,.17); }
.theme-preview { display: block; height: 195px; background-size: cover; background-position: center; }
.royal-preview { background-image: linear-gradient(rgba(0,10,20,.12), rgba(0,10,20,.5)), url("assets/images/dubai-night.jpg"); }
.desert-preview { background-image: linear-gradient(rgba(255,240,215,.08), rgba(100,60,30,.22)), url("assets/images/desert-sunrise.jpg"); }
.celestial-preview { background-image: linear-gradient(rgba(50,20,70,.1), rgba(20,10,40,.46)), url("assets/images/desert-night.jpg"); }
.theme-option-copy { display: block; padding: 20px; }
.theme-option-copy strong, .theme-option-copy small, .select-mark { display: block; }
.theme-option-copy strong { color: #eac779; font-family: var(--display); font-size: 24px; }
.theme-option-copy small { min-height: 55px; color: #a9a391; margin: 8px 0 15px; line-height: 1.6; }
.select-mark { color: #dcb469; font-size: 12px; }
.remember-choice { display: flex; align-items: center; gap: 8px; margin: 28px 0 16px; color: #c8baa0; font-size: 13px; }
.remember-choice input { accent-color: #d3a34f; }
.enter-button { width: min(330px, 100%); margin: 0 auto; display: flex; }
.switch-note { color: #8e8b83; text-align: center; font-size: 11px; margin: 13px 0 0; }

.guide-dialog {
  position: relative;
  width: min(860px, 94vw);
  max-height: min(86vh, 820px);
  overflow: auto;
  padding: clamp(34px, 5vw, 62px);
  border: 1px solid color-mix(in srgb, var(--accent) 48%, transparent);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--surface-solid) 94%, #000 6%), color-mix(in srgb, var(--bg-soft) 94%, #000 6%)),
    var(--surface-solid);
  color: var(--text);
  box-shadow: 0 30px 90px rgba(0,0,0,.62);
}
.guide-dialog h2 {
  font-size: clamp(34px, 4vw, 54px);
  line-height: 1.08;
  margin: 8px 0 18px;
}
.guide-lead {
  max-width: 680px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.9;
}
.guide-body {
  display: grid;
  gap: 24px;
  margin-top: 30px;
}
.guide-body section {
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.guide-body h3 {
  font-size: 25px;
  margin: 0 0 12px;
}
.guide-body p,
.guide-body li {
  color: var(--muted);
  line-height: 1.9;
}
.guide-body ul,
.guide-body ol {
  margin: 0;
  padding-inline-start: 22px;
}
.guide-body li + li { margin-top: 8px; }
.guide-callout {
  border-inline-start: 2px solid var(--accent);
  padding: 16px 18px;
  background: color-mix(in srgb, var(--surface-solid) 62%, transparent);
  color: var(--text);
}

.mobile-menu { position: fixed; inset: 0; z-index: 90; background: var(--bg); padding: 90px 28px; }
.mobile-menu button { position: absolute; top: 25px; right: 28px; border: 0; background: transparent; color: var(--text); font-size: 34px; }
.mobile-menu a { display: block; font-family: var(--display); font-size: 36px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s, transform .8s; }
.reveal.visible { opacity: 1; transform: none; }

[dir="rtl"] body { font-family: "Noto Naskh Arabic", sans-serif; }
[dir="rtl"] .hero-shade { transform: scaleX(-1); }
[dir="rtl"] .eyebrow { letter-spacing: .06em; }

@media (max-width: 1050px) {
  .desktop-nav { display: none; }
  .menu-trigger { display: block; }
  .hero-content { width: 70%; }
  .hero-cards { right: 2vw; opacity: .76; }
  .reading-workspace { grid-template-columns: 1fr; }
  .question-panel { border-inline-end: 0; border-bottom: 1px solid var(--line); }
  .theme-dialog { width: min(760px, 96vw); }
  .theme-options { grid-template-columns: 1fr; }
  .theme-option { display: grid; grid-template-columns: 190px 1fr; }
  .theme-preview { height: 100%; min-height: 150px; }
  .theme-option-copy small { min-height: auto; }
}

@media (max-width: 700px) {
  .site-header { height: 67px; padding: 0 18px; }
  .brand { font-size: 14px; letter-spacing: .1em; gap: 7px; }
  .brand-star { font-size: 11px; }
  .language-switch span { display: none; }
  .language-switch { gap: 1px; font-size: 10px; }
  .language-switch button { min-width: 25px; padding: 5px 3px; }
  .language-switch button[data-lang="ar"] { min-width: 35px; }
  .theme-trigger > span:last-child { display: none; }
  .theme-trigger { min-width: 34px; min-height: 34px; justify-content: center; padding: 7px; }
  .header-actions { gap: 8px; }
  .hero { min-height: 850px; padding: 110px 22px 80px; align-items: start; }
  .heritage-frame { inset: 82px 10px 22px; border-radius: 130px 130px 8px 8px; }
  .hero-content { width: 100%; }
  h1 { max-width: 350px; font-size: clamp(46px, 13.2vw, 54px); line-height: 1.14; letter-spacing: .01em; }
  .hero-copy { font-size: 15px; line-height: 1.9; }
  .hero-actions { display: grid; width: min(100%, 290px); }
  .hero-actions .button { width: 100%; }
  .hero-shade { background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 90%, transparent), color-mix(in srgb, var(--bg) 78%, transparent) 60%, var(--bg)); }
  body[data-theme="desert"] .hero-shade { background: linear-gradient(180deg, rgba(242,234,219,.93), rgba(242,234,219,.72), var(--bg)); }
  .hero-cards { top: auto; bottom: 35px; left: 50%; right: auto; width: 340px; height: 320px; transform: translateX(-50%); }
  .hero-cards img { width: 125px; height: 220px; }
  .trust-row { gap: 10px; flex-wrap: wrap; margin-top: 28px; }
  .scroll-cue { display: none; }
  .section { padding: 75px 20px; }
  .reading-workspace { min-height: 0; }
  .question-panel { padding: 26px 20px; }
  .card-stage { min-height: 440px; padding: 30px 12px; }
  .stage-back-row { height: 135px; }
  .stage-back-card { width: 68px; }
  .drawn-cards,
  .drawn-cards.draw-count-4,
  .drawn-cards.draw-count-5,
  .drawn-cards.draw-count-7,
  .drawn-cards.draw-count-10 {
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px 9px;
  }
  .drawn-card {
    max-width: 100px;
    grid-template-rows: 175px minmax(31px, auto) minmax(42px, auto);
  }
  .drawn-cards.draw-count-1 .drawn-card,
  .drawn-cards.draw-count-3 .drawn-card {
    max-width: 112px;
    grid-template-rows: 196px minmax(31px, auto) minmax(42px, auto);
  }
  .drawn-card strong { font-size: 15px; }
  .drawn-card small { font-size: 11px; }
  .result-grid { grid-template-columns: 1fr; }
  .result-grid { gap: 8px; }
  .result-card {
    display: grid;
    grid-template-columns: 92px 1fr;
    column-gap: 18px;
    align-items: start;
  }
  .result-card-inner { display: contents; }
  .result-card-image {
    grid-row: span 3;
    width: 92px;
    height: auto;
    aspect-ratio: 0.583;
    margin: 4px auto 0;
  }
  .result-card-image img {
    height: 100%;
  }
  .result-grid.single-result {
    justify-items: center;
  }
  .result-grid.single-result .result-card {
    grid-template-columns: 1fr;
    width: min(100%, 360px);
    text-align: center;
  }
  .result-grid.single-result .result-card-inner {
    display: grid;
    justify-items: center;
    grid-template-rows: 250px 20px minmax(48px, auto) auto;
  }
  .result-grid.single-result .result-card-image {
    grid-row: auto;
    width: 145px;
    height: 250px;
    margin: 0 auto;
  }
  .journey-copy { text-align: start; margin-bottom: 38px; }
  .journey-copy h2 { font-size: 42px; }
  .journey-copy > p:last-child { margin: 0; font-size: 15px; }
  .steps {
    grid-template-columns: 1fr;
    margin-bottom: 46px;
  }
  .steps li {
    min-height: 0;
    grid-template-columns: 54px 1fr;
    grid-template-rows: auto;
    gap: 18px;
    padding: 24px 0;
    border-inline-end: 0;
    border-bottom: 1px solid var(--line);
  }
  .steps li:last-child { border-bottom: 0; }
  .steps h3 { font-size: 24px; }
  .about-contact-grid {
    grid-template-columns: 1fr;
    gap: 42px;
  }
  .about-note {
    padding: 24px 0 0 20px;
  }
  .message-board {
    margin-top: 0;
    padding: 24px 0 0 20px;
  }
  .theme-modal { padding: 10px; }
  .theme-dialog { width: 100%; max-height: 97vh; padding: 34px 18px 25px; }
  .guide-modal { padding: 10px; }
  .guide-dialog { width: 100%; max-height: 94vh; padding: 34px 18px 28px; }
  .guide-dialog h2 { font-size: 34px; }
  .guide-lead { font-size: 15px; }
  .guide-body { gap: 18px; }
  .guide-body h3 { font-size: 22px; }
  .theme-options { gap: 10px; }
  .theme-option { grid-template-columns: 110px 1fr; }
  .theme-preview { min-height: 135px; }
  .theme-option-copy { padding: 14px; }
  .theme-option-copy strong { font-size: 20px; }
  .theme-option-copy small { font-size: 11px; margin: 4px 0 8px; }
  .modal-heading { margin-bottom: 20px; }
  .modal-heading h2 { font-size: 35px; }
  .modal-heading > p:last-child { margin-bottom: 0; font-size: 12px; }
  .remember-choice { margin-top: 18px; }
}

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