@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&display=swap');

/* ============================================================
   Recolor pydata-sphinx-theme primary chrome to DFEC navy.
   ----------------------------------------------------------
   The theme's default `--pst-color-primary` is a teal (#0a7d91)
   that drives the sidebar-toggle, article-header buttons, the
   search-button keycap hints, and link color. We retarget it
   onto the DFEC palette so all chrome reads as one family.
   ============================================================ */
html[data-theme="light"],
html {
  --pst-color-primary:    #00205B;
  --pst-color-primary-bg: #eef3fb;
  --pst-color-link:       #1f6098;
  --pst-color-link-hover: #00205B;
  --pst-color-inline-code-links: #1f6098;
  /* --pst-color-accent drives the focus box-shadow on the Cmd+K
     search-modal input. Default is a magenta (#c132af) that clashes
     with the DFEC navy/blue palette; retarget to DFEC mid-blue. */
  --pst-color-accent:     #1f6098;
}

/* ============================================================
   ECE 215/S — DFEC palette (ported from ECE 495)
   ============================================================
   --tps-navy   : #00205B    (primary, brand)
   --tps-mid    : #1f6098    (accent / borders / table headers)
   --tps-light  : #1f5c8b    (h3 left border)
   --tps-bg     : #eef3fb    (key concept background)
   --tps-bg-alt : #f0f7ff    (example/table even rows)
   --tps-edge   : #c8ddef    (light divider)
   --tps-edge-2 : #a8c8e8    (medium divider)
*/

/* ============================================================
   Typography
   ============================================================ */

body, .bd-article {
  font-family: 'Inter', sans-serif;
}

/* ============================================================
   Heading Styles
   ============================================================ */

.bd-article h1 {
  color: #00205B;
  font-weight: 800;
  letter-spacing: -0.01em;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
}
.bd-article h1::after {
  content: '';
  display: block;
  width: 2.5em;
  height: 4px;
  background-color: #1f6098;
  border-radius: 2px;
  margin-top: 0.4em;
  margin-bottom: 0.5em;
}

.bd-article h2 {
  color: #00205B;
  font-weight: 700;
  border-bottom: 1px solid #c8ddef;
  padding-bottom: 0.2em;
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.2;
}

.bd-article h3 {
  color: #1f5c8b;
  font-weight: 600;
  border-left: 4px solid #1f6098;
  padding-left: 0.65em;
  font-size: 18px;
  line-height: 1.25;
}

/* Inline code styling (consumes JetBrains Mono, navy on --tps-bg) */
.bd-article :not(pre) > code {
  background-color: #eef3fb;
  color: #00205B;
  padding: 0.1em 0.4em;
  border-radius: 3px;
  font-family: 'JetBrains Mono', 'Menlo', 'Consolas', monospace;
  font-size: 0.86em;
  font-weight: 500;
}

/* ============================================================
   Textbook Callout Styles
   ============================================================ */

/* --- Key Concept boxes ------------------------------------ */
.admonition.key-concept,
div.admonition.key-concept {
  border: 1px solid #b8c9e8 !important;
  border-left: 5px solid #00205B !important;
  border-radius: 0 6px 6px 0 !important;
  background-color: #eef3fb !important;
  padding: 0 !important;
  overflow: hidden;
  margin: 1.5em 0;
  box-shadow: none !important;
}
.admonition.key-concept > .admonition-title,
div.admonition.key-concept > p.admonition-title {
  background-color: #00205B !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  font-size: 0.85em !important;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4em 1em !important;
  margin: 0 !important;
}
/* Aggressively suppress the theme's bell/warning icon on Key Concept titles */
.admonition.key-concept > .admonition-title::before,
div.admonition.key-concept > p.admonition-title::before,
.admonition.key-concept > .admonition-title::after,
div.admonition.key-concept > p.admonition-title::after {
  content: none !important;
  display: none !important;
  width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  background: none !important;
}
.admonition.key-concept > *:not(.admonition-title),
div.admonition.key-concept > *:not(.admonition-title) {
  padding: 0.75em 1.5em !important;
  margin: 0 !important;
}

/* --- Callout list breathing room --------------------------- */
/* Bump padding-left on ordered / unordered lists inside any of the
   four callout cards so the list markers ("1.", "•") don't crowd
   the colored left border. Higher specificity than the body padding
   rules below so it actually wins. */
.bd-article .admonition.key-concept > ol,
.bd-article .admonition.key-concept > ul,
.bd-article .admonition.example-problem > ol,
.bd-article .admonition.example-problem > ul,
.bd-article .admonition.type-along > ol,
.bd-article .admonition.type-along > ul,
.bd-article .admonition.ground-rules > ol,
.bd-article .admonition.ground-rules > ul,
.bd-article div.admonition.key-concept > ol,
.bd-article div.admonition.key-concept > ul,
.bd-article div.admonition.example-problem > ol,
.bd-article div.admonition.example-problem > ul,
.bd-article div.admonition.type-along > ol,
.bd-article div.admonition.type-along > ul,
.bd-article div.admonition.ground-rules > ol,
.bd-article div.admonition.ground-rules > ul {
  padding-left: 2.6em !important;
}

/* --- Type-along boxes (mid-blue) -------------------------- */
.admonition.type-along,
div.admonition.type-along {
  border: 1px solid #a8c8e8 !important;
  border-left: 5px solid #1f6098 !important;
  border-radius: 0 6px 6px 0 !important;
  background-color: #f6fbff !important;
  padding: 0 !important;
  overflow: hidden;
  margin: 1.5em 0;
  box-shadow: none !important;
}
.admonition.type-along > .admonition-title,
div.admonition.type-along > p.admonition-title {
  background-color: #1f6098 !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  font-size: 0.85em !important;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4em 1em !important;
  margin: 0 !important;
}
.admonition.type-along > .admonition-title::before,
div.admonition.type-along > p.admonition-title::before,
.admonition.type-along > .admonition-title::after,
div.admonition.type-along > p.admonition-title::after {
  content: none !important;
  display: none !important;
  width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  background: none !important;
}
.admonition.type-along > *:not(.admonition-title),
div.admonition.type-along > *:not(.admonition-title) {
  padding: 0.5em 1.5em !important;
  margin: 0 !important;
}
/* Make the nested Solution dropdown read as a child of the exercise. */
.admonition.type-along .admonition.dropdown {
  margin: 0.5em 0 0 !important;
  border-radius: 4px !important;
}

