/* ==========================================================================
   Sabeeli (سبيلي) — Tone-on-Tone Sanctuary Web & Mobile Design System
   Animated Calligraphic Hero · 3 Store Channels · Pixel-Perfect Mobile UI
   ========================================================================== */

:root {
  --bg: #F8F5EE;
  --bg-subtle: #F2EDE2;
  --surface: #FFFFFF;
  --surface-2: #F5F0E6;
  --ink: #101B19;
  --ink-2: #485854;
  --ink-3: #76847F;
  --line: rgba(1, 64, 63, 0.085);
  --line-strong: rgba(1, 64, 63, 0.16);
  --gold-line: rgba(197, 160, 89, 0.34);
  --accent: #064E3B;
  --accent-ink: #FFFFFF;
  --deep: #013836;
  --gold: #C5A059;
  --soft: color-mix(in srgb, var(--accent) 8%, transparent);
  --soft-gold: color-mix(in srgb, var(--gold) 14%, transparent);
  --shadow-card: 0 1px 2px rgba(1, 40, 38, 0.03), 0 16px 36px -26px rgba(1, 40, 38, 0.12);
  --shadow-emblem: 0 20px 50px -20px rgba(1, 64, 63, 0.16), 0 2px 6px rgba(1, 64, 63, 0.04);
  --shadow-float: 0 22px 54px -18px rgba(1, 32, 30, 0.24);

  --hero-grad: linear-gradient(180deg, #FCF9F2 0%, #F6F0E4 58%, #EFE7D6 100%);
  --halo-glow: radial-gradient(circle, rgba(255, 255, 255, 0.95) 0%, rgba(197, 160, 89, 0.14) 44%, transparent 72%);

  --font-sans: 'Plus Jakarta Sans', 'IBM Plex Sans Arabic', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --font-serif: 'Amiri', Georgia, serif;
  --font-quran: 'Amiri Quran', 'Amiri', serif;

  --max: 1120px;
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-pill: 999px;
}

html[data-scheme="dark"] {
  --bg: #0A1210;
  --bg-subtle: #0E1815;
  --surface: #131F1C;
  --surface-2: #192824;
  --ink: #F3EFE6;
  --ink-2: #A6B4AF;
  --ink-3: #6E7E78;
  --line: rgba(243, 239, 230, 0.085);
  --line-strong: rgba(243, 239, 230, 0.17);
  --gold-line: rgba(227, 201, 156, 0.28);
  --accent: #5EEAD4;
  --accent-ink: #042420;
  --deep: #052E2B;
  --gold: #E3C99C;
  --soft: color-mix(in srgb, var(--accent) 11%, transparent);
  --soft-gold: color-mix(in srgb, var(--gold) 14%, transparent);
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.26), 0 20px 44px -26px rgba(0, 0, 0, 0.55);
  --shadow-emblem: 0 24px 60px -20px rgba(0, 0, 0, 0.65), 0 0 40px -12px rgba(94, 234, 212, 0.14);
  --shadow-float: 0 26px 64px -18px rgba(0, 0, 0, 0.76);

  --hero-grad: linear-gradient(180deg, #032B29 0%, #071A18 58%, #0A1210 100%);
  --halo-glow: radial-gradient(circle, rgba(16, 118, 110, 0.42) 0%, rgba(227, 201, 156, 0.09) 46%, transparent 72%);
}

/* Script-aware typography */
html[lang="ar"] {
  --font-sans: 'IBM Plex Sans Arabic', 'Plus Jakarta Sans', system-ui, sans-serif;
}
html[lang="fa"] {
  --font-sans: 'Vazirmatn', 'IBM Plex Sans Arabic', system-ui, sans-serif;
}
html[lang="ps"] {
  --font-sans: 'Noto Sans Arabic', 'IBM Plex Sans Arabic', system-ui, sans-serif;
}
html[lang="ru"] {
  --font-sans: 'Manrope', 'Plus Jakarta Sans', system-ui, sans-serif;
}
html[lang="ur"] {
  --font-sans: 'Noto Nastaliq Urdu', 'IBM Plex Sans Arabic', system-ui, serif;
  line-height: 2.0;
}
html[lang="bn"] {
  --font-sans: 'Noto Sans Bengali', 'Plus Jakarta Sans', system-ui, sans-serif;
}
html[lang="hi"] {
  --font-sans: 'Noto Sans Devanagari', 'Plus Jakarta Sans', system-ui, sans-serif;
}
html[lang="zh"] {
  --font-sans: 'Noto Sans SC', 'Plus Jakarta Sans', system-ui, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
img { display: block; max-width: 100%; }
::selection { background: var(--accent); color: var(--accent-ink); }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 24px;
}

.sacred-ar {
  font-family: var(--font-quran);
  direction: rtl;
  unicode-bidi: isolate;
}
.accent-text {
  color: var(--accent);
}

/* ==========================================================================
   1. Minimal Glass Top Navigation
   ========================================================================== */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 80;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease, background-color 0.3s ease;
}
.site-nav.scrolled {
  border-bottom-color: var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}
