:root {
  --oa-bg: #f7f4ee;
  --oa-surface: #fffdf9;
  --oa-surface-2: #f0ebe2;
  --oa-ink: #211b16;
  --oa-muted: #74695d;
  --oa-line: rgba(74, 55, 34, 0.13);
  --oa-gold: #a7772f;
  --oa-gold-2: #c89b50;
  --oa-gold-soft: #f0e4cf;
  --oa-deep: #2a1d15;
  --oa-red: #7d2d2d;
  --oa-green: #2e6b46;
  --oa-radius: 24px;
  --oa-radius-sm: 16px;
  --oa-shadow: 0 16px 44px rgba(47, 35, 24, 0.09);
  --oa-dock-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body.orthodox-app,
body.app-page {
  margin: 0;
  min-height: 100vh;
  background: var(--oa-bg);
  color: var(--oa-ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  padding-bottom: calc(var(--oa-dock-h) + 24px);
}
button, input, select { font: inherit; }
a { color: inherit; }

.oa-page {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 40px;
}

.oa-topbar {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}
.oa-brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
.oa-brand img { width: 34px; height: 42px; object-fit: contain; }
.oa-brand-copy { display: grid; gap: 1px; }
.oa-brand-copy strong { font-family: Georgia, "Times New Roman", serif; font-size: 1.1rem; font-weight: 600; }
.oa-brand-copy span { font-size: .72rem; color: var(--oa-muted); letter-spacing: .12em; text-transform: uppercase; }
.oa-top-actions { display: flex; align-items: center; gap: 8px; }
.oa-icon-button,
.oa-pill-button {
  border: 1px solid var(--oa-line);
  background: rgba(255,253,249,.88);
  color: var(--oa-ink);
  min-height: 42px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  text-decoration: none;
  cursor: pointer;
}
.oa-icon-button { width: 42px; padding: 0; }
.oa-icon-button svg, .oa-pill-button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.oa-icon-button:hover, .oa-pill-button:hover { background: var(--oa-gold-soft); }

.oa-eyebrow { margin: 0 0 7px; color: var(--oa-gold); font-size: .76rem; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; }
.oa-section-title { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.55rem, 3vw, 2.15rem); font-weight: 600; line-height: 1.1; }
.oa-section-subtitle { margin: 8px 0 0; max-width: 640px; color: var(--oa-muted); line-height: 1.6; }
.oa-section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin: 34px 0 15px; }
.oa-section-link { color: var(--oa-gold); text-decoration: none; font-size: .9rem; font-weight: 650; white-space: nowrap; }

.oa-hero {
  position: relative;
  min-height: 390px;
  border-radius: 30px;
  overflow: hidden;
  color: white;
  background: #2e241c;
  box-shadow: var(--oa-shadow);
  isolation: isolate;
}
.oa-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(18,14,11,.86) 0%, rgba(18,14,11,.58) 48%, rgba(18,14,11,.22) 100%),
              linear-gradient(0deg, rgba(18,14,11,.46), transparent 60%);
}
.oa-hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.oa-hero-content { min-height: 390px; width: min(610px, 100%); display: flex; flex-direction: column; justify-content: end; padding: clamp(28px, 5vw, 58px); }
.oa-hero-kicker { margin: 0 0 10px; font-size: .78rem; letter-spacing: .15em; text-transform: uppercase; color: #f3d7a4; font-weight: 700; }
.oa-hero h1 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(2.35rem, 6vw, 4.6rem); line-height: .98; font-weight: 500; }
.oa-hero p { margin: 16px 0 0; color: rgba(255,255,255,.82); font-size: clamp(.96rem, 2vw, 1.1rem); line-height: 1.6; }
.oa-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.oa-primary,
.oa-secondary {
  min-height: 46px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 18px;
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
}
.oa-primary { background: #fff9ef; color: #332218; }
.oa-secondary { background: rgba(255,255,255,.11); color: white; border-color: rgba(255,255,255,.34); backdrop-filter: blur(8px); }
.oa-primary svg, .oa-secondary svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.9; }