/* --- Example Problem boxes -------------------------------- */
div.admonition.example-problem {
  border: 1px solid #ddb896;
  border-left: 5px solid #7b3000;
  border-radius: 0 6px 6px 0;
  background-color: #fdf6f1;
  padding: 0;
  overflow: hidden;
  margin: 1.5em 0;
}
div.admonition.example-problem > p.admonition-title {
  background-color: #7b3000;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.85em;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4em 1em;
  margin: 0;
}
div.admonition.example-problem > p.admonition-title::before {
  display: none;
}
div.admonition.example-problem > *:not(.admonition-title) {
  padding: 0.5em 1.5em 0.25em 1.5em;
  margin: 0;
}

/* ============================================================
   Table Styles
   ============================================================ */

.bd-article table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.95em;
  margin: 1.25em 0;
}
.bd-article table thead tr {
  background-color: #1f6098;
}
/* One header treatment for every table in the book: same size, weight,
   letter-spacing and padding, whether or not the table is a .dfec-table.
   text-transform is the one property that is NOT shared -- see below. */
.bd-article table thead th {
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 0.7em 0.8em;
  border: none;
  text-align: left;
  vertical-align: middle;
}

/* Uppercase is confined to the schedule and objectives tables, whose headers
   are plain words. It is NOT applied book-wide because six headers in the
   readings and labs carry notation that text-transform corrupts:

     vin(t) - Input from Control Unit  ->  VIN(T) - ...
     vout(t), Gauge Input*             ->  VOUT(T), ...
     Input amplitude (Vpp)             ->  ... (VPP)
     Output amplitude (Vpp)            ->  ... (VPP)
     Mass (g)                          ->  MASS (G)     (grams, not G)
     MTBF (hr)                         ->  MTBF (HR)

   Lowercase v is instantaneous voltage and (t) is the time variable, so
   VIN(T) is wrong in a signals course -- a content error, not a style one.
   CSS cannot select on cell text, so the split is by table role instead. */
.dfec-table table thead th { text-transform: uppercase; }
.bd-article table tbody td {
  padding: 0.45em 0.85em;
  border-bottom: 1px solid #a8c8e8;
  color: #000000 !important;
  text-wrap: pretty;
}
.bd-article table tbody tr:nth-child(even) {
  background-color: #f0f7ff;
}
.bd-article table tbody tr:hover {
  background-color: #eef3fb;
  box-shadow: inset 3px 0 0 #1f6098;
}
.bd-article table tbody tr:nth-child(even) td,
.bd-article table tbody tr:hover td {
  color: #000000 !important;
}

/* ============================================================
   Flashcard Styles
   ============================================================ */

.bd-article details {
  border: 1px solid #b8cfe8;
  border-left: 5px solid #00205B;
  border-radius: 0 6px 6px 0;
  margin: 0.6em 0;
  overflow: hidden;
}
.bd-article details summary {
  background-color: #00205B;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.95em;
  padding: 0.55em 1.1em;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.6em;
}
.bd-article details summary::-webkit-details-marker { display: none; }
.bd-article details summary::before {
  content: '\25B6';
  font-size: 0.7em;
  transition: transform 0.2s;
  flex-shrink: 0;
}
.bd-article details[open] summary::before { transform: rotate(90deg); }
.bd-article details .card-answer {
  background-color: #eef3fb;
  padding: 0.75em 1.5em;
  color: #212529;
}
.bd-article .card-answer ol { margin: 0.4em 0 0.4em 1.4em; }
.bd-article .card-answer p  { margin: 0.5em 0; }

/* ============================================================
   Page-width utilities
   ============================================================ */

.wide-page .bd-main .bd-content,
.wide-page .bd-main .bd-content .bd-article-container,
.wide-page .bd-main .bd-content .bd-article {
  max-width: 100% !important;
}

.wide-page .bd-container {
  max-width: 100% !important;
}

