/* ==========================================================================
   JGL Divine Healing Technician — style.css   ("Midnight & Gold", 2026-10-06)
   ==========================================================================
   Written for ./index.php. Full notes: ./other/docs/PROJECT_GUIDE.md

   CONTENTS
     0  Design tokens (dark default · light · text-size steps)
     1  Base & helpers
     2  Splash (first visit)
     3  Top bar
     4  Hero
     5  Buttons
     6  "Welcome back" bar
     7  Learn: tabs, help, panels
     8  YouTube cards
     9  Recording cards, progress, session list
    10  Read (PDF cards)
    11  About · More on Healing · Disclaimer · Footer
    12  Course player dock
    13  Toast
    14  Responsive tweaks
    15  Reduced motion · Print

   RULES
   - NEVER use the class names .content / .active / .collapsible: the global menu CSS
     (/css/expanding_menu_php.css) styles them site-wide. Use .is-on / .is-current instead.
   - Everything is sized in rem so the A− / A+ text-size buttons scale the whole page.
   - Flexbox "gap" is used for convenience; older browsers just lose the spacing, not the layout.
   ========================================================================== */


/* ==========================================================================
   0  DESIGN TOKENS
   ========================================================================== */
:root {
    color-scheme: dark light;

    /* surfaces */
    --bg:        #0b1630;
    --page-bg:   radial-gradient(1100px 520px at 88% -80px, rgba(38, 86, 190, .42), transparent 62%),
                 radial-gradient(900px 500px at -10% 10%, rgba(246, 196, 83, .07), transparent 60%),
                 #0b1630;
    --surface:   #12214a;
    --surface-2: #182b5c;
    --line:      #27407a;
    --topbar-bg: rgba(11, 22, 48, .9);
    --dock-bg:   #0c1838;
    --hover:     rgba(255, 255, 255, .08);
    --track:     rgba(255, 255, 255, .16);
    --row-current: rgba(246, 196, 83, .11);

    /* text */
    --text:      #efe9d8;
    --text-2:    #b9c4df;
    --link:      #a9ccff;

    /* accents */
    --accent:    #f6c453;       /* gold: text, borders, icons */
    --accent-2:  #fde68a;
    --btn-bg:    #f6c453;
    --btn-bg-h:  #ffd770;
    --btn-ink:   #1b1403;
    --btn-line:  rgba(246, 196, 83, .55);
    --play-bg:   #f6c453;
    --play-ink:  #1b1403;
    --ok:        #4ade80;
    --ok-ink:    #052e16;
    --focus:     #fde68a;
    --shadow:    0 10px 30px rgba(0, 0, 0, .32);

    /* shape & type */
    --radius:    16px;
    --font-head: "Lora", Georgia, "Times New Roman", serif;
    --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
    --fsm:       1;             /* text-size multiplier (set by html[data-fs]) */
}

/* Light version: follows the visitor's device unless they pressed the ☀️/🌙 button */
@media (prefers-color-scheme: light) {
    :root:not([data-theme]) {
        --bg: #faf6ec;
        --page-bg: radial-gradient(1000px 480px at 90% -60px, rgba(246, 196, 83, .22), transparent 62%), #faf6ec;
        --surface: #ffffff; --surface-2: #f5eedd; --line: #e0d4b4;
        --topbar-bg: rgba(250, 246, 236, .92); --dock-bg: #ffffff;
        --hover: rgba(27, 35, 64, .07); --track: rgba(27, 35, 64, .14); --row-current: rgba(30, 58, 138, .07);
        --text: #1b2340; --text-2: #484f70; --link: #1a47c7;
        --accent: #8a4b08; --accent-2: #b45309;
        --btn-bg: #1e3a8a; --btn-bg-h: #1d4ed8; --btn-ink: #ffffff; --btn-line: rgba(30, 58, 138, .5);
        --play-bg: #1e3a8a; --play-ink: #ffffff;
        --ok: #15803d; --ok-ink: #ffffff; --focus: #1d4ed8;
        --shadow: 0 8px 24px rgba(60, 40, 0, .10);
    }
}
:root[data-theme="light"] {
    --bg: #faf6ec;
    --page-bg: radial-gradient(1000px 480px at 90% -60px, rgba(246, 196, 83, .22), transparent 62%), #faf6ec;
    --surface: #ffffff; --surface-2: #f5eedd; --line: #e0d4b4;
    --topbar-bg: rgba(250, 246, 236, .92); --dock-bg: #ffffff;
    --hover: rgba(27, 35, 64, .07); --track: rgba(27, 35, 64, .14); --row-current: rgba(30, 58, 138, .07);
    --text: #1b2340; --text-2: #484f70; --link: #1a47c7;
    --accent: #8a4b08; --accent-2: #b45309;
    --btn-bg: #1e3a8a; --btn-bg-h: #1d4ed8; --btn-ink: #ffffff; --btn-line: rgba(30, 58, 138, .5);
    --play-bg: #1e3a8a; --play-ink: #ffffff;
    --ok: #15803d; --ok-ink: #ffffff; --focus: #1d4ed8;
    --shadow: 0 8px 24px rgba(60, 40, 0, .10);
}

