/* =============================================================================
   A47 "WORD" (261101) -- additions only. Loads AFTER styles.css and a43-pass2.css.
   Logical properties throughout. Nothing above is edited; superseded rules are
   overridden here with a pointer.
   ========================================================================== */

/* ---------- 1. PAGE STRIP: STORY · HOME · JOURNEY · WORD ------------------------------
   One sideways-scrolling strip, used in the header, the phone bottom bar and the menu.
   The list is written three times so it loops; the middle copy is the real one (the
   others are aria-hidden + tabindex -1). The chosen page slides to the centre and rises
   with a rounder top; the others are near-square tabs, and the ones at the edges are cut
   straight by the strip (no fade). The bottom line is one straight rule. */
.hm-pages {
  position: relative; min-inline-size: 0; overflow-x: auto; overflow-y: hidden;
  scrollbar-width: none; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  border-block-end: 2px solid var(--accent);
}
.hm-pages::-webkit-scrollbar { display: none; }
.hm-pages-track { display: flex; align-items: flex-end; gap: 4px; inline-size: max-content; padding-block-start: 6px; }
.hm-pages a {
  flex: none; display: flex; align-items: center; justify-content: center;
  min-inline-size: 92px; block-size: 34px; padding-inline: 14px; box-sizing: border-box;
  border-radius: 3px 3px 0 0; scroll-snap-align: center;
  font-size: .78rem; font-weight: 700; letter-spacing: .04em; text-decoration: none; white-space: nowrap;
  color: #fff; background: rgba(255,255,255,.10);
  transition: block-size .32s cubic-bezier(.3,.7,.2,1), border-radius .32s cubic-bezier(.3,.7,.2,1), background-color .32s, color .32s;
}
.hm-pages a:hover { background: rgba(255,255,255,.18); }
.hm-pages a[aria-current="page"] {
  block-size: 40px; border-radius: 16px 16px 0 0;
  background: var(--accent); color: var(--on-accent);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.6);
}
.hm-pages a:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; }
.hm-pages a[aria-current="page"]:focus-visible { outline-color: var(--on-accent); }
/* On a light ground (bottom bar, menu): navy words, navy line. */
.hm-pages.on-light { border-block-end-color: var(--primary); }
.hm-pages.on-light a { color: var(--primary); background: color-mix(in srgb, var(--primary) 9%, var(--card-bg)); }
.hm-pages.on-light a:hover { background: color-mix(in srgb, var(--primary) 16%, var(--card-bg)); }
.hm-pages.on-light a[aria-current="page"] { color: var(--on-accent); background: var(--accent); }
@media (prefers-reduced-motion: reduce) { .hm-pages a { transition: none; } }
body.motion-paused .hm-pages a { transition: none; }

/* ---------- Header, desktop (721px+): STORY left of the home block; JOURNEY · WORD right of it;
   magnifier in the end corner. Same .header-story-link words as before; the strip is phone-only.
   HOME is the home block itself. Shrunk header still hides the words (styles.css item b). */
header.topbar .hm-hdr-story { grid-row: 1; }
@media (min-width: 721px) {
  header.topbar { grid-template-columns: auto minmax(0,1fr) auto minmax(0,1fr); column-gap: 28px; }
  header.topbar #bookshelf-btn { grid-row: 1; grid-column: 1; }
  header.topbar .hm-hdr-story { grid-column: 2; justify-self: end; }
  header.topbar .home-block { grid-row: 1; grid-column: 3; }
  header.topbar .header-right { grid-row: 1; grid-column: 4; justify-self: stretch; display: flex; align-items: center; gap: 24px; }
  header.topbar .header-right .search-btn { margin-inline-start: auto; }
  header.topbar .hm-hdr-pages { display: none; }
}
/* Phone (720px and less): the header is only Menu · home block · magnifier.
   The page words and the strip leave the header; the pages are in the menu and the bottom bar.
   (A43 pass 2 stacked STORY/JOURNEY here; superseded.) */
@media (max-width: 720px) {
  header.topbar .hm-hdr-story, header.topbar.shrunk .hm-hdr-story,
  header.topbar .header-right .hm-hdr-link, header.topbar.shrunk .header-right .hm-hdr-link { display: none; }
  header.topbar { grid-template-columns: 1fr auto 1fr; }
  header.topbar .header-right { grid-row: 1; grid-column: 3; justify-self: end; flex-direction: row; }
  header.topbar .header-right .search-btn { display: grid; }
}

/* ---------- Phone bottom bar: the pill strip across the full width (no magnifier; Search is in the menu).
   The round Menu leaves the bar and sits under ↓ in the arrows stack (.hm-fab-menu). ---
   The pill is the A44 .hm-seg shape. While the strip moves, the end it moves toward is cut
   straight (.cut-start / .cut-end, set from the scroll direction); at rest both ends are round. */