.full-width {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

/* ============================================================
   Embedded media
   ============================================================ */

.bd-article video {
  max-width: 100%;
  border-radius: 6px;
  margin: 1em 0;
}

.bd-article iframe.pdf-embed {
  width: 100%;
  height: 80vh;
  border: 1px solid #c8ddef;
  border-radius: 6px;
}

/* ============================================================
   Sidebar TOC — match ECE-315 / sphinx-book-theme look on the
   globaltoc.html output that we use to render the FULL nav tree
   on every page. The sbt-sidebar-shim.js adds <details>/<summary>
   chevron wrappers; this CSS styles them.
   ============================================================ */

/* The globaltoc heading is repurposed as a Home link by the JS shim
   (see sbt-sidebar-shim.js). Show only the tagged variant. */
.sy-globaltoc > h3 { display: none; }
.sy-globaltoc > h3.sy-globaltoc-home {
  display: block;
  margin: 0 0 0.6em 0;
  padding: 0;
  font-size: 0.9em;
  font-weight: 500;
}
.sy-globaltoc > h3.sy-globaltoc-home a {
  display: block;
  padding: 0.4em 1.6em 0.4em 0.5em;
  color: #495057;
  text-decoration: none;
  border-left: 3px solid transparent;
}
.sy-globaltoc > h3.sy-globaltoc-home a:hover {
  background: #f4f7fb;
  color: #1f6098;
}
.sy-globaltoc > h3.sy-globaltoc-home.current a,
.sy-globaltoc > h3.sy-globaltoc-home a.current {
  color: #1f6098;
  border-left-color: #1f6098;
  font-weight: 600;
}

/* Caption rows ("Block 1", "Block 2", ...) */
.sy-globaltoc p.caption {
  font-weight: 700;
  font-size: 0.9em;
  color: #212529;
  margin: 1.2em 0 0.4em 0;
  padding: 0;
  text-transform: none;
}

/* Top-level UL: kill default bullet marks, indent */
.sy-globaltoc ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

/* Top-level lessons */
.sy-globaltoc li.toctree-l1 {
  position: relative;
  padding: 0;
  margin: 0;
}
.sy-globaltoc li.toctree-l1 > a {
  display: block;
  padding: 0.4em 1.6em 0.4em 0.5em;
  color: #495057;
  text-decoration: none;
  border-left: 3px solid transparent;
  font-weight: 500;
  font-size: 0.9em;
  line-height: 1.35;
}
.sy-globaltoc li.toctree-l1 > a:hover {
  background: #f4f7fb;
  color: #1f6098;
}

/* Active top-level lesson: blue text + blue left bar */
.sy-globaltoc li.toctree-l1.current > a,
.sy-globaltoc li.toctree-l1 > a.current {
  color: #1f6098;
  border-left-color: #1f6098;
  font-weight: 600;
  background: transparent;
}

/* Chevron toggle: position absolute on the right of each l1 row */
.sy-globaltoc li.toctree-l1.has-children > details > summary {
  position: absolute;
  top: 0;
  right: 0;
  padding: 0.4em 0.6em;
  cursor: pointer;
  list-style: none;
  color: #6c757d;
  background: transparent;
  border: none;
  font-size: 0.85em;
}
.sy-globaltoc li.toctree-l1.has-children > details > summary::-webkit-details-marker {
  display: none;
}
.sy-globaltoc li.toctree-l1.has-children > details > summary i {
  transition: transform 0.2s ease;
}
.sy-globaltoc li.toctree-l1.has-children > details[open] > summary i {
  transform: rotate(180deg);
}
.sy-globaltoc li.toctree-l1.has-children > details > summary:hover {
  color: #1f6098;
}

/* Sub-items (Lesson sub-pages) */
.sy-globaltoc li.toctree-l2 {
  margin: 0;
}
.sy-globaltoc li.toctree-l2 > a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.3em 0.5em 0.3em 1.5em;
  color: #6c757d;
  text-decoration: none;
  font-size: 0.85em;
  line-height: 1.35;
  border-left: 4px solid transparent;
}
.sy-globaltoc li.toctree-l2 > a:hover {
  background: #f4f7fb;
  color: #1f6098;
}
.sy-globaltoc li.toctree-l2 > a.current,
.sy-globaltoc li.toctree-l2.current > a {
  color: #1f6098;
  font-weight: 600;
  background: #eef3fb;
  border-left-color: #1f6098;
}

/* Sidebar l2 glyphs (Reading / Flashcards / Slides / Practice / Demo).
   Demo shares the violet of the .bt-demo card accent — the one kind that
   leaves the book for usafa-ece.org. */
