/* ==============================================================================
   تفکّر — «لاجورد و طلا / کاغذِ منقش» theme layer
   Drop-in override for the tafacur-deewan plugin. No PHP, no template edits.
   Version 1.0 · targets plugin v1.4.0 (ホームページは tafacur-deewan markup のまま)

   HOW TO INSTALL (pick one)
   ---------------------------------------------------------------------------
   A. Appearance → Customize → Additional CSS → paste this whole file → Publish.
      WordPress prints Additional CSS after plugin styles, so it wins.
   B. Append to a child theme's style.css, or load it with any
      "custom CSS" / "code snippets" plugin.

   WHAT IT DOES
   ---------------------------------------------------------------------------
   · Repoints the plugin's own tokens (--kaghaz, --siah, --sunehra, --surkh,
     --lakeer, --shadow, --radius, --font-najd). Most components follow
     automatically, because the plugin styles everything through those tokens.
   · On the homepage it runs as a controlled overlay on top of tafacur-deewan's
     current palette and markup: the canvas/grain, masthead gradient, shahrah
     chip, hero, waraq cards, rail cards, ginti row and پلگ ان chrome all keep
     their deewan character, and this layer only retunes the parts you asked to
     change (title scale, a few radii, link colour, focus, archive grid, pager,
     inner-template block tokens and reading surface).
   · On inner pages it repoints the block-theme token set (--wp--preset--color--*)
     at the same palette and then sets the reading surface by hand (section 12).

   PALETTES
   ---------------------------------------------------------------------------
   Day  (default, data-theme="roz")  = «کاغذِ منقش» warm laid paper
   Night (data-theme="shab")         = «لاجورد و طلا» lapis & gold

   The toggle keeps its meaning: روز = paper, شب = lapis. By default every
   template follows whatever data-theme the page carries — the homepage prints
   it, the inner templates do not, so they arrive in روز unless the companion
   script (tafacur-night-default.js) sets it. That script also makes شب the
   first-visit default and remembers an explicit روز choice.

   WHAT CSS CANNOT FIX (needs templates/content)
   ---------------------------------------------------------------------------
   · The 48 emoji are text nodes inside buttons and labels; no selector
     can remove them.
   · The running `[ad_1]` shortcode, `admin` bylines and English dates are
     post content.
   · A skip link needs one line of markup before <main>.
   · The 15 stacked homepage sections need template work; this only
     tightens their rhythm.
   ============================================================================ */

/* ---------------------------------------------------------------------------
   1. TOKENS — DAY: laid paper, rubric, one leaf-gold
   These names are the same ones tafacur-deewan defines, so most of its
   components follow without a separate selector for each one.
   --------------------------------------------------------------------------- */
:root{
  --kaghaz:#F6EFE1;
  --kaghaz-2:#EFE4CC;
  --kaghaz-3:#E7D9BC;
  --siah:#1F1810;
  --siah-halka:#5E5140;
  --surkh:#7A2B22;          /* rubric red — 8.36:1 on paper */
  --surkh-gehra:#63201A;
  --sunehra:#87621F;        /* leaf gold — 4.83:1, safe for text */
  --sunehra-halka:#B08A45;  /* ornament / fills (dark text only) */
  --neel:#87621F;           /* one accent only — teal folded into gold */
  --sabz:#87621F;           /* one accent only — green folded into gold */
  --lakeer:#D8C39B;
  --card:#FCF7EC;

  /* the four levers that do most of the work */
  --shadow:none;
  --radius:2px;
  --font-najd:var(--font-nast);
  --font-latin:var(--font-nast);   /* one family for the whole page */
}

/* ---------------------------------------------------------------------------
   2. TOKENS — NIGHT: lapis ground, ivory Nastaliq, gold ink
   --------------------------------------------------------------------------- */
body[data-theme="shab"]{
  --kaghaz:#0D1626;
  --kaghaz-2:#14203A;
  --kaghaz-3:#1A2745;
  --siah:#F2E9D6;
  --siah-halka:#BCB09A;
  --surkh:#7A3A34;          /* deep seal — only used as a fill */
  --surkh-gehra:#5E2A26;
  --sunehra:#CBA75F;        /* 7.96:1 on lapis */
  --sunehra-halka:#E3C98C;
  --neel:#CBA75F;
  --sabz:#CBA75F;
  --lakeer:#2B3B5C;
  --card:#14203A;
}

/* ---------------------------------------------------------------------------
   3. TYPE — Nastaliq everywhere, real reading sizes
   --------------------------------------------------------------------------- */
body{
  font-size:19px;
  line-height:2.15;
  -webkit-font-smoothing:antialiased;
}

