/* منبر — mosque green / gold / cream */

:root {
  --g950: #0A0722;
  --g900: #120C2E;
  --g850: #161036;
  --g800: #1B143E;
  --g700: #2B2160;

  --gold: #8B7CF6;
  --gold-soft: #B7ABFA;
  --gold-deep: #6A55E8;
  --kicker: #B98A2E;
  --kicker-soft: #D9B25F;

  --cream: #F3F1FB;
  --cream-2: #E9E6F7;
  --paper: #FCFBFF;

  --ink: #1E1839;
  --ink-2: #4F4973;
  --ink-3: #8B87A8;
  --line: #DBD7EE;

  --live: #E4573D;
  --amber: #B87514;
  --amber-bg: #FBF3E2;

  --chart-base: #B37E2E;   /* بدون منبر — validated */
  --chart-manbar: #7B5FE0; /* مع منبر — validated */

  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 10px 30px rgba(18, 12, 46, 0.10);
  --font: "IBM Plex Sans Arabic", system-ui, sans-serif;
  --font-quran: "Amiri", serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img, svg { display: block; }

.container { width: min(1120px, 92%); margin-inline: auto; }
.center { text-align: center; }
.spacer { flex: 1; }

/* topbar */
.topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 28px;
  padding: 14px 4vw;
  background: rgba(243, 241, 251, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
body[data-view="screen"] .topbar {
  background: rgba(10, 7, 34, 0.92);
  border-bottom-color: rgba(139, 124, 246, 0.18);
  color: var(--cream);
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 26px; color: var(--gold-deep); }
body[data-view="screen"] .brand-mark { color: var(--gold); }
.brand-mark svg { width: 100%; height: auto; }
.brand-name { font-size: 24px; font-weight: 700; letter-spacing: 0.5px; }

.nav { display: flex; gap: 4px; flex: 1; }
.nav a {
  padding: 8px 14px; border-radius: 999px;
  font-size: 15px; font-weight: 500; color: inherit; opacity: 0.75;
  transition: all 0.15s ease;
}
.nav a:hover { opacity: 1; background: rgba(30, 22, 70, 0.07); }
body[data-view="screen"] .nav a:hover { background: rgba(139, 124, 246, 0.12); }
.nav a.active {
  opacity: 1; background: var(--g900); color: var(--cream); font-weight: 600;
}
body[data-view="screen"] .nav a.active { background: var(--gold); color: var(--g950); }

.sim-badge {
  font-size: 12.5px; font-weight: 600; color: var(--amber);
  background: var(--amber-bg); border: 1px solid rgba(184, 117, 20, 0.35);
  padding: 4px 12px; border-radius: 999px; white-space: nowrap;
}
.nav-toggle { display: none; background: none; border: none; color: inherit; }

/* views */
.view { display: none; }
.view.active { display: block; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 24px; border-radius: 999px; border: 1.5px solid transparent;
  font-size: 15.5px; font-weight: 600; transition: all 0.15s ease;
}
.btn-lg { padding: 14px 32px; font-size: 17px; }
.btn-primary { background: var(--g900); color: var(--cream); }
.btn-primary:hover { background: var(--g700); transform: translateY(-1px); }
.btn-ghost { border-color: var(--g900); color: var(--g900); background: transparent; }
.btn-ghost:hover { background: rgba(18, 12, 46, 0.06); }
.btn-gold { background: var(--gold); color: var(--g950); }
.btn-gold:hover { background: var(--gold-soft); }

/* hero */
.hero {
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(139, 124, 246,0.14), transparent 60%),
    var(--g900);
  color: var(--cream);
  overflow: hidden;
}
.hero-grid {
  display: grid; grid-template-columns: 1.25fr 0.75fr; gap: 40px;
  align-items: center; padding: 84px 0 76px;
}
.hero-kicker {
  color: var(--kicker-soft); font-size: 15px; font-weight: 600; margin-bottom: 18px;
}
.hero-title { font-size: clamp(64px, 9vw, 108px); font-weight: 700; line-height: 1; }
.hero-sub {
  color: var(--kicker-soft); font-size: clamp(24px, 3.2vw, 34px);
  font-weight: 700; margin: 14px 0 18px;
}
.hero-desc { max-width: 560px; font-size: 18px; font-weight: 300; opacity: 0.92; }
.hero-cta { display: flex; gap: 14px; margin-top: 34px; flex-wrap: wrap; }
.hero .btn-primary { background: var(--gold); color: var(--g950); }
.hero .btn-primary:hover { background: var(--gold-soft); }
.hero .btn-ghost { border-color: rgba(243, 241, 251,0.5); color: var(--cream); }
.hero .btn-ghost:hover { background: rgba(243, 241, 251,0.08); }

/* sections */
.section { padding: 84px 0; }
.section-tint { background: var(--cream-2); }
.section-dark {
  background:
    radial-gradient(900px 400px at 15% 110%, rgba(139, 124, 246,0.10), transparent 60%),
    var(--g900);
  color: var(--cream);
}
.sec-kicker { color: var(--kicker); font-weight: 700; font-size: 15px; margin-bottom: 10px; }
.section-dark .sec-kicker { color: var(--kicker-soft); }
.sec-title {
  font-size: clamp(26px, 3.6vw, 40px); font-weight: 700; line-height: 1.45;
  max-width: 900px; margin-bottom: 14px;
}
.sec-title-sm { font-size: clamp(22px, 2.6vw, 30px); font-weight: 700; margin-bottom: 22px; }
.sec-lead { font-size: 18px; color: var(--ink-2); max-width: 760px; }
.section-dark .sec-lead { color: rgba(243, 241, 251,0.8); }
.center .btn { margin-top: 26px; }

.stat-duo {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 48px;
}
.stat-block { border-right: 3px solid var(--gold); padding-right: 22px; }
.stat-over { color: var(--ink-2); font-size: 15px; }
.stat-big { font-size: clamp(34px, 4.5vw, 52px); font-weight: 700; line-height: 1.25; }
.stat-under { color: var(--ink-2); font-size: 15px; max-width: 420px; }

.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 38px; }
.cards-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 38px; }
.card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 28px 26px;
}
.card h3 { font-size: 19px; font-weight: 700; margin-bottom: 10px; }
.card p { color: var(--ink-2); font-size: 15.5px; }
.card-dark {
  background: rgba(243, 241, 251, 0.05);
  border-color: rgba(139, 124, 246, 0.25);
}
.card-dark h3 { color: var(--gold-soft); }
.card-dark p { color: rgba(243, 241, 251, 0.82); }
.beneficiaries { margin-top: 30px; color: rgba(243, 241, 251,0.85); font-size: 15.5px; }
.beneficiaries strong { color: var(--gold); margin-left: 8px; }

