:root {
  --bg: #0d0d0f;
  --panel: #151518;
  --panel-2: #1c1c20;
  --line: #2a2a30;
  --text: #ececf0;
  --muted: #8b8b95;
  --accent: #c9a24a;
  --warn: #e0534a;
  --radius: 10px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.45 -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", sans-serif; }
button, input, select { font: inherit; color: inherit; }
svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

.top { display: flex; align-items: center; gap: 16px; padding: 12px 20px; border-bottom: 1px solid var(--line); background: var(--panel); position: sticky; top: 0; z-index: 5; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand .mark { width: 30px; height: 30px; border-radius: 8px; background: var(--panel-2); border: 1px solid var(--line); display: grid; place-items: center; font-size: 11px; color: var(--accent); font-weight: 700; }
.brand b { display: block; font-size: 13px; }
.brand small { color: var(--muted); font-size: 11px; }
#search { margin-left: auto; width: min(360px, 50vw); background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; padding: 7px 10px; }

main { padding: 18px 20px 40px; position: relative; }
h1 { font-size: 20px; margin: 0 0 12px; }
.bar { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.bar .left, .bar .right { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.select { display: flex; align-items: center; gap: 6px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 0 8px; }
.select select { background: transparent; border: 0; padding: 7px 2px; outline: none; }
.select option { background: var(--panel); }
.tabs { display: flex; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 3px; }
.tabs button { background: none; border: 0; padding: 5px 14px; border-radius: 6px; cursor: pointer; color: var(--muted); }
.tabs button.on { background: var(--panel-2); color: var(--text); }
.ghost { display: inline-flex; align-items: center; gap: 6px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 7px 14px; cursor: pointer; }
a.ghost { color: var(--text); text-decoration: none; justify-content: center; }
.ghost.on { border-color: var(--accent); color: var(--accent); }
.ghost.wide { width: 100%; justify-content: center; margin-top: 14px; }
#filterCount:not(:empty) { background: var(--accent); color: #000; border-radius: 10px; padding: 0 6px; font-size: 11px; }

.filters { position: absolute; right: 20px; top: 92px; width: 320px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; z-index: 4; box-shadow: 0 12px 40px rgba(0,0,0,.5); }
.filters h3 { margin: 0 0 10px; font-size: 15px; }
.filters .pair { display: grid; grid-template-columns: 70px 1fr 1fr; gap: 8px; align-items: center; margin-bottom: 8px; }
.filters .pair span, .filters .label { color: var(--muted); font-size: 12px; }
.filters .label { display: block; margin: 12px 0 6px; }
.filters input, .filters select { width: 100%; background: var(--panel-2); border: 1px solid var(--line); border-radius: 7px; padding: 7px 9px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; max-height: 120px; overflow: auto; }
.chips button { background: var(--panel-2); border: 1px solid var(--line); border-radius: 6px; padding: 3px 9px; cursor: pointer; font-size: 12px; }
.chips button.on { border-color: var(--accent); color: var(--accent); }

.summary { color: var(--muted); margin: 14px 0 10px; font-size: 12px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.card { position: relative; aspect-ratio: 9 / 16; border-radius: var(--radius); overflow: hidden; background: var(--panel-2); border: 1px solid var(--line); cursor: pointer; }
.card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card .noimg { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 12px; }
.card .shade { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,.55), transparent 22%, transparent 62%, rgba(0,0,0,.8)); }
.card .tl, .card .tr, .card .bl, .card .br { position: absolute; font-size: 11px; display: flex; gap: 6px; align-items: center; }
.card .tl { top: 8px; left: 9px; }
.card .tr { top: 8px; right: 9px; }
.card .bl { bottom: 9px; left: 9px; flex-direction: column; align-items: flex-start; gap: 3px; }
.card .br { bottom: 9px; right: 9px; flex-direction: column; align-items: flex-end; gap: 3px; }
.pill { background: rgba(0,0,0,.55); border-radius: 5px; padding: 1px 6px; }
.pill.gold { color: var(--accent); }
.pill.ok { color: #7fd18b; }
.card .x { font-weight: 700; font-size: 13px; }
.card:hover { border-color: var(--accent); }

.detail { position: fixed; inset: 0; background: rgba(0,0,0,.72); z-index: 10; display: grid; place-items: center; padding: 20px; }
.detail .sheet { position: relative; display: grid; grid-template-columns: minmax(260px, 380px) minmax(320px, 620px); gap: 18px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 18px; max-height: calc(100vh - 40px); width: min(1040px, 100%); }
.close { position: absolute; top: 8px; right: 12px; background: none; border: 0; font-size: 26px; color: var(--muted); cursor: pointer; }
.player video { width: 100%; max-height: calc(100vh - 80px); border-radius: var(--radius); background: #000; }
.info { display: flex; flex-direction: column; min-height: 0; }
.meta { padding-right: 30px; }
.meta h2 { margin: 0 0 4px; font-size: 16px; }
.meta .stats { display: flex; flex-wrap: wrap; gap: 12px; color: var(--muted); font-size: 12px; margin: 6px 0 12px; }
.meta .stats b { color: var(--text); }
.meta a { color: var(--accent); }
.pane { overflow: auto; margin-top: 12px; padding-right: 4px; min-height: 0; }
.pane pre { white-space: pre-wrap; font: inherit; margin: 0; background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.pane .actions { display: flex; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.pane .empty { color: var(--muted); }
.shots { width: 100%; border-collapse: collapse; font-size: 12px; }
.shots td { padding: 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.shots tr { cursor: pointer; }
.shots tr:hover, .shots tr.on { background: var(--panel-2); }
.shots img { width: 54px; border-radius: 4px; display: block; }
.shots .t { color: var(--accent); white-space: nowrap; }
.pane img.wide { width: 100%; border-radius: var(--radius); margin-top: 10px; }
.tag { display: inline-block; background: var(--panel-2); border: 1px solid var(--line); border-radius: 5px; padding: 1px 7px; margin: 0 4px 4px 0; font-size: 12px; }

@media (max-width: 760px) {
  .detail .sheet { grid-template-columns: 1fr; overflow: auto; }
  .player video { max-height: 60vh; }
  .filters { left: 16px; right: 16px; width: auto; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  main, .top { padding-left: 16px; padding-right: 16px; }
}

.why { background: rgba(212, 175, 55, 0.08); border: 1px solid rgba(212, 175, 55, 0.25); border-radius: 10px; padding: 10px 14px; margin: 0 0 12px; font-size: 13px; line-height: 1.5; }
.why b { display: block; margin-bottom: 4px; color: #d4af37; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; }
.why p { margin: 0; }

/* ---------- hub additions ---------- */
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a { color: inherit; text-decoration: none; padding: 7px 12px; border-radius: 999px; font-size: 14px; opacity: 0.75; }
.nav a.on { background: rgba(255,255,255,0.1); opacity: 1; }
.view[hidden] { display: none !important; }
.doc { max-width: 760px; line-height: 1.65; font-size: 15px; }
.doc h1 { font-size: 30px; margin: 8px 0 12px; }
.doc h2 { font-size: 20px; margin: 30px 0 8px; }
.doc h3 { font-size: 16px; margin: 20px 0 6px; }
.doc ul, .doc ol { padding-left: 22px; }
.doc li { margin: 4px 0; }
.doc p { margin: 8px 0; }
.modules { display: grid; gap: 18px; max-width: 760px; }
.module h2 { font-size: 17px; margin: 0 0 8px; }
.lesson-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; background: rgba(255,255,255,0.04); margin: 6px 0; cursor: pointer; color: inherit; text-decoration: none; }
.lesson-row:hover { background: rgba(255,255,255,0.08); }
.lesson-row .tick { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,0.35); display: grid; place-items: center; font-size: 12px; flex: none; }
.lesson-row.done .tick { background: #3ecf8e; border-color: #3ecf8e; color: #062; }
.lesson-row small { margin-left: auto; opacity: 0.6; }
.lesson-video { position: relative; padding-top: 56.25%; border-radius: 12px; overflow: hidden; background: #000; margin: 10px 0 16px; max-width: 760px; }
.lesson-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player.frames { display: flex; flex-direction: column; gap: 10px; align-items: stretch; justify-content: flex-start; overflow: auto; padding: 12px; }
.player.frames img { width: 100%; border-radius: 8px; }
.player.frames .open { text-align: center; }
.player.frames .slides { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.player.frames .slides img { aspect-ratio: 9 / 16; object-fit: cover; background: #000; }
.tagbar { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; }
.tagbar button { font-size: 12px; }
body.gate { display: grid; place-items: center; min-height: 100vh; }
.gatebox { max-width: 380px; width: calc(100% - 32px); padding: 28px; border-radius: 16px; background: rgba(255,255,255,0.04); }
.gatebox .brand { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.gatebox h1 { font-size: 22px; margin: 0 0 8px; }
.gatebox form { display: grid; gap: 10px; margin-top: 14px; }
.gatebox input { padding: 11px 12px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.15); background: rgba(0,0,0,0.3); color: inherit; font-size: 15px; }
.gatebox button { padding: 11px; border-radius: 10px; border: 0; background: #d4af37; color: #111; font-weight: 600; font-size: 15px; cursor: pointer; }
.gatebox .err { color: #ff8a80; }
@media (max-width: 700px) { .top { flex-wrap: wrap; gap: 10px; } .nav { order: 3; width: 100%; } }
@media (max-width: 760px) {
  .detail { padding: 8px; place-items: stretch; }
  .detail .sheet { grid-template-columns: minmax(0, 1fr); width: 100%; max-height: calc(100vh - 16px); overflow: auto; padding: 12px; gap: 12px; }
  .player.frames { overflow: visible; padding: 0; }
  .player.frames img { max-height: 42vh; object-fit: contain; background: #000; }
  .info { min-width: 0; }
  .pane pre { white-space: pre-wrap; word-break: break-word; }
}

.watermark { position: fixed; inset: -50%; z-index: 50; pointer-events: none; user-select: none; color: rgba(255,255,255,0.045);
  font-size: 15px; line-height: 90px; word-spacing: 30px; transform: rotate(-24deg); overflow: hidden; white-space: normal; }
.brand small a { color: inherit; }
.gatebox .small, .small { font-size: 12px; opacity: 0.65; }
.gatebox a { color: #d4af37; }

.slidegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.slidegrid figure { margin: 0; }
.slidegrid img { width: 100%; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 8px; background: #000; display: block; }
.slidegrid figcaption { font-size: 12px; color: var(--muted); margin-top: 4px; }

/* ---------- EM brand (Emil 2026-11-22: black and gold, EM Hub, course part EM Systems) ---------- */
:root {
  --bg: #080807;
  --panel: #100f0d;
  --panel-2: #181613;
  --line: #2a261f;
  --text: #f2ede3;
  --muted: #9b9285;
  --accent: #d6b66c;
  --gold: linear-gradient(135deg, #f6e7b8 0%, #d6b66c 38%, #9c7a3c 68%, #ead28f 100%);
  --gold-line: rgba(214, 182, 108, 0.28);
  --serif: "Cormorant Garamond", Georgia, serif;
}
html, body { font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
body { background: radial-gradient(1200px 500px at 50% -180px, rgba(214, 182, 108, 0.09), transparent 70%), var(--bg); background-attachment: fixed; }
::selection { background: rgba(214, 182, 108, 0.35); }

.top { background: rgba(8, 8, 7, 0.82); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--gold-line); }
.brand .logo { width: 38px; height: 38px; object-fit: contain; filter: drop-shadow(0 0 10px rgba(214, 182, 108, 0.25)); }
.brand b { font-family: var(--serif); font-size: 22px; font-weight: 700; letter-spacing: 0.06em; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand small { letter-spacing: 0.02em; }
.nav a { opacity: 0.7; transition: opacity .15s, background .15s; }
.nav a:hover { opacity: 1; }
.nav a.on { background: rgba(214, 182, 108, 0.1); color: var(--gold-light); box-shadow: inset 0 0 0 1px var(--gold-line); opacity: 1; }
#search { background: var(--panel); border-color: var(--line); }
#search:focus, .filters input:focus { outline: none; border-color: var(--accent); }

h1, .doc h1, .doc h2 { font-family: var(--serif); font-weight: 700; letter-spacing: 0.01em; }
main > section > h1, .doc h1 { font-size: 34px; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.doc h2 { font-size: 26px; color: var(--gold-light); }
.doc a, .meta a { color: var(--accent); }

.tabs, .select, .ghost { background: var(--panel); border-color: var(--line); }
.tabs button.on { background: rgba(214, 182, 108, 0.12); color: var(--gold-light); }
.ghost:hover { border-color: var(--gold-line); }
#filterCount:not(:empty) { background: var(--gold); }

.card { border-color: var(--line); transition: transform .15s, border-color .15s, box-shadow .15s; }
.card:hover { border-color: var(--accent); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(214, 182, 108, 0.25); transform: translateY(-2px); }
.pill.gold, .card .x { color: var(--gold-light); }
.detail .sheet { border-color: var(--gold-line); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7); }

/* EM Systems (the course) */
.modules { max-width: 820px; gap: 22px; }
.module { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; }
.module h2 { font-family: var(--serif); font-size: 22px; color: var(--gold-light); display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.module h2 .summary { margin: 0; font-family: "Inter", sans-serif; }
.lesson-row { background: var(--panel-2); border: 1px solid transparent; }
.lesson-row:hover { background: #1f1c17; border-color: var(--gold-line); }
.lesson-row .tick { border-color: rgba(214, 182, 108, 0.45); }
.lesson-row.done .tick { background: var(--gold); border-color: transparent; color: #1a1408; }
.lesson-video { border: 1px solid var(--gold-line); max-width: 900px; }

/* Login, invite and waiting pages */
body.gate { background: radial-gradient(700px 420px at 50% 30%, rgba(214, 182, 108, 0.12), transparent 70%), var(--bg); }
.gatebox { background: rgba(16, 15, 13, 0.85); border: 1px solid var(--gold-line); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); padding: 32px 30px; }
.gatebox .brand { flex-direction: column; gap: 8px; margin-bottom: 22px; text-align: center; }
.gatebox .brand .logo { width: 96px; height: 96px; }
.gatebox .brand b { font-size: 30px; }
.gatebox h1 { font-family: var(--serif); font-size: 26px; text-align: center; color: var(--gold-light); }
.gatebox input { border-color: var(--line); background: #0c0b0a; }
.gatebox input:focus { outline: none; border-color: var(--accent); }
.gatebox button { background: var(--gold); color: #1a1408; letter-spacing: 0.02em; transition: filter .15s; }
.gatebox button:hover { filter: brightness(1.08); }
.gatebox a { color: var(--accent); }

/* ---------- design pass 2 (Emil 2026-11-22): home, EM Systems, lesson page, Start here ---------- */
main { max-width: 1320px; margin: 0 auto; }
.eyebrow { text-transform: uppercase; letter-spacing: 0.14em; font-size: 11px; color: var(--accent); margin: 0 0 6px; font-weight: 600; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.grow { flex: 1; min-width: 0; }
.panel { background: linear-gradient(180deg, rgba(214, 182, 108, 0.05), transparent 60%), var(--panel); border: 1px solid var(--line); border-radius: 16px; }
.btn-gold { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 18px; border-radius: 10px; border: 0; background: var(--gold); color: #1a1408; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; transition: filter .15s; }
.btn-gold:hover { filter: brightness(1.08); }
.btn-done { padding: 10px 18px; border-radius: 10px; border: 1px solid var(--gold-line); background: rgba(214, 182, 108, 0.1); color: var(--gold-light); font-weight: 600; cursor: pointer; }
.bar-progress { height: 6px; border-radius: 99px; background: #24201a; overflow: hidden; margin: 10px 0 6px; }
.bar-progress span { display: block; height: 100%; background: var(--gold); border-radius: 99px; width: 0; transition: width .4s; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 34px 0 12px; }
.section-head h2 { font-family: var(--serif); font-size: 26px; margin: 0; color: var(--gold-light); }
.section-head a { color: var(--accent); text-decoration: none; font-size: 13px; }

/* Home */
.home .hero { display: flex; align-items: center; gap: 26px; padding: 28px 4px 22px; }
.hero-logo { width: 110px; height: 110px; object-fit: contain; filter: drop-shadow(0 0 24px rgba(214, 182, 108, 0.35)); flex: none; }
.hero-logo.small { width: 72px; height: 72px; }
.home .hero h1 { font-size: 44px; margin: 0 0 6px; }
.lead { color: var(--muted); font-size: 15px; max-width: 620px; margin: 0; line-height: 1.6; }
.home-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; }
.home-grid .panel { padding: 22px 24px; text-decoration: none; color: var(--text); display: flex; flex-direction: column; gap: 4px; transition: border-color .15s, transform .15s; }
.home-grid .panel:hover { border-color: var(--gold-line); transform: translateY(-2px); }
.home-grid .panel b { font-family: var(--serif); font-size: 26px; font-weight: 700; }
.grid.strip { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* EM Systems */
.course .course-head { display: flex; align-items: center; gap: 22px; padding: 24px 26px; margin: 8px 0 22px; }
.course .course-head h1 { margin: 0 0 4px; }
.course .modules { max-width: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.module-head { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.module-head h2 { margin: 0 0 2px; font-size: 21px; }
.module-n { font-family: var(--serif); font-size: 34px; font-weight: 700; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; min-width: 44px; }
.ring { --p: 0; width: 46px; height: 46px; border-radius: 50%; flex: none; display: grid; place-items: center; background: conic-gradient(var(--accent) calc(var(--p) * 1%), #24201a 0); }
.ring span { width: 36px; height: 36px; border-radius: 50%; background: var(--panel); display: grid; place-items: center; font-size: 10px; color: var(--muted); }
.lesson-row { gap: 12px; }
.lesson-row.next { border-color: var(--gold-line); background: rgba(214, 182, 108, 0.07); }
.lesson-row .pill.gold { background: rgba(214, 182, 108, 0.14); border-radius: 6px; padding: 1px 8px; font-size: 11px; }

/* Lesson */
.lesson-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 26px; align-items: start; }
.lesson-main h1 { margin: 0 0 14px; font-size: 34px; }
.lesson-main .back { color: var(--muted); text-decoration: none; font-size: 13px; display: inline-block; margin: 4px 0 14px; }
.lesson-main .back:hover { color: var(--accent); }
.lesson-video { max-width: none; margin: 0 0 14px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55); }
.lesson-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 18px; }
.notes { max-width: 820px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 6px 24px 16px; }
.notes h2 { font-size: 22px; }
.lesson-side { position: sticky; top: 76px; max-height: calc(100vh - 96px); overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.side-module { margin-top: 14px; }
.side-module > b { display: block; font-family: var(--serif); font-size: 16px; color: var(--gold-light); margin-bottom: 4px; }
.side-row { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 8px; color: var(--muted); text-decoration: none; font-size: 13px; }
.side-row:hover { background: var(--panel-2); color: var(--text); }
.side-row.on { background: rgba(214, 182, 108, 0.12); color: var(--gold-light); }
.side-row .tick { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid rgba(214, 182, 108, 0.45); display: grid; place-items: center; font-size: 10px; flex: none; }
.side-row.done .tick { background: var(--gold); border-color: transparent; color: #1a1408; }

/* Start here */
.guide { max-width: 980px; margin: 0 auto; }
.guide-inner { max-width: 760px; margin: 0 auto; }
.guide h1 { font-size: 46px; }
.guide h2 { border-top: 1px solid var(--gold-line); padding-top: 26px; margin-top: 36px; }
.rule-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 14px 0 8px; }
.rule { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 18px 18px 14px 64px; font-size: 14px; line-height: 1.6; }
.rule:hover { border-color: var(--gold-line); }
.rule h3 { font-family: var(--serif); font-size: 20px; margin: 0 0 6px; color: var(--gold-light); }
.rule p { margin: 6px 0; }
.rule-n { position: absolute; left: 18px; top: 12px; font-family: var(--serif); font-size: 38px; font-weight: 700; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; }

@media (max-width: 1100px) {
  .grid.strip { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lesson-layout { grid-template-columns: minmax(0, 1fr); }
  .lesson-side { position: static; max-height: none; }
}
@media (max-width: 760px) {
  .home-grid, .course .modules, .rule-grid { grid-template-columns: minmax(0, 1fr); }
  .grid.strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home .hero { flex-direction: column; align-items: flex-start; }
  .course .course-head { flex-wrap: wrap; }
}
.course .course-head h1 { font-size: 38px; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.rule-n, .module-n { font-variant-numeric: lining-nums; }

/* ---------- MemberSpot style course (Emil 2026-11-22): playlist right, lessons unlock in order ---------- */
.lesson-layout { grid-template-columns: minmax(0, 1fr) 380px; }
.crumbs { font-size: 13px; color: var(--muted); margin: 6px 0 14px; display: flex; gap: 8px; flex-wrap: wrap; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--accent); }
.crumbs span { color: var(--text); }
.lesson-main h1 { margin: 6px 0 12px; font-size: 32px; }
.btn-gold:disabled { filter: grayscale(0.8) brightness(0.6); cursor: not-allowed; }
.btn-done:disabled { cursor: default; }
.lesson-side { position: sticky; top: 76px; max-height: calc(100vh - 96px); overflow: auto; background: none; border: 0; padding: 0; display: grid; gap: 14px; }
.side-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.side-head { display: flex; align-items: center; gap: 10px; }
.side-head b { flex: 1; font-family: var(--serif); font-size: 18px; color: var(--gold-light); }
.count { font-size: 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 99px; padding: 2px 9px; color: var(--muted); }
.side-row { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 10px; margin: 0 -6px; }
.side-row.on { background: rgba(214, 182, 108, 0.1); box-shadow: inset 3px 0 0 var(--accent); color: var(--gold-light); }
.side-row.locked { opacity: 0.45; cursor: not-allowed; }
.side-row .dot { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid rgba(214, 182, 108, 0.45); display: grid; place-items: center; font-size: 10px; flex: none; }
.side-row.on .dot { background: var(--accent); box-shadow: 0 0 0 3px rgba(214, 182, 108, 0.25); border-color: transparent; }
.side-row.done .dot { background: var(--gold); border-color: transparent; color: #1a1408; }
.side-row.locked .dot { border: 0; font-size: 11px; }
.thumbwrap { position: relative; width: 86px; flex: none; }
.thumbwrap img { width: 86px; height: 49px; object-fit: cover; border-radius: 6px; display: block; background: #000; }
.thumbwrap em { position: absolute; right: 4px; bottom: 3px; font-style: normal; font-size: 10px; background: rgba(0, 0, 0, 0.75); padding: 0 4px; border-radius: 3px; color: #fff; }
.next-section { display: block; text-align: center; margin: 10px -16px -16px; padding: 12px; border-top: 1px solid var(--line); color: var(--accent); text-decoration: none; font-weight: 600; border-radius: 0 0 14px 14px; }
.next-section:hover { background: rgba(214, 182, 108, 0.08); }
.next-section.off { color: var(--muted); font-weight: 400; font-size: 12px; }
.breakdown { font-size: 13.5px; line-height: 1.6; }
.breakdown h2 { font-family: var(--serif); font-size: 18px; color: var(--gold-light); margin: 14px 0 4px; border: 0; padding: 0; }
.breakdown ul, .breakdown ol { padding-left: 18px; margin: 4px 0; }
.breakdown li { margin: 4px 0; }
.locked-box { text-align: center; padding: 70px 20px; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; }
.lock-big { font-size: 40px; display: block; margin-bottom: 8px; }
.locked-box p { max-width: 420px; margin: 8px auto 18px; }

/* overview: modules pull down */
details.module > summary { list-style: none; cursor: pointer; }
details.module > summary::-webkit-details-marker { display: none; }
details.module .chev { color: var(--muted); font-size: 18px; transition: transform .2s; }
details.module[open] .chev { transform: rotate(180deg); }
details.module:not([open]) .module-head { margin-bottom: 0; }
details.module.locked { opacity: 0.6; }
.lesson-row .lthumb { width: 64px; height: 36px; object-fit: cover; border-radius: 5px; flex: none; background: #000; }
.lesson-row.locked { opacity: 0.5; cursor: not-allowed; }
.course .modules { grid-template-columns: minmax(0, 1fr); max-width: 980px; }
@media (max-width: 1100px) { .lesson-layout { grid-template-columns: minmax(0, 1fr); } .lesson-side { position: static; max-height: none; } }

/* ---------- Feeds (Emil 2026-11-23): one swipe feed per content category, like a for you page ---------- */
.feeds { padding: 0; }
.feed-chips { display: flex; gap: 8px; overflow-x: auto; padding: 0 0 12px; scrollbar-width: none; }
.feed-chips::-webkit-scrollbar { display: none; }
.feed-chips button { flex: none; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; cursor: pointer; color: var(--muted); white-space: nowrap; }
.feed-chips button b { color: var(--text); font-weight: 600; margin-right: 6px; }
.feed-chips button.on { border-color: var(--accent); background: rgba(214, 182, 108, 0.12); color: var(--gold-light); }
.feed-chips button.on b { color: var(--gold-light); }
.feed-chips button.empty { opacity: .45; }
.feed { height: 70vh; overflow-y: auto; scroll-snap-type: y mandatory; overscroll-behavior: contain; scrollbar-width: none; outline: none; }
.feed::-webkit-scrollbar { display: none; }
.slide { height: 100%; scroll-snap-align: start; scroll-snap-stop: always; display: flex; justify-content: center; padding: 0 0 10px; }
.stage { position: relative; height: 100%; aspect-ratio: 9 / 16; max-width: 100%; background: #000; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); }
.stage video, .stage > img { width: 100%; height: 100%; object-fit: cover; display: block; background: #000; }
.stage .slides-row { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.stage .slides-row::-webkit-scrollbar { display: none; }
.stage .slides-row img { flex: none; width: 100%; height: 100%; object-fit: contain; scroll-snap-align: center; background: #000; }
.stage .shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to bottom, rgba(0,0,0,.45), transparent 18%, transparent 60%, rgba(0,0,0,.82)); }
.stage .who { position: absolute; left: 14px; right: 74px; bottom: 14px; display: flex; flex-direction: column; gap: 5px; pointer-events: none; }
.stage .who b { font-size: 15px; }
.stage .who .line { display: flex; flex-wrap: wrap; gap: 10px; font-size: 12px; color: #ddd6c8; }
.stage .who .x { color: var(--gold-light); font-weight: 700; }
.stage .top-l { position: absolute; top: 12px; left: 12px; display: flex; gap: 6px; font-size: 11px; }
.stage .count { position: absolute; top: 12px; right: 12px; font-size: 11px; }
.rail { position: absolute; right: 10px; bottom: 14px; display: flex; flex-direction: column; gap: 12px; align-items: center; }
.rail button, .rail a { width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255,255,255,.14); background: rgba(0,0,0,.5); color: #fff; font-size: 19px; display: grid; place-items: center; cursor: pointer; text-decoration: none; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.rail button:hover, .rail a:hover { border-color: var(--accent); }
.rail .on.up { background: rgba(127, 209, 139, .25); border-color: #7fd18b; }
.rail .on.down { background: rgba(224, 83, 74, .25); border-color: var(--warn); }
.rail small { display: block; font-size: 9px; color: #ddd6c8; margin-top: -8px; }
.stage .tap { position: absolute; inset: 0 70px 90px 0; background: none; border: 0; cursor: pointer; }
.stage .paused-icon { position: absolute; inset: 0; display: grid; place-items: center; font-size: 58px; color: rgba(255,255,255,.8); pointer-events: none; }
.slide.gone .stage { opacity: .35; }
.feed .end { height: 100%; scroll-snap-align: start; display: grid; place-items: center; color: var(--muted); text-align: center; padding: 20px; }
@media (max-width: 760px) {
  .stage { border-radius: 0; border: 0; width: 100%; aspect-ratio: auto; }
  .slide { padding: 0; }
  main:has(> .feeds:not([hidden])) { padding: 10px 0 0; }
  .feed-chips { padding: 0 12px 10px; }
}

/* Playing reels in the hub (2026-11-23): hover previews on cards, the player and slideshow viewer in the detail sheet. */
.card .hovervideo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.card .pill.kind { opacity: .9; }
.card .hovercount { position: absolute; top: 34px; left: 9px; font-size: 11px; }
.player.frames video { width: 100%; aspect-ratio: 9 / 16; max-height: 72vh; object-fit: contain; background: #000; border-radius: 8px; }
.player.frames .open.small { font-size: 12px; color: var(--muted); text-align: center; text-decoration: none; }
.player.frames .open.small:hover { color: var(--accent); }
.gallery { position: relative; }
.player.frames .gallery img { aspect-ratio: 9 / 16; max-height: 72vh; object-fit: contain; background: #000; }
.gallery .gnav { position: absolute; top: 50%; transform: translateY(-50%); width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .55); color: #fff; font-size: 24px; line-height: 1; cursor: pointer; }
.gallery .gnav.prev { left: 8px; }
.gallery .gnav.next { right: 8px; }
.gallery .gnav:hover { background: rgba(0, 0, 0, .8); }
.gallery .gcount { position: absolute; top: 10px; right: 10px; }
.gthumbs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; }
.player.frames .gthumbs img { flex: none; width: 52px; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 6px; opacity: .55; cursor: pointer; }
.player.frames .gthumbs img.on { opacity: 1; outline: 2px solid var(--accent); }
button.sound { position: absolute; width: 34px; height: 34px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .6); color: #fff; font-size: 16px; line-height: 1; cursor: pointer; z-index: 3; }
button.sound:hover { background: rgba(0, 0, 0, .85); }
.card .hoversound { bottom: 64px; right: 9px; }
.dwrap { position: relative; }
.dwrap .sound { top: 10px; right: 10px; }

/* Written lessons (no video): the text sits in the main column. */
.lesson-text { max-width: 760px; margin-top: 18px; font-size: 15px; line-height: 1.7; }
.lesson-text h2 { font-size: 21px; margin-top: 22px; }
.lesson-text a { color: #e6c77e; text-decoration: underline; }

/* Clipping tool */
.clip-head { max-width: 760px; margin-bottom: 16px; }
.clip-form { padding: 18px; display: grid; gap: 14px; max-width: 860px; }
.clip-file { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border: 1px dashed var(--line); border-radius: 12px; cursor: pointer; }
.clip-file > span:last-child { display: grid; gap: 4px; min-width: 0; }
.clip-file .step { width: 26px; height: 26px; border-radius: 50%; background: var(--panel-2); border: 1px solid var(--line); display: grid; place-items: center; color: var(--accent); font-weight: 600; flex: none; }
.clip-file input { margin-top: 6px; max-width: 100%; }
.clip-file .files { font-size: 12px; color: var(--accent); overflow-wrap: anywhere; }
.clip-opts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.clip-opts.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.clip-opts label { display: grid; gap: 6px; color: var(--muted); font-size: 12px; }
.clip-form input:not([type=file]):not([type=checkbox]), .clip-form select, .clip-form textarea { background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; color: var(--text); font: inherit; width: 100%; }
.clip-form textarea { resize: vertical; }
.consent { display: flex; gap: 8px; align-items: flex-start; }
.clip-go { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.clip-bar { height: 6px; background: var(--panel-2); border-radius: 3px; overflow: hidden; }
.clip-bar span { display: block; height: 100%; width: 0; background: var(--gold, var(--accent)); transition: width .3s; }
.clip-err { color: var(--warn); }
.clip-jobs { display: grid; gap: 12px; max-width: 860px; }
.clip-job { padding: 14px 16px; }
.clip-job header { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: baseline; }
.clip-job header b { overflow-wrap: anywhere; }
.clip-job .link { margin-left: auto; background: none; border: 0; color: var(--muted); cursor: pointer; text-decoration: underline; }
.chip { font-size: 11px; padding: 2px 8px; border-radius: 99px; border: 1px solid var(--line); color: var(--muted); }
.chip.s-done { color: #1a1408; background: var(--gold, var(--accent)); border-color: transparent; }
.chip.s-running, .chip.s-queued, .chip.s-uploading { color: var(--accent); border-color: var(--accent); }
.chip.s-failed { color: var(--warn); border-color: var(--warn); }
.clip-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 12px 0; }
.btn-ghost { padding: 9px 14px; border-radius: 10px; border: 1px solid var(--line); color: var(--text); text-decoration: none; }
.clip-sheet { width: 100%; border-radius: 10px; border: 1px solid var(--line); display: block; }
.clip-versions { margin: 12px 0 0; padding-left: 0; list-style: none; display: grid; gap: 6px; }
.clip-versions li { display: grid; grid-template-columns: 80px 1fr auto; gap: 10px; align-items: baseline; padding: 6px 0; border-top: 1px solid var(--line); }
.clip-versions a { color: var(--accent); }
.clip-note { max-width: 760px; font-size: 12px; margin-top: 14px; }
@media (max-width: 720px) {
  .clip-opts, .clip-opts.two { grid-template-columns: 1fr 1fr; }
  .clip-versions li { grid-template-columns: 64px 1fr; }
  .clip-versions li span.muted { grid-column: 2; }
}
.clip-ai { display: grid; gap: 12px; padding: 14px; border: 1px dashed var(--line); border-radius: 12px; }
.clip-ai-head { display: flex; gap: 12px; align-items: flex-start; }
.clip-ai-head > span:last-child { display: grid; gap: 4px; }
.clip-ai-head .step { width: 26px; height: 26px; border-radius: 50%; background: var(--panel-2); border: 1px solid var(--line); display: grid; place-items: center; color: var(--accent); font-weight: 600; flex: none; }
.clip-hf { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.clip-hf .link { background: none; border: 0; color: var(--muted); cursor: pointer; text-decoration: underline; }
.clip-hf-form { flex-basis: 100%; display: grid; gap: 10px; }
.clip-hf-form a { color: var(--accent); }
/* Clipping page guide */
.clip-guide { max-width: 860px; margin-bottom: 16px; padding: 0; }
.clip-guide > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 14px 18px; }
.clip-guide > summary::-webkit-details-marker { display: none; }
.clip-guide > summary > span:first-child { display: grid; gap: 2px; flex: 1; }
.clip-guide > summary .muted { font-size: 12px; }
.clip-guide .chev { color: var(--muted); font-size: 18px; transition: transform .2s; }
.clip-guide[open] .chev { transform: rotate(180deg); }
.clip-guide-body { padding: 0 18px 16px; border-top: 1px solid var(--line); }
.clip-guide-body h3 { font-size: 14px; margin: 16px 0 6px; color: var(--accent); }
.clip-guide-body ul { margin: 0; padding-left: 18px; display: grid; gap: 6px; }
.clip-guide-body li { font-size: 13px; line-height: 1.5; }
.clip-guide-body a { color: var(--accent); }

/* ---------- design pass 3 (Emil 2026-11-26): the EM CRM look. Left sidebar, framed workspace, sans headings ---------- */
:root {
  --bg: #0a0a0a;
  --panel: #141311;
  --panel-2: #1a1815;
  --line: #2a2620;
  --line-soft: #1f1d1a;
  --text: #f5f1e8;
  --muted: #a8a095;
  --dim: #9a9284;
  --accent: #bfa970;
  --gold-light: #e0d0a8;
  --gold: linear-gradient(135deg, #e0d0a8 0%, #bfa970 50%, #988058 100%);
  --gold-line: rgba(191, 169, 112, 0.22);
  --serif: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
  --frame-line: rgba(224, 208, 168, 0.11);
  --card-bg: linear-gradient(145deg, rgba(25, 23, 20, 0.84), rgba(12, 12, 11, 0.82));
  --card-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 24px 70px -46px rgba(0, 0, 0, 0.95);
  --side-w: 272px;
}
html, body { font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif; -webkit-font-smoothing: antialiased; }
body {
  background:
    radial-gradient(circle at 8% -8%, rgba(191, 169, 112, 0.16), transparent 34rem),
    radial-gradient(circle at 92% 108%, rgba(152, 128, 88, 0.1), transparent 36rem),
    linear-gradient(180deg, #090908 0%, #070706 100%);
  background-attachment: fixed;
}
::selection { background: rgba(191, 169, 112, 0.3); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #0a0a0a; }
::-webkit-scrollbar-thumb { background: rgba(191, 169, 112, 0.2); border-radius: 5px; border: 2px solid #0a0a0a; }
::-webkit-scrollbar-thumb:hover { background: rgba(191, 169, 112, 0.35); }

/* Shell: the framed workspace with the sidebar on the left */
.shell { display: flex; align-items: flex-start; min-height: 100vh; }
.col { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }
@media (min-width: 1025px) {
  body { padding: 24px; }
  .shell { min-height: calc(100vh - 48px); max-width: 1760px; margin: 0 auto; border: 1px solid var(--frame-line); border-radius: 28px;
    background: radial-gradient(circle at 0% 0%, rgba(191, 169, 112, 0.075), transparent 24rem), linear-gradient(145deg, rgba(18, 17, 15, 0.94), rgba(10, 10, 9, 0.97));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 30px 100px rgba(0, 0, 0, 0.42); }
  .col { min-height: calc(100vh - 48px); }
}

.side { width: var(--side-w); flex: none; position: sticky; top: 40px; margin: 16px 0 16px 16px; height: calc(100vh - 80px); display: flex; flex-direction: column;
  border: 1px solid var(--frame-line); border-radius: 23px;
  background: radial-gradient(circle at 45% 0%, rgba(191, 169, 112, 0.11), transparent 17rem), linear-gradient(180deg, rgba(25, 24, 21, 0.94), rgba(13, 13, 12, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 16px 0 56px -34px rgba(0, 0, 0, 0.9); z-index: 20; }
.side-brand { display: flex; align-items: center; gap: 12px; padding: 24px 20px 26px; }
.side-brand b { display: block; font-size: 14px; font-weight: 600; letter-spacing: 0.02em; color: var(--text); }
.side-brand small { display: block; margin-top: 2px; font-size: 9px; text-transform: uppercase; letter-spacing: 0.24em; color: var(--dim); }
.em-tile { width: 36px; height: 36px; flex: none; display: grid; place-items: center; border-radius: 12px; border: 1px solid rgba(191, 169, 112, 0.2);
  background: linear-gradient(135deg, #e0d0a8, #bfa970 50%, #988058); color: #0a0a0a; font-size: 12px; font-weight: 700; box-shadow: 0 10px 28px -14px rgba(191, 169, 112, 0.75); }
.em-tile.small { width: 32px; height: 32px; border-radius: 10px; font-size: 11px; }
.em-tile.big { width: 64px; height: 64px; border-radius: 18px; font-size: 20px; }
.side .nav { display: flex; flex-direction: column; flex-wrap: nowrap; gap: 4px; padding: 0 12px 12px; flex: 1; min-height: 0; overflow-y: auto; }
.side .nav a, .side-foot a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; border: 1px solid transparent; color: var(--muted);
  font-size: 14px; text-decoration: none; opacity: 1; background: none; box-shadow: none; transition: color .2s, background .2s, border-color .2s; }
.side .nav a svg, .side-foot svg { width: 16px; height: 16px; stroke-width: 1.75; flex: none; }
.side .nav a:hover, .side-foot a:hover { color: var(--text); background: rgba(245, 241, 232, 0.025); border-color: rgba(191, 169, 112, 0.1); }
.side .nav a.on { color: var(--text); border-color: rgba(191, 169, 112, 0.2); background: linear-gradient(90deg, rgba(191, 169, 112, 0.15), rgba(255, 255, 255, 0.02));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025); }
.nav-label { margin: 0; padding: 20px 12px 4px; font-size: 10px; text-transform: uppercase; letter-spacing: 0.19em; color: var(--dim); }
.side-foot { border-top: 1px solid rgba(31, 29, 26, 0.8); padding: 12px; }
.side-shade, .menu-logo, .icon-btn.side-x, .icon-btn.menu-btn { display: none; }

/* Top bar: breadcrumb, search, member */
.top { position: sticky; top: 24px; z-index: 10; display: flex; align-items: center; gap: 24px; height: 96px; padding: 0 40px; margin: 0;
  border-bottom: 1px solid var(--line-soft); background: linear-gradient(180deg, rgba(14, 14, 13, 0.88), rgba(12, 12, 11, 0.72));
  backdrop-filter: blur(20px) saturate(120%); -webkit-backdrop-filter: blur(20px) saturate(120%); border-top-right-radius: 27px; }
.crumb { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 14px; }
.crumb a { color: var(--dim); display: grid; }
.crumb a:hover { color: var(--text); }
.crumb svg { width: 16px; height: 16px; stroke-width: 1.75; color: var(--dim); }
.crumb > svg { width: 14px; height: 14px; opacity: 0.7; }
.crumb b { font-weight: 500; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-search { margin-left: auto; display: flex; align-items: center; gap: 12px; height: 44px; width: min(28rem, 34vw); padding: 0 14px; border: 1px solid var(--line);
  border-radius: 14px; background: rgba(5, 5, 5, 0.34); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025); transition: border-color .18s, background .18s, box-shadow .18s; }
.top-search:focus-within { border-color: rgba(191, 169, 112, 0.5); background: rgba(10, 10, 9, 0.7); box-shadow: 0 0 0 3px rgba(191, 169, 112, 0.08); }
.top-search svg { width: 16px; height: 16px; color: var(--dim); flex: none; }
.top-search #search, #search:focus { margin: 0; width: auto; flex: 1; min-width: 0; background: none; border: 0; padding: 0; outline: none; font-size: 14px; color: var(--text); }
.top-search #search::placeholder { color: var(--dim); }
.top-search[hidden] + .me { margin-left: auto; }
.me { display: flex; align-items: center; gap: 12px; padding-left: 20px; border-left: 1px solid var(--line-soft); flex: none; }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 1px solid rgba(191, 169, 112, 0.2); background: rgba(191, 169, 112, 0.1);
  color: var(--gold-light); font-size: 12px; font-weight: 600; }
.me-txt { line-height: 1.2; }
.me-txt b { display: block; font-size: 14px; font-weight: 500; color: var(--text); }
.me-txt small { display: block; margin-top: 2px; font-size: 11px; color: var(--dim); }
.icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: rgba(245, 241, 232, 0.025); color: var(--text); cursor: pointer; flex: none; }
.icon-btn svg { width: 16px; height: 16px; stroke-width: 1.75; }

main { width: 100%; max-width: 1440px; margin: 0 auto; padding: 28px 40px 48px; }

/* Type: bold sans headlines like the CRM, gold small caps eyebrows */
h1, .doc h1, .doc h2, .module h2, .section-head h2, .home-grid .panel b, .side-module > b, .rule h3, .side-head b, .breakdown h2, .gatebox h1 {
  font-family: var(--serif); letter-spacing: -0.02em; }
main > section > h1, .doc h1, .course .course-head h1, .home .hero h1 { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: var(--text);
  font-weight: 700; letter-spacing: -0.035em; display: block; }
.home .hero h1 { font-size: 40px; }
main > section > h1, .doc h1, .course .course-head h1 { font-size: 34px; }
.eyebrow { font-size: 11px; letter-spacing: 0.18em; color: var(--gold-light); font-weight: 600; }
.section-head { margin: 32px 0 14px; }
.section-head h2 { font-size: 20px; font-weight: 600; color: var(--text); }
.doc h2 { font-size: 22px; font-weight: 600; color: var(--text); }
.module h2, .module-head h2 { font-size: 18px; font-weight: 600; color: var(--text); }
.home-grid .panel b { font-size: 22px; font-weight: 600; color: var(--text); }
.side-module > b, .side-head b, .rule h3, .breakdown h2 { color: var(--text); font-weight: 600; }
.module-n, .rule-n { font-family: var(--serif); letter-spacing: -0.04em; }
.lead { font-size: 14px; }
.hero-logo { width: 84px; height: 84px; }

/* Cards and controls: the CRM panel surface */
.panel, .module { background: var(--card-bg); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--card-shadow); }
.home-grid .panel:hover, .card:hover { border-color: rgba(191, 169, 112, 0.28); }
.card { border-radius: 16px; }
.lesson-row { border-radius: 12px; }
.btn-gold, .gatebox button { background: var(--gold); color: #0a0a0a; border-radius: 12px; font-weight: 500; box-shadow: 0 1px 0 rgba(255, 255, 255, 0.1) inset, 0 4px 16px -4px rgba(191, 169, 112, 0.4); }
.btn-gold:hover, .gatebox button:hover { filter: brightness(1.08); box-shadow: 0 1px 0 rgba(255, 255, 255, 0.15) inset, 0 6px 20px -4px rgba(191, 169, 112, 0.55); }
.btn-ghost, .ghost, .tabs, .select { border-radius: 12px; border-color: var(--line); background: rgba(255, 255, 255, 0.018); }
.tabs button { border-radius: 9px; }
.tabs button.on { background: rgba(245, 241, 232, 0.08); color: var(--text); }
.btn-done { border-radius: 12px; }

/* Login, invite and waiting pages */
body.gate { padding: 0; display: grid; place-items: center; min-height: 100vh; }
.gatebox { border-radius: 24px; border: 1px solid var(--frame-line); background: radial-gradient(circle at 0% 0%, rgba(191, 169, 112, 0.075), transparent 24rem), linear-gradient(145deg, rgba(18, 17, 15, 0.94), rgba(10, 10, 9, 0.97));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 30px 100px rgba(0, 0, 0, 0.42); }
.gatebox .brand b { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: var(--text); font-family: var(--serif); font-size: 20px; font-weight: 600; letter-spacing: 0.01em; }
.gatebox .brand small { font-size: 9px; text-transform: uppercase; letter-spacing: 0.24em; color: var(--dim); }
.gatebox h1 { color: var(--text); font-size: 22px; font-weight: 600; }
.gatebox input { border-radius: 12px; background: rgba(5, 5, 5, 0.34); }
.gatebox input:focus { border-color: rgba(191, 169, 112, 0.5); box-shadow: 0 0 0 3px rgba(191, 169, 112, 0.08); }

/* Laptops: the sidebar takes room, so dense grids step down sooner */
@media (max-width: 1440px) { .grid.strip { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 1280px) { .course .modules { grid-template-columns: minmax(0, 1fr); } }

/* Tablets and phones: top bar with a menu button, the sidebar slides in */
@media (max-width: 1024px) {
  .side { position: fixed; top: 0; left: 0; bottom: 0; margin: 0; height: 100vh; border-radius: 0 20px 20px 0; transform: translateX(-105%); transition: transform .22s ease; z-index: 40; }
  .side.open { transform: none; }
  .icon-btn.side-x { display: grid; margin-left: auto; }
  .side-shade:not([hidden]) { display: block; position: fixed; inset: 0; background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); z-index: 35; }
  .icon-btn.menu-btn, .menu-logo { display: grid; }
  .top { top: 0; height: auto; padding: max(12px, env(safe-area-inset-top)) 16px 12px; gap: 12px; border-radius: 0; background: rgba(10, 10, 10, 0.9); }
  .top-search { width: auto; flex: 1; margin-left: 8px; height: 40px; }
  .me-txt { display: none; }
  .me { padding-left: 0; border: 0; }
  main { padding: 20px 20px 40px; }
}
@media (max-width: 760px) {
  .crumb { display: none; }
  .top-search[hidden] + .me { margin-left: auto; }
  .avatar { width: 36px; height: 36px; }
  main { padding: 16px 16px 40px; }
  .home .hero h1 { font-size: 30px; }
  main > section > h1, .doc h1, .course .course-head h1 { font-size: 26px; }
  .grid.strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.h-tail { color: var(--muted); font-weight: 600; }
.detail { z-index: 45; }
.clip-head h1 { font-size: 34px; font-weight: 700; letter-spacing: -0.035em; color: var(--text); margin: 0 0 8px; }
@media (max-width: 760px) { .clip-head h1 { font-size: 26px; } }
/* Desktop: the page scrolls under a fixed strip above the frame, so nothing shows above the top bar */
@media (min-width: 1025px) {
  body:not(.gate)::before { content: ""; position: fixed; left: 0; right: 0; top: 0; height: 24px; z-index: 9; pointer-events: none;
    background: radial-gradient(circle at 8% -8%, rgba(191, 169, 112, 0.16), transparent 34rem), linear-gradient(180deg, #090908 0%, #070706 100%); background-attachment: fixed; }
  .lesson-side { top: 136px; max-height: calc(100vh - 160px); }
}
@media (max-width: 1024px) { .lesson-side { top: 80px; max-height: calc(100vh - 96px); } }
.clip-form { grid-template-columns: minmax(0, 1fr); }
.clip-file { min-width: 0; }
.clip-file input[type=file] { width: 100%; }
@media (max-width: 1024px) { .side .nav { order: 0; width: auto; } }
@media (max-width: 1024px) { .top { flex-wrap: nowrap; } .top-search { min-width: 0; } }

/* ---------- Students (owner only) ---------- */
.stu-tiles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin: 22px 0 12px; }
.stu-tile { padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.stu-tile b { font-size: 28px; font-weight: 650; letter-spacing: -0.02em; }
.stu-dist { padding: 18px 20px; margin-bottom: 18px; }
.stu-dist h2 { font-size: 14px; margin: 0 0 10px; font-weight: 600; }
.stu-band { display: grid; grid-template-columns: 92px 1fr 36px; align-items: center; gap: 12px; width: 100%; padding: 6px 8px; margin: 0 -8px; background: none;
  border: 0; border-radius: 10px; color: var(--muted); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.stu-band:hover, .stu-band.on { background: rgba(191, 169, 112, 0.08); color: var(--text); }
.stu-band b { text-align: right; color: var(--text); }
.stu-band-bar { height: 8px; border-radius: 99px; background: #24201a; overflow: hidden; }
.stu-band-bar i { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.stu-bar { display: flex; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.stu-search { flex: 1 1 240px; display: flex; align-items: center; gap: 8px; padding: 0 14px; height: 42px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.stu-search svg { width: 16px; height: 16px; stroke: var(--muted); fill: none; stroke-width: 1.75; flex: none; }
.stu-search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: var(--text); font: inherit; font-size: 14px; }
.stu-bar select { height: 42px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); color: var(--text); font: inherit; font-size: 14px; }
.stu-table { padding: 6px 0; overflow: hidden; }
.stu-row { display: grid; grid-template-columns: minmax(0, 2.2fr) minmax(0, 1.6fr) 70px minmax(0, 1fr) minmax(0, 1.3fr); gap: 16px; align-items: center; padding: 12px 20px; border-top: 1px solid var(--line); font-size: 14px; }
.stu-row:first-child { border-top: 0; }
.stu-headrow { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--dim); padding-top: 10px; padding-bottom: 10px; }
.stu-who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.stu-who > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.stu-who b, .stu-who .muted { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stu-who .avatar { flex: none; }
.stu-prog { display: flex; align-items: center; gap: 10px; }
.stu-prog .bar-progress { flex: 1; margin: 0; }
.stu-prog b { width: 40px; text-align: right; font-weight: 600; }
.stu-num, .stu-hubcell { display: flex; flex-direction: column; }
.stu-k { display: none; }
.stu-hub { font-weight: 600; color: var(--muted); }
.stu-hub.on { color: var(--gold-light); }
.stu-hub.none { font-weight: 400; color: var(--dim); }
.stu-count { padding: 10px 20px 4px; margin: 0; border-top: 1px solid var(--line); }
@media (max-width: 1100px) { .stu-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .stu-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stu-tile b { font-size: 22px; }
  .stu-bar select { flex: 1 1 140px; }
  .stu-headrow { display: none; }
  .stu-row { grid-template-columns: 1fr 1fr; gap: 10px 16px; padding: 14px 16px; }
  .stu-row > :first-child, .stu-row > :nth-child(2) { grid-column: 1 / -1; }
  .stu-k { display: block; font-size: 10px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--dim); margin-bottom: 2px; }
  .stu-count { padding: 10px 16px 4px; }
}

/* ---------- Courses: library and course page laid out like MemberSpot's member area ---------- */
.library, .course { max-width: 860px; }
.lib-banner { display: flex; align-items: center; gap: 22px; padding: 34px 32px; margin: 8px 0 26px; min-height: 150px;
  background: radial-gradient(120% 140% at 0% 0%, rgba(191, 169, 112, 0.18), transparent 55%), linear-gradient(180deg, rgba(191, 169, 112, 0.06), transparent), var(--panel); }
.lib-banner img { width: 76px; height: 76px; flex: none; }
.lib-banner h1 { margin: 0; font-size: 34px; letter-spacing: -0.02em; }
.lib-h { font-size: 17px; font-weight: 600; margin: 0 0 12px; }
.lib-continue { position: relative; display: block; width: min(100%, 340px); aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; border: 1px solid var(--line);
  margin-bottom: 28px; color: var(--text); text-decoration: none; background: #000; transition: border-color .15s, transform .15s; }
.lib-continue:hover { border-color: rgba(191, 169, 112, 0.45); transform: translateY(-1px); }
.lib-continue img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lib-shade { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(0, 0, 0, 0.85)); }
.lib-txt { position: absolute; left: 14px; right: 56px; bottom: 12px; display: flex; flex-direction: column; gap: 2px; }
.lib-txt b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-txt small { font-size: 11px; color: rgba(245, 241, 232, 0.75); }
.lib-play { position: absolute; right: 12px; bottom: 12px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 12px;
  background: var(--accent); color: #1a1408; }
.lib-courses { display: grid; gap: 12px; }
.lib-course { display: flex; align-items: center; gap: 20px; padding: 14px 18px 14px 14px; color: var(--text); text-decoration: none; transition: border-color .15s; }
.lib-course:hover { border-color: rgba(191, 169, 112, 0.35); }
.lib-art { position: relative; width: 168px; aspect-ratio: 16 / 10; border-radius: 10px; flex: none; display: grid; place-items: center;
  background: radial-gradient(100% 100% at 30% 20%, rgba(191, 169, 112, 0.25), transparent 70%), #16140f; border: 1px solid var(--line); }
.lib-art img { width: 58px; height: 58px; }
.lib-art .ring { position: absolute; right: 8px; bottom: 8px; width: 36px; height: 36px; }
.lib-art .ring span { width: 28px; height: 28px; font-size: 9px; }
.lib-course .grow { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.lib-course b { font-size: 16px; }
.lib-course .bar-progress { max-width: 260px; margin: 8px 0 2px; }
.lib-course .btn-ghost { flex: none; font-size: 14px; }
.course .crumbs { margin-top: 0; }
.course-card { display: flex; align-items: center; gap: 22px; padding: 24px 26px; margin-bottom: 14px; }
.course-card h1 { margin: 0 0 4px; font-size: 30px; letter-spacing: -0.02em; }
.course-card .bar-progress { max-width: 420px; }
.course-art { width: 150px; aspect-ratio: 16 / 10; border-radius: 12px; flex: none; display: grid; place-items: center;
  background: radial-gradient(100% 100% at 30% 20%, rgba(191, 169, 112, 0.25), transparent 70%), #16140f; border: 1px solid var(--line); }
.course-art img { width: 56px; height: 56px; }
.cont-strip { display: flex; align-items: center; gap: 16px; padding: 0 16px 0 0; margin-bottom: 22px; overflow: hidden; color: var(--text); text-decoration: none; transition: border-color .15s; }
.cont-strip:hover { border-color: rgba(191, 169, 112, 0.35); }
.cont-strip img { width: 128px; aspect-ratio: 16 / 9; object-fit: cover; flex: none; background: #000; }
.cont-strip .grow { display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 12px 0; }
.cont-strip .eyebrow { margin: 0; font-size: 10px; }
.cont-strip b { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cont-strip .btn-gold { flex: none; padding: 9px 16px; font-size: 14px; }
.mlist { padding: 8px; display: grid; gap: 2px; }
.mrow { border-radius: 12px; }
.mrow > summary { display: flex; align-items: center; gap: 16px; padding: 10px; border-radius: 12px; cursor: pointer; list-style: none; }
.mrow > summary::-webkit-details-marker { display: none; }
.mrow > summary:hover, .mrow[open] > summary { background: rgba(245, 241, 232, 0.03); }
.m-thumb { position: relative; width: 108px; aspect-ratio: 16 / 9; border-radius: 8px; overflow: hidden; flex: none; background: #000; border: 1px solid var(--line); }
.m-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.m-thumb i { position: absolute; inset: 0; z-index: 0; display: grid; place-items: center; background: rgba(10, 10, 10, 0.55); font-style: normal; font-size: 13px; font-weight: 700; color: #1a1408; }
.m-thumb i::before { content: ""; position: absolute; z-index: -1; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); }
.mrow .grow { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mrow .grow > b { font-size: 15px; font-weight: 600; }
.m-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--muted); }
.m-meta > span { display: inline-flex; align-items: center; gap: 5px; }
.m-meta .ico { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2; }
.m-ok { color: var(--gold-light); font-weight: 600; }
.mrow.locked > summary { opacity: 0.5; }
.mrow .chev { color: var(--muted); font-size: 18px; transition: transform .2s; padding: 0 6px; }
.mrow[open] .chev { transform: rotate(180deg); }
.m-lessons { padding: 2px 10px 12px 134px; }
.m-lessons .lesson-row { margin: 6px 0; }
.back-btn { display: inline-flex; margin: 18px 0 8px; padding: 9px 14px; border-radius: 10px; border: 1px solid var(--line); color: var(--muted); text-decoration: none; font-size: 13px; }
.back-btn:hover { color: var(--text); border-color: rgba(191, 169, 112, 0.35); }
@media (max-width: 760px) {
  .lib-banner { padding: 24px 20px; min-height: 0; gap: 16px; }
  .lib-banner img { width: 54px; height: 54px; }
  .lib-banner h1 { font-size: 26px; }
  .lib-course { flex-wrap: wrap; gap: 14px; padding: 12px; }
  .lib-art { width: 100%; aspect-ratio: 16 / 7; }
  .lib-course .btn-ghost { width: 100%; text-align: center; }
  .course-card { padding: 18px; }
  .course-card h1 { font-size: 24px; }
  .course-art { display: none; }
  .cont-strip { flex-wrap: wrap; padding: 0; }
  .cont-strip img { width: 100%; }
  .cont-strip .grow { padding: 0 16px; }
  .cont-strip .btn-gold { margin: 0 16px 16px; width: calc(100% - 32px); }
  .m-thumb { width: 80px; }
  .mrow > summary { gap: 12px; padding: 8px; }
  .m-lessons { padding: 2px 4px 10px; }
}

/* Back button in the top bar, on every page */
.icon-btn.top-back { width: 36px; height: 36px; border-radius: 10px; color: var(--muted); margin-right: -10px; }
.icon-btn.top-back:hover { color: var(--text); border-color: rgba(191, 169, 112, 0.35); }
@media (max-width: 1024px) { .icon-btn.top-back { margin-right: 0; } }

/* ---------- Students: EM Hub members and member detail ---------- */
.stu-tabs { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); margin: 18px 0 10px; }
.stu-tabs button { border: 0; background: none; color: var(--muted); font: inherit; font-size: 14px; padding: 8px 14px; border-radius: 9px; cursor: pointer; }
.stu-tabs button.on { color: var(--text); background: linear-gradient(90deg, rgba(191, 169, 112, 0.18), rgba(255, 255, 255, 0.02)); }
.stu-bar .btn-gold { height: 42px; }
.stu-approvals { padding: 16px 20px; margin-bottom: 16px; border-color: rgba(191, 169, 112, 0.4); }
.stu-approvals h2, .stu-invite h2, .mem-chart h2, .mem-course h2, .mem-logs h2 { font-size: 15px; font-weight: 600; margin: 0 0 10px; }
.stu-appr { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 10px 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.stu-appr > span:first-child { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.stu-appr-btns { display: flex; gap: 8px; }
.stu-appr-btns button { padding: 8px 14px; font-size: 13px; cursor: pointer; font: inherit; }
.stu-invite { padding: 18px 20px; margin-bottom: 14px; }
.stu-invite-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.stu-invite-row input { flex: 1 1 200px; height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; background: rgba(0, 0, 0, 0.25); color: var(--text); font: inherit; font-size: 14px; }
.stu-invite-row .btn-gold { height: 42px; }
.stu-linkbox { margin-top: 14px; }
#memMsg .stu-linkbox { padding: 16px 20px; margin: 0 0 14px; }
.stu-link { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.stu-link code { flex: 1 1 260px; min-width: 0; padding: 10px 12px; border-radius: 10px; background: rgba(0, 0, 0, 0.35); border: 1px solid var(--line); font-size: 13px; overflow-wrap: anywhere; color: var(--gold-light); }
.stu-link .btn-ghost { cursor: pointer; font: inherit; font-size: 13px; }
.stu-err { color: #e8a598; margin: 0; }
.hub-row { grid-template-columns: minmax(0, 2.1fr) minmax(0, 1.5fr) 80px 100px minmax(0, 1fr) 130px; color: var(--text); text-decoration: none; }
a.hub-row:hover { background: rgba(245, 241, 232, 0.025); }
.stu-pill { display: inline-block; padding: 3px 10px; border-radius: 99px; font-size: 12px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.stu-pill.on { color: var(--gold-light); border-color: rgba(191, 169, 112, 0.35); }
.stu-pill.wait { color: #1a1408; background: var(--accent); border-color: transparent; }
.stu-pill.off { color: #e8a598; border-color: rgba(232, 165, 152, 0.35); }
.back-btn.back-up { margin: 0 0 14px; }
.mem-head { display: flex; align-items: center; gap: 18px; padding: 22px 24px; margin-bottom: 14px; flex-wrap: wrap; }
.mem-head .grow { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-width: 0; }
.mem-head h1 { margin: 0; font-size: 26px; }
.avatar.big { width: 56px; height: 56px; font-size: 18px; }
.mem-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.mem-actions button { cursor: pointer; font: inherit; font-size: 13px; }
.btn-ghost.danger { color: #e8a598; border-color: rgba(232, 165, 152, 0.35); }
.mem-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px 20px; padding: 18px 22px; margin-bottom: 14px; }
.mem-facts > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.mem-facts b { font-size: 14px; font-weight: 600; overflow-wrap: anywhere; }
.stu-k.on { display: block; font-size: 10px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--dim); }
.mem-chart, .mem-course, .mem-logs { padding: 18px 22px; margin-bottom: 14px; }
.mem-bars { display: flex; align-items: flex-end; gap: 2px; height: 120px; border-bottom: 1px solid var(--line); }
.mem-bar { position: relative; flex: 1; height: 100%; display: flex; align-items: flex-end; cursor: default; }
.mem-bar i { display: block; width: 100%; background: var(--accent); border-radius: 4px 4px 0 0; }
.mem-bar:hover i { background: var(--gold-light); }
.mem-bar:hover::after { content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); white-space: nowrap; z-index: 3;
  padding: 6px 10px; border-radius: 8px; background: #1d1a15; border: 1px solid var(--line); color: var(--text); font-size: 12px; pointer-events: none; }
.mem-bar:first-child:hover::after { left: 0; transform: none; }
.mem-bar:last-child:hover::after { left: auto; right: 0; transform: none; }
.mem-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--dim); margin-top: 6px; }
.mem-mod { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--accent); margin: 14px 0 4px; }
.mem-mod:first-of-type { margin-top: 0; }
.mem-lesson { display: grid; grid-template-columns: minmax(0, 1fr) 180px 130px; gap: 14px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14px; }
.mem-watch { display: flex; flex-direction: column; gap: 2px; }
.mem-watch .bar-progress { margin: 0; }
.mem-watch small, .mem-done { font-size: 12px; color: var(--muted); }
.mem-done { text-align: right; }
.mem-log { display: grid; grid-template-columns: 130px 130px minmax(0, 1fr) minmax(0, 1fr) 120px; gap: 12px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 13px; }
.mem-log > span { min-width: 0; overflow-wrap: anywhere; }
.mem-loghead { font-size: 10px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--dim); border-top: 0; }
.mem-logs { max-height: 460px; overflow: auto; }
.mem-dev { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; border-top: 1px solid var(--line); }
@media (max-width: 1100px) { .mem-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .hub-row { grid-template-columns: 1fr 1fr; }
  .hub-row > :first-child, .hub-row > :nth-child(2) { grid-column: 1 / -1; }
  .mem-head { padding: 18px; }
  .mem-actions { width: 100%; }
  .mem-actions button { flex: 1; }
  .mem-lesson { grid-template-columns: 1fr; gap: 6px; }
  .mem-done { text-align: left; }
  .mem-log { grid-template-columns: 1fr 1fr; gap: 4px 12px; }
  .mem-loghead { display: none; }
  .mem-chart, .mem-course, .mem-logs { padding: 16px; }
}

/* ---------- Onboarding (2026-11-26): the client's intake form, the Home banner, Emil's view ---------- */
.ob-head { max-width: 860px; margin-bottom: 16px; }
.ob-head .muted { max-width: 680px; }
.ob-top { display: flex; align-items: center; gap: 18px; padding: 16px 20px; margin-bottom: 14px; max-width: 980px; position: sticky; top: 64px; z-index: 3; background: rgba(21, 21, 24, 0.96); backdrop-filter: blur(10px); }
.ob-prog { display: flex; align-items: center; gap: 10px; }
.ob-prog .bar-progress { flex: 1; margin: 0; }
.ob-prog b { min-width: 40px; text-align: right; color: var(--gold-light); }
.ob-err { color: var(--warn); }
.ob-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; max-width: 980px; }
.ob-tabs button { padding: 8px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); cursor: pointer; }
.ob-tabs button[aria-selected="true"] { color: var(--gold-light); border-color: var(--gold-line); background: rgba(214, 182, 108, 0.1); }
.ob-tabs .ob-addmodel { border-style: dashed; color: var(--accent); }
.ob-tabwrap { display: inline-flex; }
.ob-tabwrap [role="tab"] { border-top-right-radius: 0; border-bottom-right-radius: 0; border-right: 0; }
.ob-tabs .ob-tabbin { display: inline-flex; align-items: center; padding: 8px 10px; border-top-left-radius: 0; border-bottom-left-radius: 0; }
.ob-tabs .ob-tabbin:hover, .ob-tabs .ob-tabbin:focus-visible { color: #e5736b; }
.ob-tabwrap [aria-selected="true"] + .ob-tabbin { border-color: var(--gold-line); background: rgba(214, 182, 108, 0.1); }
.ob-hint { padding: 14px 18px; max-width: 980px; margin: 0 0 12px; }
#obBody, .ob-adm-body { max-width: 980px; }
.ob-part { font-family: var(--serif); font-size: 24px; color: var(--gold-light); margin: 26px 0 2px; }
.ob-partnote { margin: 0 0 10px; }
.ob-sec { margin-bottom: 10px; padding: 0; overflow: hidden; }
.ob-sec > summary { display: flex; align-items: center; gap: 12px; padding: 14px 18px; cursor: pointer; list-style: none; }
.ob-sec > summary::-webkit-details-marker { display: none; }
.ob-sec > summary::after { content: '›'; color: var(--muted); font-size: 18px; transition: transform .15s; }
.ob-sec[open] > summary::after { transform: rotate(90deg); }
.ob-sec > summary b { font-size: 15px; }
.ob-emoji { font-size: 18px; width: 24px; text-align: center; }
.ob-count { font-size: 12px; color: var(--muted); border: 1px solid var(--line); border-radius: 99px; padding: 2px 10px; white-space: nowrap; }
.ob-count.full { color: #1a1408; background: var(--gold); border-color: transparent; }
.ob-intro { margin: 0 18px 6px; }
.ob-body { padding: 4px 18px 18px; display: grid; gap: 14px; }
.ob-h { font-size: 13px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--accent); margin: 10px 0 0; }
.ob-note { margin: 0; }
.ob-ul { margin: 0; padding-left: 20px; color: var(--muted); display: grid; gap: 4px; }
.ob-q { display: grid; gap: 6px; }
.ob-label { font-size: 13.5px; }
.ob-q input, .ob-q textarea, .ob-cell input { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: rgba(0, 0, 0, 0.25); color: var(--text); font: inherit; resize: vertical; }
.ob-q input:focus, .ob-q textarea:focus, .ob-cell input:focus { outline: none; border-color: var(--accent); }
.ob-choice { display: flex; flex-wrap: wrap; gap: 6px; }
.ob-choice button { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: rgba(0, 0, 0, 0.2); color: var(--text); cursor: pointer; font-size: 13px; text-align: left; }
.ob-choice button:hover { border-color: var(--gold-line); }
.ob-choice button[aria-pressed="true"] { background: var(--gold); color: #1a1408; border-color: transparent; font-weight: 600; }
.ob-calc { font-size: 14px; }
.ob-calc b { color: var(--gold-light); }
.ob-q-calc { padding: 10px 14px; border: 1px dashed var(--gold-line); border-radius: 10px; }
.ob-tally { display: inline-block; margin-right: 16px; }
.ob-pts { font-size: 11px; color: var(--accent); border: 1px solid var(--gold-line); border-radius: 99px; padding: 0 7px; margin-left: 6px; white-space: nowrap; }
.ob-grid { display: grid; gap: 6px; }
.ob-grow { display: grid; grid-template-columns: minmax(150px, 1.1fr) repeat(var(--cols), minmax(0, 1fr)); gap: 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.ob-ghead { border-top: 0; font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); padding-bottom: 0; }
.ob-rowlabel { display: grid; gap: 2px; font-size: 13.5px; }
.ob-rowlabel small { font-size: 12px; }
.ob-cell-k { display: none; color: var(--muted); font-size: 11px; }
.ob-cell .ob-choice button { padding: 5px 10px; font-size: 12px; }
.ob-item { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: rgba(0, 0, 0, 0.15); }
.ob-item-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.ob-item-head b:first-child { flex: 1; }
.ob-item-body { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.ob-item-body .ob-q:has(.ob-choice) { grid-column: 1 / -1; }
.ob-x { padding: 5px 10px; font-size: 12px; }
.ob-add { justify-self: start; }
.ob-foot { margin: 18px 0; }
.btn-ghost.danger { color: var(--warn); border-color: rgba(224, 83, 74, 0.4); background: none; cursor: pointer; }
.ob-val { color: var(--text); white-space: pre-wrap; word-break: break-word; }
.ob-val a { color: var(--accent); }
.ob-home { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 24px; padding: 20px 22px; text-decoration: none; color: var(--text); border-color: var(--gold-line); }
.ob-home .eyebrow, .ob-home b, .ob-home .muted { grid-column: 1; }
.ob-home b { font-size: 20px; font-family: var(--serif); color: var(--gold-light); }
.ob-home .ob-prog { grid-column: 1; max-width: 420px; }
.ob-home .btn-gold { grid-column: 2; grid-row: 1 / span 4; }
.ob-mini { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; }
.ob-mini.sent { color: var(--accent); }
.mem-onboard { padding: 18px 20px; }
.ob-adm-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.ob-adm-head h2 { flex: 1; margin: 0; font-size: 15px; font-weight: 600; }
.ob-adm-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.ob-adm-btns button { cursor: pointer; background: none; }
.mem-onboard .ob-sec { background: rgba(0, 0, 0, 0.15); }
@media (max-width: 760px) {
  .ob-top { flex-direction: column; align-items: stretch; top: 56px; }
  .ob-grow { grid-template-columns: 1fr; gap: 6px; }
  .ob-ghead { display: none; }
  .ob-cell-k { display: block; }
  .ob-home { grid-template-columns: 1fr; }
  .ob-home .btn-gold { grid-column: 1; grid-row: auto; justify-self: start; }
}
.ob-home { text-align: left; }
.ob-home .ob-prog { width: 100%; }
.ob-home .ob-prog .bar-progress { min-width: 120px; }
.home-grid a.ob-home { display: grid; align-items: center; }
.home-grid .ob-home .ob-prog b { font-family: inherit; font-size: 14px; color: var(--gold-light); }

/* ---------- Start here, designed (2026-11-26) ---------- */
.st { max-width: 1060px; margin: 0 auto; }
#v-start.guide { max-width: none; }
.st-hero { display: grid; grid-template-columns: 1.5fr 1fr; gap: 28px; padding: 28px 30px; align-items: center; background: radial-gradient(520px 260px at 85% 20%, rgba(214, 182, 108, 0.14), transparent 70%), var(--panel); border-color: var(--gold-line); }
.st-hero h1 { font-size: 48px; margin: 0 0 8px; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.st-hero p { color: var(--text); opacity: .88; line-height: 1.65; margin: 0 0 10px; }
.st-path { display: grid; gap: 10px; }
.st-step { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: rgba(0, 0, 0, 0.25); color: var(--text); text-decoration: none; }
.st-step[href]:hover { border-color: var(--gold-line); }
.st-step b { display: block; font-size: 14px; }
.st-step small { color: var(--muted); }
.st-step-n { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center; font-weight: 700; border: 1px solid var(--gold-line); color: var(--gold-light); }
.st-step.now { border-color: var(--gold-line); box-shadow: 0 0 0 1px rgba(214, 182, 108, 0.25), 0 10px 30px rgba(214, 182, 108, 0.08); }
.st-step.now .st-step-n, .st-step.done .st-step-n { background: var(--gold); color: #1a1408; border-color: transparent; }
.st-chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 18px 0 6px; position: sticky; top: 64px; z-index: 3; padding: 8px 0; background: linear-gradient(var(--bg) 70%, transparent); }
.st-chips a { padding: 7px 13px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--text); text-decoration: none; font-size: 13px; white-space: nowrap; }
.st-chips a:hover { border-color: var(--gold-line); color: var(--gold-light); }
.st-sec { scroll-margin-top: 120px; margin-top: 34px; }
.st-sec h2 { font-family: var(--serif); font-size: 32px; color: var(--gold-light); margin: 0 0 14px; display: flex; align-items: center; gap: 12px; border: 0; padding: 0; }
.st-h-emoji { font-size: 26px; }
.st-sub { margin: -6px 0 14px; }
.st-tour { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.st-tile { text-align: left; padding: 0; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); color: var(--text); cursor: pointer; overflow: hidden; display: grid; transition: transform .15s, border-color .15s; font: inherit; }
.st-tile:hover { transform: translateY(-3px); border-color: var(--gold-line); }
.st-shot { height: 130px; background-size: cover; background-position: top left; border-bottom: 1px solid var(--line); }
.st-shot-emoji { display: grid; place-items: center; font-size: 46px; background: radial-gradient(circle at 50% 40%, rgba(214, 182, 108, 0.18), transparent 70%); }
.st-tile-t { padding: 12px 14px 2px; font-weight: 600; font-size: 15px; }
.st-tile-d { padding: 0 14px 14px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.st-rules { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.st-rule { position: relative; text-align: left; display: flex; flex-direction: column; gap: 8px; padding: 18px; border-radius: 16px; border: 1px solid var(--line); background: linear-gradient(180deg, rgba(214, 182, 108, 0.06), transparent 60%), var(--panel); color: var(--text); cursor: pointer; font: inherit; transition: transform .15s, border-color .15s, box-shadow .15s; }
.st-rule:hover { transform: translateY(-3px); border-color: var(--gold-line); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45); }
.st-rule-top { display: flex; align-items: center; gap: 8px; }
.st-rule-emoji { font-size: 28px; }
.st-rule-n { margin-left: auto; font-family: var(--serif); font-size: 34px; font-weight: 700; line-height: 1; background: var(--gold); -webkit-background-clip: text; background-clip: text; color: transparent; }
.st-tick { position: absolute; top: 10px; left: 10px; width: 18px; height: 18px; border-radius: 50%; background: var(--gold); color: #1a1408; font-size: 11px; display: none; place-items: center; font-weight: 700; }
.st-rule.seen .st-tick { display: grid; }
.st-rule b { font-family: var(--serif); font-size: 21px; line-height: 1.15; color: var(--gold-light); }
.st-rule-d { color: var(--muted); font-size: 13px; line-height: 1.5; flex: 1; }
.st-more { font-size: 12px; color: var(--accent); }
.st-focus { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.st-card { padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.st-card-emoji { font-size: 26px; display: block; margin-bottom: 8px; }
.st-card b { font-size: 16px; }
.st-card p { color: var(--muted); margin: 6px 0 0; line-height: 1.6; font-size: 14px; }
.st-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.st-tabs button { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); cursor: pointer; font: inherit; font-size: 13px; }
.st-tabs button[aria-selected="true"] { background: var(--gold); color: #1a1408; border-color: transparent; font-weight: 600; }
.st-work { padding: 24px 26px; }
.st-work-p { display: flex; gap: 18px; align-items: flex-start; animation: stIn .25s ease; }
.st-work-emoji { font-size: 44px; line-height: 1; }
.st-work h3 { font-family: var(--serif); font-size: 26px; color: var(--gold-light); margin: 0 0 8px; }
.st-work p { margin: 0; line-height: 1.75; font-size: 15px; }
.st-quote { color: var(--gold-light); font-style: italic; }
@keyframes stIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.st-flips { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.st-flip { padding: 0; border: 0; background: none; cursor: pointer; perspective: 900px; height: 170px; font: inherit; color: var(--text); text-align: left; }
.st-flip-in { position: relative; display: block; width: 100%; height: 100%; transition: transform .5s; transform-style: preserve-3d; }
.st-flip.flipped .st-flip-in { transform: rotateY(180deg); }
.st-face { position: absolute; inset: 0; border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 6px; backface-visibility: hidden; -webkit-backface-visibility: hidden; border: 1px solid var(--line); }
.st-front { background: linear-gradient(160deg, rgba(224, 83, 74, 0.12), transparent 60%), var(--panel); }
.st-front b { font-size: 15px; line-height: 1.35; flex: 1; }
.st-front small { color: var(--muted); font-size: 11px; }
.st-flip-n { position: absolute; top: 12px; right: 14px; font-family: var(--serif); font-size: 26px; color: rgba(224, 83, 74, 0.55); font-weight: 700; }
.st-x { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: rgba(224, 83, 74, 0.18); color: var(--warn); font-size: 12px; }
.st-back { transform: rotateY(180deg); background: linear-gradient(160deg, rgba(214, 182, 108, 0.16), transparent 70%), var(--panel); border-color: var(--gold-line); font-size: 14px; line-height: 1.5; }
.st-ok { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--gold); color: #1a1408; font-size: 12px; font-weight: 700; }
.st-steps { list-style: none; margin: 0; padding: 0; position: relative; }
.st-steps::before { content: ''; position: absolute; left: 17px; top: 10px; bottom: 10px; width: 2px; background: linear-gradient(var(--gold-line), transparent); }
.st-steps li { display: flex; gap: 16px; align-items: flex-start; padding: 10px 0; position: relative; }
.st-step-dot { width: 36px; height: 36px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--gold); color: #1a1408; font-weight: 700; box-shadow: 0 0 0 5px var(--bg); }
.st-steps li div { padding-top: 7px; line-height: 1.65; font-size: 15px; }
.st-quotes { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.st-q { margin: 0; position: relative; padding: 22px 22px 16px; border: 1px solid var(--gold-line); border-radius: 16px; background: radial-gradient(300px 140px at 0% 0%, rgba(214, 182, 108, 0.12), transparent 70%), var(--panel); }
.st-q-mark { position: absolute; top: -6px; left: 14px; font-family: var(--serif); font-size: 72px; line-height: 1; color: rgba(214, 182, 108, 0.35); }
.st-q blockquote { margin: 14px 0 10px; font-family: var(--serif); font-size: 22px; line-height: 1.3; color: var(--text); }
.st-q figcaption { color: var(--accent); font-size: 12px; text-transform: uppercase; letter-spacing: 0.14em; }
.st-end { display: flex; align-items: center; gap: 20px; justify-content: space-between; padding: 22px 26px; margin: 40px 0 10px; border-color: var(--gold-line); flex-wrap: wrap; }
.st-end b { display: block; font-family: var(--serif); font-size: 24px; color: var(--gold-light); }
.st-dlg { width: min(680px, calc(100vw - 32px)); max-height: calc(100vh - 48px); padding: 0; border: 1px solid var(--gold-line); border-radius: 20px; background: #121110; color: var(--text); box-shadow: 0 40px 120px rgba(0, 0, 0, 0.8); }
.st-dlg::backdrop { background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(4px); }
.st-dlg[open] { animation: stPop .22s ease; }
@keyframes stPop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.st-dlg-in { position: relative; padding: 26px 28px 20px; }
.st-dlg-x { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: rgba(0, 0, 0, 0.4); color: var(--text); cursor: pointer; z-index: 1; }
.st-dlg-img { display: block; width: calc(100% + 56px); margin: -26px -28px 18px; border-bottom: 1px solid var(--line); }
.st-dlg-head { display: grid; gap: 2px; margin-bottom: 10px; }
.st-dlg-emoji { font-size: 40px; }
.st-dlg-head h2 { font-family: var(--serif); font-size: 32px; color: var(--gold-light); margin: 0; }
.st-dlg-body { line-height: 1.75; font-size: 15.5px; }
.st-dlg-body p { margin: 0 0 12px; }
.st-dlg-body ul { padding-left: 18px; }
.st-dlg-nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.st-dlg-nav button { cursor: pointer; }
.st-dlg-nav button:disabled { opacity: .35; cursor: default; }
@media (max-width: 980px) { .st-rules { grid-template-columns: repeat(2, minmax(0, 1fr)); } .st-hero { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .st-rules { grid-template-columns: 1fr; } .st-hero h1 { font-size: 38px; } .st-chips { top: 56px; } .st-work-p { flex-direction: column; gap: 8px; } }
.st-tile { grid-template-rows: auto auto 1fr; align-content: start; }
.ob-head h1 { font-size: 34px; font-weight: 700; letter-spacing: -0.035em; color: var(--text); margin: 0 0 8px; font-family: inherit; background: none; -webkit-background-clip: initial; background-clip: initial; }
@media (max-width: 760px) { .ob-head h1 { font-size: 26px; } }
/* Emil's read only view: question and answer side by side, so a whole intake scans quickly. */
.mem-onboard .ob-body { gap: 0; }
.mem-onboard .ob-q { grid-template-columns: minmax(220px, 38%) 1fr; gap: 16px; padding: 9px 0; border-top: 1px solid rgba(255, 255, 255, 0.05); align-items: start; }
.mem-onboard .ob-label { color: var(--muted); font-size: 13px; }
.mem-onboard .ob-val { font-size: 14px; }
.mem-onboard .ob-h { margin: 16px 0 4px; }
.mem-onboard .ob-q-calc { border: 0; border-top: 1px solid var(--gold-line); padding: 10px 0; border-radius: 0; }
.mem-onboard .ob-item-body { grid-template-columns: 1fr; gap: 0; }
.mem-onboard .ob-grow { padding: 6px 0; }
@media (max-width: 760px) { .mem-onboard .ob-q { grid-template-columns: 1fr; gap: 4px; } }

/* AI made reels (2026-11-27) */
.pill.ai { color: #9fd3ff; }
.ai-made { margin: 8px 0 0; font-size: 13px; color: var(--muted, #b9b9b9); }
.ai-made .pill.ai { background: rgba(120, 180, 255, 0.14); border-radius: 6px; padding: 1px 8px; margin-right: 6px; }
.ai-flag { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin: 8px 0 0; }
.ai-flag button.on { border-color: var(--gold-light, #d4af37); color: var(--gold-light, #d4af37); }
.remake-label { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; color: #d4af37; margin: 4px 0 6px; }
.remake-changes { width: 100%; box-sizing: border-box; background: rgba(255,255,255,0.04); color: inherit; border: 1px solid rgba(255,255,255,0.14); border-radius: 8px; padding: 8px 10px; font: inherit; font-size: 13px; resize: vertical; margin-bottom: 8px; }

/* Reel sheet scrolling (Emil 2026-11-27: "I can't scroll down to read the full breakdown, it just scrolls the main page").
   On wide screens each column scrolls on its own inside the sheet; the page behind is locked while the sheet is open. */
html.sheet-open, html.sheet-open body { overflow: hidden; }
.detail { overscroll-behavior: contain; }
.detail .sheet { grid-template-rows: minmax(0, 1fr); overflow: hidden; }
.detail .sheet > .player, .detail .sheet > .info { min-height: 0; max-height: calc(100vh - 76px); max-height: calc(100dvh - 76px); }
.detail .sheet > .player.frames { overflow-y: auto; overscroll-behavior: contain; }
.pane { overscroll-behavior: contain; }
@media (max-width: 760px) {
  /* Phones: one column, the whole sheet scrolls. */
  .detail .sheet { grid-template-rows: none; overflow-y: auto; overscroll-behavior: contain; max-height: calc(100dvh - 16px); }
  .detail .sheet > .player, .detail .sheet > .info { max-height: none; }
  .detail .sheet > .player.frames { overflow: visible; }
  .pane { overflow: visible; }
}

/* Slideshows (Emil 2026-11-27: "I can't click to see the other slides, especially in the feed"): click the left or
   right side of a slide, or the arrows, to go back or forward. */
.gallery #gMain { cursor: pointer; }
.stage .snav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 40px; height: 40px; border-radius: 50%; border: 0;
  background: rgba(0, 0, 0, .5); color: #fff; font-size: 24px; line-height: 1; cursor: pointer; }
.stage .snav.prev { left: 10px; }
.stage .snav.next { right: 66px; }
.stage .snav:hover { background: rgba(0, 0, 0, .8); }
.stage .slides-row img { cursor: pointer; }

/* Onboarding: "Watch this first" explainer above the form (Emil 2026-11-29). Laptops: the 16:9 cut across the
   whole card, kept low enough that the form heading still shows on a 720p screen. Phones: the 9:16 cut. */
.ob-video { max-width: 980px; margin-bottom: 18px; padding: 0; overflow: hidden; }
.ob-video summary { display: flex; align-items: center; gap: 14px; padding: 16px 20px; cursor: pointer; list-style: none; }
.ob-video summary::-webkit-details-marker { display: none; }
.ob-video summary .grow { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ob-video summary b { font-family: var(--serif); font-size: 20px; color: var(--gold-light); }
.ob-vsub { color: var(--muted); font-size: 14px; line-height: 1.45; }
.ob-vplay { width: 38px; height: 38px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; background: var(--gold, #d6b66c); color: #111; font-size: 14px; padding-left: 2px; }
.ob-vtoggle { flex: none; }
.ob-vtoggle .on, .ob-video[open] .ob-vtoggle .off { display: none; }
.ob-video[open] .ob-vtoggle .on { display: inline; }
.ob-vbody { padding: 0 20px 20px; }
.ob-vframe { width: 260px; aspect-ratio: 9 / 16; margin: 0 auto; border-radius: 14px; overflow: hidden; background: #000; display: flex; align-items: center; justify-content: center; }
.ob-vframe.wide { width: min(100%, calc(60vh * 16 / 9)); aspect-ratio: 16 / 9; }
.ob-vframe iframe { width: 100%; height: 100%; border: 0; display: block; }
.ob-vframe .empty { padding: 16px; text-align: center; }
@media (max-width: 760px) {
  .ob-video summary { padding: 12px 16px; }
  .ob-video summary b { font-size: 17px; }
  .ob-vsub { font-size: 13px; }
  .ob-vbody { padding: 0 16px 16px; }
  .ob-vframe:not(.wide) { width: min(100%, 300px); }
}

/* Client page (Emil 2026-11-29): tabs, and the onboarding at a glance. */
.mem-tabs { display: flex; gap: 8px; margin: 18px 0 14px; flex-wrap: wrap; }
.mem-tabs button { padding: 9px 18px; border-radius: 999px; border: 1px solid var(--gold-line); background: transparent; color: var(--muted); font: inherit; font-weight: 600; cursor: pointer; }
.mem-tabs button[aria-selected="true"] { color: var(--text); border-color: var(--accent); background: rgba(191, 169, 112, 0.12); }
.stu-models { display: block; font-size: 12px; color: var(--gold-light); margin-top: 3px; }
.ob-glance { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin: 6px 0 22px; }
.ob-gl-card { display: flex; flex-direction: column; gap: 4px; padding: 18px; margin: 0; }
.ob-gl-title { font-family: var(--serif); font-size: 20px; color: var(--gold-light); margin-bottom: 8px; }
.ob-gl-rows { display: flex; flex-direction: column; flex: 1; }
.ob-gl-row { display: grid; grid-template-columns: 130px 1fr; gap: 10px; padding: 7px 0; border-top: 1px solid var(--frame-line); font-size: 13.5px; }
.ob-gl-k { color: var(--muted); font-size: 12.5px; }
.ob-gl-v { min-width: 0; overflow-wrap: anywhere; }
.ob-gl-v a { color: var(--gold-light); }
.ob-gl-open { align-self: flex-start; margin-top: 12px; }
.ob-gl-ai { align-self: flex-start; margin: -4px 0 8px; font-size: 12px; }
.ob-adm-sub { font-size: 15px; font-weight: 600; margin: 4px 0 10px; scroll-margin-top: 90px; }
@media (max-width: 760px) { .ob-gl-row { grid-template-columns: 110px 1fr; } }