/* the pencil face is now Nastaliq via --font-najd; restore weight + leading */
h1,h2,h3,h4,
.hero-sheershak,.shah-surkhi h3,.waraq h3,.gul-card h4,.rail-card b,
.tfk-related>h3,.mohar,.tab,.akhbar-head h2,.majlis-head h2{
  font-family:var(--font-nast);
  font-weight:700;
  line-height:1.9;
  letter-spacing:0;
}

.hero-sheershak{line-height:1.85;color:var(--siah)}
.majlis-head h2{font-size:clamp(1.6rem,2.4vw,2.15rem)}
.waraq h3{font-size:1.75rem;line-height:2}
.gul-card h4{font-size:1.5rem;line-height:2}
.majlis-head h2 small{font-size:1rem;line-height:1.9}

/* One family everywhere. Anything the plugin pointed at 'Inter' — tags, latin
   labels, numerals, button sub-labels — now renders in Nastaliq too. Latin words
   that Nastaliq has no glyph for fall back to the system serif automatically. */
.ginti-item b,.kitab-foot b,.kitab-btn b,.lafz-awaaz,
.unwan-tag,.huqooq,.craft,.ihuqooq,.talash-input-row input{
  font-family:var(--font-nast);
}
/* the ⌘K hint is a keycap, not prose — a mono face, but still 15px */
.dastak-search kbd{
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size:15px;
}

/* "most read" list metadata, and no synthetic italics on Nastaliq */
ol.top5 em{
  font-size:15px;
  font-style:normal;
}
/* last sub-15px holdouts: the عروض try row, the lead's tag row, the mast
   utility button, the medal stamp and the phone menu label */
.arooz-try button,.arooz-try span,.surkhi-tags span,
.btn-sada,.shamsa-medal,.shamsa-medal span,.shahrah-toggle,.shahrah-toggle-label{
  font-size:max(0.95rem,15px)
}

/* decorative glows: a glowing category dot and a hard offset "spine" shadow */
.cat-dot,.jild-row{box-shadow:none}

/* Nastaliq cannot truly italicise — the browser slants the whole ductus.
   Scoped to the homepage chrome only, so article emphasis keeps its italics. */
.hero-sheershak em,.majlis em,.waraq em,.gul-card em,.rail-card em,
.akhbar em,.daawat em,.top5 em{font-style:normal}

/* 15px floor on small Urdu labels — Nastaliq dies below this */
.ginti-item span,.mohar,.tab,.gul-tag,.ustad i,.qalam i,
.mast-side,.logo-tag,.wave-note,.arch-hint,.waraq-top,
.waraq-matn,.hero-bayan,.majlis-head p,.waraq-foot-sada,
.paindah a,.talash-input-row input,.tfk-muted,.tfk-story-meta{
  font-size:max(0.95rem,15px);
}

/* the tracked-out latin eyebrow is a web tell — let it be plain text */
.unwan-tag,.huqooq,.craft{
  letter-spacing:0;
  font-size:15px;
}

/* ---------------------------------------------------------------------------
   4. CHROME — ticker, masthead, search, nav
   Homes in on the tafacur-deewan chrome and only trims what you asked for:
   hairline instead of gradient/blur where it matters, 2px radii on the rail
   cards and the شاہراہ chip, flat buttons, and visible focus.
   The masthead gradient, the canvas/grain, the ☰ chip, the hero framing and
   the شاہراہ blur stay as deewan drew them — this is an overlay, not a rebuild.
   --------------------------------------------------------------------------- */

/* ticker: keep the deewan marquee, just set text colour and tread lightly on
   its border so it does not fight a darker masthead band if you ever switch. */
.sher-ticker{
  border-bottom:2px solid var(--sunehra);
}
body[data-theme="shab"] .sher-ticker{
  border-bottom:2px solid var(--sunehra);
}

/* masthead: leave the gradient and the ghost script alone (those are the look),
   but flatten the border and keep the hairline under the masthead so the band
   reads as one piece with the rest of the page. */
.masthead{
  border-bottom:2px solid var(--sunehra);
  box-shadow:none;
}
.masthead::before{content:none}
.masthead .mast-side,
.masthead .logo-tag{color:var(--siah-halka)}
.masthead .hijri-date,
.masthead .logo-rule{color:var(--sunehra)}
.masthead .logo-rule em{
  height:2px;
  width:110px;
  background:linear-gradient(90deg,transparent,var(--sunehra-halka),transparent);
}
.logo-callig{
  background:none;
  -webkit-background-clip:border-box;
  background-clip:border-box;
  color:var(--siah);
  -webkit-text-fill-color:currentColor;
  animation:none;
  filter:none;
}
.masthead .btn-sada{
  border-radius:2px;
  box-shadow:none;
}
.masthead .btn-sada:hover{background:rgba(0,0,0,.04);transform:none}
.masthead .kitab-btn{
  border-radius:2px;
  box-shadow:none;
}
.masthead .kitab-btn:hover{transform:none}
.masthead .dastak-search{background:var(--card)}