.oa-quick-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.oa-quick-card {
  border: 1px solid var(--oa-line);
  background: var(--oa-surface);
  border-radius: 20px;
  min-height: 128px;
  padding: 18px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.oa-quick-card:hover { transform: translateY(-3px); border-color: rgba(167,119,47,.36); background: #fffaf2; }
.oa-quick-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 13px; background: var(--oa-gold-soft); color: var(--oa-gold); }
.oa-quick-icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.oa-quick-card strong { display: block; font-size: .98rem; }
.oa-quick-card span { display: block; margin-top: 4px; color: var(--oa-muted); font-size: .78rem; }

.oa-card-row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(245px, 30%); gap: 14px; overflow-x: auto; padding: 2px 2px 10px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.oa-media-card { position: relative; min-height: 210px; border-radius: 22px; overflow: hidden; color: white; text-decoration: none; background: #32251d; scroll-snap-align: start; isolation: isolate; }
.oa-media-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.oa-media-card::after { content:""; position:absolute; inset:0; background: linear-gradient(0deg, rgba(21,14,10,.9), rgba(21,14,10,.08) 72%); z-index:-1; }
.oa-media-card-content { position: absolute; inset: auto 18px 17px; }
.oa-media-card .oa-tag { display:inline-flex; align-items:center; min-height:24px; padding:0 9px; border-radius:999px; background:rgba(255,255,255,.16); backdrop-filter: blur(6px); font-size:.68rem; text-transform:uppercase; letter-spacing:.08em; margin-bottom:8px; }
.oa-media-card h3 { margin:0; font-family: Georgia, "Times New Roman", serif; font-size:1.35rem; font-weight:600; }
.oa-media-card p { margin:5px 0 0; font-size:.78rem; color:rgba(255,255,255,.76); }

.oa-feature-grid { display: grid; grid-template-columns: 1.35fr .65fr; gap: 16px; }
.oa-feature-card { border: 1px solid var(--oa-line); background: var(--oa-surface); border-radius: 24px; overflow: hidden; text-decoration: none; min-height: 250px; position: relative; }
.oa-feature-card-image { height: 138px; overflow: hidden; background: var(--oa-surface-2); }
.oa-feature-card-image img { width:100%; height:100%; object-fit:cover; display:block; }
.oa-feature-card-body { padding: 18px; }
.oa-feature-card-body h3 { margin:0; font-family: Georgia,"Times New Roman",serif; font-size:1.35rem; }
.oa-feature-card-body p { margin:7px 0 0; color:var(--oa-muted); font-size:.86rem; line-height:1.5; }
.oa-feature-card.dark { background: var(--oa-deep); color:white; border-color: transparent; }
.oa-feature-card.dark .oa-feature-card-body p { color:rgba(255,255,255,.68); }

.oa-dock {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  width: min(620px, calc(100% - 22px));
  min-height: var(--oa-dock-h);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  padding: 8px;
  border: 1px solid rgba(64,46,29,.13);
  border-radius: 24px;
  background: rgba(255,253,249,.94);
  backdrop-filter: blur(18px);
  box-shadow: 0 16px 44px rgba(43,31,21,.16);
  z-index: 1000;
}
.oa-dock-link { min-width:0; color:#827668; text-decoration:none; border-radius:16px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:4px; font-size:.67rem; font-weight:650; }
.oa-dock-link svg { width:21px; height:21px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.oa-dock-link.is-active { color:var(--oa-gold); background:var(--oa-gold-soft); }

.oa-simple-hero { display:flex; justify-content:space-between; align-items:end; gap:24px; padding:18px 0 12px; }
.oa-simple-hero h1 { margin:0; font-family:Georgia,"Times New Roman",serif; font-size:clamp(2.2rem,5vw,4rem); font-weight:500; line-height:1; }
.oa-simple-hero p { margin:10px 0 0; max-width:620px; color:var(--oa-muted); line-height:1.6; }

.oa-calendar-choice-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin-top:26px; }
.oa-calendar-choice { position:relative; min-height:360px; overflow:hidden; border-radius:26px; color:white; text-decoration:none; isolation:isolate; }
.oa-calendar-choice img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; z-index:-2; }
.oa-calendar-choice::after { content:""; position:absolute; inset:0; background:linear-gradient(0deg,rgba(24,16,11,.92),rgba(24,16,11,.12) 72%); z-index:-1; }
.oa-calendar-choice-copy { position:absolute; left:24px; right:24px; bottom:24px; }
.oa-calendar-choice-copy span { font-size:.7rem; text-transform:uppercase; letter-spacing:.11em; color:#f1d7aa; }
.oa-calendar-choice-copy h2 { margin:7px 0 5px; font-family:Georgia,"Times New Roman",serif; font-size:2rem; font-weight:500; }
.oa-calendar-choice-copy p { margin:0; color:rgba(255,255,255,.74); line-height:1.5; font-size:.86rem; }

.oa-search-wrap { margin:24px 0 12px; position:relative; }
.oa-search-wrap svg { position:absolute; left:16px; top:50%; transform:translateY(-50%); width:20px; height:20px; fill:none; stroke:#8b7d6e; stroke-width:1.8; }
.oa-search { width:100%; height:52px; border:1px solid var(--oa-line); border-radius:16px; background:var(--oa-surface); color:var(--oa-ink); padding:0 18px 0 46px; outline:none; }
.oa-search:focus { border-color:rgba(167,119,47,.55); box-shadow:0 0 0 3px rgba(167,119,47,.10); }
.oa-chip-row { display:flex; gap:8px; overflow-x:auto; padding:4px 0 10px; }
.oa-filter-chip { border:1px solid var(--oa-line); background:var(--oa-surface); color:var(--oa-muted); border-radius:999px; padding:9px 13px; white-space:nowrap; cursor:pointer; font-size:.8rem; }
.oa-filter-chip.is-active { background:var(--oa-deep); color:white; border-color:var(--oa-deep); }
.oa-prayer-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-top:18px; }
.oa-prayer-card { border:1px solid var(--oa-line); background:var(--oa-surface); border-radius:20px; padding:18px; display:grid; gap:14px; }
.oa-prayer-card-top { display:flex; align-items:start; justify-content:space-between; gap:12px; }
.oa-prayer-card h3 { margin:0; font-family:Georgia,"Times New Roman",serif; font-size:1.22rem; font-weight:600; }
.oa-prayer-card .oa-category { margin-top:5px; color:var(--oa-gold); text-transform:uppercase; letter-spacing:.08em; font-size:.66rem; font-weight:750; }
.oa-prayer-preview { margin:0; color:var(--oa-muted); line-height:1.55; font-size:.83rem; display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; }
.oa-prayer-actions { display:flex; align-items:center; gap:8px; }
.oa-small-btn { min-height:38px; border:1px solid var(--oa-line); border-radius:999px; background:var(--oa-surface-2); color:var(--oa-ink); padding:0 13px; cursor:pointer; display:inline-flex; align-items:center; gap:7px; font-size:.78rem; font-weight:700; }
.oa-small-btn.primary { background:var(--oa-deep); color:white; border-color:var(--oa-deep); }
.oa-small-btn svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.9; }
.oa-favourite { margin-left:auto; width:38px; padding:0; justify-content:center; }
.oa-favourite.is-saved { color:var(--oa-gold); background:var(--oa-gold-soft); }

.oa-modal { position:fixed; inset:0; z-index:1200; display:none; align-items:end; justify-content:center; background:rgba(24,18,13,.48); backdrop-filter:blur(5px); padding:18px; }
.oa-modal.is-open { display:flex; }
.oa-modal-panel { width:min(760px,100%); max-height:min(84vh,850px); overflow:auto; background:var(--oa-surface); border-radius:28px; padding:22px; box-shadow:0 30px 70px rgba(24,18,13,.26); }
.oa-modal-head { position:sticky; top:-22px; z-index:2; background:linear-gradient(var(--oa-surface) 82%,transparent); padding:22px 0 18px; display:flex; align-items:start; justify-content:space-between; gap:12px; }
.oa-modal h2 { margin:0; font-family:Georgia,"Times New Roman",serif; font-size:1.8rem; }
.oa-modal-text { white-space:pre-wrap; font-family:Georgia,"Times New Roman",serif; font-size:1.08rem; line-height:1.85; color:#342a21; }
.oa-close { width:40px; height:40px; border-radius:50%; border:1px solid var(--oa-line); background:var(--oa-surface-2); cursor:pointer; flex:0 0 auto; }

.oa-audio-hero { margin-top:24px; border-radius:28px; overflow:hidden; background:var(--oa-deep); color:white; display:grid; grid-template-columns: .8fr 1.2fr; min-height:290px; }
.oa-audio-hero-art { position:relative; min-height:290px; overflow:hidden; }
.oa-audio-hero-art img { width:100%; height:100%; object-fit:cover; display:block; }
.oa-audio-hero-copy { padding:clamp(24px,4vw,42px); display:flex; flex-direction:column; justify-content:center; }
.oa-audio-hero-copy h1 { margin:0; font-family:Georgia,"Times New Roman",serif; font-weight:500; font-size:clamp(2.2rem,5vw,3.7rem); }
.oa-audio-hero-copy p { margin:12px 0 0; color:rgba(255,255,255,.7); line-height:1.6; }
.oa-track-list { display:grid; gap:8px; }
.oa-track { display:grid; grid-template-columns:48px 1fr auto; align-items:center; gap:12px; border:1px solid var(--oa-line); border-radius:18px; background:var(--oa-surface); padding:10px 12px; cursor:pointer; }
.oa-track:hover { background:#fff9f1; }
.oa-track-play { width:40px; height:40px; border:0; border-radius:50%; display:grid; place-items:center; background:var(--oa-gold-soft); color:var(--oa-gold); cursor:pointer; }
.oa-track-play svg { width:18px; height:18px; fill:currentColor; stroke:none; }
.oa-track strong { font-size:.9rem; }
.oa-track span { color:var(--oa-muted); font-size:.72rem; display:block; margin-top:2px; }
.oa-track-type { color:var(--oa-muted); font-size:.72rem; }
.oa-player { position:fixed; left:50%; bottom:calc(var(--oa-dock-h) + 25px); transform:translateX(-50%) translateY(140%); width:min(700px,calc(100% - 22px)); border:1px solid rgba(64,46,29,.14); border-radius:20px; background:rgba(42,29,21,.97); color:white; box-shadow:0 18px 55px rgba(34,24,17,.28); z-index:999; padding:12px 14px; display:grid; grid-template-columns:1fr auto; align-items:center; gap:14px; transition:transform .24s ease; }
.oa-player.is-visible { transform:translateX(-50%) translateY(0); }
.oa-player-meta { min-width:0; }
.oa-player-meta strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:.86rem; }
.oa-player-meta span { display:block; color:rgba(255,255,255,.58); font-size:.7rem; margin-top:2px; }
.oa-player-controls { display:flex; gap:6px; align-items:center; }
.oa-player-btn { width:40px; height:40px; border-radius:50%; border:1px solid rgba(255,255,255,.14); background:rgba(255,255,255,.08); color:white; display:grid; place-items:center; cursor:pointer; }
.oa-player-btn svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.9; }
.oa-player-btn.play { background:#fff7e9; color:#372317; }
.oa-player-progress { grid-column:1/-1; display:grid; grid-template-columns:38px 1fr 38px; align-items:center; gap:8px; color:rgba(255,255,255,.55); font-size:.66rem; }
.oa-player-progress input { width:100%; accent-color:#d5ad68; }

.oa-empty { border:1px dashed var(--oa-line); border-radius:20px; padding:28px; text-align:center; color:var(--oa-muted); background:rgba(255,253,249,.56); }

/* Calendar page modernization, loaded after the legacy calendar CSS */
body.app-calendar-page {
  background: var(--oa-bg) !important;
  background-image: none !important;
  display: block !important;
  padding: 18px 16px calc(var(--oa-dock-h) + 34px) !important;
  color: var(--oa-ink) !important;
}
body.app-calendar-page .app-shell {
  max-width: 1160px !important;
  margin: 0 auto !important;
  border: 0 !important;
  border-radius: 0 !important;
  overflow: visible !important;
  box-shadow: none !important;
  background: transparent !important;
}
body.app-calendar-page .calendar-selector-link {
  position: static !important;
  align-self: flex-start !important;
  margin: 0 0 12px !important;
  display: inline-flex !important;
  min-height: 38px !important;
  align-items: center !important;
  border: 1px solid var(--oa-line) !important;
  background: var(--oa-surface) !important;
  border-radius: 999px !important;
  padding: 0 13px !important;
  text-decoration: none !important;
  color: var(--oa-muted) !important;
  font-size: .8rem !important;
}
body.app-calendar-page .app-header {
  position: relative !important;
  overflow: hidden !important;
  border: 0 !important;
  border-radius: 28px !important;
  padding: 32px !important;
  background: linear-gradient(145deg,#2b211a,#4a3526) !important;
  color: white !important;
  box-shadow: var(--oa-shadow) !important;
  align-items: stretch !important;
}
body.app-calendar-page .header-top { flex-direction: row !important; align-items: center !important; justify-content: flex-start !important; }
body.app-calendar-page .app-mark { background: rgba(255,255,255,.1) !important; box-shadow: none !important; border:1px solid rgba(255,255,255,.12) !important; width:58px !important; height:58px !important; flex:0 0 auto !important; }
body.app-calendar-page .app-mark img, body.app-calendar-page .calendar-logo, body.app-calendar-page .app-logo { width:34px !important; height:42px !important; object-fit:contain !important; }
body.app-calendar-page .app-title-group { align-items:flex-start !important; text-align:left !important; }
body.app-calendar-page .app-tagline { color:#e8c991 !important; }
body.app-calendar-page .app-title { font-family:Georgia,"Times New Roman",serif !important; font-size:clamp(2rem,5vw,3.3rem) !important; font-weight:500 !important; }
body.app-calendar-page .app-subtitle { color:rgba(255,255,255,.69) !important; }
body.app-calendar-page .header-controls { align-items:flex-start !important; gap:10px !important; margin-top:14px !important; }
body.app-calendar-page .calendar-toggle-group { background:rgba(255,255,255,.08) !important; border:1px solid rgba(255,255,255,.12) !important; border-radius:999px !important; padding:4px !important; }
body.app-calendar-page .calendar-toggle-btn { color:rgba(255,255,255,.68) !important; border:0 !important; background:transparent !important; }
body.app-calendar-page .calendar-toggle-btn.active { background:#fff8ec !important; color:#3a281d !important; box-shadow:none !important; }
body.app-calendar-page .header-meta, body.app-calendar-page .meta-date { color:rgba(255,255,255,.72) !important; }
body.app-calendar-page .hymn-main-btn { background:rgba(255,255,255,.1) !important; color:white !important; border-color:rgba(255,255,255,.18) !important; }
body.app-calendar-page .hymn-secondary-btn { background:rgba(255,255,255,.1) !important; color:white !important; border-color:rgba(255,255,255,.18) !important; }
body.app-calendar-page .hymn-now-playing { color:rgba(255,255,255,.62) !important; }
body.app-calendar-page .app-main { padding:20px 0 0 !important; gap:16px !important; align-items:start !important; }
body.app-calendar-page .today-panel,
body.app-calendar-page .readings-panel,
body.app-calendar-page .prayers-panel {
  border:1px solid var(--oa-line) !important;
  border-radius:24px !important;
  background:var(--oa-surface) !important;
  box-shadow:none !important;
}
body.app-calendar-page .today-panel { overflow:hidden !important; }
body.app-calendar-page .today-header { border-bottom:1px solid var(--oa-line) !important; background:var(--oa-surface-2) !important; }
body.app-calendar-page .today-label-date { color:var(--oa-ink) !important; }
body.app-calendar-page .today-section { border-top:1px solid var(--oa-line) !important; }
body.app-calendar-page .section-heading, body.app-calendar-page .panel-header h3 { font-family:Georgia,"Times New Roman",serif !important; font-weight:600 !important; color:var(--oa-ink) !important; }
body.app-calendar-page .panel-sub, body.app-calendar-page .muted { color:var(--oa-muted) !important; }
body.app-calendar-page .reading-card { border:1px solid var(--oa-line) !important; border-radius:16px !important; background:#fffdfa !important; box-shadow:none !important; }
body.app-calendar-page .reading-header:hover { background:#fbf5eb !important; }
body.app-calendar-page .reading-toggle, body.app-calendar-page .prayer-toggle { color:var(--oa-gold) !important; }
body.app-calendar-page .month-nav button { border:1px solid var(--oa-line) !important; background:var(--oa-surface-2) !important; color:var(--oa-ink) !important; }
body.app-calendar-page .chip { background:var(--oa-gold-soft) !important; color:#66461f !important; }
body.app-calendar-page .month-grid { border-color:var(--oa-line) !important; }
body.app-calendar-page .month-grid th { color:var(--oa-muted) !important; }
body.app-calendar-page .month-grid td { border-color:var(--oa-line) !important; }
body.app-calendar-page .month-day-inner:hover { background:var(--oa-gold-soft) !important; }
body.app-calendar-page .month-day-inner.selected, body.app-calendar-page .month-day-inner.is-selected { background:var(--oa-deep) !important; color:white !important; }
body.app-calendar-page .app-footer { border:0 !important; background:transparent !important; color:var(--oa-muted) !important; padding:24px 0 10px !important; }

/* Study Bible modernization */
body.app-bible-page { background:var(--oa-bg) !important; color:var(--oa-ink) !important; padding-bottom:calc(var(--oa-dock-h) + 32px) !important; }
body.app-bible-page .back-link { position:relative !important; display:inline-flex !important; margin:18px 0 0 max(16px,calc((100% - 1180px)/2)) !important; min-height:38px !important; align-items:center !important; border:1px solid var(--oa-line) !important; border-radius:999px !important; background:var(--oa-surface) !important; padding:0 13px !important; color:var(--oa-muted) !important; text-decoration:none !important; }
body.app-bible-page .reader-page { width:min(1180px,calc(100% - 32px)) !important; margin:14px auto 0 !important; padding:0 !important; }
body.app-bible-page .reader-header { border:0 !important; background:linear-gradient(145deg,#2b211a,#4a3526) !important; color:white !important; border-radius:28px !important; min-height:160px !important; display:flex !important; flex-direction:column !important; align-items:center !important; justify-content:center !important; padding:24px !important; box-shadow:var(--oa-shadow) !important; }
body.app-bible-page .reader-logo { width:42px !important; max-height:54px !important; }
body.app-bible-page .reader-header h1 { font-family:Georgia,"Times New Roman",serif !important; font-weight:500 !important; font-size:clamp(1.9rem,4vw,3rem) !important; }
body.app-bible-page .reader-toolbar { margin:14px 0 0 !important; width:100% !important; max-width:none !important; border:1px solid var(--oa-line) !important; border-radius:18px !important; background:var(--oa-surface) !important; box-shadow:none !important; padding:8px !important; overflow-x:auto !important; flex-wrap:nowrap !important; justify-content:flex-start !important; }
body.app-bible-page .reader-toolbar select { border:1px solid var(--oa-line) !important; background:var(--oa-surface-2) !important; border-radius:12px !important; color:var(--oa-ink) !important; }
body.app-bible-page .icon-tool { border:1px solid transparent !important; border-radius:12px !important; background:transparent !important; color:var(--oa-muted) !important; flex:0 0 auto !important; }
body.app-bible-page .icon-tool:hover { background:var(--oa-gold-soft) !important; color:var(--oa-gold) !important; }
body.app-bible-page .reader-status { color:var(--oa-muted) !important; }
body.app-bible-page .book-stage { background:transparent !important; border:0 !important; box-shadow:none !important; }
body.app-bible-page .book-shell { background:transparent !important; border:0 !important; box-shadow:none !important; }
body.app-bible-page .book-spread { background:transparent !important; }
body.app-bible-page canvas { border-radius:8px !important; box-shadow:0 14px 40px rgba(36,27,20,.12) !important; }
body.app-bible-page .page-navigation { border:1px solid var(--oa-line) !important; border-radius:999px !important; background:var(--oa-surface) !important; width:max-content !important; max-width:100% !important; margin:14px auto 0 !important; padding:5px !important; }
body.app-bible-page .page-arrow { background:var(--oa-surface-2) !important; color:var(--oa-ink) !important; border-radius:50% !important; border:0 !important; }
body.app-bible-page .location-label { color:var(--oa-muted) !important; }
body.app-bible-page .text-reader { border:1px solid var(--oa-line) !important; background:var(--oa-surface) !important; border-radius:24px !important; box-shadow:none !important; }

@media (min-width: 1120px) {
  body.orthodox-app, body.app-page { padding-left: 96px; padding-bottom: 28px; }
  .oa-dock { left:16px; top:50%; bottom:auto; transform:translateY(-50%); width:72px; min-height:420px; grid-template-columns:1fr; grid-template-rows:repeat(5,1fr); border-radius:24px; }
  .oa-dock-link { padding:7px 2px; }
  .oa-player { bottom:18px; }
  body.app-calendar-page { padding-left:112px !important; }
  body.app-bible-page { padding-left:96px !important; }
}

@media (max-width: 820px) {
  .oa-page { width:min(100% - 24px,1180px); padding-top:12px; }
  .oa-topbar { min-height:52px; margin-bottom:14px; }
  .oa-brand-copy span { display:none; }
  .oa-hero, .oa-hero-content { min-height:410px; }
  .oa-hero::after { background:linear-gradient(0deg,rgba(18,14,11,.90) 0%,rgba(18,14,11,.54) 62%,rgba(18,14,11,.16) 100%); }
  .oa-hero-content { justify-content:end; padding:24px; }
  .oa-quick-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .oa-card-row { grid-auto-columns:minmax(235px,76%); }
  .oa-feature-grid { grid-template-columns:1fr; }
  .oa-calendar-choice-grid { grid-template-columns:1fr; }
  .oa-calendar-choice { min-height:300px; }
  .oa-prayer-grid { grid-template-columns:1fr; }
  .oa-audio-hero { grid-template-columns:1fr; }
  .oa-audio-hero-art { min-height:180px; max-height:230px; }
  body.app-calendar-page .app-header { padding:24px !important; }
  body.app-calendar-page .header-top { align-items:flex-start !important; }
  body.app-calendar-page .app-main { grid-template-columns:1fr !important; }
  body.app-calendar-page .calendar-toggle-group { width:100% !important; border-radius:16px !important; }
  body.app-calendar-page .calendar-toggle-btn { flex:1 !important; border-radius:12px !important; }
  body.app-bible-page .reader-page { width:calc(100% - 20px) !important; }
}

@media (max-width: 520px) {
  .oa-top-actions .oa-pill-button span { display:none; }
  .oa-hero { border-radius:24px; min-height:430px; }
  .oa-hero-content { min-height:430px; }
  .oa-hero h1 { font-size:2.55rem; }
  .oa-quick-card { min-height:112px; padding:15px; }
  .oa-section-head { align-items:start; }
  .oa-section-title { font-size:1.55rem; }
  .oa-dock { bottom:8px; border-radius:21px; min-height:70px; }
  .oa-dock-link span { font-size:.62rem; }
  .oa-simple-hero { padding-top:8px; }
  .oa-simple-hero h1 { font-size:2.55rem; }
  .oa-modal { padding:8px; }
  .oa-modal-panel { border-radius:22px; padding:18px; max-height:90vh; }
  .oa-player { bottom:88px; }
  .oa-track { grid-template-columns:44px 1fr; }
  .oa-track-type { display:none; }
  body.app-calendar-page { padding:10px 10px 94px !important; }
  body.app-calendar-page .app-header { border-radius:22px !important; padding:20px !important; }
  body.app-calendar-page .app-mark { width:48px !important; height:48px !important; }
  body.app-calendar-page .app-title { font-size:2rem !important; }
  body.app-calendar-page .hymn-controls { flex-wrap:wrap !important; }
  body.app-bible-page { padding-left:0 !important; }
  body.app-bible-page .back-link { margin-left:10px !important; }
  body.app-bible-page .reader-header { border-radius:22px !important; min-height:138px !important; }
}

@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { scroll-behavior:auto !important; transition:none !important; }
}



/* September 2026 app refinement */
:root {
  --oa-bg: #f5f1e9;
  --oa-surface: #fffdf8;
  --oa-surface-2: #eee7dc;
  --oa-ink: #241b15;
  --oa-muted: #74685d;
  --oa-line: rgba(70, 49, 31, 0.15);
  --oa-gold: #9b6d2c;
  --oa-gold-soft: #efe1c8;
  --oa-deep: #211812;
  --oa-radius: 16px;
  --oa-radius-sm: 11px;
  --oa-shadow: 0 12px 34px rgba(47, 35, 24, 0.07);
}

.oa-page { width: min(1220px, calc(100% - 32px)); }
.oa-topbar { margin-bottom: 18px; }
.oa-brand img { display:block; }
.oa-pill-button,
.oa-icon-button { border-radius: 11px; background: transparent; }
.oa-pill-button svg,
.oa-icon-button svg { display:block; flex:0 0 auto; }
.oa-pill-button:hover,
.oa-icon-button:hover { background: var(--oa-surface-2); }

.oa-section-head { margin-top: 31px; }
.oa-section-link { text-decoration: underline; text-decoration-color: rgba(155,109,44,.35); text-underline-offset: 4px; }

/* Home carousel */
.oa-hero-carousel {
  min-height: 370px;
  border: 1px solid rgba(61,43,28,.18);
  border-radius: 18px;
  box-shadow: none;
  overflow: hidden;
  background: var(--oa-deep);
}
.oa-hero-carousel::after { display:none; }
.oa-hero-track {
  display:flex;
  width:100%;
  min-height:370px;
  will-change:transform;
  transition:transform .78s cubic-bezier(.22,.61,.36,1);
}
.oa-hero-slide {
  position:relative;
  flex:0 0 100%;
  width:100%;
  min-height:370px;
  color:#fff;
  isolation:isolate;
  overflow:hidden;
}
.oa-hero-slide::after {
  content:"";
  position:absolute;
  inset:0;
  z-index:-1;
  background:
    linear-gradient(90deg, rgba(19,13,10,.88) 0%, rgba(19,13,10,.62) 49%, rgba(19,13,10,.20) 100%),
    linear-gradient(0deg, rgba(19,13,10,.42), transparent 62%);
}
.oa-hero-slide .oa-hero-bg { z-index:-2; transform:scale(1.015); transition:transform 6.5s ease; }
.oa-hero-slide.is-current .oa-hero-bg { transform:scale(1.055); }
.oa-hero-carousel .oa-hero-content { min-height:370px; padding:clamp(28px,5vw,54px); }
.oa-hero-carousel .oa-hero-content h1 { max-width:760px; }
.oa-hero-dots {
  position:absolute;
  right:20px;
  bottom:18px;
  z-index:5;
  display:flex;
  align-items:center;
  gap:7px;
}
.oa-hero-dot {
  width:7px;
  height:7px;
  min-height:0;
  padding:0;
  border:0;
  border-radius:50%;
  background:rgba(255,255,255,.42);
  cursor:pointer;
  transition:width .22s ease, background .22s ease, border-radius .22s ease;
}
.oa-hero-dot.is-active { width:22px; border-radius:999px; background:#fff; }
.oa-hero-dot:focus-visible { outline:2px solid #fff; outline-offset:3px; }

/* Compact quick actions, with icon boxes aligned correctly */
.oa-quick-grid { gap:10px; }
.oa-quick-card {
  min-height:88px;
  padding:15px;
  border-radius:13px;
  flex-direction:row;
  align-items:center;
  justify-content:flex-start;
  gap:13px;
  text-align:left;
  box-shadow:none;
  transition:transform .2s ease, background .2s ease, border-color .2s ease;
}
button.oa-quick-card { width:100%; color:inherit; font:inherit; }
.oa-quick-card:hover { transform:translateY(-2px); background:#fffaf2; }
.oa-quick-card > .oa-quick-icon {
  display:grid;
  place-items:center;
  flex:0 0 42px;
  width:42px;
  height:42px;
  margin:0;
  border-radius:10px;
  background:var(--oa-gold-soft);
  color:#76501d;
  line-height:1;
}
.oa-quick-card > .oa-quick-icon svg {
  display:block;
  width:21px;
  height:21px;
  margin:0;
}
.oa-quick-card > .oa-quick-copy {
  display:block;
  min-width:0;
  margin:0;
  color:var(--oa-ink);
  font-size:inherit;
}
.oa-quick-card > .oa-quick-copy strong { margin:0; line-height:1.25; }
.oa-quick-card > .oa-quick-copy > span {
  display:block;
  margin-top:4px;
  color:var(--oa-muted);
  font-size:.77rem;
  line-height:1.3;
}

.oa-media-card,
.oa-feature-card,
.oa-calendar-choice { border-radius:14px; }
.oa-media-card { min-height:220px; }
.oa-media-card img,
.oa-feature-card-image img,
.oa-calendar-choice img { transition:transform .45s ease; }
.oa-media-card:hover img,
.oa-feature-card:hover .oa-feature-card-image img,
.oa-calendar-choice:hover img { transform:scale(1.035); }
.oa-feature-card { box-shadow:none; }
.oa-feature-card-image { height:148px; }

/* Prayer library */
.oa-prayer-grid { gap:10px; }
.oa-prayer-card {
  min-height:122px;
  padding:16px;
  border-radius:13px;
  gap:12px;
  box-shadow:none;
}
.oa-prayer-card-top { align-items:center; }
.oa-prayer-open-title {
  min-width:0;
  flex:1;
  padding:0;
  border:0;
  background:transparent;
  color:inherit;
  text-align:left;
  cursor:pointer;
}
.oa-prayer-open-title:hover,
.oa-prayer-open-title:focus-visible { background:transparent; outline:0; }
.oa-prayer-open-title .oa-category {
  display:block;
  margin:0 0 5px;
  color:var(--oa-gold);
  text-transform:uppercase;
  letter-spacing:.08em;
  font-size:.64rem;
  font-weight:750;
}
.oa-prayer-open-title h3 { transition:color .16s ease; }
.oa-prayer-open-title:hover h3 { color:var(--oa-gold); }
.oa-prayer-preview { display:none; }
.oa-prayer-actions { margin-top:auto; }
.oa-small-btn {
  min-height:36px;
  border-radius:10px;
  background:transparent;
  padding:0 11px;
}
.oa-small-btn.primary { background:var(--oa-deep); }
.oa-small-btn svg { display:block; flex:0 0 auto; }
.oa-favourite { width:36px; height:36px; min-height:36px; padding:0; border-radius:50%; }
.oa-modal-panel { border-radius:16px; }
.oa-close { display:grid; place-items:center; line-height:1; }

/* Listen library */
.oa-audio-hero {
  margin-top:18px;
  border-radius:16px;
  border:1px solid rgba(61,43,28,.18);
  box-shadow:none;
}
.oa-audio-hero-copy .oa-eyebrow { color:#e0bd7a; }
.oa-listen-tabs {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  width:min(520px,100%);
  margin:24px 0 0;
  border-bottom:1px solid var(--oa-line);
}
.oa-listen-tab {
  position:relative;
  min-height:44px;
  padding:0 8px;
  border:0;
  border-radius:0;
  background:transparent;
  color:var(--oa-muted);
  font-weight:700;
  cursor:pointer;
}
.oa-listen-tab::after {
  content:"";
  position:absolute;
  left:0;
  right:0;
  bottom:-1px;
  height:2px;
  transform:scaleX(0);
  background:var(--oa-gold);
  transition:transform .2s ease;
}
.oa-listen-tab.is-active { color:var(--oa-ink); }
.oa-listen-tab.is-active::after { transform:scaleX(1); }
.oa-listen-tab:hover { background:transparent; }
.oa-track {
  width:100%;
  min-height:64px;
  border-radius:11px;
  text-align:left;
  color:inherit;
}
.oa-track-play { display:grid; place-items:center; flex:0 0 auto; }
.oa-track-play svg { display:block; }
.oa-track-copy { display:block; min-width:0; }
.oa-track-copy strong { display:block; }
.oa-recorded-empty {
  display:grid;
  grid-template-columns:54px 1fr;
  gap:16px;
  align-items:start;
  max-width:780px;
  margin-top:8px;
  padding:22px 0;
  border-top:1px solid var(--oa-line);
  border-bottom:1px solid var(--oa-line);
}
.oa-recorded-empty-mark {
  width:48px;
  height:48px;
  display:grid;
  place-items:center;
  border:1px solid var(--oa-line);
  border-radius:50%;
  color:var(--oa-gold);
}
.oa-recorded-empty-mark svg { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.8; }
.oa-recorded-empty h3 { margin:0; font-family:Georgia,"Times New Roman",serif; font-size:1.25rem; }
.oa-recorded-empty p { margin:6px 0 0; color:var(--oa-muted); line-height:1.6; }

/* Bottom navigation behaves like an app bar on phones and tablets */
@media (max-width:1119px) {
  body.orthodox-app,
  body.app-page { padding-bottom:calc(var(--oa-dock-h) + env(safe-area-inset-bottom) + 12px); }
  .oa-dock {
    left:0;
    right:0;
    bottom:0;
    transform:none;
    width:100%;
    min-height:68px;
    padding:6px 8px calc(6px + env(safe-area-inset-bottom));
    border:0;
    border-top:1px solid var(--oa-line);
    border-radius:0;
    box-shadow:0 -8px 24px rgba(39,28,19,.07);
    background:rgba(255,253,248,.96);
  }
  .oa-dock-link { border-radius:9px; }
  .oa-dock-link.is-active { background:transparent; color:var(--oa-gold); }
  .oa-dock-link.is-active::after {
    content:"";
    width:18px;
    height:2px;
    border-radius:2px;
    background:currentColor;
    position:absolute;
    top:4px;
  }
  .oa-dock-link { position:relative; }
  .oa-player { bottom:calc(74px + env(safe-area-inset-bottom)); }
}

@media (min-width:1120px) {
  .oa-dock { border-radius:13px; box-shadow:0 8px 30px rgba(43,31,21,.10); }
  .oa-dock-link { border-radius:9px; }
  .oa-dock-link.is-active { background:transparent; }
}

/* Calendar polish, fewer oversized rounded containers */
body.app-calendar-page .app-header { border-radius:16px !important; box-shadow:none !important; }
body.app-calendar-page .today-panel,
body.app-calendar-page .readings-panel,
body.app-calendar-page .prayers-panel { border-radius:14px !important; }
body.app-calendar-page .reading-card { border-radius:10px !important; }
body.app-calendar-page .calendar-toggle-group { border-radius:11px !important; }
body.app-calendar-page .calendar-toggle-btn.active { border-radius:8px !important; }

/* Study Bible, simpler masthead and genuinely centred controls */
body.app-bible-page .back-link {
  position:relative !important;
  margin:14px 0 0 max(14px,calc((100% - 1400px)/2)) !important;
  min-height:auto !important;
  padding:3px 0 !important;
  border:0 !important;
  border-radius:0 !important;
  background:transparent !important;
  color:var(--oa-muted) !important;
}
body.app-bible-page .reader-page {
  width:min(1400px,calc(100% - 28px)) !important;
  margin:8px auto 0 !important;
}
body.app-bible-page .reader-header {
  min-height:0 !important;
  padding:4px 0 12px !important;
  border:0 !important;
  border-bottom:1px solid var(--oa-line) !important;
  border-radius:0 !important;
  background:transparent !important;
  color:var(--oa-ink) !important;
  box-shadow:none !important;
  display:block !important;
}
.reader-title-lockup {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  width:100%;
}
body.app-bible-page .reader-logo {
  width:38px !important;
  height:auto !important;
  max-height:48px !important;
  margin:0 !important;
  flex:0 0 auto;
}
.reader-title-copy { min-width:0; text-align:left; }
.reader-kicker {
  margin:0 0 2px;
  color:var(--oa-gold);
  font-size:.66rem;
  font-weight:750;
  letter-spacing:.12em;
  text-transform:uppercase;
}
body.app-bible-page .reader-header h1 {
  margin:0 !important;
  color:var(--oa-ink) !important;
  font-family:Georgia,"Times New Roman",serif !important;
  font-size:clamp(1.55rem,3vw,2.3rem) !important;
  font-weight:500 !important;
  line-height:1.05 !important;
}
.reader-subtitle {
  margin:4px 0 0;
  color:var(--oa-muted);
  font-size:.78rem;
}
body.app-bible-page .reader-toolbar {
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  gap:7px !important;
  width:fit-content !important;
  max-width:100% !important;
  min-height:0 !important;
  margin:10px auto 0 !important;
  padding:6px 8px !important;
  border:1px solid var(--oa-line) !important;
  border-radius:11px !important;
  background:var(--oa-surface) !important;
  box-shadow:none !important;
  overflow:visible !important;
  flex-wrap:nowrap !important;
}
.reader-select-group,
.reader-tool-group {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:4px;
  min-width:0;
}
.reader-tool-group { flex-wrap:nowrap; }
body.app-bible-page .reader-toolbar select {
  height:34px !important;
  min-height:34px !important;
  border-radius:8px !important;
  padding-top:0 !important;
  padding-bottom:0 !important;
  font-size:.8rem !important;
}
body.app-bible-page .book-select { width:clamp(170px,19vw,250px) !important; }
body.app-bible-page .part-select { width:clamp(120px,13vw,165px) !important; }
body.app-bible-page .reader-toolbar .icon-tool {
  display:grid !important;
  place-items:center !important;
  flex:0 0 34px !important;
  width:34px !important;
  height:34px !important;
  min-height:34px !important;
  padding:0 !important;
  border-radius:8px !important;
  line-height:1 !important;
}
body.app-bible-page .reader-toolbar .icon-tool svg {
  display:block !important;
  width:17px !important;
  height:17px !important;
  margin:0 !important;
}
body.app-bible-page .reader-toolbar .text-size-tool {
  width:36px !important;
  flex-basis:36px !important;
  font-size:.8rem !important;
}
body.app-bible-page .toolbar-divider { height:24px; align-self:center; }
body.app-bible-page .book-stage {
  width:100% !important;
  max-width:100% !important;
  overflow:visible !important;
  justify-content:center !important;
  padding:10px 8px 3px !important;
  -webkit-overflow-scrolling:touch;
  overscroll-behavior:contain;
}
body.app-bible-page .book-stage.is-enlarged {
  justify-content:flex-start !important;
  overflow:auto !important;
  scrollbar-width:thin !important;
}
body.app-bible-page .book-stage.is-enlarged .book-shell { margin-inline:0 !important; }
body.app-bible-page .book-page {
  outline:2px solid #946d31 !important;
  border:0 !important;
  border-radius:2px !important;
}
body.app-bible-page canvas {
  border-radius:0 !important;
  box-shadow:0 9px 28px rgba(36,27,20,.12) !important;
}
body.app-bible-page .page-navigation {
  width:min(600px,100%) !important;
  min-height:48px !important;
  margin:5px auto 0 !important;
  padding:2px 0 !important;
  border:0 !important;
  border-radius:0 !important;
  background:transparent !important;
}
body.app-bible-page .page-arrow {
  width:46px !important;
  height:42px !important;
  min-height:42px !important;
  border:1px solid var(--oa-line) !important;
  border-radius:9px !important;
  background:var(--oa-surface) !important;
  color:var(--oa-ink) !important;
  font-size:2rem !important;
}
body.app-bible-page .page-arrow:hover { background:var(--oa-surface-2) !important; color:var(--oa-gold) !important; }
body.app-bible-page .text-reader { border-radius:12px !important; }

/* restrained entrance motion */
.oa-reveal { opacity:0; transform:translateY(12px); transition:opacity .48s ease, transform .48s ease; }
.oa-reveal.is-visible { opacity:1; transform:none; }

@media (max-width:820px) {
  .oa-page { width:calc(100% - 20px); padding-top:10px; }
  .oa-topbar { margin-bottom:12px; }
  .oa-hero-carousel,
  .oa-hero-track,
  .oa-hero-slide,
  .oa-hero-carousel .oa-hero-content { min-height:395px; }
  .oa-hero-slide::after {
    background:linear-gradient(0deg,rgba(18,13,10,.92) 0%,rgba(18,13,10,.61) 60%,rgba(18,13,10,.18) 100%);
  }
  .oa-hero-carousel .oa-hero-content { padding:24px 20px 42px; }
  .oa-hero-dots { left:20px; right:auto; bottom:17px; }
  .oa-quick-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .oa-quick-card { min-height:82px; padding:13px; gap:11px; }
  .oa-quick-card > .oa-quick-icon { flex-basis:38px; width:38px; height:38px; }
  .oa-quick-card > .oa-quick-icon svg { width:19px; height:19px; }
  .oa-card-row { grid-auto-columns:minmax(240px,82%); }
  .oa-audio-hero { grid-template-columns:1fr; }
  .oa-audio-hero-art { min-height:175px; max-height:210px; }
  .oa-listen-tabs { width:100%; }
  body.app-bible-page .reader-page { width:calc(100% - 16px) !important; }
  body.app-bible-page .reader-header { padding-bottom:10px !important; }
  body.app-bible-page .reader-toolbar {
    width:100% !important;
    flex-direction:column !important;
    align-items:stretch !important;
    gap:6px !important;
    padding:7px !important;
  }
  body.app-bible-page .toolbar-divider-main { display:none !important; }
  .reader-select-group { width:100%; }
  body.app-bible-page .book-select,
  body.app-bible-page .part-select { flex:1 1 0 !important; width:auto !important; min-width:0 !important; }
  .reader-tool-group { width:100%; flex-wrap:wrap; justify-content:center; gap:4px; }
  body.app-bible-page .book-stage { padding-inline:3px !important; }
}

@media (max-width:520px) {
  .oa-brand-copy strong { font-size:1rem; }
  .oa-brand img { width:30px; height:38px; }
  .oa-pill-button { width:40px; height:40px; min-height:40px; padding:0; }
  .oa-hero-carousel { border-radius:14px; }
  .oa-hero-carousel .oa-hero-content h1 { font-size:2.35rem; }
  .oa-hero-carousel .oa-hero-content p { line-height:1.5; }
  .oa-quick-card { min-height:78px; }
  .oa-quick-card > .oa-quick-copy > span { font-size:.7rem; }
  .oa-section-head { margin-top:27px; }
  .oa-media-card { min-height:205px; }
  .oa-prayer-grid { grid-template-columns:1fr; }
  .oa-prayer-card { min-height:116px; }
  .oa-modal { padding:0; align-items:end; }
  .oa-modal-panel { width:100%; max-height:92vh; border-radius:16px 16px 0 0; padding:18px 16px calc(18px + env(safe-area-inset-bottom)); }
  .oa-recorded-empty { grid-template-columns:44px 1fr; gap:12px; }
  .oa-recorded-empty-mark { width:42px; height:42px; }
  .oa-player { width:calc(100% - 12px); border-radius:12px; }
  body.app-calendar-page { padding-bottom:calc(78px + env(safe-area-inset-bottom)) !important; }
  body.app-calendar-page .app-header { border-radius:14px !important; }
  body.app-bible-page .back-link { margin-left:8px !important; }
  .reader-title-lockup { gap:9px; justify-content:flex-start; }
  body.app-bible-page .reader-logo { width:32px !important; max-height:42px !important; }
  body.app-bible-page .reader-header h1 { font-size:1.55rem !important; }
  .reader-subtitle { font-size:.7rem; }
  body.app-bible-page .reader-toolbar .icon-tool { flex-basis:33px !important; width:33px !important; height:33px !important; min-height:33px !important; }
  body.app-bible-page .reader-toolbar .text-size-tool { flex-basis:35px !important; width:35px !important; }
  body.app-bible-page .page-navigation { grid-template-columns:50px minmax(0,1fr) 50px !important; }
}

@media (prefers-reduced-motion: reduce) {
  .oa-hero-track,
  .oa-hero-slide .oa-hero-bg,
  .oa-hero-dot,
  .oa-reveal,
  .oa-media-card img,
  .oa-feature-card-image img,
  .oa-calendar-choice img { transition:none !important; transform:none !important; }
  .oa-reveal { opacity:1 !important; }
}

/* September 2026, third refinement. More liturgical, less card-driven. */
.oa-feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Prayer library reads as a quiet index rather than a stack of generic cards. */
.oa-prayer-grid {
  gap: 8px 28px;
}
.oa-prayer-card {
  position: relative;
  min-height: 108px;
  padding: 16px 12px 14px 34px;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.oa-prayer-card::before {
  content: "☦";
  position: absolute;
  left: 5px;
  top: 17px;
  color: rgba(155,109,44,.62);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
  line-height: 1;
}
.oa-prayer-card::after {
  content: "";
  position: absolute;
  left: 34px;
  right: 10px;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(155,109,44,.30), rgba(90,67,47,.07), transparent);
}
.oa-prayer-card:hover { background: rgba(255,253,248,.48); }
.oa-prayer-actions { justify-content: flex-start; }
.oa-prayer-actions .oa-small-btn.primary {
  min-height: 32px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--oa-gold);
}
.oa-prayer-actions .oa-small-btn.primary:hover { color: var(--oa-ink); }
.oa-favourite { background: transparent; border: 0; }
.oa-favourite:hover { background: var(--oa-gold-soft); }

/* Equal-sized calendar choices on the home screen. */
.oa-feature-card { min-width: 0; }
.oa-feature-card .oa-feature-card-image { height: 155px; }

/* Liturgical calendar masthead. */
body.app-calendar-page .calendar-selector-link {
  border: 0 !important;
  border-radius: 0 !important;
  padding: 4px 0 !important;
  background: transparent !important;
  color: #786b60 !important;
}
body.app-calendar-page .liturgical-masthead {
  position: relative !important;
  isolation: isolate !important;
  overflow: hidden !important;
  display: block !important;
  padding: clamp(30px, 5vw, 56px) clamp(22px, 5vw, 68px) 0 !important;
  border: 0 !important;
  border-radius: 4px !important;
  background:
    radial-gradient(circle at 50% -30%, rgba(181,139,72,.26), transparent 46%),
    linear-gradient(128deg, #20150f 0%, #352218 47%, #241710 100%) !important;
  color: #fffaf0 !important;
  box-shadow: 0 16px 44px rgba(38,24,16,.16) !important;
}
body.app-calendar-page .liturgical-masthead::before,
body.app-calendar-page .liturgical-masthead::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
}
body.app-calendar-page .liturgical-masthead::before {
  inset: 9px;
  border: 1px solid rgba(208,169,104,.22);
}
body.app-calendar-page .liturgical-masthead::after {
  left: 50%;
  top: -150px;
  width: min(580px, 70vw);
  height: 330px;
  transform: translateX(-50%);
  border: 1px solid rgba(218,178,107,.14);
  border-radius: 50% 50% 44% 44%;
}
body.app-calendar-page .liturgical-watermark {
  position: absolute;
  top: 26px;
  right: clamp(22px,5vw,58px);
  width: 150px;
  height: 185px;
  opacity: .045;
  pointer-events: none;
}
body.app-calendar-page .liturgical-watermark img {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
  filter: grayscale(1) brightness(4);
}
body.app-calendar-page .liturgical-heading {
  position: relative;
  z-index: 1;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}
body.app-calendar-page .liturgical-crest {
  width: 66px;
  height: 82px;
  margin: 0 auto 12px;
  display: grid;
  place-items: center;
  background: radial-gradient(circle, rgba(216,178,111,.14), transparent 70%);
}
body.app-calendar-page .liturgical-crest img {
  width: 44px !important;
  height: 58px !important;
  object-fit: contain !important;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.18));
}
body.app-calendar-page .liturgical-heading .app-tagline {
  margin: 0 0 8px !important;
  color: #d9b877 !important;
  font-size: .72rem !important;
  font-weight: 700 !important;
  letter-spacing: .24em !important;
}
body.app-calendar-page .liturgical-heading .app-title {
  margin: 0 !important;
  color: #fffaf1 !important;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: clamp(2.65rem, 7vw, 5.7rem) !important;
  font-weight: 400 !important;
  line-height: .96 !important;
  letter-spacing: -.025em !important;
}
body.app-calendar-page .liturgical-heading .app-subtitle {
  max-width: 560px;
  margin: 15px auto 0 !important;
  color: rgba(255,250,241,.70) !important;
  font-size: .98rem !important;
  line-height: 1.55 !important;
}
.liturgical-ornament {
  display: grid;
  grid-template-columns: minmax(30px,90px) auto minmax(30px,90px);
  align-items: center;
  justify-content: center;
  gap: 11px;
  width: min(250px,72%);
  margin: 22px auto 24px;
  color: #d5ad65;
}
.liturgical-ornament span {
  height: 1px;
  background: linear-gradient(90deg, transparent, currentColor);
  opacity: .55;
}
.liturgical-ornament span:last-child { background: linear-gradient(90deg, currentColor, transparent); }
.liturgical-ornament b { font-family: Georgia,"Times New Roman",serif; font-size: 1.1rem; font-weight: 400; }

body.app-calendar-page .liturgical-control-band {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: .82fr 1.12fr 1.06fr;
  align-items: stretch;
  margin: 0 calc(clamp(22px,5vw,68px) * -1);
  background: rgba(255,249,239,.055);
  border-top: 1px solid rgba(224,190,126,.18);
}
body.app-calendar-page .liturgical-control-band > * {
  min-width: 0;
  padding: 19px clamp(18px,2.7vw,34px) 21px;
}
body.app-calendar-page .liturgical-control-band > * + * {
  border-left: 1px solid rgba(224,190,126,.15);
}
.liturgical-control-label {
  display: block;
  margin-bottom: 7px;
  color: #c9a666;
  font-size: .62rem;
  font-weight: 750;
  letter-spacing: .18em;
  text-transform: uppercase;
}
body.app-calendar-page .liturgical-date-block .header-meta {
  margin: 0 !important;
  color: #fffaf1 !important;
}
body.app-calendar-page .liturgical-date-block .meta-date {
  color: #fffaf1 !important;
  font-family: Georgia,"Times New Roman",serif !important;
  font-size: clamp(1.05rem,2vw,1.45rem) !important;
  font-weight: 500 !important;
  line-height: 1.25 !important;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-group {
  display: grid !important;
  grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  width: 100% !important;
  padding: 0 !important;
  gap: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn {
  position: relative;
  display: grid !important;
  gap: 2px !important;
  min-height: 48px !important;
  padding: 4px 12px 7px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(224,190,126,.24) !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: rgba(255,250,241,.58) !important;
  text-align: left !important;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn + .calendar-toggle-btn {
  margin-left: 12px;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn span {
  font-size: .84rem !important;
  font-weight: 700 !important;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn small {
  display: block;
  color: inherit;
  font-size: .64rem;
  font-weight: 500;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn.active {
  background: transparent !important;
  color: #fff9ee !important;
  box-shadow: none !important;
  border-bottom-color: #d7b36d !important;
}
body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn.active::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 44%;
  height: 3px;
  background: #d7b36d;
}
body.app-calendar-page .liturgical-audio { margin: 0 !important; }
body.app-calendar-page .liturgical-audio .hymn-main-btn {
  width: 100% !important;
  min-height: 48px !important;
  display: grid !important;
  grid-template-columns: 34px 1fr auto !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 0 0 7px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(224,190,126,.24) !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #fffaf1 !important;
  text-align: left !important;
}
body.app-calendar-page .liturgical-audio .hymn-main-btn:hover { border-bottom-color: #d7b36d !important; }
.hymn-main-icon {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  color: #d9b36b;
}
.hymn-main-icon svg { width: 25px; height: 25px; fill:none; stroke:currentColor; stroke-width:1.55; stroke-linecap:round; stroke-linejoin:round; }
.hymn-main-copy { display: grid; gap: 1px; min-width: 0; }
.hymn-main-copy strong { font-size: .86rem; font-weight: 700; }
.hymn-main-copy small { color: rgba(255,250,241,.55); font-size: .65rem; }
.hymn-main-arrow { color: #d9b36b; font-size: .72rem; }
body.app-calendar-page .liturgical-audio .hymn-controls {
  display: none;
  align-items: center;
  gap: 5px;
  margin-top: 9px !important;
}
body.app-calendar-page .liturgical-audio .hymn-controls.is-visible { display: flex !important; }
body.app-calendar-page .liturgical-audio .hymn-secondary-btn {
  width: 31px !important;
  height: 31px !important;
  min-height: 31px !important;
  padding: 0 !important;
  border: 1px solid rgba(224,190,126,.20) !important;
  border-radius: 50% !important;
  background: transparent !important;
  color: #fff7ea !important;
}
body.app-calendar-page .liturgical-audio .hymn-volume {
  margin-left: 5px;
  display: flex !important;
  align-items: center;
  gap: 6px;
  color: rgba(255,250,241,.55) !important;
  font-size: .62rem !important;
}
body.app-calendar-page .liturgical-audio .hymn-volume input { width: 70px !important; }
body.app-calendar-page .liturgical-audio .hymn-now-playing {
  margin: 8px 0 0 !important;
  color: rgba(255,250,241,.63) !important;
  font-size: .66rem !important;
}

/* Content beneath the masthead has a more editorial rhythm. */
body.app-calendar-page .app-main { gap: 22px !important; padding-top: 26px !important; }
body.app-calendar-page .today-panel,
body.app-calendar-page .readings-panel,
body.app-calendar-page .prayers-panel {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
}
body.app-calendar-page .today-header {
  padding: 0 0 14px !important;
  border: 0 !important;
  background: transparent !important;
}
body.app-calendar-page .today-label-date {
  font-family: Georgia,"Times New Roman",serif !important;
  font-size: 1.15rem !important;
  font-weight: 600 !important;
}
body.app-calendar-page .today-section {
  position: relative;
  padding: 18px 0 20px 26px !important;
  border: 0 !important;
}
body.app-calendar-page .today-section::before {
  content: "☦";
  position: absolute;
  left: 1px;
  top: 21px;
  color: rgba(155,109,44,.52);
  font-family: Georgia,"Times New Roman",serif;
  font-size: .8rem;
}
body.app-calendar-page .today-section + .today-section::after,
body.app-calendar-page .right-panel > section + section::after {
  content: "";
  position: absolute;
  top: 0;
  left: 26px;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(155,109,44,.24), transparent 72%);
}
body.app-calendar-page .right-panel { display: grid !important; gap: 28px !important; }
body.app-calendar-page .right-panel > section { position: relative; padding: 2px 0 0 !important; }
body.app-calendar-page .right-panel > section + section { padding-top: 24px !important; }
body.app-calendar-page .right-panel > section + section::after { left: 0; }
body.app-calendar-page .panel-header { padding: 0 0 12px !important; }
body.app-calendar-page .panel-header h3,
body.app-calendar-page .section-heading {
  font-size: 1.35rem !important;
}
body.app-calendar-page .reading-card {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  border-bottom: 1px solid rgba(91,69,50,.10) !important;
}
body.app-calendar-page .reading-header { padding-inline: 0 !important; }
body.app-calendar-page .reading-header:hover { background: transparent !important; }
body.app-calendar-page .reading-toggle,
body.app-calendar-page .prayer-toggle { color: #986a2b !important; }

/* Study Bible, make the tool rail separate from the page and fit the cover exactly. */
body.app-bible-page .reader-page { width: min(1500px, calc(100% - 24px)) !important; }
body.app-bible-page .reader-header {
  padding: 2px 0 13px !important;
  border: 0 !important;
  background: transparent !important;
}
.reader-title-lockup {
  position: relative;
  display: grid;
  grid-template-columns: minmax(24px,110px) auto minmax(24px,110px);
  align-items: center;
  justify-content: center;
  gap: 14px;
  max-width: 760px;
  margin: 0 auto;
}
.reader-title-lockup > .reader-logo { grid-column: 2; grid-row: 1; justify-self: start; }
.reader-title-copy { grid-column: 2; grid-row: 1; padding-left: 51px; text-align: left; }
.reader-title-ornament {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(155,109,44,.46));
}
.reader-title-ornament:last-child { background: linear-gradient(90deg, rgba(155,109,44,.46), transparent); }
body.app-bible-page .reader-logo {
  width: 38px !important;
  max-height: 48px !important;
}
body.app-bible-page .reader-kicker {
  margin-bottom: 1px !important;
  color: #8f6327 !important;
  font-size: .61rem !important;
  letter-spacing: .15em !important;
}
body.app-bible-page .reader-header h1 {
  font-size: clamp(1.45rem,2.8vw,2.25rem) !important;
  letter-spacing: -.015em !important;
}
body.app-bible-page .reader-subtitle { margin-top: 3px !important; }
body.app-bible-page .reader-toolbar {
  position: relative !important;
  z-index: 8 !important;
  width: fit-content !important;
  max-width: calc(100% - 8px) !important;
  margin: 5px auto 0 !important;
  padding: 6px 8px !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: rgba(255,253,248,.88) !important;
  box-shadow: 0 4px 18px rgba(44,32,23,.07) !important;
  backdrop-filter: blur(10px);
}
body.app-bible-page .reader-toolbar::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(155,109,44,.25), transparent);
}
body.app-bible-page .reader-toolbar select {
  border: 0 !important;
  border-radius: 5px !important;
  background: #eee7dc !important;
}
body.app-bible-page .reader-toolbar .icon-tool { border-radius: 5px !important; }
body.app-bible-page .book-stage {
  position: relative !important;
  z-index: 1 !important;
  align-items: flex-start !important;
  justify-content: center !important;
  margin-top: 8px !important;
  padding: 0 !important;
  overflow: hidden !important;
}
body.app-bible-page .book-stage.is-enlarged {
  justify-content: flex-start !important;
  overflow: auto !important;
}
body.app-bible-page .book-shell {
  align-self: flex-start !important;
  margin: 0 auto !important;
  filter: none !important;
}
body.app-bible-page .book-stage.is-enlarged .book-shell { margin: 0 !important; }
body.app-bible-page .book-page {
  flex: 0 0 auto !important;
  outline: 2px solid #946d31 !important;
  outline-offset: -1px !important;
  box-shadow: 0 10px 30px rgba(36,27,20,.10) !important;
}
body.app-bible-page canvas { box-shadow: none !important; }
body.app-bible-page .page-navigation { margin-top: 8px !important; }

@media (max-width: 900px) {
  .oa-feature-grid { grid-template-columns: 1fr; }
  body.app-calendar-page .liturgical-control-band {
    grid-template-columns: 1fr 1fr !important;
  }
  body.app-calendar-page .liturgical-control-band > .liturgical-audio {
    grid-column: 1 / -1;
    border-left: 0 !important;
    border-top: 1px solid rgba(224,190,126,.15);
  }
}

@media (max-width: 620px) {
  .oa-prayer-card { padding-left: 29px; }
  .oa-prayer-card::after { left: 29px; }
  body.app-calendar-page .liturgical-masthead {
    padding: 25px 17px 0 !important;
    border-radius: 2px !important;
  }
  body.app-calendar-page .liturgical-masthead::before { inset: 6px; }
  body.app-calendar-page .liturgical-watermark { width: 96px; height: 120px; top: 18px; right: 10px; }
  body.app-calendar-page .liturgical-crest { width: 54px; height: 66px; margin-bottom: 9px; }
  body.app-calendar-page .liturgical-crest img { width: 36px !important; height: 48px !important; }
  body.app-calendar-page .liturgical-heading .app-tagline { font-size: .58rem !important; letter-spacing: .18em !important; }
  body.app-calendar-page .liturgical-heading .app-title { font-size: clamp(2.45rem,13vw,3.8rem) !important; }
  body.app-calendar-page .liturgical-heading .app-subtitle { font-size: .84rem !important; }
  .liturgical-ornament { margin: 17px auto 19px; }
  body.app-calendar-page .liturgical-control-band {
    grid-template-columns: 1fr !important;
    margin: 0 -17px !important;
  }
  body.app-calendar-page .liturgical-control-band > * {
    padding: 14px 18px 16px !important;
  }
  body.app-calendar-page .liturgical-control-band > * + * {
    border-left: 0 !important;
    border-top: 1px solid rgba(224,190,126,.15);
  }
  body.app-calendar-page .liturgical-control-band > .liturgical-audio { grid-column: auto; }
  body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn { min-height: 43px !important; }
  body.app-calendar-page .liturgical-audio .hymn-main-btn { min-height: 44px !important; }
  body.app-calendar-page .today-section { padding-left: 22px !important; }
  body.app-calendar-page .today-section + .today-section::after { left: 22px; }

  .reader-title-lockup {
    grid-template-columns: 28px minmax(0,1fr) 28px;
    gap: 8px;
  }
  .reader-title-copy { padding-left: 42px; }
  body.app-bible-page .reader-logo { width: 31px !important; max-height: 42px !important; }
  body.app-bible-page .reader-toolbar {
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 6px !important;
    box-shadow: none !important;
  }
  body.app-bible-page .book-stage { margin-top: 6px !important; }
}

/* =========================================================
   Refresh pass, home, calendar cards, listen, prayers, Bible
   ========================================================= */

.oa-topbar {
  justify-content: space-between;
}

.oa-card-row-library {
  grid-auto-flow: row;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-columns: unset;
  overflow: visible;
  padding-bottom: 2px;
}

.oa-card-row-library .oa-media-card {
  min-height: 250px;
  border: 1px solid rgba(73, 52, 31, .08);
  box-shadow: 0 14px 26px rgba(54, 38, 23, .05);
}

.oa-card-row-library .oa-media-card::after {
  background: linear-gradient(0deg, rgba(21,14,10,.86), rgba(21,14,10,.18) 72%);
}

.oa-calendar-home-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.oa-calendar-home-grid .oa-feature-card {
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #fffcf7 0%, #f5ede0 100%);
  border-color: rgba(108, 80, 49, .12);
}

.oa-calendar-home-grid .oa-feature-card-image {
  height: 230px;
}

.oa-calendar-home-grid .oa-feature-card-body {
  min-height: 166px;
  background: linear-gradient(180deg, rgba(255,251,244,.96) 0%, rgba(246,238,226,.98) 100%);
}

.oa-calendar-home-grid .oa-feature-card-body p {
  max-width: 36ch;
}

.oa-quick-copy { min-width: 0; }

.oa-listen-page .oa-section-head {
  align-items: center;
}

.oa-audio-hero-refined {
  min-height: 320px;
  border: 1px solid rgba(91, 66, 40, .11);
  box-shadow: 0 20px 34px rgba(53, 37, 21, .06);
}

.oa-audio-hero-refined .oa-audio-hero-copy {
  background: linear-gradient(135deg, #2b1c14 0%, #452719 52%, #5c3320 100%);
}

.oa-audio-hero-refined .oa-audio-hero-copy p,
.oa-audio-hero-refined .oa-audio-hero-copy h1 {
  max-width: 34ch;
}

.oa-listen-tabs-wide {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border-bottom: 1px solid rgba(116, 86, 52, .15);
}

.oa-listen-tabs-wide .oa-listen-tab {
  justify-content: center;
  padding-inline: 12px;
}

.oa-track-list-organised {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.oa-track-group {
  border: 1px solid rgba(116, 86, 52, .12);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,251,245,.92) 0%, rgba(249,242,232,.88) 100%);
  padding: 18px;
  box-shadow: 0 12px 22px rgba(56, 41, 26, .04);
}

.oa-track-group-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.oa-track-group-head h3 {
  margin: 2px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.42rem;
}

.oa-track-group-count,
.oa-listen-page .oa-section-link {
  display: inline-flex;
  align-items: center;
  min-height: 31px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(173, 125, 56, .09);
  color: #89612c;
  font-size: .76rem;
  font-weight: 700;
}

.oa-track-group-list {
  display: grid;
  gap: 10px;
}

.oa-track {
  width: 100%;
  text-align: left;
}

.oa-track.is-playing {
  border-color: rgba(167,119,47,.42);
  background: linear-gradient(180deg, #fff7ea 0%, #fdf1de 100%);
}

.oa-track.is-playing .oa-track-copy strong {
  color: #7f5618;
}

.oa-track-copy strong { font-size: .95rem; }

.oa-recorded-empty-refined {
  align-items: center;
  min-height: 180px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,252,247,.95), rgba(247,239,229,.95));
  border-color: rgba(116, 86, 52, .12);
}

.oa-prayer-open-title {
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.oa-prayer-open-title:hover,
.oa-prayer-open-title:focus-visible {
  background: transparent;
  outline: 0;
}

body.app-calendar-page .liturgical-masthead {
  padding: 18px 22px 0 !important;
  border-radius: 22px !important;
}

body.app-calendar-page .liturgical-masthead::before {
  inset: 10px !important;
}

body.app-calendar-page .liturgical-watermark {
  width: 120px;
  height: 146px;
  top: 18px;
}

body.app-calendar-page .liturgical-crest {
  width: 60px;
  height: 72px;
  margin-bottom: 10px;
}

body.app-calendar-page .liturgical-crest img {
  width: 38px !important;
  height: 50px !important;
}

body.app-calendar-page .liturgical-heading .app-tagline {
  font-size: .66rem !important;
}

body.app-calendar-page .liturgical-heading .app-title {
  font-size: clamp(2.85rem, 7vw, 4.4rem) !important;
  line-height: .96 !important;
}

body.app-calendar-page .liturgical-heading .app-subtitle {
  max-width: 40ch;
  font-size: .96rem !important;
}

body.app-calendar-page .liturgical-control-band {
  margin: 20px -22px 0 !important;
}

body.app-calendar-page .liturgical-control-band > * {
  padding: 18px 22px 17px !important;
}

body.app-calendar-page .liturgical-control-label {
  margin-bottom: 10px !important;
}

body.app-calendar-page .liturgical-date-block .meta-date {
  font-size: clamp(1.15rem, 2.2vw, 1.55rem) !important;
}

body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn {
  min-height: 45px !important;
  padding-top: 8px !important;
  padding-bottom: 9px !important;
}

body.app-calendar-page .liturgical-audio .hymn-main-btn {
  min-height: 46px !important;
  padding-bottom: 9px !important;
}

body.app-bible-page {
  background:
    radial-gradient(circle at top, rgba(234,216,188,.35), transparent 34%),
    linear-gradient(180deg, #f8f3ea 0%, #f3ede1 100%);
}

body.app-bible-page .reader-page {
  width: min(1460px, calc(100% - 20px)) !important;
  padding-top: 12px !important;
  padding-bottom: 22px !important;
}

body.app-bible-page .reader-header {
  margin: 10px auto 0 !important;
  padding: 22px 18px 18px !important;
  border: 1px solid rgba(126, 92, 50, .10);
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(255,253,249,.93) 0%, rgba(247,240,229,.97) 100%);
  box-shadow: 0 16px 28px rgba(62, 43, 23, .05);
}

body.app-bible-page .reader-title-lockup {
  max-width: 860px;
}

body.app-bible-page .reader-title-copy {
  padding-left: 55px;
}

body.app-bible-page .reader-kicker {
  font-size: .7rem !important;
}

body.app-bible-page .reader-header h1 {
  font-size: clamp(1.7rem, 3vw, 2.5rem) !important;
}

body.app-bible-page .reader-subtitle {
  color: #6d5a45;
  font-size: .95rem;
}

body.app-bible-page .reader-toolbar {
  margin: 14px auto 14px !important;
  padding: 8px 10px !important;
  border-radius: 16px !important;
  background: rgba(255, 252, 246, .93) !important;
  box-shadow: 0 14px 26px rgba(44, 32, 23, .06) !important;
}

body.app-bible-page .book-stage {
  margin-top: 4px !important;
  padding: 12px 8px 8px !important;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255,254,251,.88), rgba(248,241,230,.84));
  border: 1px solid rgba(126, 92, 50, .09);
}

body.app-bible-page .book-shell {
  padding: 4px;
}

body.app-bible-page .book-page {
  border-radius: 12px !important;
}

body.app-bible-page .page-navigation {
  width: min(860px, calc(100% - 8px));
  margin-top: 12px !important;
  padding: 8px 16px !important;
  border-radius: 18px;
  background: rgba(255,252,246,.88);
  border: 1px solid rgba(126, 92, 50, .09);
  box-shadow: 0 10px 18px rgba(44, 32, 23, .04);
}

body.app-bible-page .location-label {
  color: #5d4b39;
  font-size: .94rem;
}

body.app-bible-page .text-reader {
  border-radius: 24px;
  border-color: rgba(126, 92, 50, .10);
  background: rgba(255,252,246,.94);
}

@media (max-width: 1080px) {
  .oa-card-row-library {
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: minmax(250px, 48%);
    overflow-x: auto;
    padding-bottom: 8px;
  }

  .oa-track-list-organised {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .oa-calendar-home-grid {
    grid-template-columns: 1fr;
  }

  .oa-audio-hero-refined .oa-audio-hero-copy p,
  .oa-audio-hero-refined .oa-audio-hero-copy h1 {
    max-width: none;
  }
}

@media (max-width: 620px) {
  .oa-listen-tabs-wide {
    gap: 8px;
    border-bottom: 0;
  }

  .oa-listen-tabs-wide .oa-listen-tab {
    border-bottom: 1px solid rgba(116, 86, 52, .15);
  }

  body.app-calendar-page .liturgical-masthead {
    padding: 18px 16px 0 !important;
  }

  body.app-calendar-page .liturgical-control-band {
    margin: 18px -16px 0 !important;
  }

  body.app-calendar-page .liturgical-control-band > * {
    padding: 14px 16px 14px !important;
  }

  body.app-bible-page .reader-header {
    border-radius: 20px;
    padding: 18px 12px 14px !important;
  }

  body.app-bible-page .reader-toolbar {
    margin: 10px auto 12px !important;
  }

  body.app-bible-page .book-stage {
    border-radius: 20px;
    padding: 8px 2px 4px !important;
  }

  body.app-bible-page .page-navigation {
    border-radius: 14px;
    padding-inline: 8px !important;
  }
}

/* =========================================================
   V5 refinement: compact calendar, editorial content, audio
   ========================================================= */

/* Calendar masthead, deliberately shorter and quieter. */
body.app-calendar-page .app-shell {
  max-width: 1280px !important;
}

body.app-calendar-page .liturgical-masthead {
  padding: 14px 20px 0 !important;
  border-radius: 18px !important;
  box-shadow: 0 12px 32px rgba(38,24,16,.12) !important;
}

body.app-calendar-page .liturgical-masthead::before {
  inset: 7px !important;
}

body.app-calendar-page .liturgical-masthead::after {
  top: -215px !important;
  height: 315px !important;
  opacity: .7;
}

body.app-calendar-page .liturgical-watermark {
  top: 10px !important;
  right: 18px !important;
  width: 92px !important;
  height: 112px !important;
  opacity: .035 !important;
}

body.app-calendar-page .liturgical-heading {
  max-width: 700px !important;
}

body.app-calendar-page .liturgical-crest {
  width: 40px !important;
  height: 46px !important;
  margin: 0 auto 4px !important;
}

body.app-calendar-page .liturgical-crest img {
  width: 28px !important;
  height: 38px !important;
}

body.app-calendar-page .liturgical-heading .app-tagline {
  margin-bottom: 4px !important;
  font-size: .58rem !important;
  letter-spacing: .22em !important;
}

body.app-calendar-page .liturgical-heading .app-title {
  font-size: clamp(2.35rem, 5vw, 3.55rem) !important;
  line-height: .98 !important;
}

body.app-calendar-page .liturgical-heading .app-subtitle {
  max-width: 500px !important;
  margin-top: 8px !important;
  font-size: .84rem !important;
  line-height: 1.4 !important;
}

body.app-calendar-page .liturgical-ornament {
  width: min(185px, 58%) !important;
  margin: 9px auto 12px !important;
  gap: 8px !important;
}

body.app-calendar-page .liturgical-ornament b {
  font-size: .88rem !important;
}

body.app-calendar-page .liturgical-control-band {
  margin: 0 -20px !important;
  grid-template-columns: .82fr 1.08fr 1.1fr !important;
}

body.app-calendar-page .liturgical-control-band > * {
  padding: 10px 18px 11px !important;
}

body.app-calendar-page .liturgical-control-label {
  margin-bottom: 4px !important;
  font-size: .55rem !important;
  letter-spacing: .16em !important;
}

body.app-calendar-page .liturgical-date-block .meta-date {
  font-size: clamp(.98rem, 1.7vw, 1.22rem) !important;
  line-height: 1.18 !important;
}

body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn {
  min-height: 37px !important;
  padding: 2px 8px 5px !important;
}

body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn span {
  font-size: .75rem !important;
}

body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn small {
  font-size: .58rem !important;
}

body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn.active::after {
  height: 2px !important;
}

body.app-calendar-page .liturgical-audio .hymn-main-btn {
  min-height: 37px !important;
  grid-template-columns: 28px 1fr auto !important;
  gap: 8px !important;
  padding-bottom: 5px !important;
}

body.app-calendar-page .hymn-main-icon {
  width: 26px !important;
  height: 26px !important;
}

body.app-calendar-page .hymn-main-icon svg {
  width: 20px !important;
  height: 20px !important;
}

body.app-calendar-page .hymn-main-copy strong {
  font-size: .76rem !important;
}

body.app-calendar-page .hymn-main-copy small {
  font-size: .58rem !important;
}

/* Calendar content, more like a liturgical journal and less like stacked cards. */
body.app-calendar-page .app-main {
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr) !important;
  gap: clamp(34px, 5vw, 70px) !important;
  padding: 34px 8px 8px !important;
  font-family: "Palatino Linotype", Palatino, Georgia, serif !important;
  transition: opacity .23s ease, transform .23s ease, filter .23s ease !important;
}

body.app-calendar-page .app-main.is-updating {
  opacity: 0 !important;
  transform: translateY(7px) !important;
  filter: blur(1px);
}

body.app-calendar-page .today-panel,
body.app-calendar-page .readings-panel,
body.app-calendar-page .prayers-panel {
  overflow: visible !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.app-calendar-page .today-header {
  margin: 0 0 22px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

body.app-calendar-page .liturgical-date-line {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 5px 8px !important;
  align-items: baseline !important;
}

body.app-calendar-page .today-label-date {
  color: #756554 !important;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-size: .77rem !important;
  font-weight: 600 !important;
}

body.app-calendar-page .today-label-prefix {
  color: #a17436 !important;
  font-size: .62rem !important;
  letter-spacing: .09em !important;
  text-transform: uppercase;
}

body.app-calendar-page .today-section {
  position: relative !important;
  margin: 0 0 30px !important;
  padding: 0 !important;
  border: 0 !important;
}

body.app-calendar-page .today-section::before,
body.app-calendar-page .today-section + .today-section::after,
body.app-calendar-page .right-panel > section + section::after {
  content: none !important;
}

body.app-calendar-page .section-heading,
body.app-calendar-page .panel-header h3 {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  margin: 0 0 12px !important;
  color: #2b2017 !important;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: clamp(1.28rem, 2vw, 1.55rem) !important;
  font-weight: 600 !important;
  letter-spacing: -.015em !important;
  text-transform: none !important;
}

body.app-calendar-page .section-heading::before,
body.app-calendar-page .panel-header h3::before {
  content: "☦";
  color: #a77a38;
  font-size: .68em;
  font-weight: 400;
}

body.app-calendar-page .panel-header {
  margin: 0 0 15px !important;
  padding: 0 !important;
}

body.app-calendar-page .panel-sub {
  max-width: 48ch;
  margin: -5px 0 14px 25px !important;
  color: #7a6d60 !important;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-size: .78rem !important;
  line-height: 1.5 !important;
}

body.app-calendar-page .right-panel {
  display: grid !important;
  gap: 46px !important;
}

body.app-calendar-page .right-panel > section,
body.app-calendar-page .right-panel > section + section {
  padding: 0 !important;
}

body.app-calendar-page .list,
body.app-calendar-page .readings-list {
  gap: 4px !important;
}

body.app-calendar-page .saints-list,
body.app-calendar-page .fast-list,
body.app-calendar-page .feasts-list,
body.app-calendar-page .notes-list {
  font-size: 1rem !important;
}

body.app-calendar-page .reading-card {
  margin: 0 !important;
  padding: 10px 5px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  animation: oaLiturgicalReveal .36s cubic-bezier(.22,.72,.25,1) both;
}

body.app-calendar-page .reading-card:hover {
  background: rgba(182, 137, 70, .055) !important;
}

body.app-calendar-page .reading-header {
  min-height: 38px !important;
  align-items: baseline !important;
  gap: 16px !important;
  padding: 0 !important;
}

body.app-calendar-page .reading-header:hover {
  background: transparent !important;
}

body.app-calendar-page .saint-name,
body.app-calendar-page .fast-name,
body.app-calendar-page .feast-name,
body.app-calendar-page .reading-ref,
body.app-calendar-page .prayer-category-name,
body.app-calendar-page .prayer-title {
  padding-left: 0 !important;
  color: #35271d !important;
  font-family: "Palatino Linotype", Palatino, Georgia, serif !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  line-height: 1.45 !important;
}

body.app-calendar-page .saint-name::before {
  content: none !important;
}

body.app-calendar-page .reading-type {
  margin-top: 3px !important;
  color: #9a8061 !important;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-size: .58rem !important;
  letter-spacing: .13em !important;
}

body.app-calendar-page .reading-toggle,
body.app-calendar-page .prayer-toggle {
  color: #9a6c2c !important;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-size: .66rem !important;
  font-weight: 700 !important;
  letter-spacing: .02em !important;
  white-space: nowrap;
}

body.app-calendar-page .reading-body,
body.app-calendar-page .prayer-body {
  margin: 9px 0 3px 0 !important;
  padding: 10px 14px !important;
  border: 0 !important;
  border-left: 2px solid rgba(167, 119, 47, .35) !important;
  border-radius: 0 !important;
  background: rgba(255, 252, 246, .58) !important;
  color: #5e5043 !important;
  font-family: "Palatino Linotype", Palatino, Georgia, serif !important;
  font-size: .95rem !important;
  line-height: 1.68 !important;
  animation: oaLiturgicalBody .26s ease both;
}

body.app-calendar-page .today-date {
  margin-top: 38px !important;
  padding-top: 0 !important;
}

body.app-calendar-page .date-header-center {
  justify-content: flex-start !important;
}

body.app-calendar-page .month-nav {
  justify-content: flex-start !important;
  gap: 10px !important;
}

body.app-calendar-page .month-nav button {
  width: 32px !important;
  height: 32px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  color: #8a6635 !important;
  font-size: 1.15rem !important;
}

body.app-calendar-page .chip {
  border: 0 !important;
  background: transparent !important;
  color: #35271d !important;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: 1.06rem !important;
  font-weight: 600 !important;
}

body.app-calendar-page .month-grid {
  margin-top: 12px !important;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-size: .72rem !important;
}

body.app-calendar-page .month-grid th {
  padding-bottom: 7px !important;
  color: #9a8d7f !important;
  font-size: .58rem !important;
  font-weight: 700 !important;
  letter-spacing: .04em;
  text-transform: uppercase;
}

body.app-calendar-page .month-grid td {
  height: 2.35rem !important;
  border: 0 !important;
}

body.app-calendar-page .month-day-inner {
  min-width: 2rem !important;
  min-height: 2rem !important;
  border-radius: 50% !important;
}

body.app-calendar-page .month-day-today .month-day-inner,
body.app-calendar-page .month-day-selected .month-day-inner {
  border-color: #9a6c2c !important;
  background: #f2e5cf !important;
  color: #6d481a !important;
}

@keyframes oaLiturgicalReveal {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes oaLiturgicalBody {
  from { opacity: 0; transform: translateY(-3px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Prayer library: the prayer row itself is the control. */
.oa-prayer-card-button {
  width: 100%;
  min-height: 88px;
  grid-template-columns: 30px minmax(0, 1fr) 24px !important;
  align-items: center !important;
  gap: 15px !important;
  padding: 15px 8px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: var(--oa-ink);
  text-align: left;
  cursor: pointer;
}

.oa-prayer-card-button:hover,
.oa-prayer-card-button:focus-visible {
  background: rgba(167, 119, 47, .055) !important;
  outline: 0;
}

.oa-prayer-card-button::before,
.oa-prayer-card-button::after {
  content: none !important;
}

.oa-prayer-cross {
  color: #a7772f;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.15rem;
  text-align: center;
}

.oa-prayer-card-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.oa-prayer-card-copy .oa-category {
  margin: 0 !important;
  color: #a7772f !important;
  font-size: .61rem !important;
  font-weight: 750 !important;
  letter-spacing: .1em !important;
  text-transform: uppercase;
}

.oa-prayer-card-copy strong {
  color: #2d2118;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.16rem;
  font-weight: 600;
  line-height: 1.3;
}

.oa-prayer-open-mark {
  color: #9b7b51;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.8rem;
  line-height: 1;
  text-align: center;
  transition: transform .18s ease;
}

.oa-prayer-card-button:hover .oa-prayer-open-mark {
  transform: translateX(3px);
}

/* Listen page, no nested AI-like cards. */
.oa-track-list-organised {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: clamp(30px, 5vw, 64px) !important;
}

.oa-track-group {
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.oa-track-group-head {
  margin-bottom: 14px !important;
  padding: 0 8px !important;
}

.oa-track-group-head h3 {
  font-size: clamp(1.35rem, 2.3vw, 1.72rem) !important;
  letter-spacing: -.015em;
}

.oa-track-group-count,
.oa-listen-page .oa-section-link {
  min-height: 0 !important;
  padding: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #9a6b2d !important;
  font-size: .69rem !important;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.oa-track-group-list {
  gap: 2px !important;
}

.oa-track {
  grid-template-columns: 54px minmax(0, 1fr) !important;
  gap: 15px !important;
  min-height: 72px !important;
  padding: 8px 10px 8px 6px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: transparent !important;
  box-shadow: none !important;
  text-align: left;
  transition: background .18s ease, transform .18s ease !important;
}

.oa-track:hover,
.oa-track.is-playing {
  background: rgba(167, 119, 47, .06) !important;
  transform: translateX(2px);
}

.oa-track-play {
  display: grid !important;
  place-items: center !important;
  width: 44px !important;
  height: 44px !important;
  margin: 0 0 0 5px !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: #efe0c3 !important;
  color: #8d632b !important;
}

.oa-track-play svg {
  display: block !important;
  width: 17px !important;
  height: 17px !important;
  margin: 0 !important;
  transform: translateX(1px);
  fill: currentColor !important;
  stroke: none !important;
}

.oa-track-copy {
  align-self: center;
}

.oa-track-copy strong {
  color: #3c2e22;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.02rem !important;
  font-weight: 600;
}

.oa-track-copy span {
  margin-top: 3px !important;
  color: #7e6c5b !important;
  font-size: .72rem !important;
}

.oa-listen-tabs-wide {
  margin-top: 26px !important;
  border-bottom: 0 !important;
}

.oa-listen-tabs-wide .oa-listen-tab {
  position: relative;
  min-height: 50px;
  border: 0 !important;
  background: transparent !important;
  color: #77695c;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.02rem;
}

.oa-listen-tabs-wide .oa-listen-tab::after {
  left: 50% !important;
  right: auto !important;
  bottom: 3px !important;
  width: 26px !important;
  height: 2px !important;
  transform: translateX(-50%) scaleX(0) !important;
  transform-origin: center !important;
}

.oa-listen-tabs-wide .oa-listen-tab.is-active::after {
  transform: translateX(-50%) scaleX(1) !important;
}

.oa-recorded-empty-refined {
  min-height: 150px !important;
  padding: 22px 8px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* Bible: large readable page, document scroll remains on the browser page. */
body.app-bible-page,
body.app-bible-page .reader-page {
  overflow-y: visible !important;
}

body.app-bible-page .book-stage {
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  overflow-x: auto !important;
  overflow-y: visible !important;
  align-items: flex-start !important;
  justify-content: center !important;
  padding: 14px 6px 10px !important;
  overscroll-behavior-x: contain;
}

body.app-bible-page .book-stage.is-enlarged {
  justify-content: flex-start !important;
  overflow-x: auto !important;
  overflow-y: visible !important;
}

body.app-bible-page .book-shell {
  align-self: flex-start !important;
  margin: 0 auto !important;
}

body.app-bible-page .reader-toolbar {
  flex-wrap: wrap !important;
  justify-content: center !important;
  overflow: visible !important;
}

body.app-bible-page .reader-select-group,
body.app-bible-page .reader-tool-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

body.app-bible-page .book-page {
  max-width: none !important;
}

@media (max-width: 900px) {
  body.app-calendar-page .app-main {
    grid-template-columns: 1fr !important;
    gap: 44px !important;
    padding-inline: 4px !important;
  }

  body.app-calendar-page .right-panel {
    gap: 38px !important;
  }

  .oa-track-list-organised {
    grid-template-columns: 1fr !important;
    gap: 36px !important;
  }
}

@media (max-width: 620px) {
  body.app-calendar-page .liturgical-masthead {
    padding: 11px 12px 0 !important;
    border-radius: 14px !important;
  }

  body.app-calendar-page .liturgical-watermark {
    width: 70px !important;
    height: 86px !important;
    top: 8px !important;
    right: 8px !important;
  }

  body.app-calendar-page .liturgical-crest {
    width: 32px !important;
    height: 38px !important;
    margin-bottom: 2px !important;
  }

  body.app-calendar-page .liturgical-crest img {
    width: 24px !important;
    height: 32px !important;
  }

  body.app-calendar-page .liturgical-heading .app-title {
    font-size: clamp(2rem, 10vw, 2.65rem) !important;
  }

  body.app-calendar-page .liturgical-heading .app-subtitle {
    margin-top: 6px !important;
    font-size: .75rem !important;
  }

  body.app-calendar-page .liturgical-ornament {
    margin: 7px auto 9px !important;
  }

  body.app-calendar-page .liturgical-control-band {
    grid-template-columns: .82fr 1.18fr !important;
    margin: 0 -12px !important;
  }

  body.app-calendar-page .liturgical-control-band > * {
    padding: 9px 12px 10px !important;
  }

  body.app-calendar-page .liturgical-control-band > * + * {
    border-top: 0 !important;
  }

  body.app-calendar-page .liturgical-control-band > .liturgical-audio {
    grid-column: 1 / -1 !important;
    border-left: 0 !important;
    border-top: 1px solid rgba(224,190,126,.15) !important;
  }

  body.app-calendar-page .liturgical-date-block .meta-date {
    font-size: .88rem !important;
  }

  body.app-calendar-page .calendar-toggle-frame .calendar-toggle-btn + .calendar-toggle-btn {
    margin-left: 6px !important;
  }

  body.app-calendar-page .app-main {
    padding-top: 25px !important;
  }

  body.app-calendar-page .today-section {
    margin-bottom: 25px !important;
  }

  body.app-calendar-page .section-heading,
  body.app-calendar-page .panel-header h3 {
    font-size: 1.28rem !important;
  }

  body.app-calendar-page .reading-card {
    padding-inline: 2px !important;
  }

  .oa-prayer-grid {
    gap: 2px !important;
  }

  .oa-prayer-card-button {
    min-height: 78px;
    grid-template-columns: 25px minmax(0, 1fr) 20px !important;
    gap: 11px !important;
    padding: 12px 2px !important;
  }

  .oa-track {
    grid-template-columns: 50px minmax(0, 1fr) !important;
    padding-inline: 2px 4px !important;
  }

  .oa-track-play {
    width: 42px !important;
    height: 42px !important;
    margin-left: 3px !important;
  }

  body.app-bible-page .reader-toolbar {
    width: 100% !important;
    max-width: 100% !important;
  }

  body.app-bible-page .toolbar-divider-main {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.app-calendar-page .reading-card,
  body.app-calendar-page .reading-body,
  body.app-calendar-page .prayer-body {
    animation: none !important;
  }
}

/* v6, keep prayer content in the prayer library and make the calendar link to it. */
body.app-calendar-page .calendar-prayer-gateway .panel-sub {
  max-width: 42ch;
  margin-bottom: 12px !important;
}

body.app-calendar-page .calendar-prayer-links {
  display: grid;
  gap: 0;
  margin-top: 4px;
}

body.app-calendar-page .calendar-prayer-links a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 20px;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  padding: 7px 2px;
  border-bottom: 1px solid rgba(112, 83, 50, .11);
  color: #3b2c20;
  font-family: "Palatino Linotype", Palatino, Georgia, serif;
  font-size: .95rem;
  font-weight: 600;
  line-height: 1.35;
  text-decoration: none;
  transition: color .18s ease, padding-left .18s ease, border-color .18s ease;
}

body.app-calendar-page .calendar-prayer-links a > span:last-child {
  justify-self: end;
  color: #a17436;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1.1rem;
  font-weight: 500;
  transition: transform .18s ease;
}

body.app-calendar-page .calendar-prayer-links a:hover,
body.app-calendar-page .calendar-prayer-links a:focus-visible {
  padding-left: 5px;
  border-bottom-color: rgba(161, 116, 54, .28);
  color: #8d6129;
  outline: 0;
}

body.app-calendar-page .calendar-prayer-links a:hover > span:last-child,
body.app-calendar-page .calendar-prayer-links a:focus-visible > span:last-child {
  transform: translateX(3px);
}

body.app-calendar-page .calendar-prayer-links .calendar-prayer-all {
  margin-top: 5px;
  border-bottom: 0;
  color: #8d6129;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: .78rem;
  font-weight: 750;
  letter-spacing: .02em;
}

@media (max-width: 620px) {
  body.app-calendar-page .calendar-prayer-links a {
    min-height: 42px;
    font-size: .91rem;
  }
}

/* v7, flatter editorial treatment and smaller Bible page. */

/* Desktop navigation rail, keep the app structure without an enclosing card. */
@media (min-width:1120px) {
  .oa-dock {
    width: 76px !important;
    min-height: 410px !important;
    padding: 4px 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
  }
  .oa-dock-link {
    position: relative;
    border-radius: 0 !important;
    background: transparent !important;
  }
  .oa-dock-link.is-active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 2px;
    height: 30px;
    transform: translateY(-50%);
    background: var(--oa-gold);
  }
}

/* Prayer library, one calm list rather than a grid of cards. */
.oa-prayer-grid {
  grid-template-columns: 1fr !important;
  gap: 0 !important;
  width: min(900px, 100%);
  margin-inline: auto;
}

.oa-prayer-card-button {
  min-height: 76px !important;
  grid-template-columns: 28px minmax(0, 1fr) !important;
  gap: 14px !important;
  padding: 13px 4px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(111, 82, 49, .12) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.oa-prayer-card-button:hover,
.oa-prayer-card-button:focus-visible {
  padding-left: 8px !important;
  background: transparent !important;
  color: #8c612a !important;
}

.oa-prayer-card-button:last-child {
  border-bottom: 0 !important;
}

.oa-prayer-cross {
  font-size: 1rem !important;
  opacity: .76;
}

.oa-prayer-open-mark {
  display: none !important;
}

.oa-modal-panel {
  border-radius: 12px !important;
  box-shadow: 0 22px 55px rgba(24,18,13,.18) !important;
}

/* Calendar prayer links, no chevrons and no pseudo-card styling. */
body.app-calendar-page .calendar-prayer-links a {
  grid-template-columns: 1fr !important;
  min-height: 42px !important;
  padding: 7px 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
}

body.app-calendar-page .calendar-prayer-links a > span:last-child {
  display: none !important;
}

body.app-calendar-page .calendar-prayer-links a:hover,
body.app-calendar-page .calendar-prayer-links a:focus-visible {
  padding-left: 6px !important;
  background: transparent !important;
}

/* Listen, use separated rows rather than rounded boxes. */
.oa-audio-hero-refined {
  border-radius: 10px !important;
  box-shadow: none !important;
}

.oa-track-group {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.oa-track-group-head {
  padding-inline: 0 !important;
}

.oa-track-group-list {
  gap: 0 !important;
}

.oa-track {
  grid-template-columns: 58px minmax(0, 1fr) !important;
  min-height: 70px !important;
  padding: 10px 4px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(111, 82, 49, .11) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  transform: none !important;
}

.oa-track:last-child {
  border-bottom: 0 !important;
}

.oa-track:hover,
.oa-track.is-playing {
  padding-left: 8px !important;
  background: transparent !important;
  transform: none !important;
}

.oa-track-play {
  width: 42px !important;
  height: 42px !important;
  margin-left: 8px !important;
  border-radius: 50% !important;
  background: #efe0c3 !important;
}

.oa-track-play svg {
  width: 16px !important;
  height: 16px !important;
  transform: translateX(1px) !important;
}

.oa-recorded-empty-refined {
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* Home cards retain imagery but lose the generic soft-card treatment. */
.oa-media-card,
.oa-feature-card,
.oa-calendar-choice {
  border-radius: 8px !important;
  box-shadow: none !important;
}

.oa-calendar-home-grid .oa-feature-card-body {
  border-radius: 0 !important;
}

/* Bible, smaller page and a flatter reader chrome. */
body.app-bible-page .reader-header {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.app-bible-page .reader-toolbar {
  width: fit-content !important;
  max-width: calc(100% - 20px) !important;
  margin: 10px auto 16px !important;
  padding: 7px 4px !important;
  border: 0 !important;
  border-top: 1px solid rgba(126, 92, 50, .13) !important;
  border-bottom: 1px solid rgba(126, 92, 50, .13) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

body.app-bible-page .reader-toolbar::after {
  display: none !important;
}

body.app-bible-page .reader-toolbar select {
  border-radius: 4px !important;
  background: #eee7dc !important;
}

body.app-bible-page .reader-toolbar .icon-tool {
  border-radius: 4px !important;
}

body.app-bible-page .book-stage {
  width: min(920px, 100%) !important;
  margin-inline: auto !important;
  padding: 8px 0 5px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
}

body.app-bible-page .book-shell {
  padding: 0 !important;
}

body.app-bible-page .book-page {
  border-radius: 4px !important;
  box-shadow: 0 8px 22px rgba(36,27,20,.10) !important;
}

body.app-bible-page .page-navigation {
  width: min(720px, calc(100% - 8px)) !important;
  margin-top: 10px !important;
  padding: 5px 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

@media (max-width: 760px) {
  .oa-prayer-card-button {
    min-height: 68px !important;
    grid-template-columns: 24px minmax(0, 1fr) !important;
    padding: 11px 2px !important;
  }

  .oa-track-list-organised {
    gap: 34px !important;
  }

  .oa-track {
    grid-template-columns: 54px minmax(0, 1fr) !important;
  }

  body.app-bible-page .book-stage {
    width: 100% !important;
  }
}

body.app-calendar-page .calendar-prayer-links a > span:last-child {
  display: inline !important;
  justify-self: start !important;
  color: inherit !important;
  font-family: inherit !important;
  font-size: inherit !important;
  font-weight: inherit !important;
  transition: none !important;
}
body.app-calendar-page .calendar-prayer-links a:hover > span:last-child,
body.app-calendar-page .calendar-prayer-links a:focus-visible > span:last-child {
  transform: none !important;
}

/* Calendar chrome, more like a liturgical page than a rounded dashboard. */
body.app-calendar-page .calendar-selector-link {
  min-height: 30px !important;
  margin-bottom: 10px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #81643f !important;
}

body.app-calendar-page .liturgical-masthead {
  border-radius: 8px !important;
  box-shadow: none !important;
}

body.app-calendar-page .liturgical-masthead::before {
  display: none !important;
}

/* =========================================================
   v8 refinement, prayer alignment and renewed Bible reader
   ========================================================= */

/* Prayer library follows the same left edge as the page heading and search. */
.oa-prayer-grid {
  width: 100% !important;
  max-width: none !important;
  margin: 20px 0 0 !important;
}

.oa-prayer-card-button {
  width: 100% !important;
  min-height: 72px !important;
  grid-template-columns: 22px minmax(0, 1fr) !important;
  gap: 12px !important;
  padding: 12px 0 !important;
}

.oa-prayer-card-button:hover,
.oa-prayer-card-button:focus-visible {
  padding-left: 0 !important;
}

.oa-prayer-cross {
  text-align: left !important;
}

/* Bible page, use the same app language as the rest of the site. */
body.app-bible-page {
  background: var(--oa-bg) !important;
}

body.app-bible-page .reader-page {
  width: min(1180px, calc(100% - 32px)) !important;
  margin: 0 auto !important;
  padding: 18px 0 36px !important;
}

body.app-bible-page .bible-topbar {
  margin: 0 0 24px !important;
}

body.app-bible-page .bible-editorial-head {
  width: min(760px, 100%);
  margin: 8px auto 18px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: start;
  gap: 14px;
}

body.app-bible-page .bible-editorial-mark {
  padding-top: 7px;
  color: var(--oa-gold);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.45rem;
  line-height: 1;
}

body.app-bible-page .bible-editorial-copy h1 {
  margin: 2px 0 5px;
  color: var(--oa-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -.025em;
}

body.app-bible-page .bible-editorial-copy > p:last-child {
  margin: 0;
  max-width: 590px;
  color: var(--oa-muted);
  font-size: .94rem;
  line-height: 1.55;
}

body.app-bible-page .reader-toolbar {
  width: min(760px, 100%) !important;
  max-width: none !important;
  margin: 0 auto 16px !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
  backdrop-filter: none !important;
}

body.app-bible-page .reader-select-group,
body.app-bible-page .reader-tool-group {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}

body.app-bible-page .reader-select-group {
  flex: 1 1 auto;
  min-width: 0;
}

body.app-bible-page .reader-tool-group {
  flex: 0 0 auto;
}

body.app-bible-page .reader-toolbar select {
  height: 38px !important;
  min-height: 38px !important;
  padding: 0 24px 0 2px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(91, 69, 50, .20) !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: var(--oa-ink) !important;
  box-shadow: none !important;
  font-size: .86rem !important;
}

body.app-bible-page .book-select {
  width: min(310px, 48vw) !important;
}

body.app-bible-page .part-select {
  width: min(180px, 29vw) !important;
}

body.app-bible-page .reader-toolbar .icon-tool {
  display: grid !important;
  place-items: center !important;
  flex: 0 0 34px !important;
  width: 34px !important;
  height: 34px !important;
  min-height: 34px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: transparent !important;
  color: #786a5b !important;
  box-shadow: none !important;
}

body.app-bible-page .reader-toolbar .icon-tool:hover,
body.app-bible-page .reader-toolbar .icon-tool:focus-visible,
body.app-bible-page .reader-toolbar .icon-tool.is-active,
body.app-bible-page .reader-toolbar .icon-tool[aria-pressed="true"] {
  background: rgba(167, 119, 47, .09) !important;
  color: var(--oa-gold) !important;
  outline: 0 !important;
}

body.app-bible-page .reader-toolbar .text-size-tool {
  flex-basis: 36px !important;
  width: 36px !important;
  font-family: Georgia, "Times New Roman", serif !important;
}

body.app-bible-page .reader-status {
  width: min(620px, 100%);
  margin: 0 auto 4px !important;
}

body.app-bible-page .book-stage {
  width: min(620px, 100%) !important;
  max-width: 620px !important;
  margin: 0 auto !important;
  padding: 0 !important;
  justify-content: center !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  scrollbar-width: thin;
}

body.app-bible-page .book-stage.is-enlarged {
  justify-content: flex-start !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
}

body.app-bible-page .book-shell,
body.app-bible-page .book-stage.is-enlarged .book-shell {
  margin: 0 auto !important;
  padding: 0 !important;
  filter: none !important;
}

body.app-bible-page .book-stage.is-enlarged .book-shell {
  margin-left: 0 !important;
}

body.app-bible-page .book-page {
  border: 0 !important;
  border-radius: 2px !important;
  outline: 1px solid rgba(148, 109, 49, .62) !important;
  outline-offset: 0 !important;
  box-shadow: 0 10px 28px rgba(36, 27, 20, .10) !important;
}

body.app-bible-page canvas {
  border-radius: 0 !important;
  box-shadow: none !important;
}

body.app-bible-page .page-navigation {
  width: min(620px, 100%) !important;
  min-height: 50px !important;
  margin: 8px auto 0 !important;
  padding: 0 !important;
  display: grid !important;
  grid-template-columns: 46px minmax(0, 1fr) 46px !important;
  align-items: center !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.app-bible-page .page-arrow {
  width: 42px !important;
  height: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: transparent !important;
  color: #6f6255 !important;
  font-size: 1.85rem !important;
}

body.app-bible-page .page-arrow:hover,
body.app-bible-page .page-arrow:focus-visible {
  background: rgba(167, 119, 47, .08) !important;
  color: var(--oa-gold) !important;
  outline: 0 !important;
}

body.app-bible-page .location-label {
  color: var(--oa-muted) !important;
  font-size: .82rem !important;
  font-weight: 650 !important;
}

body.app-bible-page .text-reader {
  width: min(760px, 100%) !important;
  margin: 18px auto 0 !important;
  padding: 18px 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

@media (max-width: 820px) {
  body.app-bible-page .reader-page {
    width: calc(100% - 20px) !important;
    padding-top: 10px !important;
  }

  body.app-bible-page .bible-topbar {
    margin-bottom: 18px !important;
  }

  body.app-bible-page .bible-editorial-head {
    grid-template-columns: 26px minmax(0, 1fr);
    gap: 10px;
    margin-bottom: 14px;
  }

  body.app-bible-page .bible-editorial-copy h1 {
    font-size: 2rem;
  }

  body.app-bible-page .reader-toolbar {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 9px !important;
    margin-bottom: 12px !important;
  }

  body.app-bible-page .reader-select-group,
  body.app-bible-page .reader-tool-group {
    width: 100% !important;
    justify-content: center !important;
  }

  body.app-bible-page .book-select,
  body.app-bible-page .part-select {
    flex: 1 1 0 !important;
    width: auto !important;
    min-width: 0 !important;
  }

  body.app-bible-page .book-stage,
  body.app-bible-page .page-navigation {
    width: min(100%, 560px) !important;
  }
}

/* =========================================================
   v9, Bible reader, prayer modal and continuous chant library
   ========================================================= */

/* Prayer reader opens near the top so long prayers use the screen properly. */
.oa-modal {
  align-items: flex-start !important;
  padding: clamp(18px, 3vh, 32px) 18px 18px !important;
}

.oa-modal-panel {
  width: min(820px, 100%) !important;
  max-height: calc(100dvh - clamp(40px, 7vh, 72px)) !important;
  margin: 0 auto !important;
  border-radius: 8px !important;
}

/* Keep prayer links clean, without a decorative arrow or chevron. */
body.app-calendar-page .calendar-prayer-links a > span:last-child {
  display: none !important;
}

/* Listen, one continuous chant library. */
.oa-track-list-organised {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 0 !important;
  width: 100% !important;
}

.oa-track-group,
.oa-track-group-head,
.oa-track-group-list,
.oa-track-group-count {
  display: contents !important;
}

.oa-track {
  width: 100% !important;
  min-height: 76px !important;
  grid-template-columns: 68px minmax(0, 1fr) !important;
  gap: 14px !important;
  padding: 12px 10px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(111, 82, 49, .12) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.oa-track:last-child {
  border-bottom: 0 !important;
}

.oa-track:hover,
.oa-track:focus-visible,
.oa-track.is-playing {
  padding-left: 10px !important;
  background: rgba(167, 119, 47, .035) !important;
  outline: 0 !important;
}

.oa-track-play {
  width: 44px !important;
  height: 44px !important;
  margin: 0 0 0 8px !important;
  display: grid !important;
  place-items: center !important;
  align-self: center !important;
  border-radius: 50% !important;
  background: #efe0c3 !important;
  color: #7f5a27 !important;
}

.oa-track-play svg {
  width: 17px !important;
  height: 17px !important;
  display: block !important;
  transform: none !important;
}

.oa-track-copy {
  display: grid !important;
  align-content: center !important;
  gap: 5px !important;
}

.oa-track-copy strong {
  font-size: .98rem !important;
}

.oa-track-tradition {
  margin: 0 !important;
  color: var(--oa-gold) !important;
  font-size: .72rem !important;
  font-weight: 700 !important;
  letter-spacing: .08em !important;
  text-transform: uppercase !important;
}

/* Bible, a compact liturgical reader rather than a card-based utility page. */
body.app-bible-page {
  background: #f6f1e8 !important;
  color: var(--oa-ink) !important;
}

body.app-bible-page .reader-page {
  width: min(1120px, calc(100% - 32px)) !important;
  margin: 0 auto !important;
  padding: 18px 0 42px !important;
}

body.app-bible-page .bible-topbar {
  max-width: 940px !important;
  margin: 0 auto 18px !important;
}

body.app-bible-page .bible-editorial-head {
  position: relative !important;
  isolation: isolate !important;
  width: min(940px, 100%) !important;
  min-height: 154px !important;
  margin: 0 auto 20px !important;
  padding: 28px 34px !important;
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 18px !important;
  overflow: hidden !important;
  border: 0 !important;
  border-radius: 4px !important;
  background: linear-gradient(102deg, #271812 0%, #3a2117 58%, #5b3522 100%) !important;
  color: #fffaf2 !important;
  box-shadow: none !important;
}

body.app-bible-page .bible-editorial-head::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: -58%;
  right: -1%;
  width: 310px;
  height: 310px;
  border: 1px solid rgba(222, 181, 105, .13);
  border-radius: 50%;
}

body.app-bible-page .bible-editorial-mark {
  padding: 0 !important;
  color: #d5a850 !important;
  font-size: 2rem !important;
  text-align: center !important;
}

body.app-bible-page .bible-kicker {
  margin: 0 0 6px !important;
  color: #e0b664 !important;
  font-size: .69rem !important;
  font-weight: 750 !important;
  letter-spacing: .18em !important;
  text-transform: uppercase !important;
}

body.app-bible-page .bible-editorial-copy h1 {
  margin: 0 0 7px !important;
  color: #fffaf2 !important;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: clamp(2.15rem, 4vw, 3.25rem) !important;
  font-weight: 500 !important;
  line-height: .98 !important;
}

body.app-bible-page .bible-editorial-copy > p:last-child {
  max-width: 630px !important;
  margin: 0 !important;
  color: rgba(255, 250, 242, .72) !important;
  font-size: .9rem !important;
  line-height: 1.5 !important;
}

body.app-bible-page .bible-editorial-rule {
  display: none !important;
}

body.app-bible-page .reader-toolbar {
  width: min(820px, 100%) !important;
  max-width: none !important;
  margin: 0 auto 15px !important;
  padding: 0 0 10px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 20px !important;
  overflow: visible !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(108, 78, 45, .14) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

body.app-bible-page .reader-select-group,
body.app-bible-page .reader-tool-group {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}

body.app-bible-page .reader-select-group {
  flex: 1 1 auto !important;
  min-width: 0 !important;
}

body.app-bible-page .reader-tool-group {
  flex: 0 0 auto !important;
}

body.app-bible-page .reader-toolbar select {
  height: 36px !important;
  min-height: 36px !important;
  padding: 0 24px 0 2px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(91, 69, 50, .24) !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: var(--oa-ink) !important;
  box-shadow: none !important;
  font-size: .84rem !important;
}

body.app-bible-page .book-select {
  width: min(300px, 43vw) !important;
}

body.app-bible-page .part-select {
  width: min(160px, 24vw) !important;
}

body.app-bible-page .reader-toolbar .icon-tool {
  display: grid !important;
  place-items: center !important;
  flex: 0 0 32px !important;
  width: 32px !important;
  height: 32px !important;
  min-height: 32px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #716354 !important;
  box-shadow: none !important;
}

body.app-bible-page .reader-toolbar .icon-tool:hover,
body.app-bible-page .reader-toolbar .icon-tool:focus-visible,
body.app-bible-page .reader-toolbar .icon-tool.is-active,
body.app-bible-page .reader-toolbar .icon-tool[aria-pressed="true"] {
  color: var(--oa-gold) !important;
  background: transparent !important;
  outline: 0 !important;
}

body.app-bible-page .reader-toolbar .text-size-tool {
  flex-basis: 34px !important;
  width: 34px !important;
  font-family: Georgia, "Times New Roman", serif !important;
}

body.app-bible-page .reader-status {
  width: min(760px, 100%) !important;
  margin: 0 auto 5px !important;
}

body.app-bible-page .bible-reading-deck {
  position: relative !important;
  width: min(660px, 100%) !important;
  min-height: 360px !important;
  margin: 0 auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow-anchor: none !important;
}

body.app-bible-page .book-stage {
  width: min(540px, calc(100% - 108px)) !important;
  max-width: 540px !important;
  min-width: 0 !important;
  margin: 0 auto !important;
  padding: 4px 0 !important;
  justify-content: center !important;
  overflow: visible !important;
  overflow-anchor: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.app-bible-page .book-stage.is-enlarged {
  justify-content: flex-start !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
}

body.app-bible-page .book-shell,
body.app-bible-page .book-stage.is-enlarged .book-shell {
  margin: 0 auto !important;
  padding: 0 !important;
  filter: none !important;
}

body.app-bible-page .book-page {
  border: 0 !important;
  border-radius: 1px !important;
  outline: 1px solid rgba(148, 109, 49, .55) !important;
  outline-offset: 0 !important;
  box-shadow: 0 8px 20px rgba(36, 27, 20, .09) !important;
}

body.app-bible-page .bible-side-arrow {
  position: absolute !important;
  z-index: 5 !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  width: 46px !important;
  height: 64px !important;
  min-height: 64px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #6b5d4f !important;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: 2.25rem !important;
  font-weight: 400 !important;
  line-height: 1 !important;
  box-shadow: none !important;
}

body.app-bible-page .bible-side-arrow:hover,
body.app-bible-page .bible-side-arrow:focus-visible {
  color: var(--oa-gold) !important;
  background: transparent !important;
  outline: 0 !important;
}

body.app-bible-page .page-arrow-left {
  left: 0 !important;
}

body.app-bible-page .page-arrow-right {
  right: 0 !important;
}

body.app-bible-page .page-arrow-left:hover,
body.app-bible-page .page-arrow-left:focus-visible {
  transform: translate(-4px, -50%) !important;
}

body.app-bible-page .page-arrow-right:hover,
body.app-bible-page .page-arrow-right:focus-visible {
  transform: translate(4px, -50%) !important;
}

body.app-bible-page .bible-location-line {
  width: min(540px, calc(100% - 108px)) !important;
  margin: 7px auto 0 !important;
  min-height: 24px !important;
  text-align: center !important;
}

body.app-bible-page .location-label {
  color: #796b5d !important;
  font-size: .78rem !important;
  font-weight: 650 !important;
}

body.app-bible-page .text-reader {
  width: min(820px, 100%) !important;
  margin: 20px auto 0 !important;
  padding: 18px 0 !important;
  border: 0 !important;
  border-top: 1px solid rgba(108, 78, 45, .14) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

@media (max-width: 820px) {
  .oa-modal {
    padding: max(10px, env(safe-area-inset-top)) 10px 10px !important;
  }

  .oa-modal-panel {
    max-height: calc(100dvh - 22px) !important;
  }

  body.app-bible-page .reader-page {
    width: calc(100% - 20px) !important;
    padding-top: 10px !important;
  }

  body.app-bible-page .bible-topbar {
    margin-bottom: 14px !important;
  }

  body.app-bible-page .bible-editorial-head {
    min-height: 132px !important;
    padding: 22px 20px !important;
    grid-template-columns: 30px minmax(0, 1fr) !important;
    gap: 12px !important;
  }

  body.app-bible-page .bible-editorial-mark {
    font-size: 1.55rem !important;
  }

  body.app-bible-page .bible-editorial-copy h1 {
    font-size: clamp(1.85rem, 8vw, 2.45rem) !important;
  }

  body.app-bible-page .bible-editorial-copy > p:last-child {
    font-size: .82rem !important;
  }

  body.app-bible-page .reader-toolbar {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    margin-bottom: 10px !important;
  }

  body.app-bible-page .reader-select-group,
  body.app-bible-page .reader-tool-group {
    width: 100% !important;
    justify-content: center !important;
  }

  body.app-bible-page .book-select,
  body.app-bible-page .part-select {
    flex: 1 1 0 !important;
    width: auto !important;
    min-width: 0 !important;
  }

  body.app-bible-page .bible-reading-deck {
    width: 100% !important;
    min-height: 300px !important;
  }

  body.app-bible-page .book-stage,
  body.app-bible-page .bible-location-line {
    width: calc(100% - 72px) !important;
    max-width: 500px !important;
  }

  body.app-bible-page .bible-side-arrow {
    width: 34px !important;
    font-size: 1.8rem !important;
  }
}

@media (max-width: 520px) {
  .oa-track {
    grid-template-columns: 58px minmax(0, 1fr) !important;
    padding-inline: 4px !important;
  }

  .oa-track-play {
    margin-left: 4px !important;
    width: 40px !important;
    height: 40px !important;
  }

  body.app-bible-page .bible-editorial-head {
    min-height: 118px !important;
    padding: 18px 16px !important;
  }

  body.app-bible-page .bible-editorial-copy > p:last-child {
    display: none !important;
  }

  body.app-bible-page .reader-tool-group {
    gap: 4px !important;
  }

  body.app-bible-page .book-stage,
  body.app-bible-page .bible-location-line {
    width: calc(100% - 58px) !important;
  }

  body.app-bible-page .bible-side-arrow {
    width: 28px !important;
  }
}


/* =========================================================
   v10, prayer link repair and animated split tradition selector
   ========================================================= */

/* Repair the prayer links inside the calendar. Earlier arrow-hiding rules were hiding the only span. */
body.app-calendar-page .calendar-prayer-links a > span:last-child {
  display: inline !important;
  color: inherit !important;
  transform: none !important;
  opacity: 1 !important;
}

body.app-calendar-page .calendar-prayer-links {
  display: grid !important;
  gap: 0 !important;
}

body.app-calendar-page .calendar-prayer-links a {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
  min-height: 52px !important;
  padding: 12px 0 !important;
  border-bottom: 1px solid rgba(133, 102, 61, .16) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.app-calendar-page .calendar-prayer-links a::after {
  content: '↗';
  font-size: .9rem;
  color: rgba(159, 117, 52, .92);
  transition: transform .22s ease, opacity .22s ease;
  opacity: .72;
}

body.app-calendar-page .calendar-prayer-links a:hover::after,
body.app-calendar-page .calendar-prayer-links a:focus-visible::after {
  transform: translateX(3px) translateY(-1px);
  opacity: 1;
}

body.app-calendar-page .calendar-prayer-links a:hover,
body.app-calendar-page .calendar-prayer-links a:focus-visible {
  color: #7d551b !important;
}

/* One long animated tradition button, shared by home and calendar selection page. */
.oa-tradition-split-wrap {
  margin-top: 8px;
}

.oa-tradition-split {
  position: relative;
  display: flex;
  min-height: 280px;
  border-radius: 28px;
  overflow: hidden;
  background: #1e140f;
  border: 1px solid rgba(87, 61, 34, .18);
  box-shadow: 0 18px 36px rgba(41, 28, 18, .08);
  isolation: isolate;
}

.oa-tradition-split::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 18px;
  bottom: 18px;
  width: 2px;
  background: linear-gradient(180deg, rgba(232,199,141,.06), rgba(240,208,158,.72), rgba(232,199,141,.06));
  transform: translateX(-50%) skewX(-14deg);
  transform-origin: center;
  z-index: 5;
  pointer-events: none;
  transition: opacity .28s ease, transform .34s ease;
}

.oa-tradition-pane {
  position: relative;
  flex: 1 1 50%;
  min-width: 0;
  text-decoration: none;
  color: #fff9f0;
  overflow: hidden;
  transition: flex-grow .42s cubic-bezier(.22,.61,.36,1), filter .3s ease;
}

.oa-tradition-pane img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.01);
  transition: transform .55s ease, filter .35s ease;
}

.oa-tradition-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(23,16,12,.12) 0%, rgba(23,16,12,.32) 35%, rgba(23,16,12,.82) 100%);
}

.oa-tradition-pane.is-russian .oa-tradition-overlay {
  background: linear-gradient(180deg, rgba(25,16,10,.2) 0%, rgba(26,16,10,.42) 32%, rgba(26,16,10,.9) 100%);
}

.oa-tradition-copy {
  position: absolute;
  inset: auto 24px 22px 24px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 34ch;
}

.oa-tradition-copy small {
  font-size: .72rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #e9c277;
  font-weight: 700;
}

.oa-tradition-copy strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.8rem, 3vw, 2.85rem);
  line-height: .98;
  font-weight: 700;
}

.oa-tradition-copy em {
  font-style: normal;
  font-size: 1rem;
  line-height: 1.5;
  color: rgba(255, 245, 229, .9);
}

@supports selector(.oa-tradition-split:has(.oa-tradition-pane:hover)) {
  .oa-tradition-split:has(.oa-tradition-pane:hover) .oa-tradition-pane,
  .oa-tradition-split:has(.oa-tradition-pane:focus-visible) .oa-tradition-pane {
    flex-grow: .92;
  }

  .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover) .oa-tradition-pane.is-greek,
  .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible) .oa-tradition-pane.is-greek,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover) .oa-tradition-pane.is-russian,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible) .oa-tradition-pane.is-russian {
    flex-grow: 1.18;
  }

  .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover)::before,
  .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible)::before {
    transform: translateX(-15px) skewX(-14deg);
  }

  .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover)::before,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible)::before {
    transform: translateX(15px) skewX(-14deg);
  }
}

.oa-tradition-pane:hover img,
.oa-tradition-pane:focus-visible img {
  transform: scale(1.045);
  filter: saturate(1.06);
}

.oa-tradition-pane:hover .oa-tradition-copy strong,
.oa-tradition-pane:focus-visible .oa-tradition-copy strong {
  text-shadow: 0 10px 22px rgba(0,0,0,.28);
}

.oa-tradition-pane:focus-visible {
  outline: 2px solid rgba(228, 190, 119, .88);
  outline-offset: -2px;
}

.oa-tradition-page-wrap .oa-tradition-split {
  min-height: 340px;
}

@media (max-width: 860px) {
  .oa-tradition-split {
    min-height: 420px;
    flex-direction: column;
  }

  .oa-tradition-split::before {
    left: 24px;
    right: 24px;
    top: 50%;
    bottom: auto;
    width: auto;
    height: 2px;
    transform: translateY(-50%) skewX(-10deg);
  }

  @supports selector(.oa-tradition-split:has(.oa-tradition-pane:hover)) {
    .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover)::before,
    .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible)::before {
      transform: translateY(-18px) skewX(-10deg);
    }

    .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover)::before,
    .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible)::before {
      transform: translateY(18px) skewX(-10deg);
    }
  }

  .oa-tradition-copy strong {
    font-size: clamp(1.55rem, 6vw, 2.1rem);
  }
}

/* =========================================================
   v11, true split gap and stronger tradition expansion
   ========================================================= */

.oa-tradition-split {
  display: flex !important;
  gap: 10px !important;
  min-height: 280px;
  overflow: hidden !important;
  background: var(--oa-bg) !important;
  border: 1px solid rgba(87, 61, 34, .14) !important;
  border-radius: 28px !important;
  box-shadow: 0 18px 36px rgba(41, 28, 18, .06) !important;
}

/* The divider is now a genuine empty gap between the two images. */
.oa-tradition-split::before {
  display: none !important;
  content: none !important;
}

.oa-tradition-pane {
  flex: 1 1 0 !important;
  min-width: 0 !important;
  border-radius: 22px !important;
  overflow: hidden !important;
  transition:
    flex-grow .52s cubic-bezier(.2,.72,.2,1),
    filter .32s ease,
    opacity .32s ease !important;
}

/* Hovering either tradition makes it occupy almost the whole selector. */
@supports selector(.oa-tradition-split:has(.oa-tradition-pane:hover)) {
  .oa-tradition-split:has(.oa-tradition-pane:hover) .oa-tradition-pane,
  .oa-tradition-split:has(.oa-tradition-pane:focus-visible) .oa-tradition-pane {
    flex-grow: 1 !important;
  }

  .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover) .oa-tradition-pane.is-greek,
  .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible) .oa-tradition-pane.is-greek,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover) .oa-tradition-pane.is-russian,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible) .oa-tradition-pane.is-russian {
    flex-grow: 8.5 !important;
  }

  .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover) .oa-tradition-pane.is-russian,
  .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible) .oa-tradition-pane.is-russian,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover) .oa-tradition-pane.is-greek,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible) .oa-tradition-pane.is-greek {
    flex-grow: 1 !important;
    filter: saturate(.78) brightness(.72) !important;
  }
}

.oa-tradition-pane img {
  transition: transform .62s cubic-bezier(.2,.72,.2,1), filter .32s ease !important;
}

.oa-tradition-pane:hover img,
.oa-tradition-pane:focus-visible img {
  transform: scale(1.055) !important;
}

/* Keep the collapsed side readable but restrained. */
@supports selector(.oa-tradition-split:has(.oa-tradition-pane:hover)) {
  .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover) .oa-tradition-pane.is-russian .oa-tradition-copy em,
  .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible) .oa-tradition-pane.is-russian .oa-tradition-copy em,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover) .oa-tradition-pane.is-greek .oa-tradition-copy em,
  .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible) .oa-tradition-pane.is-greek .oa-tradition-copy em {
    opacity: 0 !important;
    transform: translateY(6px) !important;
  }

  .oa-tradition-copy em {
    transition: opacity .22s ease, transform .28s ease !important;
  }
}

@media (max-width: 860px) {
  .oa-tradition-split {
    min-height: 400px !important;
    flex-direction: column !important;
    gap: 10px !important;
  }

  .oa-tradition-pane {
    flex: 1 1 0 !important;
  }

  /* Touch layouts stay balanced. The large expansion is a pointer-hover effect. */
  @media (hover: hover) and (pointer: fine) {
    @supports selector(.oa-tradition-split:has(.oa-tradition-pane:hover)) {
      .oa-tradition-split:has(.oa-tradition-pane.is-greek:hover) .oa-tradition-pane.is-greek,
      .oa-tradition-split:has(.oa-tradition-pane.is-greek:focus-visible) .oa-tradition-pane.is-greek,
      .oa-tradition-split:has(.oa-tradition-pane.is-russian:hover) .oa-tradition-pane.is-russian,
      .oa-tradition-split:has(.oa-tradition-pane.is-russian:focus-visible) .oa-tradition-pane.is-russian {
        flex-grow: 5 !important;
      }
    }
  }
}


/* =========================================================
   v12, simplified calendar entry on Home and classic selection cards
   ========================================================= */

.oa-calendar-home-button {
  position: relative;
  display: block;
  min-height: 260px;
  overflow: hidden;
  border-radius: 18px;
  text-decoration: none;
  color: #fffaf1;
  background: #21160f;
  isolation: isolate;
}

.oa-calendar-home-images {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  z-index: -3;
}

.oa-calendar-home-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .55s ease, filter .4s ease;
}

.oa-calendar-home-shade {
  position: absolute;
  inset: 0;
  z-index: -2;
  background: linear-gradient(90deg, rgba(25,16,11,.80) 0%, rgba(25,16,11,.62) 48%, rgba(25,16,11,.66) 52%, rgba(25,16,11,.82) 100%);
}

.oa-calendar-home-copy {
  position: absolute;
  left: clamp(22px, 4vw, 46px);
  bottom: clamp(22px, 4vw, 42px);
  display: grid;
  gap: 7px;
  max-width: 620px;
}

.oa-calendar-home-copy small {
  color: #e5bb6e;
  text-transform: uppercase;
  letter-spacing: .15em;
  font-size: .72rem;
  font-weight: 750;
}

.oa-calendar-home-copy strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.9rem, 4vw, 3.2rem);
  line-height: 1;
}

.oa-calendar-home-copy > span {
  color: rgba(255,250,241,.82);
  line-height: 1.5;
}

.oa-calendar-home-enter {
  position: absolute;
  right: clamp(22px, 4vw, 42px);
  bottom: clamp(22px, 4vw, 42px);
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid rgba(237,202,139,.48);
  border-radius: 999px;
  color: #f4d696;
  font-size: .82rem;
  font-weight: 750;
  letter-spacing: .05em;
  transition: background .25s ease, color .25s ease, transform .25s ease;
}

.oa-calendar-home-button:hover .oa-calendar-home-images img:first-child,
.oa-calendar-home-button:focus-visible .oa-calendar-home-images img:first-child {
  transform: scale(1.035) translateX(-4px);
}

.oa-calendar-home-button:hover .oa-calendar-home-images img:last-child,
.oa-calendar-home-button:focus-visible .oa-calendar-home-images img:last-child {
  transform: scale(1.035) translateX(4px);
}

.oa-calendar-home-button:hover .oa-calendar-home-enter,
.oa-calendar-home-button:focus-visible .oa-calendar-home-enter {
  background: #f1d291;
  color: #281a10;
  transform: translateY(-2px);
}

.oa-calendar-home-button:focus-visible {
  outline: 3px solid rgba(181,130,54,.42);
  outline-offset: 4px;
}

/* Restore the calendar selection screen to two separate choice cards. */
.oa-calendar-choice-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 16px !important;
  margin-top: 26px !important;
}

.oa-calendar-choice {
  min-height: 360px !important;
}

@media (max-width: 760px) {
  .oa-calendar-home-button { min-height: 320px; }
  .oa-calendar-home-copy { right: 22px; bottom: 78px; }
  .oa-calendar-home-enter { left: 22px; right: auto; bottom: 22px; }
  .oa-calendar-choice-grid { grid-template-columns: 1fr !important; }
  .oa-calendar-choice { min-height: 300px !important; }
}


/* =========================================================
   v13, single home calendar image and cleaner prayer links
   ========================================================= */

.oa-calendar-home-image {
  position: absolute;
  inset: 0;
  z-index: -3;
}

.oa-calendar-home-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .55s ease, filter .35s ease;
}