/* Text-size steps: A− / A+ buttons (index 1 = normal) */
html[data-fs="0"] { --fsm: .88; }
html[data-fs="2"] { --fsm: 1.12; }
html[data-fs="3"] { --fsm: 1.25; }
html[data-fs="4"] { --fsm: 1.4; }
html[data-fs="5"] { --fsm: 1.6; }


/* ==========================================================================
   1  BASE & HELPERS
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html {
    font-size: calc(106.25% * var(--fsm));          /* 17px × text-size step; respects the browser setting */
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 4.5rem;                     /* anchor links clear the sticky top bar */
}
body.jgl {
    margin: 0;
    background: var(--bg);
    background-image: var(--page-bg);
    background-repeat: no-repeat;
    color: var(--text);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}
html.has-dock body.jgl { padding-bottom: var(--dock-h, 11rem); }

.jgl a { color: var(--link); }
.jgl img { max-width: 100%; height: auto; }
.jgl h1, .jgl h2, .jgl h3 { font-family: var(--font-head); line-height: 1.2; margin: 0; }
.jgl p { margin: 0 0 1rem; }
[hidden] { display: none !important; }
.no-js .js-only { display: none !important; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 700px) { .wrap { padding: 0 28px; } }

/* Keyboard focus is always clearly visible */
.jgl :focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 8px; }

.jgl .skip-link {
    position: absolute; left: 8px; top: -80px; z-index: 200;
    background: var(--btn-bg); color: var(--btn-ink); padding: .7rem 1rem; border-radius: 10px; font-weight: 700;
}
.jgl .skip-link:focus { top: 8px; }

.callout {
    background: var(--surface); border: 1px solid var(--line); border-left: 5px solid var(--accent);
    border-radius: 12px; padding: 1rem 1.15rem; font-size: .95rem; color: var(--text-2); line-height: 1.6;
}
.callout strong { color: var(--text); }
.link-btn {
    background: none; border: 0; padding: .35rem .2rem; font: inherit; color: var(--link);
    text-decoration: underline; cursor: pointer; min-height: 44px;
}
.icon-x {
    background: transparent; border: 0; color: var(--text); font: inherit; font-size: 1.1rem; cursor: pointer;
    width: 44px; height: 44px; border-radius: 50%;
}
.icon-x:hover { background: var(--hover); }

/* play / pause / skip glyphs drawn in CSS so they look identical on every device */
.ico { display: inline-block; position: relative; width: 1em; height: 1em; flex: none; }
.ico-play  { width: 0; height: 0; border-style: solid; border-width: .55em 0 .55em .9em; border-color: transparent transparent transparent currentColor; margin-left: .2em; }
.ico-pause { width: .9em; height: 1.1em; background: linear-gradient(90deg, currentColor 0, currentColor 36%, transparent 36%, transparent 64%, currentColor 64%); }
.ico-next::before, .ico-prev::before { content: ""; position: absolute; top: .05em; border-style: solid; }
.ico-next::before { left: 0;  border-width: .45em 0 .45em .72em; border-color: transparent transparent transparent currentColor; }
.ico-prev::before { right: 0; border-width: .45em .72em .45em 0; border-color: transparent currentColor transparent transparent; }
.ico-next::after, .ico-prev::after { content: ""; position: absolute; top: .05em; width: .16em; height: .9em; background: currentColor; border-radius: 1px; }
.ico-next::after { right: .02em; }
.ico-prev::after { left: .02em; }
.ico-svg { display: block; }


/* ==========================================================================
   2  SPLASH — shown once, on the first visit. Tap / Esc skips it (script.js).
      It also removes ITSELF with a CSS animation, so it can never get stuck
      even if script.js fails to load.
   ========================================================================== */