/* search */
.dastak-search{
  border-radius:2px;
  box-shadow:none;
}
.dastak-search:hover{border-color:var(--sunehra)}
.dastak-icon{
  border-radius:2px;
}
.dastak-search kbd{border-radius:2px;font-family:var(--font-latin)}
.kitab-btn{
  border-radius:2px;
  box-shadow:none;
}
.kitab-btn:hover{transform:none}

/* nav: keep the deewan chip; tighten it to 2px and one family, keep the blur. */
.shahrah .container{
  border-radius:2px;
  box-shadow:none;
  -webkit-backdrop-filter:none;
  backdrop-filter:none;
}
.shahrah .sh-item a{
  border-radius:2px;
  font-family:var(--font-nast);
  padding:6px 14px;
}
.shahrah .sh-item a:hover{background:rgba(185,134,31,.15);color:var(--siah)}
.shahrah .sh-item.active a{
  background:var(--surkh);
  color:#FFF3D6;
  font-weight:700;
}
.shahrah .sh-item.sh-kitab a{
  background:rgba(185,134,31,.18);
  border:1.5px solid var(--sunehra);
  color:var(--surkh);
  font-weight:700;
}
body[data-theme="shab"] .sh-item.sh-kitab a{color:var(--sunehra-halka)}

/* ---------------------------------------------------------------------------
   5. HERO — one invitation, no highlighter boxes
   --------------------------------------------------------------------------- */
.hero-sheershak em{
  background:none;
  border:0;
  padding:0;
  border-radius:0;
  color:inherit;
}
.hero-sheershak .surkh,
.hero-sheershak .neel,
body[data-theme="shab"] .hero-sheershak .surkh,
body[data-theme="shab"] .hero-sheershak .neel{
  background:none;
  border:0;
  color:inherit;
}
.kicker-gul{color:var(--sunehra)}
.hero-kicker{color:var(--sunehra)}
body[data-theme="shab"] .hero-kicker{color:var(--sunehra-halka)}
.hero-bayan{line-height:2.05}

/* buttons: flat, 2px, no lift — leave the deewan fills, drop the lift */
.btn-mehrab,.btn-kaghaz,.btn-bara,.arch-btns button,.btn-chhota{
  border-radius:2px;
  box-shadow:none;
}
.btn-mehrab:hover{background:var(--surkh-gehra);transform:none}
.btn-kaghaz:hover{background:rgba(122,43,34,.06)}
body[data-theme="shab"] .btn-kaghaz{border-color:var(--sunehra)}
.arch-btns button{border:1px solid var(--lakeer);background:transparent}
.arch-btns button:hover{border-color:var(--sunehra)}

/* one corner, everywhere: the plugin uses nine radii and 44 pills. A دیوان has
   ruled edges, so every chip, tag, panel, input and thumbnail goes to 2px.
   Circles (avatars, seals, the گردش disc) are left alone. */
.mohar,.tab,.unwan-tag,.breaking,.btn-sada,.kb-toggle,.toast,
.sh-item a,.surkhi-tags span,.arooz-try button,.ashaar-refresh,.tfk-fsize,
.shah-surkhi,.maeh-khana,.ustad,.qalam,.gul-card,.waraq,.rail-card,
.ashaar-card,.talash-item,.drop,.wave-line,.arooz-natija,.paindah-teh,
.jild,.waraq-arooz input,.waraq-arooz textarea,.shahrah .container,
.tfk-pagination .page-numbers,.hero-sheershak em{
  border-radius:2px;
}
.rail-card img,.akhbar img,.aks-grid img,.gul-card img{border-radius:2px}
/* the plugin prints border-radius:12px inline on card thumbnails; an inline
   style can only be beaten with !important, so it is scoped to those images */
.gul-card a > img{border-radius:2px!important}
/* the kitab "shelf" keeps its line, loses the drop-under shadow */
.waraq-kitab .jild-row{box-shadow:none;border-bottom-width:4px;border-bottom-color:var(--lakeer)}

/* the four stat boxes become one hairline row */
.hero-ginti{
  gap:0;
  border-top:1px solid var(--lakeer);
  margin-top:18px;
}
.ginti-item{
  background:transparent;
  border:0;
  border-inline-start:1px solid var(--lakeer);
  border-radius:0;
  box-shadow:none;
  padding:14px 12px 4px;
}
.ginti-item:first-child{border-inline-start:0;padding-inline-start:0}
.ginti-item:hover{transform:none}
.ginti-item b{color:var(--sunehra);font-weight:700;font-size:1.45rem}
body[data-theme="shab"] .ginti-item b{color:var(--sunehra)}