.oa-calendar-home-shade {
  background: linear-gradient(90deg, rgba(25,16,11,.70) 0%, rgba(25,16,11,.50) 42%, rgba(25,16,11,.58) 100%) !important;
}

.oa-calendar-home-button:hover .oa-calendar-home-image img,
.oa-calendar-home-button:focus-visible .oa-calendar-home-image img {
  transform: scale(1.035);
  filter: saturate(1.04);
}

.oa-calendar-home-button:hover .oa-calendar-home-enter,
.oa-calendar-home-button:focus-visible .oa-calendar-home-enter {
  transform: translateY(-2px);
}

/* Neutralise old two-image behaviour. */
.oa-calendar-home-images { display: none !important; }

/* Calendar prayer links should be simple text links only, no arrows. */
body.app-calendar-page .calendar-prayer-links a::after {
  display: none !important;
  content: none !important;
}

body.app-calendar-page .calendar-prayer-links a {
  justify-content: flex-start !important;
  gap: 0 !important;
}

body.app-calendar-page .calendar-prayer-links a > span:last-child {
  display: inline !important;
}

/* =========================================================
   v14, shared footer, persistent audio handoff and calendar alignment
   ========================================================= */

/* Legacy back links are no longer part of the app navigation. */
.back-link,
.calendar-selector-link,
[data-back-button] {
  display: none !important;
}

