@font-face { font-family: "GoArabic"; src: url(/site/fonts/NotoSansArabicUI-Regular.woff2) format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "GoArabic"; src: url(/site/fonts/NotoSansArabicUI-Bold.woff2) format("woff2"); font-weight: 700; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "AmiriQuran"; src: url(/app-data/fonts/AmiriQuran.ttf) format("truetype"); font-display: swap; }
/* s29: the Android app's s25 design tokens (mobile/lib/ui/tokens.dart). Colours carry MEANING:
   primary green = the action / the way, danger red = SOS / real danger only, warning amber = attention (black text),
   neutral = everything else. Sun mode (high contrast, the default for new visitors) = white / black, every text pair >= 7:1.
   Type: caption 14 (meta only) · body 18 · label 20 · title 24 · display 44 · giant 120 (the lap number only).
   Taps: min 48 · primary 56 · hero 72. */
:root {
  --primary: #0B6E4F; --on-primary: #fff; --primary-soft: #E3F1EA;
  --danger: #B71C1C; --on-danger: #fff; --danger-soft: #FFEBEE;
  --warning: #FFB300; --on-warning: #000; --warning-soft: #FFF4D6; --warning-ink: #7A4A00;
  --ink: #111; --ink-muted: #424242; --line: #BDBDBD; --edge: 1px; --surface: #fff; --surface-alt: #F3F4F2;
  --night: #0A0A0A; --gold: #D4AF5F;
  --t-caption: 14px; --t-body: 18px; --t-label: 20px; --t-title: 24px; --t-display: 44px; --t-giant: 120px;
  --s-xs: 4px; --s-s: 8px; --s-m: 12px; --s-l: 16px; --s-xl: 24px; --s-xxl: 32px;
  --r-s: 10px; --r-m: 16px; --r-l: 22px;
  --tap-min: 48px; --tap-primary: 56px; --tap-hero: 72px;
  --tabh: 68px; --barh: 52px;
}
body.sun {
  --primary: #00402C; --primary-soft: #fff; --danger: #8E0000; --danger-soft: #fff; --warning-soft: #fff; --warning-ink: #000;
  --ink: #000; --ink-muted: #000; --line: #000; --edge: 2px; --surface-alt: #fff;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body { font: var(--t-body)/1.5 system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, "GoArabic", sans-serif; color: var(--ink);
  background: var(--surface-alt); display: flex; flex-direction: column; overscroll-behavior: none; }
