:root {
  --ink: #1C1410;
  --ink-2: #3F332C;
  --ink-3: #6B5A4E;
  --bg: #FFF8F2;
  --card: #ffffff;
  --line: #E8D9CD;
  --dark: #0F0B09;
  --dark-2: #1C1410;
  --brand: #FF6A1F;
  --brand-2: #FF8A4C;
  --brand-deep: #B83E00;
  --brand-soft: #FFEADB;
  --peach: #FED7AA;
  --accent: #FF8A4C;
  --accent-soft: #FFF1E6;
  --good: #156B3B;
  --good-soft: #E2F3E8;
  --warn: #9A4A0B;
  --warn-soft: #FFEBD6;
  --bad: #B23B3B;
  --bad-soft: #F8E3E3;
  --radius: 22px;
  --shadow: 0 1px 2px rgba(28,20,16,.05), 0 18px 40px -24px rgba(184,62,0,.25);
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: Onest, system-ui, -apple-system, Segoe UI, sans-serif; color: var(--ink); background: var(--bg); line-height: 1.55; font-size: 16px; }
a { color: var(--brand-deep); }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; font-family: Sora, Onest, sans-serif; letter-spacing: -.02em; font-weight: 700; }
h1 { font-weight: 800; font-size: clamp(1.7rem, 3.2vw, 2.4rem); letter-spacing: -.03em; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 .8em; }
small, .muted { color: var(--ink-3); }

.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px clamp(16px, 4vw, 40px); background: var(--dark); border-bottom: 1px solid rgba(255,255,255,.06); }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: #fff; font-family: Sora, sans-serif; font-weight: 800; font-size: 1.05rem; letter-spacing: -.01em; }
.brand b { color: var(--brand-2); font-weight: 800; }
.sun { width: 22px; height: 22px; fill: var(--brand); stroke: var(--brand); flex: none; }
.brand em { font-style: normal; font-weight: 600; font-family: Onest, sans-serif; font-size: .82em; color: var(--peach); padding: 3px 9px; border: 1px solid rgba(254,215,170,.35); border-radius: 999px; margin-left: 4px; }