/* The home calendar image is the action itself, so no extra Open badge. */
.oa-calendar-home-enter {
  display: none !important;
}

/* Shared site footer. Flat, restrained and consistent on every screen. */
.oa-site-footer {
  width: 100%;
  margin-top: clamp(48px, 7vw, 88px);
  padding: 26px 0 18px;
  border-top: 1px solid rgba(99, 73, 45, .16);
  color: var(--oa-muted, #74685b);
}

.oa-site-footer-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.oa-site-footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  color: var(--oa-ink, #2b2118);
  text-decoration: none;
}

.oa-site-footer-brand img {
  width: 34px;
  height: 42px;
  object-fit: contain;
  flex: 0 0 auto;
}

.oa-site-footer-brand span {
  display: grid;
  gap: 2px;
}

.oa-site-footer-brand strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
  font-weight: 700;
}

.oa-site-footer-brand small {
  color: var(--oa-muted, #74685b);
  font-size: .7rem;
}

.oa-site-footer-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 22px;
}

.oa-site-footer-nav a,
.oa-site-footer-bottom a {
  color: inherit;
  text-decoration: none;
  font-size: .78rem;
  font-weight: 650;
  transition: color .18s ease;
}

.oa-site-footer-nav a:hover,
.oa-site-footer-nav a:focus-visible,
.oa-site-footer-bottom a:hover,
.oa-site-footer-bottom a:focus-visible {
  color: var(--oa-gold, #a7772f);
}

.oa-site-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid rgba(99, 73, 45, .09);
  font-size: .72rem;
}

