/* ===== Tokens ===== */
:root {
  --paper: #FFFFFF;
  --mist: #F2F2F0;
  --line: #E4E4E0;
  --ink: #000000;
  --graphite: #6E6E6A;
  --highlight: #F5CF3B;
  --alert: #D93A3F;
  --ok: #2F7D4F;

  --k-audio: #2F6E8A;
  --k-video: #7A4A86;
  --k-ebook: #3E8A52;
  --k-pdf: #A8603F;
  --k-other: #7A6E4E;

  --sans: "Schibsted Grotesk", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;

  --r-lg: 26px;
  --r-md: 18px;
  --r-sm: 12px;
  --pad: 20px;
  --nav-h: 76px;
  --lift: 0 1px 2px rgba(0,0,0,.04), 0 8px 24px rgba(0,0,0,.06);
  box-sizing: border-box;
}
*, *::before, *::after { box-sizing: border-box; }
details::details-content { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: env(safe-area-inset-top, 0px); }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--sans); font-size: 16px; line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: calc(var(--nav-h) + 28px + env(safe-area-inset-bottom, 0px));
}
body.no-nav { padding-bottom: 40px; }
a { color: inherit; }
img { max-width: 100%; display: block; }
.ic { width: 22px; height: 22px; flex: none; }
:focus-visible { outline: 2.5px solid var(--ink); outline-offset: 2px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ===== Layout ===== */
.wrap { max-width: 760px; margin: 0 auto; padding: 0 var(--pad); }
.wrap.wide { max-width: 1120px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 0 6px; }
.brand { font-weight: 800; font-size: 15px; letter-spacing: -.01em; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.brand-mark { width: 26px; height: 26px; border-radius: 8px; background: var(--ink); color: #fff; display: grid; place-items: center; font-size: 13px; }
.pill-btn-group { display: flex; gap: 4px; background: var(--paper); border-radius: 999px; box-shadow: var(--lift); padding: 4px; }
.icon-btn { width: 44px; height: 44px; border-radius: 999px; display: grid; place-items: center; border: 0; background: transparent; color: var(--ink); cursor: pointer; text-decoration: none; }
.icon-btn:hover { background: var(--mist); }

h1, h2, h3 { margin: 0; letter-spacing: -.025em; }
.display { font-size: clamp(34px, 8vw, 46px); font-weight: 800; line-height: 1.02; letter-spacing: -.035em; margin: 22px 0 6px; }
.h2 { font-size: 24px; font-weight: 800; }
.sub { color: var(--graphite); margin: 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 34px 0 14px; gap: 12px; }
.section-head a { font-weight: 600; font-size: 15px; text-decoration: none; display: inline-flex; align-items: center; gap: 2px; }
.section-head a .ic { width: 18px; height: 18px; }
.muted { color: var(--graphite); }
.small { font-size: 14px; }
.tiny { font-size: 12.5px; }
.serif { font-family: var(--serif); }
.stack > * + * { margin-top: 12px; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.spread { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hide { display: none !important; }

/* ===== Tabs (Activity / Saved / Profile style) ===== */
.tabs { display: flex; gap: 28px; border-bottom: 1.5px solid var(--line); margin: 22px 0 18px; overflow-x: auto; scrollbar-width: none; }
.tabs a { padding: 10px 0 12px; font-weight: 700; font-size: 19px; text-decoration: none; color: var(--graphite); white-space: nowrap; border-bottom: 3px solid transparent; margin-bottom: -1.5px; }
.tabs a.on { color: var(--ink); border-color: var(--ink); }

/* ===== Filter pills ===== */
.pills { display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 8px; margin: 0 calc(var(--pad) * -1); padding-left: var(--pad); padding-right: var(--pad); scrollbar-width: none; }
.pills::-webkit-scrollbar, .tabs::-webkit-scrollbar { display: none; }
.pill { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 18px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--paper); font-weight: 700; font-size: 15.5px; text-decoration: none; white-space: nowrap; cursor: pointer; color: var(--ink); font-family: inherit; }
.pill .ic { width: 19px; height: 19px; }
.pill.on { background: var(--ink); border-color: var(--ink); color: #fff; }

/* ===== Cards ===== */
.card { background: var(--paper); border-radius: var(--r-lg); box-shadow: var(--lift); padding: 22px; }
.card.flat { box-shadow: none; background: var(--mist); }
.card + .card { margin-top: 14px; }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat { background: var(--paper); border-radius: var(--r-lg); box-shadow: var(--lift); padding: 20px 20px 18px; min-height: 140px; display: flex; flex-direction: column; justify-content: space-between; text-decoration: none; }
.stat .label { font-size: 15.5px; font-weight: 500; }
.stat .num { font-size: 44px; font-weight: 800; letter-spacing: -.04em; line-height: 1; margin-top: 18px; }
.stat .foot { font-size: 14px; color: var(--graphite); margin-top: 8px; }
.stat.wide { grid-column: 1 / -1; min-height: 0; flex-direction: row; align-items: center; }
.stat.wide .num { font-size: 32px; margin: 0; }
@media (min-width: 900px) { .stat-grid.four { grid-template-columns: repeat(4, 1fr); } }

/* ===== Covers (Topic-tile style) ===== */
.cover { position: relative; aspect-ratio: 1; border-radius: var(--r-md); overflow: hidden; background: var(--k-other); color: #fff; display: flex; flex-direction: column; justify-content: flex-end; padding: 14px; isolation: isolate; }
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -1; }
.cover .cv-title { font-weight: 800; font-size: clamp(17px, 4.6vw, 22px); line-height: 1.05; letter-spacing: -.025em; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.cover .cv-icon { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: 999px; background: rgba(255,255,255,.18); display: grid; place-items: center; }
.cover .cv-icon .ic { width: 18px; height: 18px; }
.cover::after { content: ""; position: absolute; right: -18%; top: -14%; width: 64%; aspect-ratio: 1; border-radius: 28%; background: rgba(255,255,255,.1); transform: rotate(12deg); z-index: -1; }
.cover.has-img::after { display: none; }
.cover.has-img .cv-title { display: none; }
.k-audio { background: var(--k-audio); } .k-video { background: var(--k-video); } .k-ebook { background: var(--k-ebook); } .k-pdf { background: var(--k-pdf); } .k-other { background: var(--k-other); }
.k-pack { background: #1E1E1C; }

.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 14px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .wide .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tile { text-decoration: none; display: block; min-width: 0; }
.tile .meta { margin-top: 9px; font-size: 14px; color: var(--graphite); }
.tile .name { font-size: 16.5px; font-weight: 600; line-height: 1.25; margin-top: 2px; overflow-wrap: anywhere; }
.tile .owned { display: inline-flex; align-items: center; gap: 4px; color: var(--ok); font-weight: 600; }

.rail { display: grid; grid-auto-flow: column; grid-auto-columns: 42%; gap: 14px; overflow-x: auto; margin: 0 calc(var(--pad) * -1); padding: 2px var(--pad) 6px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.rail > * { scroll-snap-align: start; }
@media (min-width: 640px) { .rail { grid-auto-columns: 28%; } }

/* Kind tiles (Topics row) */
.kind-tiles { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
@media (min-width: 640px) { .kind-tiles { grid-template-columns: repeat(3, minmax(0,1fr)); } }
.kind-tile { border-radius: var(--r-md); height: 96px; color: #fff; text-decoration: none; display: flex; align-items: flex-end; padding: 14px 18px; font-weight: 800; font-size: 26px; letter-spacing: -.03em; position: relative; overflow: hidden; }
.kind-tile .ic { position: absolute; right: 14px; top: 14px; opacity: .55; width: 30px; height: 30px; }

/* ===== Lists ===== */
.list { background: var(--paper); border-radius: var(--r-lg); box-shadow: var(--lift); overflow: hidden; }
.li { display: flex; align-items: center; gap: 14px; padding: 14px 18px; text-decoration: none; border-top: 1px solid var(--line); min-height: 64px; }
.li:first-child { border-top: 0; }
a.li:hover { background: #FAFAF8; }
.li .grow { flex: 1; min-width: 0; }
.li .t { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li .s { font-size: 14px; color: var(--graphite); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li .end { font-size: 13.5px; color: var(--graphite); text-align: right; white-space: nowrap; }
.li .chev { color: #B4B4AE; }
.thumb { width: 46px; height: 46px; border-radius: 12px; flex: none; display: grid; place-items: center; color: #fff; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb .ic { width: 20px; height: 20px; }
.avatar { width: 44px; height: 44px; border-radius: 999px; background: var(--mist); display: grid; place-items: center; font-weight: 800; font-size: 15px; flex: none; }
.dot { width: 9px; height: 9px; border-radius: 999px; background: var(--highlight); display: inline-block; flex: none; }
.dot.alert { background: var(--alert); }
.badge { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 999px; background: var(--mist); font-size: 13px; font-weight: 650; white-space: nowrap; }
.badge.yellow { background: #FBEFB8; }
.badge.green { background: #DCEFE2; color: #1D5B37; }
.badge.dark { background: var(--ink); color: #fff; }

/* Activity feed */
.feed .li { align-items: flex-start; }
.feed .t { white-space: normal; font-weight: 500; }
.feed .t b { font-weight: 700; }
.ev { width: 36px; height: 36px; border-radius: 999px; display: grid; place-items: center; flex: none; background: var(--mist); }
.ev .ic { width: 18px; height: 18px; }
.ev.download { background: #E3EEF3; color: var(--k-audio); }
.ev.stream { background: #EFE6F1; color: var(--k-video); }
.ev.login, .ev.link_login { background: #FBEFB8; }
.ev.purchase { background: #DCEFE2; color: var(--ok); }

/* ===== Forms ===== */
label.f { display: block; font-weight: 650; font-size: 15px; margin: 18px 0 7px; }
.input, select.input, textarea.input {
  width: 100%; height: 52px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--paper);
  padding: 0 16px; font: inherit; font-size: 16px; color: var(--ink); appearance: none;
}
textarea.input { height: auto; min-height: 110px; padding: 14px 16px; resize: vertical; line-height: 1.5; }
.input:focus { outline: none; border-color: var(--ink); }
.search { position: relative; }
.search .ic { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: var(--graphite); }
.search .input { background: var(--mist); border-color: var(--mist); border-radius: 999px; padding-left: 52px; height: 56px; font-size: 17px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.three { display: grid; grid-template-columns: 1.4fr .8fr 1fr; gap: 0 12px; }
@media (max-width: 480px) { .three { grid-template-columns: 1fr 1fr; } .three > :first-child { grid-column: 1 / -1; } }
.hint { font-size: 13.5px; color: var(--graphite); margin-top: 6px; }
.check { display: flex; align-items: flex-start; gap: 12px; padding: 12px 0; cursor: pointer; font-weight: 500; }
.check input { width: 22px; height: 22px; accent-color: var(--ink); margin: 1px 0 0; flex: none; }
.check .s { display: block; font-size: 14px; color: var(--graphite); font-weight: 400; }
.picker { border: 1.5px solid var(--line); border-radius: var(--r-md); max-height: 340px; overflow-y: auto; }
.picker .check { padding: 12px 16px; border-top: 1px solid var(--line); margin: 0; align-items: center; }
.picker .check:first-child { border-top: 0; }
.picker .check:has(input:checked) { background: #FAFAF6; }
.picker-tools { display: flex; gap: 8px; margin-bottom: 10px; }
.picker-tools .search .input { height: 46px; font-size: 15.5px; }
.segmented { display: flex; max-width: 420px; background: var(--mist); border-radius: 999px; padding: 4px; gap: 2px; }
.segmented label { position: relative; flex: 1; text-align: center; }
.segmented input { position: absolute; opacity: 0; inset: 0; }
.segmented span { display: block; padding: 9px 16px; border-radius: 999px; font-weight: 650; font-size: 14.5px; cursor: pointer; }
.segmented input:checked + span { background: var(--paper); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.segmented input:focus-visible + span { outline: 2px solid var(--ink); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 52px; padding: 0 24px; border-radius: 999px; border: 1.5px solid var(--ink); background: var(--ink); color: #fff; font: inherit; font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn .ic { width: 20px; height: 20px; }
.btn.light { background: var(--paper); color: var(--ink); border-color: var(--line); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--ink); padding: 0 12px; }
.btn.danger { background: var(--paper); color: var(--alert); border-color: #F1C9CA; }
.btn.block { width: 100%; }
.btn.sm { height: 42px; padding: 0 16px; font-size: 15px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 24px; }
.sticky-save { position: sticky; bottom: calc(var(--nav-h) + 22px + env(safe-area-inset-bottom, 0px)); z-index: 5; margin-top: 24px; }
.sticky-save .btn { box-shadow: 0 10px 30px rgba(0,0,0,.18); }

/* Upload drop zone */
.drop { border: 2px dashed var(--line); border-radius: var(--r-lg); padding: 26px 20px; text-align: center; cursor: pointer; display: block; background: #FCFCFA; }
.drop.over { border-color: var(--ink); background: var(--mist); }
.drop .ic { width: 30px; height: 30px; margin: 0 auto 8px; }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop strong { display: block; font-size: 17px; }
.progress { height: 8px; border-radius: 999px; background: var(--mist); overflow: hidden; margin-top: 14px; }
.progress > i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .15s; }
.file-chip { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--r-md); background: var(--mist); margin-top: 12px; text-align: left; }
.file-chip .grow { flex: 1; min-width: 0; }
.file-chip .t { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== Flash ===== */
.flash { border-radius: var(--r-md); padding: 14px 16px; margin: 14px 0; font-weight: 600; display: flex; gap: 10px; align-items: flex-start; }
.flash.ok { background: #DCEFE2; color: #164A2C; }
.flash.err { background: #FBE3E3; color: #7A1E21; }
.creds { background: var(--ink); color: #fff; border-radius: var(--r-lg); padding: 22px; margin: 16px 0; }
.creds h3 { font-size: 19px; margin-bottom: 4px; }
.creds .kv { display: flex; align-items: center; gap: 10px; background: rgba(255,255,255,.1); border-radius: var(--r-sm); padding: 10px 10px 10px 14px; margin-top: 10px; }
.creds .kv .k { font-size: 12.5px; opacity: .7; }
.creds .kv .v { font-weight: 700; overflow-wrap: anywhere; font-size: 15px; }
.creds .kv .grow { flex: 1; min-width: 0; }
.creds .icon-btn { color: #fff; width: 40px; height: 40px; background: rgba(255,255,255,.12); }
.copied { background: var(--ok) !important; }

/* ===== Player (Verse-of-the-day card) ===== */
.stage { position: relative; border-radius: var(--r-lg); overflow: hidden; color: #fff; padding: 22px 22px 20px; isolation: isolate; margin-top: 16px; }
.stage::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(180deg, color-mix(in srgb, var(--kc) 75%, #9AA7B4) 0%, color-mix(in srgb, var(--kc) 55%, #B9A79A) 55%, #111 100%); }
.stage .bg { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; opacity: .35; filter: blur(2px); }
.stage .lbl { font-size: 15px; opacity: .9; }
.stage .ttl { font-weight: 800; font-size: 19px; margin-top: 2px; }
.stage .quote { font-family: var(--serif); font-size: clamp(26px, 6.6vw, 34px); line-height: 1.22; margin: 30px 0 30px; letter-spacing: -.01em; overflow-wrap: anywhere; }
.player { display: flex; align-items: center; gap: 14px; }
.player .play { width: 62px; height: 62px; border-radius: 999px; border: 0; background: #fff; color: #000; display: grid; place-items: center; cursor: pointer; flex: none; }
.player .play .ic { width: 26px; height: 26px; }
.player .skip { background: transparent; border: 0; color: #fff; cursor: pointer; padding: 6px; opacity: .9; }
.player .track { flex: 1; min-width: 0; }
.player input[type=range] { width: 100%; accent-color: #fff; height: 22px; }
.player .times { display: flex; justify-content: space-between; font-size: 13px; opacity: .85; font-variant-numeric: tabular-nums; }
.stage-actions { display: flex; gap: 10px; margin-top: 20px; }
.stage-actions .btn { flex: 1; background: rgba(255,255,255,.95); color: #000; border-color: transparent; }
.stage-actions .btn.alt { background: rgba(255,255,255,.16); color: #fff; }
video.vid { width: 100%; border-radius: var(--r-md); background: #000; margin-top: 18px; aspect-ratio: 16/9; }
.pdf-frame { width: 100%; height: 70vh; border: 0; border-radius: var(--r-md); margin-top: 16px; background: var(--mist); }
.desc { font-family: var(--serif); font-size: 19px; line-height: 1.6; margin: 22px 0 0; white-space: pre-line; max-width: 64ch; }

/* Track list (packs) */
.tracks .li { cursor: pointer; }
.tracks .li.playing .t { color: var(--k-audio); }
.tracks .num { width: 24px; text-align: center; color: var(--graphite); font-variant-numeric: tabular-nums; font-weight: 600; }
.tracks .li.playing .num { color: var(--k-audio); }
.mini { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--nav-h) + 22px + env(safe-area-inset-bottom, 0px)); width: min(720px, calc(100% - 24px)); background: #111; color: #fff; border-radius: 22px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; box-shadow: 0 16px 40px rgba(0,0,0,.28); z-index: 30; }
.mini .play { width: 46px; height: 46px; }
.mini .play .ic { width: 20px; height: 20px; }
.mini .t { font-weight: 700; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== Bottom nav ===== */
.bnav { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(14px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  width: min(560px, calc(100% - 24px)); height: var(--nav-h); border-radius: 999px; padding: 6px;
  background: rgba(255,255,255,.86); backdrop-filter: saturate(1.6) blur(18px); -webkit-backdrop-filter: saturate(1.6) blur(18px);
  box-shadow: 0 0 0 1px rgba(0,0,0,.05), 0 12px 32px rgba(0,0,0,.12); display: flex; }
.bnav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; text-decoration: none; font-weight: 650; font-size: 13.5px; border-radius: 999px; color: var(--ink); min-width: 0; }
.bnav a .ic { width: 25px; height: 25px; }
.bnav a.on { background: rgba(0,0,0,.07); }
.bnav a.on .ic path, .bnav a.on .ic rect, .bnav a.on .ic circle { stroke-width: 2.3; }

/* ===== Auth ===== */
.auth { min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: 40px var(--pad); max-width: 460px; margin: 0 auto; }
.auth .display { margin-top: 0; }
.auth-foot { margin-top: 22px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.auth-foot a { font-weight: 600; }
.mark-lg { width: 54px; height: 54px; border-radius: 16px; background: var(--ink); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 22px; margin-bottom: 28px; }

/* ===== Tables (desktop admin) ===== */
.table-wrap { overflow-x: auto; }
.price { font-weight: 800; font-size: 26px; letter-spacing: -.02em; }
.buy-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 22px; padding: 18px 20px; border-radius: var(--r-lg); background: var(--mist); }
.empty { text-align: center; padding: 44px 20px; }
.empty .ic { width: 36px; height: 36px; margin: 0 auto 10px; color: var(--graphite); }
.empty h3 { font-size: 20px; margin-bottom: 6px; }
.empty p { color: var(--graphite); margin: 0 auto 18px; max-width: 36ch; }

.split { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.split > * { min-width: 0; }
@media (min-width: 960px) { .split { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: start; } }
.danger-zone { margin-top: 30px; padding-top: 20px; border-top: 1.5px solid var(--line); }
details.more summary { cursor: pointer; font-weight: 700; list-style: none; padding: 14px 0; display: flex; justify-content: space-between; align-items: center; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary::after { content: "+"; font-size: 22px; font-weight: 500; }
details.more[open] summary::after { content: "–"; }

@media (max-width: 520px) { .hide-sm { display: none; } }

/* ===== Stars ===== */
.rating { color: var(--highlight); letter-spacing: 1px; -webkit-text-stroke: .5px #C9A21B; }
.rating.small { font-size: 14px; }
.stars { display: inline-flex; flex-direction: row-reverse; justify-content: flex-end; gap: 0; position: relative; }
.stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.stars label { font-size: 40px; line-height: 1; color: #D8D8D2; cursor: pointer; padding: 2px 5px; min-width: 44px; min-height: 48px; text-align: center; }
.stars input:checked ~ label, .stars label:hover, .stars label:hover ~ label { color: var(--highlight); }
.stars input:focus-visible + label { outline: 2.5px solid var(--ink); border-radius: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ===== Give ===== */
.amounts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 560px) { .amounts { grid-template-columns: repeat(4, 1fr); } }
.amt { position: relative; }
.amt input { position: absolute; opacity: 0; inset: 0; }
.amt span { display: flex; align-items: center; justify-content: center; height: 64px; border-radius: var(--r-md); border: 1.5px solid var(--line); font-weight: 800; font-size: 22px; letter-spacing: -.02em; cursor: pointer; background: var(--paper); }
.amt input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.amt input:focus-visible + span { outline: 2.5px solid var(--ink); outline-offset: 2px; }
.money-input { position: relative; margin-top: 10px; }
.money-input > span { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); font-weight: 700; color: var(--graphite); }
.money-input .input { padding-left: 34px; height: 60px; font-size: 18px; font-weight: 600; }
.give-summary { font-family: var(--serif); font-size: 21px; line-height: 1.35; margin: 22px 0 16px; min-height: 1.4em; }
.segmented span { white-space: nowrap; }
[data-donate] .segmented span { padding: 11px 6px; font-size: 14.5px; }

/* ===== Prayer Mission card ===== */
.pm-mark { width: 40px; height: 40px; border-radius: 12px; background: rgba(255,255,255,.18); display: grid; place-items: center; flex: none; }
.pm-actions { display: flex; flex-direction: column; gap: 10px; }
.pm-actions .btn { background: rgba(255,255,255,.95); color: #000; border-color: transparent; width: 100%; }
.pm-actions .btn.alt { background: rgba(255,255,255,.16); color: #fff; }
@media (min-width: 640px) { .pm-actions { flex-direction: row; flex-wrap: wrap; } .pm-actions .btn { width: auto; flex: 1 1 auto; } }

/* ===== Customer notes ===== */
.note { margin-top: 18px; }
.note + .note { margin-top: 12px; }
.note .note-ic { width: 16px; height: 16px; display: inline-block; vertical-align: -3px; margin-right: 6px; }

/* ===== Hub + landing pages ===== */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.hub { max-width: 560px; margin: 0 auto; padding: 0 var(--pad) 40px; }
.hub-top { display: flex; justify-content: flex-end; padding: 16px 0 0; }
.sm-pill { height: 38px; font-size: 14px; padding: 0 14px; }
.hub-head { text-align: center; padding: 6px 0 24px; }
.hub-photo { width: 112px; height: 112px; border-radius: 999px; object-fit: cover; margin: 0 auto 14px; display: block; box-shadow: var(--lift); }
.hub-mark { background: var(--ink); color: #fff; display: grid; place-items: center; font-size: 44px; font-weight: 800; }
.hub-head h1 { font-size: clamp(30px, 8vw, 40px); font-weight: 800; letter-spacing: -.035em; line-height: 1.05; }
.hub-tag { color: var(--graphite); font-size: 17px; margin: 8px auto 0; max-width: 34ch; }
.hub-list { display: flex; flex-direction: column; gap: 12px; }
.offer-card { display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: var(--r-lg); background: var(--paper); box-shadow: var(--lift); text-decoration: none; }
.offer-card:active { transform: scale(.99); }
.oc-thumb { width: 84px; height: 84px; border-radius: 16px; flex: none; display: grid; place-items: center; color: #fff; overflow: hidden; position: relative; }
.oc-thumb img { width: 100%; height: 100%; object-fit: cover; }
.oc-thumb .ic { width: 30px; height: 30px; }
.oc-free { background: var(--k-ebook); } .oc-paid { background: var(--k-audio); } .oc-prayer { background: #4B5568; }
.oc-body { flex: 1; min-width: 0; }
.oc-title { font-weight: 800; font-size: 18px; letter-spacing: -.02em; line-height: 1.2; }
.oc-blurb { color: var(--graphite); font-size: 14.5px; margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.oc-tag { display: inline-block; margin-top: 8px; font-weight: 800; font-size: 14px; background: var(--ink); color: #fff; border-radius: 999px; padding: 3px 11px; }
.oc-tag.free { background: #DCEFE2; color: #1D5B37; }
.hub-links { display: flex; flex-direction: column; gap: 10px; margin-top: 18px; }
.hub-foot { text-align: center; margin-top: 28px; }
.hub-foot a { color: inherit; }

.lp { max-width: 640px; margin: 0 auto; padding: 0 var(--pad) 120px; }
.lp-top { display: flex; align-items: center; justify-content: space-between; padding: 16px 0 10px; }
.lp-top .small { font-weight: 650; }
.lp-hero { width: 100%; border-radius: var(--r-lg); margin-top: 8px; aspect-ratio: 1; object-fit: cover; max-height: 440px; }
.lp-media { margin-top: 8px; border-radius: var(--r-lg); overflow: hidden; background: #000; aspect-ratio: 16 / 9; }
.lp-media iframe, .lp-media video { width: 100%; height: 100%; border: 0; display: block; }
.lp-h1 { font-size: clamp(32px, 8.4vw, 46px); font-weight: 800; line-height: 1.04; letter-spacing: -.035em; margin: 22px 0 0; overflow-wrap: anywhere; }
.lp-sub { font-size: 19px; color: var(--graphite); line-height: 1.45; margin: 12px 0 0; }
.lp-cta { margin-top: 22px; height: 58px; font-size: 17px; }
.lp-bullets { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-direction: column; gap: 14px; }
.lp-bullets li { display: flex; gap: 12px; align-items: flex-start; font-size: 17.5px; line-height: 1.4; }
.lp-bullets .ic { width: 24px; height: 24px; flex: none; color: var(--ok); margin-top: 1px; stroke-width: 2.6; }
.lp-body { margin-top: 28px; }
.lp-proof { display: flex; flex-direction: column; gap: 12px; margin-top: 30px; }
.lp-proof blockquote { margin: 0 0 10px; font-size: 18.5px; line-height: 1.5; }
.lp-get { margin-top: 34px; scroll-margin-top: 20px; }
.sticky-cta { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 12px var(--pad) calc(12px + env(safe-area-inset-bottom, 0px)); background: linear-gradient(180deg, rgba(255,255,255,0), #fff 40%); transition: transform .2s, opacity .2s; }
.sticky-cta .btn { max-width: 640px; margin: 0 auto; height: 56px; box-shadow: 0 10px 30px rgba(0,0,0,.2); }
.sticky-cta.gone { transform: translateY(120%); opacity: 0; pointer-events: none; }
body.no-nav .lp ~ .sticky-cta { display: block; }

/* admin offers */
.offer-row { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-top: 1px solid var(--line); }
.offer-row:first-child { border-top: 0; }
.offer-row .grow { flex: 1; min-width: 0; }

/* ===== Hub: social icons + total ===== */
.hub-total { margin: 12px 0 0; color: var(--graphite); font-size: 15px; text-align: center; }
.hub-total b { color: var(--ink); font-weight: 800; font-size: 17px; }
.hub-social-block { display: flex; flex-direction: column; align-items: center; margin-top: 16px; }
.hub-socials { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0; }
.soc { width: 46px; height: 46px; border-radius: 999px; display: grid; place-items: center; background: var(--paper); box-shadow: var(--lift); color: var(--ink); text-decoration: none; }
.soc:active { transform: scale(.95); }
.soc .ic { width: 22px; height: 22px; }

/* ===== Hub: full-bleed top photo that fades into the page ===== */
body.hub-page { padding-top: 0; }
.hub-hero { position: relative; margin: 0 calc(var(--pad) * -1); overflow: hidden; background: var(--mist); }
.hub-hero.shape-wide { aspect-ratio: 16 / 9; }
.hub-hero.shape-square { aspect-ratio: 1 / 1; }
.hub-hero img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hub-fade { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, var(--paper) 0%, rgba(255,255,255,.93) 7%, rgba(255,255,255,.72) 15%, rgba(255,255,255,.4) 23%, rgba(255,255,255,.13) 30%, rgba(255,255,255,0) 36%); }
.hub-top.over { position: absolute; top: calc(env(safe-area-inset-top, 0px) + 12px); right: var(--pad); left: auto; padding: 0; z-index: 2; }
.hub-top.over .pill { background: rgba(255,255,255,.88); border-color: transparent; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.hub-head.over { position: relative; margin-top: -22px; padding-top: 0; z-index: 1; }
.hub-video { margin: 4px 0 26px; }

/* ===== Upsell step ===== */
.up-badge { display: inline-block; margin: 6px 0 14px; padding: 6px 14px; border-radius: 999px; background: #FBEFB8; color: #5A4800; font-weight: 800; font-size: 13.5px; letter-spacing: .01em; }
.up-box { margin-top: 22px; }
.up-price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.up-price .price { font-size: 38px; }
.up-was { color: var(--graphite); font-size: 15px; }
.up-was b { color: var(--ok); }
.up-yes { height: 60px; font-size: 17px; }
.linkbtn { display: block; width: 100%; margin: 14px auto 0; padding: 12px; background: none; border: 0; font: inherit; font-weight: 650; font-size: 15.5px; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; text-align: center; }
.linkbtn.muted-link { color: var(--graphite); font-weight: 500; }
.linkbtn[disabled] { opacity: .45; cursor: not-allowed; }
.rot-up { transform: rotate(90deg); } .rot-down { transform: rotate(-90deg); }

/* ===== Give card (home page + Give page) ===== */
.give-feature { display: flex; gap: 14px; align-items: center; margin-top: 18px; padding: 14px; border-radius: var(--r-md); background: var(--mist); }
.gf-thumb { width: 64px; height: 64px; border-radius: 14px; flex: none; overflow: hidden; background: var(--ink); color: #fff; display: grid; place-items: center; }
.gf-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gf-kicker { font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--graphite); }
.gf-title { font-weight: 800; font-size: 18px; letter-spacing: -.02em; line-height: 1.2; margin: 2px 0 3px; }
.give-gifts { margin: 0 0 14px; padding: 12px 14px; border-radius: var(--r-sm); background: #DCEFE2; color: #1D5B37; font-weight: 600; font-size: 15px; line-height: 1.4; }
.ok-ic { width: 20px; height: 20px; color: var(--ok); flex: none; }

/* ===== Courses ===== */
.course-head { display: flex; gap: 16px; align-items: center; margin-top: 8px; }
.course-cover { width: 96px; height: 96px; flex: none; border-radius: var(--r-md); background: var(--ink); color: #fff; display: grid; place-items: center; overflow: hidden; }
.course-cover img { width: 100%; height: 100%; object-fit: cover; }
.course-cover .ic { width: 34px; height: 34px; }
.course-thumb { width: 64px; height: 64px; flex: none; border-radius: 14px; background: var(--ink); color: #fff; display: grid; place-items: center; overflow: hidden; }
.course-thumb img { width: 100%; height: 100%; object-fit: cover; }
.course-card { align-items: center; }
.progress.course > i { background: var(--ok); }
.notes-html { font-size: 17px; line-height: 1.65; overflow-wrap: anywhere; }
.notes-html p { margin: 0 0 14px; }
.notes-html h3, .notes-html h4, .notes-html h5 { margin: 22px 0 8px; letter-spacing: -.02em; line-height: 1.25; }
.notes-html h3 { font-size: 24px; } .notes-html h4 { font-size: 20px; } .notes-html h5 { font-size: 17px; }
.notes-html ul, .notes-html ol { margin: 0 0 14px; padding-left: 22px; } .notes-html li { margin: 4px 0; }
.notes-html a { color: var(--ink); text-underline-offset: 3px; }
.lesson-wrap { padding-bottom: 60px; }

/* ===== Custom card backgrounds (home page) ===== */
.card.themed { background: var(--cbg); color: var(--ink); }
.themed .input { background: #fff; color: #111; }
.themed .money-input > span { color: #6E6E6A; }
/* light text on a dark background */
.card.themed.tone-light { --ink: #fff; --graphite: rgba(255,255,255,.78); --line: rgba(255,255,255,.28); --mist: rgba(255,255,255,.14); --paper: rgba(255,255,255,.12); color: #fff; }
.tone-light .btn, .tone-light .btn.light { background: #fff; color: #111; border-color: #fff; }
.tone-light .btn[disabled] { opacity: .6; }
.tone-light .amt span { color: #fff; background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.3); }
.tone-light .amt input:checked + span { background: #fff; color: #111; border-color: #fff; }
.tone-light .segmented input:checked + span { background: #fff; color: #111; }
.tone-light .gf-thumb { background: rgba(255,255,255,.2); }
.tone-light .input::placeholder { color: #8A8A86; }
.tone-light .linkbtn { color: #fff; }
/* the Prayer Mission card is light-on-dark by default; this is for a light background */
.pm-card.themed::before { background: var(--cbg); }
.pm-link { color: #fff; }
.pm-card.tone-dark { color: #111; }
.pm-card.tone-dark .pm-mark { background: rgba(0,0,0,.08); }
.pm-card.tone-dark .pm-actions .btn { background: #111; color: #fff; }
.pm-card.tone-dark .pm-actions .btn.alt { background: rgba(0,0,0,.08); color: #111; }
.pm-card.tone-dark .pm-link { color: #111; }

/* ===== Admin: layout and colors ===== */
.style-preview { margin-top: 12px; padding: 18px; border-radius: var(--r-md); background: var(--paper); border: 1.5px solid var(--line); }
.style-preview .pv-title { font-weight: 800; font-size: 19px; letter-spacing: -.02em; }
.style-preview .pv-line { margin: 4px 0 12px; font-size: 14.5px; opacity: .85; }
.style-preview .pv-btn { display: inline-block; padding: 9px 22px; border-radius: 999px; font-weight: 700; font-size: 14.5px; background: #000; color: #fff; }
.swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.swatch { width: 44px; height: 44px; border-radius: 999px; border: 2px solid #fff; box-shadow: 0 0 0 1.5px var(--line), 0 2px 6px rgba(0,0,0,.12); cursor: pointer; padding: 0; }
.swatch:active { transform: scale(.93); }
.color-input { width: 100%; height: 54px; padding: 4px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--paper); cursor: pointer; }
