/* Kitabsaz — the website's own pages (the welcome page, a shared book or card, privacy, terms,
   not found): the app's colours and faces (the tokens are copied from bol.css, keep them in step),
   on pages that scroll like documents rather than an app shell. */
@font-face { font-family: Nastaliq; src: url('./fonts/NotoNastaliqUrdu.ttf') format('truetype'); font-weight: 400 700; font-display: swap; }
@font-face { font-family: Gulzar; src: url('./fonts/Gulzar-Regular.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: Naskh; src: url('./fonts/NotoNaskhArabic.ttf') format('truetype'); font-weight: 400 700; font-display: swap; }

/* ——— tokens ——— */
:root {
  color-scheme: light;
  --brand: #123f37; --brand-2: #1b5a4b; --brand-3: #0b2a24; --brand-ink: #135044;
  --brand-soft: #e6f0eb; --brand-line: #bcd6cb;
  --gold: #c39a55; --gold-2: #e2c27a; --gold-soft: #f7eedb; --gold-ink: #7a5a22; --gold-line: #e8d3a4;
  --bg: #f3f1ec; --surface: #ffffff; --surface-2: #f8f6f1; --surface-3: #efece4;
  --paper: #fffdf8; --paper-line: #efe8d9; --block-focus: #fbf5e9; --quote-bg: #f7f1e3;
  --field: #ffffff; --sheet: #fbfaf7;
  --ink: #1b2522; --ink-2: #48544f; --ink-3: #7b8580; --ink-on-dark: #f3f6f2;
  --line: #e4dfd3; --line-2: #d3ccbc;
  --danger: #b2433a; --danger-soft: #fcefed; --danger-line: #efcac4;
  --ok: #2b7a4e; --ok-soft: #e9f5ee; --ok-line: #c3e2cf;
  --warn: #946414; --warn-soft: #fcf4e3; --warn-line: #ecd5a6;
  --rec: #d1463a; --rec-2: #a5322a;
  --hero-1: #17493d; --hero-2: #0c2c25; --hero-glow: #23705d;
  --toast: rgb(24 34 31 / .95);
  --focus-ring: rgb(195 154 85 / .32);
  --shadow-1: 0 1px 2px rgb(16 40 34 / .06), 0 1px 1px rgb(16 40 34 / .03);
  --shadow-2: 0 1px 2px rgb(16 40 34 / .05), 0 10px 26px -10px rgb(16 40 34 / .2);
  --shadow-3: 0 2px 6px rgb(16 40 34 / .06), 0 24px 48px -16px rgb(16 40 34 / .32);
  --shadow-dock: 0 -1px 0 rgb(16 40 34 / .05), 0 -14px 34px -12px rgb(16 40 34 / .22);
  --urdu: Nastaliq, 'Noto Nastaliq Urdu', serif;
  --ui: Naskh, 'Noto Naskh Arabic', system-ui, 'Segoe UI', sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --safe-bottom: env(safe-area-inset-bottom, 0px); --safe-top: env(safe-area-inset-top, 0px);
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --brand: #1d6a57; --brand-2: #258069; --brand-3: #0d2924; --brand-ink: #86d3b8;
  --brand-soft: #15302a; --brand-line: #2a5248;
  --gold: #d3ae6b; --gold-2: #e6c784; --gold-soft: #2b2518; --gold-ink: #e3c486; --gold-line: #574729;
  --bg: #0c1311; --surface: #141c19; --surface-2: #19231f; --surface-3: #212c28;
  --paper: #151d1a; --paper-line: #25302b; --block-focus: #1c2622; --quote-bg: #1d2620;
  --field: #0f1614; --sheet: #121a17;
  --ink: #ebe6da; --ink-2: #bcb7ab; --ink-3: #8a8a81; --ink-on-dark: #f3f6f2;
  --line: #26312d; --line-2: #35423c;
  --danger: #ef8b80; --danger-soft: #2b1a18; --danger-line: #57302b;
  --ok: #82d0a0; --ok-soft: #13261b; --ok-line: #24452f;
  --warn: #e4b968; --warn-soft: #282113; --warn-line: #4c3e1f;
  --hero-1: #113a31; --hero-2: #081a16; --hero-glow: #1c5c4c;
  --toast: rgb(38 50 46 / .96);
  --focus-ring: rgb(211 174 107 / .3);
  --shadow-1: 0 1px 2px rgb(0 0 0 / .35);
  --shadow-2: 0 1px 2px rgb(0 0 0 / .3), 0 12px 28px -12px rgb(0 0 0 / .6);
  --shadow-3: 0 2px 6px rgb(0 0 0 / .3), 0 26px 52px -16px rgb(0 0 0 / .75);
  --shadow-dock: 0 -1px 0 rgb(255 255 255 / .04), 0 -16px 36px -12px rgb(0 0 0 / .65);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --brand: #1d6a57; --brand-2: #258069; --brand-3: #0d2924; --brand-ink: #86d3b8;
    --brand-soft: #15302a; --brand-line: #2a5248;
    --gold: #d3ae6b; --gold-2: #e6c784; --gold-soft: #2b2518; --gold-ink: #e3c486; --gold-line: #574729;
    --bg: #0c1311; --surface: #141c19; --surface-2: #19231f; --surface-3: #212c28;
    --paper: #151d1a; --paper-line: #25302b; --block-focus: #1c2622; --quote-bg: #1d2620;
    --field: #0f1614; --sheet: #121a17;
    --ink: #ebe6da; --ink-2: #bcb7ab; --ink-3: #8a8a81; --ink-on-dark: #f3f6f2;
    --line: #26312d; --line-2: #35423c;
    --danger: #ef8b80; --danger-soft: #2b1a18; --danger-line: #57302b;
    --ok: #82d0a0; --ok-soft: #13261b; --ok-line: #24452f;
    --warn: #e4b968; --warn-soft: #282113; --warn-line: #4c3e1f;
    --hero-1: #113a31; --hero-2: #081a16; --hero-glow: #1c5c4c;
    --toast: rgb(38 50 46 / .96);
    --focus-ring: rgb(211 174 107 / .3);
    --shadow-1: 0 1px 2px rgb(0 0 0 / .35);
    --shadow-2: 0 1px 2px rgb(0 0 0 / .3), 0 12px 28px -12px rgb(0 0 0 / .6);
    --shadow-3: 0 2px 6px rgb(0 0 0 / .3), 0 26px 52px -16px rgb(0 0 0 / .75);
    --shadow-dock: 0 -1px 0 rgb(255 255 255 / .04), 0 -16px 36px -12px rgb(0 0 0 / .65);
  }
}

/* ——— base ——— */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--ui); font-size: 16px; line-height: 1.75; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip; }
a { color: var(--brand-ink); }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2.5px solid var(--gold); outline-offset: 2px; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.i { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ur { font-family: var(--urdu); font-weight: 400; }
.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.fine { font-size: 13.5px; color: var(--ink-3); }
@keyframes rise { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes float { 50% { transform: translateY(-8px); } }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 22px; border-radius: 16px; border: 1.5px solid var(--line);
  background: var(--surface); color: var(--ink); font: inherit; font-size: 16px; font-weight: 700; text-decoration: none; cursor: pointer; transition: transform .12s var(--ease), filter .2s, background .2s, border-color .2s; }
.button:hover { border-color: var(--line-2); }
.button:active { transform: scale(.98); }
.button .i { width: 20px; height: 20px; }
.button.primary { background: linear-gradient(180deg, var(--brand-2), var(--brand)); border-color: transparent; color: #fff; box-shadow: inset 0 1px 0 rgb(255 255 255 / .14), 0 10px 22px -12px rgb(12 43 37 / .9); }
.button.gold { background: linear-gradient(160deg, #f1d79e, #c39a55 75%); border-color: transparent; color: #2b2210; box-shadow: 0 12px 26px -12px rgb(122 90 34 / .9), inset 0 1px 0 rgb(255 255 255 / .4); }
.button.gold:hover, .button.primary:hover { filter: brightness(1.05); }
.button.ghost { background: rgb(255 255 255 / .08); border-color: rgb(255 255 255 / .22); color: #f3eedf; }
.button.small { min-height: 40px; padding: 0 16px; font-size: 14px; border-radius: 999px; }

/* ——— header ——— */
.site-header { position: sticky; top: 0; z-index: 20; backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  background: color-mix(in srgb, var(--hero-2) 82%, transparent); border-bottom: 1px solid rgb(226 194 122 / .14); color: var(--ink-on-dark); }
.site-header .wrap { display: flex; align-items: center; gap: 18px; height: 68px; }
.site-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.site-brand img { width: 40px; height: 40px; border-radius: 12px; box-shadow: 0 6px 16px -6px rgb(0 0 0 / .6); }
.site-brand .ur { font-size: 26px; line-height: 1.6; background: linear-gradient(180deg, #f6e2b4 15%, #d3aa5f 85%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; padding: 6px 0; }
.site-nav { display: flex; gap: 4px; margin-inline-start: auto; }
.site-nav a { color: rgb(236 230 214 / .86); text-decoration: none; font-size: 15px; font-weight: 600; padding: 8px 12px; border-radius: 10px; }
.site-nav a:hover { background: rgb(255 255 255 / .08); color: #fff; }
@media (max-width: 760px) { .site-nav { display: none; } .site-header .button { margin-inline-start: auto; } }

/* ——— hero ——— */
.hero { position: relative; overflow: hidden; color: var(--ink-on-dark); padding: 64px 0 96px;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cg fill='none' stroke='%23E2C27A' stroke-opacity='.1' stroke-width='1'%3E%3Crect x='18' y='18' width='28' height='28'/%3E%3Crect x='18' y='18' width='28' height='28' transform='rotate(45 32 32)'/%3E%3Ccircle cx='32' cy='32' r='6'/%3E%3Cpath d='M0 32h8M56 32h8M32 0v8M32 56v8'/%3E%3C/g%3E%3C/svg%3E") center top / 64px,
    radial-gradient(80% 90% at 85% 0%, var(--hero-glow) 0%, transparent 60%),
    radial-gradient(60% 70% at 0% 100%, rgb(195 154 85 / .16), transparent 70%),
    linear-gradient(170deg, var(--hero-1), var(--hero-2)); }
.hero::after { content: ''; position: absolute; inset: auto 0 -1px; height: 90px; background: linear-gradient(transparent, var(--bg)); pointer-events: none; }
.hero .wrap { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; background: rgb(255 255 255 / .08); border: 1px solid rgb(226 194 122 / .3); color: #f1d79e; font-size: 14px; font-weight: 600; }
.hero h1 { font-family: var(--urdu); font-weight: 400; font-size: clamp(34px, 4.6vw, 54px); line-height: 1.75; margin: 18px 0 8px; color: #fbf3df; text-wrap: balance; }
.hero h1 em { font-style: normal; background: linear-gradient(180deg, #f6e2b4 15%, #d3aa5f 85%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; padding: 8px 0; }
.hero-lead { font-size: clamp(16px, 1.9vw, 19px); line-height: 1.95; color: rgb(226 236 230 / .88); max-width: 560px; margin: 0 0 26px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-note { margin-top: 16px; font-size: 13.5px; color: rgb(214 230 222 / .7); display: flex; align-items: center; gap: 8px; }
.hero-art { position: relative; min-height: 480px; }
.device { position: absolute; border-radius: 34px; padding: 10px; background: #0b1714; box-shadow: 0 40px 80px -30px rgb(0 0 0 / .75), inset 0 0 0 1.5px rgb(255 255 255 / .1); }
.device img { border-radius: 26px; width: 100%; height: 100%; object-fit: cover; object-position: top; background: var(--bg); }
.device.phone-a { width: 250px; height: 520px; top: 0; inset-inline-end: 12%; animation: float 7s ease-in-out infinite; }
.device.phone-b { width: 220px; height: 460px; top: 70px; inset-inline-end: 52%; transform: rotate(-4deg); opacity: .97; }
.floating-card { position: absolute; inset-inline-start: 4%; bottom: -10px; width: 200px; border-radius: 16px; overflow: hidden; box-shadow: 0 30px 60px -24px rgb(0 0 0 / .7); transform: rotate(5deg); }
@media (max-width: 900px) {
  .hero { padding: 40px 0 70px; }
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-art { min-height: 420px; margin-top: 10px; }
  .device.phone-a { inset-inline-end: 6%; width: 210px; height: 440px; }
  .device.phone-b { inset-inline-end: 46%; width: 190px; height: 400px; }
  .floating-card { width: 160px; }
}

/* ——— sections ——— */
.section { padding: 64px 0; }
.section.tint { background: linear-gradient(180deg, var(--surface-2), var(--bg)); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 36px; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .4px; color: var(--gold-ink); background: var(--gold-soft); border: 1px solid var(--gold-line); padding: 3px 12px; border-radius: 999px; }
.section-head h2 { font-family: var(--urdu); font-weight: 400; font-size: clamp(28px, 3.6vw, 40px); line-height: 1.85; margin: 10px 0 4px; }
.section-head p { color: var(--ink-2); font-size: 17px; line-height: 1.95; margin: 0; }
.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.feature { position: relative; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 22px; box-shadow: var(--shadow-1); transition: transform .2s var(--ease), box-shadow .2s; }
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
.feature-icon { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 12px; color: #f1d79e; background: linear-gradient(150deg, var(--brand-2), var(--brand-3)); box-shadow: 0 12px 20px -12px rgb(12 43 37 / .9); }
.feature:nth-child(3n+2) .feature-icon { color: #fff9ea; background: linear-gradient(150deg, #d7b06a, #9b7534 75%); }
.feature-icon .i { width: 26px; height: 26px; }
.feature h3 { font-family: var(--urdu); font-weight: 400; font-size: 22px; line-height: 1.9; margin: 0 0 2px; }
.feature p { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.9; }

.template-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 18px 14px; align-items: end; }
@media (min-width: 900px) { .template-strip { grid-template-columns: repeat(4, 1fr); gap: 26px 22px; } }
.template-tile { display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: inherit; }
.template-thumb { position: relative; overflow: hidden; border-radius: 14px; background: var(--surface-3); box-shadow: 0 18px 34px -18px rgb(16 40 34 / .55), 0 0 0 1px var(--line); transition: transform .25s var(--ease); }
.template-tile:hover .template-thumb { transform: translateY(-4px) rotate(-.5deg); }
.template-thumb .artboard-host { transform-origin: top right; position: absolute; top: 0; right: 0; }
.template-tile strong { font-family: var(--urdu); font-weight: 400; font-size: 17px; line-height: 1.8; text-align: center; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; counter-reset: step; }
.step { position: relative; padding: 22px 22px 22px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.step::before { counter-increment: step; content: counter(step, arabic-indic); position: absolute; top: 16px; inset-inline-end: 18px; font-family: var(--urdu); font-size: 44px; line-height: 1; color: var(--gold-line); }
.step h3 { font-family: var(--urdu); font-weight: 400; font-size: 21px; line-height: 1.9; margin: 0 0 4px; }
.step p { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.9; }

.layout-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.mini-book { aspect-ratio: 3 / 4.1; border-radius: 12px 5px 5px 12px; padding: 14px 12px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: #f6e7c1;
  background: radial-gradient(130% 90% at 40% 0%, rgb(255 255 255 / .1), transparent 55%), linear-gradient(90deg, rgb(0 0 0 / .05), rgb(255 255 255 / .05) 70%, rgb(0 0 0 / .22)), var(--cover, #123f37);
  box-shadow: 0 16px 28px -14px rgb(16 40 34 / .7); position: relative; }
.mini-book::after { content: ''; position: absolute; inset: 10px 18px 10px 10px; border: 1px solid rgb(226 194 122 / .6); border-radius: 6px; }
.mini-book strong { font-family: var(--urdu); font-weight: 400; font-size: 19px; line-height: 1.8; color: #f4dfa9; position: relative; }
.mini-book small { font-size: 12px; opacity: .8; position: relative; }

.faq { max-width: 820px; margin: 0 auto; display: grid; gap: 10px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 0 18px; }
.faq summary { cursor: pointer; list-style: none; padding: 16px 0; font-weight: 700; font-size: 16.5px; display: flex; align-items: center; gap: 10px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; margin-inline-start: auto; font-size: 22px; color: var(--gold-ink); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 16px; color: var(--ink-2); line-height: 1.95; }

.cta-band { position: relative; overflow: hidden; border-radius: 30px; padding: 44px 28px; text-align: center; color: var(--ink-on-dark);
  background: radial-gradient(70% 90% at 90% 0%, var(--hero-glow), transparent 60%), linear-gradient(160deg, var(--hero-1), var(--hero-2)); box-shadow: var(--shadow-3); }
.cta-band h2 { font-family: var(--urdu); font-weight: 400; font-size: clamp(26px, 3.4vw, 38px); line-height: 1.85; margin: 0 0 6px; color: #fbf3df; }
.cta-band p { margin: 0 0 22px; color: rgb(226 236 230 / .85); }

.site-footer { padding: 36px 0 48px; color: var(--ink-3); font-size: 14px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 24px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.site-footer a { color: var(--ink-2); text-decoration: none; font-weight: 600; }
.site-footer a:hover { color: var(--brand-ink); }
/* the maker's credit moves to a line of its own as one piece when the footer is narrow */
.site-footer .credit { display: inline-block; }
.english { direction: ltr; text-align: left; font-family: system-ui, 'Segoe UI', sans-serif; }

/* ——— documents: privacy, terms ——— */
.doc-hero { padding: 48px 0 70px; }
.doc-hero h1 { font-size: clamp(30px, 4.4vw, 46px); margin: 10px 0 0; }
.prose { max-width: 800px; margin: -40px auto 40px; position: relative; z-index: 1; background: var(--surface); border: 1px solid var(--line); border-radius: 26px; padding: 30px clamp(20px, 4vw, 44px); box-shadow: var(--shadow-2); }
.prose h2 { font-family: var(--urdu); font-weight: 400; font-size: 25px; line-height: 1.9; margin: 26px 0 6px; color: var(--brand-ink); }
.prose p, .prose li { font-size: 16.5px; line-height: 2; color: var(--ink); }
.prose ul { padding-inline-start: 22px; }
.prose .english { border-top: 1px solid var(--line); margin-top: 28px; padding-top: 18px; color: var(--ink-2); font-size: 14.5px; }
.prose .english h2 { font-family: system-ui, sans-serif; font-weight: 700; font-size: 18px; color: var(--ink); }
.prose .english p, .prose .english li { font-size: 14.5px; line-height: 1.7; color: var(--ink-2); }

/* ——— a shared book or card (read.html) ——— */
.reader-top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.reader-top .wrap { display: flex; align-items: center; gap: 10px; height: 60px; max-width: 900px; }
.reader-top .site-brand .ur { font-size: 22px; }
.reader-top .site-brand img { width: 34px; height: 34px; border-radius: 10px; }
.reader-tools { margin-inline-start: auto; display: flex; gap: 6px; align-items: center; }
.tool { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); display: grid; place-items: center; cursor: pointer; font: inherit; font-weight: 700; }
.tool:hover { border-color: var(--line-2); color: var(--ink); }
.reader { max-width: 820px; margin: 0 auto; padding: 24px 18px 60px; }
.reader-cover { position: relative; text-align: center; padding: 48px 24px 40px; margin: 8px 0 26px; border-radius: 26px; color: #f6e7c1; overflow: hidden;
  background: radial-gradient(130% 90% at 40% 0%, rgb(255 255 255 / .1), transparent 55%), var(--cover, #123f37); box-shadow: var(--shadow-3); }
.reader-cover::before { content: ''; position: absolute; inset: 12px; border: 1.2px solid rgb(226 194 122 / .6); border-radius: 18px; pointer-events: none; }
.reader-cover h1 { font-family: var(--urdu); font-weight: 400; font-size: clamp(30px, 6vw, 46px); line-height: 1.9; margin: 0; color: #f4dfa9; }
.reader-cover p { margin: 4px 0 0; font-family: var(--urdu); font-size: 18px; line-height: 2; color: rgb(243 232 205 / .85); }
.reader-cover .orn { color: #e2c27a; font-size: 22px; letter-spacing: 8px; }
.reader-meta { text-align: center; color: var(--ink-3); font-size: 14px; margin: -10px 0 22px; }
.reader-toc { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 12px 20px; margin: 0 0 26px; }
.reader-toc summary { cursor: pointer; font-weight: 700; padding: 6px 0; }
.reader-toc ol { margin: 6px 0 4px; padding-inline-start: 26px; }
.reader-toc.urdu ol { list-style-type: arabic-indic; }
.reader-toc a { font-family: var(--urdu); font-size: 17px; line-height: 2.1; text-decoration: none; color: var(--ink); }
.reader-body { --size: 21px; background: var(--paper); border: 1px solid var(--paper-line); border-radius: 22px; padding: clamp(18px, 4vw, 44px); box-shadow: var(--shadow-1); }
.reader-body.script-urdu { font-family: var(--urdu); font-size: var(--size); line-height: 2.25; }
.reader-body.script-other { font-family: system-ui, 'Noto Sans', sans-serif; font-size: calc(var(--size) * .82); line-height: 1.8; }
.r-title { font-weight: 400; font-size: 1.7em; text-align: center; line-height: 1.9; margin: 1.2em 0 .4em; color: var(--brand-ink); }
.r-subtitle { text-align: center; color: var(--ink-2); margin: 0 0 1em; }
.r-heading { font-weight: 400; font-size: 1.35em; text-align: center; line-height: 1.9; margin: 1.4em 0 .5em; color: var(--brand-ink); }
.r-heading::before { content: '❁'; display: block; font-family: serif; font-size: .6em; color: var(--gold); letter-spacing: 6px; }
.r-para { text-align: justify; margin: 0 0 .7em; }
.r-sher { margin: 0 0 1.1em; text-align: center; }
.r-sher span, .r-band span { display: block; }
.r-band { margin: 0 0 1.2em; text-align: center; }
.r-quote { margin: 1em 0; padding: .7em 1em; background: var(--quote-bg); border-radius: 16px; text-align: center; }
.r-quote .arabic { font-family: Naskh, serif; font-size: 1.15em; line-height: 2; direction: rtl; }
.r-quote .translation { font-size: .9em; color: var(--ink-2); margin: .2em 0 0; }
.r-note { font-size: .82em; color: var(--ink-2); border-top: 1px solid var(--line); padding-top: .4em; margin: .8em 0; }
.r-break { border: 0; text-align: center; margin: 1.4em 0; }
.r-break::after { content: '❖ ❖ ❖'; color: var(--gold); font-family: serif; letter-spacing: 6px; }
sup.fn { font-size: .6em; line-height: 0; }
.reader-cta { margin: 30px 0 0; text-align: center; padding: 26px 20px; border-radius: 24px; background: var(--surface); border: 1px solid var(--line); }
.reader-cta strong { display: block; font-family: var(--urdu); font-weight: 400; font-size: 22px; line-height: 2; }
.reader-cta p { margin: 0 0 14px; color: var(--ink-2); }
.design-view { display: grid; place-items: center; padding: 10px 0 0; }
.design-stage { position: relative; border-radius: 10px; overflow: hidden; box-shadow: 0 30px 60px -24px rgb(16 40 34 / .6), 0 0 0 1px var(--line); background: #fff; }
.design-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 20px 0 0; }
.reader-state { text-align: center; padding: 80px 20px; color: var(--ink-2); font-family: var(--urdu); font-size: 20px; line-height: 2.2; }
@media print {
  .reader-top, .reader-cta, .reader-toc, .reader-meta { display: none !important; }
  .reader-body { border: 0; box-shadow: none; padding: 0; }
  body { background: #fff; }
}