.brand-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.brand-mark-nav {
  height: 31px;
  width: auto;
  object-fit: contain;
}
html[data-scheme="dark"] .mark-light-only { display: none; }
html:not([data-scheme="dark"]) .mark-dark-only { display: none; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink-2);
}
.nav-links a {
  transition: color 0.2s ease;
  white-space: nowrap;
}
.nav-links a:hover {
  color: var(--ink);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}
.icon-pill, .lang-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  padding-inline: 12px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  font-size: 0.81rem;
  font-weight: 600;
  color: var(--ink-2);
  transition: border-color 0.2s ease, color 0.2s ease, background-color 0.2s ease;
}
.icon-pill {
  width: 36px;
  padding-inline: 0;
}
.icon-pill:hover, .lang-trigger:hover {
  border-color: var(--line-strong);
  color: var(--ink);
  background: var(--surface);
}
.icon-pill svg, .lang-trigger svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}
.nav-cta-btn {
  display: inline-flex;
  align-items: center;
  height: 36px;
  padding-inline: 16px;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-cta-btn:hover {
  transform: translateY(-1px);
  opacity: 0.92;
}

/* Language Popover */
.lang-popover {
  position: absolute;
  top: calc(100% + 10px);
  inset-inline-end: 0;
  width: min(500px, calc(100vw - 32px));
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  padding: 10px;
  box-shadow: var(--shadow-float);
  display: none;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px;
  z-index: 95;
}
.lang-popover.open {
  display: grid;
  animation: popIn 0.16s ease-out;
}
@keyframes popIn {
  from { opacity: 0; transform: translateY(-6px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.lang-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 9px 10px;
  border-radius: 11px;
  text-align: start;
  font-size: 0.82rem;
  color: var(--ink-2);
  min-width: 0;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.lang-opt span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lang-opt:hover {
  background: var(--surface-2);
  color: var(--ink);
}
.lang-opt[aria-current="true"] {
  background: var(--soft);
  color: var(--accent);
  font-weight: 600;
}
.lang-opt .mono {
  font-size: 0.67rem;
  opacity: 0.65;
  font-weight: 600;
  flex-shrink: 0;
}

/* ==========================================================================
   2. Tone-on-Tone Sanctuary Hero + Live Animated Calligraphic Logo
   ========================================================================== */
.hero {
  position: relative;
  padding: 58px 0 80px;
  background: var(--hero-grad);
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

/* Ambient Drifting Calligraphic Watermarks (matches SabeeliSplashHost) */
.hero-wm {
  position: absolute;
  pointer-events: none;
  user-select: none;
  will-change: transform;
}
.hero-wm-top {
  top: -80px;
  inset-inline-start: -140px;
  width: min(620px, 82vw);
  opacity: 0.042;
  filter: brightness(0);
  animation: wmDriftTop 22s ease-in-out infinite alternate;
}
html[data-scheme="dark"] .hero-wm-top {
  filter: none;
  opacity: 0.05;
}
.hero-wm-bottom {
  bottom: -90px;
  inset-inline-end: -110px;
  width: min(520px, 74vw);
  opacity: 0.065;
  animation: wmDriftBottom 26s ease-in-out infinite alternate;
}
html[data-scheme="dark"] .hero-wm-bottom {
  filter: invert(1);
  opacity: 0.045;
}

@keyframes wmDriftTop {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(18px, 14px, 0) scale(1.04); }
}
@keyframes wmDriftBottom {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(-16px, -12px, 0) scale(1.03); }
}

.hero-center {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  margin-inline: auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  max-width: 100%;
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--gold-line);
  background: color-mix(in srgb, var(--surface) 76%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 30px;
}
.hero-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 3px var(--soft-gold);
  flex-shrink: 0;
  animation: badgePulse 2.8s ease-in-out infinite;
}
@keyframes badgePulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.25); opacity: 0.72; }
}