body.app-calendar-page .oa-site-footer {
  padding-inline: 0;
}

/* Audio close control, kept out of the player grid so alignment stays intact. */
.oa-player {
  position: fixed;
  padding-right: 48px !important;
}

.oa-player-close {
  position: absolute;
  top: 9px;
  right: 10px;
  z-index: 3;
  width: 28px;
  height: 28px;
  min-height: 28px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(255,255,255,.66);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
}

.oa-player-close:hover,
.oa-player-close:focus-visible {
  background: rgba(255,255,255,.09);
  color: #fff;
  outline: none;
}

/* Match Today and Calendar to the centred Sacred sound heading. */
body.app-calendar-page .liturgical-date-block,
body.app-calendar-page .calendar-toggle-frame,
body.app-calendar-page .liturgical-audio {
  text-align: center !important;
}

body.app-calendar-page .liturgical-date-block > .liturgical-control-label,
body.app-calendar-page .calendar-toggle-frame > .liturgical-control-label,
body.app-calendar-page .liturgical-audio > .liturgical-control-label {
  display: block !important;
  width: 100% !important;
  text-align: center !important;
}

body.app-calendar-page .liturgical-date-block .header-meta,
body.app-calendar-page .liturgical-date-block .meta-date {
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
}

body.app-calendar-page .calendar-toggle-frame .calendar-toggle-group {
  width: 100% !important;
  justify-content: center !important;
  margin-inline: auto !important;
}

