
:root {
  --primary: #0070e0;
  --accent: #ffaf05;
  --ink: #1E3440;
  --paper: #F7F9FC;
  --surface: #FFFFFF;
  --graphite: #4B535A;
  --rule: #D5DCDA;
  --mark: #F2DD4C;
  --mark-ink: #1E3440;
  --deadline: #B3261E;
  --ok: #24693F;
  --ok-bg: #E4F1E8;
  --bad-bg: #F8E3E1;
  --focus: #0070e0;
  --soft: #EBF3FC;
  color-scheme: light;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #E3EAE8; --paper: #121A1F; --surface: #1A242A; --graphite: #A9B3B8;
    --rule: #2F3C43; --mark: #C9B530; --mark-ink: #121A1F; --deadline: #F07A6E;
    --ok: #7FD39B; --ok-bg: #1C3326; --bad-bg: #3A1F1D; --focus: #7DB4F0; --soft: #202C33;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ink: #E3EAE8; --paper: #121A1F; --surface: #1A242A; --graphite: #A9B3B8;
  --rule: #2F3C43; --mark: #C9B530; --mark-ink: #121A1F; --deadline: #F07A6E;
  --ok: #7FD39B; --ok-bg: #1C3326; --bad-bg: #3A1F1D; --focus: #7DB4F0; --soft: #202C33;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: inherit; }
[hidden] { display: none !important; }
html { scroll-padding-top: env(safe-area-inset-top, 0px); height: 100%; }
body {
  margin: 0; min-height: 100%;
  background: var(--paper); color: var(--ink);
  font-family: "Public Sans", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1.0625rem; line-height: 1.6;
}
h1, h2, h3 { font-family: inherit; font-weight: 650; line-height: 1.2; letter-spacing: -0.025em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); margin: 0 0 .5rem; }
h2 { font-size: 1.55rem; margin: 2.4rem 0 .75rem; }
h3 { font-size: 1.15rem; margin: 1.8rem 0 .5rem; }
p, li { max-width: 68ch; }
a { color: var(--focus); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
img { max-width: 100%; }

.layout { display: grid; grid-template-columns: 17rem minmax(0, 1fr); min-height: 100vh; }
.rail {
  display:flex; flex-direction:column;
  border-right: 1px solid var(--rule); padding: 1.75rem 1.25rem; position: sticky; top: env(safe-area-inset-top, 0px);
  height: 100vh; overflow-y: auto; background: var(--surface);
}
.brand { width:180px; max-width:100%; margin: auto auto 0; padding-top:2.5rem; flex-shrink:0; }
.rail > .btn { align-self:flex-start; }
.rail > progress { flex-shrink:0; }
.brand img { display:block; width:100%; height:auto; }
.brand .brand-dark { display:none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand-light { display:none; }
  :root:not([data-theme="light"]) .brand-dark { display:block; }
}
:root[data-theme="dark"] .brand-light { display:none; }
:root[data-theme="dark"] .brand-dark { display:block; }
.rail .course { font-size: 1rem; font-weight: 650; line-height:1.4; margin-bottom: .5rem; }
.rail .meta { color: var(--graphite); font-size: .85rem; margin-bottom: 1.5rem; }
.rail ol { list-style: none; padding: 0; margin: 0; counter-reset: m; }
.rail li { margin: 0; }
.rail a {
  display: grid; grid-template-columns: 1.9rem 1fr; gap: .4rem; align-items: baseline;
  padding: .5rem .5rem; border-radius: 6px; color: var(--ink); text-decoration: none; font-size: .95rem;
}
.rail a:hover { background: var(--soft); }
.rail a[aria-current="page"] { background: var(--soft); font-weight: 600; }
.rail .num { font-variant-numeric: tabular-nums; color: var(--graphite); font-size: .85rem; }
.rail a.done .num { color: var(--ok); }
.rail a.done .num::after { content: " ✓"; }
.progress { height: 4px; background: var(--rule); border-radius: 2px; margin: 0 0 1.5rem; overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--ink); width: 0; transition: width .3s; }

main { width:100%; min-width:0; margin-inline:auto; padding: 3rem clamp(1.25rem, 3vw, 3rem) 5rem; max-width: 52rem; }
.draft {
  border: 1px dashed var(--graphite); color: var(--graphite); padding: .6rem .9rem; border-radius: 6px;
  font-size: .88rem; margin-bottom: 2rem; max-width: 68ch;
}
.lede { font-size: 1.15rem; color: var(--graphite); max-width: 60ch; }
.module { display: none; }
.module.active { display: block; }