/* Living Animated Calligraphic Medallion Stage */
.hero-emblem-stage {
  position: relative;
  width: clamp(216px, 28vw, 276px);
  height: clamp(168px, 21vw, 214px);
  margin: 0 auto 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.hero-halo {
  position: absolute;
  inset: -44px;
  background: var(--halo-glow);
  border-radius: 50%;
  pointer-events: none;
  animation: haloBreath 5.6s ease-in-out infinite;
}
@keyframes haloBreath {
  0%, 100% { transform: scale(0.96); opacity: 0.85; }
  50%      { transform: scale(1.07); opacity: 1; }
}

.hero-orbit-ring {
  position: absolute;
  width: clamp(192px, 24.5vw, 244px);
  height: clamp(192px, 24.5vw, 244px);
  border-radius: 50%;
  border: 1px dashed var(--gold-line);
  pointer-events: none;
  animation: orbitSlow 38s linear infinite;
}
@keyframes orbitSlow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.orbit-gem {
  position: absolute;
  left: 50%;
  width: 7px;
  height: 7px;
  background: var(--gold);
  transform: translateX(-50%) rotate(45deg);
}
.orbit-gem-n { top: -4px; }
.orbit-gem-s { bottom: -4px; }

.hero-emblem-frame {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  border-radius: 30px;
  background: color-mix(in srgb, var(--surface) 74%, transparent);
  backdrop-filter: saturate(150%) blur(16px);
  -webkit-backdrop-filter: saturate(150%) blur(16px);
  border: 1px solid var(--gold-line);
  box-shadow: var(--shadow-emblem);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: transform 0.28s cubic-bezier(0.16, 0.8, 0.2, 1), border-color 0.28s ease;
}
.hero-emblem-stage:hover .hero-emblem-frame {
  transform: translateY(-2px) scale(1.015);
  border-color: var(--gold);
}
.hero-emblem-stage:active .hero-emblem-frame {
  transform: scale(0.985);
}

/* 512x512 animated WebP cropped optically around its calligraphic stroke bbox */
.hero-logo-img {
  width: clamp(198px, 25.5vw, 252px);
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  margin-block: -20px;
  filter: drop-shadow(0 6px 18px rgba(1, 64, 63, 0.08));
}
html[data-scheme="dark"] .hero-logo-img {
  filter: drop-shadow(0 8px 22px rgba(0, 0, 0, 0.38));
}

/* Gold Filigree Rule (matches SabeeliSplashHost._rule + _Diamond) */
.hero-filigree {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 auto 16px;
}
.filigree-line {
  width: 56px;
  height: 1px;
}
.filigree-start {
  background: linear-gradient(90deg, transparent, var(--gold));
}
.filigree-end {
  background: linear-gradient(90deg, var(--gold), transparent);
}
html[dir="rtl"] .filigree-start {
  background: linear-gradient(270deg, transparent, var(--gold));
}
html[dir="rtl"] .filigree-end {
  background: linear-gradient(270deg, var(--gold), transparent);
}
.filigree-diamond {
  width: 7px;
  height: 7px;
  background: var(--gold);
  transform: rotate(45deg);
  flex-shrink: 0;
}

.hero h1 {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(2.15rem, 5vw, 3.75rem);
  line-height: 1.18;
  letter-spacing: -0.012em;
  text-wrap: balance;
}
html[lang="ur"] .hero h1 {
  font-family: var(--font-sans);
  line-height: 1.65;
}

.hero-lead {
  max-width: 560px;
  margin: 14px auto 0;
  font-size: clamp(0.95rem, 1.25vw, 1.07rem);
  color: var(--ink-2);
  text-wrap: pretty;
}

/* 4-Store Conversion Dock: App Store · Google Play · Huawei Edition · Official APK */
.store-trio {
  margin: 30px auto 0;
  max-width: 960px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
  text-align: start;
}

.store-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  border-radius: 17px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-card);
  min-width: 0;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.store-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-float);
  border-color: var(--accent);
}
.store-btn:active {
  transform: scale(0.985);
}