/* Pipeline */
.pipeline {
  display: flex; align-items: stretch; gap: 8px; margin-top: 40px; flex-wrap: wrap;
}
.pipe-step {
  flex: 1; min-width: 150px;
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px 18px;
}
.pipe-num {
  display: inline-block; color: var(--gold-deep); font-weight: 700; font-size: 15px;
  margin-bottom: 6px;
}
.pipe-step h4 { font-size: 16.5px; font-weight: 700; margin-bottom: 4px; }
.pipe-step p { font-size: 13.5px; color: var(--ink-2); line-height: 1.6; }
.pipe-arrow { align-self: center; color: var(--gold-deep); font-size: 20px; }

.modes-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 26px; }
.mode-card {
  background: var(--g900); color: var(--cream);
  border-radius: var(--radius-lg); padding: 26px;
}
.mode-card h4 { color: var(--gold-soft); font-size: 17.5px; margin-bottom: 8px; }
.mode-card p { font-size: 15px; opacity: 0.88; }
.mode-card-alt { background: var(--paper); color: var(--ink); border: 1px solid var(--line); }
.mode-card-alt h4 { color: var(--amber); }
.mode-card-alt p { color: var(--ink-2); }

/* Footer */
.footer { background: var(--g950); color: var(--cream); padding: 40px 0; }
.footer-grid { display: flex; justify-content: space-between; gap: 30px; align-items: center; flex-wrap: wrap; }
.footer-brand { font-weight: 700; font-size: 17px; color: var(--gold-soft); }
.footer-note { font-size: 14px; opacity: 0.7; }
.footer-disclaimer { font-size: 13px; opacity: 0.6; max-width: 380px; }

/* Mosque screen */
.screen-stage {
  position: relative;
  min-height: calc(100vh - 62px);
  display: flex; flex-direction: column;
  background:
    radial-gradient(1200px 600px at 50% -20%, rgba(139, 124, 246,0.08), transparent 55%),
    var(--g950);
  color: var(--cream);
  padding: 26px 4vw 18px;
}
.screen-stage:fullscreen { min-height: 100vh; }