body:lang(ar) { font-family: "GoArabic", system-ui, "Segoe UI", Tahoma, sans-serif; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--primary); }
:focus-visible { outline: 3px solid var(--warning); outline-offset: 2px; }
.bar { height: calc(var(--barh) + env(safe-area-inset-top)); flex: none; display: flex; align-items: center; gap: var(--s-s); padding: 0 var(--s-m);
  padding-top: env(safe-area-inset-top); background: var(--night); color: #fff; }
.bar .logo img { display: block; height: 32px; width: auto; }
.grow { flex: 1; }
.chip { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; min-height: 40px; padding: 6px 14px; font-size: 16px; font-weight: 700;
  text-decoration: none; border: var(--edge) solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; white-space: nowrap; }
.chip.gold { background: var(--gold); border-color: var(--gold); color: #111; }
.chip.on { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
#lang { background: #1c1b18; color: #fff; border: 1px solid #777; border-radius: var(--r-s); min-height: 40px; padding: 4px 6px; font-size: 16px; }
@media (max-width: 400px) { #getApk { display: none; } }
/* one status line (s25 MapStatusLine): the most important item only, "+N" opens the rest */
#status { flex: none; display: flex; align-items: center; gap: var(--s-s); min-height: 44px; padding: 4px var(--s-m); font-size: 16px; font-weight: 700;
  background: var(--surface); color: var(--ink); border-bottom: var(--edge) solid var(--line); }
#status .txt { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#status .ico { flex: none; width: 12px; height: 12px; border-radius: 50%; background: var(--primary); }
#status.k-danger { background: var(--danger); color: var(--on-danger); border-color: var(--danger); } #status.k-danger .ico { background: #fff; }
#status.k-warning { background: var(--warning); color: var(--on-warning); border-color: var(--warning); } #status.k-warning .ico { background: #000; }
#status .act { flex: none; min-height: 36px; padding: 4px 12px; border-radius: 999px; border: 2px solid currentColor; background: transparent; font-weight: 800; cursor: pointer; color: inherit; text-decoration: none; display: inline-flex; align-items: center; }
#status .more { flex: none; min-height: 36px; min-width: 44px; border-radius: 999px; border: 0; background: rgba(0,0,0,.12); font-weight: 800; cursor: pointer; color: inherit; }
.stlist { list-style: none; margin: 0; padding: 0; }
.stlist li { display: flex; gap: var(--s-s); align-items: center; padding: var(--s-m) 0; border-bottom: var(--edge) solid var(--line); }
main { flex: 1; min-height: 0; overflow: auto; position: relative; -webkit-overflow-scrolling: touch; }
main.full { overflow: hidden; }
/* bottom bar (s25 HomeNavBar): one short word per tab, the selected tab = green pill + green top bar + bold label */
.tabs { flex: none; height: calc(var(--tabh) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); display: flex;
  background: var(--surface); border-top: var(--edge) solid var(--line); }
.tabs a { flex: 1; min-width: 0; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  text-decoration: none; color: var(--ink-muted); font-size: 15px; font-weight: 600; }
.tabs a span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 2px; }
.tabs svg { width: 32px; height: 32px; fill: currentColor; padding: 2px 12px; box-sizing: content-box; border-radius: 16px; }
.tabs a.on { color: var(--primary); font-weight: 800; }
.tabs a.on::before { content: ""; position: absolute; top: 0; inset-inline: 18%; height: 3px; border-radius: 0 0 3px 3px; background: var(--primary); }
.tabs a.on svg { background: var(--primary-soft); outline: var(--edge) solid var(--primary); outline-offset: -1px; }
body:not(.sun) .tabs a.on svg { outline: 0; }
.tabs a .dot { position: absolute; top: 8px; inset-inline-end: calc(50% - 26px); width: 12px; height: 12px; border-radius: 50%; background: var(--danger); border: 2px solid var(--surface); }
.page { max-width: 760px; margin: 0 auto; padding: var(--s-l) var(--s-l) var(--s-xxl); }
.page h1 { font-size: var(--t-title); line-height: 1.25; margin: 4px 0 var(--s-m); }
.page h2 { font-size: var(--t-label); margin: var(--s-xl) 0 var(--s-s); }
.card { background: var(--surface); border: var(--edge) solid var(--line); border-radius: var(--r-m); padding: var(--s-l); margin: 0 0 var(--s-m); }
.small { font-size: var(--t-caption); color: var(--ink-muted); }
.note { background: var(--warning-soft); border: 1.5px solid var(--warning); color: var(--ink); border-radius: var(--r-s); padding: var(--s-m); font-size: 16px; margin: 0 0 var(--s-m); }
body.sun .note { border-width: 2px; }
.note.ok { background: var(--primary-soft); border-color: var(--primary); }
.note.warn { background: var(--danger-soft); border-color: var(--danger); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: var(--tap-primary); padding: 10px 20px; border-radius: var(--r-m);
  border: 0; font-weight: 700; font-size: var(--t-label); line-height: 1.2; cursor: pointer; text-decoration: none; background: var(--primary); color: var(--on-primary); }
.btn.alt { background: var(--surface); color: var(--primary); border: 2px solid var(--primary); }
.btn.sos, .btn.danger { background: var(--danger); color: var(--on-danger); }
.btn.warn { background: var(--warning); color: var(--on-warning); }
.btn.hero { min-height: var(--tap-hero); font-size: 22px; }
.btn.block { display: flex; width: 100%; }
.btn.sm { min-height: var(--tap-min); font-size: 17px; padding: 6px 14px; }
.btn:disabled { opacity: .45; cursor: default; }
.row { display: flex; gap: var(--s-s); flex-wrap: wrap; align-items: center; }
.row > .btn { flex: 1 1 auto; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-s); }
label { display: block; font-weight: 600; margin: 0 0 var(--s-s); }
input[type=text], input[type=tel], input[type=search], input[type=number], select.inp, textarea { width: 100%; min-height: var(--tap-min); padding: 12px 14px; border-radius: var(--r-s);
  border: var(--edge) solid var(--line); background: var(--surface); font-size: var(--t-body); font-weight: 400; margin-top: 4px; }
body.sun input[type=text], body.sun input[type=tel], body.sun input[type=search], body.sun textarea { border-width: 2px; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { border-bottom: var(--edge) solid var(--line); }
.list li:last-child { border-bottom: 0; }
.list a.btn, .list button.btn { display: inline-flex; width: auto; flex: none; min-height: var(--tap-min); padding: 6px 16px; }
.list a, .list button { display: flex; width: 100%; min-height: var(--tap-primary); gap: 12px; align-items: center; padding: 10px 6px; color: inherit; text-decoration: none;
  background: none; border: 0; text-align: start; cursor: pointer; font-size: var(--t-body); }
.badge { display: inline-block; font-size: 14px; font-weight: 700; border-radius: 6px; padding: 1px 8px; background: var(--surface-alt); color: var(--ink); border: 1px solid var(--line); vertical-align: middle; }
.badge.ok { background: var(--primary-soft); color: var(--primary); border-color: var(--primary); }
.badge.rv { background: var(--warning-soft); color: var(--ink); border-color: var(--warning); }
.num { flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-weight: 800; border: var(--edge) solid var(--primary);
  display: inline-flex; align-items: center; justify-content: center; }
.ar { font-family: "AmiriQuran", "GoArabic", serif; direction: rtl; font-size: 28px; line-height: 2; text-align: right; }
.translit { font-style: italic; color: var(--ink-muted); }
/* dua card ▶ */
.play { display: inline-flex; align-items: center; gap: 8px; min-height: var(--tap-primary); padding: 6px 18px 6px 12px; border-radius: 999px; border: 2px solid var(--primary);
  background: var(--surface); color: var(--primary); font-weight: 800; font-size: 18px; cursor: pointer; }
.play svg { width: 30px; height: 30px; fill: currentColor; }
.play.on { background: var(--primary); color: var(--on-primary); }
.play .bar2 { width: 70px; height: 6px; border-radius: 3px; background: var(--primary-soft); overflow: hidden; border: 1px solid currentColor; }
.play .bar2 i { display: block; height: 100%; width: 0; background: currentColor; }
.hub { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-s); margin: 0 0 var(--s-m); }
.hub a { display: flex; flex-direction: column; gap: 6px; justify-content: center; min-height: 96px; padding: var(--s-m); border-radius: var(--r-m); text-decoration: none;
  background: var(--surface); color: var(--ink); border: var(--edge) solid var(--line); font-weight: 800; font-size: var(--t-label); }
.hub a svg { width: 32px; height: 32px; fill: var(--primary); }
.hub a.main { grid-column: 1 / -1; background: var(--primary); color: var(--on-primary); border-color: var(--primary); }
.hub a.main svg { fill: var(--on-primary); }
.hub a small { font-size: var(--t-caption); font-weight: 600; color: inherit; opacity: .9; }
/* map */
#map { position: absolute; inset: 0; }
.mapui { position: absolute; inset-inline: 8px; top: 8px; z-index: 2; display: grid; gap: 6px; pointer-events: none; }
.mapui > * { pointer-events: auto; }
.search { position: relative; }
.search input { box-shadow: 0 2px 10px rgba(0,0,0,.2); padding-inline-start: 16px; margin: 0; }
.results { background: var(--surface); border-radius: var(--r-s); box-shadow: 0 6px 18px rgba(0,0,0,.18); max-height: 46vh; overflow: auto; border: var(--edge) solid var(--line); }
.results button { display: block; width: 100%; min-height: var(--tap-min); text-align: start; padding: 10px 14px; border: 0; border-bottom: 1px solid var(--line); background: var(--surface); cursor: pointer; }
.results small { display: block; color: var(--ink-muted); font-size: var(--t-caption); }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.chips .chip { box-shadow: 0 1px 5px rgba(0,0,0,.2); }
.fab { position: absolute; inset-inline-end: 10px; z-index: 2; width: 56px; height: 56px; border-radius: var(--r-m); border: var(--edge) solid var(--line); background: var(--surface);
  box-shadow: 0 2px 10px rgba(0,0,0,.25); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.fab svg { width: 30px; height: 30px; fill: var(--primary); }
.fab.on { background: var(--primary); } .fab.on svg { fill: var(--on-primary); }
.sheet { position: absolute; inset-inline: 0; bottom: 0; z-index: 3; background: var(--surface); border-radius: var(--r-l) var(--r-l) 0 0; box-shadow: 0 -4px 18px rgba(0,0,0,.18);
  padding: var(--s-m) var(--s-l) var(--s-l); max-height: 60%; overflow: auto; border-top: var(--edge) solid var(--line); }
.sheet h3 { margin: 0 48px 4px 0; font-size: var(--t-title); }
.sheet .x { position: absolute; inset-inline-end: 6px; top: 4px; width: 48px; height: 48px; border: 0; background: none; font-size: 30px; color: var(--ink-muted); cursor: pointer; }
.sheet .row { margin: var(--s-s) 0; }
.maplibregl-ctrl-attrib { font-size: 12px; }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--tabh) + 16px); z-index: 50; background: #111; color: #fff; padding: 12px 18px;
  border-radius: var(--r-s); max-width: 90vw; font-size: 17px; }