.sy-globaltoc .sy-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: currentColor;
}
.sy-globaltoc li.sy-l2-reading    > a .sy-icon { color: #1f6098; }
.sy-globaltoc li.sy-l2-flashcards > a .sy-icon { color: #14a8c8; }
.sy-globaltoc li.sy-l2-slides     > a .sy-icon { color: #1d7a4d; }
.sy-globaltoc li.sy-l2-practice   > a .sy-icon { color: #8a5a00; }
.sy-globaltoc li.sy-l2-demo       > a .sy-icon { color: #6a3d9a; }
.sy-globaltoc li.toctree-l2.current > a .sy-icon { color: #1f6098; }

/* Hide toctree details summary's default UA list-style triangle */
.sy-globaltoc details > summary { list-style: none; }
.sy-globaltoc details > summary::marker { content: ""; }

/* ============================================================
   Disable the dark-mode theme switcher.
   default_mode: light is set in _config.yml, so the page renders
   in light mode by default. Hiding the toggle removes the option
   for users to switch (the dark mode styles don't play well with
   our hardcoded DFEC palette).
   ============================================================ */
.theme-switch-button,
button.theme-switch-button,
.bd-header .theme-switch-button,
.bd-header-article .theme-switch-button,
.header-article-items .theme-switch-button,
.navbar-header-items .theme-switch-button,
nav .theme-switch-button {
  display: none !important;
  visibility: hidden !important;
  width: 0 !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  pointer-events: none !important;
}

/* ============================================================
   Demo iframe "open in full screen" link.
   Add a `.demo-fullscreen` link right before each demo iframe
   so users can pop the demo out into its own tab.
   ============================================================ */
.demo-fullscreen {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  margin: 0 0 6px;
  background: #f6f8fa;
  border: 1px solid #d8e2ec;
  border-radius: 4px;
  color: #00205B !important;
  font-size: 0.85em;
  font-weight: 500;
  text-decoration: none !important;
  transition: background 0.12s ease;
}
.demo-fullscreen:hover {
  background: #e9eef5;
  border-color: #1f6098;
}
.demo-fullscreen::before {
  content: "↗";
  font-weight: 700;
  color: #1f6098;
}

/* ============================================================
   MATLAB cross-reference chip
   ============================================================ */
.bd-article .matlab-link {
  display: inline-flex;
  align-items: center;
  gap: 0;
  padding: 8px 14px;
  margin: 0.4em 0 0.6em;
  background: #fff7ed;
  border: 1px solid #f3c89a;
  border-radius: 5px;
  color: #7b3000 !important;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none !important;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.bd-article .matlab-link:hover {
  background: #fdf0dc;
  border-color: #e87722;
}
.bd-article .matlab-link .ml-text {
  font-variant-numeric: tabular-nums;
}
.bd-article .matlab-link .ml-text code,
.bd-article .matlab-link code {
  background: transparent;
  color: inherit;
  padding: 0;
  font-size: 0.95em;
}
.bd-article .matlab-link .ml-arrow {
  margin-left: 10px;
  font-weight: 700;
  color: #e87722;
}

/* ============================================================
   Figures (inline reading figures)
   ============================================================ */
.bd-article figure {
  margin: 1.5em 0;
  padding: 10px 12px 6px;
  background: #fff;
  border: 1px solid var(--tps-rule, #d8e2ec);
  border-radius: 8px;
}
.bd-article figure > img,
.bd-article figure > picture > img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}
.bd-article figure figcaption {
  color: var(--ink-3, #5b6573);
  font-size: 0.92em;
  font-style: italic;
  margin-top: 8px;
  padding: 0 4px;
  text-wrap: pretty;
}

/* ============================================================
   Demo iframe wrapper (auto-height handshake)
   ============================================================
   Demo HTMLs call SY.iframe.publishHeight() and post their
   scrollHeight to the parent. iframe-resize-parent.js sets the
   matching iframe.height, so the value below is just a sane
   fallback while the first message is in flight.
   ============================================================ */
.bd-article .demo-wrap {
  margin: 0.5em 0;
}
.bd-article .demo-wrap iframe {
  width: 100%;
  min-height: 480px;
  border: 1px solid var(--tps-rule, #d8e2ec);
  border-radius: 8px;
  display: block;
  margin: 0;
}

/* ============================================================
   Per-block dashboard (blockNN/index.md)
   ============================================================ */
.bd-article .block-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: -8px 0 18px;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.10em;
  color: #5b6573;
  font-weight: 600;
}
.bd-article .block-meta .b-block {
  color: #00205B;
  padding: 2px 8px;
  background: #eef3fb;
  border-radius: 3px;
  letter-spacing: 0.08em;
}
.bd-article .block-meta .b-time,
.bd-article .block-meta .b-demos {
  display: inline-flex;
  align-items: center;
}
.bd-article .block-meta .b-time::before {
  content: "○ ";
  color: #a8c8e8;
  margin-right: 4px;
}
.bd-article .block-meta .b-demos::before {
  content: "▶ ";
  color: #1d7a4d;
  margin-right: 4px;
}
.bd-article .block-synopsis {
  font-size: 17px;
  line-height: 1.55;
  color: #3b4651;
  max-width: 68ch;
  margin: 0 0 22px;
}

/* "What you'll learn" list: the objective code IS the marker.
   _gen_lessons.py emits a bullet list wrapped in :::{container} obj-list --
   an ordered list would print an auto ordinal in front of the code
   ("1. **1.1** — ..."), which is what this replaces.

   padding-left cancels the browser's 40px list indent so the codes line up
   with the synopsis above; the li then re-adds it as a hanging indent
   (padding-left + equal negative text-indent). 3.2em is measured, not
   guessed: the markers render 45.8-51.2px at the 16px body size, so 3.2em
   (51.2px) is the tightest column that clears the widest of them -- eight of
   the nine Block 3 items then wrap within 2px of where their first line
   starts. The figures are proportional, so "3.1" is the narrow outlier.
   text-indent is inherited by the <p> docutils puts inside each <li>, which
   is where it actually takes effect.

   Scoped to .obj-list, so no other list in the book is touched. Geometry
   and spacing only -- color and type come from the body rules. */
.bd-article .obj-list ul {
  list-style: none;
  padding-left: 0;
  margin: 0 0 22px;
}
.bd-article .obj-list li {
  padding-left: 3.2em;
  text-indent: -3.2em;
  margin-bottom: 0.45em;
}

.bd-article .block-toc {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0 8px;
}
@media (max-width: 720px) {
  .bd-article .block-toc { grid-template-columns: 1fr; }
}
.bd-article .bt-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 14px 16px 12px 18px;
  background: #fff;
  border: 1px solid var(--tps-rule, #d8e2ec);
  border-left: 4px solid #1f6098;
  border-radius: 0 6px 6px 0;
  color: var(--ink, #15202b) !important;
  text-decoration: none !important;
  transition: border-color 0.12s ease, background 0.12s ease;
}
.bd-article .bt-card:hover {
  background: #f8fbff;
  border-color: #1f6098;
  border-left-color: #00205B;
}
.bd-article .bt-card .bt-kind {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.10em;
  color: #5b6573;
  margin-bottom: 2px;
}
.bd-article .bt-card h4 {
  margin: 2px 0 4px;
  font-size: 15px;
  font-weight: 700;
  color: #00205B;
}
.bd-article .bt-card p {
  margin: 0;
  font-size: 13px;
  color: #3b4651;
  line-height: 1.45;
}
/* Card kind colors. bt-demo is the odd one out: it is the only card that
   leaves the book, linking an interactive demo on usafa-ece.org, so it gets a
   hue of its own instead of reusing one of the four in-book kinds. Violet
   because blue, cyan, green and amber are taken and the warm end is already
   spoken for by the example-problem and MATLAB accents (#7b3000 / #e87722).
   Not magenta -- this file already rejects that as a clash; see the
   --pst-color-accent note at the top. #6a3d9a reads 7.6:1 on white, inside the
   4.0-6.6:1 band the other four .bt-kind labels already sit in. */
.bd-article .bt-card.bt-reading    { border-left-color: #1f6098; }
.bd-article .bt-card.bt-flashcards { border-left-color: #14a8c8; }
.bd-article .bt-card.bt-slides     { border-left-color: #1d7a4d; }
.bd-article .bt-card.bt-practice   { border-left-color: #8a5a00; }
.bd-article .bt-card.bt-demo       { border-left-color: #6a3d9a; }
.bd-article .bt-card.bt-reading .bt-kind    { color: #1f6098; }
.bd-article .bt-card.bt-flashcards .bt-kind { color: #0c8aa5; }
.bd-article .bt-card.bt-slides .bt-kind     { color: #1d7a4d; }
.bd-article .bt-card.bt-practice .bt-kind   { color: #8a5a00; }
.bd-article .bt-card.bt-demo .bt-kind       { color: #6a3d9a; }

.bd-article .block-nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin: 28px 0 8px;
  padding: 14px 0 0;
  border-top: 1px solid var(--tps-rule, #d8e2ec);
  font-size: 13.5px;
}
.bd-article .block-nav a {
  color: #1f6098;
  text-decoration: none;
  font-weight: 600;
}
.bd-article .block-nav a:hover { color: #00205B; }
.bd-article .block-nav .block-nav-prev { margin-right: auto; }
.bd-article .block-nav .block-nav-next { margin-left:  auto; text-align: right; }

/* ============================================================
   Breadcrumb (above page title on interior pages)
   ============================================================ */
.bd-article .sy-breadcrumb {
  margin: 0 0 8px;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.10em;
  font-weight: 600;
  color: #5b6573;
  text-wrap: pretty;
}
.bd-article .sy-breadcrumb a {
  color: #1f6098;
  text-decoration: none;
}
.bd-article .sy-breadcrumb a:hover {
  color: #00205B;
  text-decoration: underline;
}
.bd-article .sy-breadcrumb .sep {
  color: #a8c8e8;
  margin: 0 6px;
}

/* ============================================================
   Hero section (intro page)
   ============================================================ */
.bd-article .hero {
  position: relative;
  margin: 0 0 28px;
  padding: 40px 44px 44px;
  background:
    radial-gradient(ellipse at top right, rgba(31, 96, 152, 0.20), transparent 55%),
    linear-gradient(180deg, #001541 0%, #00205B 60%, #002a76 100%);
  color: #fff;
  border-radius: 10px;
  overflow: hidden;
}
.bd-article .hero::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 6px;
  background: linear-gradient(90deg, #1f6098 0%, #4a8fce 50%, #1f6098 100%);
}
.bd-article .hero .hero-eyebrow {
  margin: 0 0 12px;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.78);
}
.bd-article .hero h1.hero-title {
  color: #fff;
  font-size: clamp(28px, 4.2vw, 44px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0 0 12px;
  max-width: 18ch;
}
/* Suppress the normal h1::after underline inside the hero. */
.bd-article .hero h1.hero-title::after { display: none; }
.bd-article .hero .hero-lede {
  margin: 0 0 22px;
  font-size: 17px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.86);
  max-width: 50ch;
}
.bd-article .hero .hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.bd-article .hero .cta {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff !important;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none !important;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.bd-article .hero .cta:hover {
  background: rgba(255, 255, 255, 0.10);
  border-color: rgba(255, 255, 255, 0.65);
}
.bd-article .hero .cta-primary {
  background: #1f6098;
  border-color: #1f6098;
}
.bd-article .hero .cta-primary:hover {
  background: #2c75b3;
  border-color: #2c75b3;
}
@media (max-width: 720px) {
  .bd-article .hero {
    padding: 28px 24px 32px;
  }
}

/* ============================================================
   Block grid (intro page)
   ============================================================ */
/* ECE 215 has three blocks, not the four ECE 495 had, so a fixed 2-column grid
   would strand the third card alone on a second row. Auto-fit keeps all three
   on one row when there is width for it and degrades gracefully. */
.bd-article .block-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  margin: 28px 0;
}
@media (max-width: 560px) {
  .bd-article .block-grid { grid-template-columns: 1fr; }
}
.bd-article .block-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 16px 18px 14px;
  background: #fff;
  border: 1px solid var(--tps-rule, #d8e2ec);
  border-radius: 8px;
  color: var(--ink, #15202b) !important;
  text-decoration: none !important;
  transition: border-color 0.12s ease, transform 0.12s ease, box-shadow 0.12s ease;
}
.bd-article .block-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: #00205B;
  border-radius: 8px 8px 0 0;
}
.bd-article .block-card:hover {
  border-color: #1f6098;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 32, 91, 0.08);
}
.bd-article .block-card .num {
  font-family: 'JetBrains Mono', 'Menlo', monospace;
  font-size: 11px;
  color: #5b6573;
  font-weight: 600;
  letter-spacing: 0.08em;
}
.bd-article .block-card h3 {
  margin: 4px 0 6px;
  font-size: 16px;
  font-weight: 700;
  color: #00205B;
  border-left: none;
  padding-left: 0;
}
.bd-article .block-card p {
  margin: 0 0 12px;
  font-size: 13.5px;
  color: #3b4651;
  line-height: 1.45;
  flex: 1;
}
.bd-article .block-card footer {
  font-size: 11px;
  color: #1d7a4d;
  font-weight: 600;
  letter-spacing: 0.04em;
}

/* ============================================================
   Deliverable cards (intro page)
   ============================================================ */
.bd-article .deliverable-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 28px 0;
}
@media (max-width: 720px) {
  .bd-article .deliverable-cards { grid-template-columns: 1fr; }
}
.bd-article .deliverable-card {
  border: 1px solid var(--tps-rule, #d8e2ec);
  border-left: 5px solid #00205B;
  border-radius: 0 8px 8px 0;
  padding: 16px 20px 14px;
  background: #f8fbff;
}
.bd-article .deliverable-card .d-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 600;
  color: #1f6098;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.bd-article .deliverable-card h3 {
  margin: 4px 0 10px;
  font-size: 22px;
  font-weight: 700;
  color: #00205B;
  border-left: none;
  padding-left: 0;
}
.bd-article .deliverable-card .d-weight {
  margin: 0 0 4px;
  font-size: 13px;
  color: #3b4651;
}
.bd-article .deliverable-card .d-weight .d-w-num {
  font-weight: 700;
  color: #00205B;
  font-size: 17px;
  font-variant-numeric: tabular-nums;
  margin-right: 4px;
}
.bd-article .deliverable-card .d-due {
  margin: 0 0 12px;
  font-size: 13px;
  color: #3b4651;
}
.bd-article .deliverable-card .d-due strong {
  color: #00205B;
  font-weight: 700;
}
.bd-article .deliverable-card .d-link {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: #1f6098;
  text-decoration: none;
}
.bd-article .deliverable-card .d-link:hover {
  text-decoration: underline;
  color: #00205B;
}
.bd-article .deliverable-card .d-link-muted {
  color: #1d7a4d;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 11px;
}
.bd-article .deliverable-card .d-link-muted:hover {
  text-decoration: none;
  color: #1d7a4d;
}

/* ============================================================
   Ground-rules callout (rust accent, like example-problem)
   ============================================================ */
.admonition.ground-rules,
div.admonition.ground-rules {
  border: 1px solid #ddb896 !important;
  border-left: 5px solid #7b3000 !important;
  border-radius: 0 6px 6px 0 !important;
  background-color: #fdf6f1 !important;
  padding: 0 !important;
  overflow: hidden;
  margin: 1.5em 0;
  box-shadow: none !important;
}
.admonition.ground-rules > .admonition-title,
div.admonition.ground-rules > p.admonition-title {
  background-color: #7b3000 !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  font-size: 0.85em !important;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4em 1em !important;
  margin: 0 !important;
}
.admonition.ground-rules > .admonition-title::before,
div.admonition.ground-rules > p.admonition-title::before,
.admonition.ground-rules > .admonition-title::after,
div.admonition.ground-rules > p.admonition-title::after {
  content: none !important;
  display: none !important;
  width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  background: none !important;
}
.admonition.ground-rules > *:not(.admonition-title),
div.admonition.ground-rules > *:not(.admonition-title) {
  padding: 0.75em 1.5em !important;
  margin: 0 !important;
}

/* ============================================================
   Download cards (Downloads page)
   ============================================================ */
.bd-article .dl-row {
  display: flex;
  flex-direction: column;
  gap: 0.6em;
  margin: 1em 0;
}
.bd-article .dl-card {
  border: 1px solid #c8ddef;
  border-left: 5px solid #00205B;
  border-radius: 0 6px 6px 0;
  padding: 0.85em 1.2em;
  background: #f8fbff;
}
.bd-article .dl-card a.dl-link {
  display: inline-block;
  color: #00205B;
  font-weight: 600;
  font-size: 0.95em;
  text-decoration: none;
  margin-top: 0.15em;
}
.bd-article .dl-card a.dl-link:hover {
  text-decoration: underline;
  color: #1f6098;
}
.bd-article .dl-meta {
  color: #5a6772;
  font-size: 0.82em;
  margin-left: 0.4em;
}
.bd-article .dl-summary {
  margin: 0.4em 0 0.5em 0;
  color: #2a3340;
  font-size: 0.93em;
}

/* ============================================================
   Reference tags (Additional References page)
   ============================================================ */
.bd-article .ref-tag {
  display: inline-block;
  background: #eef3fb;
  color: #00205B;
  font-weight: 600;
  font-size: 0.78em;
  padding: 0.15em 0.55em;
  border-radius: 4px;
  margin-right: 0.4em;
  vertical-align: middle;
}
.bd-article .ref-meta {
  color: #5a6772;
  font-size: 0.85em;
  margin: 0.3em 0 1em 0;
}
.bd-article .ref-link {
  display: inline-block;
  margin-right: 1em;
}

/* ============================================================
   Print styles
   ----------------------------------------------------------
   Some students print readings to mark up by hand. Strip the
   chrome (sidebar, navy hero, theme switcher), replace embedded
   iframes with a printed URL placeholder, force backgrounds to
   white, and reset the article column to full width.
   ============================================================ */
@media print {
  html, body {
    background: #fff !important;
    color: #000 !important;
  }

  /* Hide every piece of theme chrome. */
  .bd-sidebar-primary,
  .bd-sidebar-secondary,
  .bd-header,
  .bd-header-article,
  .bd-footer,
  .bd-footer-content,
  .bd-header-announcement,
  .header-article,
  .prev-next-area,
  .theme-switch-button,
  button.theme-switch-button,
  .toc-h2,
  .sphinxsidebar,
  .sy-breadcrumb,
  .block-nav,
  .hero .hero-cta,
  .fc-toolbar,
  .fc-study {
    display: none !important;
  }

  /* Main column: full width. */
  .bd-main,
  .bd-container,
  .bd-content,
  .bd-article-container,
  .bd-article {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    grid-template-columns: 1fr !important;
  }

  /* Replace each demo iframe with its full-screen URL printed in mono.
     The companion .demo-fullscreen anchor remains visible above. */
  .demo-wrap iframe { display: none !important; }
  .demo-wrap::after {
    content: "Interactive demo — open the linked URL above to use it online.";
    display: block;
    padding: 14px;
    border: 1px dashed #999;
    border-radius: 4px;
    color: #555;
    font-style: italic;
    font-size: 11pt;
  }

  /* Hero strip prints as a plain title row. */
  .bd-article .hero {
    background: none !important;
    color: #000 !important;
    padding: 0 0 12pt !important;
    border-bottom: 2pt solid #000;
    margin-bottom: 18pt;
    page-break-after: avoid;
  }
  .bd-article .hero::after { display: none !important; }
  .bd-article .hero .hero-shield { display: none !important; }
  .bd-article .hero .hero-eyebrow { color: #444 !important; }
  .bd-article .hero h1.hero-title,
  .bd-article .hero .hero-lede { color: #000 !important; }

  /* Block cards: stripped-down list look. */
  .bd-article .block-grid {
    display: block !important;
  }
  .bd-article .block-card {
    background: none !important;
    border: 1pt solid #999 !important;
    margin-bottom: 6pt !important;
    box-shadow: none !important;
    transform: none !important;
    page-break-inside: avoid;
  }

  /* Callouts: preserve the left-border accent, force white fill. */
  .admonition,
  div.admonition,
  .admonition.key-concept,
  .admonition.example-problem,
  .admonition.type-along,
  .admonition.ground-rules {
    background: #fff !important;
    box-shadow: none !important;
    page-break-inside: avoid;
  }
  .admonition > .admonition-title,
  div.admonition > p.admonition-title {
    background: #fff !important;
    color: #000 !important;
    border-bottom: 1pt solid #000 !important;
  }

  /* Page breaks. */
  h1, h2, h3 { page-break-after: avoid; }
  figure, table, .deliverable-card, .bt-card { page-break-inside: avoid; }

  /* MATLAB chip prints as a plain underlined reference. */
  .bd-article .matlab-link {
    background: none !important;
    border: none !important;
    color: #000 !important;
    padding: 0 !important;
    text-decoration: underline !important;
  }
  .bd-article .matlab-link svg,
  .bd-article .matlab-link .ml-arrow { display: none !important; }

  /* Inline code: no background, just JetBrains Mono. */
  .bd-article :not(pre) > code {
    background: none !important;
    color: #000 !important;
    padding: 0 !important;
  }

  a, a:visited { color: #000 !important; text-decoration: underline; }
  a[href]::after { content: ""; }  /* don't print every URL */
}

/* In-class media demos (Lesson 20 aliasing/quantization). Constrain the video
   so a 16:9 clip does not blow past the content column on wide screens. */
video.lesson-demo {
  display: block;
  width: 100%;
  max-width: 640px;
  height: auto;
  margin: 0.5rem 0 1rem;
  border-radius: 6px;
  background: #000;
}

audio.lesson-demo {
  display: block;
  width: 100%;
  max-width: 640px;
  margin: 0.5rem 0 1rem;
}

/* ============================================================
   Instructor bio pages  (book/instructors/*.md)
   Ported from the ECE 495 book.
   ============================================================ */
.bd-article .bio-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px;
  margin: 6px 0 22px;
  background: linear-gradient(135deg, #00205B 0%, #1f6098 100%);
  border-radius: 10px;
  color: #fff;
}
.bd-article .bio-head .bio-eyebrow {
  margin: 0 0 4px;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #b9d2ee;
}
/* h2 carries a rule underneath it site-wide (border-bottom plus an ::after
   underline); the gradient panel supplies its own separation, so drop both. */
.bd-article .bio-head .bio-name {
  margin: 0 0 6px;
  font-size: 27px;
  font-weight: 800;
  line-height: 1.15;
  color: #fff;
  border-bottom: none;
  padding-bottom: 0;
}
.bd-article .bio-head .bio-name::after { display: none; }
.bd-article .bio-head .bio-role {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.45;
  color: #dce8f6;
}
/* Shared PDF embed shell. Note this is the DIV wrapper; the older
   `iframe.pdf-embed` rule higher up styles a bare iframe and is unrelated. */
.bd-article .pdf-embed {
  border: 1px solid var(--tps-rule, #d8e2ec);
  border-radius: 8px;
  overflow: hidden;
  background: #f4f7fb;
  margin: 16px 0 10px;
}
.bd-article .pdf-embed iframe {
  display: block;
  width: 100%;
  height: 820px;
  border: 0;
}
@media (max-width: 720px) {
  .bd-article .pdf-embed iframe { height: 520px; }
}
.bd-article .pdf-fallback {
  font-size: 13px;
  color: #5b6573;
  margin: 0 0 18px;
}

/* ============================================================
   Framed data tables  (.dfec-table)
   ============================================================
   Shared by the Course Schedule and the Learning Objectives pages.
   Markup is `:::{container} dfec-table <variant>` around the table;
   .dfec-table carries the card framing, eyebrow header, and fixed
   layout, and each variant sets only its own column widths.

   Fixed layout because an auto-layout table starves whichever column
   the browser feels like: on the schedule that was the date column,
   so "Date (M / T)" orphaned onto a second line and "6 Aug / 7 Aug"
   wrapped mid-value.

   Colors, zebra, and hover all come from the base .bd-article
   table rules above. */

/* The schedule is the one page whose content is wider than prose. Its
   right-hand Contents panel lists only four headings -- the same three
   block names the tables are already titled with -- so on a wide screen
   that 272px is worth more to the table than to the nav. body:has() keys
   off the page's own markup, which avoids needing a Sphinx extension to
   stamp a per-page body class (.wide-page exists in this file for that
   purpose and was never wired up). Browsers without :has() simply keep
   the narrower layout. */
@media (min-width: 1200px) {
  body:has(.sched) .bd-sidebar-secondary { display: none; }
  /* The theme caps the article at 960px via `.bd-main .bd-content
     .bd-article-container`; the selector has to be at least that long to
     win, which is why this is not simply `body:has(.sched) .bd-article`. */
  body:has(.sched) .bd-main .bd-content,
  body:has(.sched) .bd-main .bd-content .bd-article-container,
  body:has(.sched) .bd-main .bd-content .bd-article {
    max-width: 100%;
  }
}

/* pydata-sphinx-theme already wraps every table in a
   .pst-scrollable-table-container that handles the horizontal scroll, so the
   card framing goes on THAT element -- put it on the outer .sched and the
   rounded border sits outside the scroll area and shears off as you scroll.
   The :not(:has(...)) arm keeps the framing if a future theme version drops
   that wrapper. */
.dfec-table { margin: 1.25em 0; }

.dfec-table .pst-scrollable-table-container,
.dfec-table:not(:has(.pst-scrollable-table-container)) {
  overflow-x: auto;
  border: 1px solid var(--tps-edge, #c8ddef);
  border-radius: 10px;
}

.dfec-table table {
  table-layout: fixed;
  width: 100%;
  margin: 0;                 /* the wrapper owns the outer margin now */
  border-radius: 0;
  /* The theme puts a 1px #f3f4f5 border on the table element. Inside a
     rounded container that reads as a square frame tucked behind the curve,
     and it insets the header so its corners do not follow the radius. The
     container's own border is the only one wanted here. */
  border: 0;
}

/* Header: the same uppercase eyebrow treatment as .bt-kind and
   .bio-eyebrow, so the tables read as part of the same system. Only the
   date header is nowrap -- applying nowrap to all of them made the wider
   labels spill out of their columns instead of wrapping. */
.dfec-table table tbody td {
  vertical-align: top;
  padding: 0.55em 0.8em;
}

/* The container's border-radius clips the tbody -- the bottom corners follow
   the curve -- but not the thead's row background, which paints square into
   the top corners. Round the end header cells to the same radius so the whole
   card reads as one shape. (Only visible artifact: on a narrow viewport, if
   you scroll the table sideways the rounded corner travels with the first and
   last header cells.) */
.dfec-table table thead th:first-child { border-top-left-radius: 10px; }
.dfec-table table thead th:last-child  { border-top-right-radius: 10px; }

/* Column sizing. Uppercase labels are wider than most of the values under
   them, so these are driven by the header, not the content -- which is why
   "Objectives" is rendered "Obj". Topic carries no width and absorbs the
   remainder, because it holds the longest strings on the page.

   RULE: a per-column selector may set GEOMETRY on both th and td (width,
   text-align, white-space) but must set TYPOGRAPHY on td only. An
   `.x table th:nth-child(n)` selector outscores `.dfec-table table thead th`,
   so a font-size or font-weight there silently overrides the shared header
   style for that one column. Both mistakes shipped: the Due header rendered
   at 14.3px against everyone else's 11px, because `font-size: 0.94em`
   resolved against the inherited 15.2px rather than the 11px it was meant to
   trim; and Lesson, LO# and the holidays Date all rendered at weight 600
   against everyone else's 700. */
.sched table th:nth-child(1),
.sched table td:nth-child(1) {
  width: 4.5rem;
  text-align: center;
}
.sched table td:nth-child(1) {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--tps-navy, #00205B) !important;
}

/* Date: the column this whole block exists for. */
.sched table th:nth-child(2),
.sched table td:nth-child(2) {
  width: 9rem;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* 3 = Topic, deliberately unsized. */

.sched table th:nth-child(4),
.sched table td:nth-child(4) {
  width: 5.25rem;             /* fits "2.1, 2.2" on one line */
  font-variant-numeric: tabular-nums;
}
.sched table th:nth-child(5),
.sched table td:nth-child(5) { width: 8.5rem; }   /* "Analog Filter Lab" */
.sched table th:nth-child(6),
.sched table td:nth-child(6) { width: 16rem; }
.sched table td:nth-child(6) { font-size: 0.94em; }

/* Due items are the reason a cadet opens this page -- give them weight. */
.sched table td:nth-child(6) strong {
  color: var(--tps-navy, #00205B);
}

/* Break rows: no lesson number, so they are marked in the source with
   .sched-break rather than inferred from position. */
.sched-break {
  font-weight: 600;
  font-style: italic;
  color: var(--tps-mid, #1f6098);
}
.sched table tbody tr:has(.sched-break) {
  background: #e7eefb;
}
.sched table tbody tr:has(.sched-break):hover {
  background: #e7eefb;
  box-shadow: inset 3px 0 0 var(--tps-navy, #00205B);
}

/* Hands-on badge: marks a lesson that runs a short bench segment in class.
   Authored into the Topic cell in the source (and once in the intro prose as a
   legend), so like .sched-break it is not scoped to .sched.

   text-transform is safe HERE and only here: the span's only content is the
   word "hands-on". It is set on the class itself rather than on any
   th/td/nth-child selector, so it cannot reach a header or a notation-bearing
   cell -- see the uppercase note at the top of the table section.

   Palette follows the .block-meta .b-block pill (navy on --tps-bg). The 1px
   --tps-edge border is what keeps it readable on the even-row zebra (#f0f7ff),
   which is close enough to the fill to swallow a borderless pill. Geometry
   only touches the span, so the .sched nth-child column widths and the
   min-width floor below are untouched -- Topic is the unsized column and
   absorbs the extra ~5.5rem. nowrap keeps the badge from breaking across
   lines when Topic narrows. */
.sched-handson {
  display: inline-block;
  margin-left: 0.5em;
  padding: 0.05em 0.55em;
  font-size: 0.72em;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  border-radius: 999px;
  color: var(--tps-navy, #00205B);
  background: var(--tps-bg, #eef3fb);
  border: 1px solid var(--tps-edge, #c8ddef);
}

/* Learning Objectives: two columns, LO number pinned.
   Deliberately NOT given the wide-layout treatment the schedule gets -- the
   description column is prose, and widening it to 1126px would push the line
   length past comfortable reading. Six columns needed the room; two do not. */
.los table th:nth-child(1),
.los table td:nth-child(1) {
  width: 5.5rem;
  text-align: center;
  white-space: nowrap;
}
.los table td:nth-child(1) {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}
/* 2 = Description, unsized, takes the remainder. */

/* Holidays table: two columns, date pinned. */
.sched-holidays table th:nth-child(1),
.sched-holidays table td:nth-child(1) {
  /* Sized for the longest value, "Wed 25 Nov - Mon 30 Nov", which needs
     203px of text plus 24px of padding. At 12rem it overran into the
     Occasion column instead of wrapping, because of the nowrap below. */
  width: 15rem;
  white-space: nowrap;
}
.sched-holidays table td:nth-child(1) {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

@media (max-width: 1199px) {
  /* Below the wide-layout breakpoint the table scrolls sideways instead of
     compressing. This floor MUST exceed the sum of the fixed columns above
     (4.5 + 9 + 5.25 + 8.5 + 16 = 43.25rem) or the leftover -- the topic
     column -- collapses to a few pixels and wraps one character per line.
     60rem leaves it roughly 16.75rem. */
  .sched table { min-width: 60rem; }
  .sched-holidays table { min-width: 34rem; }   /* 15rem date + room to read */
  /* No floor for .los: two columns fit a phone, and the description is
     prose that reads fine wrapped. Forcing a sideways scroll on a
     2-column table is more annoying than a narrower measure. */
}

/* ============================================================
   Task lists  (`- [ ] item`, MyST's `tasklist` extension)
   ============================================================
   The checkbox replaces the bullet: without the first rule the theme draws
   both, a disc and then the box. The box hangs in the bullet's place -- the
   list keeps its own padding -- so a wrapped line still starts under the
   text. Sizes are in em so the box scales with the text. No color is set
   anywhere: the box is the browser's own (disabled) control, so it follows
   the theme's color-scheme. */
.bd-article ul.contains-task-list > li.task-list-item {
  list-style: none;
}
.bd-article li.task-list-item input.task-list-item-checkbox {
  width: 0.85em;
  height: 0.85em;
  margin: 0 0.3em 0.2em -1.4em;
  vertical-align: middle;
}