.screen-top {
  display: flex; justify-content: space-between; align-items: center; gap: 18px;
  padding-bottom: 16px; border-bottom: 1px solid rgba(139, 124, 246,0.16);
}
.live-pill {
  display: inline-flex; align-items: center; gap: 9px;
  color: var(--live); font-weight: 700; font-size: 15px;
}
.live-dot {
  width: 9px; height: 9px; border-radius: 50%; background: var(--live);
  animation: pulse 1.6s ease-in-out infinite;
}
.live-dot.paused { animation: none; opacity: 0.35; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.25; } }

.waveform { display: inline-flex; align-items: flex-end; gap: 2.5px; height: 16px; margin-right: 6px; }
.waveform i {
  width: 3px; background: var(--gold); border-radius: 2px; height: 30%;
  animation: wave 1s ease-in-out infinite;
}
.waveform i:nth-child(2) { animation-delay: 0.15s; }
.waveform i:nth-child(3) { animation-delay: 0.3s; }
.waveform i:nth-child(4) { animation-delay: 0.45s; }
.waveform i:nth-child(5) { animation-delay: 0.6s; }
@keyframes wave { 0%,100% { height: 25%; } 50% { height: 100%; } }
.waveform.flat i { animation: none; height: 15%; background: var(--live); }
.waveform.idle i { animation: none; height: 25%; opacity: 0.4; }

.screen-meta { font-size: 15px; opacity: 0.75; }
.meta-sep { color: var(--gold); margin-inline: 6px; }
.meta-title { color: var(--gold-soft); }

.screen-body {
  flex: 1; display: flex; gap: 34px; align-items: center; padding: 28px 0 10px;
}
.text-col { flex: 1; position: relative; min-width: 0; }

.prev-line {
  color: rgba(243, 241, 251,0.42); font-size: 20px; min-height: 34px;
  margin-bottom: 16px; transition: opacity 0.3s;
}
.current-wrap { position: relative; }
.current-line {
  font-weight: 700; line-height: 1.75;
  border-right: 5px solid var(--gold); padding-right: 22px;
  transition: opacity 0.25s ease;
}
.screen-stage[data-fontsize="s"] .current-line { font-size: clamp(24px, 3.4vw, 38px); }
.screen-stage[data-fontsize="m"] .current-line { font-size: clamp(30px, 4.4vw, 50px); }
.screen-stage[data-fontsize="l"] .current-line { font-size: clamp(38px, 5.6vw, 64px); }
.current-line.fading { opacity: 0; }
.current-line .term-chip {
  background: none; border: none; color: var(--gold);
  font: inherit; font-weight: 700;
  border-bottom: 3px dotted rgba(139, 124, 246,0.55);
  padding: 0 2px; transition: background 0.15s;
}
.current-line .term-chip:hover { background: rgba(139, 124, 246,0.14); border-radius: 6px; }

