/* Hazro Chhach app v3 — navy / gold, Urdu-first RTL, light + dark */
@font-face { font-family: "HCT Nastaliq"; src: url("../fonts/NotoNastaliqUrdu.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "HCT Naskh"; src: url("../fonts/NotoNaskhArabic.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "HCT Latin"; src: url("../fonts/Montserrat.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --navy: #081b40; --navy-deep: #040e24; --blue: #164ea0; --blue-2: #1d5bb8; --gold: #e8b632; --gold-light: #fad66e;
  --red: #c62828; --green: #0f7a43;
  --bg: #eef2f8; --card: #fff; --card2: #f3f6fb; --ink: #0d1a33; --ink2: #2a3a57; --muted: #56657f; --line: #e1e7f0;
  --head-1: #081b40; --head-2: #0c2657; --title: #081b40; --link: #164ea0;
  --shadow: 0 1px 2px rgba(8,27,64,.06), 0 6px 18px rgba(8,27,64,.07);
  --me-bg: #0c2a60; --me-ink: #fff; --them-bg: #fff;
  --radius: 16px; --tabbar-h: 66px; --hdr: 92px; --tap: 44px;
  --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 24px;
  --fs-xs: 12px; --fs-sm: 13.5px; --fs-md: 15.5px; --fs-lg: 17px;
  --ease: cubic-bezier(.2,.7,.2,1);
  --nq: "HCT Nastaliq", "Noto Nastaliq Urdu", "HCT Naskh", serif;
  --nk: "HCT Naskh", "Noto Naskh Arabic", "HCT Latin", sans-serif;
  --lt: "HCT Latin", "Montserrat", system-ui, sans-serif;
  color-scheme: light;
}
[data-theme="dark"] {
  --bg: #050c1a; --card: #0d1930; --card2: #14233f; --ink: #e8eef8; --ink2: #c4d0e4; --muted: #8b9cb9; --line: #1c2b48;
  --head-1: #030a1a; --head-2: #081a3d; --title: #f3f6fc; --link: #7fb0f0;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 6px 18px rgba(0,0,0,.25);
  --me-bg: #1d3f7a; --them-bg: #13223e;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
body {
  margin: 0; background: var(--bg); color: var(--ink); font-family: var(--nk); font-size: 16.5px; line-height: 1.75;
  padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); overscroll-behavior-y: contain;
  -webkit-tap-highlight-color: transparent; transition: background .25s;
}
a { color: var(--link); }
button, input, textarea { font: inherit; color: inherit; }
.en { font-family: var(--lt); direction: ltr; unicode-bidi: isolate; letter-spacing: .01em; }
.num { font-family: var(--lt); direction: ltr; unicode-bidi: isolate; font-variant-numeric: tabular-nums; }
.num small, small.per { font-family: var(--nk); font-weight: 500; font-size: .7em; margin-inline-start: 3px; opacity: .8; }
.muted { color: var(--muted); } .small { font-size: 13px; }
[hidden] { display: none !important; }
.ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ---------- splash ---------- */
#splash { position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  background: radial-gradient(circle at 50% 40%, #1a4a9a 0%, #081b40 55%, #040e24 100%); color: #fff; transition: opacity .4s, visibility .4s; }
#splash img { width: 132px; height: 132px; border-radius: 50%; box-shadow: 0 12px 40px rgba(0,0,0,.45); animation: pop .6s ease-out; }
#splash .sp-ur { font-family: var(--nq); font-size: 30px; line-height: 2.2; color: var(--gold-light); margin-top: 14px; }
#splash .sp-en { font-family: var(--lt); font-weight: 800; letter-spacing: .22em; font-size: 12px; color: #dfe7f5; direction: ltr; }
#splash .sp-tag { font-size: 14px; color: #b9c8e2; margin-top: 8px; }
#splash .sp-bar { width: 120px; height: 3px; border-radius: 3px; background: rgba(255,255,255,.15); overflow: hidden; margin-top: 26px; }
#splash .sp-bar i { display: block; height: 100%; width: 40%; background: var(--gold); border-radius: 3px; animation: load 1s ease-in-out infinite; }
#splash.hide { opacity: 0; visibility: hidden; }
@keyframes pop { from { transform: scale(.9); } }   /* no opacity fade: keeps LCP early */
@keyframes load { from { transform: translateX(160%); } to { transform: translateX(-260%); } }

/* ---------- top bar + ticker ---------- */
.hdr { position: sticky; top: 0; z-index: 40; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: calc(8px + env(safe-area-inset-top)) 12px 6px; color: #fff; min-height: 60px;
  background: linear-gradient(180deg, var(--head-1), var(--head-2)); }
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; min-width: 0; min-height: var(--tap); border-radius: 12px; }
.brand img { width: 40px; height: 40px; border-radius: 50%; box-shadow: 0 0 0 2px var(--gold); }
.brand-text { display: flex; flex-direction: column; }
.brand-ur { font-family: var(--nq); font-size: 18px; line-height: 1.9; color: var(--gold-light); white-space: nowrap; word-spacing: .3em; margin-top: -2px; }
.brand-en { font-family: var(--lt); font-size: 9.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #dbe4f3; margin-top: -3px; direction: ltr; text-align: right; line-height: 1.2; }
.top-actions { display: flex; gap: 6px; }
.icon-btn { width: var(--tap); height: var(--tap); border-radius: 50%; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.06); color: #fff; display: grid; place-items: center; cursor: pointer; }
.icon-btn .ic { width: 20px; height: 20px; }

.ticker { display: flex; align-items: stretch; height: 34px; overflow: hidden;
  background: var(--navy-deep); border-bottom: 2px solid var(--gold); border-top: 1px solid rgba(255,255,255,.06); }
.tk-label { flex: none; display: flex; align-items: center; gap: 6px; padding: 0 12px; background: var(--gold); color: var(--navy); font-weight: 700; font-size: 14px; position: relative; z-index: 2; }
.tk-label i { width: 8px; height: 8px; border-radius: 50%; background: var(--red); animation: blink 1.2s infinite; }
.tk-track { flex: 1; overflow: hidden; position: relative; mask-image: linear-gradient(to left, transparent 0, #000 12px, #000 calc(100% - 24px), transparent 100%); }
.tk-move { display: inline-flex; white-space: nowrap; height: 100%; align-items: center; animation: tk 30s linear infinite; will-change: transform; }
.tk-copy { display: inline-flex; align-items: center; }
.tk-item { color: #fff; text-decoration: none; font-size: 14.5px; padding: 0 6px; }
.tk-dot { color: var(--gold); font-size: 9px; padding: 0 12px; }
.ticker:hover .tk-move { animation-play-state: paused; }
@keyframes tk { from { transform: translateX(0); } to { transform: translateX(50%); } }
@keyframes blink { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .tk-move { animation: none; } }
.r-community .ticker { display: none; }

.offline-bar { background: #3b2a00; color: var(--gold-light); font-size: 13px; text-align: center; padding: 3px 10px; }
#ptr { position: fixed; top: calc(var(--hdr) + 4px); left: 50%; z-index: 38; width: 40px; height: 40px; border-radius: 50%; margin-top: -44px;
  display: grid; place-items: center; background: var(--card); color: var(--blue); box-shadow: var(--shadow); opacity: 0; transform: translate(-50%, 0); pointer-events: none; }
#ptr.ready { color: var(--gold); }
#ptr.spin .ic { animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

main { max-width: 640px; margin: 0 auto; padding: 12px 14px 28px; outline: none; }

/* ---------- headings ---------- */
.h-sec { font-family: var(--nq); font-weight: 400; font-size: 19px; line-height: 2.05; color: var(--title); margin: 16px 0 6px; display: flex; align-items: baseline; gap: 8px; }
.h-sec::before { content: ""; width: 4px; height: 20px; background: var(--gold); border-radius: 3px; align-self: center; }
.h-sec .en { font-size: 10.5px; font-weight: 700; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.sec-more { margin-inline-start: auto; font-family: var(--nk); font-size: 13.5px; text-decoration: none; display: flex; align-items: center; gap: 2px; align-self: center; min-height: var(--tap); padding-inline: 6px; margin-block: -6px; }
.sec-more .ic { width: 16px; height: 16px; }
.page-h { display: flex; align-items: baseline; gap: 10px; margin: 2px 0 10px; }
.page-h h1 { font-family: var(--nq); font-weight: 400; font-size: 25px; line-height: 2.1; margin: 0; color: var(--title); }
.page-h .en { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* ---------- generic ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px; margin-bottom: 12px; }
.card.list { padding: 4px 14px; }
.badge { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; line-height: 1.75; padding: 0 9px; border-radius: 999px; background: var(--navy); color: var(--gold-light); white-space: nowrap; }
.badge .ic { width: 12px; height: 12px; }
.badge.sample { background: transparent; color: #c0492f; border: 1.4px dashed #c0492f; font-weight: 700; }
.badge.gold { background: var(--gold); color: var(--navy); font-weight: 700; }
.badge.cat-pakistan { background: var(--green); color: #fff; } .badge.cat-world { background: #1c7d9c; color: #fff; } .badge.cat-sports { background: #2e8b3a; color: #fff; }
[data-theme="dark"] .badge:not(.gold):not(.live):not(.admin):not(.sample):not(.cat-pakistan):not(.cat-world):not(.cat-sports) { background: #1d3566; } [data-theme="dark"] .badge.sample { background: transparent; color: #ff8a70; border-color: #ff8a70; }
.note { display: flex; gap: 8px; align-items: flex-start; border-radius: 12px; padding: 9px 12px; font-size: 14px; margin-bottom: 12px; line-height: 1.7; }
.note .ic { width: 18px; height: 18px; margin-top: 4px; }
.note small { display: block; opacity: .85; }
.sample-note { border: 1.4px dashed #c0492f; color: #9d3622; background: #fff5f2; }
.gold-note { background: #fff7dd; border: 1px solid #f0d58a; color: #5b4300; }
.warn { background: #fff0ee; color: #8a2a1c; }
[data-theme="dark"] .sample-note { background: #2a1410; color: #ffb4a3; border-color: #a2503e; }
[data-theme="dark"] .gold-note { background: #231c06; border-color: #5a4610; color: #f3dc9a; }
[data-theme="dark"] .warn { background: #2a1210; color: #ffb4a3; }
.attrib { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 8px; line-height: 1.9; }
.attrib a { color: var(--muted); }

.btn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 48px; border: 0; border-radius: 14px; padding: 9px 16px; transition: transform .12s var(--ease), filter .15s; font-size: 16.5px; text-decoration: none; cursor: pointer; line-height: 1.7; margin-bottom: 10px; }
.btn .bl { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.55; }
.btn .bl small { font-size: 11px; opacity: .85; line-height: 1.3; }
.btn-fb { background: #1877f2; color: #fff; } .btn-wa-on { background: #25d366; color: #073b1c; }
.btn-wa { background: var(--card2); color: var(--muted); cursor: not-allowed; }
.btn-gold { background: var(--gold); color: var(--navy); font-weight: 700; }
.btn-ghost { background: var(--card); color: var(--title); border: 1.4px solid var(--line); }
.btn:disabled { opacity: .55; }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 10px; scrollbar-width: none; }
.chips::-webkit-scrollbar, .rooms::-webkit-scrollbar, .cat-tabs::-webkit-scrollbar, .hours::-webkit-scrollbar { display: none; }
.chip { flex: none; min-height: var(--tap); border: 1px solid var(--line); background: var(--card); color: var(--title); border-radius: 999px; padding: 2px 16px; transition: background .15s, color .15s; font-size: 14.5px; cursor: pointer; line-height: 1.8; }
.chip[aria-pressed="true"] { background: var(--navy); color: var(--gold-light); border-color: var(--navy); }
[data-theme="dark"] .chip[aria-pressed="true"] { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.seg { display: flex; background: var(--card); border-radius: 14px; padding: 4px; gap: 4px; margin-bottom: 12px; box-shadow: var(--shadow); }
.seg button { flex: 1; min-height: var(--tap); border: 0; background: none; border-radius: 10px; padding: 3px 6px; transition: background .18s, color .18s; cursor: pointer; color: var(--title); font-size: 15.5px; line-height: 1.6; }
.seg button small { display: block; font-size: 10px; color: var(--muted); line-height: 1.2; }
.seg button[aria-pressed="true"] { background: var(--navy); color: var(--gold-light); }
.seg button[aria-pressed="true"] small { color: #d3dcee; }
[data-theme="dark"] .seg button[aria-pressed="true"] { background: var(--gold); color: var(--navy); }
[data-theme="dark"] .seg button[aria-pressed="true"] small { color: #3b3310; }
.small-seg { max-width: 220px; }

/* ---------- skeleton + empty ---------- */
.sk { background: linear-gradient(90deg, var(--card2) 25%, var(--line) 50%, var(--card2) 75%); background-size: 200% 100%; animation: sk 1.3s infinite linear; border-radius: 8px; }
@keyframes sk { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.sk-card { background: var(--card); border-radius: var(--radius); padding: 12px; margin-bottom: 12px; box-shadow: var(--shadow); }
.sk-img { aspect-ratio: 16/9; border-radius: 12px; margin-bottom: 12px; }
.sk-line { height: 14px; margin: 8px 0; } .w90 { width: 90%; } .w80 { width: 80%; } .w60 { width: 60%; } .w50 { width: 50%; }
.sk-row { display: flex; gap: 12px; align-items: center; padding: 10px 0; }
.sk-thumb { width: 104px; height: 66px; border-radius: 10px; flex: none; }
.sk-msg { display: flex; margin: 10px 0; } .sk-msg.me { justify-content: flex-end; }
.empty { text-align: center; padding: 26px 16px; color: var(--muted); }
.empty svg { width: 110px; height: 110px; display: block; margin: 0 auto 6px; }
.empty b { display: block; color: var(--title); font-size: 16.5px; font-weight: 600; }
.empty p { margin: 2px 0 0; font-size: 14px; }
.empty .btn { width: auto; display: inline-flex; margin: 14px auto 0; padding-inline: 22px; }
.empty .btn .ic { width: 18px; height: 18px; }

/* ---------- home ---------- */
.hello { display: flex; justify-content: space-between; align-items: center; margin: 0 2px 8px; }
.hello-t { font-family: var(--nq); font-size: 22px; line-height: 2; color: var(--title); }
.hello-d { font-size: 13px; color: var(--muted); margin-top: -4px; }
.loc-pill { display: inline-flex; align-items: center; gap: 4px; min-height: var(--tap); background: var(--card); color: var(--title); border-radius: 999px; padding: 2px 14px 2px 12px; font-size: 14px; text-decoration: none; box-shadow: var(--shadow); }
.loc-pill .ic { width: 16px; height: 16px; color: var(--gold); }
.quick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.qcard { display: flex; align-items: center; gap: 8px; min-height: 84px; padding: 10px 12px; border-radius: var(--radius); text-decoration: none; color: #fff;
  background: linear-gradient(140deg, var(--blue-2), var(--navy) 80%); border: 1px solid rgba(232,182,50,.35); box-shadow: var(--shadow); }
.qcard .sk { width: 100%; opacity: .25; margin: 0 !important; }
.qcard svg.wx { width: 44px; height: 44px; flex: none; }
.qcard > div { display: flex; flex-direction: column; min-width: 0; }
.qcard small { font-size: 11.5px; color: var(--gold-light); line-height: 1.5; }
.qcard b { font-size: 18px; line-height: 1.45; font-weight: 700; white-space: nowrap; }
.qcard b.num { font-size: 26px; line-height: 1.15; }
.qcard b.num small.hl { font-family: var(--lt); font-size: 12px; font-weight: 600; color: #d6dfef; margin-inline-start: 6px; opacity: 1; }
.qcard span { font-size: 12px; color: #d6dfef; line-height: 1.45; }
.q-moon { width: 40px; height: 40px; border-radius: 50%; background: rgba(232,182,50,.18); display: grid; place-items: center; flex: none; color: var(--gold-light); }
.community-cta { display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  text-decoration: none; color: var(--ink); border-inline-start: 4px solid var(--gold); margin-bottom: 4px; }
.cc-ic { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(140deg, var(--gold-light), var(--gold)); color: var(--navy); flex: none; }
.cc-b { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cc-b b { font-size: 16.5px; color: var(--title); }
.cc-b small { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.community-cta > .ic { color: var(--muted); width: 18px; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.tile { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 12px 6px 8px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); text-decoration: none; color: var(--title); text-align: center; }
.tile-ic { width: 42px; height: 42px; border-radius: 14px; display: grid; place-items: center; color: #fff; margin-bottom: 4px; }
.tile b { font-size: 14px; font-weight: 600; line-height: 1.5; }
.tile small { font-size: 9.5px; color: var(--muted); font-weight: 600; letter-spacing: .04em; }
.t-chat .tile-ic { background: linear-gradient(140deg, #f4c542, #d99a0b); color: var(--navy); }
.t-local .tile-ic { background: linear-gradient(140deg, #2a6bd0, #0c2a60); } .t-pk .tile-ic { background: linear-gradient(140deg, #16a05a, #02552b); }
.t-world .tile-ic { background: linear-gradient(140deg, #22a0c4, #0c4a63); } .t-sports .tile-ic { background: linear-gradient(140deg, #4cb857, #1b6a26); }
.t-wx .tile-ic { background: linear-gradient(140deg, #57a6ff, #2261c2); } .t-pr .tile-ic { background: linear-gradient(140deg, #7c5cd6, #3a2388); }
.t-joke .tile-ic { background: linear-gradient(140deg, #ff9f43, #e0602a); } .t-util .tile-ic { background: linear-gradient(140deg, #f0b429, #b57800); }
.joke-mini { display: flex; gap: 10px; text-decoration: none; color: var(--ink); position: relative; border-inline-start: 4px solid #ff9f43; flex-wrap: wrap; }
.joke-mini .jm-q { font-family: Georgia, serif; font-size: 46px; line-height: .9; color: #ff9f43; }
.joke-mini > div { flex: 1; min-width: 0; } .joke-mini p { margin: 0; font-size: 15px; line-height: 1.85; }
.jm-more { width: 100%; display: flex; justify-content: flex-end; align-items: center; font-size: 13px; color: var(--link); }
.jm-more .ic { width: 15px; height: 15px; }

/* ---------- news ---------- */
.thumb { display: block; width: 100%; aspect-ratio: 16/9; object-fit: cover; background: var(--navy); }
.hero { display: block; background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); text-decoration: none; color: var(--ink); margin-bottom: 12px; }
.hero-b { padding: 10px 14px 12px; }
.hero h2 { font-family: var(--nq); font-weight: 400; font-size: 20px; line-height: 2.1; margin: 4px 0 2px; color: var(--title); text-wrap: balance; }
.hero p { margin: 0 0 4px; color: var(--ink2); font-size: 15px; line-height: 1.8; }
.nmeta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.nrow { display: flex; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); align-items: flex-start; }
.nrow:last-child { border-bottom: 0; }
.nrow .thumb.sm { width: 108px; height: 70px; aspect-ratio: auto; border-radius: 10px; flex: none; }
.nrow-b { flex: 1; min-width: 0; }
.nrow h3 { font-family: var(--nq); font-weight: 400; font-size: 15.5px; line-height: 2; margin: -4px 0 2px; color: var(--title); text-wrap: pretty; }
/* v4.2 editor teaser on list rows (1-2 lines) + full story body on the article page */
.nrow-t { font-size: 13.5px; line-height: 1.85; color: var(--muted); margin: 0 0 3px; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero p[data-teaser] { display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.article .art-body { margin-top: 8px; }
.article .art-body.full p { text-align: start; }
.cat-tabs { display: flex; gap: 6px; overflow-x: auto; margin: 0 -14px 10px; padding: 0 14px 8px; border-bottom: 1px solid var(--line); scrollbar-width: none; }
.cat-tabs a { flex: 1 0 auto; display: flex; align-items: center; justify-content: center; gap: 6px; min-height: var(--tap); padding: 5px 12px; transition: background .18s, color .18s; border-radius: 12px; text-decoration: none; color: var(--muted); font-size: 15.5px; font-weight: 600; }
.cat-tabs a .ic { width: 18px; height: 18px; }
.cat-tabs a.on { background: var(--navy); color: var(--gold-light); box-shadow: var(--shadow); }
[data-theme="dark"] .cat-tabs a.on { background: var(--gold); color: var(--navy); }
.back { display: inline-flex; align-items: center; gap: 4px; min-height: var(--tap); border: 0; background: none; color: var(--link); padding: 0 4px 0 10px; margin-bottom: 4px; cursor: pointer; font-size: 15px; }
.back .ic { width: 18px; height: 18px; }
.article { background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); padding-bottom: 10px; margin-bottom: 12px; }
.article > :not(.thumb) { margin-inline: 16px; }
.article .nmeta:first-of-type { margin-top: 12px; }
.article h1 { font-family: var(--nq); font-weight: 400; font-size: 23px; line-height: 2.15; color: var(--title); margin-top: 4px; margin-bottom: 2px; text-wrap: balance; }
.article p { font-size: 17px; line-height: 2; margin-top: 0; margin-bottom: 10px; color: var(--ink); }
.art-meta { padding-bottom: 10px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.article p.src-credit { font-size: 14.5px; line-height: 1.9; color: var(--muted); border-top: 1px solid var(--line); padding-top: 10px; margin-top: 6px; margin-bottom: 4px; user-select: text; }
.share-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 8px; }
.sbtn { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; border: 0; border-radius: 12px; padding: 8px; font-size: 14.5px; cursor: pointer; text-decoration: none; }
.sbtn.wa { background: #25d366; color: #063b1a; } .sbtn.fb { background: #1877f2; color: #fff; } .sbtn.more { background: var(--gold); color: var(--navy); }
.scores { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 8px; }
.score { flex: 1 0 260px; background: linear-gradient(145deg, #1b6a26, #0b3314); color: #fff; border-radius: var(--radius); padding: 10px 14px; box-shadow: var(--shadow); }
.score.is-sample { outline: 1.5px dashed rgba(255,255,255,.55); outline-offset: -5px; }
.score-h { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #d9f2dc; margin-bottom: 4px; }
.score-h .en { margin-inline-start: auto; font-weight: 700; font-size: 11px; }
.badge.live { background: var(--red); color: #fff; }
.score-t { display: flex; justify-content: space-between; font-size: 16.5px; line-height: 1.9; }
.score-t .num { font-weight: 700; font-size: 18px; }
.score-s { font-size: 12.5px; color: #cfe9d2; border-top: 1px solid rgba(255,255,255,.15); margin-top: 4px; padding-top: 4px; }

/* ---------- prayer ---------- */
.pr-head { background: radial-gradient(circle at 20% 0%, #2a64c4 0%, #0c2a60 45%, #081b40 100%); color: #fff; border-radius: 20px; padding: 14px 16px 12px; text-align: center; box-shadow: var(--shadow); margin-bottom: 12px; border: 1px solid rgba(232,182,50,.35); }
.pr-next-l { color: var(--gold-light); font-size: 13.5px; }
.pr-next-n { font-family: var(--nq); font-size: 32px; line-height: 2.1; }
.pr-count { font-size: 34px; font-weight: 800; letter-spacing: .05em; line-height: 1.2; }
.pr-bar { height: 6px; border-radius: 6px; background: rgba(255,255,255,.14); margin: 12px 10px 10px; overflow: hidden; direction: rtl; }
.pr-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold-light), var(--gold)); border-radius: 6px; transition: width 1s linear; }
.pr-dates { display: flex; justify-content: space-between; font-size: 13.5px; color: #d0dbee; }
.pr-list { padding: 4px 0; overflow: hidden; }
.pr { display: flex; align-items: center; gap: 10px; padding: 9px 16px; border-bottom: 1px solid var(--line); }
.pr:last-child { border-bottom: 0; }
.pr-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--card2); color: var(--blue); }
.pr-ic .ic { width: 18px; height: 18px; }
.pr .n { flex: 1; display: flex; align-items: baseline; gap: 8px; font-size: 17.5px; }
.pr .n small { font-size: 11px; color: var(--muted); }
.pr .n em { font-style: normal; font-size: 11.5px; background: var(--gold); color: var(--navy); border-radius: 999px; padding: 0 8px; line-height: 1.75; align-self: center; }
.pr .t { font-size: 18px; font-weight: 700; color: var(--title); }
.pr.sub { opacity: .7; } .pr.sub .n, .pr.sub .t { font-size: 15.5px; }
.pr.next { background: linear-gradient(90deg, transparent, rgba(232,182,50,.16)); box-shadow: inset -4px 0 0 var(--gold); }
.pr.next .pr-ic { background: var(--gold); color: var(--navy); }
.pr.passed .n, .pr.passed .t { color: var(--muted); }
.pr-sun { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; padding: 10px 6px; }
.pr-sun > div { display: flex; flex-direction: column; align-items: center; line-height: 1.5; }
.pr-sun .ic { color: var(--gold); width: 20px; height: 20px; }
.pr-sun small { font-size: 12px; color: var(--muted); }
.pr-sun b { font-size: 15px; color: var(--title); }

/* ---------- weather ---------- */
.wx-now { border-radius: 20px; padding: 14px 16px 12px; color: #fff; box-shadow: var(--shadow); margin-bottom: 4px; border: 1px solid rgba(232,182,50,.35);
  background: radial-gradient(circle at 15% 10%, #3b82e0 0%, #1d5bb8 35%, #081b40 100%); }
.wx-now.is-night { background: radial-gradient(circle at 15% 10%, #2b3f7a 0%, #0f1f4a 45%, #040e24 100%); }
.wx-now .row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.wx-now .place { font-family: var(--nq); font-size: 21px; line-height: 2; color: var(--gold-light); }
.wx-now .place .en { font-size: 11px; color: #d6dfef; }
.wx-now .temp { font-size: 64px; font-weight: 700; line-height: 1; }
.wx-now .temp sup { font-size: 24px; font-weight: 500; }
.wx-now .desc { font-size: 18px; }
.wx-now .hilo { font-size: 14px; color: #d6dfef; }
.wx-now svg.big { width: 104px; height: 104px; }
.wx-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.wx-grid div { background: rgba(255,255,255,.09); border-radius: 12px; padding: 5px 6px; text-align: center; }
.wx-grid small { display: block; font-size: 11.5px; color: #d6dfef; line-height: 1.5; }
.wx-grid b { font-size: 15px; font-weight: 600; }
.upd { font-size: 12.5px; color: #c9d6ea; margin-top: 8px; }
.hours { display: flex; gap: 4px; overflow-x: auto; padding: 8px; scrollbar-width: none; }
.hr { flex: none; width: 58px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0; border-radius: 12px; }
.hr:first-child { background: var(--card2); }
.hr small { font-size: 11.5px; color: var(--muted); white-space: nowrap; line-height: 1.4; }
.hr svg.wx { width: 32px; height: 32px; }
.hr b { font-size: 15px; color: var(--title); } .hr i { font-style: normal; font-size: 11px; color: var(--link); min-height: 14px; }
.days { padding: 2px 14px; }
.day { display: grid; grid-template-columns: 4.6em 34px 1fr 118px; align-items: center; gap: 8px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.day:last-child { border-bottom: 0; }
.day .dn { line-height: 1.45; font-weight: 600; } .day .dn small { display: block; color: var(--muted); font-size: 11.5px; font-weight: 400; }
.day svg.wx { width: 34px; height: 34px; }
.day .dd { font-size: 13.5px; color: var(--ink2); line-height: 1.5; }
.day .dd .rain { display: block; color: var(--link); font-size: 12px; }
.range { display: flex; align-items: center; gap: 6px; direction: ltr; font-size: 14px; }
.range span.num { color: var(--muted); width: 26px; text-align: right; }
.range b { color: var(--title); width: 28px; }
.range .bar { flex: 1; height: 5px; border-radius: 5px; background: var(--card2); position: relative; }
.range .bar i { position: absolute; top: 0; bottom: 0; border-radius: 5px; background: linear-gradient(90deg, #57a6ff, var(--gold)); }

/* ---------- joke ---------- */
.joke-card { position: relative; border-radius: 22px; padding: 16px 18px 14px; color: #fff; overflow: hidden; box-shadow: var(--shadow);
  background: radial-gradient(circle at 85% 0%, #2a64c4 0%, #0c2a60 50%, #081b40 100%); border: 1px solid rgba(232,182,50,.45); }
.jk-top { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: #d6dfef; }
.jk-q { font-family: Georgia, serif; font-size: 90px; line-height: .6; color: var(--gold); opacity: .6; height: 42px; margin-top: 16px; }
.jk-lines p { font-size: 19px; line-height: 2.05; margin: 0 0 6px; }
.jk-lines b { color: var(--gold-light); font-weight: 700; margin-inline-end: 4px; }
.jk-foot { display: flex; align-items: center; gap: 6px; justify-content: flex-end; font-size: 12.5px; color: #b9c8e2; margin-top: 6px; border-top: 1px solid rgba(255,255,255,.12); padding-top: 8px; }
.jk-foot .ic { width: 16px; height: 16px; color: var(--gold); }
.jk-nav { display: grid; grid-template-columns: 1fr 1.3fr 1fr; gap: 8px; margin-top: 12px; }
.jk-nav .btn { margin: 0; font-size: 15px; padding: 8px 6px; gap: 4px; }
.jk-nav .ic { width: 18px; height: 18px; }

/* ---------- utility / more ---------- */
.util h4 { margin: 0 0 6px; font-weight: 600; font-size: 17px; color: var(--title); display: flex; align-items: center; gap: 8px; }
.util h4 .en { margin-inline-start: auto; font-size: 11px; color: var(--muted); font-weight: 600; }
.u-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: #fff2cc; color: #b57800; }
.u-ic.gas { background: #ffe3d6; color: #d0501f; } .u-ic .ic { width: 18px; height: 18px; }
[data-theme="dark"] .u-ic { background: #3a2e08; } [data-theme="dark"] .u-ic.gas { background: #3a1a0d; }
.util .empty { padding: 8px; } .util .empty svg { width: 70px; height: 70px; }
.u-item { border-top: 1px solid var(--line); padding: 8px 0; } .u-item:first-of-type { border-top: 0; } .u-item b { display: block; }
.help { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.help a { display: flex; justify-content: space-between; align-items: center; gap: 6px; background: var(--card2); border-radius: 12px; padding: 6px 10px; text-decoration: none; color: var(--title); line-height: 1.5; }
.help a small { display: block; font-size: 10.5px; color: var(--muted); }
.help a .num { font-weight: 700; font-size: 17px; color: var(--link); }
.mlist { padding: 2px 0; }
.mitem { display: flex; align-items: center; gap: 12px; padding: 9px 16px; text-decoration: none; color: var(--title); border-bottom: 1px solid var(--line); }
.mitem:last-child { border-bottom: 0; }
.mi-ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--card2); color: var(--blue); }
[data-theme="dark"] .mi-ic { color: var(--gold-light); }
.mi-t { flex: 1; display: flex; flex-direction: column; line-height: 1.5; font-size: 16px; }
.mi-t small { font-size: 10.5px; color: var(--muted); }
.mitem > .ic { color: var(--muted); width: 18px; }
.switch { display: flex; gap: 10px; align-items: center; cursor: pointer; font-size: 15px; line-height: 1.6; min-height: var(--tap); }
.switch input { width: 20px; height: 20px; accent-color: var(--gold); flex: none; }
.switch small { display: block; font-size: 11px; color: var(--muted); }
.about { display: flex; gap: 12px; align-items: flex-start; } .about img { border-radius: 50%; flex: none; }
.about p { margin: 0 0 6px; font-size: 15px; } .about .en { text-align: right; }
.rules ol { margin: 0; padding-inline-start: 20px; } .rules li { margin: 4px 0; line-height: 1.85; }

/* ---------- community ---------- */
.r-community { overflow: hidden; }
.r-community main { padding: 0; max-width: 680px; }
.chat { display: flex; flex-direction: column; height: calc(100dvh - var(--hdr) - var(--tabbar-h) - env(safe-area-inset-bottom)); }
.chat-head { flex: none; padding: 8px 12px 0; background: var(--bg); border-bottom: 1px solid var(--line); }
.chat-status { display: flex; gap: 8px; align-items: center; font-size: 12.5px; line-height: 1.65; padding: 4px 10px; border-radius: 10px; margin-bottom: 8px; background: #fff2cc; color: #6b4600; border: 1px solid #f0d58a; }
.chat-status[hidden] { display: none; } .chat-status .ic { width: 16px; height: 16px; flex: none; }
[data-theme="dark"] .chat-status { background: #2a2106; color: #f3dc9a; border-color: #5a4610; }
.rooms { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 8px; scrollbar-width: none; }
.room { flex: none; min-height: var(--tap); border: 1px solid var(--line); background: var(--card); color: var(--title); border-radius: 999px; padding: 1px 14px; font-size: 14px; cursor: pointer; line-height: 1.85; }
.room[aria-pressed="true"] { background: var(--navy); color: var(--gold-light); border-color: var(--navy); }
[data-theme="dark"] .room[aria-pressed="true"] { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.msgs { flex: 1; overflow-y: auto; padding: 8px 12px 12px; overscroll-behavior: contain;
  background-image: radial-gradient(circle at 1px 1px, rgba(22,78,160,.07) 1px, transparent 0); background-size: 18px 18px; }
.day-sep { text-align: center; margin: 10px 0; } .day-sep span { font-size: 11.5px; background: var(--card2); color: var(--muted); padding: 1px 12px; border-radius: 999px; }
.msg { display: flex; gap: 8px; align-items: flex-end; margin: 6px 0; }
.msg.me { flex-direction: row-reverse; }
.av { width: 30px; height: 30px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-size: 14px; flex: none; font-weight: 700; }
.bubble { max-width: 80%; background: var(--them-bg); border-radius: 16px; border-start-start-radius: 4px; padding: 5px 12px 3px; box-shadow: 0 1px 1px rgba(8,27,64,.08); }
.msg.me .bubble { background: var(--me-bg); color: var(--me-ink); border-radius: 16px; border-end-end-radius: 4px; }
.who { font-size: 12.5px; font-weight: 700; line-height: 1.7; display: flex; align-items: center; gap: 6px; }
.badge.admin { background: var(--gold); color: var(--navy); font-size: 10px; padding: 0 6px; line-height: 1.6; }
.txt { font-size: 15.5px; line-height: 1.85; white-space: pre-wrap; overflow-wrap: anywhere; }
.mmeta { display: flex; justify-content: flex-end; align-items: center; gap: 4px; font-size: 10.5px; color: var(--muted); line-height: 1.5; }
.msg.me .mmeta { color: #b8c7e6; }
.dots { border: 0; background: none; padding: 0; width: var(--tap); height: var(--tap); margin: -14px -12px -14px -10px; cursor: pointer; color: inherit; display: grid; place-items: center; border-radius: 50%; }
.dots .ic { width: 16px; height: 16px; }
.msg.gone .bubble { background: transparent; box-shadow: none; border: 1px dashed var(--line); color: var(--muted); font-size: 13px; }
.msg.gone .txt { display: flex; align-items: center; gap: 6px; font-size: 13px; } .msg.gone .ic { width: 15px; height: 15px; }
.msg.is-hidden .bubble { opacity: .75; outline: 1.5px dashed #c0492f; }
.hid-note { font-size: 11.5px; color: #c0492f; display: flex; gap: 4px; align-items: center; } .hid-note .ic { width: 13px; height: 13px; }
.composer { flex: none; padding: 8px 10px; background: var(--card); border-top: 1px solid var(--line); }
.comp-row { display: flex; gap: 8px; align-items: flex-end; }
.comp-row textarea { flex: 1; resize: none; border: 1px solid var(--line); background: var(--bg); border-radius: 20px; padding: 6px 14px; line-height: 1.7; max-height: 120px; font-size: 15.5px; outline: none; }
.comp-row textarea:focus { border-color: var(--gold); }
.send { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--gold); color: var(--navy); display: grid; place-items: center; cursor: pointer; flex: none; }
.send .ic { transform: scaleX(-1); } .send:disabled { opacity: .45; }
.c-count { font-size: 11px; color: var(--muted); text-align: left; min-height: 0; }
.join-btn { margin: 0; }

/* ---------- sheet + toast ---------- */
.sheet-wrap { position: fixed; inset: 0; z-index: 80; }
.sheet-bg { position: absolute; inset: 0; background: rgba(2,8,20,.5); opacity: 0; transition: opacity .2s; }
.sheet { position: absolute; bottom: 0; left: 0; right: 0; max-width: 640px; margin: 0 auto; background: var(--card); border-radius: 22px 22px 0 0;
  padding: 8px 16px calc(14px + env(safe-area-inset-bottom)); transform: translateY(100%); transition: transform .25s ease-out; max-height: 88vh; overflow-y: auto; }
.sheet-wrap.open .sheet { transform: none; } .sheet-wrap.open .sheet-bg { opacity: 1; }
.grip { width: 42px; height: 4px; border-radius: 4px; background: var(--line); margin: 0 auto 8px; }
.sheet-title { font-family: var(--nq); font-weight: 400; font-size: 20px; line-height: 2; margin: 0; color: var(--title); display: flex; gap: 8px; align-items: baseline; }
.sheet-title .en { font-size: 11px; color: var(--muted); }
.sheet-sub { font-size: 13px; color: var(--muted); margin: 2px 0 10px; }
.share-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(72px, 1fr)); gap: 8px; margin: 8px 0 12px; }
.share-btn { display: flex; flex-direction: column; align-items: center; gap: 4px; border: 0; background: none; cursor: pointer; font-size: 12.5px; color: var(--ink); text-decoration: none; }
.share-btn .ic { width: 50px; height: 50px; padding: 13px; border-radius: 50%; box-sizing: border-box; }
.share-btn.wa .ic { background: #25d366; color: #fff; } .share-btn.fb .ic { background: #1877f2; color: #fff; }
.share-btn.cp .ic { background: var(--card2); color: var(--title); } .share-btn.more .ic { background: var(--gold); color: var(--navy); }
.acts { display: flex; flex-direction: column; margin: 6px 0 10px; }
.act { display: flex; align-items: center; gap: 12px; min-height: 48px; border: 0; background: none; padding: 10px 4px; font-size: 16px; cursor: pointer; border-bottom: 1px solid var(--line); text-align: start; color: var(--ink); }
.act .ic { color: var(--muted); } .act.warn .ic { color: #d08a00; } .act.danger { color: #c62828; } .act.danger .ic { color: #c62828; }
.field { display: flex; flex-direction: column; gap: 4px; margin: 8px 0; font-size: 14px; }
.field small { color: var(--muted); }
.field input { border: 1.4px solid var(--line); border-radius: 12px; padding: 8px 12px; background: var(--bg); font-size: 16px; outline: none; }
.field input:focus { border-color: var(--gold); }
.rules-mini { background: var(--card2); border-radius: 12px; padding: 8px 12px; font-size: 13.5px; margin: 8px 0; }
.rules-mini b { display: flex; align-items: center; gap: 6px; } .rules-mini .ic { width: 16px; height: 16px; color: var(--gold); }
.rules-mini ul { margin: 4px 0; padding-inline-start: 18px; line-height: 1.8; }
.sheet .switch { margin: 10px 0 12px; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 18px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); z-index: 90;
  background: #0b1a36; color: #fff; padding: 8px 16px; border-radius: 14px; font-size: 14.5px; box-shadow: 0 8px 24px rgba(0,0,0,.3); opacity: 0; pointer-events: none;
  transition: .25s; max-width: calc(100% - 32px); text-align: center; border: 1px solid rgba(232,182,50,.4); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: #5a1511; border-color: #a2503e; }

/* ---------- tab bar ---------- */
.tabbar { position: fixed; bottom: 0; inset-inline: 0; z-index: 50; display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--card); border-top: 1px solid var(--line); box-shadow: 0 -4px 18px rgba(8,27,64,.08);
  padding-bottom: env(safe-area-inset-bottom); height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); }
[data-theme="dark"] .tabbar { background: #081226; }
.tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--muted); text-decoration: none; position: relative; padding-top: 2px; transition: color .18s; }
.tabbar b { font-weight: 600; font-size: 12.5px; line-height: 1.5; white-space: nowrap; }
.tabbar small { font-family: var(--lt); font-size: 9px; line-height: 1; color: var(--muted); }
.tabbar a.active small { color: var(--ink2); }
.tabbar a.active { color: var(--title); }
.tabbar a.active:not(.tab-center)::before { content: ""; position: absolute; top: 0; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--gold); }
.tabbar a.active .ic { color: var(--gold); stroke-width: 2.1; }
.tab-center .fab { width: 50px; height: 50px; border-radius: 50%; margin-top: -22px; display: grid; place-items: center; color: var(--navy);
  background: linear-gradient(140deg, var(--gold-light), var(--gold)); box-shadow: 0 6px 16px rgba(232,182,50,.45), 0 0 0 4px var(--card); }
[data-theme="dark"] .tab-center .fab { box-shadow: 0 6px 16px rgba(232,182,50,.3), 0 0 0 4px #081226; }
.tab-center .fab .ic { color: var(--navy) !important; width: 24px; height: 24px; }
.tab-center b { margin-top: 1px; }
@media (min-width: 700px) { .tabbar { max-width: 640px; margin: 0 auto; border-radius: 18px 18px 0 0; } }

/* ---------- v3: interaction, motion, accessibility ---------- */
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 10px; }
.tabbar a:focus-visible { outline-offset: -4px; }
a, button { touch-action: manipulation; }
.btn:active, .sbtn:active, .tile:active, .qcard:active, .hero:active, .community-cta:active, .mitem:active, .chip:active, .room:active,
.cat-tabs a:active, .icon-btn:active, .help a:active, .share-btn:active, .loc-pill:active { transform: scale(.975); filter: brightness(.97); }
.tile, .qcard, .hero, .community-cta, .mitem, .help a, .icon-btn, .nrow, .loc-pill { transition: transform .12s var(--ease), filter .15s, background .2s; }
.nrow:active { background: var(--card2); }
.icon-btn:hover { background: rgba(255,255,255,.12); }
#view.enter { animation: view-in .26s var(--ease) both; }
@keyframes view-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.fade-in { animation: fade-in .3s var(--ease) both; }
@keyframes fade-in { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
.skip-link { position: absolute; inset-inline-start: 8px; top: -60px; z-index: 120; background: var(--gold); color: var(--navy); padding: 10px 16px; border-radius: 10px; font-weight: 700; text-decoration: none; }
.skip-link:focus { top: 8px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* narrow phones (360 px class): keep the 4 news tabs on one row */
@media (max-width: 380px) {
  .cat-tabs { gap: 4px; }
  .cat-tabs a { padding: 5px 8px; font-size: 15px; }
  .cat-tabs a .ic { display: none; }
  .tiles { gap: 8px; }
  .tile b { font-size: 13.5px; }
  .qcard { padding: 10px; gap: 6px; }
  .qcard b.num { font-size: 24px; }
}

/* ---------- v3: feed status, verify flags, error state ---------- */
.feed-upd { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); margin: -4px 2px 10px; }
.feed-upd .ic { width: 15px; height: 15px; }
.feed-upd .dot { width: 7px; height: 7px; border-radius: 50%; background: #2e9b4f; flex: none; }
.feed-upd.is-sample .dot { background: #c0492f; }
.badge.verify { font-family: var(--lt); letter-spacing: .04em; background: #fff0c2; color: #7a4d00; border: 1px dashed #c98a00; font-weight: 700; font-size: 10.5px; line-height: 1.6; padding: 0 6px; }
[data-theme="dark"] .badge.verify { background: #3b2e05; color: var(--gold-light); border-color: #8a6a12; }
.help a { min-height: 56px; }
.help a .hl-n { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; }
.err-box { text-align: center; }

/* ---------- v3: document pages (About, Privacy) ---------- */
.doc { scroll-margin-top: calc(var(--hdr) + 10px); background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 18px 8px; margin-bottom: 14px; }
.doc h1 { font-family: var(--nq); font-weight: 400; font-size: 24px; line-height: 2.1; margin: 0 0 4px; color: var(--title); }
.doc h2 { font-family: var(--nq); font-weight: 400; font-size: 19px; line-height: 2.1; margin: 18px 0 2px; color: var(--title); display: flex; gap: 8px; align-items: baseline; }
.doc h2::before { content: ""; width: 4px; height: 18px; background: var(--gold); border-radius: 3px; align-self: center; }
.doc p, .doc li { font-size: 16px; line-height: 2; color: var(--ink); }
.doc p { margin: 0 0 10px; }
.doc ul, .doc ol { margin: 0 0 10px; padding-inline-start: 22px; }
.doc .meta { font-size: 13px; color: var(--muted); }
.doc[lang="en"], .doc [lang="en"] { direction: ltr; text-align: left; font-family: var(--lt); }
.doc[lang="en"] h1, .doc[lang="en"] h2 { font-family: var(--lt); font-weight: 700; font-size: 19px; line-height: 1.5; margin-top: 18px; }
.doc[lang="en"] h1 { font-size: 22px; }
.doc[lang="en"] p, .doc[lang="en"] li { font-size: 14.5px; line-height: 1.7; }
.doc[lang="en"] h2::before { display: none; }
.placeholder { background: #fff0c2; color: #6b4300; border: 1.5px dashed #c98a00; border-radius: 6px; padding: 0 6px; font-weight: 700; font-family: var(--lt); direction: ltr; unicode-bidi: isolate; white-space: nowrap; }
[data-theme="dark"] .placeholder { background: #3b2e05; color: var(--gold-light); border-color: #8a6a12; }
.pledge { display: flex; align-items: center; gap: 14px; border-radius: 18px; padding: 16px; margin: 6px 0 14px; color: #fff;
  background: radial-gradient(circle at 85% 0%, #2a64c4 0%, #0c2a60 55%, #081b40 100%); border: 1px solid rgba(232,182,50,.5); box-shadow: var(--shadow); }
.pledge .pc { flex: none; width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; background: var(--gold); color: var(--navy);
  font-family: var(--lt); font-weight: 800; font-size: 25px; direction: ltr; box-shadow: 0 0 0 5px rgba(232,182,50,.25); }
.pledge p { margin: 0; font-size: 16px; line-height: 1.95; color: #fff; }
.pledge small { display: block; color: #d6dfef; font-size: 12.5px; line-height: 1.6; font-family: var(--lt); direction: ltr; text-align: right; }
.doc-lang { display: flex; gap: 6px; margin: 0 0 12px; }
.doc-lang a { flex: 1; text-align: center; min-height: var(--tap); display: grid; place-items: center; border-radius: 12px; background: var(--card); box-shadow: var(--shadow); text-decoration: none; color: var(--title); font-size: 15px; }
.doc-links { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.doc-links .btn { margin: 0; font-size: 15px; }

/* ---------- v3: static pages (about.html / privacy.html opened directly) ---------- */
body.static { padding-bottom: 0; }
.static .topbar { position: sticky; top: 0; z-index: 40; }
.static-open { color: var(--navy); background: var(--gold); border-radius: 12px; padding: 0 14px; min-height: var(--tap); display: inline-flex; align-items: center; gap: 6px; text-decoration: none; font-weight: 700; font-size: 14.5px; }
.static-open .en { font-size: 11px; font-weight: 700; }
.static-main { max-width: 720px; margin: 0 auto; padding: 14px 14px 8px; }
.static-foot { text-align: center; font-size: 13px; color: var(--muted); padding: 8px 14px calc(22px + env(safe-area-inset-bottom)); }
.static-foot a { color: var(--link); display: inline-block; min-height: var(--tap); line-height: var(--tap); padding: 0 6px; }
.about-link { text-decoration: none; color: var(--ink); }
.pledge-mini { margin: 4px 0 0 !important; font-size: 13.5px !important; color: var(--title); background: var(--card2); border-radius: 10px; padding: 4px 10px; display: inline-block; }
.pledge-mini b { font-family: var(--lt); color: #b57800; }
[data-theme="dark"] .pledge-mini b { color: var(--gold-light); }
.pledge-mini .en { font-size: 11px; color: var(--muted); }
.toast { pointer-events: none; }
.toast.show { pointer-events: auto; }
.toast-btn { margin-inline-start: 10px; min-height: 36px; padding: 0 12px; border-radius: 10px; border: 0; background: var(--gold); color: var(--navy); font-weight: 700; cursor: pointer; }
/* English-language headlines inside the Urdu UI */
h1.lat, h2.lat, h3.lat, p.lat { font-family: var(--lt); font-weight: 700; letter-spacing: 0; text-align: start; }
.nrow h3.lat { font-size: 15px; line-height: 1.45; margin: 0 0 6px; }
.hero h2.lat { font-size: 19px; line-height: 1.4; margin: 8px 0 6px; }
.article h1.lat { font-size: 22px; line-height: 1.4; margin: 10px 16px 8px; }
p.lat { font-weight: 400; font-size: 15px; line-height: 1.6; }

/* ---------- villages weather (#/villages, #/village/<id>) ---------- */
.vx-search { position: sticky; top: calc(var(--hdr) + 6px); z-index: 5; display: flex; align-items: center; gap: 8px; background: var(--card); border-radius: 14px;
  padding: 0 12px; box-shadow: var(--shadow); border: 1.4px solid var(--line); margin-bottom: 8px; }
.vx-search:focus-within { border-color: var(--gold); }
.vx-search .ic { width: 20px; height: 20px; color: var(--muted); flex: none; }
.vx-search input { flex: 1; min-width: 0; min-height: 48px; border: 0; background: none; outline: none; font-size: 16px; }
.vx-search input::-webkit-search-cancel-button { cursor: pointer; }
.vx-meta { font-size: 12.5px; color: var(--muted); margin: 0 4px 8px; }
.vx-meta .note { margin-bottom: 6px; }
.vx-list { padding: 2px 12px; }
.vx-row { display: flex; align-items: center; gap: 10px; min-height: 60px; padding: 6px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.vx-row:last-child { border-bottom: 0; }
.vx-row svg.wx, .vx-noic { width: 38px; height: 38px; flex: none; }
.vx-noic { border-radius: 50%; background: var(--card2); }
.vx-n { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 8px; line-height: 1.6; }
.vx-n b { font-size: 17px; font-weight: 600; color: var(--title); }
.vx-n small { font-size: 11px; color: var(--muted); }
.vx-tag { font-style: normal; font-size: 10.5px; line-height: 1.7; padding: 0 7px; border-radius: 999px; background: var(--card2); color: var(--muted); align-self: center; }
.vx-w { display: flex; flex-direction: column; align-items: flex-end; text-align: end; line-height: 1.35; flex: none; }
.vx-w b { font-size: 19px; font-weight: 700; color: var(--title); }
.vx-w small { font-size: 11.5px; color: var(--muted); }
.vx-w .vx-d { color: var(--ink2); max-width: 8.5em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vx-w .rain { color: var(--link); }
.vx-row > .ic { width: 16px; height: 16px; color: var(--muted); flex: none; }
.vx-none { text-align: center; color: var(--muted); padding: 22px 8px; }
.vx-link { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); border-inline-start: 4px solid var(--gold); padding: 10px 14px; }
.vx-link > .ic:first-child { width: 22px; height: 22px; color: var(--gold); flex: none; }
.vx-link span { flex: 1; display: flex; flex-direction: column; line-height: 1.6; }
.vx-link b { font-weight: 600; color: var(--title); } .vx-link small { font-size: 12.5px; color: var(--muted); }
.vx-link > .ic:last-child { width: 16px; height: 16px; color: var(--muted); }
a.back { text-decoration: none; }
.vx-w .vx-hl { white-space: nowrap; }
.vx-w .vx-hl b { font-size: inherit; font-weight: 700; color: var(--ink2); }
.page-h .back-btn { align-self: center; flex: none; }

/* v0.5.5 web push button */
.notify-btn { background: linear-gradient(135deg, var(--gold), #f4c95d); color: var(--navy); font-weight: 700; font-size: 17px; box-shadow: 0 4px 14px rgba(0,0,0,.12); margin: 4px 0 14px; }
.notify-btn[data-state="on"] { background: var(--card); color: var(--title); border: 1.4px solid var(--line); box-shadow: none; font-weight: 600; font-size: 15px; }
.notify-btn[data-state="denied"], .notify-btn[data-state="unsupported"] { background: var(--card2); color: var(--muted); box-shadow: none; }