.splash {
    display: none; position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 100;
    align-items: center; justify-content: center; margin: 0; padding: 0; border: 0; cursor: pointer;
    background: #060d20; color: #fff;
}
.show-splash .splash { display: flex; animation: jgl-splash 3s ease forwards; }
.splash img { display: block; width: 100%; height: 100%; object-fit: contain; max-width: none; }
.splash-hint {
    position: absolute; left: 0; right: 0; bottom: 1.2rem; text-align: center; font-size: .95rem;
    color: rgba(255, 255, 255, .85); text-shadow: 0 1px 6px rgba(0, 0, 0, .8);
}
.splash.is-gone { display: none !important; }
@keyframes jgl-splash { 0%, 84% { opacity: 1; visibility: visible; } 100% { opacity: 0; visibility: hidden; } }


/* ==========================================================================
   3  TOP BAR
   ========================================================================== */
.topbar {
    position: sticky; top: 0; z-index: 8;
    background: var(--topbar-bg);
    -webkit-backdrop-filter: saturate(1.4) blur(10px); backdrop-filter: saturate(1.4) blur(10px);
    border-bottom: 1px solid var(--line);
}
.topbar-in { display: flex; flex-wrap: wrap; align-items: center; min-height: 3.4rem; gap: .1rem .25rem; }
.jgl .tb-brand {
    flex: 1; min-width: 0; margin-left: .6rem; color: var(--text); text-decoration: none;
    font-family: var(--font-head); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.tb-brand span { font-weight: 600; color: var(--text-2); }
.tb-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: .15rem; margin-left: auto; }
.fs-group { display: flex; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin: 0 .25rem; }
.fs-group .tb-btn { border-radius: 0; min-width: 46px; padding: 0 .5rem; font-size: 1.08rem; letter-spacing: .01em; }
.tb-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .35rem;
    min-height: 44px; min-width: 44px; padding: 0 .65rem;
    background: transparent; color: var(--text); border: 1px solid transparent; border-radius: 12px;
    font: inherit; font-weight: 700; font-size: .95rem; cursor: pointer; white-space: nowrap;
}
.tb-btn:hover { background: var(--hover); }
.tb-ico { font-size: 1.15rem; line-height: 1; }


/* ==========================================================================
   4  HERO
   ========================================================================== */
.hero { padding: 1.6rem 0 2.2rem; }
.hero-in { display: grid; grid-template-columns: 1fr; gap: 1.4rem; align-items: center; }
.hero-art {
    order: -1; position: relative; width: 100%; padding-top: 56.25%;
    background: #0b1630 url("files/images/hero-wide-960.jpg") center / cover no-repeat;
    border-radius: var(--radius); border: 1px solid rgba(246, 196, 83, .45);
    box-shadow: 0 0 0 4px rgba(246, 196, 83, .08), 0 18px 50px rgba(0, 0, 0, .45), 0 0 70px rgba(246, 196, 83, .12);
}
.eyebrow {
    margin: 0 0 .6rem; color: var(--accent); font-weight: 800; font-size: .8rem; letter-spacing: .12em; text-transform: uppercase;
}
.hero h1 { font-size: clamp(1.85rem, 1.2rem + 3.4vw, 3.15rem); font-weight: 700; letter-spacing: -.01em; margin-bottom: .9rem; }
.h1-top { display: block; color: var(--accent); font-size: .66em; letter-spacing: .01em; margin-bottom: .1em; }
.lead { font-size: 1.12rem; color: var(--text-2); max-width: 36em; margin-bottom: 1.3rem !important; }
.lead strong { color: var(--text); }
.cta-row { display: flex; flex-wrap: wrap; gap: .7rem; margin-bottom: 1.2rem; }
.chips { display: flex; flex-wrap: wrap; gap: .45rem; list-style: none; margin: 0; padding: 0; }
.chips li {
    padding: .3rem .8rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
    font-size: .88rem; color: var(--text-2); font-weight: 600;
}
@media (min-width: 880px) {
    .hero { padding: 3rem 0 3.4rem; }
    .hero-in { grid-template-columns: 1.1fr .9fr; gap: 3.2rem; }
    .hero-art { order: 0; padding-top: 100%; max-width: 440px; justify-self: end; background-image: url("files/images/hero-square-720.jpg"); }
}