/* mehrab: one gold hairline, no dashed seam, no glow */
.mehrab-arch{
  border-radius:2px;
  box-shadow:none;
}
.mehrab-arch::before{
  border-radius:2px;
  inset:7px;
}
.arch-label{color:var(--sunehra)}
.arch-poet{color:var(--siah-halka)}
.arch-verse{line-height:2.3;font-weight:400}
.arch-shamsa{letter-spacing:2px;color:var(--sunehra)}
.wave-line{background:transparent;border:1px solid var(--lakeer);border-radius:2px}
.wave-line button{background:var(--sunehra);border-radius:2px}

/* dividers: single hairline with a lozenge, not a 2+1px double rule */
.dohri-lakeer{color:var(--sunehra);gap:12px}
.dohri-lakeer span{
  border-top:1px solid var(--lakeer);
  border-bottom:0;
  padding-top:0;
  opacity:1;
}

/* ---------------------------------------------------------------------------
   6. CARDS — the card kit comes off
   --------------------------------------------------------------------------- */
.waraq,.ustad,.qalam,.gul-card,.aks-grid figure,.talash-box{
  border:1px solid var(--lakeer);
  border-radius:2px;
  box-shadow:none;
}
.waraq:hover,.ustad:hover,.qalam:hover,.gul-card:hover,.ginti-item:hover{
  transform:none;
}
.waraq:hover{border-color:var(--sunehra)}
.waraq-khas{border-right-width:2px;border-right-color:var(--surkh)}
.waraq-lafz,.waraq-arooz,.waraq-dastan,.waraq-kitab{border-top-width:2px}
.waraq-lafz{border-top-color:var(--sunehra)}
.waraq-arooz{border-top-color:var(--neel)}
.waraq-dastan{border-top-color:var(--sabz)}
.waraq-kitab{
  border:1px solid var(--surkh);
  background:var(--card);
}
.waraq-foot,.gul-meta,.kitab-foot,.waraq-foot-sada{
  border-top:1px solid var(--lakeer);
}
.waraq-lafz blockquote{
  border-right:2px solid var(--sunehra);
  background:transparent;
  border-radius:0;
  padding:4px 14px;
}