@media (max-width: 760px) {
  .oa-site-footer {
    margin-top: 48px;
    padding-bottom: calc(96px + env(safe-area-inset-bottom));
  }

  .oa-site-footer-main,
  .oa-site-footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .oa-site-footer-nav {
    justify-content: flex-start;
  }

  .oa-player {
    padding-right: 42px !important;
  }
}

/* =========================================================
   v15, thin footer and uninterrupted persistent-audio navigation
   ========================================================= */

.oa-site-footer {
  width: 100% !important;
  margin-top: 30px !important;
  padding: 9px 0 11px !important;
  border-top: 1px solid rgba(99, 73, 45, .12) !important;
  text-align: center !important;
  color: var(--oa-muted, #74685b) !important;
}

.oa-site-footer-copyright {
  color: inherit !important;
  text-decoration: none !important;
  font-size: .72rem !important;
  font-weight: 500 !important;
  letter-spacing: .01em !important;
}

.oa-site-footer-copyright:hover,
.oa-site-footer-copyright:focus-visible {
  color: var(--oa-gold, #a7772f) !important;
  outline: none !important;
}

/* Older footer structure can never make the footer bulky if a cached document contains it. */
.oa-site-footer-main,
.oa-site-footer-nav,
.oa-site-footer-bottom,
.oa-site-footer-brand {
  display: none !important;
}

@media (max-width: 760px) {
  .oa-site-footer {
    margin-top: 24px !important;
    padding: 8px 0 10px !important;
  }
}

/* When audio is active, internal pages load inside this full-screen app frame.
   The top-level audio element never unloads, so playback does not stop or jump. */
.oa-persistent-frame {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: var(--oa-bg, #f7f4ee);
  z-index: 1100;
}

html.oa-persistent-audio-shell,
html.oa-persistent-audio-shell body {
  overflow: hidden !important;
}

html.oa-persistent-audio-shell .oa-player {
  z-index: 1400 !important;
}


/* =========================================================
   v17, Bible without duplicate app branding and gapless audio navigation
   ========================================================= */
body.app-bible-page .bible-topbar {
  display: none !important;
}

body.app-bible-page .bible-editorial-head {
  margin-top: clamp(14px, 2.4vw, 30px) !important;
}

/* Keep the persistent page frame below the audio player and above the old page. */
.oa-persistent-frame {
  z-index: 1250 !important;
}
html.oa-persistent-audio-shell .oa-player {
  z-index: 1500 !important;
}


/* Daily Orthodox Life branding */
.oa-site-footer-copyright a {
  color: inherit;
  text-decoration: none;
}
.oa-site-footer-copyright a:hover,
.oa-site-footer-copyright a:focus-visible {
  color: var(--oa-gold, #a17436);
  text-decoration: underline;
}


/* =========================================================
   Mk15, audio sleep timer
   ========================================================= */

.oa-player-timer {
  position: absolute;
  top: 10px;
  right: 43px;
  z-index: 4;
  width: 28px;
  height: 28px;
  min-height: 28px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(255,255,255,.68);
  cursor: pointer;
}

.oa-player-timer svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.oa-player-timer:hover,
.oa-player-timer:focus-visible,
.oa-player-timer.is-active {
  background: rgba(255,255,255,.09);
  color: #fff7e9;
  outline: none;
}

.oa-player-timer-badge,
#audio-sleep-timer-badge {
  position: absolute;
  top: 25px;
  right: 50%;
  transform: translateX(50%);
  min-width: max-content;
  color: #e5bb6e;
  font-size: .56rem;
  font-weight: 750;
  line-height: 1;
  letter-spacing: .01em;
  pointer-events: none;
}

.oa-sleep-panel {
  position: absolute;
  right: 8px;
  bottom: calc(100% + 8px);
  z-index: 8;
  width: min(290px, calc(100vw - 34px));
  padding: 14px;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 12px;
  background: #2a1d15;
  color: #fff7e9;
  box-shadow: 0 14px 34px rgba(20,14,10,.28);
}

.oa-sleep-panel[hidden] {
  display: none !important;
}

.oa-sleep-panel > strong {
  display: block;
  font-size: .86rem;
  margin-bottom: 2px;
}

.oa-sleep-note {
  display: block;
  color: rgba(255,255,255,.58);
  font-size: .68rem;
  margin-bottom: 10px;
}

.oa-sleep-presets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.oa-sleep-presets button,
.oa-sleep-custom button,
.oa-sleep-cancel {
  min-height: 34px;
  padding: 0 9px;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 7px;
  background: rgba(255,255,255,.06);
  color: #fff7e9;
  font: inherit;
  font-size: .7rem;
  cursor: pointer;
}

.oa-sleep-presets button:hover,
.oa-sleep-presets button:focus-visible,
.oa-sleep-custom button:hover,
.oa-sleep-custom button:focus-visible,
.oa-sleep-cancel:hover,
.oa-sleep-cancel:focus-visible {
  background: rgba(255,255,255,.12);
  outline: none;
}

.oa-sleep-custom {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 7px;
  margin-top: 8px;
}

.oa-sleep-custom label {
  color: rgba(255,255,255,.68);
  font-size: .68rem;
}

.oa-sleep-custom input {
  min-width: 0;
  height: 34px;
  padding: 0 8px;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 7px;
  background: rgba(255,255,255,.06);
  color: #fff;
  font: inherit;
  font-size: .72rem;
  outline: none;
}

.oa-sleep-custom input::placeholder {
  color: rgba(255,255,255,.42);
}

.oa-sleep-custom input:focus {
  border-color: rgba(229,187,110,.72);
}

.oa-sleep-cancel {
  width: 100%;
  margin-top: 8px;
  color: #e5bb6e;
}

@media (max-width: 560px) {
  .oa-player {
    padding-right: 78px !important;
  }

  .oa-sleep-panel {
    right: -2px;
  }

  .oa-sleep-presets {
    grid-template-columns: repeat(2, 1fr);
  }
}


/* =========================================================
   Mk16, balanced player controls and volume
   ========================================================= */

.oa-player {
  grid-template-columns: minmax(170px, 1fr) auto minmax(220px, 1fr) !important;
  column-gap: clamp(16px, 2.2vw, 30px) !important;
  row-gap: 13px !important;
  padding: 14px 18px !important;
}

.oa-player-meta {
  grid-column: 1 !important;
  align-self: center;
}

.oa-player-controls {
  grid-column: 2 !important;
  justify-self: center !important;
  gap: 9px !important;
}

.oa-player-tools {
  grid-column: 3 !important;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.oa-player-progress {
  grid-column: 1 / -1 !important;
}

.oa-player-close,
.oa-player-timer {
  position: static !important;
  inset: auto !important;
  flex: 0 0 auto;
  width: 30px !important;
  height: 30px !important;
  min-height: 30px !important;
}

.oa-player-close {
  font-size: 1.05rem !important;
}

.oa-player-timer-badge,
#audio-sleep-timer-badge {
  top: 27px !important;
}

.oa-player-volume {
  display: grid;
  grid-template-columns: 24px minmax(62px, 100px) 24px;
  align-items: center;
  gap: 5px;
  min-width: 120px;
}

.oa-volume-step {
  width: 24px;
  height: 24px;
  min-height: 24px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(255,255,255,.72);
  font-size: .95rem;
  line-height: 1;
  cursor: pointer;
}

.oa-volume-step:hover,
.oa-volume-step:focus-visible {
  background: rgba(255,255,255,.09);
  color: #fff;
  outline: none;
}

.oa-player-volume input[type="range"] {
  width: 100%;
  min-width: 0;
  accent-color: #d5ad68;
  cursor: pointer;
}

.oa-sleep-panel {
  right: 0 !important;
  bottom: calc(100% + 10px) !important;
}

@media (max-width: 860px) {
  .oa-player {
    grid-template-columns: minmax(0, 1fr) auto !important;
    padding: 13px 15px !important;
  }

  .oa-player-meta { grid-column: 1 !important; }
  .oa-player-tools { grid-column: 2 !important; }

  .oa-player-controls {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    justify-self: center !important;
  }

  .oa-player-progress { grid-row: 3 !important; }
}

@media (max-width: 560px) {
  .oa-player {
    grid-template-columns: 1fr !important;
    padding: 13px 14px !important;
    row-gap: 10px !important;
  }

  .oa-player-meta,
  .oa-player-controls,
  .oa-player-tools,
  .oa-player-progress {
    grid-column: 1 !important;
  }

  .oa-player-meta { grid-row: 1 !important; }

  .oa-player-controls {
    grid-row: 2 !important;
    justify-self: center !important;
  }

  .oa-player-tools {
    grid-row: 3 !important;
    justify-self: center !important;
    justify-content: center !important;
  }

  .oa-player-progress { grid-row: 4 !important; }

  .oa-player-volume {
    grid-template-columns: 22px minmax(76px, 110px) 22px;
  }

  .oa-sleep-panel {
    right: 50% !important;
    transform: translateX(50%);
    width: min(290px, calc(100vw - 28px)) !important;
  }
}

/* Mk17 SEO: semantic hero headings retain the existing visual treatment. */
.oa-hero h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.35rem, 6vw, 4.6rem);
  line-height: .98;
  font-weight: 500;
}
.oa-hero-carousel .oa-hero-content h2 { max-width: 760px; }
@media (max-width: 760px) {
  .oa-hero h2,
  .oa-hero-carousel .oa-hero-content h2 { font-size: 2.35rem; }
}

/* =========================================================
   Accessibility controls and consistent vector prayer cross
   ========================================================= */

.oa-prayer-cross {
  display: grid !important;
  place-items: center !important;
  width: 20px !important;
  height: 28px !important;
  color: #a7772f !important;
  line-height: 1 !important;
}

.oa-prayer-cross svg {
  display: block;
  width: 13px;
  height: 21px;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.35;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.oa-accessibility {
  position: fixed;
  top: max(12px, env(safe-area-inset-top));
  right: max(12px, env(safe-area-inset-right));
  z-index: 10040;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.oa-accessibility-toggle {
  width: 40px;
  height: 40px;
  min-height: 40px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(91, 66, 41, .2);
  border-radius: 50%;
  background: rgba(248, 244, 236, .94);
  color: #493426;
  box-shadow: 0 4px 16px rgba(38, 27, 19, .08);
  backdrop-filter: blur(8px);
  cursor: pointer;
}

.oa-accessibility-toggle svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.oa-accessibility-toggle:hover,
.oa-accessibility-toggle:focus-visible {
  border-color: rgba(167, 119, 47, .5);
  color: #8a5d22;
  outline: 3px solid rgba(167, 119, 47, .17);
  outline-offset: 2px;
}

.oa-accessibility-panel {
  position: absolute;
  top: 48px;
  right: 0;
  width: min(310px, calc(100vw - 24px));
  padding: 15px;
  border: 1px solid rgba(91, 66, 41, .16);
  border-radius: 12px;
  background: #fbf8f2;
  color: #2e2118;
  box-shadow: 0 16px 38px rgba(37, 25, 17, .16);
}

.oa-accessibility-panel[hidden] { display: none !important; }

.oa-accessibility-panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.oa-accessibility-panel header strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
}

.oa-accessibility-close {
  width: 28px;
  height: 28px;
  min-height: 28px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #6c5c50;
  font-size: 1.15rem;
  cursor: pointer;
}

.oa-a11y-field,
.oa-a11y-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 42px;
  border-top: 1px solid rgba(91, 66, 41, .10);
  font-size: .78rem;
}

.oa-a11y-field select {
  max-width: 160px;
  min-height: 32px;
  padding: 4px 26px 4px 8px;
  border: 1px solid rgba(91, 66, 41, .18);
  border-radius: 6px;
  background: #fffdf9;
  color: #34251a;
  font: inherit;
}

.oa-a11y-switch input {
  width: 18px;
  height: 18px;
  accent-color: #9a6a2c;
}

.oa-a11y-reset {
  width: 100%;
  min-height: 34px;
  margin-top: 10px;
  border: 1px solid rgba(91, 66, 41, .16);
  border-radius: 6px;
  background: transparent;
  color: #704c21;
  font: inherit;
  font-size: .74rem;
  font-weight: 700;
  cursor: pointer;
}

.oa-accessibility-panel > small {
  display: block;
  margin-top: 9px;
  color: #796d62;
  font-size: .62rem;
  line-height: 1.4;
}

.oa-google-translate-host {
  position: fixed !important;
  left: -10000px !important;
  top: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

body.oa-a11y-reduce-motion *,
body.oa-a11y-reduce-motion *::before,
body.oa-a11y-reduce-motion *::after {
  animation-duration: .001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: .001ms !important;
  scroll-behavior: auto !important;
}

body.oa-a11y-underline-links a:not(.oa-dock-link) {
  text-decoration: underline !important;
  text-underline-offset: .18em;
}

body.oa-a11y-contrast {
  --oa-bg: #ffffff !important;
  --oa-surface: #ffffff !important;
  --oa-ink: #050505 !important;
  --oa-muted: #292929 !important;
  --oa-gold: #704700 !important;
  --oa-gold-soft: #fff0c9 !important;
}

body.oa-a11y-contrast .oa-page,
body.oa-a11y-contrast .reader-page,
body.oa-a11y-contrast .app-shell,
body.oa-a11y-contrast .oa-modal-panel,
body.oa-a11y-contrast .oa-accessibility-panel {
  color: #050505 !important;
}

body.oa-a11y-contrast :focus-visible {
  outline: 3px solid #111 !important;
  outline-offset: 3px !important;
}

@media (max-width: 760px) {
  .oa-accessibility {
    top: max(8px, env(safe-area-inset-top));
    right: max(8px, env(safe-area-inset-right));
  }
  .oa-accessibility-toggle {
    width: 36px;
    height: 36px;
    min-height: 36px;
  }
  .oa-accessibility-panel { top: 43px; }
}


/* =========================================================
   Mk19, prayer favourites and unobtrusive translation
   ========================================================= */

.oa-prayer-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  align-items: center;
  border-bottom: 1px solid rgba(111, 82, 49, .12);
}

.oa-prayer-row:last-child { border-bottom: 0; }

.oa-prayer-row .oa-prayer-card-button {
  border-bottom: 0 !important;
  min-width: 0;
  grid-template-columns: 22px minmax(0, 1fr) !important;
  padding-right: 6px !important;
}

.oa-prayer-favourite {
  width: 34px;
  height: 34px;
  min-height: 34px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #9b846a;
  cursor: pointer;
}

.oa-prayer-favourite svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.55;
  stroke-linejoin: round;
  transition: transform .16s ease, fill .16s ease, color .16s ease;
}