/* ==========================================================================
   5  BUTTONS
   ========================================================================== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
    min-height: 48px; padding: .65rem 1.3rem; border-radius: 999px; border: 2px solid transparent;
    font: inherit; font-weight: 800; line-height: 1.2; text-align: center; text-decoration: none; cursor: pointer;
    transition: background .15s, transform .1s, border-color .15s;
}
.btn:active { transform: translateY(1px); }
.jgl .btn-primary { background: var(--btn-bg); color: var(--btn-ink); }
.jgl .btn-primary:hover { background: var(--btn-bg-h); }
.jgl .btn-ghost { background: transparent; color: var(--text); border-color: var(--btn-line); }
.jgl .btn-ghost:hover { background: var(--hover); }
.btn-lg { min-height: 56px; font-size: 1.1rem; padding: .8rem 1.7rem; }
.btn-sm { min-height: 44px; font-size: .95rem; padding: .45rem 1.05rem; }


/* ==========================================================================
   6  "WELCOME BACK" BAR
   ========================================================================== */
.resume { background: var(--surface-2); border-top: 1px solid var(--btn-line); border-bottom: 1px solid var(--btn-line); }
.resume-in { display: flex; align-items: center; gap: .8rem; padding-top: .7rem; padding-bottom: .7rem; flex-wrap: wrap; }
.resume-ico { font-size: 1.6rem; }
.resume-txt { flex: 1 1 14rem; margin: 0 !important; font-size: 1.02rem; }
.resume-txt b { color: var(--accent); }


/* ==========================================================================
   7  LEARN: TABS · HELP · PANELS
   ========================================================================== */
.learn { padding: 2.2rem 0 1rem; }
.learn h2, .about h2, .more h2 { font-size: clamp(1.45rem, 1.1rem + 1.4vw, 2rem); margin-bottom: 1rem; }

.tabs {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: .35rem; padding: .35rem;
    background: var(--surface); border: 1px solid var(--line); border-radius: 20px; margin-bottom: 1rem;
}
.tab {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem;
    min-height: 4rem; padding: .4rem .2rem; border: 0; border-radius: 15px; background: transparent;
    color: var(--text-2); font: inherit; font-weight: 800; font-size: .98rem; cursor: pointer;
}
.tab:hover { background: var(--hover); color: var(--text); }
.tab-ico { font-size: 1.45rem; line-height: 1; }
.tab[aria-selected="true"] { background: var(--btn-bg); color: var(--btn-ink); box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
@media (min-width: 620px) {
    .tab { flex-direction: row; gap: .55rem; min-height: 3.6rem; font-size: 1.08rem; }
}

.help {
    background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: .15rem 1rem; margin-bottom: 1.2rem;
}
.help summary { cursor: pointer; font-weight: 700; min-height: 44px; display: flex; align-items: center; }
.help ul { margin: 0 0 .8rem; padding-left: 1.2rem; color: var(--text-2); }
.help li { margin: .4rem 0; }
.help li strong { color: var(--text); }

/* Panels. With JS: only the chosen one shows (html[data-tab] is set before first paint).
   Without JS: all of them show, one after another, each with a heading. */
.panel { padding-bottom: 1rem; }
.no-js .panel::before {
    content: attr(data-label); display: block; font-family: var(--font-head); font-size: 1.5rem; font-weight: 700; margin: 1.6rem 0 .6rem;
}
.no-js .tabs, .no-js .help { display: none; }
.js .panel { display: none; }
.js[data-tab="watch"]    #watch,
.js[data-tab="listen"]   #listen,
.js[data-tab="read"]     #read,
.js[data-tab="francais"] #francais { display: block; }
.js:not([data-tab]) #watch { display: block; }

/* Recording A / B switch (Listen tab) */
.seg { display: grid; grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr)); gap: .5rem; margin-bottom: .4rem; }
.seg-btn {
    display: flex; flex-direction: column; align-items: flex-start; gap: .1rem; text-align: left;
    padding: .7rem .9rem; min-height: 4rem; border: 2px solid var(--line); border-radius: 14px;
    background: var(--surface); color: var(--text); font: inherit; cursor: pointer;
}
.seg-btn:hover { border-color: var(--btn-line); }
.seg-name { font-weight: 800; }
.seg-sub  { font-size: .85rem; color: var(--text-2); }
.seg-btn[aria-pressed="true"] { border-color: var(--accent); background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--accent); }
.js #rec-A, .js #rec-B { display: none; }
.js[data-rec="A"] #rec-A, .js[data-rec="B"] #rec-B, .js:not([data-rec]) #rec-A { display: block; }


