@font-face {
  font-family: Geist;
  src: url("assets/fonts/geist-sans.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Geist Serif";
  src: url("assets/fonts/geist-serif.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("assets/fonts/geist-mono.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
:root {
  font-family: Geist, "Segoe UI", sans-serif;
  background: #142f31;
  --reading-white: #f8f5e9;
  --reading-mint: #d1e8d9;
}
#glass-landscape {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 65%;
}

html .atmosphere .reading-shade {
  background: linear-gradient(180deg,rgba(9,31,37,.82),rgba(15,43,44,.82) 52%,rgba(18,47,48,.49)),linear-gradient(90deg,#122e3040,transparent);
}
html[data-dayphase="night"] .atmosphere .reading-shade {
  background: linear-gradient(175deg,#0c222ce8,#112d31da 58%,#16363585);
}
.app {
  width: min(100%, 720px);
  height: var(--app-height, 100dvh);
  padding: 0 clamp(20px,5vw,44px) max(12px,env(safe-area-inset-bottom));
}
.app .header {
  height: calc(76px + env(safe-area-inset-top));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.header .wordmark {
  position: static;
  order: -1;
  transform: none;
  width: auto;
  height: 44px;
  gap: 7px;
  font: 530 26px/1 "Geist Serif", Georgia, serif;
  letter-spacing: -.055em;
}
.header .wordmark img { width: 26px; height: 26px; }
.header .profile-link {
  position: static;
  margin-left: auto;
  order: 2;
  width: 44px;
  height: 44px;
  border-color: #d0ede02e;
  background: #eaf8ef0d;
}
.header .island-shell {
  z-index: 15;
  left: auto;
  right: 54px;
  top: calc(16px + env(safe-area-inset-top));
  width: 102px;
  transform: none;
  border-radius: 22px;
  background: #203735d9;
  border-color: #e2f5e236;
  box-shadow: inset 0 1px #f3fff012;
}
.header .island-shell.is-open {
  width: min(100%, 385px);
  right: 0;
  background: #203735fa;
  border-radius: 23px;
}
.header .day-island { height: 42px; gap: 9px; }
.header .island-chevron { display: flex; }
.header #headerTime { font: 550 15px/1 Geist,sans-serif; }
.header .island-shell.is-open #headerTime { font-size: 19px; }
.header .island-shell.is-open #headerDate { line-height: 1.3; white-space: normal; }
html[data-page="quran"] .header .island-shell { background: #f1f3eaf5; }
.today .feed-slide {
  padding-block: 24px 56px;
}
.today .reading { animation: none; color: var(--reading-white); }
.today .reading-heading { justify-content: flex-start; }
.today .reading-heading h1 { letter-spacing: normal; text-transform: none; font: 500 13px/1.3 Geist, sans-serif; }
.today .reading-topic {
  padding: 0 14px;
  font: inherit;
  color: var(--reading-mint);
  border: 1px solid #def4df3b;
  background: #182f32a6;
  gap: 8px;
}
.today .reading-topic span:nth-child(3) { opacity: 1; letter-spacing: 0; }
.today .reading article {
  padding: clamp(14px,2.5vh,28px) 0 0;
  text-align: start;
}
.today .arabic {
  color: #f7f2df;
  font: 400 clamp(28px,4.8vw,42px)/1.83 Amiri,serif;
  text-align: right;
  text-shadow: none;
}
.today .verse-divider {
  display: block;
  width: 35px;
  height: 1px;
  background: #badccc85;
  margin: clamp(11px,2vh,23px) 0;
}
.today .verse-divider > * { display: none; }
.today .translation {
  color: var(--reading-white);
  font: 430 clamp(27px,4.9vw,40px)/1.22 "Geist Serif", Georgia, serif;
  letter-spacing: -.032em;
  text-align: left;
  text-shadow: none;
}
.today .verse-meta {
  min-height: 0;
  align-items: flex-start;
  margin-top: 17px;
  gap: 6px;
}
.today .reference { font: 540 13px/1.4 Geist,sans-serif; color: #deecdf; }
.today .meal-source { font: 400 11px/1.5 Geist,sans-serif; color: #bfd0c7; }
.today .verse-actions {
  position: static;
  display: flex;
  justify-content: flex-start;
  width: auto;
  height: auto;
  opacity: 1;
  visibility: visible;
  transform: none;
  margin-top: 20px;
  padding: 0;
  gap: 8px;
  border: 0;
  background: none;
  box-shadow: none;
  backdrop-filter: none;
}
.today .reading:not(#verseWrap)::after { content: ""; display: block; height: 64px; }
.today .save-button,.today .share-button {
  flex: none;
  height: 44px;
  min-width: 44px;
  border: 1px solid #e2f1e533;
  border-radius: 22px;
  color: #ecf5e9;
  background: #1b3334b3;
}
.today .save-button { order: -1; padding-inline: 16px; }
.today .save-button[aria-pressed="true"] { background: #c9e7d8; color: #15392e; }
.today .save-button svg,.today .share-button svg { width: 17px; height: 17px; }
.today .feed-hint { color: #e3ebe3; bottom: 6px; flex-direction: row; gap: 8px; }
.today .feed-hint span:last-child { animation: none; }
.app .bottom-dock { width: min(100%,448px); margin-top: 5px; }
.app #dockNav {
  isolation: isolate;
  padding: 5px;
  width: 100%;
  background: linear-gradient(135deg,#27423fcf,#112727cf);
  border: 1px solid #ddf2e141;
  box-shadow: inset 0 1px #f7fff41a,0 6px 22px #0d252831;
  backdrop-filter: blur(16px) saturate(1.15);
}
#dockNav a { z-index: 1; color: #e1eee4; font-size: 11px; font-weight: 500; }
#dockNav a[aria-current="page"] { background: #b2deca33; color: #e0f9e8; box-shadow: inset 0 1px #f4ffef22; }
html[data-page="quran"] .app #dockNav { background: linear-gradient(135deg,#fcfaf3ec,#e2e9dfee); border-color: #63755b58; }
html[data-page="quran"] #dockNav a { color: #465844; }
html[data-page="quran"] #dockNav a[aria-current="page"] { background: #47694e20; color: #294c37; }
#liquid-nav-surface { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; }
@media (max-height: 700px) {
  .app .header { height: calc(62px + env(safe-area-inset-top)); }
  .header .island-shell { top: calc(9px + env(safe-area-inset-top)); }
  .today .feed-slide { padding-block: 14px 36px; }
}
@media (prefers-reduced-transparency: reduce) {
  .app #dockNav,.header .island-shell { backdrop-filter: none; background: #203937; }
}

html[data-page]:not([data-page="today"]) .header,
html[data-page]:not([data-page="today"]) .profile-link {
  color: var(--lp-ink);
}
html[data-page]:not([data-page="today"]) .profile-link {
  background: var(--lp-glass);
  border-color: var(--lp-line);
}
html[data-page]:not([data-page="today"]) .header .island-shell,
html[data-page]:not([data-page="today"]) .app #dockNav {
  color: var(--lp-ink);
  background: var(--lp-glass);
  border-color: var(--lp-line);
}
html[data-page]:not([data-page="today"]) .header .island-shell :is(#headerDate,.prayer-place,.island-panel-heading,.island-panel-heading button,.island-chevron svg,.island-prayer-item span,.island-source) { color: var(--lp-muted); }
html[data-page]:not([data-page="today"]) .header .island-shell :is(#nextPrayer,.island-prayer-item strong,.island-status,.island-retry) { color: var(--lp-ink); }
html[data-page]:not([data-page="today"]) .header .island-prayer-item { background: var(--lp-surface); border-color: var(--lp-line); }
html[data-page]:not([data-page="today"]) .header .island-prayer-item.next { background: var(--lp-tint); }
html[data-page]:not([data-page="today"]) #dockNav a { color: var(--lp-muted); }
html[data-page]:not([data-page="today"]) #dockNav a[aria-current="page"] { background: var(--lp-tint); color: var(--lp-accent); }
html[data-page]:not([data-page="today"]) .header .wordmark img { filter: brightness(0); }
html:is([data-dayphase="night"],[data-dayphase="twilight"])[data-page]:not([data-page="today"]) .header .wordmark img { filter: brightness(0) invert(1); }

.bottom-dock :is(.dock-menu, .verse-actions) {
  background: linear-gradient(135deg,#27423fe8,#112727df);
  color: var(--reading-white);
  border-color: #ddf2e141;
}
.bottom-dock .save-button { background: #cce7d7; color: #16392e; }
.bottom-dock .save-button[aria-pressed="true"] { background: #38594c; color: #f2faef; }
.bottom-dock .share-button { color: var(--reading-white); }
.app .bottom-dock[data-mode="actions"] #dockNav { width: 62px; }

/* Keep the reading scrollable while the navigation stays inside the viewport. */
html, body { height: 100%; min-height: 0; overflow: hidden; }
.app {
  height: 100vh;
  height: 100svh;
  height: var(--app-height, 100dvh);
  padding-bottom: calc(16px + max(32px, env(safe-area-inset-bottom, 0px)));
  overflow: hidden;
}
.app main { min-height: 0; }
html[data-page="today"] main { scroll-snap-type: none; scroll-padding: 24px; overflow-anchor: auto; }
.today { display: flex; flex-direction: column; justify-content: center; justify-content: safe center; padding: 24px 0 32px; min-height: 100%; }
.today .reading { flex-shrink: 0; }
.app .bottom-dock { flex: 0 0 62px; }

.app .bottom-dock[data-mode="actions"] { width: min(100%, 220px); }
.bottom-dock[data-mode="actions"] .verse-actions { justify-content: center; }