/* 1. App Store (Primary Sacred Emerald / Luminous Teal) */
.store-btn.store-ios {
  background: linear-gradient(150deg, var(--deep) 0%, #064E3B 100%);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.14);
}
html[data-scheme="dark"] .store-btn.store-ios {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: transparent;
}

/* 2. Google Play (Authoritative Obsidian / Warm Ivory) */
.store-btn.store-play {
  background: #101B19;
  color: #F8F5EE;
  border-color: rgba(255, 255, 255, 0.1);
}
html[data-scheme="dark"] .store-btn.store-play {
  background: #F3EFE6;
  color: #0A1210;
  border-color: transparent;
}

/* 3. Huawei Edition (Refined Crimson Petal Accent — Zero GBox Required) */
.store-btn.store-huawei {
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  border-color: rgba(199, 0, 11, 0.28);
}
html[data-scheme="dark"] .store-btn.store-huawei {
  border-color: rgba(248, 113, 113, 0.34);
}
.store-btn.store-huawei:hover {
  border-color: #C7000B;
}
html[data-scheme="dark"] .store-btn.store-huawei:hover {
  border-color: #FB7185;
}

/* 4. Official Signed APK */
.store-btn.store-apk {
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  border-color: var(--gold-line);
}

.store-ic {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: var(--soft);
  color: var(--accent);
}
.store-btn.store-ios .store-ic {
  background: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
}
html[data-scheme="dark"] .store-btn.store-ios .store-ic {
  background: rgba(4, 36, 32, 0.13);
  color: var(--accent-ink);
}
.store-btn.store-play .store-ic {
  background: rgba(255, 255, 255, 0.12);
  color: #5EEAD4;
}
html[data-scheme="dark"] .store-btn.store-play .store-ic {
  background: rgba(10, 18, 16, 0.09);
  color: #064E3B;
}
.store-btn.store-huawei .store-ic {
  background: rgba(199, 0, 11, 0.11);
  color: #C7000B;
}
html[data-scheme="dark"] .store-btn.store-huawei .store-ic {
  background: rgba(251, 113, 133, 0.16);
  color: #FB7185;
}
.store-btn.store-apk .store-ic {
  background: var(--soft-gold);
  color: var(--gold);
}
html:not([data-scheme="dark"]) .store-btn.store-apk .store-ic {
  color: #8A6826;
}
.store-ic svg {
  width: 20px;
  height: 20px;
}

.store-meta {
  min-width: 0;
  flex: 1;
}
.store-kicker {
  display: block;
  font-size: 0.69rem;
  opacity: 0.76;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.store-title {
  display: block;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.25;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Subtle Desktop QR Inline Pill */
.qr-inline {
  margin: 18px auto 0;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  padding: 7px 15px 7px 9px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 74%, transparent);
  font-size: 0.78rem;
  color: var(--ink-3);
}
html[dir="rtl"] .qr-inline {
  padding: 7px 9px 7px 15px;
}
.qr-mini-box {
  width: 34px;
  height: 34px;
  padding: 3px;
  border-radius: 8px;
  background: #FFFFFF;
  color: #0A1210;
  border: 1px solid rgba(1, 64, 63, 0.1);
  flex-shrink: 0;
}
.qr-mini-box svg {
  width: 100%;
  height: 100%;
  display: block;
  shape-rendering: crispEdges;
}

/* ==========================================================================
   3. Minimal Section Headers (Zero Paragraph Bloat)
   ========================================================================== */
.section-block {
  padding: 80px 0;
}
.section-block.alt-bg {
  background: var(--bg-subtle);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section-head-min {
  text-align: center;
  max-width: 660px;
  margin: 0 auto 40px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 10px;
  letter-spacing: 0.02em;
}
.eyebrow::before {
  content: "";
  width: 5px;
  height: 5px;
  transform: rotate(45deg);
  background: var(--gold);
  flex-shrink: 0;
}
.section-head-min h2 {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(1.75rem, 3.4vw, 2.5rem);
  line-height: 1.24;
  text-wrap: balance;
}
html[lang="ur"] .section-head-min h2 {
  font-family: var(--font-sans);
  line-height: 1.65;
}

/* ==========================================================================
   4. "Only in Sabeeli" — 8 Minimal Bento Cards (Short Title + 1 Line Only)
   ========================================================================== */
.exclusives-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.excl-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 22px 20px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 11px;
  min-width: 0;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.excl-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
}
.excl-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.excl-icon {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.excl-icon svg {
  width: 19px;
  height: 19px;
}
.excl-tag {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--accent);
  background: var(--soft);
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}
.excl-card h3 {
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.38;
  color: var(--ink);
  overflow-wrap: anywhere;
}
.excl-line {
  font-size: 0.85rem;
  color: var(--ink-2);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

/* ==========================================================================
   5. 24-Tool Compact Pill Grid (Zero Paragraph Clutter)
   ========================================================================== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px;
  margin-bottom: 26px;
}
.filter-pill {
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 0.81rem;
  font-weight: 600;
  color: var(--ink-2);
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.18s ease;
}
.filter-pill:hover {
  border-color: var(--line-strong);
  color: var(--ink);
}
.filter-pill.on {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.eco-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.eco-chip {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 13px 14px;
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  transition: border-color 0.18s ease, transform 0.18s ease;
}
.eco-chip:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
}
.eco-chip-ic {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.eco-chip-ic svg {
  width: 16px;
  height: 16px;
}
.eco-chip span {
  font-size: 0.86rem;
  font-weight: 600;
  line-height: 1.34;
  color: var(--ink);
  min-width: 0;
  overflow-wrap: anywhere;
}

/* ==========================================================================
   6. Sacred Origin Verse & 15 Native Global Languages
   ========================================================================== */
.origin-band {
  padding: 54px 0;
  text-align: center;
  border-bottom: 1px solid var(--line);
}
.origin-band blockquote {
  font-size: clamp(1.36rem, 2.8vw, 2.1rem);
  line-height: 2.05;
  color: var(--ink);
  max-width: 740px;
  margin-inline: auto;
}
.origin-band cite {
  display: inline-block;
  margin-top: 10px;
  font-style: normal;
  font-size: 0.8rem;
  color: var(--gold);
  font-weight: 600;
}

.lang-matrix {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}
.lang-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 14px;
  text-align: start;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  transition: border-color 0.18s ease, transform 0.18s ease, background-color 0.18s ease;
}
.lang-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-1.5px);
}
.lang-card[aria-current="true"] {
  border-color: var(--accent);
  background: var(--soft);
}
.lang-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-size: 0.7rem;
  color: var(--ink-3);
}
.lang-card[aria-current="true"] .lang-card-top {
  color: var(--accent);
  font-weight: 600;
}
.lang-native {
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ==========================================================================
   7. Final Minimal Download Sanctuary & Footer
   ========================================================================== */
.final-cta {
  text-align: center;
  padding: 80px 0 88px;
  border-top: 1px solid var(--line);
  background: radial-gradient(circle at 50% 0%, var(--soft) 0%, transparent 70%);
}
.final-emblem {
  display: flex;
  justify-content: center;
  align-items: center;
}
.final-cta h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.95rem, 4.4vw, 3.15rem);
  line-height: 1.22;
  font-weight: 700;
  margin-top: 16px;
  text-wrap: balance;
}
html[lang="ur"] .final-cta h2 {
  font-family: var(--font-sans);
  line-height: 1.65;
}
.final-note {
  display: block;
  margin-top: 20px;
  font-size: 0.8rem;
  color: var(--ink-3);
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 28px 0 calc(40px + env(safe-area-inset-bottom, 0px));
  font-size: 0.84rem;
  color: var(--ink-3);
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.footer-brand img {
  height: 24px;
  width: auto;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}
.footer-links a:hover {
  color: var(--ink);
}

/* ==========================================================================
   8. Floating Bottom Download Dock (App Store + Google Play + Direct APK)
   ========================================================================== */
.sticky-dl-bar {
  position: fixed;
  inset-inline: 16px;
  bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  z-index: 85;
  max-width: 820px;
  margin-inline: auto;
  padding: 8px 10px 8px 18px;
  border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: saturate(170%) blur(20px);
  -webkit-backdrop-filter: saturate(170%) blur(20px);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-float);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(18px);
  transition: opacity 0.24s ease, transform 0.24s ease;
}
html[dir="rtl"] .sticky-dl-bar {
  padding: 8px 18px 8px 10px;
}
.sticky-dl-bar.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.sticky-dl-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.sticky-dl-brand img {
  height: 22px;
  width: auto;
  flex-shrink: 0;
}
.sticky-dl-brand strong {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sticky-dl-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.sticky-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 38px;
  padding-inline: 14px;
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
  min-width: 0;
  transition: transform 0.16s ease, opacity 0.16s ease;
}
.sticky-pill span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sticky-pill:hover {
  transform: translateY(-1px);
  opacity: 0.92;
}
.sticky-pill:active {
  transform: scale(0.97);
}
.sticky-pill svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
.sticky-pill-ios {
  background: var(--accent);
  color: var(--accent-ink);
}
.sticky-pill-play {
  background: var(--ink);
  color: var(--bg);
}
.sticky-pill-huawei {
  background: rgba(199, 0, 11, 0.1);
  color: #B91C1C;
  border: 1px solid rgba(199, 0, 11, 0.28);
}
html[data-scheme="dark"] .sticky-pill-huawei {
  background: rgba(251, 113, 133, 0.14);
  color: #FDA4AF;
  border-color: rgba(251, 113, 133, 0.34);
}
.sticky-pill-apk {
  background: var(--surface-2);
  color: var(--ink);
  border: 1px solid var(--gold-line);
}