/* ==========================================================================
   8  YOUTUBE CARDS  (click-to-load: no YouTube code is downloaded until pressed)
   ========================================================================== */
.jgl .yt { position: relative; display: block; color: #fff; text-decoration: none; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.yt-play {
    position: absolute; z-index: 2; width: 74px; height: 74px; left: 50%; top: 42%; margin: -37px 0 0 -37px; border-radius: 50%;
    background: var(--play-bg); box-shadow: 0 8px 28px rgba(0, 0, 0, .55); transition: transform .15s;
}
.yt-play::before {
    content: ""; position: absolute; left: 29px; top: 21px; border-style: solid; border-width: 16px 0 16px 26px;
    border-color: transparent transparent transparent var(--play-ink);
}
.yt:hover .yt-play, .yt:focus-visible .yt-play { transform: scale(1.08); }
.yt-cap { display: flex; flex-direction: column; }
.yt-cap small { opacity: .85; }

.jgl .yt-feature { background: #0a1330; color: #fff; border-color: rgba(246, 196, 83, .45); box-shadow: var(--shadow); }
.yt-poster { display: block; position: relative; padding-top: 37.5%; background: #0b1630 url("files/images/feature-cross-960.jpg") center / cover no-repeat; }
.yt-poster .yt-play { top: 50%; }
.yt-feature .yt-cap { padding: .9rem 1.1rem 1.05rem; }
.yt-feature .yt-cap b { font-size: 1.12rem; line-height: 1.3; }
@media (min-width: 700px) { .yt-poster { padding-top: 0; height: 260px; } }
.feature { margin: .4rem 0 1.4rem; }

.sub { font-size: 1.15rem; margin: 1.4rem 0 .7rem; }
.yt-grid { display: grid; grid-template-columns: 1fr; gap: .7rem; margin-bottom: 1.6rem; }
@media (min-width: 560px) { .yt-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .yt-grid { grid-template-columns: repeat(3, 1fr); } }
.jgl .yt-card { display: flex; align-items: center; min-height: 5.2rem; background: var(--surface); color: var(--text); padding: .4rem .6rem; }
.yt-card:hover { border-color: var(--accent); }
.yt-card .yt-play { position: relative; left: auto; top: auto; margin: 0 .9rem 0 .2rem; width: 52px; height: 52px; flex: none; box-shadow: 0 3px 12px rgba(0, 0, 0, .35); }
.yt-card .yt-play::before { left: 20px; top: 14px; border-width: 12px 0 12px 19px; }
.yt-card .yt-cap b { font-size: 1rem; }
.yt-card .yt-cap small { color: var(--text-2); }

.yt-box { position: relative; width: 100%; padding-top: 56.25%; background: #000; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.yt-box iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.yt-wrap { min-width: 0; }
.yt-grid .yt-wrap { grid-column: 1 / -1; }
.yt-fallback { margin: .4rem 0 0; font-size: .9rem; }


/* ==========================================================================
   9  RECORDING CARDS · PROGRESS · SESSION LIST
   ========================================================================== */
.rec { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1rem .5rem; margin: 1.1rem 0; box-shadow: var(--shadow); }
@media (min-width: 700px) { .rec { padding: 1.3rem 1.4rem .6rem; } }
.rec-head { display: flex; flex-wrap: wrap; gap: .8rem 1.4rem; align-items: flex-start; margin-bottom: .6rem; }
.rec-info { flex: 1 1 18rem; min-width: 0; }
.rec h3 { font-size: 1.3rem; margin-bottom: .4rem; }
.rec-tag { display: inline-block; vertical-align: .15em; margin-left: .35rem; padding: .1rem .65rem; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-family: var(--font-body); font-size: .75rem; font-weight: 700; color: var(--accent); }
.rec-info p { color: var(--text-2); margin-bottom: .5rem; }
.rec-info .rec-facts { color: var(--text); font-weight: 700; font-size: .92rem; }
.rec-actions { display: flex; flex-direction: column; align-items: flex-start; gap: .3rem; }
.rec-actions small { color: var(--text-2); font-size: .8rem; }
.rec-note { padding: .6rem .2rem; color: var(--text-2); font-size: .95rem; }
.rec-foot { margin: .4rem 0 .6rem; font-size: .92rem; }

.prog { margin: .4rem 0 .6rem; }
.prog-top { display: flex; flex-wrap: wrap; align-items: center; gap: .1rem 1rem; }
.prog-text { font-weight: 800; }
.auto { display: inline-flex; align-items: center; gap: .45rem; margin-left: auto; min-height: 44px; font-size: .88rem; color: var(--text-2); cursor: pointer; }
.auto input { width: 20px; height: 20px; accent-color: var(--accent); cursor: pointer; }
.prog-bar { height: 9px; border-radius: 99px; background: var(--track); overflow: hidden; }
.prog-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent-2), var(--accent)); border-radius: 99px; transition: width .35s; }
.prog-reset { font-size: .85rem; }