.unrev-badge {
  display: inline-block; margin-bottom: 12px;
  background: rgba(184, 117, 20, 0.16); color: #E8B563;
  border: 1px solid rgba(232, 181, 99, 0.45);
  font-size: 13.5px; font-weight: 600; padding: 4px 14px; border-radius: 999px;
}
.screen-stage[data-mode="improvised"] .current-line { border-right-color: #E8B563; }

/* Verse card */
.verse-card {
  margin-top: 26px; background: rgba(10, 7, 34, 0.65);
  border: 1px solid rgba(139, 124, 246,0.35);
  border-radius: var(--radius-lg); padding: 26px 30px;
  box-shadow: inset 0 0 60px rgba(139, 124, 246,0.05);
}
.verse-badge {
  display: inline-block; color: var(--gold); font-size: 12.5px; font-weight: 600;
  border: 1px solid rgba(139, 124, 246,0.4); border-radius: 999px;
  padding: 2px 12px; margin-bottom: 14px;
}
.verse-text {
  font-family: var(--font-quran);
  font-size: clamp(24px, 3.4vw, 40px); line-height: 2; color: #F8F3E4;
}
.verse-source { color: var(--gold-soft); font-size: 14.5px; margin-top: 10px; }
.verse-tafsir {
  color: rgba(243, 241, 251,0.78); font-size: 16.5px; margin-top: 12px;
  padding-top: 12px; border-top: 1px dashed rgba(139, 124, 246,0.25);
}
.verse-tafsir::before { content: "التفسير الميسر: "; color: var(--gold); font-weight: 600; }

.review-note { margin-top: 22px; font-size: 13.5px; color: rgba(243, 241, 251,0.5); }

/* Noise overlay */
.noise-overlay {
  position: absolute; inset: -10px; display: flex; align-items: center; justify-content: center;
  background: rgba(10, 7, 34, 0.82); backdrop-filter: blur(4px);
  border-radius: var(--radius-lg); z-index: 5;
}
.noise-card {
  text-align: center; border: 1px solid rgba(228, 87, 61, 0.4);
  background: rgba(228, 87, 61, 0.08); border-radius: var(--radius-lg);
  padding: 30px 44px;
}
.noise-title { color: #F0907C; font-size: 24px; font-weight: 700; }
.noise-desc { color: rgba(243, 241, 251,0.8); font-size: 15.5px; margin-top: 8px; max-width: 380px; }

/* ASR line */
.asr-line {
  font-size: 13.5px; color: rgba(243, 241, 251,0.45);
  padding: 10px 0; border-top: 1px solid rgba(139, 124, 246,0.12);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.asr-label {
  color: var(--gold); font-weight: 600; margin-left: 8px;
  border: 1px solid rgba(139, 124, 246,0.3); border-radius: 6px; padding: 1px 8px; font-size: 12px;
}

/* Controls */
.screen-controls { padding-top: 12px; }
.controls-row { display: flex; align-items: center; gap: 10px; }
.controls-row-2 { margin-top: 10px; flex-wrap: wrap; }
.ctl-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; height: 40px; padding: 0 12px;
  background: rgba(243, 241, 251,0.07); color: var(--cream);
  border: 1px solid rgba(243, 241, 251,0.14); border-radius: 12px;
  transition: all 0.15s; font-size: 14px; font-weight: 600;
}
.ctl-btn:hover { background: rgba(243, 241, 251,0.15); }
.ctl-primary { background: var(--gold); color: var(--g950); border-color: var(--gold); }
.ctl-primary:hover { background: var(--gold-soft); }
.ctl-text { font-size: 13.5px; }
.ctl-btn.on { background: rgba(139, 124, 246,0.25); border-color: var(--gold); color: var(--gold-soft); }

.progress-wrap {
  flex: 1; height: 10px; background: rgba(243, 241, 251,0.12);
  border-radius: 999px; cursor: pointer; overflow: hidden;
}
.progress-bar {
  height: 100%; width: 0%;
  background: linear-gradient(270deg, var(--gold), #B7ABFA);
  border-radius: 999px; transition: width 0.15s linear;
}
.time-label { font-size: 13px; opacity: 0.7; min-width: 86px; text-align: left; font-variant-numeric: tabular-nums; direction: ltr; }

.mode-toggle {
  display: inline-flex; background: rgba(243, 241, 251,0.07);
  border: 1px solid rgba(243, 241, 251,0.14); border-radius: 999px; padding: 3px;
}
.mode-toggle button {
  border: none; background: transparent; color: rgba(243, 241, 251,0.65);
  padding: 6px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
}
.mode-toggle button.on { background: var(--gold); color: var(--g950); }

.sync-widget {
  font-size: 13px; color: rgba(243, 241, 251,0.65);
  border: 1px solid rgba(243, 241, 251,0.14); border-radius: 999px; padding: 7px 16px;
}
.sync-widget strong { color: #8FD4B4; font-variant-numeric: tabular-nums; }
.sync-widget.warn strong { color: #E8B563; }

/* Start / End overlays */
.start-overlay, .end-overlay {
  position: absolute; inset: 0; z-index: 10;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  background: rgba(10, 7, 34, 0.88); backdrop-filter: blur(5px);
}
.start-btn {
  display: flex; align-items: center; gap: 14px;
  background: var(--gold); color: var(--g950);
  border: none; border-radius: 999px; padding: 18px 38px;
  font-size: 20px; font-weight: 700; transition: all 0.15s;
}
.start-btn:hover { background: var(--gold-soft); transform: scale(1.03); }
.start-note { color: rgba(243, 241, 251,0.7); font-size: 15px; max-width: 460px; text-align: center; }
.end-title { color: var(--gold-soft); font-size: 34px; font-weight: 700; }
.end-desc { color: rgba(243, 241, 251,0.8); font-size: 16px; max-width: 480px; text-align: center; }

.screen-notes { padding: 40px 0 70px; }
.screen-notes h3 { font-size: 21px; font-weight: 700; margin-bottom: 14px; }
.notes-list { list-style: none; display: grid; gap: 10px; }
.notes-list li {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px 18px; font-size: 15px; color: var(--ink-2);
}
.notes-list strong { color: var(--ink); }

/* Dashboard */
.page-head {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px;
  padding: 54px 0 8px; flex-wrap: wrap;
}
.page-sub { color: var(--ink-2); font-size: 15.5px; max-width: 640px; }

.steps-row { display: flex; gap: 10px; margin: 28px 0 18px; flex-wrap: wrap; }
.step-pill {
  flex: 1; min-width: 200px; display: flex; align-items: center; gap: 12px;
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px 18px;
}
.step-pill .dot {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(14, 138, 95, 0.12); color: var(--chart-manbar); font-weight: 700;
}
.step-pill h5 { font-size: 14.5px; font-weight: 700; }
.step-pill p { font-size: 12.5px; color: var(--ink-3); }

.dash-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.dstat {
  background: var(--g900); color: var(--cream);
  border-radius: var(--radius); padding: 18px 20px;
}
.dstat .v { font-size: 30px; font-weight: 700; color: var(--gold-soft); font-variant-numeric: tabular-nums; }
.dstat .l { font-size: 13.5px; opacity: 0.8; }

.dash-grid { display: grid; grid-template-columns: 1.9fr 1fr; gap: 20px; padding-bottom: 80px; }
.panel {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 24px;
}
.panel + .panel { margin-top: 18px; }
.panel h3 { font-size: 17.5px; font-weight: 700; margin-bottom: 14px; }
.panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; gap: 12px; flex-wrap: wrap; }
.panel-head h3 { margin-bottom: 0; }

.chip {
  font-size: 12.5px; font-weight: 700; border-radius: 999px; padding: 4px 12px;
  white-space: nowrap;
}
.chip-green { background: rgba(14,138,95,0.12); color: #0B6B4A; border: 1px solid rgba(14,138,95,0.3); }
.chip-gold { background: rgba(179,126,46,0.12); color: #8C6323; border: 1px solid rgba(179,126,46,0.35); }
.chip-outline { background: transparent; color: var(--ink-2); border: 1px solid var(--line); }
.chip-amber { background: var(--amber-bg); color: var(--amber); border: 1px solid rgba(184,117,20,0.35); }

.table-wrap { overflow-x: auto; }
.review-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.review-table th {
  text-align: right; color: var(--ink-3); font-weight: 600; font-size: 12.5px;
  padding: 10px 12px; border-bottom: 1.5px solid var(--line);
}
.review-table td {
  padding: 12px; border-bottom: 1px solid var(--cream-2); vertical-align: top;
}
.review-table tr:last-child td { border-bottom: none; }
.review-table .orig { color: var(--ink-3); font-size: 13px; }
.review-table .simp { font-weight: 500; }
.review-table .verse-row .simp { font-family: var(--font-quran); font-size: 15.5px; }

.side-list { list-style: none; display: grid; gap: 10px; }
.side-list li {
  border: 1px solid var(--cream-2); border-radius: 12px; padding: 12px 14px;
  font-size: 14px; display: flex; justify-content: space-between; align-items: center; gap: 10px;
}
.side-list .t { font-weight: 600; }
.side-list .s { font-size: 12px; color: var(--ink-3); display: block; }

.panel-next { background: var(--g900); color: var(--cream); border-color: var(--g900); }
.panel-next h3 { color: var(--gold-soft); }
.next-title { font-size: 20px; font-weight: 700; margin-bottom: 12px; }
.mini-progress { height: 8px; background: rgba(243, 241, 251,0.15); border-radius: 999px; overflow: hidden; }
.mini-progress div { height: 100%; background: var(--gold); border-radius: 999px; }
.next-note { font-size: 13px; opacity: 0.75; margin-top: 10px; }

/* Glossary */
.glossary-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 18px; padding-bottom: 80px;
}
.term-card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-lg); overflow: hidden;
  display: flex; flex-direction: column;
}
.term-thumb {
  position: relative; aspect-ratio: 16/10;
  background:
    radial-gradient(400px 200px at 50% 120%, rgba(139, 124, 246,0.25), transparent 70%),
    var(--g900);
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); border: none; transition: all 0.15s;
}
.term-thumb:hover { filter: brightness(1.2); }
.term-thumb .play-ring {
  width: 54px; height: 54px; border-radius: 50%;
  border: 2px solid var(--gold); display: flex; align-items: center; justify-content: center;
  background: rgba(139, 124, 246,0.12);
}
.term-thumb.pending { opacity: 0.55; cursor: default; }
.term-thumb.pending .play-ring { border-style: dashed; }
.term-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.term-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.term-name { font-size: 20px; font-weight: 700; }
.term-def { font-size: 14px; color: var(--ink-2); flex: 1; }
.term-signer { font-size: 12.5px; color: var(--ink-3); }

/* Impact */
.chart-panel { margin-bottom: 18px; }
.compare-chart { display: grid; gap: 18px; padding: 14px 4px 6px; }
.cbar { display: grid; grid-template-columns: 110px 1fr 64px; align-items: center; gap: 14px; }
.cbar .name { font-size: 14.5px; font-weight: 600; color: var(--ink-2); }
.cbar .track { height: 30px; background: var(--cream-2); border-radius: 6px; position: relative; }
.cbar .fill {
  position: absolute; inset-block: 0; right: 0; border-radius: 6px 2px 2px 6px;
  width: 0; transition: width 0.9s cubic-bezier(0.2, 0.7, 0.3, 1);
}
.cbar.base .fill { background: var(--chart-base); }
.cbar.manbar .fill { background: var(--chart-manbar); }
.cbar .val { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.chart-note { font-size: 13px; color: var(--ink-3); margin-top: 14px; }

.metric-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.mtile {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 26px;
}
.mtile .num { font-size: 44px; font-weight: 700; color: var(--g900); font-variant-numeric: tabular-nums; line-height: 1.2; }
.mtile .lbl { font-size: 16px; font-weight: 700; margin-top: 2px; }
.mtile .why { font-size: 13.5px; color: var(--ink-2); margin-top: 8px; }

.demo-banner {
  margin: 22px 0 8px; background: var(--amber-bg);
  border: 1px solid rgba(184,117,20,0.3); color: var(--amber);
  border-radius: var(--radius); padding: 12px 18px; font-size: 13.5px; font-weight: 600;
}
.section-inline { padding: 46px 0 90px; }

/* Modal & toast */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(10, 7, 34, 0.7); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal {
  position: relative; background: var(--paper); border-radius: var(--radius-lg);
  width: min(520px, 100%); padding: 30px; box-shadow: var(--shadow);
  animation: rise 0.25s ease;
}
@keyframes rise { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-close {
  position: absolute; top: 14px; left: 14px;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--cream); font-size: 14px;
}
.modal h3 { font-size: 21px; margin-bottom: 6px; }
.modal .sub { color: var(--ink-2); font-size: 14px; margin-bottom: 16px; }

.sign-player {
  aspect-ratio: 16/10; border-radius: var(--radius);
  background:
    radial-gradient(400px 240px at 50% 130%, rgba(139, 124, 246,0.3), transparent 70%),
    var(--g900);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: var(--gold-soft); gap: 10px; margin-bottom: 14px; overflow: hidden; position: relative;
}
.sign-hands { font-size: 15px; letter-spacing: 1px; color: var(--gold); font-weight: 700; }
.sign-anim {
  width: 74px; height: 74px; border-radius: 50%;
  border: 2px solid var(--gold);
  display: flex; align-items: center; justify-content: center;
  animation: signPulse 1.4s ease-in-out infinite;
}
@keyframes signPulse { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.12); opacity: 0.75; } }
.sign-meta { font-size: 13px; color: var(--ink-2); display: grid; gap: 4px; }
.sign-meta strong { color: var(--ink); }

.dropzone {
  border: 2px dashed var(--line); border-radius: var(--radius);
  padding: 34px; text-align: center; color: var(--ink-3); font-size: 14.5px;
  margin-bottom: 16px; background: var(--cream);
}
.modal .btn { width: 100%; }

.toast {
  position: fixed; bottom: 26px; right: 50%; transform: translateX(50%);
  z-index: 120; background: var(--g900); color: var(--cream);
  border-radius: 999px; padding: 12px 26px; font-size: 14.5px; font-weight: 600;
  box-shadow: var(--shadow); animation: rise 0.3s ease;
}

/* Responsive */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; padding: 60px 0 50px; }
  .cards-3, .cards-2, .modes-duo, .stat-duo { grid-template-columns: 1fr; }
  .dash-grid { grid-template-columns: 1fr; }
  .dash-stats { grid-template-columns: repeat(2, 1fr); }
  .metric-tiles { grid-template-columns: 1fr; }
  .pipeline { flex-direction: column; }
  .pipe-arrow { transform: rotate(90deg); align-self: flex-start; margin-right: 24px; }
  .screen-body { flex-direction: column; align-items: stretch; gap: 20px; }
}
@media (max-width: 760px) {
  .nav {
    position: fixed; inset: 62px 0 auto 0; z-index: 49;
    flex-direction: column; background: var(--cream);
    border-bottom: 1px solid var(--line); padding: 12px 5vw 18px;
    display: none;
  }
  .nav.open { display: flex; }
  body[data-view="screen"] .nav { background: var(--g950); }
  .nav-toggle { display: block; }
  .sim-badge { margin-right: auto; }
  .cbar { grid-template-columns: 84px 1fr 52px; }
  .cbar .name { font-size: 12.5px; }
  .controls-row { flex-wrap: wrap; }
  .time-label { min-width: auto; }
}