/* Practical guidance callouts */
.rule { margin:1.75rem 0; padding:1rem 1.2rem; border-left:3px solid var(--focus); background:var(--soft); max-width:68ch; }
.rule, .note, .check .feedback, #status { border-radius:0; }
.rule p { margin:0; }
.rule .rule-title { font-weight:600; line-height:1.5; }
.rule .why { margin-top:.5rem; color:var(--graphite); font-size:.95rem; }

.cite { color: var(--graphite); font-size: .85rem; }
dl.terms { display: grid; grid-template-columns: minmax(9rem, 13rem) 1fr; gap: .6rem 1.25rem; max-width: 68ch; }
dl.terms dt { font-weight: 600; }
dl.terms dd { margin: 0; }
@media (max-width: 560px) { dl.terms { grid-template-columns: 1fr; } dl.terms dd { margin-bottom: .6rem; } }

.table-wrap { overflow-x: auto; margin: 1.25rem 0; }
table { border-collapse: collapse; min-width: 36rem; font-size: .95rem; }
th, td { text-align: left; vertical-align: top; padding: .6rem .75rem; border-bottom: 1px solid var(--rule); }
th { font-weight: 600; color: var(--graphite); font-size: .85rem; }

/* Breach clock: the signature element */
.clock { margin: 1.75rem 0 2rem; max-width: 46rem; }
.clock-scale { position: relative; height: 2px; background: var(--rule); margin: 3.2rem 0 2.8rem; }
.clock-scale .tick { position: absolute; top: 8px; font-size: .75rem; color: var(--graphite); transform: translateX(-50%); font-variant-numeric: tabular-nums; }
.clock-row { display: grid; grid-template-columns: 9.5rem 1fr; align-items: center; gap: .75rem; margin: .7rem 0; }
.clock-row .who { font-size: .88rem; line-height: 1.3; }
.clock-track { position: relative; height: 1.6rem; background: var(--soft); border-radius: 3px; }
.clock-bar { position: absolute; top: 0; bottom: 0; left: 0; background: var(--deadline); border-radius: 3px; opacity: .9; transform-origin: left; }
.clock-bar.later { opacity: .45; }
.clock-bar span { position: absolute; right: -.4rem; transform: translateX(100%); top: .15rem; font-size: .82rem; font-weight: 600; color: var(--deadline); white-space: nowrap; }
.clock-zero { position: absolute; left: 0; top: -2.4rem; font-size: .82rem; font-weight: 700; color: var(--deadline); }
@media (prefers-reduced-motion: no-preference) {
  .module.active .clock-bar { animation: grow .9s cubic-bezier(.2,.7,.2,1) both; }
  .module.active .clock-row:nth-child(3) .clock-bar { animation-delay: .1s; }
  .module.active .clock-row:nth-child(4) .clock-bar { animation-delay: .2s; }
  .module.active .clock-row:nth-child(5) .clock-bar { animation-delay: .3s; }
}
@keyframes grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@media (max-width: 560px) { .clock-row { grid-template-columns: 1fr; gap: .25rem; } .clock-bar span { font-size: .75rem; } }

/* Checks and quiz */
.check { border-top: 2px solid var(--ink); margin-top: 2.5rem; padding-top: 1.25rem; max-width: 68ch; }
.check .label { font-size: .85rem; color: var(--graphite); font-weight: 600; }
.check .q { font-weight: 600; margin: .4rem 0 .8rem; }
.opts { display: grid; gap: .5rem; }
.opt {
  text-align: left; font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--rule);
  border-radius: 6px; padding: .7rem .9rem; cursor: pointer; line-height: 1.45;
}
.opt:hover:not(:disabled) { border-color: var(--graphite); }
.opt[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.opt.correct { background: var(--ok-bg); border-color: var(--ok); }
.opt.wrong { background: var(--bad-bg); border-color: var(--deadline); }
.opt:disabled { cursor: default; }
.feedback { margin-top: .8rem; font-size: .95rem; }
.feedback strong { display: block; }

.nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 3rem; border-top: 1px solid var(--rule); padding-top: 1.25rem; flex-wrap: wrap; }
button.btn, a.btn {
  font: inherit; font-weight: 600; padding: .65rem 1.15rem; border-radius: 6px; cursor: pointer;
  border: 1px solid var(--primary); background: var(--primary); color: #fff; text-decoration: none; display: inline-block;
}
button.btn.secondary, a.btn.secondary { background: transparent; color: var(--ink); border-color:var(--rule); }
button.btn:hover:not(:disabled), a.btn:hover { filter:brightness(.93); }
input { accent-color:var(--primary); }
button.btn:disabled { opacity: .45; cursor: not-allowed; }