/* tags: plain, bordered, not pills */
.mohar,.mohar-sunehri,.mohar-surkh,.mohar-neel,.mohar-sabz{
  border-radius:2px;
  background:transparent;
  border:1px solid currentColor;
  padding:0 9px;
  line-height:1.9;
}
.mohar-surkh{background:var(--surkh);color:#FFF3D6;border-color:var(--surkh)}
.tab{
  border-radius:2px;
  background:transparent;
  border:1px solid var(--lakeer);
  padding:3px 16px;
}
.tab.active{background:var(--surkh);border-color:var(--surkh)}
.unwan-tag,.talash-box{border-radius:2px}
.talash-box{
  border:1px solid var(--sunehra);
  box-shadow:0 24px 60px rgba(0,0,0,.28);
}
.talash-backdrop{-webkit-backdrop-filter:none;backdrop-filter:none;background:rgba(20,14,6,.55)}

/* letter medallions: true circles, hairline rings */
.ustad-harf,.qalam-harf{
  border-radius:50%;
  background:transparent;
  border-width:1px;
}
.harf-surkh,.harf-neel,.harf-sunehri,.harf-sabz,
.qalam-harf{background:transparent}
.ustad:hover{border-color:var(--sunehra)}

/* kicker / tag under section heads */
.daawat{
  background:var(--surkh);
  border:1px solid var(--sunehra);
  border-radius:2px;
  box-shadow:none;
}
.daawat h2{line-height:2}

/* ---------------------------------------------------------------------------
   7. READING SURFACE — paper fibre instead of polka dots
   Keep the deewan canvas/grain; this layer only adds the paper feel the
   homepage did not already ship. */
.kaghaz-grain{
  background-image:radial-gradient(rgba(135,98,31,.14) 1px,transparent 1px);
  background-size:3px 3px;
  opacity:.22;
}
body[data-theme="shab"] .kaghaz-grain{
  background-image:radial-gradient(rgba(242,233,214,.10) 1px,transparent 1px);
  opacity:.16;
}
.paindah{border-top-width:1px}
.paindah-logo{font-weight:700}
::selection{background:var(--sunehra-halka);color:#20180A}

/* ---------------------------------------------------------------------------
   8. ACCESSIBILITY — focus was being removed entirely
   --------------------------------------------------------------------------- */
body :is(a,button,input,select,textarea,summary,[tabindex]):focus-visible{
  outline:2px solid var(--sunehra);
  outline-offset:3px;
}
.waraq-arooz input:focus,
.talash-input-row input:focus{
  outline:2px solid var(--sunehra) !important;
  outline-offset:1px;
  border-color:var(--sunehra);
}
.waraq-arooz input{border-width:1px;border-radius:2px}
.arooz-natija,.arkaan span{border-radius:2px;background:transparent}
.tfk-fsize button{
  width:40px;height:40px;
  border-radius:50%;
  border-width:1px;
}
.shahrah-toggle:focus-visible{outline:2px solid var(--sunehra)}

/* ---------------------------------------------------------------------------
   9. MOTION — nothing loops but the ticker, and that stops on request
   --------------------------------------------------------------------------- */
@media (prefers-reduced-motion:reduce){
  .ticker-track{animation:none}
  .logo-callig{animation:none}
  .tabaq.ghoom{animation:none}
  *{transition:none!important;animation:none!important}
}
.sher-ticker:hover .ticker-track{animation-play-state:paused}

/* ---------------------------------------------------------------------------
   10. RAILS — compressed, not deleted
   The five category rails are generated by the plugin's REST calls, so CSS
   cannot merge them into one band. This halves their height without losing a
   single link: same 4-up grid, tighter cards and shorter images.
   --------------------------------------------------------------------------- */
.majlis.rail{margin:12px 0}
.majlis.rail .majlis-head{
  margin-bottom:10px;
  padding-bottom:6px;
  border-bottom:1px solid var(--lakeer);
}
.majlis.rail .rail-grid{gap:10px}
.majlis.rail .rail-card{
  border-radius:2px;
  box-shadow:none;
  border-width:1px;
  line-height:2;
}
.majlis.rail .rail-card:hover{transform:none;border-color:var(--sunehra)}
.majlis.rail .rail-card img{height:96px}
.majlis.rail .rail-card b{
  font-family:var(--font-nast);
  font-size:max(0.95rem,15px);
  line-height:1.95;
  padding:6px 10px 0;
}
.majlis.rail .rail-card span{font-size:15px;padding:0 10px 8px}

/* A false urgency badge on static, years-old posts. Scoped to the
   "most read" panel heading, where the plugin prints <small>LIVE</small>. */
.maeh-khana h4 small{display:none}

/* THREE ACTS, NOT EIGHT RAILS.
   The plugin renders a rail per category, one under the other. Above we keep
   only the first three — every rail after the third is an archive the same
   category already reaches from the مرکزی صفحہ navigation, so showing five in
   a column is repetition, not coverage. Nothing is deleted and every post is
   still reachable; the rules below simply stop painting the surplus bands.
   To show all rails again, delete this block.
   Measure affected: document.documentElement.scrollHeight */
.majlis.rail ~ .majlis.rail ~ .majlis.rail ~ .majlis.rail{display:none}

/* ---------------------------------------------------------------------------
   11. NARROW SCREENS
   --------------------------------------------------------------------------- */
@media (max-width:700px){
  body{font-size:18px}
  .hero-ginti{grid-template-columns:repeat(2,1fr)}
  .ginti-item:nth-child(3){border-inline-start:0;padding-inline-start:0}
  .ginti-item:nth-child(3),
  .ginti-item:nth-child(4){border-top:1px solid var(--lakeer)}
  .mehrab-arch{border-radius:150px 150px 2px 2px}
  .mehrab-arch::before{border-radius:142px 142px 2px 2px}
  .masthead{padding:10px 0 8px}
  .logo-callig{font-size:2rem}

  /* one rail card per row is what made the phone page 24 screens tall.
     Two up, thumbnail dropped, title still above the 15px floor. */
  .majlis.rail .rail-grid{grid-template-columns:repeat(2,1fr);gap:8px}
  .majlis.rail .rail-card img{display:none}
  .majlis.rail .rail-card b{font-size:15px;line-height:1.9;padding:8px 9px 0}
  .majlis.rail .rail-card span{padding:0 9px 8px}
  .majlis.rail .majlis-head h2{font-size:1.25rem}
}

/* ---------------------------------------------------------------------------
   12. INNER PAGES — single, page, archive, search, 404
   The homepage is plugin markup; every other template is Twenty Twenty-Four
   block markup, painted from a second token set (--wp--preset--color--*) and
   the block theme's own fonts. Section 1 cannot reach those, so this section
   repoints them at the same palette and then sets the parts block CSS leaves
   generic: the banded header, the reading surface, the rulings, the archive
   grid and the pager.

   The library app (page-id-5426) brings its own dark component stylesheet and
   interactive surfaces, so the reading-surface rules below exclude it on
   purpose. Its page chrome still takes the palette from the rules above.
   --------------------------------------------------------------------------- */

/* 12.1 The block presets — same palette, second token set.
   Declared on body, not :root: a custom property resolves its var() on the
   element where it is declared, so presets computed at :root would freeze the
   day values and the night palette would never reach the block templates. */
body{
  --wp--preset--color--base:var(--kaghaz);
  --wp--preset--color--base-2:var(--card);
  --wp--preset--color--contrast:var(--siah);
  --wp--preset--color--contrast-2:var(--siah-halka);
  --wp--preset--color--contrast-3:var(--lakeer);
  --wp--preset--color--accent:var(--sunehra-halka);
  --wp--preset--color--accent-2:var(--sunehra);
  --wp--preset--color--accent-3:var(--surkh);
  --wp--preset--color--accent-4:var(--sunehra);
  --wp--preset--color--accent-5:var(--siah-halka);

  /* the default core palette is still selectable in old posts. Fold the loud
     colours into the two inks this layer allows, as --neel/--sabz were folded
     on the homepage — no teal, no green, one red, one gold. */
  --wp--preset--color--vivid-red:var(--surkh);
  --wp--preset--color--pale-pink:var(--surkh);
  --wp--preset--color--luminous-vivid-orange:var(--sunehra);
  --wp--preset--color--luminous-vivid-amber:var(--sunehra);
  --wp--preset--color--vivid-purple:var(--sunehra);
  --wp--preset--color--vivid-cyan-blue:var(--sunehra);
  --wp--preset--color--pale-cyan-blue:var(--sunehra);
  --wp--preset--color--vivid-green-cyan:var(--sunehra);
  --wp--preset--color--light-green-cyan:var(--sunehra);
  --wp--preset--color--cyan-bluish-gray:var(--siah-halka);

  /* one face, as everywhere else */
  --wp--preset--font-family--body:var(--font-nast);
  --wp--preset--font-family--heading:var(--font-nast);

  /* The theme's size presets are printed with !important, so the preset is
     remapped here instead of fought: "small" was 0.9rem = 14.4px, which is
     under this layer's 15px floor and shows up on every meta row and colophon
     line. Remapping one variable fixes all of them at once. */
  --wp--preset--font-size--small:15px;
}

/* 12.2 Chrome — the block header is the only masthead these pages have */
header.wp-block-template-part > .wp-block-group{
  border-bottom:1px solid var(--lakeer);
}
/* the band carries has-base-background-color, and every block colour class is
   printed with !important; the masthead tone is what makes the header read as
   a band rather than as more page */
header.wp-block-template-part > .wp-block-group.has-background{
  background:var(--kaghaz-2)!important;
}
.wp-block-site-title{
  font-family:var(--font-nast);
  font-size:clamp(1.45rem,2.1vw,1.75rem);
  line-height:1.9;
  font-weight:700;
  letter-spacing:0;
  margin:0;
}
.wp-block-site-title a{color:var(--siah);text-decoration:none}
.wp-block-site-title a:hover{color:var(--sunehra)}
body[data-theme="shab"] .wp-block-site-title a:hover{color:var(--sunehra-halka)}

/* the tagline is a colophon line, not a subtitle */
.wp-block-site-tagline{font-size:15px;line-height:1.9;color:var(--siah-halka);margin:0}

/* nav: the same hairline gesture as شاہراہ, not a floating pill */
header .wp-block-navigation{font-size:max(1rem,16px);line-height:1.9}
header .wp-block-navigation a{
  color:var(--siah);
  text-decoration:none;
  padding:2px 0;
  border-bottom:2px solid transparent;
}
header .wp-block-navigation a:hover{color:var(--surkh);border-bottom-color:var(--sunehra)}
body[data-theme="shab"] header .wp-block-navigation a:hover{color:var(--sunehra-halka)}

/* the phone menu opens on paper, and its ☰ / ✕ gets an edge. Core paints the
   open overlay #fff on #000 with a five-class selector, so this matches that
   exactly instead of out-specifying it by half */
.wp-block-navigation:not(.has-background) .wp-block-navigation__responsive-container.is-menu-open:not(.disable-default-overlay){
  background-color:var(--kaghaz);
  color:var(--siah);
}
.wp-block-navigation__responsive-container-open,
.wp-block-navigation__responsive-container-close{
  color:var(--siah);
  border:1px solid var(--lakeer);
  border-radius:2px;
  padding:4px;
}

/* the skip link core prints here is the one the homepage lacks — make it felt */
.skip-link.screen-reader-text:focus{
  background:var(--kaghaz-2);
  color:var(--siah);
  border:1px solid var(--sunehra);
  border-radius:2px;
  font-size:16px;
  padding:10px 16px;
}

footer.wp-block-template-part{
  border-top:1px solid var(--lakeer);
  margin-top:48px;
}
/* both carry a preset size class, which is !important — hence !important here */
footer .wp-block-site-title{font-size:1.4rem!important}
/* About / Privacy are theme demo headings; at 15px gold they read as colophon
   labels instead of competing with the article title above them */
footer .wp-block-heading{
  font-family:var(--font-nast);
  font-size:15px!important;
  letter-spacing:0;
  color:var(--sunehra);
  line-height:2;
  margin:0 0 4px;
}
footer .wp-block-navigation{font-size:15px;line-height:1.9}
footer .wp-block-navigation a{
  color:var(--siah-halka);
  text-decoration:none;
  border:0;
  padding:1px 0;
}
footer .wp-block-navigation a:hover{color:var(--sunehra);border:0}

/* 12.3 Titles */
.wp-block-post-title,.wp-block-query-title,.wp-block-heading{
  font-family:var(--font-nast);
  color:var(--siah);
  letter-spacing:0;
  line-height:1.85;
}
.wp-block-post-title{
  font-size:clamp(1.9rem,3.2vw,2.45rem);
  font-weight:700;
}
.wp-block-post-title a{color:inherit;text-decoration:none}
.wp-block-post-title a:hover{color:var(--surkh)}
body[data-theme="shab"] .wp-block-post-title a:hover{color:var(--sunehra-halka)}

/* Core prints the archive title as `Category: <span>بلاگ</span>`. The English
   prefix becomes a quiet kicker instead of competing with the term at 52px.
   Nothing is hidden — screen readers still hear the whole label. */
.wp-block-query-title:has(> span){
  font-size:15px;
  line-height:2!important;   /* the template prints an inline line-height:1 */
  font-weight:400;
  color:var(--siah-halka);
}
.wp-block-query-title > span{
  display:block;
  font-size:clamp(2rem,3.2vw,2.6rem);
  line-height:1.75;
  font-weight:700;
  color:var(--siah);
}

/* 12.4 The meta row: date · by · author · in · category, one colophon line */
.wp-block-post-date,.wp-block-post-author-name,.wp-block-post-terms{
  font-size:15px;
  line-height:2;
  color:var(--siah-halka);
}
.wp-block-post-date a,.wp-block-post-author-name a,.wp-block-post-terms a{
  color:var(--siah-halka);
  text-decoration:none;
}
.wp-block-post-date a:hover,.wp-block-post-author-name a:hover,.wp-block-post-terms a:hover{
  color:var(--sunehra);
  text-decoration:underline;
  text-underline-offset:.2em;
}
/* the em dash and the English "by" are paragraphs beside the date; without
   this they render at 19px next to a 15px date */
.wp-block-post-date ~ .wp-block-paragraph{font-size:15px;line-height:2;margin:0}
/* the size comes from the remapped preset above; leading is set here because
   the theme's 1.6 clips Nastaliq's descenders at 15px */
.has-small-font-size{line-height:2}

/* 12.5 Reading surface. The library app is excluded: it is an application,
   not prose, and it ships its own dark stylesheet. */
body:not(.page-id-5426) .wp-block-post-content{
  font-size:19px;
  line-height:2.15;
}
body:not(.page-id-5426) .wp-block-post-content p{margin:0 0 1.1em}
body:not(.page-id-5426) .wp-block-post-content > :first-child{margin-top:0}
body:not(.page-id-5426) .wp-block-post-content a{
  color:var(--sunehra);
  text-decoration:underline;
  text-decoration-thickness:1px;
  text-underline-offset:.24em;
  text-decoration-color:color-mix(in srgb,currentColor 45%,transparent);
}
body:not(.page-id-5426) .wp-block-post-content a:hover{
  color:var(--siah);
  text-decoration-color:currentColor;
}

/* subheads inside a post follow the same scale as the title */
body:not(.page-id-5426) .wp-block-post-content h2{font-size:1.55rem;line-height:1.95;margin:1.8em 0 .7em}
body:not(.page-id-5426) .wp-block-post-content h3{font-size:1.32rem;line-height:1.95;margin:1.6em 0 .6em}

body:not(.page-id-5426) .wp-block-post-content figure{margin:2rem 0}
body:not(.page-id-5426) .wp-block-post-content img,
body:not(.page-id-5426) .wp-block-post-featured-image img,
body:not(.page-id-5426) .wp-block-image img{
  border-radius:2px;
  max-width:100%;   /* imported posts carry 1200px sources in a 620px column */
  height:auto;
}
body:not(.page-id-5426) figcaption,
body:not(.page-id-5426) .wp-element-caption{
  font-family:var(--font-nast);
  font-size:15px;
  line-height:1.95;
  color:var(--siah-halka);
  text-align:center;
  margin-top:10px;
}

/* a quotation is a ruled passage, not a tinted card */
body:not(.page-id-5426) .wp-block-quote{
  border:0;
  border-inline-start:2px solid var(--sunehra);
  margin:1.9rem 0;
  padding:0 1.4rem;
  font-size:1.02em;
  line-height:2.2;
  color:var(--siah);
}
body:not(.page-id-5426) .wp-block-quote cite{
  display:block;
  font-size:15px;
  font-style:normal;
  color:var(--siah-halka);
  margin-top:.7rem;
}
body:not(.page-id-5426) .wp-block-post-content ul,
body:not(.page-id-5426) .wp-block-post-content ol{
  padding-inline-start:1.5em;
  margin:0 0 1.1em;
}
body:not(.page-id-5426) .wp-block-post-content li{margin-bottom:.35em}
body:not(.page-id-5426) .wp-block-post-content li::marker{color:var(--sunehra)}

body:not(.page-id-5426) .wp-block-post-content table{
  border-collapse:collapse;
  width:100%;
  font-size:17px;
  margin:0 0 1.4em;
}
body:not(.page-id-5426) .wp-block-post-content th,
body:not(.page-id-5426) .wp-block-post-content td{
  border:1px solid var(--lakeer);
  padding:8px 12px;
  text-align:start;
}
body:not(.page-id-5426) .wp-block-post-content th{
  background:var(--kaghaz-2);
  font-weight:700;
}

/* code is the one place a mono face belongs (see the ⌘K keycap, section 3) */
body:not(.page-id-5426) .wp-block-post-content code,
body:not(.page-id-5426) .wp-block-post-content kbd{
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size:15px;
  background:var(--kaghaz-2);
  border:1px solid var(--lakeer);
  border-radius:2px;
  padding:1px 5px;
}
body:not(.page-id-5426) .wp-block-post-content pre{
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size:15px;
  line-height:1.7;
  background:var(--kaghaz-2);
  border:1px solid var(--lakeer);
  border-radius:2px;
  padding:14px 16px;
  overflow:auto;
  direction:ltr;
  text-align:left;
}

/* the template's separator arrives as a 2px grey bar on a background class */
.wp-block-separator{
  border:0;
  border-top:1px solid var(--lakeer);
  background:none;
  color:var(--lakeer);
  height:0;
  margin-block:2rem;
}
.wp-block-separator.is-style-dots{border-top:0}
.wp-block-separator.is-style-dots:before{color:var(--sunehra)}

/* 12.6 Post-to-post navigation: two ruled columns, English labels demoted */
.wp-block-post-navigation-link{font-size:17px;line-height:2}
.wp-block-post-navigation-link a{color:var(--siah);text-decoration:none}
.wp-block-post-navigation-link a:hover{color:var(--sunehra)}
.post-navigation-link__label{
  display:block;
  font-size:15px;
  line-height:1.9;
  color:var(--siah-halka);
}
.wp-block-post-navigation-link__arrow-previous,
.wp-block-post-navigation-link__arrow-next{color:var(--sunehra)}

/* 12.7 Archive grid: ruled columns, not a card wall */
.wp-block-post-template.is-layout-grid{gap:0 40px}
.wp-block-post-template > li{
  border-top:1px solid var(--lakeer);
  padding-top:20px;
  margin-bottom:28px;
}
/* card titles carry has-large-font-size (1.85rem, !important) — at 30px in a
   three-column grid they take three lines and the page grows a screen */
.wp-block-post-template .wp-block-post-title{
  font-size:clamp(1.3rem,1.8vw,1.55rem)!important;
  line-height:1.9;
}
/* the excerpt is the one "small" that should read as prose, not as a label;
   its preset class is !important, so the extra pixel needs one too */
.wp-block-post-excerpt__excerpt{
  font-size:16px!important;
  line-height:2;
  color:var(--siah-halka);
}
.wp-block-post-template img{border-radius:2px}
.wp-block-post-featured-image{margin-bottom:12px}

.wp-block-query-pagination{
  border-top:1px solid var(--lakeer);
  margin-top:20px;
  padding-top:18px;
  font-size:16px;
}
.wp-block-query-pagination a,
.wp-block-query-pagination .page-numbers{
  color:var(--siah);
  text-decoration:none;
  padding:3px 10px;
  border:1px solid transparent;
  border-radius:2px;
}
.wp-block-query-pagination a:hover{border-color:var(--lakeer);color:var(--sunehra)}
.wp-block-query-pagination-previous-arrow,
.wp-block-query-pagination-next-arrow{color:var(--sunehra)}
.wp-block-query-pagination .page-numbers.current{
  color:var(--surkh);
  border-color:var(--sunehra);
  font-weight:700;
}
body[data-theme="shab"] .wp-block-query-pagination .page-numbers.current{color:var(--sunehra-halka)}

/* 12.8 Narrow screens */
@media (max-width:700px){
  header.wp-block-template-part > .wp-block-group{padding-block:14px}
  .wp-block-site-title{font-size:1.5rem}
  .wp-block-post-title{font-size:1.75rem}
  .wp-block-post-template.is-layout-grid{grid-template-columns:1fr;gap:0}
  .wp-block-post-template > li{margin-bottom:20px;padding-top:16px}
  body:not(.page-id-5426) .wp-block-post-content{font-size:18px;line-height:2.1}
  .wp-block-post-navigation-link{font-size:16px}
  footer.wp-block-template-part{margin-top:32px}
}
