/* Helix Instruct 0.3.2 · styles
   Colours and type come from the Helix brand tokens (helix-brand 2.1.0).
   A publisher's storefront replaces --accent and --dark; everything else follows from those two. */

@font-face { font-family: 'Poppins'; font-weight: 500; font-display: swap; src: url('/fonts/poppins-500.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-weight: 700; font-display: swap; src: url('/fonts/poppins-700.woff2') format('woff2'); }

:root {
  --accent: #4078BD;        /* XtremeLabs Blue */
  --accent-strong: #2B5384; /* Blue Dark: text and buttons, where contrast matters */
  --accent-light: #8FB4DB;  /* Blue Light */
  --dark: #16273F;          /* Deep Navy */
  --dark-mid: #213F66;      /* Navy Mid */
  --ice: #CFE0F2;
  --cloud: #F1F6FC;
  --hairline: #D6E2F0;
  --ink: #1B2735;
  --slate: #475569;
  --grey: #6B7280;
  --good: #1F7A4D;
  --good-bg: #E6F4EC;
  --warn: #8A5A00;
  --warn-bg: #FBF1DA;
  --bad: #A4262C;
  --bad-bg: #FBE9EA;
  --display: 'Poppins', 'Segoe UI', system-ui, sans-serif;
  --body: Calibri, 'Segoe UI', system-ui, -apple-system, Arial, sans-serif;
  --page: 1180px;
}
:root[data-own-brand] {
  --accent-strong: color-mix(in srgb, var(--accent) 76%, #000);
  --accent-light: color-mix(in srgb, var(--accent) 55%, #fff);
  --dark-mid: color-mix(in srgb, var(--dark) 82%, #fff);
  --ice: color-mix(in srgb, var(--accent) 22%, #fff);
  --cloud: color-mix(in srgb, var(--accent) 6%, #fff);
  --hairline: color-mix(in srgb, var(--accent) 18%, #fff);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.5 var(--body); color: var(--ink); background: #fff; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; line-height: 1.2; margin: 0; color: var(--dark); }
h1 { font-size: 30px; letter-spacing: -0.01em; }
h2 { font-size: 21px; }
h3 { font-size: 17px; }
h4 { font-size: 15px; font-weight: 500; }
p { margin: 0 0 12px; }
a { color: var(--accent-strong); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--accent-light); outline-offset: 2px; }
.skip { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 12px; border-radius: 6px; z-index: 50; }
.skip:focus { left: 8px; }
.boot { padding: 80px 24px; text-align: center; color: var(--grey); }
.muted { color: var(--grey); }
.small { font-size: 14px; }
.nowrap { white-space: nowrap; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mono { font-family: ui-monospace, 'SF Mono', Consolas, monospace; font-size: 14px; letter-spacing: 0.02em; }

/* ---------- top bar ---------- */

.bar { background: var(--dark); color: #fff; }
.bar-in { max-width: var(--page); margin: 0 auto; padding: 0 24px; height: 62px; display: flex; align-items: center; gap: 20px; }
.brandmark { display: flex; align-items: center; gap: 14px; text-decoration: none; color: #fff; min-width: 0; }
.brandmark img { height: 34px; width: auto; max-width: 190px; display: block; object-fit: contain; object-position: left center; }
.brandmark .product { font: 500 17px var(--display); white-space: nowrap; padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, 0.28); }
.brandmark .name { font: 700 19px var(--display); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.bar nav a, .bar nav button { color: var(--ice); text-decoration: none; padding: 8px 12px; border-radius: 6px; background: none; border: 0; cursor: pointer; font-size: 15px; }
.bar nav a:hover, .bar nav button:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.bar nav a[aria-current] { color: #fff; background: rgba(255, 255, 255, 0.14); }
.bar nav a, .bar nav button { white-space: nowrap; }
.bar nav .me .wide { display: inline-block; max-width: 220px; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; }
.bar nav .me .narrow { display: none; }

.subbar { background: var(--cloud); border-bottom: 1px solid var(--hairline); }
.subbar-in { max-width: var(--page); margin: 0 auto; padding: 0 24px; display: flex; gap: 2px; overflow-x: auto; }
.subbar a { padding: 13px 14px 11px; text-decoration: none; color: var(--slate); border-bottom: 3px solid transparent; white-space: nowrap; font-size: 15px; }
.subbar a:hover { color: var(--dark); }
.subbar a[aria-current] { color: var(--dark); border-bottom-color: var(--accent); font-weight: 700; }

main { max-width: var(--page); margin: 0 auto; padding: 32px 24px 80px; }
.foot { max-width: var(--page); margin: 0 auto; padding: 20px 24px 40px; color: var(--grey); font-size: 14px; border-top: 1px solid var(--hairline); display: flex; gap: 18px; flex-wrap: wrap; justify-content: space-between; }
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.head p { margin: 6px 0 0; color: var(--slate); max-width: 68ch; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.back { display: inline-block; margin-bottom: 14px; font-size: 15px; text-decoration: none; }
.back:hover { text-decoration: underline; }

/* ---------- controls ---------- */

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--accent-strong); color: #fff; border: 1px solid var(--accent-strong); border-radius: 6px; padding: 9px 16px; font: 500 15px var(--display); cursor: pointer; text-decoration: none; line-height: 1.2; }
.btn:hover { background: var(--dark); border-color: var(--dark); }
.btn.ghost { background: #fff; color: var(--accent-strong); border-color: var(--hairline); }
.btn.ghost:hover { border-color: var(--accent); background: var(--cloud); }
.btn.danger { background: #fff; color: var(--bad); border-color: #E6B8BB; }
.btn.danger:hover { background: var(--bad-bg); }
.btn.small { padding: 6px 11px; font-size: 13.5px; }
.btn:disabled { opacity: 0.55; cursor: default; }
.link-btn { background: none; border: 0; padding: 0; color: var(--accent-strong); cursor: pointer; text-decoration: underline; font-size: inherit; }
.icon-btn { background: none; border: 0; font-size: 26px; line-height: 1; padding: 2px 8px; cursor: pointer; color: var(--slate); border-radius: 6px; }
.icon-btn:hover { background: var(--cloud); }

.field { margin-bottom: 14px; }
.field label { display: block; font-weight: 700; font-size: 14.5px; margin-bottom: 5px; color: var(--dark); }
.field .hint { font-size: 13.5px; color: var(--grey); margin: 5px 0 0; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=search], select, textarea {
  width: 100%; border: 1px solid #B9C7D8; border-radius: 6px; padding: 9px 11px; background: #fff; min-height: 40px; }
textarea { min-height: 84px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); outline: 3px solid var(--ice); outline-offset: 0; }
input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--accent-strong); vertical-align: -3px; margin: 0 7px 0 0; }
.check { display: flex; align-items: center; font-size: 15px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 18px; }
.span2 { grid-column: span 2; }
.span3 { grid-column: 1 / -1; }
.form-actions { display: flex; gap: 10px; align-items: center; margin-top: 8px; flex-wrap: wrap; }

.chip { display: inline-block; font-size: 12.5px; line-height: 1; padding: 5px 9px; border-radius: 999px; background: var(--cloud); color: var(--accent-strong); border: 1px solid var(--hairline); white-space: nowrap; }
.chip.good { background: var(--good-bg); color: var(--good); border-color: #BFE0CD; }
.chip.warn { background: var(--warn-bg); color: var(--warn); border-color: #EBD9A8; }
.chip.bad { background: var(--bad-bg); color: var(--bad); border-color: #EBC4C6; }
.chip.dark { background: var(--dark); color: #fff; border-color: var(--dark); }

.panel { border: 1px solid var(--hairline); border-radius: 10px; padding: 20px 22px; background: #fff; margin-bottom: 20px; }
.panel > h2, .panel > h3 { margin-bottom: 12px; }
.panel.tint { background: var(--cloud); }
.notice { border-left: 4px solid var(--accent); background: var(--cloud); padding: 12px 16px; border-radius: 0 6px 6px 0; margin-bottom: 18px; }
.notice.warn { border-left-color: #C98B00; background: var(--warn-bg); }
.notice.bad { border-left-color: var(--bad); background: var(--bad-bg); }
.notice p:last-child { margin-bottom: 0; }
.empty { color: var(--grey); padding: 28px 0; }

.table-wrap { overflow-x: auto; border: 1px solid var(--hairline); border-radius: 10px; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th { text-align: left; background: var(--dark); color: #fff; font: 500 13.5px var(--display); padding: 10px 12px; white-space: nowrap; }
.table th.num { text-align: right; }
.table td { padding: 10px 12px; border-top: 1px solid var(--hairline); vertical-align: top; }
.table tbody tr:nth-child(even) td { background: var(--cloud); }
.table td .sub { display: block; color: var(--grey); font-size: 13.5px; }
.table a.row-link { font-weight: 700; text-decoration: none; }
.table a.row-link:hover { text-decoration: underline; }
.table input[type=text], .table input[type=number], .table select { min-height: 34px; padding: 5px 8px; font-size: 14.5px; }

.toast { position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 20px); background: var(--dark); color: #fff; padding: 12px 18px; border-radius: 8px; opacity: 0; pointer-events: none; transition: opacity 0.18s, transform 0.18s; max-width: min(560px, 92vw); z-index: 60; font-size: 15px; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.bad { background: var(--bad); }

.backdrop { position: fixed; inset: 0; background: rgba(22, 39, 63, 0.55); display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px 24px; overflow-y: auto; z-index: 40; }
.dialog { background: #fff; border-radius: 12px; width: min(560px, 100%); box-shadow: 0 24px 60px rgba(22, 39, 63, 0.35); }
.dialog.wide { width: min(880px, 100%); }
.dialog-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px 12px; border-bottom: 1px solid var(--hairline); }
.dialog-body { padding: 18px 20px 20px; }
.dialog-text { color: var(--slate); }
.dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }

.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--hairline); margin: 0 0 24px; overflow-x: auto; }
.tabs button { background: none; border: 0; border-bottom: 3px solid transparent; padding: 11px 15px 9px; cursor: pointer; color: var(--slate); white-space: nowrap; font-size: 15.5px; }
.tabs button:hover { color: var(--dark); }
.tabs button[aria-selected=true] { color: var(--dark); border-bottom-color: var(--accent); font-weight: 700; }

/* ---------- sign in ---------- */

.gate { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.gate-side { background: var(--dark); color: #fff; padding: 56px 56px 44px; display: flex; flex-direction: column; position: relative; overflow: hidden; }
.gate-side .lockup { height: 62px; width: auto; align-self: flex-start; max-width: 260px; object-fit: contain; object-position: left center; }
.gate-side .pub-name { font: 700 24px var(--display); }
.gate-side h1 { color: #fff; font-size: clamp(38px, 4.6vw, 60px); line-height: 1.05; margin-top: auto; max-width: calc(100% - 190px); letter-spacing: -0.02em; }
.gate-side .tagline { color: var(--ice); font-size: 19px; max-width: min(24em, calc(100% - 190px)); margin: 18px 0 0; }
.gate-side .facts { margin: 34px 0 0; padding: 0; list-style: none; color: var(--accent-light); font-size: 15.5px; max-width: min(30em, calc(100% - 190px)); }
.gate-side .facts li { padding: 9px 0; border-top: 1px solid rgba(255, 255, 255, 0.14); }
.gate-side .motif { position: absolute; right: 36px; top: 50%; height: 80%; transform: translateY(-50%); opacity: 0.9; pointer-events: none; }
.gate-side .powered { margin-top: 30px; color: var(--accent-light); font-size: 13.5px; }
.gate-form { padding: 56px 48px; display: flex; align-items: center; justify-content: center; }
.gate-card { width: min(420px, 100%); }
.gate-card h2 { font-size: 24px; margin-bottom: 6px; }
.gate-card .lead { color: var(--slate); margin-bottom: 20px; }
.switch { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--hairline); border-radius: 8px; padding: 4px; gap: 4px; margin-bottom: 22px; background: var(--cloud); }
.switch button { border: 0; background: none; padding: 9px 8px; border-radius: 5px; cursor: pointer; color: var(--slate); font-size: 15px; }
.switch button[aria-selected=true] { background: #fff; color: var(--dark); font-weight: 700; box-shadow: 0 1px 3px rgba(22, 39, 63, 0.16); }
.gate-card .btn { width: 100%; padding: 12px 16px; font-size: 16px; }
.gate-card .under { margin-top: 14px; font-size: 14.5px; color: var(--grey); text-align: center; }
.code-input { font-family: ui-monospace, 'SF Mono', Consolas, monospace; letter-spacing: 0.12em; text-transform: uppercase; font-size: 18px !important; }

/* ---------- license agreement ---------- */

.gate-card.wide { width: min(640px, 100%); }
.agree { display: grid; grid-template-columns: auto 1fr; gap: 3px; align-items: start; margin: 4px 0 18px; font-size: 14.5px; }
.agree input[type=checkbox] { margin-top: 2px; }
.agree label { display: block; color: var(--dark); font-weight: 700; }
.agree .agree-links { margin-top: 4px; }
.agreement-text a { overflow-wrap: anywhere; }
.agreement-title { font-size: 18px; margin-bottom: 2px; }
.agreement-text { border: 1px solid var(--hairline); border-radius: 8px; padding: 2px 18px 10px; max-height: 46vh; overflow-y: auto; background: #fff; font-size: 14.5px; color: var(--slate); margin: 12px 0 14px; }
.agreement-text:focus-visible { outline: 3px solid var(--ice); border-color: var(--accent); }
.agreement-text h3 { font-size: 15.5px; margin: 16px 0 6px; color: var(--dark); }
.agreement-text p { margin: 0 0 9px; }
.agreement-text ul { margin: 0 0 9px; padding-left: 20px; }
.agreement-text li { margin-bottom: 5px; }
.gate-card .gate-help { margin-top: 18px; }
.agree-note { font-size: 14px; color: var(--slate); margin: 0 0 14px; }

/* ---------- library ---------- */

.redeem { display: flex; gap: 8px; align-items: flex-start; }
.redeem input { width: 230px; }
.shelf { display: grid; gap: 14px; }
.kit-row { display: grid; grid-template-columns: 190px minmax(0, 1fr) auto; gap: 0; border: 1px solid var(--hairline); border-radius: 10px; overflow: hidden; background: #fff; }
.kit-row .code { background: var(--dark); color: #fff; padding: 22px 20px; display: flex; flex-direction: column; justify-content: center; }
.kit-row .code strong { font: 700 28px/1.05 var(--display); letter-spacing: -0.01em; overflow-wrap: anywhere; }
.kit-row .code span { color: var(--accent-light); font-size: 14px; margin-top: 8px; }
.kit-row .about { padding: 18px 22px; min-width: 0; }
.kit-row .about h2 { font-size: 19px; margin-bottom: 4px; }
.kit-row .about p { color: var(--slate); margin: 0 0 8px; }
.kit-row .meta { display: flex; flex-wrap: wrap; gap: 6px 18px; color: var(--grey); font-size: 14px; }
.kit-row .go { padding: 18px 22px; display: flex; flex-direction: column; align-items: flex-end; justify-content: center; gap: 8px; background: var(--cloud); border-left: 1px solid var(--hairline); min-width: 190px; }
.kit-row .go .until { font-size: 13.5px; color: var(--slate); text-align: right; }
.kit-row.off .code { background: #5B6676; }
.kit-row.off .about { opacity: 0.75; }

/* ---------- kit view ---------- */

.kit-hero { background: var(--dark); color: #fff; }
.kit-hero-in { max-width: var(--page); margin: 0 auto; padding: 26px 24px 0; }
.kit-hero a.back { color: var(--accent-light); }
.kit-hero h1 { color: #fff; font-size: 30px; max-width: 26em; }
.kit-hero .facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 10px 0 22px; color: var(--ice); font-size: 15px; }
.kit-hero .facts strong { color: #fff; font-weight: 700; }

/* The course ruler: one cell for each week of the term, filled by the module taught that week. */
.ruler { padding-bottom: 20px; }
.ruler-title { font: 500 13.5px var(--display); color: var(--accent-light); margin-bottom: 8px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.ruler-grid { display: grid; gap: 3px; grid-template-columns: repeat(var(--weeks, 16), minmax(0, 1fr)); }
.ruler-week { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ruler-num { font-size: 12px; color: var(--accent-light); text-align: center; font-variant-numeric: tabular-nums; }
.ruler-cells { display: flex; gap: 2px; height: 38px; }
.ruler-cell { flex: 1; min-width: 0; border: 0; border-radius: 4px; background: var(--dark-mid); color: var(--ice); font: 500 12.5px var(--display); cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.ruler-cell.mod { background: var(--accent); color: #fff; }
.ruler-cell.mod.alt { background: var(--accent-light); color: var(--dark); }
.ruler-cell.mod:hover, .ruler-cell.mod:focus-visible { background: #fff; color: var(--dark); }
.ruler-cell.on { background: #fff; color: var(--dark); box-shadow: inset 0 -4px 0 var(--accent); }
.ruler-cell.plain { font-weight: 400; font-family: var(--body); font-size: 12px; }
.ruler-cell.plain:hover, .ruler-cell.plain:focus-visible, .ruler-cell.plain.on { background: #fff; color: var(--dark); }
.table tbody tr.at td { background: #FFF6D6; box-shadow: inset 0 2px 0 var(--accent), inset 0 -2px 0 var(--accent); }

.kit-tabs { background: var(--dark); }
.kit-tabs .tabs { max-width: var(--page); margin: 0 auto; padding: 0 24px; border-bottom: 0; }
.kit-tabs .tabs button { color: var(--accent-light); padding: 13px 15px 11px; }
.kit-tabs .tabs button:hover { color: #fff; }
.kit-tabs .tabs button[aria-selected=true] { color: var(--dark); background: #fff; border-radius: 8px 8px 0 0; border-bottom-color: #fff; }

.cols { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 32px; align-items: start; }
.side-list { list-style: none; margin: 0; padding: 0; position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow-y: auto; }
.side-list button { width: 100%; text-align: left; background: none; border: 0; border-left: 3px solid var(--hairline); padding: 9px 12px; cursor: pointer; display: flex; gap: 10px; align-items: baseline; font-size: 15px; color: var(--slate); }
.side-list button:hover { background: var(--cloud); color: var(--dark); }
.side-list button[aria-current] { border-left-color: var(--accent); background: var(--cloud); color: var(--dark); font-weight: 700; }
.side-list .n { font: 700 13px var(--display); color: var(--accent-strong); min-width: 1.6em; }
.prose { max-width: 74ch; }
.prose h2 { margin: 0 0 6px; font-size: 24px; }
.prose h3 { margin: 28px 0 10px; }
.prose ul { margin: 0 0 12px; padding-left: 20px; }
.prose li { margin-bottom: 6px; }
.lede { font-size: 17.5px; color: var(--slate); }
.terms { margin: 0; display: grid; grid-template-columns: minmax(140px, 220px) minmax(0, 1fr); gap: 0; border-top: 1px solid var(--hairline); }
.terms dt { font-weight: 700; padding: 9px 14px 9px 0; border-bottom: 1px solid var(--hairline); color: var(--dark); }
.terms dd { margin: 0; padding: 9px 0; border-bottom: 1px solid var(--hairline); color: var(--slate); }
.file-line { display: flex; gap: 14px; align-items: center; justify-content: space-between; border: 1px solid var(--hairline); border-radius: 8px; padding: 12px 16px; background: var(--cloud); margin: 14px 0 6px; flex-wrap: wrap; }
.file-line .what { min-width: 0; }
.file-line .what strong { display: block; color: var(--dark); }
.file-line .what span { color: var(--grey); font-size: 14px; }
details.slide { border-top: 1px solid var(--hairline); }
details.slide:last-of-type { border-bottom: 1px solid var(--hairline); }
details.slide summary { cursor: pointer; padding: 10px 2px; display: flex; gap: 12px; align-items: baseline; list-style: none; }
details.slide summary::-webkit-details-marker { display: none; }
details.slide summary .n { font: 500 13px var(--display); color: var(--grey); min-width: 2em; }
details.slide summary .t { font-weight: 700; color: var(--dark); }
details.slide[open] summary .t { color: var(--accent-strong); }
details.slide .inside { padding: 0 2px 14px 2.9em; }
.note { background: var(--cloud); border-radius: 6px; padding: 10px 14px; color: var(--slate); font-size: 15px; margin-top: 8px; }
.note b { color: var(--dark); }

.stats { display: flex; flex-wrap: wrap; gap: 0; border: 1px solid var(--hairline); border-radius: 10px; overflow: hidden; margin-bottom: 26px; }
.stats div { flex: 1 1 120px; padding: 14px 18px; border-right: 1px solid var(--hairline); background: #fff; }
.stats div:last-child { border-right: 0; }
.stats b { display: block; font: 700 26px/1.1 var(--display); color: var(--dark); }
.stats span { color: var(--grey); font-size: 14px; }
.weight { display: flex; align-items: center; gap: 10px; min-width: 150px; }
.weight i { display: block; height: 8px; border-radius: 4px; background: var(--accent); }
.toolbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar select, .toolbar input[type=search] { width: auto; min-width: 200px; }
.q { border-top: 1px solid var(--hairline); padding: 16px 0; max-width: 80ch; }
.q .stem { font-weight: 700; color: var(--dark); margin-bottom: 8px; display: flex; gap: 10px; }
.q .stem .n { color: var(--grey); font-weight: 400; min-width: 2.2em; font-variant-numeric: tabular-nums; }
.q ol { margin: 0 0 0 2.9em; padding: 0; list-style: upper-alpha; }
.q li { padding: 3px 6px; border-radius: 4px; margin-bottom: 2px; }
.keys-on .q li.right { background: var(--good-bg); color: var(--good); font-weight: 700; }
.q .why { display: none; margin: 8px 0 0 2.9em; color: var(--slate); font-size: 15px; }
.keys-on .q .why { display: block; }
.lab-card { border: 1px solid var(--hairline); border-radius: 10px; margin-bottom: 14px; overflow: hidden; }
.lab-card > summary { cursor: pointer; padding: 14px 18px; display: flex; gap: 12px; align-items: center; background: var(--cloud); list-style: none; }
.lab-card > summary::-webkit-details-marker { display: none; }
.lab-card > summary h3 { flex: 1; }
.lab-card .inside { padding: 16px 18px; }
.answer { display: none; }
.keys-on .answer { display: revert; }
.files h3 { margin: 26px 0 10px; }
.files h3:first-child { margin-top: 0; }
.file-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 16px; align-items: center; padding: 12px 0; border-top: 1px solid var(--hairline); }
.file-row .t { font-weight: 700; color: var(--dark); }
.file-row .d { color: var(--slate); font-size: 15px; }
.file-row .f { color: var(--grey); font-size: 13.5px; }

/* ---------- admin ---------- */

.drop { border: 2px dashed #B9C7D8; border-radius: 10px; padding: 26px 20px; text-align: center; color: var(--slate); background: var(--cloud); }
.drop.over { border-color: var(--accent); background: var(--ice); }
.drop input[type=file] { display: none; }
.version { border: 1px solid var(--hairline); border-radius: 10px; margin-bottom: 18px; overflow: hidden; }
.version-head { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 14px 18px; background: var(--cloud); border-bottom: 1px solid var(--hairline); }
.version-head h3 { font-size: 18px; }
.version-head .actions { margin-left: auto; }
.version-body { padding: 16px 18px; }
.version-body .table-wrap { margin-bottom: 14px; }
.order-line { display: grid; grid-template-columns: minmax(0, 2.2fr) 90px 120px 150px 36px; gap: 10px; align-items: end; margin-bottom: 10px; }
.order-line .field { margin: 0; }
.progress { height: 8px; border-radius: 4px; background: var(--hairline); overflow: hidden; margin: 12px 0 6px; }
.progress i { display: block; height: 100%; background: var(--accent); width: 0; transition: width 0.2s; }
.swatch { display: inline-block; width: 18px; height: 18px; border-radius: 4px; border: 1px solid rgba(0, 0, 0, 0.15); vertical-align: -4px; margin-right: 6px; }
.logo-prev { background: var(--dark); border-radius: 8px; padding: 14px 18px; display: inline-flex; align-items: center; min-height: 62px; }
.logo-prev img { height: 34px; width: auto; max-width: 200px; object-fit: contain; object-position: left center; }
.codes { max-height: 420px; overflow: auto; }
.bar-mini { display: inline-block; width: 90px; height: 8px; background: var(--hairline); border-radius: 4px; overflow: hidden; vertical-align: 1px; margin-right: 8px; }
.bar-mini i { display: block; height: 100%; background: var(--accent); }

@media (max-width: 900px) {
  .gate { grid-template-columns: 1fr; }
  .gate-side { padding: 32px 24px; min-height: 0; }
  .gate-side h1 { margin-top: 28px; }
  .gate-side .motif, .gate-side .facts { display: none; }
  .gate-form { padding: 32px 24px 56px; }
  .cols { grid-template-columns: 1fr; }
  .side-list { position: static; max-height: none; display: flex; overflow-x: auto; gap: 2px; }
  .side-list button { border-left: 0; border-bottom: 3px solid var(--hairline); white-space: nowrap; }
  .side-list button[aria-current] { border-bottom-color: var(--accent); }
  .kit-row { grid-template-columns: 1fr; }
  .kit-row .go { align-items: flex-start; border-left: 0; border-top: 1px solid var(--hairline); }
  .kit-row .go .until { text-align: left; }
  .grid2, .grid3 { grid-template-columns: 1fr; }
  .span2 { grid-column: auto; }
  .order-line { grid-template-columns: 1fr 1fr; }
  .bar-in { padding: 0 14px; gap: 10px; }
  .bar nav a, .bar nav button { padding: 8px 9px; font-size: 14.5px; }
  .bar nav .me .wide { display: none; }
  .bar nav .me .narrow { display: inline; }
  .brandmark .product { display: none; }
  .brandmark img { height: 28px; max-width: 120px; }
  .ruler-grid { grid-template-columns: repeat(var(--half, 8), minmax(0, 1fr)); row-gap: 10px; }
  main { padding: 24px 16px 60px; }
  .kit-hero-in { padding: 20px 16px 0; }
  .kit-hero h1 { font-size: 24px; }
  .kit-tabs .tabs { padding: 0 10px; }
  .redeem { width: 100%; }
  .redeem input { flex: 1; width: auto; min-width: 0; }
  .terms { grid-template-columns: 1fr; }
  .terms dt { border-bottom: 0; padding-bottom: 0; }
  .file-row { grid-template-columns: 1fr; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print { .bar, .subbar, .kit-tabs, .foot, .toast, .btn { display: none !important; } .kit-hero { background: none; color: #000; } }
.table .link-btn { text-align: left; }