/* media blocks */
.hero-figure { position: relative; justify-self: center; margin: 0; }
.hero-figure img {
  width: min(320px, 38vw); aspect-ratio: 3 / 4.2; object-fit: cover;
  border-radius: 50% 50% var(--radius-lg) var(--radius-lg) / 36% 36% var(--radius-lg) var(--radius-lg);
  border: 2px solid rgba(139, 124, 246, 0.55);
  outline: 1px solid rgba(139, 124, 246, 0.25); outline-offset: 10px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
}
.hero-figure figcaption {
  text-align: center; font-size: 12.5px; color: rgba(243, 241, 251, 0.55); margin-top: 16px;
}

.split-media { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 48px; align-items: center; }
.split-figure { margin: 0; }
.split-figure img {
  width: 100%; max-height: 520px; object-fit: cover;
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
}
.split-figure figcaption { font-size: 13px; color: var(--ink-3); margin-top: 10px; }

.quote-band {
  background:
    radial-gradient(800px 400px at 80% 0%, rgba(139, 124, 246, 0.12), transparent 60%),
    var(--g950);
  color: var(--cream); padding: 64px 0;
}
.quote-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 48px; align-items: center; }
.quote-grid blockquote { border-right: 4px solid var(--gold); padding-right: 24px; }
.quote-grid blockquote p { font-size: clamp(26px, 3.4vw, 38px); font-weight: 700; color: var(--gold-soft); line-height: 1.6; }
.quote-grid blockquote footer { margin-top: 12px; font-size: 16px; opacity: 0.85; }
.quote-figure { margin: 0; justify-self: center; }
.quote-figure img {
  width: min(280px, 60vw); aspect-ratio: 1; object-fit: cover; object-position: center 25%;
  border-radius: 50%; border: 3px solid rgba(139, 124, 246, 0.5);
  outline: 1px solid rgba(139, 124, 246, 0.22); outline-offset: 12px;
}