form.profile { display: grid; gap: 1rem; max-width: 30rem; margin: 1.5rem 0; }
label.field { display: grid; gap: .3rem; font-weight: 600; font-size: .95rem; }
input[type="text"], input[type="email"] {
  font: inherit; font-weight: 400; padding: .6rem .7rem; border: 1px solid var(--rule); border-radius: 6px;
  background: var(--surface); color: var(--ink);
}
fieldset { border: 1px solid var(--rule); border-radius: 6px; padding: .8rem 1rem; margin: 0; }
legend { font-weight: 600; font-size: .95rem; padding: 0 .3rem; }
.choice { display: flex; gap: .55rem; align-items: flex-start; margin: .35rem 0; font-weight: 400; }
.choice input { margin-top: .35rem; }
.hint { color: var(--graphite); font-size: .88rem; font-weight: 400; }
.role-only { display: none; }
.role-only.show { display: block; }
.role-tag { font-size: .8rem; color: var(--graphite); font-weight: 600; }

.score { font-family: "Literata", Georgia, serif; font-size: 2rem; font-weight: 650; }
.record {
  background: var(--surface); border: 1px solid var(--rule); border-radius: 8px; padding: 1.25rem 1.4rem; max-width: 40rem;
  font-size: .95rem;
}
.record dl { display: grid; grid-template-columns: 9rem 1fr; gap: .35rem 1rem; margin: 0; }
.record dt { color: var(--graphite); }
.record dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.next-wrap { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; justify-content: flex-end; margin-left: auto; }
.status { font-size: .9rem; margin-left: .6rem; color: var(--ok); }
.error { color: var(--deadline); font-size: .9rem; }

@media (max-width: 860px) {
  .layout { grid-template-columns: 1fr; }
  .rail { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--rule); padding: 1.25rem; }
  .rail ol { display: flex; overflow-x: auto; gap: .25rem; padding-bottom: .25rem; }
  .rail a { grid-template-columns: auto; white-space: nowrap; }
  .rail a .title { display: none; }
  .rail a .num { font-size: .95rem; }
}