.hm-bb-pages {
  flex: 1; min-inline-size: 0; block-size: var(--bar-h); display: flex; align-items: stretch; padding: 3px; box-sizing: border-box;
  background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 999px; overflow: hidden; box-shadow: var(--elev-2), inset 0 2px 5px rgba(0,0,0,.10);
  transition: border-radius .22s cubic-bezier(.3,.7,.2,1);
}
.hm-bb-pages.cut-start { border-start-start-radius: 0; border-end-start-radius: 0; }
.hm-bb-pages.cut-end { border-start-end-radius: 0; border-end-end-radius: 0; }
.hm-bb-pages .hm-pages { flex: 1; border-block-end: 0; border-radius: inherit; }
.hm-bb-pages .hm-pages-track { align-items: stretch; block-size: 100%; padding: 0; }
.hm-bb-pages .hm-pages a { block-size: auto; border-radius: 4px; background: transparent; min-inline-size: 84px; }
.hm-bb-pages .hm-pages a[aria-current="page"] {
  border-radius: 999px; background: var(--accent);
  box-shadow: 0 2px 4px rgba(0,0,0,.25), inset 0 1px 0 rgba(255,255,255,.6), inset 0 -2px 0 rgba(0,0,0,.14);
}
@media (prefers-reduced-motion: reduce) { .hm-bb-pages { transition: none; } }
body.motion-paused .hm-bb-pages { transition: none; }
.hm-bar-search .search-mark { inline-size: 22px; block-size: 22px; stroke-width: 2.4; }
.hm-bar-search:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ---------- Menu: pages stay books (Home · Story · Journey · Word); magnifier in the bar's end corner */
.side-panel .hm-panel-bar .hm-bar-search {
  margin-inline-start: auto; inline-size: var(--tap); block-size: var(--tap); border-radius: 50%; padding: 0;
  border: 1px solid var(--border); background: var(--card-bg); color: var(--primary); display: grid; place-items: center; cursor: pointer;
}

/* ---------- 6. Follow + Learn: no group labels, no dashed placeholder ---------------- */
/* Shelf below Share: Feed reader, then Learn (a book that opens like Settings).
   Learn > Tools: a link with a round (i); the (i) opens a short notice under the row. */
.hm-tools-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-block-size: 44px; }
.hm-tools-row > a { flex: 1; min-block-size: 44px; display: flex; align-items: center; font-weight: 700; color: var(--primary); text-decoration: none; }
.hm-tools-row > a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 4px; }
.hm-tools-row .hm-info { inline-size: 44px; block-size: 44px; }
.hm-tools-row .hm-info span { inline-size: 22px; block-size: 22px; font-size: .8rem; border-width: 1.5px; }
.hm-tools-note { margin: 0 0 6px; }

/* ---------- 5. Moving-text line back at 30px, small play/pause inside ------------------- */
/* (A46 V4 §9c made the line 52px for a 44px button; superseded.) The visible box is 22px;
   the hit area reaches 44px wide across the line's full 30px height. */
#status-ticker.hm-ticker { block-size: 30px; height: 30px; padding-inline: 4px 0; gap: 8px; }
.hm-motion.hm-motion-line { position: relative; inline-size: 22px; block-size: 22px; border-width: 1.5px; border-radius: 6px; }
.hm-motion.hm-motion-line::before { content: ""; position: absolute; inset: -4px -11px; }
.hm-motion.hm-motion-line .play { inline-size: 8px; block-size: 10px; border-inline-width: 3px; }
.hm-motion.hm-motion-line[aria-pressed="true"] .play { inline-size: 0; block-size: 0; margin-left: 2px; border-left-width: 8px; border-block-width: 5px; }

/* Phone floating buttons lower: on the gesture line while the bar is away, just above the
   bar when it shows. (Was 96px at all times.) */
@media (max-width: 1023px) {
  :root { --float-bottom: calc(var(--gesture) + 6px); }
  body.has-bottombar { --float-bottom: calc(var(--gesture) + 6px + var(--bar-h) + 8px); }
  .hm-float, .hm-untuck { transition: inset-block-end .26s cubic-bezier(0.618, 0, 0.382, 1); }
}

/* ---------- 2. WORD page ---------------------------------------------------------------- */
.hm-word { padding-block: 12px 8px; }
.hm-word-kicker { margin: 0 0 6px; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--secondary); }
.hm-word h1 { font-family: var(--serif); font-weight: 700; font-size: clamp(1.9rem, 1.5rem + 1.6vw, 2.6rem); line-height: 1.15; margin: 0 0 22px; text-wrap: balance; }
.hm-word p { max-width: 60ch; margin: 0 0 1.2em; line-height: 1.65; text-wrap: pretty; }
@media (max-width: 480px) { .hm-word p { font-size: 1.125rem; } }
.hm-word-help { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-block-start: 28px !important;
  padding-block-start: 16px; border-block-start: 1px solid var(--border); color: var(--secondary); font-size: .95rem !important; }
.hm-word-help a { color: var(--primary); font-weight: 700; text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 4px; min-block-size: 44px; display: inline-flex; align-items: center; }

/* ---------- 4. HOME: the last three posts + More ----------------------------------------- */
.hm-latest { margin: 8px 0 36px; }
.hm-latest h2 { margin: 0 0 12px; }
@media (min-width: 720px) { .hm-latest .jr-card { flex-basis: calc((100% - 48px) / 4); } }
.hm-pic-helmet { align-items: center; justify-content: center; padding: 10%; }
.hm-pic-helmet img { inline-size: auto; block-size: 76%; max-inline-size: 100%; object-fit: contain; }
.hm-more-pic { display: flex; align-items: center; justify-content: center; gap: 6px; aspect-ratio: 4 / 3;
  background: color-mix(in srgb, var(--primary) 7%, var(--card-bg)); border-block-end: 3px solid var(--border);
  color: var(--primary); font-size: 1.35rem; font-weight: 700; }