/* ==========================================================================
   9. Legal Sub-Pages (privacy.html & data-deletion.html)
   ========================================================================== */
.legal-main {
  max-width: 820px;
  margin-inline: auto;
  padding: 56px 24px 96px;
}
.legal-hero {
  text-align: center;
  margin-bottom: 40px;
}
.legal-hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  line-height: 1.25;
  margin-bottom: 12px;
}
.legal-hero p {
  color: var(--ink-2);
  max-width: 640px;
  margin-inline: auto;
}
.legal-updated {
  margin-top: 10px;
  font-size: 0.82rem;
  color: var(--ink-3);
}
.legal-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.legal-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 22px 24px;
}
.legal-card h2 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--ink);
}
.legal-card p, .legal-card li {
  color: var(--ink-2);
  font-size: 0.93rem;
}
.legal-card ol {
  padding-inline-start: 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}
.danger-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 12px 22px;
  border-radius: var(--radius-pill);
  background: #BE123C;
  color: #FFFFFF;
  font-size: 0.88rem;
  font-weight: 600;
}
.danger-btn:hover { opacity: 0.92; }

/* Gentle Scroll Reveal */
.reveal {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal.in {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-wm, .hero-halo, .hero-orbit-ring, .hero-badge-dot { animation: none !important; }
  html { scroll-behavior: auto; }
}

/* ==========================================================================
   10. Tablet & Mobile Breakpoints — Crafted Specifically for Mobile Thumbs
   ========================================================================== */
@media (max-width: 980px) {
  .nav-links { display: none; }
  .store-trio {
    max-width: 560px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .exclusives-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .eco-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lang-matrix { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .qr-inline { display: none; }
  .section-block { padding: 64px 0; }
}

@media (max-width: 680px) {
  .wrap { padding-inline: 16px; }
  .nav-inner { height: 58px; gap: 10px; }
  .brand-mark-nav { height: 28px; }
  .nav-cta-btn { display: none; }
  .icon-pill { width: 38px; height: 38px; }
  .lang-trigger { height: 38px; padding-inline: 13px; }

  /* Full-width viewport-safe mobile language sheet */
  .lang-popover {
    position: fixed;
    top: 66px;
    inset-inline: 12px;
    width: auto;
    max-height: calc(100svh - 82px);
    overflow-y: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 10px;
    border-radius: 20px;
  }

  /* Above-the-fold Mobile Sanctuary Hero */
  .hero {
    min-height: calc(100svh - 58px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 26px 0 38px;
  }
  .hero-badge {
    font-size: 0.72rem;
    padding: 5px 13px;
    margin-bottom: 24px;
  }
  .hero-emblem-stage {
    width: 212px;
    height: 162px;
    margin-bottom: 24px;
  }
  .hero-orbit-ring {
    width: 190px;
    height: 190px;
  }
  .hero-emblem-frame {
    border-radius: 26px;
  }
  .hero-logo-img {
    width: 196px;
    margin-block: -18px;
  }
  .hero-filigree {
    margin-bottom: 12px;
  }
  .filigree-line {
    width: 42px;
  }
  .hero h1 {
    font-size: clamp(1.88rem, 7.6vw, 2.35rem);
    line-height: 1.22;
  }
  .hero-lead {
    font-size: 0.92rem;
    line-height: 1.56;
    margin-top: 10px;
    max-width: 340px;
  }

  /* Signature 2+1 Mobile Store Bento:
     Row 1: App Store + Google Play side-by-side
     Row 2: Official Direct APK full-width bar */
  .store-trio {
    margin-top: 22px;
    max-width: 420px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }
  .store-btn {
    padding: 11px 12px;
    gap: 10px;
    border-radius: 15px;
  }
  .store-ic {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }
  .store-ic svg {
    width: 18px;
    height: 18px;
  }
  .store-kicker {
    font-size: 0.64rem;
  }
  .store-title {
    font-size: 0.9rem;
  }
  .store-btn.store-apk {
    grid-column: 1 / -1;
    justify-content: center;
    padding: 11px 16px;
  }
  .store-btn.store-apk .store-meta {
    flex: 0 1 auto;
  }

  /* Mobile Sections & Cards */
  .section-block { padding: 52px 0; }
  .section-head-min { margin-bottom: 28px; }
  .section-head-min h2 { font-size: clamp(1.5rem, 6.2vw, 1.95rem); }

  .exclusives-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .excl-card {
    padding: 17px 16px;
    border-radius: 17px;
    gap: 9px;
  }

  /* Swipeable single-row filter pills + compact 2-column tool chips */
  .filter-bar {
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    margin-inline: -16px;
    padding-inline: 16px;
    padding-bottom: 4px;
    margin-bottom: 18px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .filter-bar::-webkit-scrollbar { display: none; }

  .eco-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .eco-chip {
    padding: 11px 11px;
    gap: 9px;
    border-radius: 13px;
  }
  .eco-chip-ic {
    width: 28px;
    height: 28px;
    border-radius: 8px;
  }
  .eco-chip-ic svg {
    width: 14px;
    height: 14px;
  }
  .eco-chip span {
    font-size: 0.79rem;
    line-height: 1.3;
  }

  .origin-band { padding: 42px 0; }

  .lang-matrix {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .final-cta { padding: 58px 0 64px; }

  /* Safe bottom clearance so floating dock never covers footer links */
  .site-footer {
    padding: 24px 0 calc(88px + env(safe-area-inset-bottom, 0px));
  }
  .footer-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
  }
  .footer-links {
    justify-content: center;
    gap: 18px;
  }

  /* Sleek Mobile Floating Bottom Dock */
  .sticky-dl-bar,
  html[dir="rtl"] .sticky-dl-bar {
    inset-inline: 10px;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    padding: 6px;
    justify-content: center;
  }
  .sticky-dl-brand { display: none; }
  .sticky-dl-actions {
    width: 100%;
    gap: 5px;
  }
  .sticky-pill {
    flex: 1 1 0;
    height: 40px;
    padding-inline: 8px;
    font-size: 0.74rem;
    gap: 5px;
  }
  .sticky-pill svg {
    width: 13px;
    height: 13px;
  }
}

@media (max-width: 360px) {
  .store-trio {
    grid-template-columns: 1fr;
  }
  .eco-grid {
    grid-template-columns: 1fr;
  }
}