.page-figure { margin: 0; flex-shrink: 0; }
.page-figure img {
  width: 190px; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow);
}
.page-figure figcaption { font-size: 12px; color: var(--ink-3); margin-top: 8px; text-align: center; }

.vision-band { position: relative; border-radius: var(--radius-lg); overflow: hidden; margin-top: 46px; }
.vision-band img { width: 100%; height: 300px; object-fit: cover; display: block; }
.vision-overlay {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 30px 34px; color: var(--cream);
  background: linear-gradient(180deg, rgba(10, 7, 34, 0.05) 30%, rgba(10, 7, 34, 0.85));
}
.vision-overlay .sec-kicker { color: var(--kicker-soft); margin-bottom: 4px; }
.vision-overlay h3 { font-size: clamp(24px, 3vw, 34px); font-weight: 700; }
.section-inline { padding: 26px 0 90px; }

/* glossary video thumbs */
.term-thumb { padding: 0; }
.term-thumb video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.term-thumb .play-ring { position: relative; z-index: 2; }
.term-thumb.has-video::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(10, 7, 34, 0.55));
}
.term-thumb.has-video:hover .play-ring { opacity: 0; }

/* sign modal video */
.sign-player.has-video { background: var(--g950); padding: 0; aspect-ratio: auto; }
.sign-player.has-video video { width: 100%; max-height: 340px; display: block; }
.demo-tag {
  font-size: 12px; color: var(--amber); background: var(--amber-bg);
  border: 1px solid rgba(184, 117, 20, 0.3); border-radius: 8px;
  padding: 6px 12px; margin-bottom: 14px;
}