/* video stage (MP4 recording) */
.vstage { margin: .4rem 0 1rem; }
.vstage video { display: block; width: 100%; max-height: 72vh; background: #000; border-radius: 12px; }
.vstage-title { margin: .5rem 0 0 !important; font-weight: 700; color: var(--accent); }

/* the sessions */
.slist { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); counter-reset: none; }
.s-row {
    display: grid; grid-template-columns: 2.3rem 3rem minmax(0, 1fr) auto 2.6rem; align-items: center; column-gap: .55rem;
    padding: .5rem .35rem; border-bottom: 1px solid var(--line); border-radius: 10px;
}
.s-row:last-child { border-bottom: 0; }
.no-js .s-row { grid-template-columns: minmax(0, 1fr) auto 2.6rem; }
.js .s-row { grid-template-areas: "done play main meta dl"; }
.js .s-done { grid-area: done; } .js .s-play { grid-area: play; } .js .s-main { grid-area: main; } .js .s-meta { grid-area: meta; } .js .s-dl { grid-area: dl; }
.js .s-row.is-missing { grid-template-areas: none; }
.js .s-row.is-missing .s-main { grid-area: auto; }
.s-row.is-current { background: var(--row-current); border-color: transparent; }
.s-row.is-current .s-title { color: var(--accent); }
.s-row.is-missing { opacity: .6; }
.s-row.is-missing .s-topic { font-style: italic; }
.s-main { min-width: 0; line-height: 1.3; }
.s-title { display: block; font-weight: 800; }
.s-topic { display: block; font-size: .9rem; color: var(--text-2); margin-top: .1rem; }
.s-meta { display: flex; flex-direction: column; text-align: right; font-size: .8rem; line-height: 1.3; color: var(--text-2); white-space: nowrap; }
.s-dur { font-weight: 700; color: var(--text); }

.s-play {
    width: 3rem; height: 3rem; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 50%;
    background: var(--play-bg); color: var(--play-ink); font-size: 1.05rem; cursor: pointer; transition: transform .12s;
}
.s-play:hover { transform: scale(1.07); }
.s-row.is-current:not(.is-playing) .s-play { box-shadow: 0 0 0 3px var(--row-current), 0 0 0 5px var(--accent); }
.s-done {
    width: 2.3rem; height: 2.3rem; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%;
    border: 2px solid var(--line); background: transparent; color: transparent; font: inherit; font-weight: 900; cursor: pointer;
    position: relative;
}
.s-done::after { content: ""; position: absolute; top: -.25rem; right: -.25rem; bottom: -.25rem; left: -.25rem; } /* bigger tap area */
.s-done:hover { border-color: var(--ok); }
.s-done[aria-pressed="true"] { background: var(--ok); border-color: var(--ok); color: var(--ok-ink); }
.jgl .s-dl {
    width: 2.6rem; height: 2.6rem; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%;
    color: var(--text-2); text-decoration: none;
}
.jgl .s-dl:hover { background: var(--hover); color: var(--text); }
.s-gap { display: block; }
.s-row.is-missing { grid-template-columns: 2.3rem 3rem minmax(0, 1fr); }
.no-js .s-row.is-missing { grid-template-columns: minmax(0, 1fr); }
.no-js .s-gap { display: none; }


/* ==========================================================================
   10  READ — PDF CARDS
   ========================================================================== */