/* counter (s25): giant number of the lap you are walking + one full-width "done" button */
.counter { text-align: center; }
.counter .big { font-size: var(--t-giant); font-weight: 800; line-height: 1; color: var(--primary); margin: var(--s-s) 0 0; font-variant-numeric: tabular-nums; }
.counter .of { font-size: var(--t-label); color: var(--ink-muted); font-weight: 600; }
.dots { display: flex; justify-content: center; gap: 10px; margin: var(--s-m) 0; }
.dots i { width: 24px; height: 24px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line); display: inline-block; }
.dots i.d { background: var(--primary); border-color: var(--primary); }
.dots i.c { border-color: var(--primary); border-width: 3px; }
.plus { width: 100%; min-height: 96px; font-size: 28px; border-radius: var(--r-l); }
.ask { background: var(--warning); color: var(--on-warning); border-radius: var(--r-m); padding: var(--s-l); margin: var(--s-m) 0; text-align: center; }
.ask b { display: block; font-size: var(--t-title); margin-bottom: var(--s-m); }
.ask .row .btn { min-height: var(--tap-hero); font-size: 24px; }
.seg { display: flex; background: var(--surface); border: var(--edge) solid var(--line); border-radius: var(--r-m); padding: 4px; gap: 4px; margin: 0 0 var(--s-m); }
.seg button { flex: 1; min-height: var(--tap-min); border: 0; background: none; padding: 8px; border-radius: var(--r-s); font-weight: 700; font-size: 18px; cursor: pointer; color: var(--ink-muted); }
.seg button.on { background: var(--primary); color: var(--on-primary); }
.laps { text-align: start; font-size: 16px; color: var(--ink-muted); }
details.more > summary { min-height: var(--tap-min); display: flex; align-items: center; font-weight: 700; cursor: pointer; color: var(--primary); }
/* prayer */
.ptable { width: 100%; border-collapse: collapse; }
.ptable td { padding: 12px 6px; border-bottom: var(--edge) solid var(--line); font-size: var(--t-body); }
.ptable td.tm { text-align: end; font-weight: 700; font-variant-numeric: tabular-nums; direction: ltr; }
.ptable tr.next td { background: var(--primary-soft); font-weight: 800; }
.ptable tr.past td { color: var(--ink-muted); }
.nextp { font-size: var(--t-title); font-weight: 800; color: var(--primary); }
/* quran */
.sura-list .ar-name { font-family: "GoArabic", serif; font-size: 20px; margin-inline-start: auto; }
.aya { font-family: "AmiriQuran", serif; direction: rtl; text-align: justify; font-size: 28px; line-height: 2.25; }
.aya .n { font-size: 22px; color: var(--ink-muted); }
.basmala { text-align: center; font-family: "AmiriQuran", serif; font-size: 28px; direction: rtl; margin: 6px 0 12px; }
/* guide board (s27) */
.brow { display: flex; gap: var(--s-m); align-items: center; width: 100%; min-height: 64px; padding: 10px 8px; border: 0; border-bottom: var(--edge) solid var(--line);
  background: none; text-align: start; cursor: pointer; font-size: var(--t-body); color: var(--ink); }