.footer-small { max-width: 460px; display: grid; gap: 10px; }
.footer-credits { font-size: 11.5px; opacity: 0.45; line-height: 1.8; }

@media (max-width: 960px) {
  .split-media, .quote-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero-figure { display: block; margin-top: 8px; }
  .hero-figure img { width: min(300px, 70vw); }
  .page-head .page-figure { display: none; }
  .vision-band img { height: 220px; }
}

/* new-concept components */
.hero-platforms { margin-top: 18px; font-size: 13.5px; color: rgba(243, 241, 251, 0.55); }

.cards-top { margin-top: 26px; }
.card .card-h4 { font-size: 17px; font-weight: 700; margin-bottom: 8px; color: var(--ink); }

.tech-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.tech-chips span {
  background: var(--g900); color: var(--cream);
  border-radius: 999px; padding: 8px 18px; font-size: 13.5px; font-weight: 600;
  direction: ltr;
}
.tech-note { margin-top: 14px; font-size: 13.5px; color: var(--ink-2); }

/* digital signer panel */
.signer-panel { width: clamp(240px, 25vw, 330px); flex-shrink: 0; }
.signer-frame {
  position: relative; aspect-ratio: 3 / 4; border-radius: var(--radius-lg); overflow: hidden;
  background:
    radial-gradient(300px 220px at 50% 110%, rgba(139, 124, 246, 0.18), transparent 70%),
    var(--g900);
  border: 1.5px solid rgba(139, 124, 246, 0.45);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35);
}
.signer-frame video { width: 100%; height: 100%; object-fit: cover; display: block; }
.signer-tag {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  background: rgba(10, 7, 34, 0.75); color: var(--gold-soft);
  border: 1px solid rgba(139, 124, 246, 0.4);
  font-size: 12px; font-weight: 700; border-radius: 999px; padding: 4px 12px;
}
.signer-flag {
  position: absolute; bottom: 12px; inset-inline: 12px; z-index: 2; text-align: center;
  background: rgba(184, 117, 20, 0.28); color: #F0C987;
  border: 1px solid rgba(232, 181, 99, 0.5); backdrop-filter: blur(4px);
  font-size: 12px; font-weight: 700; border-radius: 10px; padding: 5px 10px;
}
.signer-idle {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 10px;
  color: var(--gold); font-size: 14px; background: var(--g900); z-index: 1;
}
.screen-stage.noisy .signer-frame video { filter: blur(6px) brightness(0.45); }
.signer-note {
  font-size: 12.5px; color: rgba(243, 241, 251, 0.55);
  margin-top: 10px; text-align: center; line-height: 1.8;
}
.signer-note strong { color: var(--gold-soft); font-weight: 600; }