.oa-prayer-favourite:hover,
.oa-prayer-favourite:focus-visible {
  color: #9a6829;
  background: rgba(167, 119, 47, .07);
  outline: 2px solid rgba(167, 119, 47, .16);
  outline-offset: 1px;
}

.oa-prayer-favourite.is-favourite {
  color: #a7772f;
}

.oa-prayer-favourite.is-favourite svg {
  fill: currentColor;
  transform: scale(1.04);
}

.oa-favourite-count {
  display: inline-block;
  min-width: 1.25em;
  margin-left: .18em;
  font-size: .78em;
  opacity: .75;
}

/* Google Translate may inject a legacy or current toolbar. Keep translation active
   but prevent that toolbar from shifting or covering the app. */
body > .skiptranslate,
iframe.goog-te-banner-frame,
.goog-te-banner-frame,
.VIpgJd-ZVi9od-ORHb-OEVmcd,
.VIpgJd-ZVi9od-aZ2wEe-wOHMyf {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
}

html.translated-ltr,
html.translated-rtl,
html.translated-ltr body,
html.translated-rtl body,
body {
  top: 0 !important;
}


/* =========================================================
   Mk20, prayer categories and stable prayer list
   ========================================================= */

#prayer-filters.oa-chip-row {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center;
  gap: 7px 8px !important;
  overflow: visible !important;
  overflow-x: visible !important;
  white-space: normal !important;
  padding: 4px 0 8px !important;
  scrollbar-width: none;
}

#prayer-filters .oa-filter-chip {
  flex: 0 0 auto;
  white-space: nowrap !important;
}

/* The prayer index is interactive content, not an entrance animation target. */
#prayer-grid,
#prayer-grid.oa-reveal,
#prayer-grid.oa-reveal.is-visible {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
  animation: none !important;
}

/* =========================================================
   Mk21, seamless persistent translation and single a11y control
   ========================================================= */

/* Cross-document transitions let the previous page remain visually present
   while the next same-origin page is prepared. */
@view-transition {
  navigation: auto;
}

/* Never flash the English source page while a remembered translation is
   being restored. The translation bootstrap adds this class before first paint. */
html.oa-translation-pending body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  background: var(--oa-bg, #f7f4ee);
  pointer-events: none;
}

html.oa-translation-ready body::after {
  display: none !important;
}

/* In the persistent-audio shell, keep the previous page visible until the
   replacement iframe confirms its translation is ready. */
.oa-persistent-frame {
  opacity: 1;
  transition: opacity .12s ease;
}

.oa-persistent-frame.is-loading {
  opacity: 0;
  pointer-events: none;
  background: transparent !important;
}

/* The parent shell owns the one accessibility button while framed pages are open. */
html.oa-persistent-audio-shell .oa-accessibility {
  z-index: 1600 !important;
}


/* =========================================================
   Mk22, fast first load
   ========================================================= */

/* Translation must never block navigation or make the first page appear hung.
   A remembered language may visibly settle in shortly after load, but the app
   remains interactive throughout. */
html.oa-translation-pending body::after,
html.oa-translation-ready body::after {
  display: none !important;
  content: none !important;
}

/* Keep the accessibility control visible above the homepage carousel and all
   other ordinary page content. */
body > .oa-accessibility {
  position: fixed !important;
  z-index: 2147482000 !important;
  visibility: visible !important;
  opacity: 1 !important;
}


/* =========================================================
   Mk23, stable non-blocking translation
   ========================================================= */

/* Never cover or block the application while a translation service loads. */
html.oa-translation-pending body::after,
html.oa-translation-ready body::after {
  display: none !important;
  content: none !important;
}

/* Translation is no longer used to gate persistent-page visibility. */
.oa-persistent-frame,
.oa-persistent-frame.is-loading {
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* Accessibility control must be present on Home and every other top-level page. */
body > .oa-accessibility {
  display: block !important;
  position: fixed !important;
  z-index: 2147482000 !important;
  visibility: visible !important;
  opacity: 1 !important;
}


/* =========================================================
   Mk25, 404 page
   ========================================================= */

.oa-404-page {
  min-height: 100dvh;
  background:
    radial-gradient(circle at 50% 16%, rgba(174,126,61,.09), transparent 34rem),
    var(--oa-bg, #f7f4ee);
}

.oa-404-main {
  min-height: calc(100dvh - var(--oa-dock-h, 76px));
  display: grid;
  place-items: center;
  padding-top: clamp(30px, 5vw, 70px);
  padding-bottom: clamp(110px, 13vw, 150px);
}

.oa-404-content {
  width: min(850px, calc(100% - 28px));
  margin: 0 auto;
  text-align: center;
}

.oa-404-art {
  width: min(540px, 76vw);
  margin: 0 auto clamp(10px, 2vw, 22px);
}

.oa-404-art img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.oa-404-code {
  margin: 0 0 5px;
  color: var(--oa-gold, #a17436);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .22em;
  text-transform: uppercase;
}

.oa-404-content h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 5.5vw, 4rem);
  line-height: 1.02;
  font-weight: 500;
  color: var(--oa-ink, #2b2119);
}

.oa-404-copy {
  max-width: 600px;
  margin: 16px auto 0;
  color: var(--oa-muted, #75685c);
  font-size: clamp(.92rem, 1.8vw, 1.04rem);
  line-height: 1.65;
}

.oa-404-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 9px;
  margin-top: 25px;
}

.oa-404-actions a {
  min-width: 112px;
}

@media (max-width: 560px) {
  .oa-404-art {
    width: min(380px, 88vw);
  }

  .oa-404-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(360px, 100%);
    margin-left: auto;
    margin-right: auto;
  }

  .oa-404-actions a:first-child {
    grid-column: 1 / -1;
  }
}


/* =========================================================
   Mk25, minimisable audio shell
   ========================================================= */

.oa-player-minimise {
  position: static;
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(255,255,255,.72);
  cursor: pointer;
}

.oa-player-minimise svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform .2s ease;
}

.oa-player-minimise:hover,
.oa-player-minimise:focus-visible {
  background: rgba(255,255,255,.09);
  color: #fff7e9;
  outline: none;
}

.oa-player.is-minimized .oa-player-minimise svg {
  transform: rotate(180deg);
}

.oa-player.is-minimized {
  width: min(620px, calc(100% - 24px)) !important;
  bottom: 12px !important;
  grid-template-columns: auto 1fr auto !important;
  grid-template-rows: auto auto !important;
  column-gap: 10px !important;
  row-gap: 7px !important;
  padding: 8px 10px !important;
  border-radius: 14px !important;
}

.oa-player.is-minimized .oa-player-meta,
.oa-player.is-minimized .oa-player-volume {
  display: none !important;
}

.oa-player.is-minimized .oa-player-controls {
  grid-column: 1 !important;
  grid-row: 1 !important;
  justify-self: start !important;
  gap: 5px !important;
}