.pdf-grid { display: grid; grid-template-columns: 1fr; gap: 1rem; margin-top: .4rem; }
@media (min-width: 760px) { .pdf-grid { grid-template-columns: repeat(3, 1fr); } }
.pdf { display: flex; flex-direction: column; align-items: flex-start; gap: .55rem; padding: 1.2rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.pdf-ico { font-size: 2.3rem; line-height: 1; }
.pdf h3 { font-size: 1.2rem; }
.pdf p { color: var(--text-2); margin: 0; font-size: .95rem; }
.pdf .pdf-facts { color: var(--text); font-weight: 700; font-size: .85rem; margin-bottom: .3rem; }
.pdf .btn { align-self: stretch; }


/* ==========================================================================
   11  ABOUT · MORE ON HEALING · DISCLAIMER · FOOTER
   ========================================================================== */
.about { padding: 2.4rem 0 1rem; }
.about-in { display: flex; flex-wrap: wrap; gap: 1.2rem 1.8rem; align-items: flex-start; }
.about-photo { width: 161px; height: 108px; border-radius: 12px; border: 2px solid var(--accent); box-shadow: var(--shadow); flex: none; }
.about-text { flex: 1 1 22rem; min-width: 0; }
.about-text p { color: var(--text-2); max-width: 44em; }

.more { padding: 1.4rem 0 1rem; }
.more-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: .7rem; }
@media (min-width: 640px) { .more-grid { grid-template-columns: 1fr 1fr; } }
.more-grid a {
    display: flex; align-items: center; gap: .9rem; min-height: 4.2rem; padding: .7rem 1rem; text-decoration: none; color: var(--text);
    background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
}
.more-grid a:hover { border-color: var(--accent); background: var(--surface-2); }
.more-ico { font-size: 1.7rem; line-height: 1; }
.more-txt { display: flex; flex-direction: column; min-width: 0; }
.more-txt small { color: var(--text-2); }

.legal { padding: 1.6rem 0 1rem; }
.foot { margin-top: 1.6rem; border-top: 1px solid var(--line); padding: 1.1rem 0 2rem; }
.foot-in { display: flex; flex-wrap: wrap; gap: .4rem 1.6rem; }
.foot a { color: var(--text-2); min-height: 44px; display: inline-flex; align-items: center; }


/* ==========================================================================
   12  COURSE PLAYER DOCK
   ========================================================================== */