.skip { position:absolute;left:-9999px } .skip:focus { left:1rem;top:1rem;z-index:9;background:var(--surface);padding:1rem }
.badge { font:600 .78rem "Public Sans",sans-serif;letter-spacing:.04em;text-transform:uppercase;color:var(--graphite) }
.note { border-left:4px solid var(--focus);padding:.75rem 1rem;background:var(--soft);margin:1.25rem 0 }
.note p:first-child { margin-top:0 } .note p:last-child { margin-bottom:0 }
details { border:1px solid var(--rule);border-radius:6px;padding:.9rem 1rem;margin:1.2rem 0 }
summary { font-weight:600;cursor:pointer } .answer-label { display:block;font-weight:700;font-size:.85rem }
.check legend { max-width:65ch } .check fieldset { border:0;padding:0 } .check .choice { background:var(--surface);border:1px solid var(--rule);border-radius:6px;padding:.65rem .8rem }
.check .choice.correct { border-color:var(--ok);background:var(--ok-bg) } .check .choice.wrong { border-color:var(--deadline);background:var(--bad-bg) }
.check .choice span { flex:1 } .check input { flex:none }
.check .feedback { padding:.8rem 1rem; }
.check .feedback.correct { border-left:3px solid var(--ok); background:var(--ok-bg); }
.check .feedback.incorrect { border-left:3px solid var(--deadline); background:var(--bad-bg); }
.feedback.correct strong { color:var(--ok); }
.feedback.incorrect strong { color:var(--deadline); }
.feedback p { margin:.35rem 0 0; }
.sources { font-size:.85rem;color:var(--graphite) } .sources li { margin:.35rem 0 }
.table-wrap { max-width:100% } th[scope=row] { font-size:.92rem;color:var(--ink) } caption { text-align:left;font-weight:600;margin-bottom:.7rem }
.service-table { min-width:42rem } .service-table td { min-width:10rem } .role-only.show { display:block }
.rail .btn { margin-top:1rem;font-size:.82rem;padding:.4rem .55rem } .progress-text { font-size:.82rem;color:var(--graphite) }
.storage-warning { color:var(--deadline) } .record dl { grid-template-columns:minmax(6rem,10rem) minmax(0,1fr) }
.setup-table td:first-child { min-width:11rem } .inline-links { display:flex;flex-wrap:wrap;gap:.75rem;font-size:.9rem }
@media(max-width:860px) { .rail a { display:flex;gap:.4rem } .rail a .title { display:inline;font-size:.85rem } .rail ol { align-items:center } .rail .progress { margin-bottom:.7rem } main { padding-top:1.5rem } }
@media(max-width:560px) { .record dl { grid-template-columns:1fr;gap:.1rem } .record dd { margin-bottom:.5rem } }
@media print { .rail,.draft,.nav,.check,form,button,.skip,#quiz-result,#attest,.local-notice { display:none!important } .layout { display:block } main { padding:0;max-width:none } .module { display:block!important;break-before:page } #start { break-before:auto } .role-only { display:block!important } details { display:block } details > * { display:block!important } body { background:white;color:black;font-size:11pt } .note { background:white } a { color:inherit } }
.print-heading { display:none; }
.record dd ol { margin:0; padding-left:1.2em; }
.record dd ol li + li { margin-top:.6em; }
@media print {
  @page { size: auto; margin: .65in; }
  body.print-record { background:#fff!important; color:#15252d!important; font:11pt/1.4 Arial,sans-serif; }
  body.print-record .module,
  body.print-record .rail,
  body.print-record #pager,
  body.print-record #storage-status,
  body.print-record noscript { display:none!important; }
  body.print-record #assessment { display:block!important; break-before:auto; }
  body.print-record #assessment > :not(#completion) { display:none!important; }
  body.print-record #completion { display:block!important; }
  body.print-record .record-actions { display:none!important; }
  body.print-record .print-heading { display:block; margin:0 0 10pt; font:10pt/1.4 Arial,sans-serif; color:#405561; }
  body.print-record h2 { margin:0 0 18pt; font:700 23pt/1.15 Arial,sans-serif; }
  body.print-record .layout { display:block; }
  body.print-record main { max-width:none; margin:0; padding:0; }
  body.print-record .record { max-width:none; border:0; border-top:2pt solid #315765; border-radius:0; background:white; padding:16pt 0 0; font-size:10.5pt; }
  body.print-record .record dl { display:grid; grid-template-columns:118pt minmax(0,1fr); gap:7pt 14pt; }
  body.print-record .record dt { color:#405561; font-weight:600; }
  body.print-record .record dd { color:#15252d; font-weight:400; overflow-wrap:anywhere; }
  body.print-record .record dd ol { padding-left:13pt; }
  body.print-record .record dd li { break-inside:avoid; }
}
/* Hosted training shell */
#content > div > h1:first-child { margin-top:0; }
#account { font-size:.8rem;overflow-wrap:anywhere;margin:1rem 0; }
#google-signin { margin-top:1rem; }
.signin-panel { border:1px solid var(--rule); border-radius:8px; background:var(--surface); padding:1.25rem 1.5rem; margin:2rem 0; }
.signin-panel h2 { font-size:1.2rem; margin:0 0 .5rem; }
.signin-panel p { margin:0; font-size:.95rem; color:var(--graphite); }
.signin-panel #google-signin { min-height:44px; }
#progress { width:100%;height:6px;accent-color:var(--focus);margin-bottom:1.4rem; }
#status:empty { display:none; }
#status { color:var(--graphite);border-left:3px solid var(--focus);padding:.5rem .8rem; }
#content fieldset { max-width:100%; }
#content .check fieldset { width:100%; }
#content form > .btn { margin:1rem 0; }
#content .record { display:grid;grid-template-columns:10rem 1fr;gap:.75rem;padding:1.2rem; }
#content .record dd { margin:0;overflow-wrap:anywhere; }
#content .check .answer-label { margin-left:.5rem; }
#content > .btn { margin:.5rem .5rem .5rem 0; }
#pager { margin-top:2rem;display:flex;justify-content:space-between; }
#content .check input { min-width:1rem; }
#content table td { overflow-wrap:anywhere; }
@media(max-width:560px){#content .record{grid-template-columns:1fr}.rail{position:static}#google-signin{margin-bottom:1rem}}
@media(max-width:860px){.brand{display:none}.rail .meta{margin-bottom:.75rem}.signin-panel{padding:1.25rem}}
.preview-banner {padding:.4rem 1rem;background:#634f20;color:#fff;text-align:center;font-size:.8rem}