nav { display: flex; gap: 4px; flex-wrap: wrap; }
nav a, nav button { font: inherit; font-size: .92rem; color: #E9DCD2; text-decoration: none; padding: 7px 12px; border-radius: 8px; background: none; border: 0; cursor: pointer; }
nav a, nav button { border-radius: 999px !important; }
nav a:hover, nav button:hover { background: rgba(255,255,255,.08); color: #fff; }
nav a.on { background: var(--brand); color: var(--dark-2); font-weight: 600; }

main { max-width: 1040px; margin: 0 auto; padding: clamp(20px, 4vw, 40px) clamp(16px, 4vw, 40px) 80px; }
.loading { padding: 80px 0; text-align: center; color: var(--ink-3); }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(18px, 3vw, 28px); box-shadow: var(--shadow); }
.stack > * + * { margin-top: 16px; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }

.btn { font: inherit; font-weight: 600; font-size: .95rem; display: inline-flex; align-items: center; gap: 8px; padding: 11px 22px; border-radius: 999px; border: 1px solid transparent; background: var(--brand); color: var(--dark-2); transition: transform .2s ease, background .2s ease; cursor: pointer; text-decoration: none; }
.btn:hover { background: var(--brand-2); transform: translateY(-2px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.ghost { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.btn.ghost:hover { background: #fff; border-color: var(--brand-2); }
.btn.small { padding: 6px 12px; font-size: .85rem; }
.btn.danger { background: var(--bad); color: #fff; }

label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
input, textarea, select { font: inherit; width: 100%; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--brand); outline-offset: 1px; border-color: transparent; }
textarea { min-height: 90px; resize: vertical; }
.field + .field { margin-top: 14px; }
.error { color: var(--bad); font-size: .92rem; min-height: 1.2em; margin-top: 8px; }

.login-wrap { min-height: 80vh; display: grid; place-items: center; }
.login { width: min(420px, 100%); }
.login .brand { margin-bottom: 22px; }

.hero { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; background: radial-gradient(120% 140% at 85% 10%, rgba(255,106,31,.35), transparent 55%), var(--dark); color: #fff; border-color: transparent; border-radius: 28px; }
.hero h1 { color: #fff; }
.hero p { color: #E9DCD2; }
.hero .muted { color: var(--peach) !important; }
.hero .btn.ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.25); }
@media (max-width: 640px) { .hero { grid-template-columns: 1fr; } }
.ring { --p: 0; width: 128px; height: 128px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--brand) calc(var(--p) * 1%), rgba(255,255,255,.12) 0); }
.ring span { width: 98px; height: 98px; border-radius: 50%; background: var(--dark); color: #fff; display: grid; place-items: center; font-family: Sora, sans-serif; font-weight: 800; font-size: 1.5rem; }

.stat { padding: 16px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.stat b { display: block; font-family: Sora, sans-serif; font-size: 1.5rem; letter-spacing: -.02em; }
.stat span { color: var(--ink-3); font-size: .88rem; }

.modules { display: grid; gap: 12px; }
.module { display: grid; grid-template-columns: 44px 1fr auto; gap: 16px; align-items: center; padding: 16px 18px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: inherit; }
.module { transition: transform .2s ease, box-shadow .2s ease, border-color .2s; }
.module:hover { border-color: var(--brand-2); transform: translateY(-2px); box-shadow: 0 18px 40px -18px rgba(184,62,0,.45); }
.module.locked { opacity: .55; pointer-events: none; }
.module .num { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; font-family: Sora, sans-serif; font-weight: 800; background: var(--brand-soft); color: var(--brand-deep); }
.module.done .num { background: var(--dark); color: var(--brand-2); }
.module h3 { margin: 0 0 2px; }
.module p { margin: 0; color: var(--ink-3); font-size: .9rem; }

.pill { display: inline-block; font-size: .78rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-deep); white-space: nowrap; }
.pill.good { background: var(--good-soft); color: var(--good); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.bad { background: var(--bad-soft); color: var(--bad); }
.pill.grey { background: #F1E8E0; color: var(--ink-3); }

.lessons { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.lessons a { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); text-decoration: none; color: inherit; background: #fff; }
.lessons a:hover { border-color: var(--brand-2); }
.check { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; flex: none; font-size: .8rem; }
.check.on { background: var(--good); border-color: var(--good); color: #fff; }

.crumbs { font-size: .9rem; margin-bottom: 14px; color: var(--ink-3); }
.crumbs a { color: var(--ink-3); }

.video { position: relative; aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; background: #0f1720; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-empty { padding: 18px; border-radius: 16px; background: var(--accent-soft); border: 1px dashed var(--brand-2); font-size: .92rem; }

.md ul, .md ol { padding-left: 1.3em; }
.md li { margin: 6px 0; }
.md pre { background: var(--dark); color: #e8f0f2; padding: 14px 16px; border-radius: 10px; overflow-x: auto; font-size: .85rem; white-space: pre-wrap; }
.md code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .9em; background: var(--accent-soft); padding: 1px 5px; border-radius: 5px; }
.md pre code { background: none; padding: 0; }
.md table { border-collapse: collapse; width: 100%; margin: 12px 0; font-size: .92rem; display: block; overflow-x: auto; }
.md th, .md td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.md th { background: var(--accent-soft); }
.md li.task { list-style: none; margin-left: -1.3em; }
.md li.task::before { content: "☐ "; color: var(--brand); }

.quiz-q { padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.quiz-q h3 { font-weight: 600; }
.opt { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); margin-top: 8px; cursor: pointer; font-weight: 400; }
.opt:hover { border-color: var(--brand-2); }
.opt input { width: auto; margin-top: 4px; }
.opt.right { border-color: var(--good); background: var(--good-soft); }
.opt.wrong { border-color: var(--bad); background: var(--bad-soft); }
.why { margin-top: 10px; font-size: .92rem; color: var(--ink-2); }
.result { padding: 18px; border-radius: 12px; }
.result.pass { background: var(--good-soft); }
.result.fail { background: var(--warn-soft); }

table.data { width: 100%; border-collapse: collapse; font-size: .92rem; }
table.data th, table.data td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
table.data th { font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-3); }
.table-wrap { overflow-x: auto; }
.bar { height: 8px; border-radius: 99px; background: var(--brand-soft); overflow: hidden; min-width: 80px; }
.bar i { display: block; height: 100%; background: var(--brand); }

.notice { padding: 14px 16px; border-radius: 16px; background: var(--accent-soft); border: 1px solid var(--peach); }
.secret { font-family: ui-monospace, Menlo, monospace; font-size: 1.1rem; padding: 10px 14px; background: var(--dark); color: #fff; border-radius: 10px; display: inline-block; user-select: all; }
#toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; box-shadow: var(--shadow); z-index: 50; max-width: 90vw; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
details summary { cursor: pointer; font-weight: 600; }

[hidden] { display: none !important; }
.login .btn { width: 100%; justify-content: center; display: flex; }

/* Better Help VAs brand extras */
.login-wrap { position: fixed; inset: 0; overflow: auto; z-index: 5; background: radial-gradient(60% 60% at 50% 0%, rgba(255,106,31,.28), transparent 70%), var(--dark); padding: 40px 16px; }
.card.login-wrap, form.login { margin: auto; }
.login { border-radius: 26px; border: 0; }
.login .brand { color: var(--ink); }
.login .brand em { color: var(--brand-deep); border-color: var(--line); }
.yt { margin-top: 18px; }
.yt-meta { margin: 0 0 8px; font-size: .95rem; }
.video { border-radius: 18px; }
.check.on { background: var(--brand); border-color: var(--brand); color: var(--dark-2); }
.stat { border-radius: 18px; }
.lessons a { border-radius: 14px; }
.lessons a:hover { border-color: var(--brand-2); }
.quiz-q { border-radius: 18px; }
.opt { border-radius: 14px; }
.opt:hover { border-color: var(--brand-2); }

.bonus { margin-top: 18px; padding: 14px 16px; border: 1px dashed var(--line); border-radius: 16px; background: #fff; }
.bonus summary { color: var(--brand-deep); }
.scores { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
.scores label { font-size: .85rem; }
.scores select { margin-top: 4px; }

.shorts { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; margin-top: 12px; }
.vert { position: relative; aspect-ratio: 9/16; border-radius: 18px; overflow: hidden; background: #0F0B09; }
.vert iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.tip { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 12px; }
.tip .row { margin: 6px 0; }