.dock {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 9;
    background: var(--dock-bg); border-top: 2px solid var(--accent); box-shadow: 0 -10px 30px rgba(0, 0, 0, .38);
    padding-bottom: env(safe-area-inset-bottom, 0);
}
.dock-in { max-width: 780px; margin: 0 auto; padding: .45rem .9rem .5rem; }
.dock-top { display: flex; align-items: center; gap: .2rem; }
.dock-title { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.dock-title b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dock-title span { font-size: .8rem; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dock-btn {
    display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 0 .4rem;
    background: transparent; color: var(--text); border: 0; border-radius: 50%; font: inherit; font-weight: 800; font-size: 1.05rem; cursor: pointer;
}
.dock-btn:hover { background: var(--hover); }
.dock-speed { border-radius: 999px; border: 1px solid var(--btn-line); min-width: 3.4rem; font-size: .95rem; }
.dock-x { font-size: 1.1rem; }
.dock-seek { display: flex; align-items: center; gap: .6rem; }
.dock-time { font-variant-numeric: tabular-nums; font-size: .82rem; color: var(--text-2); min-width: 3.1rem; text-align: center; }
.dock-ctl { display: flex; align-items: center; justify-content: center; gap: .35rem; margin-top: .1rem; }
.dock-skip { font-size: .98rem; border-radius: 14px; min-width: 3.4rem; }
.dock-skip small { font-size: .7em; margin-left: 1px; }
.dock-main { width: 3.6rem; height: 3.6rem; background: var(--play-bg); color: var(--play-ink); font-size: 1.25rem; margin: 0 .3rem; }
.dock-main:hover { background: var(--btn-bg-h); }
.dock.is-loading .dock-main { opacity: .7; }

/* the seek slider, styled for Chrome/Safari/Edge and Firefox */
#seek {
    flex: 1; min-width: 0; height: 2.4rem; margin: 0; background: transparent; cursor: pointer; -webkit-appearance: none; appearance: none;
    --p: 0%;
}
#seek::-webkit-slider-runnable-track { height: 8px; border-radius: 99px; background: linear-gradient(to right, var(--accent) var(--p), var(--track) var(--p)); }
#seek::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; margin-top: -7px; border-radius: 50%; background: var(--accent-2); border: 3px solid var(--dock-bg); box-shadow: 0 0 0 2px var(--accent); }
#seek::-moz-range-track { height: 8px; border-radius: 99px; background: var(--track); }
#seek::-moz-range-progress { height: 8px; border-radius: 99px; background: var(--accent); }
#seek::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--accent-2); border: 3px solid var(--dock-bg); box-shadow: 0 0 0 2px var(--accent); }
#seek:focus-visible { outline-offset: 4px; }


/* ==========================================================================
   13  TOAST
   ========================================================================== */
.toast {
    position: fixed; left: 50%; bottom: calc(var(--dock-h, 0px) + 1.2rem); z-index: 60; max-width: min(92vw, 30rem);
    transform: translate(-50%, 16px); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
    background: #0a1022; color: #fff; border: 1px solid rgba(246, 196, 83, .6); border-radius: 14px; padding: .75rem 1.1rem; font-weight: 700; text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }


/* ==========================================================================
   13b LARGE TEXT — when A+ has been pressed, keep every control inside the screen
   ========================================================================== */
html[data-fs="3"] .tabs, html[data-fs="4"] .tabs, html[data-fs="5"] .tabs { grid-template-columns: 1fr 1fr; }
html[data-fs="4"] .topbar, html[data-fs="5"] .topbar { position: static; }
html[data-fs="4"] .dock-btn, html[data-fs="5"] .dock-btn { font-size: 1rem; }
@media (max-width: 559px) {
    /* phones: title + topic get the full middle column; duration · size sit underneath */
    .js .s-row {
        grid-template-columns: 2.1rem 2.8rem minmax(0, 1fr) 2.4rem;
        grid-template-areas: "done play main dl" ". . meta meta";
        row-gap: .1rem;
    }
    .js .s-row .s-meta { flex-direction: row; flex-wrap: wrap; gap: 0 .6rem; text-align: left; white-space: normal; }
    .js .s-row.is-missing { grid-template-columns: 2.1rem 2.8rem minmax(0, 1fr); grid-template-areas: none; }
}
@media (max-width: 559px) {
    html.js[data-fs="4"] .s-row, html.js[data-fs="5"] .s-row {
        grid-template-areas: "done play . dl" "main main main main" "meta meta meta meta";
    }
}
.s-main { overflow-wrap: break-word; }


/* ==========================================================================
   14  RESPONSIVE TWEAKS
   ========================================================================== */
@media (max-width: 899px) {
    .tb-brand span { display: none; }
}
@media (max-width: 559px) {
    .tb-brand { display: none; }
    .tb-tools { flex: 1; justify-content: flex-end; }
    #btn-theme .tb-txt, #btn-share .tb-txt { display: none; }
    .s-row { grid-template-columns: 2.1rem 2.8rem minmax(0, 1fr) auto 2.4rem; column-gap: .4rem; padding-left: .1rem; padding-right: .1rem; }
    .s-done { width: 2.1rem; height: 2.1rem; }
    .s-play { width: 2.8rem; height: 2.8rem; }
    .s-dl { width: 2.4rem; }
    .s-row.is-missing { grid-template-columns: 2.1rem 2.8rem minmax(0, 1fr); }
    .no-js .s-row { grid-template-columns: minmax(0, 1fr) auto 2.4rem; }
    .auto { margin-left: 0; }
}
@media (max-width: 339px) {
    .tb-btn .tb-txt { display: none; }
    .tb-btn { padding: 0 .45rem; }
    .fs-group { margin: 0 .1rem; }
    .dock-skip { min-width: 3rem; }
}


/* ==========================================================================
   15  REDUCED MOTION · PRINT
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

@media print {
    .splash, .topbar, .hero-art, .tabs, .help, .dock, .toast, .cta-row, .chips, .resume, .seg, .prog, .vstage,
    .s-play, .s-done, .s-dl, .s-meta, .yt, .yt-grid, .sub, .feature, .foot, .rec-actions, .rec-foot, .rec-note, .js-only,
    #watch, #francais, #rec-B, .more { display: none !important; }
    body.jgl { background: #fff !important; color: #000 !important; }
    .js #listen, .js #rec-A, .js #read { display: block !important; }
    .rec, .pdf, .callout { border: 1px solid #999; box-shadow: none; background: #fff; color: #000; }
    .jgl a { color: #000; }
    .s-row { grid-template-columns: 1fr; }
}