.brow .st { flex: none; width: 14px; align-self: stretch; border-radius: 7px; background: var(--primary); }
.brow .st.k-danger { background: var(--danger); } .brow .st.k-warning { background: var(--warning); } .brow .st.k-muted { background: var(--line); }
.brow .who { flex: 1; min-width: 0; }
.brow .who b { display: block; font-size: var(--t-label); }
.brow .meta { font-size: 16px; color: var(--ink-muted); }
.brow .dist { flex: none; text-align: end; font-weight: 800; font-size: var(--t-label); }
.brow .dist .arr { display: inline-block; font-size: 22px; }
.brow.sos { background: var(--danger-soft); }
.counts { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 var(--s-s); }
.radius { display: flex; gap: 6px; flex-wrap: wrap; }
.radius .chip { min-height: var(--tap-min); font-size: 18px; }
/* SOS alarm (guide, while the page is open): full-screen red */
#alarm { position: fixed; inset: 0; z-index: 100; background: #B71C1C; color: #fff; display: flex; flex-direction: column; justify-content: center; gap: var(--s-l);
  padding: var(--s-xl); text-align: center; animation: pulse 1s infinite alternate; }
#alarm h2 { font-size: var(--t-display); margin: 0; line-height: 1.1; }
#alarm p { font-size: var(--t-label); margin: 0; }
#alarm .btn { background: #fff; color: #8E0000; min-height: var(--tap-hero); font-size: 26px; }
#alarm .btn.alt2 { background: transparent; color: #fff; border: 3px solid #fff; }
@keyframes pulse { from { background: #B71C1C; } to { background: #7F0000; } }
@media (prefers-reduced-motion: reduce) { #alarm { animation: none; } }
/* hold to confirm (s25 HoldToConfirm, 2 s) */
.hold { position: relative; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; }
.hold .fill { position: absolute; inset: 0; width: 0; background: rgba(255,255,255,.35); pointer-events: none; }
.hold > span { position: relative; }
@media (min-width: 900px) { .page { padding-top: var(--s-xl); } }
/* s31: live dua on the counter */
.livedua { border: 2px solid var(--primary); text-align: start; }
.livedua .ar { font-size: 32px; text-align: center; margin: 6px 0; }
.segs { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.segs button { flex: 1 1 40%; min-height: 48px; border-radius: var(--r-m); border: var(--edge) solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-weight: 700; }
.segs button.on { background: var(--primary); color: #fff; border-color: var(--primary); }
