:root {
  color-scheme: light;
  --paper: #f6f5f1;
  --white: #fff;
  --ink: #201f1d;
  --muted: #5e5a53;
  --line: #dedbd4;
  --accent: #bf3b18;
  --orange: #ff7b52;
  --black: #191817;
  font: 100%/1.6 "Segoe UI", Arial, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); }
[hidden] { display: none !important; }
main { min-height: 70vh; }
a { color: var(--accent); text-underline-offset: .21em; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
:focus-visible { outline: 3px solid #28718f; outline-offset: 4px; }
.skip { position: absolute; top: -80px; left: 1rem; z-index: 4; background: white; padding: .5rem 1rem; }
.skip:focus { top: .5rem; }
.wrap { width: min(1220px, calc(100% - 72px)); margin-inline: auto; }
.masthead { background: var(--paper); border-bottom: 1px solid var(--line); }
.header-inner { min-height: 75px; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--ink); text-decoration: none; font: 800 1rem/1.2 Consolas, monospace; letter-spacing: -.025em; white-space: nowrap; }
.brand-accent { color: var(--accent); }
.chip { display: inline-grid; place-items: center; width: 32px; height: 32px; color: white; background: var(--accent); border-radius: 7px; font-size: 1.3rem; }
.topnav { display: flex; flex-wrap: wrap; gap: .4rem 1.55rem; }
.topnav a { color: var(--muted); padding: .35rem 0; font-size: .94rem; font-weight: 650; text-decoration: none; border-bottom: 2px solid transparent; }
.topnav a:hover, .topnav a[aria-current] { color: var(--accent); border-color: var(--accent); }
.hero { background: #181715; color: white; position: relative; isolation: isolate; overflow: hidden; }
.hero::before { content: ""; background: linear-gradient(90deg,#181715 2%,#181715cc 22%,transparent 76%), url(motherboard.jpg) center 48% / cover; position: absolute; z-index: -1; inset: 0 0 0 38%; }
.hero-inner { display: flex; align-items: center; min-height: 466px; padding-block: 4rem; }
.hero-copy { max-width: 690px; }
.eyebrow { color: var(--accent); font: 700 .88rem/1.4 Consolas, monospace; letter-spacing: .105em; text-transform: uppercase; margin: 0 0 1.1rem; }
.hero .eyebrow { color: #ff9b7c; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.12; letter-spacing: -.035em; }
h1 { font-size: clamp(2.35rem, 5.2vw, 4.5rem); margin-bottom: 1.15rem; }
.hero h1 { color: white; max-width: 11ch; line-height: 1; }
.hero h1 span { color: var(--orange); }
.hero p:not(.eyebrow) { max-width: 37ch; color: #e3ded7; }
.lead { font-size: clamp(1.06rem, 2vw, 1.25rem); color: var(--muted); max-width: 68ch; }
h2 { font-size: clamp(1.65rem, 3vw, 2.55rem); margin-bottom: .8rem; }
h3 { font-size: 1.26rem; margin-bottom: .45rem; }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: .7rem; margin-top: 1.45rem; }
.btn { display: inline-flex; align-items: center; justify-content: center; padding: .63rem 1rem; min-height: 44px; background: var(--black); color: white; border: 1px solid var(--black); border-radius: 7px; text-decoration: none; font-weight: 650; font-size: .94rem; }
.btn:hover { background: #3c3833; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: white; }
.btn.primary:hover { background: #9f2b0b; }
.btn.ghost { background: transparent; border-color: #aaa49a; color: inherit; }
.btn.ghost:hover { border-color: currentColor; }
.btn:disabled { opacity: .55; cursor: default; }
.section { padding-block: 3.1rem; }
.page-head { padding: 3.3rem 0 1.5rem; }
.page-head h1 { font-size: clamp(2.25rem, 5vw, 3.8rem); }
.section-head { display: flex; gap: 1rem; align-items: baseline; justify-content: space-between; margin-bottom: .9rem; }
.tile, .panel, .assignment { background: var(--white); border: 1px solid var(--line); border-radius: 10px; }
.tile, .assignment { padding: 1rem 1.15rem; }
a.tile, a.assignment { text-decoration: none; color: inherit; }
a.tile:hover, a.assignment:hover { border-color: var(--accent); }
.tile-icon { display: block; color: var(--accent); margin-bottom: .62rem; font: 700 1.15rem/1.4 Consolas, monospace; }
.assignment small, .muted { color: var(--muted); }
.tile strong { display: block; margin-bottom: .25rem; }
.home-grid { display: grid; gap: 1rem; grid-template-columns: repeat(2,minmax(0,1fr)); }
.subject-tile { padding: 1.45rem; }
.subject-tile h3 { font-size: clamp(1.35rem, 2.1vw, 2rem); }
.subject-tile p { color: var(--muted); max-width: 45ch; }
.subject-link { color: var(--accent); font-weight: 700; }
.subject-content, .doc-nav { padding-bottom: 3rem; }
.status-note { color: #934027; font-weight: 750; }
.grid-lab { display: grid; gap: .65rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr)); }
.panel { padding: 1.25rem; min-width: 0; }
.panel > :last-child { margin-bottom: 0; }
label { display: grid; gap: .28rem; font-size: .95rem; font-weight: 650; }
input, select, textarea { width: 100%; padding: .57rem .7rem; min-height: 44px; border: 1px solid #aaa49a; border-radius: 6px; background: white; color: var(--ink); }
select { appearance: none; padding-right: 2rem; background: linear-gradient(45deg, transparent 50%, #514842 50%) right 1.1rem center / 5px 5px no-repeat, linear-gradient(135deg,#514842 50%,transparent 50%) right .8rem center / 5px 5px no-repeat, white; }
textarea { min-height: 8rem; }
.groups { display: grid; gap: 1.7rem; }
.assignments { display: grid; gap: .65rem; grid-template-columns: repeat(3,minmax(0,1fr)); }
.assignment strong { display: block; }
.doc { max-width: 960px; }
.doc .panel { padding: clamp(1rem, 3vw, 2rem); }
.doc h2 { margin-top: 1.6rem; font-size: 1.45rem; }
.doc h2:first-child { margin-top: 0; }
.doc p { max-width: 77ch; }
.table-scroll { overflow: auto; margin: 1rem 0; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { border-bottom: 1px solid var(--line); padding: .6rem .72rem; vertical-align: top; }
th { background: #efede8; }
pre { overflow: auto; background: #24211f; color: #fbf6ef; border-radius: 7px; padding: 1rem; font-size: .9rem; }
.diagram-figure { margin: 1rem 0 1.4rem; }
.diagram-image { display: block; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; cursor: zoom-in; }
.diagram-image:hover { border-color: var(--accent); }
.diagram-image img { display: block; width: 100%; height: auto; }
.diagram-figure figcaption { color: var(--muted); margin-top: .55rem; }
.diagram-figure figcaption a { display: inline-block; font-weight: 650; }
.result { margin: .65rem 0 0; min-height: 1.5em; overflow-wrap: anywhere; }
.demo-form { display: grid; gap: .8rem; }
.demo-form .actions { margin-top: 0; }
.demo-swatch { padding: .75rem; border-radius: .35rem; font-weight: 700; background: #171717; color: white; }
.demo-swatch[data-tone="red"] { background: #9e321c; }
.demo-swatch[data-tone="blue"] { background: #184e87; }
.demo-swatch[data-tone="green"] { background: #1b633b; }
.footer { display: flex; gap: 1rem; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); padding-block: 1.55rem; color: var(--muted); }
@media(max-width: 900px) {
  .wrap { width: calc(100% - 40px); }
  .assignments { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .topnav { gap: .35rem .9rem; }
}
@media(max-width: 640px) {
  .wrap { width: calc(100% - 30px); }
  .header-inner { display: block; padding-block: .75rem; }
  .topnav { margin-top: .5rem; }
  .topnav a { font-size: .87rem; }
  .hero::before { inset: 0; background: linear-gradient(90deg,#181715ed,#1817158c), url(motherboard.jpg) 65% 50% / cover; }
  .hero-inner { min-height: 392px; padding-block: 2.75rem; }
  .home-grid, .assignments { grid-template-columns: minmax(0,1fr); }
  .section { padding-block: 2rem; }
  .section-head { display: block; }
  .footer { align-items: flex-start; flex-wrap: wrap; }
}
@media print {
  .masthead, .footer, .actions, .skip { display: none; }
  .wrap { width: 100%; }
  body, .panel { background: white; }
}