.hm-more-pic b { color: var(--fa8th); font-size: 1.6rem; line-height: 1; }

/* ---------- 3. MILESTONES: "Previous milestones" ---------------------------------------- */
.hm-prev-ms {
  display: inline-flex; align-items: center; gap: 10px; min-block-size: 48px; padding: 4px 20px 4px 10px;
  border: 0; border-radius: 999px; background: #2D3250; color: #fff; font: inherit; font-weight: 700; font-size: .92rem;
  cursor: pointer; outline: 1.5px solid var(--accent); outline-offset: -5px; box-shadow: var(--elev-1);
}
.hm-prev-ms .ord { display: inline-flex; align-items: flex-start; font-family: var(--serif); font-size: 1.6rem; line-height: 1; color: var(--accent); padding-inline-start: 6px; }
.hm-prev-ms .ord small { font-size: .5em; margin-block-start: .1em; margin-inline-start: 1px; }
.hm-prev-ms:hover { background: #3A4270; }
.hm-prev-ms:focus-visible { outline: 1.5px solid var(--accent); outline-offset: -5px; box-shadow: 0 0 0 3px var(--card-bg), 0 0 0 6px var(--accent); }
html[data-theme="dark"] .hm-prev-ms { background: #FFD700; color: #2D3250; outline-color: #2D3250; }
html[data-theme="dark"] .hm-prev-ms .ord { color: #2D3250; }
html[data-theme="dark"] .hm-prev-ms:hover { background: #FFE34D; }
html[data-theme="dark"] .hm-prev-ms:focus-visible { outline-color: #2D3250; box-shadow: 0 0 0 3px var(--bg), 0 0 0 6px #FFD700; }
.hm-prev-note { margin: 10px 4px 0; font-size: .9rem; color: var(--secondary); }
.hm-prev-note[hidden] { display: none; }
/* Sign-up now sits after Milestone 2, inside the sheet. */
.hm-sheet-page > #stay-connected { margin: 0 0 10px; }

/* Menu in the arrows stack, under ↓, only while the phone bottom bar shows (the header,
   with its own Menu, is away then). */
.hm-fab-menu { display: none; }
@media (max-width: 1023px) {
  body.has-bottombar .hm-fab-menu { display: grid; place-items: center; }
  .hm-fab-menu .bb-menu-mark { inline-size: 22px; block-size: 22px; }
  .hm-bottombar { padding-inline: 12px; }
}

/* ---------- Milestone numbers: the ordinal mark. Navy with a gold inner line, gold figures
   and a small suffix (1st, 2nd ...); reversed in dark. Replaces the large gold numeral. */
.hm-chapter-num {
  display: inline-flex; align-items: flex-start; justify-content: center; box-sizing: border-box;
  min-inline-size: 52px; block-size: 52px; padding: 11px 8px 0 10px; border-radius: 14px;
  background: #2D3250; color: #FFD700; outline: 1.5px solid #FFD700; outline-offset: -5px;
  font-family: var(--serif); font-size: 1.7rem; line-height: 1; font-weight: 700;
}
.hm-chapter-num small { font-size: .5em; margin-block-start: .1em; margin-inline-start: 1px; }
html[data-theme="dark"] .hm-chapter-num { background: #FFD700; color: #2D3250; outline-color: #2D3250; }

/* Previous milestones: a collapsed box (show / hide), Milestone 1 inside. */
.hm-prev { margin: 0 0 10px; }
.hm-prev-ms { inline-size: 100%; justify-content: space-between; padding: 4px 22px; }
.hm-prev-toggle { font-size: .82rem; font-weight: 700; color: #FFD700; text-decoration: underline; text-underline-offset: 3px; }
html[data-theme="dark"] .hm-prev-toggle { color: #2D3250; }
.hm-prev-body { padding-block-start: 10px; }
.hm-prev-body[hidden] { display: none; }


/* ===== A47.2 integration (261101, Claude Code). Design's rules above are unchanged; these lines fit them to
   what A47 / A47.1 already built (Christian's answers of 1 Nov: 22 px pause box, Previous milestones box). ===== */
/* Pause / play: A47 drew a 32 px box with ::before on a 44 px button; a47.css wants the 22 px box on the button
   itself and ::before as the invisible hit area. Undo A47's drawing so only Design's box shows. */
.hm-motion.hm-motion-line { margin-block: 0; border: 1.5px solid currentColor; border-radius: 6px; background: transparent; display: grid; place-items: center; padding: 0; }
.hm-motion.hm-motion-line::before { inset: -4px -11px; border: 0; border-radius: 0; background: none; }
.hm-motion.hm-motion-line:hover::before { background: none; }
.hm-motion.hm-motion-line:hover { background: rgba(255,255,255,.14); }
/* Previous milestones: the "1st", the label and show / hide in one row. */
.hm-prev-ms .hm-prev-label { flex: 1; text-align: start; }
/* The Home row keeps A47's sideways scroll; the More card's picture fills like the others. */
.hm-latest .hm-more-card > a { display: flex; flex-direction: column; text-decoration: none; color: inherit; }

/* ===== A47.3 (261101, Claude Code): Word page list, menu link to it, Learn > Guide rows, the Guide bubbles,
   and no iOS link preview on the home logo (it is held for "back to top"). ===== */
.hm-word h2 { font-size: 1.05rem; margin: 26px 0 8px; }
.hm-word-langs { list-style: none; padding: 0; margin: 0 0 1.2em; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); gap: 6px 18px; }
.hm-word-langs li { padding: 8px 0; border-block-end: 1px solid var(--border); font-weight: 700; color: var(--primary); }
.hm-word-en { font-weight: 400; color: var(--secondary); }
.lang-progress-link { display: flex; align-items: center; justify-content: space-between; min-block-size: 44px; padding-inline: 4px; font-weight: 700; color: var(--primary); text-decoration: none; }
.lang-progress-link:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 4px; }
.hm-learn-row { display: flex; align-items: center; inline-size: 100%; min-block-size: 44px; padding: 0 4px; border: 0; border-block-start: 1px solid var(--border);
  background: none; color: var(--primary); font: inherit; font-weight: 700; text-align: start; cursor: pointer; }
.hm-learn-row:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 4px; }
header .home-block { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }

.hm-guide { position: fixed; z-index: 10050; box-sizing: border-box; padding: 14px 16px 12px; border-radius: 16px;
  background: #2D3250; color: #fff; box-shadow: 0 10px 30px rgba(0,0,0,.35); outline: 1.5px solid #FFD700; outline-offset: -5px; }
.hm-guide-arrow { position: absolute; inline-size: 16px; block-size: 16px; background: #2D3250; transform: translateX(-50%) rotate(45deg); }
.hm-guide[data-side="below"] .hm-guide-arrow { top: -8px; }
.hm-guide[data-side="above"] .hm-guide-arrow { bottom: -8px; }
.hm-guide[data-side="none"] .hm-guide-arrow { display: none; }
.hm-guide-text { margin: 0 26px 12px 0; font-size: .95rem; line-height: 1.5; }
.hm-guide-x { position: absolute; inset-block-start: 4px; inset-inline-end: 4px; inline-size: 44px; block-size: 44px; border: 0; background: none; color: #fff; font-size: 1.4rem; cursor: pointer; }
.hm-guide-foot { display: flex; align-items: center; gap: 8px; }
.hm-guide-count { flex: 1; font-size: .8rem; opacity: .85; }
.hm-guide-btn { min-block-size: 44px; padding: 0 14px; border: 1.5px solid #FFD700; border-radius: 999px; background: transparent; color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.hm-guide-go { background: #FFD700; color: #2D3250; }
.hm-guide button:focus-visible { outline: 3px solid #FFD700; outline-offset: 2px; }
.hm-guide-target { outline: 3px solid #FFD700 !important; outline-offset: 3px !important; border-radius: 12px; }
html[data-theme="dark"] .hm-guide, html[data-theme="dark"] .hm-guide-arrow { background: #FFD700; color: #2D3250; }
html[data-theme="dark"] .hm-guide { outline-color: #2D3250; }
html[data-theme="dark"] .hm-guide-x, html[data-theme="dark"] .hm-guide-btn { color: #2D3250; border-color: #2D3250; }
html[data-theme="dark"] .hm-guide-go { background: #2D3250; color: #FFD700; }
html[data-theme="dark"] .hm-guide button:focus-visible { outline-color: #2D3250; }

/* A48 (261105): "Research Projects" label inside Learn (menu). New rules only. */
.hm-learn-group { display: grid; border-block-start: 1px solid var(--border); }
.hm-learn-sub { padding: 10px 4px 0; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--secondary); font-weight: 600; }
.hm-learn-group .hm-learn-row { border-block-start: 0; }
:root[data-theme="dark"] .hm-learn-sub { color: var(--accent); }

/* A48 (261107, Christian): three fixes. New rules only.
   1. Pause / play: an old `#motion-btn { position: fixed }` (id) beat `.hm-motion-line { position: relative }`
      (class), so the button stayed where it first sat when the top bar went away, and its box was see-through.
      Now it stays inside the line, and the box is solid white with the line's own colour on it. */
#motion-btn.hm-motion-line { position: relative; color: var(--brand-solid); }
.hm-motion.hm-motion-line::before { background: #fff; border-color: #fff; }
.hm-motion.hm-motion-line:hover::before { background: #fff; filter: brightness(.9); }
/* 2. Footer: plain clickable links, no boxes (as on the other pages). */
footer .footer-col a.social-pill, footer .footer-col button.social-pill {
  border: 0; background: none; border-radius: 0; box-shadow: none; padding: 6px 0; min-height: 32px; margin: 0;
  color: var(--primary); font-weight: 500; text-decoration: none; cursor: pointer; text-align: start;
}
footer .footer-col a.social-pill:hover, footer .footer-col button.social-pill:hover { text-decoration: underline; text-underline-offset: 3px; background: none; }
footer .footer-col a.social-pill:focus-visible, footer .footer-col button.social-pill:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
@media (pointer: coarse) { footer .footer-col a.social-pill, footer .footer-col button.social-pill { min-height: 44px; display: flex; align-items: center; } }
/* 3. Back MF8 in the header, beside the magnifier, on a computer; the floating pill is for phones. */
.hm-hdr-back { display: none; }
@media (min-width: 1024px) {
  .hm-hdr-back { display: inline-flex; align-items: center; gap: .3em; min-height: 40px; padding: 0 16px; margin-inline-end: 10px;
    border-radius: 999px; background: var(--accent); color: var(--on-accent, #1a1a1a); font-weight: 700; font-size: .92rem; text-decoration: none; white-space: nowrap; }
  .hm-hdr-back:hover { filter: brightness(.94); }
  .hm-hdr-back:focus-visible { outline: 3px solid var(--on-brand, #fff); outline-offset: 2px; }
  .hm-pill-slot { display: none; }
}

/* A48 (261107): honeycomb for the referral links in "Support me personally". Rows of two, each row centred, so a
   single cell sits between the two above it; more cells just add rows. The outline is the outer hexagon, the fill the inner. */
.hc { display: grid; justify-items: center; margin: 14px 0 6px; }
.hc-row { display: flex; justify-content: center; gap: 6px; margin-block-end: -32px; }
.hc-row:last-child { margin-block-end: 0; }
.hc-hex { display: grid; place-items: center; inline-size: 112px; block-size: 128px; background: var(--primary); color: var(--text); text-decoration: none; text-align: center;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.hc-hex > span { display: grid; place-items: center; align-content: center; gap: 2px; box-sizing: border-box; inline-size: calc(100% - 4px); block-size: calc(100% - 4px); padding: 14px 12px;
  background: var(--card-bg); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); font-size: .86rem; font-weight: 700; }
.hc-hex small { font-weight: 400; font-size: .68rem; color: var(--secondary); }
.hc-hex:hover > span { background: color-mix(in oklab, var(--accent) 22%, var(--card-bg)); }
.hc-hex:focus-visible { outline: none; background: var(--accent); }
.hc-hex:focus-visible > span { inline-size: calc(100% - 12px); block-size: calc(100% - 12px); }
.hc-list { margin: 12px 0 0; padding-inline-start: 1.1em; font-size: .84rem; line-height: 1.5; }
.freq-row button[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
#pp-paypal[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .hc-hex, .hc-hex > span { transition: none; } }
/* A48: the Community column's Telegram link had its own box (an older id rule); plain like the others. */
footer #footer-community a.social-pill, footer #footer-community a.social-pill.active { background: none; border: 0; padding: 6px 0; color: var(--primary); font-weight: 500; }
/* A48 (261107, handoff 2.2 and 2.3): the offer after an update (same colours as the Guide bubbles), the small "new"
   dot on What's new, and the What's new list. New rules only. */
.hm-offer { position: fixed; z-index: 10040; inset-inline-end: 16px; inset-block-end: 96px; box-sizing: border-box; inline-size: min(340px, calc(100vw - 32px));
  padding: 14px 14px 10px; border: 1px solid var(--border); border-radius: 16px; background: var(--card-bg); color: var(--text); box-shadow: var(--elev-2, 0 10px 30px rgba(0,0,0,.25)); }
/* A48 v2: Design 3.6 look (card, Show me = the send button, Not now = a text button); was navy like the Guide bubbles. */
.hm-offer-h { margin: 0 0 4px; font-weight: 700; font-size: 1.06rem; color: var(--primary); }
.hm-offer-text { margin: 0 0 10px; font-size: .92rem; line-height: 1.5; }
.hm-offer-foot { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
.hm-offer .hm-offer-show { inline-size: auto; min-block-size: 44px; padding-inline: 20px; }
.hm-offer-later { min-block-size: 44px; padding-inline: 14px; border: 0; background: none; color: var(--primary); font: inherit; font-weight: 600; cursor: pointer; }
.hm-offer-later:hover { text-decoration: underline; text-underline-offset: 3px; }
.hm-offer button:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
@media (prefers-reduced-motion: no-preference) { .hm-offer { animation: hm-offer-in .2s ease-out; } }
/* A48 v2 (261107): never over an open window or the side menu (Design 3.6); it comes back when they close. */
body:has(#info-modal-overlay.open) .hm-offer, body:has(#side-panel.open) .hm-offer { visibility: hidden; }
@keyframes hm-offer-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (min-width: 1024px) { .hm-offer { inset-block-end: 24px; } }
@media (max-width: 1023px) { .hm-offer { inset-block-start: 96px; inset-block-end: auto; inset-inline: 16px; inline-size: auto; max-inline-size: 420px; margin-inline: auto; } }   /* phone: clear of the arrows and Back MF8 */
.hm-new-dot { display: inline-block; inline-size: 9px; block-size: 9px; margin-inline-start: 8px; border-radius: 50%; background: #C0392B; flex: none; }
html[data-theme="dark"] .hm-new-dot { background: #FF8A80; }
.hm-wn-intro { margin: 0 0 10px; font-size: .9rem; color: var(--secondary); }
.hm-wn { border-block-start: 1px solid var(--border); }
.hm-wn summary { display: flex; align-items: center; gap: 10px; min-block-size: 56px; cursor: pointer; list-style: none; }
.hm-wn summary::-webkit-details-marker { display: none; }
.hm-wn summary::after { content: ""; margin-inline-start: auto; inline-size: 12px; block-size: 8px; background: var(--secondary);
  clip-path: polygon(0 0, 100% 0, 50% 100%); transition: transform .2s; }
.hm-wn[open] summary::after { transform: rotate(180deg); }
.hm-wn summary:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; border-radius: 4px; }
.hm-wn-v { font-size: 1.06rem; font-weight: 700; color: var(--primary); }
.hm-wn-date { font-size: .82rem; font-weight: 400; color: var(--secondary); }
@media (prefers-reduced-motion: reduce) { .hm-wn summary::after { transition: none; } }
.hm-wn ul { margin: 0; padding-inline-start: 1.2em; }
.hm-wn li { margin: 0 0 6px; font-size: .92rem; line-height: 1.5; }
.hm-wn-letter { margin: 4px 0 8px; font-size: .9rem; }
/* A48 v2 (261107, Design handoff 3.4): the support form follows the provider row (GIVE in app.js); chips are real
   radio buttons; the referral honeycomb is one list (rows of 3/2 on a phone, 4/3 on a computer), and becomes a plain
   list when fewer than 2 cells fit (400 % zoom, large text; Design said 340 px, too wide for the sheet). The older .hc / .hc-hex rules above are no longer used. */
.hm-give .hm-send { display: flex; align-items: center; justify-content: center; gap: .4em; margin-block-start: 12px; text-decoration: none; box-sizing: border-box; }
.hm-give .hm-send:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.hm-give-opens { margin: 6px 0 0; font-size: .78rem; color: var(--secondary); text-align: center; }
.hm-give-note { margin: 12px 0 0; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; font-size: .9rem; line-height: 1.5; }
.hm-give-note[hidden], .hm-chips[hidden], #pp-custom[hidden] { display: none; }
.hm-chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 12px 0 0; padding: 0; border: 0; }
.hm-chips#pp-amount { grid-template-columns: repeat(auto-fit, minmax(64px, 1fr)); }
.hm-chips legend { padding: 0; margin-block-end: 6px; font-size: .8rem; font-weight: 700; color: var(--primary); }
.hm-chips label { position: relative; display: block; }
.hm-chips input[type="radio"] { position: absolute; opacity: 0; inset: 0; margin: 0; }
.hm-chips label > span { display: flex; align-items: center; justify-content: center; min-block-size: 44px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--card-bg); color: var(--primary); font-size: .95rem; cursor: pointer; }
.hm-chips input:checked + span { background: var(--brand-solid); color: var(--on-brand, #fff); border: 2px solid var(--accent); font-weight: 700; }
.hm-chips input:focus-visible + span { outline: 3px solid var(--primary); outline-offset: 2px; }
.hm-chips #pp-custom { grid-column: 1 / -1; margin: 0; }
.hm-hc { container-type: inline-size; list-style: none; margin: 14px 0 6px; padding: 0 0 26px; }
.hm-hc-row { display: flex; justify-content: center; gap: 4px; margin-block-end: -26px; }
.hm-hc-row:last-child { margin-block-end: 0; }
.hm-hc-cell { display: grid; place-items: center; inline-size: 104px; block-size: 120px; padding: 2px; box-sizing: border-box; background: var(--border); color: var(--text); text-decoration: none;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); flex: none; }
.hm-hc-cell > span { display: grid; place-items: center; align-content: center; gap: 2px; inline-size: 100%; block-size: 100%; background: var(--card-bg); text-align: center;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.hm-hc-cell b { font-size: .94rem; color: var(--primary); }
.hm-hc-cell small { font-size: .75rem; color: var(--secondary); }
.hm-hc-cell:hover { background: var(--primary); }
.hm-hc-cell:hover > span { background: color-mix(in oklab, var(--accent) 18%, var(--card-bg)); }
.hm-hc-cell:focus-visible { outline: none; background: var(--primary); padding: 5px; }
.hm-hc-cell:active { transform: scale(.97); }
.hm-hc-spacer { visibility: hidden; }
@media (min-width: 1024px) {
  .hm-hc { padding-block-end: 32px; }
  .hm-hc-row { gap: 6px; margin-block-end: -32px; }
  .hm-hc-cell { inline-size: 132px; block-size: 152px; }
  .hm-hc-cell b { font-size: 1rem; } .hm-hc-cell small { font-size: .78rem; }
}
/* The list form: set by app.js when fewer than 2 cells fit (hcFit), and by the container query when the box later shrinks. */
.hm-hc.hm-hc-list { padding-block-end: 0; }
.hm-hc-list .hm-hc-row { flex-direction: column; gap: 8px; margin-block-end: 8px; }
.hm-hc-list .hm-hc-cell { inline-size: auto; block-size: auto; min-block-size: 48px; clip-path: none; border-radius: 12px; padding: 1px; }
.hm-hc-list .hm-hc-cell > span { clip-path: none; border-radius: 11px; display: flex; justify-content: space-between; padding: 0 14px; min-block-size: 46px; }
.hm-hc-list .hm-hc-spacer { display: none; }
@container (max-width: 211px) {
  .hm-hc-row { flex-direction: column; gap: 8px; margin-block-end: 8px; }
  .hm-hc-cell { inline-size: auto; block-size: auto; min-block-size: 48px; clip-path: none; border-radius: 12px; padding: 1px; }
  .hm-hc-cell > span { clip-path: none; border-radius: 11px; display: flex; justify-content: space-between; padding: 0 14px; min-block-size: 46px; }
  .hm-hc-spacer { display: none; }
}
@media (prefers-reduced-motion: reduce) { .hm-hc-cell:active { transform: none; } }
/* A48 v2 (261107, Design handoff 3.1): the minimal footer. Plain links in lists; 2 columns on a phone, 3 from 720 px,
   3 from 720 px and on a computer: two rows of three (Christian, 7 Nov, 03:2x: the footer sits in the 640 px text column,
   where one row of 5 broke the long links onto three lines; Design drew one row of 6 with Research, which stays inside Learn). Rows are 32 px (Design),
   44 px on touch screens (the site's tap rule). Replaces the .footer-col / .social-pill rules for the footer. */
footer > .footer-cols { display: block; margin-top: 18px; }
.hm-foot { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 16px; }
.hm-foot-col { min-inline-size: 0; }
.hm-foot h2 { margin: 0 0 4px; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--secondary); }
.hm-foot ul { list-style: none; margin: 0; padding: 0; }
.hm-foot li { margin: 0; }
.hm-foot li > a, .hm-foot li > button { display: flex; align-items: center; min-block-size: var(--fl-h, 32px); padding: 0; border: 0; background: none;
  color: var(--primary); font: inherit; font-size: .94rem; font-weight: 500; text-align: start; text-decoration: none; cursor: pointer; }
.hm-foot li > a:hover, .hm-foot li > button:hover { text-decoration: underline; text-underline-offset: 3px; }
.hm-foot li > a:focus-visible, .hm-foot li > button:focus-visible { text-decoration: underline; text-underline-offset: 3px;
  outline: 3px solid var(--primary); outline-offset: 2px; border-radius: 4px; }
.hm-foot .footer-tool { display: flex; flex-wrap: wrap; align-items: center; gap: 0 8px; }
.hm-foot .footer-tool > a { display: inline-flex; align-items: center; min-block-size: var(--fl-h, 32px); color: var(--primary); font-size: .94rem; text-decoration: none; }
.hm-foot .footer-tool > a:hover { text-decoration: underline; text-underline-offset: 3px; }
.hm-foot .footer-tool .hm-info-note { flex: 0 0 100%; margin: 4px 0 8px; }
.hm-foot .hm-new-dot { margin-inline-start: 8px; }
.hm-foot-postal { margin: 14px 0 0; font-size: .85rem; color: var(--secondary); }
@media (pointer: coarse) { .hm-foot { --fl-h: 44px; } }
@media (min-width: 720px) { .hm-foot { grid-template-columns: repeat(3, auto); justify-content: space-between; gap: 22px 24px; } }   /* columns as wide as their words, so no link wraps */
@media (min-width: 1024px) {
  .hm-foot { gap: 24px; }
  .hm-foot-col:not(:nth-child(3n+1)) { border-inline-start: 1px solid var(--border); padding-inline-start: 16px; }
  .hm-foot { --fl-h: 30px; }
}
@media (min-width: 1024px) and (pointer: coarse) { .hm-foot { --fl-h: 44px; } }
/* A48 v2 (261107, Design handoff 3.2): the header. STORY · JOURNEY (.hm-hdr-l) end-aligned before the home block,
   WORD · Back MF8 start-aligned after it; on a computer the menu and the magnifier are 44 px columns at the edges, so the
   home block is truly centred. Back MF8 is a gold outline button (was a gold fill), no breathing. */
@media (min-width: 721px) {
  header.topbar .hm-hdr-l { grid-row: 1; grid-column: 2; justify-self: end; display: flex; align-items: center; gap: 20px; }
}
@media (max-width: 720px) { header.topbar .hm-hdr-l { display: none; } }
@media (min-width: 1024px) {
  header.topbar { grid-template-columns: 44px minmax(0, 1fr) auto minmax(0, 1fr) 44px; column-gap: 28px; padding-inline: 16px; min-block-size: 64px; box-sizing: border-box; }
  header.topbar .header-right { grid-column: 4 / 6; gap: 20px; }
  header.topbar .hm-hdr-back { min-block-size: 44px; min-height: 44px; margin-inline-end: 0; padding: 0 16px; border: 2px solid var(--accent); background: transparent;
    color: var(--on-brand, #fff); font-size: .875rem; font-weight: 700; box-sizing: border-box; }
  header.topbar .hm-hdr-back b { color: var(--accent); }
  header.topbar .hm-hdr-back:hover, header.topbar .hm-hdr-back:focus-visible { background: var(--accent); color: var(--on-accent, #2D3250); filter: none; }
  header.topbar .hm-hdr-back:hover b, header.topbar .hm-hdr-back:focus-visible b { color: var(--on-accent, #2D3250); }
  header.topbar .hm-hdr-back:active { transform: scale(.97); }
  header.topbar .search-btn:focus-visible { outline: 3px solid var(--on-brand, #fff); outline-offset: 2px; }
}
@media (min-width: 1024px) and (max-width: 1099px) { header.topbar { column-gap: 16px; } header.topbar .header-right, header.topbar .hm-hdr-l { gap: 16px; } }
@media (min-width: 1024px) and (prefers-reduced-motion: reduce) { header.topbar .hm-hdr-back:active { transform: none; } }
/* A48 v2 (261107, Design handoff 3.3): on a phone and tablet the pause / play button is a TAB hanging under the
   moving line: 44 x 44, 30 px inside the line and 14 px below it, so it always moves with the line (pinned at the
   top when the header hides). Playing = navy with a gold edge and two bars; paused = gold with a navy edge and a
   triangle (never mirrored). Replaces the A47 22 px box and the A48 white box on phones; a computer keeps them. */
@media (max-width: 1023px) {
  #status-ticker.hm-ticker { position: sticky; overflow: visible; padding-inline-start: 0; }
  #status-ticker .ticker-view { padding-inline-start: 60px; }
  #status-ticker #motion-btn.hm-motion-line { position: absolute; inset-inline-start: 8px; inset-block-start: 0; z-index: 3;
    inline-size: 44px; block-size: 44px; margin: 0; padding: 4px 0 0; box-sizing: border-box; display: grid; place-items: center;
    border: 2px solid var(--accent); border-block-start: 0; border-radius: 0 0 16px 16px;
    background: var(--brand-solid); color: var(--on-brand, #fff); box-shadow: 0 2px 6px rgba(0,0,0,.25); }
  #status-ticker #motion-btn.hm-motion-line::before { display: none; }
  #status-ticker #motion-btn.hm-motion-line .play { inline-size: 10px; block-size: 14px; margin: 0; border: 0; border-inline: 4px solid currentColor; }
  #status-ticker #motion-btn.hm-motion-line[aria-pressed="true"] { background: var(--accent); border-color: var(--brand-solid); color: var(--on-accent, #2D3250); }
  #status-ticker #motion-btn.hm-motion-line[aria-pressed="true"] .play { inline-size: 0; block-size: 0; margin-left: 3px; border: 0; border-left: 12px solid currentColor; border-block: 7px solid transparent; }
  #status-ticker #motion-btn.hm-motion-line:hover { background: color-mix(in oklab, var(--on-brand, #fff) 12%, var(--brand-solid)); }
  #status-ticker #motion-btn.hm-motion-line[aria-pressed="true"]:hover { background: var(--accent); border-width: 0 3px 3px; }
  #status-ticker #motion-btn.hm-motion-line:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
}
/* A48 v2 (261107, Design handoff 3.5): the Community page. One 720 px column; intro, ways to help, the Telegram card,
   what comes next. Words: the six A47.4 footer lines (Christian D1). */
.hm-community { display: grid; gap: 28px; max-inline-size: 720px; margin-inline: auto; padding: 24px 20px 40px; box-sizing: border-box; }
.hm-community h1 { margin: 0 0 8px; font-family: var(--serif, Georgia, serif); font-size: 1.875rem; line-height: 1.2; color: var(--primary); }
.hm-cm-lede { margin: 0; font-size: 1.0625rem; line-height: 1.6; }
.hm-community h2 { margin: 0 0 8px; font-size: 1.25rem; color: var(--primary); }
.hm-cm-ways { list-style: none; margin: 0; padding: 0; }
.hm-cm-ways li { padding-block: 12px; border-block-start: 1px solid var(--border); font-size: .95rem; line-height: 1.5; }
.hm-cm-talk { padding: 18px 16px; border-radius: 12px; background: var(--card-bg); box-shadow: 0 1px 2px rgba(0,0,0,.10), 0 3px 10px rgba(0,0,0,.08); text-align: center; }
.hm-community .hm-cm-join { display: inline-flex; align-items: center; justify-content: center; gap: .4em; inline-size: auto; padding-inline: 22px; text-decoration: none; box-sizing: border-box; }
.hm-community .hm-cm-join:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.hm-cm-note { margin: 8px 0 0; font-size: .8125rem; color: var(--secondary); }
.hm-community p { margin: 0; }
@media (min-width: 720px) { .hm-community h1 { font-size: 2.25rem; } }

/* ===== A48.1 (261109, Christian): Milestones 4 and 5 ("One day. Two moments.") were flat, square-cornered rows inside the
   gold frame. Now each is a card like the other milestones (rounded, raised), with a thin gold line inside: standard plus gold. */
.milestone-pair > .milestone.hm-chapter { border: 0; border-radius: 10px; margin: 0 0 10px; padding: 16px 14px;
  background: var(--card-bg); box-shadow: inset 0 0 0 1.5px var(--accent), 0 1px 2px rgba(0,0,0,.10), 0 3px 10px rgba(0,0,0,.08); }
.milestone-pair > .milestone.hm-chapter:first-of-type { border-top: 0; }
.milestone-pair { padding: 4px 10px 2px; }

/* ===== A48.2 (261111, Christian). Previous milestones: a chevron that turns, like the FAQ rows, instead of the word "show". */
.hm-prev-toggle.chevron { text-decoration: none; font-size: 1rem; display: inline-block; transition: transform .2s ease; }
.hm-prev-ms[aria-expanded="true"] .hm-prev-toggle.chevron { transform: rotate(180deg); }
@media (prefers-reduced-motion: reduce) { .hm-prev-toggle.chevron { transition: none; } }
/* Settings: Cookies and Theme are two groups with the same kind of header (was: a small label, smaller than "Essential" inside it). */
#settings-section .settings-label, .hm-sheet .settings-label { font-size: 1.05rem; font-weight: 700; color: var(--primary); margin: 18px 0 8px; padding-block-end: 4px; border-block-end: 1px solid var(--border); }
#settings-section .settings-label:first-of-type, .hm-sheet .settings-label:first-of-type { margin-block-start: 4px; }

/* ===== A48.3 (261111): the What's new card also hides while a sheet (Settings, Language …) is open; A48 covered only the info window and the menu. */
body:has(.hm-sheet:not([hidden])) .hm-offer { visibility: hidden; }