/* worshipper-language mode */
.lang-toggle button[disabled] { opacity: 0.35; cursor: default; }
.screen-stage[data-lang="en"] .current-line {
  direction: ltr; text-align: left;
  border-right: none; padding-right: 0;
  border-left: 5px solid var(--gold); padding-left: 22px;
}
.screen-stage[data-lang="en"] .prev-line { direction: ltr; text-align: left; }
.verse-tafsir.en-tafsir { direction: ltr; text-align: left; }
.verse-tafsir.en-tafsir::before { content: "Approved translation · "; }

/* mosque picker */
.start-title { color: var(--gold-soft); font-size: 26px; font-weight: 700; }
.mosque-list { display: grid; gap: 12px; width: min(440px, 90%); }
.mosque-card {
  display: flex; justify-content: space-between; align-items: center; gap: 14px;
  background: rgba(243, 241, 251, 0.06); border: 1px solid rgba(243, 241, 251, 0.14);
  border-radius: 14px; padding: 16px 20px; color: var(--cream); text-align: right;
}
.mosque-card.live { border-color: rgba(139, 124, 246, 0.7); background: rgba(139, 124, 246, 0.1); cursor: pointer; }
.mosque-card.live:hover { background: rgba(139, 124, 246, 0.22); transform: translateY(-1px); }
.mosque-card[disabled] { opacity: 0.45; cursor: default; }
.mosque-name { font-weight: 700; font-size: 16.5px; }
.mosque-name small { opacity: 0.6; font-weight: 400; font-size: 12.5px; }
.mosque-status { font-size: 12.5px; opacity: 0.7; white-space: nowrap; }
.mosque-status.on { color: #F0907C; opacity: 1; display: inline-flex; align-items: center; gap: 7px; }
.mosque-status.on i {
  width: 7px; height: 7px; border-radius: 50%; background: var(--live);
  animation: pulse 1.6s ease-in-out infinite;
}

@media (max-width: 960px) {
  .signer-panel { width: min(250px, 68vw); margin-inline: auto; }
}

/* live prototype link */
.nav .nav-live { border: 1.5px solid var(--gold); color: var(--gold-deep); opacity: 1; font-weight: 700; }
.nav .nav-live:hover { background: var(--gold); color: var(--g950); }
body[data-view="screen"] .nav .nav-live { color: var(--gold-soft); }