.oa-player.is-minimized .oa-player-tools {
  grid-column: 3 !important;
  grid-row: 1 !important;
  justify-self: end !important;
  justify-content: flex-end !important;
  gap: 5px !important;
}

.oa-player.is-minimized .oa-player-progress {
  grid-column: 1 / -1 !important;
  grid-row: 2 !important;
  display: grid !important;
  grid-template-columns: 34px minmax(0, 1fr) 34px !important;
  gap: 7px !important;
}

.oa-player.is-minimized .oa-player-btn {
  width: 34px !important;
  height: 34px !important;
}

.oa-player.is-minimized .oa-player-btn svg {
  width: 16px !important;
  height: 16px !important;
}

.oa-player.is-minimized .oa-player-timer,
.oa-player.is-minimized .oa-player-minimise,
.oa-player.is-minimized .oa-player-close {
  width: 30px !important;
  height: 30px !important;
  min-height: 30px !important;
}

.oa-player.is-minimized .oa-sleep-panel {
  right: 0 !important;
  bottom: calc(100% + 8px) !important;
  transform: none !important;
}

@media (max-width: 760px) {
  .oa-player.is-minimized {
    left: 6px !important;
    right: 6px !important;
    width: auto !important;
    bottom: calc(72px + env(safe-area-inset-bottom)) !important;
    transform: translateY(0) !important;
    grid-template-columns: 1fr auto !important;
    grid-template-rows: auto auto !important;
    padding: 7px 9px !important;
    border-radius: 12px !important;
  }

  .oa-player.is-minimized .oa-player-controls {
    grid-column: 1 !important;
    grid-row: 1 !important;
    justify-self: start !important;
  }

  .oa-player.is-minimized .oa-player-tools {
    grid-column: 2 !important;
    grid-row: 1 !important;
    justify-self: end !important;
  }

  .oa-player.is-minimized .oa-player-progress {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
  }

  .oa-player.is-minimized .oa-player-btn {
    width: 31px !important;
    height: 31px !important;
  }

  .oa-player.is-minimized .oa-player-timer,
  .oa-player.is-minimized .oa-player-minimise,
  .oa-player.is-minimized .oa-player-close {
    width: 28px !important;
    height: 28px !important;
    min-height: 28px !important;
  }
}

@media (max-width: 390px) {
  .oa-player.is-minimized .oa-player-controls,
  .oa-player.is-minimized .oa-player-tools {
    gap: 3px !important;
  }

  .oa-player.is-minimized .oa-player-btn {
    width: 29px !important;
    height: 29px !important;
  }

  .oa-player.is-minimized .oa-player-timer,
  .oa-player.is-minimized .oa-player-minimise,
  .oa-player.is-minimized .oa-player-close {
    width: 27px !important;
    height: 27px !important;
    min-height: 27px !important;
  }
}


/* =========================================================
   Mk26, 404 navigation contrast
   ========================================================= */

.oa-404-actions a {
  color: #2b2119 !important;
  background: rgba(255,255,255,.52) !important;
  border: 1px solid rgba(87,61,34,.22) !important;
  text-decoration: none !important;
}

.oa-404-actions a:hover,
.oa-404-actions a:focus-visible {
  color: #20150f !important;
  background: #fffaf2 !important;
  border-color: rgba(87,61,34,.38) !important;
  outline: none;
}

.oa-404-actions a.oa-primary {
  color: #fff8ed !important;
  background: #2a1d15 !important;
  border-color: #2a1d15 !important;
}

.oa-404-actions a.oa-primary:hover,
.oa-404-actions a.oa-primary:focus-visible {
  color: #fff !important;
  background: #3a281d !important;
  border-color: #3a281d !important;
}


/* =========================================================
   Mk27, ultra-compact minimised audio shell
   ========================================================= */

/* Closed means closed, even if an older minimised state is still present. */
.oa-player:not(.is-visible) {
  pointer-events: none !important;
}

.oa-player.is-minimized:not(.is-visible) {
  opacity: 0 !important;
  visibility: hidden !important;
}

/* The compact shell is a single thin row:
   transport | slider | timer / expand / close */
.oa-player.is-minimized.is-visible {
  width: min(560px, calc(100% - 20px)) !important;
  min-height: 0 !important;
  bottom: 8px !important;
  padding: 4px 6px !important;
  border-radius: 11px !important;
  display: grid !important;
  grid-template-columns: auto minmax(70px, 1fr) auto !important;
  grid-template-rows: 28px !important;
  align-items: center !important;
  column-gap: 7px !important;
  row-gap: 0 !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateX(-50%) translateY(0) !important;
}

.oa-player.is-minimized .oa-player-meta,
.oa-player.is-minimized .oa-player-volume {
  display: none !important;
}

.oa-player.is-minimized .oa-player-controls {
  grid-column: 1 !important;
  grid-row: 1 !important;
  display: flex !important;
  align-items: center !important;
  justify-self: start !important;
  gap: 3px !important;
}

.oa-player.is-minimized .oa-player-progress {
  grid-column: 2 !important;
  grid-row: 1 !important;
  display: block !important;
  min-width: 0 !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 0 !important;
}

.oa-player.is-minimized .oa-player-progress > span {
  display: none !important;
}

.oa-player.is-minimized .oa-player-progress input {
  display: block !important;
  width: 100% !important;
  height: 14px !important;
  margin: 0 !important;
  cursor: pointer;
}

.oa-player.is-minimized .oa-player-tools {
  grid-column: 3 !important;
  grid-row: 1 !important;
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-self: end !important;
  justify-content: flex-end !important;
  gap: 3px !important;
  min-width: 0 !important;
}

/* Back / play / next are deliberately tiny in compact mode. */
.oa-player.is-minimized .oa-player-btn {
  width: 26px !important;
  height: 26px !important;
  min-width: 26px !important;
  min-height: 26px !important;
  padding: 0 !important;
  border-radius: 50% !important;
}

.oa-player.is-minimized .oa-player-btn svg {
  width: 13px !important;
  height: 13px !important;
}

.oa-player.is-minimized .oa-player-btn.play {
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  min-height: 28px !important;
}

/* Timer, expand and close stay available but do not increase the bar height. */
.oa-player.is-minimized .oa-player-timer,
.oa-player.is-minimized .oa-player-minimise,
.oa-player.is-minimized .oa-player-close {
  position: static !important;
  inset: auto !important;
  width: 24px !important;
  height: 24px !important;
  min-width: 24px !important;
  min-height: 24px !important;
  padding: 0 !important;
  margin: 0 !important;
}

.oa-player.is-minimized .oa-player-timer svg,
.oa-player.is-minimized .oa-player-minimise svg {
  width: 14px !important;
  height: 14px !important;
}

.oa-player.is-minimized .oa-player-close {
  font-size: .92rem !important;
  line-height: 1 !important;
}

/* The remaining-time badge used too much vertical space in compact mode. */
.oa-player.is-minimized #audio-sleep-timer-badge,
.oa-player.is-minimized .oa-player-timer-badge {
  display: none !important;
}

/* Timer menu still opens above the compact shell. */
.oa-player.is-minimized .oa-sleep-panel {
  right: 0 !important;
  bottom: calc(100% + 7px) !important;
  transform: none !important;
}

/* Mobile: sit immediately above the app nav and use almost the full width. */
@media (max-width: 760px) {
  .oa-player.is-minimized.is-visible {
    left: 6px !important;
    right: 6px !important;
    width: auto !important;
    bottom: calc(var(--oa-dock-h, 76px) + env(safe-area-inset-bottom) + 3px) !important;
    grid-template-columns: auto minmax(48px, 1fr) auto !important;
    grid-template-rows: 28px !important;
    column-gap: 5px !important;
    padding: 4px 5px !important;
    border-radius: 10px !important;
    transform: none !important;
  }

  .oa-player.is-minimized .oa-player-controls,
  .oa-player.is-minimized .oa-player-tools {
    gap: 2px !important;
  }

  .oa-player.is-minimized .oa-player-btn {
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    min-height: 24px !important;
  }

  .oa-player.is-minimized .oa-player-btn.play {
    width: 27px !important;
    height: 27px !important;
    min-width: 27px !important;
    min-height: 27px !important;
  }

  .oa-player.is-minimized .oa-player-timer,
  .oa-player.is-minimized .oa-player-minimise,
  .oa-player.is-minimized .oa-player-close {
    width: 23px !important;
    height: 23px !important;
    min-width: 23px !important;
    min-height: 23px !important;
  }

  .oa-player.is-minimized .oa-player-progress input {
    height: 12px !important;
  }
}

@media (max-width: 360px) {
  .oa-player.is-minimized.is-visible {
    left: 4px !important;
    right: 4px !important;
    column-gap: 3px !important;
    padding-inline: 4px !important;
  }

  .oa-player.is-minimized .oa-player-btn {
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    min-height: 22px !important;
  }

  .oa-player.is-minimized .oa-player-btn.play {
    width: 25px !important;
    height: 25px !important;
    min-width: 25px !important;
    min-height: 25px !important;
  }

  .oa-player.is-minimized .oa-player-timer,
  .oa-player.is-minimized .oa-player-minimise,
  .oa-player.is-minimized .oa-player-close {
    width: 21px !important;
    height: 21px !important;
    min-width: 21px !important;
    min-height: 21px !important;
  }
}


/* =========================================================
   Mk28, attached mobile player + shorter 404
   ========================================================= */

/* On mobile, visually connect the collapsed player directly to the nav bar. */
@media (max-width: 760px) {
  .oa-player.is-minimized.is-visible {
    bottom: calc(var(--oa-dock-h, 76px) + env(safe-area-inset-bottom) - 1px) !important;
    border-radius: 10px 10px 0 0 !important;
    border-bottom-color: transparent !important;
    box-shadow: 0 -5px 18px rgba(38, 26, 18, .12) !important;
  }
}

/* Make the 404 page more compact so it fits without unnecessary scrolling. */
.oa-404-main {
  padding-top: clamp(18px, 3vw, 34px) !important;
  padding-bottom: clamp(86px, 9vw, 108px) !important;
}

.oa-404-art {
  width: min(430px, 64vw) !important;
  margin-bottom: 8px !important;
}

.oa-404-copy {
  margin-top: 11px !important;
}

.oa-404-actions {
  margin-top: 18px !important;
}

@media (max-width: 560px) {
  .oa-404-art {
    width: min(285px, 70vw) !important;
  }

  .oa-404-main {
    padding-top: 12px !important;
    padding-bottom: calc(var(--oa-dock-h, 76px) + 18px) !important;
  }

  .oa-404-content h1 {
    font-size: clamp(1.8rem, 8vw, 2.5rem) !important;
  }

  .oa-404-copy {
    line-height: 1.5 !important;
  }
}


/* =========================================================
   Mk29, exact mobile player/nav join
   ========================================================= */

@media (max-width: 760px) {
  /* Give the mobile navigation an explicit height and use that exact same
     measurement for the compact player, so there can be no gap between them. */
  .oa-dock {
    height: calc(68px + env(safe-area-inset-bottom)) !important;
    min-height: calc(68px + env(safe-area-inset-bottom)) !important;
  }

  .oa-player.is-minimized.is-visible {
    bottom: calc(68px + env(safe-area-inset-bottom) - 1px) !important;
    margin-bottom: 0 !important;
  }
}


/* =========================================================
   Mk30, mobile stability and interaction fixes
   ========================================================= */

/* Accessibility belongs to the top of the page, not permanently over content. */
body > .oa-accessibility {
  position: absolute !important;
  top: max(12px, env(safe-area-inset-top)) !important;
  right: max(12px, env(safe-area-inset-right)) !important;
}

/* Never overlap an open prayer. */
body.oa-prayer-modal-open > .oa-accessibility {
  display: none !important;
}

/* Website-owned language picker: prevents iOS from opening its native giant
   select sheet on top of our accessibility panel. */
.oa-a11y-language-field {
  position: relative;
}

.oa-a11y-language-button {
  min-width: 128px;
  min-height: 32px;
  padding: 5px 27px 5px 9px;
  border: 1px solid rgba(91,66,41,.18);
  border-radius: 6px;
  background: #fffdf9;
  color: #34251a;
  font: inherit;
  text-align: left;
  cursor: pointer;
  position: relative;
}

.oa-a11y-language-button::after {
  content: "";
  position: absolute;
  right: 9px;
  top: 50%;
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-65%) rotate(45deg);
}

.oa-a11y-language-menu {
  position: absolute;
  top: calc(100% - 2px);
  right: 0;
  z-index: 4;
  width: min(210px, calc(100vw - 54px));
  max-height: 260px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 5px;
  border: 1px solid rgba(91,66,41,.18);
  border-radius: 8px;
  background: #fffdf9;
  box-shadow: 0 12px 28px rgba(37,25,17,.16);
}

.oa-a11y-language-menu[hidden] {
  display: none !important;
}

.oa-a11y-language-menu button {
  display: block;
  width: 100%;
  min-height: 34px;
  padding: 7px 9px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #34251a;
  font: inherit;
  text-align: left;
}

.oa-a11y-language-menu button:hover,
.oa-a11y-language-menu button:focus-visible,
.oa-a11y-language-menu button.is-selected {
  background: rgba(167,119,47,.12);
  outline: none;
}

.oa-a11y-language-menu button.is-selected::after {
  content: "✓";
  float: right;
  color: #9a6a2c;
}

/* Prayer close is a simple X in the actual top-right corner. */
.oa-modal-panel {
  position: relative !important;
}

.oa-modal-head {
  padding-right: 38px !important;
}

#prayer-modal-close.oa-close {
  position: absolute !important;
  top: 10px !important;
  right: 10px !important;
  z-index: 5 !important;
  width: 30px !important;
  height: 30px !important;
  min-height: 30px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #625449 !important;
  font-size: 1.55rem !important;
  line-height: 1 !important;
}

#prayer-modal-close.oa-close:hover,
#prayer-modal-close.oa-close:focus-visible {
  color: #9a6a2c !important;
  background: transparent !important;
  outline: none !important;
}

/* Remove every text/emoji cross from prayer/calendar decorations. */
.oa-prayer-card::before {
  content: none !important;
}

body.app-calendar-page .section-heading::before,
body.app-calendar-page .panel-header h3::before {
  content: "" !important;
  flex: 0 0 auto;
  width: 15px;
  height: 21px;
  background: url("../icons/orthodox-cross.svg") center / contain no-repeat;
  filter: sepia(.45) saturate(1.5);
}

.liturgical-ornament-cross {
  display: block;
  width: 18px;
  height: 25px;
  object-fit: contain;
  opacity: .86;
}

/* Closing is absolute: hidden wins over all compact-player rules. */
.oa-player[hidden],
.oa-player[aria-hidden="true"] {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* iPhone/iPad reserve media output volume for the device buttons. Do not show
   a website slider that falsely appears to control system media volume. */
.oa-player.oa-ios-player .oa-player-volume {
  display: none !important;
}

.oa-player.oa-ios-player:not(.is-minimized) .oa-player-tools::before {
  content: "Use device volume";
  color: rgba(255,255,255,.55);
  font-size: .62rem;
  white-space: nowrap;
}

/* The previous iframe page shell is no longer used. */
.oa-persistent-frame {
  display: none !important;
}
html.oa-persistent-audio-shell {
  overflow: auto !important;
}
html.oa-persistent-audio-shell body {
  overflow: auto !important;
}

@media (max-width: 760px) {
  body > .oa-accessibility {
    top: max(8px, env(safe-area-inset-top)) !important;
    right: max(8px, env(safe-area-inset-right)) !important;
  }

  #prayer-modal-close.oa-close {
    top: 7px !important;
    right: 8px !important;
  }

  .oa-a11y-language-menu {
    max-height: 220px;
  }
}


/* =========================================================
   Mk31, stable navigation, header accessibility, player polish
   ========================================================= */

/* Accessibility is part of the page header, never an overlay. */
body > .oa-accessibility {
  position: static !important;
}

.oa-topbar {
  align-items: center !important;
  gap: 14px !important;
}

.oa-topbar > .oa-accessibility {
  position: relative !important;
  margin-left: auto !important;
  top: auto !important;
  right: auto !important;
  flex: 0 0 auto;
}

.oa-accessibility-row {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  min-height: 54px;
  padding: 8px clamp(12px, 2vw, 24px) 4px;
}

.oa-accessibility-row > .oa-accessibility {
  position: relative !important;
  top: auto !important;
  right: auto !important;
  margin: 0 !important;
}

/* When audio keeps the top document alive, the current framed page owns the
   accessibility control. The old parent page's copy is hidden behind it. */
html.oa-persistent-audio-shell > body > .oa-accessibility,
html.oa-persistent-audio-shell > body > main > .oa-accessibility-row,
html.oa-persistent-audio-shell > body > .oa-page > .oa-accessibility-row {
  visibility: hidden !important;
  pointer-events: none !important;
}

/* The persistent frame is active again so audio never unloads between pages. */
.oa-persistent-frame {
  display: block !important;
  position: fixed !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  border: 0 !important;
  background: var(--oa-bg, #f7f4ee) !important;
  z-index: 1250 !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

html.oa-persistent-audio-shell,
html.oa-persistent-audio-shell body {
  overflow: hidden !important;
}

html.oa-persistent-audio-shell > body > .oa-player {
  z-index: 1500 !important;
}

/* Expanded shell: normal close control in the top-right corner. */
.oa-player.is-visible:not(.is-minimized) {
  position: fixed;
}

.oa-player.is-visible:not(.is-minimized) .oa-player-close {
  position: absolute !important;
  top: 9px !important;
  right: 10px !important;
  z-index: 10 !important;
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  min-height: 28px !important;
  background: transparent !important;
}

.oa-player.is-visible:not(.is-minimized) .oa-player-tools {
  padding-right: 34px !important;
}

/* Minimized close remains in the compact inline tool row. */
.oa-player.is-minimized .oa-player-close {
  position: static !important;
}

/* Bible/calendar pages without the standard brand bar get a small reserved
   utility row so the accessibility button cannot overlap their first heading. */
body.app-bible-page .oa-accessibility-row,
body.app-calendar-page .oa-accessibility-row {
  margin-bottom: 2px;
}

@media (max-width: 760px) {
  .oa-accessibility-row {
    min-height: 50px;
    padding: calc(6px + env(safe-area-inset-top)) 10px 3px;
  }

  .oa-topbar > .oa-accessibility {
    margin-left: auto !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-close {
    top: 7px !important;
    right: 8px !important;
  }
}


/* =========================================================
   Mk34, player close + Bible accessibility
   ========================================================= */

/* Anchor the X to the outer shell, not the positioned tools group. */
.oa-player.is-visible:not(.is-minimized) .oa-player-tools {
  position: static !important;
  padding-right: 34px !important;
}

.oa-player.is-visible:not(.is-minimized) .oa-player-close {
  position: absolute !important;
  inset: 8px 9px auto auto !important;
  top: 8px !important;
  right: 9px !important;
  z-index: 30 !important;
  margin: 0 !important;
  transform: none !important;
}

/* Only the current framed page should show accessibility while persistent
   audio navigation is active. The old parent page must show none. */
html.oa-persistent-audio-shell .oa-accessibility {
  display: none !important;
}

/* Bible accessibility stays in its own normal-flow row above the Bible header. */
body.app-bible-page .oa-accessibility-row {
  position: relative !important;
  z-index: auto !important;
  min-height: 50px !important;
  margin: 0 0 8px !important;
}

body.app-bible-page .oa-accessibility-row > .oa-accessibility {
  display: block !important;
  position: relative !important;
  top: auto !important;
  right: auto !important;
  z-index: 2 !important;
}

@media (max-width: 760px) {
  .oa-player.is-visible:not(.is-minimized) .oa-player-close {
    inset: 7px 8px auto auto !important;
    top: 7px !important;
    right: 8px !important;
  }

  body.app-bible-page .oa-accessibility-row {
    min-height: 48px !important;
    margin-bottom: 8px !important;
  }
}


/* =========================================================
   Mk35, final mobile media controls
   ========================================================= */

@media (max-width: 760px) {
  .oa-player.is-visible:not(.is-minimized) .oa-player-minimise {
    position: absolute !important;
    top: 7px !important;
    right: 43px !important;
    z-index: 30 !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    margin: 0 !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-close {
    top: 7px !important;
    right: 8px !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-meta {
    padding-right: 78px !important;
  }
}


/* =========================================================
   Mk36, sleep timer + tighter mobile expanded shell
   ========================================================= */

/* iOS already uses the hardware volume controls. The explanatory text is not
   needed in the player. */
.oa-player.oa-ios-player:not(.is-minimized) .oa-player-tools::before {
  content: none !important;
  display: none !important;
}

@media (max-width: 760px) {
  .oa-player.is-visible:not(.is-minimized) {
    padding: 10px 12px 9px !important;
    row-gap: 7px !important;
  }

  /* Timer, minimise and close all live on the title row. */
  .oa-player.is-visible:not(.is-minimized) .oa-player-tools {
    grid-row: 1 !important;
    height: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-timer {
    position: absolute !important;
    top: 7px !important;
    right: 78px !important;
    z-index: 31 !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    margin: 0 !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-minimise {
    position: absolute !important;
    top: 7px !important;
    right: 43px !important;
    z-index: 31 !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    margin: 0 !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-close {
    top: 7px !important;
    right: 8px !important;
  }

  /* The active timer value, e.g. 1m, sits immediately under the stopwatch. */
  .oa-player.is-visible:not(.is-minimized) #audio-sleep-timer-badge,
  .oa-player.is-visible:not(.is-minimized) .oa-player-timer-badge {
    display: block !important;
    position: absolute !important;
    top: 25px !important;
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    min-width: max-content !important;
    color: #e5bb6e !important;
    font-size: .52rem !important;
    line-height: 1 !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-meta {
    padding-right: 112px !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-controls {
    grid-row: 2 !important;
    margin-top: 1px !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-progress {
    grid-row: 3 !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-sleep-panel {
    right: 70px !important;
    bottom: calc(100% + 8px) !important;
    transform: none !important;
  }
}

@media (max-width: 390px) {
  .oa-player.is-visible:not(.is-minimized) .oa-player-meta {
    padding-right: 105px !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-timer {
    right: 74px !important;
  }

  .oa-player.is-visible:not(.is-minimized) .oa-player-minimise {
    right: 41px !important;
  }
}
