@import url("https://fonts.googleapis.com/css2?family=Frank+Ruhl+Libre:wght@300;400;500&family=Assistant:wght@300;400;600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap");

:root {
  /* course theme (31 Oct 2026): white, charcoal ink, soft blush blocks */
  --bg: #FFFFFF;
  --navy: #2B2627;        /* ink for bars and buttons (name kept from the template) */
  --blue: #4A3F42;        /* hover state of ink elements */
  --sky: #EADFE1;         /* blush */
  --blush: #EADFE1;
  --blush-deep: #C9AEB4;
  --side: #FAF6F6;
  --tint: #FAF6F6;
  --ink: #2B2627;
  --ink-2: #5A5254;
  --muted: #8C8285;
  --rule: #E4DADC;
  --rule-strong: #2B2627;
  --focus: #8A5A66;
  --lane: #C9AEB4;
  --stamp: #8A5A66;

  /* ERD building blocks - same colours everywhere on the site (dusty set, 31 Oct 2026) */
  --entity: #4F6F96;
  --entity-bg: #E6ECF3;
  --attr: #5E8466;
  --attr-bg: #E6EEE6;
  --rel: #8C5E7E;
  --rel-bg: #F1E5EC;

  --ok: #2B7A4B;
  --warn: #9A5B00;
  --warn-bg: #FFF5E0;

  --side-w: 272px;
  --font: "Assistant", "Heebo", system-ui, sans-serif;
  --font-serif: "Frank Ruhl Libre", "David Libre", Georgia, serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
/* lesson pages and the cheat sheet read larger (Assistant reads small); the home page keeps 16px */
html:has(body:not(.home)) { font-size: 109.4%; }
body.home { font-size: 16.5px; }

body {
  margin: 0;
  direction: rtl;
  background: var(--bg);
  color: var(--ink);
  font: 1rem/1.7 var(--font);
}

.ltr { direction: ltr; unicode-bidi: isolate; }
code, .mono { font-family: var(--font-mono); font-size: .9em; direction: ltr; unicode-bidi: isolate; }
a { color: var(--focus); }

h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; font-family: var(--font-serif); font-weight: 400; }
h1 { font-weight: 300; }
h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); letter-spacing: -.01em; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.08rem; }

/* ---------- buttons and fields ---------- */
.btn {
  font: 600 .86rem var(--font); letter-spacing: .06em; padding: 8px 16px; border-radius: 0; cursor: pointer;
  border: 1px solid var(--navy); background: var(--navy); color: #fff; line-height: 1.4;
}
.btn:hover { background: var(--blue); border-color: var(--blue); }
a.btn { text-decoration: none; display: inline-block; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn.ghost:hover { border-color: var(--blue); color: var(--blue); background: transparent; }
.btn.small { padding: 3px 10px; font-size: .84rem; }
.btn:disabled { opacity: .35; cursor: not-allowed; }
.btn:focus-visible, a:focus-visible, button:focus-visible, textarea:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

textarea, input[type="text"] {
  width: 100%; font: inherit; color: inherit; border: 1px solid var(--rule); border-radius: 4px;
  padding: 9px 11px; background: #fff;
}
textarea:focus, input[type="text"]:focus { border-color: var(--blue); outline: none; }
textarea { min-height: 120px; resize: vertical; }
.saved-hint { font-size: .8rem; color: var(--muted); }
.field-label { display: block; font-weight: 600; margin: 18px 0 6px; }

/* ---------- simple pages (home, standalone cheat sheet) ---------- */
.topbar { border-bottom: 1px solid var(--rule); }
.topbar .wrap { display: flex; align-items: center; gap: 24px; min-height: 52px; flex-wrap: wrap; }
.brand { font-weight: 700; text-decoration: none; color: var(--ink); }
.topbar nav { display: flex; gap: 18px; flex-wrap: wrap; }
.topbar nav a { text-decoration: none; color: var(--muted); font-weight: 500; font-size: .95rem; }
.topbar nav a:hover, .topbar nav a[aria-current="page"] { color: var(--ink); }

.wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }
.page-head { padding: 44px 0 12px; }
.page-head .kicker { font-family: var(--font-mono); font-size: .8rem; color: var(--muted); margin-bottom: 6px; }
.page-head p { color: var(--ink-2); max-width: 64ch; margin: 0; }
.section-title { margin: 40px 0 14px; font-size: 1.15rem; padding-bottom: 8px; border-bottom: 1px solid var(--rule-strong); }

/* home: top bar, hero block, sessions, cards */
.home-bar { display: flex; align-items: center; justify-content: space-between; padding-top: 22px; padding-bottom: 10px; }
.home-bar nav { display: flex; gap: 26px; font-size: .78rem; letter-spacing: .2em; }
.home-bar nav a { color: var(--muted); text-decoration: none; }
.home-bar nav a:hover { color: var(--ink); }
.label { font-size: .78rem; font-weight: 300; letter-spacing: .22em; color: var(--muted); }
.dotline { display: flex; align-items: center; max-width: 240px; margin: 10px 0 0; }
.dotline::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ink); flex: none; }
.dotline::after { content: ""; height: 1px; background: var(--rule); flex: 1; }
.dotline.end { flex-direction: row-reverse; }
.hero { background: var(--blush); margin: 18px 0 96px; }
.hero-in { display: flex; align-items: flex-end; justify-content: space-between; gap: 48px; padding-top: 150px; padding-bottom: 0; }
.hero-card { flex: 0 1 520px; background: #fff; border: 1px solid var(--rule); padding: 48px 52px; margin-bottom: -40px; }
.hero-card h1 { margin: 8px 0 12px; font-size: clamp(2.1rem, 4.6vw, 2.9rem); line-height: 1.15; }
.hero-card p { font-weight: 300; font-size: 1.1rem; color: var(--ink-2); margin: 0; }
.hero-side { flex: 0 1 340px; align-self: center; margin-top: -30px; font-weight: 300; font-size: 1.05rem; color: var(--ink-2); line-height: 1.7; }
.hero-side .dotline { margin-top: 14px; }
.hero-side .dotline::after { background: var(--ink); opacity: .3; }
.band-tint { background: var(--tint); padding: 64px 0 8px; margin-bottom: 64px; }
.sess { display: grid; grid-template-columns: 170px 1fr; gap: 36px; margin: 0 0 64px; }
.sess-num .num { display: block; text-align: right; font-family: var(--font-serif); font-weight: 300; font-size: 4.2rem; line-height: 1; color: var(--blush-deep); }
.sess-num .label { display: block; margin-top: 8px; }
.sess h2 { font-size: 1.6rem; margin: 6px 0 0; }
.sess .cards { margin-top: 22px; }
#map .cards, #s1 .cards, #s2 .cards, #s3 .cards, #s4 .cards { grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px 18px; }
.cards-note { margin: 18px 0 0; font-size: .85rem; color: var(--muted); }
.card {
  display: flex; flex-direction: column; gap: 6px; min-height: 170px; padding: 22px 24px;
  border: 1px solid var(--rule); border-radius: 0; background: #fff; color: inherit; text-decoration: none;
  transition: border-color .15s, box-shadow .2s;
}
a.card { box-shadow: -10px 10px 0 var(--blush); }
a.card:hover { border-color: var(--ink); box-shadow: -14px 14px 0 var(--blush); }
@keyframes card-in { from { opacity: 0; } }
.home .card { animation: card-in .4s ease-out backwards; }
.home .card:nth-child(2) { animation-delay: .05s; } .home .card:nth-child(3) { animation-delay: .1s; }
.home .card:nth-child(4) { animation-delay: .15s; } .home .card:nth-child(5) { animation-delay: .2s; }
@media (prefers-reduced-motion: reduce) { .home .card { animation: none; } }
.card-icon { direction: ltr; box-sizing: content-box; width: 20px; height: 20px; padding: 8px; margin-bottom: 8px; border-radius: 50%; background: var(--blush); color: var(--ink); fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.card.soon .card-icon { background: var(--tint); color: var(--muted); }
.card h3 { margin: 0; font-size: 1.28rem; }
.card p { margin: 0; color: var(--ink-2); font-size: .95rem; font-weight: 300; line-height: 1.6; }
.card .meta { margin-top: auto; padding-top: 12px; font-size: .76rem; letter-spacing: .2em; color: var(--muted); }
.card.soon { color: var(--muted); background: transparent; border-style: dashed; }
.card.soon h3, .card.soon p { color: var(--muted); }
.next-list { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 0 28px; }
.next-list .card { min-height: 0; border: 0; border-bottom: 1px solid var(--rule); padding: 14px 0; gap: 2px; }
.next-list .card h3 { font-size: 1.08rem; }
.next-list .card p { font-size: .88rem; }
.next-list .card .meta { display: none; }
@media (max-width: 760px) {
  .hero { margin-bottom: 80px; }
  .hero-in { padding-top: 28px; }
  .hero-card { padding: 26px 24px; margin-bottom: -48px; }
  .hero-side { display: none; }
  .sess { grid-template-columns: 1fr; gap: 6px; }
  .sess-num .num { font-size: 3rem; }
  .home-bar nav { gap: 14px; letter-spacing: .1em; }
}

footer.site-foot { color: var(--muted); font-size: .82rem; padding: 48px 0 32px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; }

/* ---------- lesson page: top bar, step pager, side column, bottom bar ---------- */
.lesson-page { height: 100vh; display: flex; flex-direction: column; overflow: hidden; }
.lesson-top { display: flex; align-items: center; gap: 22px; min-height: 48px; padding: 0 20px; background: var(--navy); color: #fff; flex: none; }
.back-home { color: #E3D3D7; text-decoration: none; font-size: .88rem; }
.back-home:hover { color: #fff; }
.lesson-name { font-weight: 700; }

.pager { position: relative; flex: none; background: var(--sky); border-bottom: 1px solid var(--rule); padding: 28px 40px 26px; }
.route { position: relative; display: flex; justify-content: space-between; max-width: 760px; margin: 0 auto; }
.route::before { content: ""; position: absolute; top: 15px; left: 15px; right: 15px; border-top: 1px solid rgba(43, 38, 39, .28); }
.route .done-line { position: absolute; top: 15px; right: 15px; height: 1px; width: 0; background: var(--ink); border-radius: 0; transition: width .6s ease; }
.stop {
  position: relative; z-index: 1; width: 32px; height: 32px; padding: 0; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid rgba(43, 38, 39, .45); background: #fff; color: var(--ink-2); font: 400 .9rem var(--font-serif); cursor: pointer;
}
.stop:hover:not(:disabled) { border-color: var(--blue); color: var(--blue); }
.stop.done { border-color: var(--ink); background: #fff; color: var(--ink); }
.stop[aria-current="step"] { border-color: var(--navy); background: var(--navy); color: #fff; box-shadow: 0 0 0 4px rgba(255, 255, 255, .7); }
.stop:disabled { cursor: not-allowed; }
.stop:disabled:not(.done) { opacity: .55; }
.stop .lbl { position: absolute; top: 36px; white-space: nowrap; font: 500 .76rem var(--font); color: var(--muted); }
.stop[aria-current="step"] .lbl { color: var(--navy); font-weight: 700; }
.hover-plane { position: absolute; top: -18px; right: 0; width: 26px; height: 11px; z-index: 2; color: var(--navy); pointer-events: none;
  transition: right .7s cubic-bezier(.34, 1.56, .64, 1); animation: bob 1.4s ease-in-out infinite; }
/* side view drawn nose-right: mirror it to face the next steps, nose up about 20 degrees */
.hover-plane svg { display: block; width: 26px; height: 11px; transform: scaleX(-1) rotate(-20deg); transform-origin: 50% 60%; }
@keyframes bob { 0%, 100% { margin-top: 0; } 50% { margin-top: -3px; } }

/* the corner: a flight lane from the step strip down the empty left margin, and an arrival stamp */
.sky { position: absolute; left: 0; top: 0; width: 380px; height: 480px; pointer-events: none; z-index: 5; }
.sky > svg { display: block; overflow: visible; }
.sky .lane { fill: none; stroke: var(--lane); stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 0 9; }
.sky .jet { color: var(--navy); }
.stamp { position: absolute; left: -12px; top: 98px; width: 106px; height: 106px; transform: rotate(-16deg); color: var(--stamp); opacity: .82; mix-blend-mode: multiply; pointer-events: none; }
.stamp svg { display: block; width: 100%; height: 100%; direction: ltr; unicode-bidi: isolate; }
.drawing .sky { display: none; }
@media (max-width: 1439px) { .sky { display: none; } }
@media (prefers-reduced-motion: reduce) { .hover-plane { animation: none; } }

.lesson { flex: 1; min-height: 0; display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); }
.side { overflow-y: auto; background: var(--side); border-inline-end: 1px solid var(--rule); display: flex; flex-direction: column; }
.side-toggle { align-self: flex-end; margin: 8px 10px 0; border: 0; background: none; cursor: pointer; color: var(--muted); font: 500 .78rem var(--font); padding: 2px 6px; border-radius: 4px; }
.side-toggle:hover { color: var(--ink); background: var(--sky); }
.side-step { padding: 2px 20px 18px; border-bottom: 1px solid var(--rule); }
.side-step .kind { display: inline-block; font-size: .76rem; font-weight: 600; color: #fff; background: var(--blue); border-radius: 3px; padding: 1px 8px; margin-bottom: 8px; }
.side-step .linkish { border: 0; background: none; padding: 0; margin-top: 8px; font: 500 .82rem var(--font); color: var(--blue); text-decoration: underline; cursor: pointer; }
.side-step .kind:empty { display: none; }
.side-step h2 { font-size: 1.2rem; margin: 0 0 4px; }
.side-step p { margin: 0; font-size: .9rem; color: var(--ink-2); line-height: 1.55; }
.side-step .side-now { font-weight: 600; color: var(--ink); margin-bottom: 4px; }
.side-block { padding: 16px 20px; border-bottom: 1px solid var(--rule); }
.side-block h3 { font-size: .76rem; font-weight: 600; color: var(--muted); margin: 0 0 10px; }
.concepts { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.concepts li { background: #fff; border: 1px solid var(--rule); border-radius: 6px; padding: 9px 12px; font-size: .85rem; line-height: 1.45; }
.concepts strong { display: block; font-size: .9rem; margin-bottom: 2px; }
.concepts strong::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--ink); margin-inline-end: 7px; vertical-align: middle; }
.concepts span { color: var(--ink-2); }
.files { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.files button { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 8px; background: #fff; border: 1px solid var(--rule); border-radius: 6px; padding: 7px 12px; font: 500 .85rem var(--font); color: var(--ink); cursor: pointer; text-align: start; }
.files button:hover { border-color: var(--blue); }
.files .ext { font: 600 .76rem var(--font-mono); color: var(--ok); border: 1px solid var(--ok); border-radius: 3px; padding: 0 5px; }
.side-tools { display: grid; gap: 6px; }
.tool {
  font: 600 .9rem var(--font); text-align: start; cursor: pointer; padding: 7px 12px; border-radius: 6px;
  border: 1px solid var(--rule); background: #fff; color: var(--ink);
}
.tool:hover { border-color: var(--blue); }
.tool[aria-pressed="true"] { background: var(--navy); color: #fff; border-color: var(--navy); }
.side-foot { margin-top: auto; padding: 16px 20px; display: grid; gap: 6px; font-size: .78rem; color: var(--muted); }
.side-foot .linkish { border: 0; background: none; padding: 0; font: inherit; color: var(--muted); text-decoration: underline; cursor: pointer; text-align: start; }
.side-foot .linkish:hover, .side-foot a:hover { color: var(--ink); }
.side-foot a { color: var(--muted); }
#backupStatus:empty { display: none; }
#backupStatus .btn { margin-top: 4px; }

/* collapsed: a narrow rail with the expand button and the reference tools */
.side-collapsed { --side-w: 64px; }
.side-collapsed .side-step, .side-collapsed #sideConceptsBlock, .side-collapsed #sideFilesBlock,
.side-collapsed .side-foot, .side-collapsed .side-tools h3 { display: none; }
.side-collapsed .side-toggle { align-self: center; margin: 10px 0 4px; }
.side-collapsed .side-tools { padding: 8px 6px; border: 0; }
.side-collapsed .tool { padding: 6px 2px; text-align: center; font-size: .76rem; }

.main { min-height: 0; display: flex; }
.stages { flex: 1; min-width: 0; overflow-y: auto; padding: 36px 48px 40px; }
.stages > .step { max-width: 780px; }

/* drawing: instructions column + editor */
.drawing .stages { flex: none; width: 400px; padding: 24px 22px 32px; border-inline-end: 1px solid var(--rule); }
.drawing .step h2 { font-size: 1.25rem; }

.lesson-bottom { flex: none; display: flex; align-items: center; gap: 16px; padding: 10px 20px; border-top: 1px solid var(--rule); background: #fff; }
.bottom-now { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.35; }
.bottom-now strong { font-size: .92rem; }
.bottom-now span { font-size: .8rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* sub-step tabs (inside a stage) */
.subnav { display: flex; gap: 4px; flex-wrap: wrap; margin: 0 0 22px; border-bottom: 1px solid var(--rule); }
.subnav button {
  display: flex; align-items: center; gap: 7px; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px;
  background: none; padding: 8px 10px; font: 600 .88rem var(--font); color: var(--ink-2); cursor: pointer;
}
.subnav button:hover:not(:disabled) { color: var(--ink); }
.subnav button[aria-selected="true"] { border-bottom-color: var(--blue); color: var(--navy); }
.subnav button:disabled { color: var(--muted); opacity: .6; cursor: not-allowed; }
.subnav .i { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid currentColor; display: inline-flex; align-items: center; justify-content: center; font: 600 .7rem var(--font-mono); }
.subnav .done .i { border-color: var(--blue); color: #fff; background: var(--blue); }
.subnav [aria-selected="true"] .i { background: var(--navy); border-color: var(--navy); color: #fff; }

/* ---------- stage content ---------- */
.step-head { margin-bottom: 18px; }
.step-head .gate { display: block; font-family: var(--font-mono); font-size: .8rem; color: var(--muted); margin-bottom: 2px; }
.step-head h2 { margin: 0; }
.lock-note { color: var(--muted); }
.step.locked > :not(.step-head):not(.lock-note) { display: none; }
.step:not(.locked) > .lock-note { display: none; }

.lead { color: var(--ink-2); margin: 0 0 18px; }
.task { font-weight: 500; margin: 0 0 12px; }

.note { border: 1px solid var(--rule); border-radius: 4px; padding: 12px 16px; margin: 0 0 20px; font-size: .95rem; }
.note > strong:first-child { display: block; margin-bottom: 2px; }

/* a change request from the company, as a message */
.msg { border: 1px solid var(--rule); border-radius: 10px; overflow: hidden; margin: 0 0 22px; background: #fff; box-shadow: 0 6px 18px -14px rgba(43, 38, 39, .5); }
.msg-head { display: flex; gap: 12px; align-items: center; background: var(--sky); padding: 10px 16px; }
.msg .avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .8rem; flex: none; }
.msg .who { font-weight: 700; line-height: 1.25; }
.msg .who small { display: block; font-weight: 400; color: var(--muted); font-size: .78rem; }
.msg .flag { margin-inline-start: auto; color: var(--blue); border: 1px solid var(--blue); background: #fff; font-size: .76rem; font-weight: 600; border-radius: 99px; padding: 0 10px; white-space: nowrap; }
.msg-body { padding: 14px 18px; }
.msg-body p { margin: 0; }

.questions { margin: 0 0 12px; padding-inline-start: 1.3em; }
.questions li { margin: 3px 0; }
h3.sub { font-size: .98rem; margin: 26px 0 8px; }

.step-foot { display: flex; flex-direction: column; gap: 10px; margin-top: 26px; padding-top: 14px; border-top: 1px solid var(--rule); }
.criteria { margin: 0; font-size: .9rem; color: var(--muted); }
.criteria strong { color: var(--ink); font-weight: 600; }
.step-foot .btn { align-self: flex-start; }
.snap-note { color: var(--ok); font-weight: 600; font-size: .9rem; margin: 0; }
.snap-note:empty { display: none; }


.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: .95rem; }
.checklist label { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.checklist input { width: 17px; height: 17px; margin-top: 5px; flex: none; accent-color: var(--ink); }

details { margin: 14px 0; border-top: 1px solid var(--rule); }
details > summary { cursor: pointer; padding: 10px 0; font-weight: 600; }
details.hint > summary { color: var(--muted); }
details.solution { border-top: 2px solid var(--ok); }
details.solution > summary { color: var(--ok); }
details[open] { padding-bottom: 6px; }

/* scenario + highlighter */
.scenario p { margin: 0 0 .9em; }
.hl-toolbar {
  position: sticky; top: 0; z-index: 5; background: var(--bg);
  display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding: 8px 0; margin-bottom: 8px; border-bottom: 1px solid var(--rule);
}
.hl-toolbar .label { font-size: .85rem; color: var(--muted); margin-inline-end: 4px; }
.hl-btn { font: 600 .86rem var(--font); border-radius: 4px; padding: 3px 11px; cursor: pointer; border: 1px solid; }
.hl-btn[data-kind="entity"] { color: var(--entity); background: var(--entity-bg); border-color: var(--entity); }
.hl-btn[data-kind="attr"] { color: var(--attr); background: var(--attr-bg); border-color: var(--attr); }
.hl-btn[data-kind="rel"] { color: var(--rel); background: var(--rel-bg); border-color: var(--rel); }
.hl-btn[data-kind="clear"] { color: var(--muted); background: #fff; border-color: var(--rule); }
mark.hl { padding: 0 2px; border-radius: 2px; color: inherit; }
mark.hl-entity { background: var(--entity-bg); box-shadow: inset 0 -2px 0 var(--entity); }
mark.hl-attr { background: var(--attr-bg); box-shadow: inset 0 -2px 0 var(--attr); }
mark.hl-rel { background: var(--rel-bg); box-shadow: inset 0 -2px 0 var(--rel); }

/* scenario as company documents */
.docs { display: flex; flex-direction: column; gap: 22px; }
.doc { border: 1px solid var(--rule); border-radius: 8px; background: #fff; box-shadow: 0 1px 0 rgba(43, 38, 39, .04), 0 6px 18px -12px rgba(43, 38, 39, .35); }
.doc-head { display: flex; align-items: center; gap: 10px; padding: 8px 16px; border-bottom: 1px solid var(--rule); font-size: .8rem; color: var(--muted); user-select: none; }
.doc-head .t { font-weight: 700; color: var(--navy); font-size: .88rem; }
.doc-head .n { margin-inline-start: auto; font-family: var(--font-mono); direction: ltr; unicode-bidi: isolate; }
.doc-body { padding: 14px 18px; }
.doc-body p { margin: 0; }
.doc-fig { margin-bottom: 12px; user-select: none; }
.memo-fields { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; font-size: .85rem; color: var(--muted); margin-bottom: 10px; user-select: none; }
.memo-fields b { color: var(--ink); font-weight: 600; }
.board { background: #0E1B2C; border-radius: 6px; padding: 10px 12px; font-family: var(--font-mono); color: #F3C04A; font-size: .82rem; direction: ltr; }
.board table { width: 100%; border-collapse: collapse; }
.board th { color: #8EA3BF; font-weight: 500; text-align: left; font-size: .76rem; padding: 2px 6px; border-bottom: 1px solid #26384F; }
.board td { padding: 4px 6px; border-bottom: 1px solid #1A2A3F; }
.board .st { color: #7FD8A4; }
.route-card { display: flex; align-items: center; gap: 18px; border: 1px solid var(--rule); border-radius: 8px; padding: 10px 16px; background: linear-gradient(180deg, var(--sky) 0, #fff 70%); direction: ltr; font-family: var(--font-mono); }
.route-card .code { font-size: 1.4rem; font-weight: 600; color: var(--navy); }
.route-card .line { flex: 1; border-top: 1px solid var(--rule); position: relative; }
.route-card .line span { position: absolute; left: 50%; top: -11px; transform: translateX(-50%); background: #fff; padding: 0 6px; color: var(--navy); font-size: .9rem; }
.route-card .meta { font-size: .78rem; color: var(--muted); text-align: right; }
.spec { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 2px 26px; font-size: .8rem; border: 1px solid var(--rule); border-radius: 8px; padding: 10px 16px; background: var(--tint); }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; font-weight: 600; font-family: var(--font-mono); direction: ltr; unicode-bidi: isolate; text-align: right; }
.signs { display: flex; gap: 10px; flex-wrap: wrap; }
.sign { background: #F6C343; color: #1B1B1B; border-radius: 4px; padding: 6px 12px; font-weight: 700; display: flex; align-items: center; gap: 10px; font-size: .9rem; }
.sign .g { font-family: var(--font-mono); background: #1B1B1B; color: #F6C343; border-radius: 3px; padding: 0 7px; direction: ltr; }
.form-card { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; border: 1px solid var(--rule); border-radius: 8px; padding: 12px 16px; font-size: .8rem; color: var(--muted); }
.form-card span { display: block; border-bottom: 1px solid var(--rule); padding-bottom: 12px; }
.form-card .full { grid-column: 1 / -1; border: 0; padding: 0; color: var(--ink-2); }
.pass { display: grid; grid-template-columns: 1fr 160px; border: 1px solid var(--rule); border-radius: 8px; overflow: hidden; }
.pass .main-p { padding: 12px 16px; background: linear-gradient(180deg, var(--sky) 0, #fff 60%); }
.pass .stub { border-inline-start: 2px dashed var(--rule); padding: 12px 14px; background: var(--tint); font-size: .8rem; }
.pass .route-big { display: flex; align-items: center; gap: 14px; font-family: var(--font-mono); font-size: 1.4rem; font-weight: 600; color: var(--navy); direction: ltr; justify-content: flex-end; }
.pass .route-big .arrow { font-size: 1rem; color: var(--muted); }
.pass dl { display: grid; grid-template-columns: repeat(4, auto); gap: 0 16px; margin: 8px 0 0; font-size: .78rem; }
.pass dt { color: var(--muted); }
.pass dd { margin: 0; font-weight: 600; }
.pass .empty { color: var(--muted); font-weight: 400; font-style: italic; }
.panel-body .doc-fig, .panel-body .memo-fields { display: none; }
.panel-body .doc { box-shadow: none; margin-bottom: 12px; }

/* intro screen at the start of a stage */
.step.show-intro > :not(.intro):not(.step-meta) { display: none; }
.step:not(.show-intro) > .intro { display: none; }
.intro .eyebrow { font-size: .8rem; font-weight: 600; color: var(--blue); }
.intro h2 { margin-top: .15em; }
.intro .lede { font-size: 1.05rem; max-width: 640px; }
.figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); margin: 22px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.figs figure { margin: 0; padding: 14px 8px; text-align: center; font-size: .85rem; }
.figs figure + figure { border-inline-start: 1px solid var(--rule); }
.figs figcaption strong { display: block; font-size: .9rem; }
.figs figcaption span { color: var(--muted); }
.figs svg { display: block; margin: 0 auto 8px; direction: ltr; max-width: 100%; height: auto; }
.quiz h3 { font-size: 1rem; margin: 26px 0 4px; }
.quiz .q, .classify .q { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 12px 0; border-bottom: 1px solid var(--rule); }
.quiz .q > span, .classify .q > span { flex-basis: 100%; }
.opt { font: 500 .85rem var(--font); border: 1px solid var(--rule); background: #fff; border-radius: 99px; padding: 3px 14px; cursor: pointer; color: var(--ink); }
.opt:hover { border-color: var(--blue); }
.opt[aria-pressed="true"] { border-color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); }
.opt.right { border-color: var(--ok); background: #E5F4EC; color: var(--ok); }
.opt.wrong { border-color: #B3261E; background: #FBEAE9; color: #B3261E; }
.start-row { margin-top: 24px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.start-row span { color: var(--muted); font-size: .88rem; }

/* worksheets */
.sheet { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: .93rem; }
.sheet th, .sheet td { border: 1px solid var(--rule); padding: 4px; text-align: center; }
.sheet th { background: var(--tint); font-weight: 600; padding: 7px 4px; }
.sheet input, .sheet select { width: 100%; border: 0; font: inherit; padding: 6px; background: transparent; text-align: center; }
.sheet select { cursor: pointer; }
.sheet .del { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 1.1rem; }
.sheet .del:hover { color: var(--ink); }
.del-table { margin-inline-start: auto; border: 0; background: none; color: #fff; opacity: .75; cursor: pointer; font: inherit; font-size: 1rem; }
.del-table:hover { opacity: 1; }
.sheet-scroll { overflow-x: auto; }
details .sheet td { text-align: start; padding: 6px 8px; }

/* before/after + gallery */
.compare { margin-top: 22px; }
.compare-grid, .gallery { display: grid; grid-template-columns: 1fr; gap: 12px; }
.compare-grid figure, .gallery figure { margin: 0; border: 1px solid var(--rule); border-radius: 4px; padding: 10px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.compare-grid figcaption, .gallery figcaption { font-size: .82rem; color: var(--muted); font-weight: 600; }
.compare-grid img, .gallery img { max-width: 100%; max-height: 360px; display: block; margin: 0 auto; cursor: zoom-in; }
.lightbox { position: fixed; inset: 0; z-index: 200; background: rgba(22, 25, 29, .82); display: flex; align-items: center; justify-content: center; padding: 24px; cursor: zoom-out; }
.lightbox img { max-width: 100%; max-height: 100%; background: #fff; border-radius: 2px; }

/* draw.io work area */
.work-area { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.editor-shell { flex: 1; display: flex; flex-direction: column; min-height: 0; background: #fff; }
.editor-bar { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--rule); }
.editor-bar .status { font-size: .8rem; color: var(--muted); margin-inline-start: auto; }
.editor-frame { flex: 1; width: 100%; min-height: 360px; border: 0; display: block; background: #fff; }
.editor-shell.full { position: fixed; inset: 0; z-index: 100; }
.editor-foot { font-size: .78rem; color: var(--muted); padding: 6px 12px; border-top: 1px solid var(--rule); margin: 0; }

/* schema editor */
.schema { display: grid; gap: 14px; margin: 12px 0; }
.schema > * { min-width: 0; }
.schema-table select { min-width: 7.2em; }
.schema-table td .ltr, .schema-table th { white-space: nowrap; } /* wide tables scroll inside their box instead of widening the page */
.schema-table { border: 1px solid var(--rule); border-radius: 4px; padding: 12px; }
.schema-head { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.schema-head input { font-weight: 700; max-width: 320px; }
.schema-table .sheet input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--ink); }
.schema-extra { display: flex; gap: 8px; align-items: center; margin-top: 8px; font-size: .88rem; color: var(--muted); }
.schema-extra input { flex: 1; }
.schema-solution pre { background: var(--tint); border-radius: 4px; padding: 12px; overflow-x: auto; font-family: var(--font-mono); font-size: .84rem; line-height: 1.5; text-align: left; }
.schema-name { font-family: var(--font-mono); font-size: 1rem; }
.schema-table tr.fixed td { color: var(--ink-2); }
.schema-table.given { background: var(--tint); }
.given-wrap { margin: 22px 0 6px; }
.given-wrap > summary { cursor: pointer; margin-bottom: 10px; }
/* part 2 worksheet: columns appear stage by stage */
#sheetBlock[data-mode="names"] .c-fk, #sheetBlock[data-mode="names"] .c-uq, #sheetBlock[data-mode="fk"] .c-uq { display: none; }
.schema-head { flex-wrap: wrap; gap: 8px 18px; }
.schema-head .tname { display: flex; gap: 6px; align-items: center; font-size: .85rem; color: var(--muted); white-space: nowrap; }
.schema-head .tname input { max-width: 230px; }
.schema-table .c-he input { min-width: 8.5em; }
.check-box { margin: 18px 0 6px; }
.schema-summary { border: 1px solid var(--rule); padding: 12px 16px; background: var(--tint); }
.schema-line { margin: 4px 0; font-family: var(--font-mono); font-size: .84rem; line-height: 1.6; }
.erd-ref > details > summary { cursor: pointer; font-weight: 600; margin: 10px 0; }
/* part 2: table cards, tasks with "בדיקה", choices (adapted from the first-year site, 5 Nov 2026) */
.tcard { border: 1px solid var(--rule); padding: 0 12px 10px; margin: 0 0 14px; background: #fff; overflow: hidden; }
.tcard-head { display: flex; gap: 10px; align-items: baseline; margin: 0 -12px 8px; padding: 6px 12px; background: var(--ink); color: #fff; }
.tcard-head .ltr { font: 600 .98rem var(--font-mono); }
.tcard-head .he { color: rgba(255, 255, 255, .8); font-size: .85rem; }
.tcard-head input { background: #fff; color: var(--ink); font: 600 .9rem var(--font-mono); padding: 2px 6px; border: 0; width: 14em; }
.tcard .sheet td { font-size: .9rem; }
.sheet .he { color: var(--muted); font-size: .85rem; }
.tcard .sheet tr.pk td { background: var(--attr-bg); }
.tcard .sheet tr.pk td:first-child .ltr, .tcard .sheet tr.pk td:first-child input { color: var(--attr); font-weight: 600; text-decoration: underline; }
.tcard .sheet tr.fk td { background: var(--rel-bg); }
.tcard .sheet .target { display: flex; gap: 4px; }
.tcard .sheet input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--attr); }
.tcard .sheet select { min-width: 7em; }
.tcard .combo { display: flex; gap: 8px; align-items: center; font-size: .86rem; color: var(--muted); margin-top: 6px; }
.tcard .combo input { flex: 1; max-width: 360px; }
.to { display: inline-block; font: 500 .82rem var(--font-mono); color: var(--entity); background: var(--entity-bg); padding: 0 6px; }
.sheet.ref .pk-name { color: var(--attr); font-weight: 600; text-decoration: underline; }
.add-table { display: flex; align-items: stretch; flex-wrap: wrap; gap: 0; margin: 18px 0; }
.add-table label { align-self: center; margin-inline-end: 12px; color: var(--muted); font-size: .92rem; }
.add-table select {
  appearance: none; -webkit-appearance: none; min-width: 15em; font: .95rem var(--font); color: var(--ink);
  padding: 8px 14px 8px 36px; border: 1px solid var(--rule); border-inline-end: 0; border-radius: 0; background: #fff
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%238C8285' stroke-width='1.3'/%3E%3C/svg%3E") no-repeat left 14px center;
  cursor: pointer;
}
.add-table select:hover { border-color: var(--ink); }
.demo-flash { outline: 3px solid var(--focus); outline-offset: 3px; transition: outline-color .3s; }
.choices { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 10px 0; }
.choices > span { font-weight: 500; }
.choices .opt[aria-pressed="true"] { border-color: var(--ink); background: var(--blush); }
.attempt { border-top: 1px solid var(--rule); padding-top: 4px; margin-top: 18px; }
.attempt .check-note { color: var(--ink-2); font-size: .92rem; }
.note .nf { font: 600 .74rem var(--font-mono); color: var(--ink-2); border: 1px solid var(--rule); padding: 0 5px; margin-inline-start: 4px; }
.checklist .nf { font: 600 .74rem var(--font-mono); color: var(--muted); margin-inline-start: 4px; }
.rules { margin: 22px 0; border-top: 1px solid var(--rule); }
.rule { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 36px; align-items: center; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.rule h3 { grid-column: 1 / -1; margin: 0; display: flex; gap: 12px; align-items: baseline; font-size: 1.1rem; }
.rule h3 .n { font-family: var(--font-serif); color: var(--blush-deep); }
.rule-text p { margin: 0 0 8px; color: var(--ink-2); }
.rule-q-label { font-size: .85rem; font-weight: 600; color: var(--muted); margin-bottom: 2px !important; }
.rule-q { margin: 0 0 12px; padding-inline-start: 1.2em; }
.rule figure { margin: 0; }
.rule svg { display: block; width: 300px; max-width: 100%; height: auto; direction: ltr; }
@media (max-width: 760px) { .rule { grid-template-columns: minmax(0, 1fr); } .rule figure { grid-row: 2; } }
.sheet.decide select[data-store$=":type"] { min-width: 7.5em; }
.sheet.decide select[data-store$=":null"] { min-width: 8em; }
.sheet.decide input[data-store$=":len"] { min-width: 4em; max-width: 6em; }
.sheet.decide td[data-after-check] { min-width: 14em; text-align: start; padding: 6px 8px; font-size: .88rem; }
.check-results { list-style: none; padding: 0; margin: 10px 0; display: grid; gap: 4px; font-size: .93rem; }
.check-results li { padding: 6px 10px; border-radius: 4px; }
.check-results li.warn { background: var(--warn-bg); }
.check-results li.ok { background: var(--attr-bg); color: var(--ok); font-weight: 600; }
.erd-ref img { max-height: 46vh; width: auto; margin: 0 auto; max-width: 100%; border: 1px solid var(--rule); border-radius: 4px; cursor: zoom-in; display: block; }

/* reference panel (scenario / cheat sheet) */
.panel {
  position: fixed; top: 0; bottom: 0; inset-inline-start: var(--side-w); z-index: 60;
  width: min(460px, calc(100vw - var(--side-w))); background: #fff; border-inline-end: 1px solid var(--rule);
  box-shadow: 0 0 32px rgba(22, 25, 29, .12); display: flex; flex-direction: column;
}
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 18px; border-bottom: 1px solid var(--rule); }
.panel-head h2 { font-size: 1.05rem; margin: 0; }
.panel-body { flex: 1; overflow-y: auto; padding: 16px 20px; font-size: .95rem; }
.panel-body.frame { padding: 0; overflow: hidden; }
.panel-body iframe { width: 100%; height: 100%; border: 0; }
.panel-body h3 { font-size: .8rem; font-family: var(--font-mono); color: var(--muted); font-weight: 500; margin: 18px 0 6px; }
.panel-body h3:first-child { margin-top: 0; }

/* ---------- cheat sheet ---------- */
.cheat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0 28px; }
.cheat { padding: 16px 0; border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; gap: 6px; }
.cheat svg { display: block; width: 100%; height: auto; max-height: 110px; direction: ltr; }
.cheat h3 { margin: 0; }
.cheat p { margin: 0; color: var(--ink-2); font-size: .94rem; }
.cheat .figure { padding: 6px 0; }
.ends { width: 100%; border-collapse: collapse; }
.ends td, .ends th { padding: 10px 12px; border-bottom: 1px solid var(--rule); text-align: start; vertical-align: middle; }
.ends th { font-size: .85rem; color: var(--muted); font-weight: 600; }
.ends svg { width: 150px; height: 40px; direction: ltr; display: block; }
.ends .mono { white-space: nowrap; }

body.embed .topbar, body.embed footer { display: none; }
body.embed .page-head { padding-top: 16px; }
body.embed .page-head .kicker { display: none; }
body.embed h1 { font-size: 1.4rem; }
body.embed .page-head p { font-size: .92rem; }
body.embed .cheat-grid { grid-template-columns: 1fr; }
body.embed .section-title { margin-top: 28px; }

/* ---------- small screens ---------- */
@media (max-width: 900px) {
  .lesson-page { height: auto; overflow: visible; display: block; }
  .lesson-top { gap: 12px; padding: 0 16px; flex-wrap: wrap; }
  .lesson-name { font-size: .92rem; }
  .pager { overflow-x: auto; padding: 26px 16px 24px; }
  .route { min-width: 520px; }
  .pass { grid-template-columns: 1fr; }
  .pass .stub { border-inline-start: 0; border-top: 2px dashed var(--rule); }
  .pass dl { grid-template-columns: repeat(2, auto); }
  .lesson, .side-collapsed .lesson { display: block; }
  .side-toggle, .side-collapsed .side-toggle { display: none; }
  .side-collapsed .side-step, .side-collapsed .side-tools h3 { display: block; }
  .side-collapsed .side-tools { padding: 16px 20px; }
  #sideConceptsBlock, #sideFilesBlock { display: none; }
  .side-foot, .side-collapsed .side-foot { display: flex; flex-wrap: wrap; gap: 6px 14px; padding: 0 20px 14px; }
  .side-step { padding-top: 16px; }
  .side-tools { display: flex; flex-wrap: wrap; }
  .side-tools h3 { width: 100%; }
  .main, .drawing .main { display: block; }
  .stages, .drawing .stages { width: auto; overflow: visible; padding: 24px 16px; border: 0; }
  .work-area { height: 80vh; padding-bottom: 16px; }
  .lesson-bottom { position: sticky; bottom: 0; padding: 8px 16px; }
  .bottom-now span { display: none; }
  .panel { inset: 0; width: 100%; }
}

@media (min-width: 1200px) {
  .compare-grid { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; }
}
@media print {
  .topbar, footer { display: none; }
  body { font-size: 13px; }
  .cheat, .ends { break-inside: avoid; }
}

/* shared relationship table: names only until the cardinality stage */
#relBlock[data-mode="names"] .sheet tr > :nth-child(2),
#relBlock[data-mode="names"] .sheet tr > :nth-child(4) { display: none; }
.drawing .sheet { font-size: .85rem; }
.drawing .sheet input, .drawing .sheet select { padding: 5px 3px; }

/* stage 2: entity builder beside the story */
.stages > .step.wide { max-width: 1180px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.split-story { position: sticky; top: 0; max-height: calc(100vh - 290px); overflow-y: auto; padding-inline-end: 4px; }
.split-story .doc-fig, .split-story .memo-fields { display: none; }
.split-story .hl-toolbar { position: sticky; top: 0; z-index: 1; background: #fff; }

.ebuild h3.sub:first-child { margin-top: 0; }
.pool { display: flex; flex-wrap: wrap; gap: 6px; min-height: 44px; padding: 8px; border: 1px dashed var(--rule); border-radius: 8px; background: var(--tint); }
.pool.over { border-color: var(--blue); background: var(--sky); }
.pool-none { margin: 4px; color: var(--muted); font-size: .9rem; }
.pool-foot { margin: 4px 0 0; min-height: 1em; font-size: .85rem; }
.pool-foot .linkish, .lead .linkish { border: 0; background: none; padding: 0; font: inherit; color: var(--blue); text-decoration: underline; cursor: pointer; }
.wide-stage .sky { display: none; }

.chip { display: inline-flex; align-items: center; border-radius: 6px; font-size: .92rem; cursor: grab; user-select: none; }
.chip.dragging { opacity: .4; }
.chip .chip-t { border: 0; background: none; font: inherit; color: inherit; padding: 3px 4px 3px 9px; cursor: inherit; }
.chip .chip-x { border: 0; background: none; color: var(--muted); font-size: 1rem; line-height: 1; padding: 3px 7px 3px 5px; cursor: pointer; }
.chip .chip-x:hover, .chip .chip-ed:hover { color: var(--ink); }
.chip .chip-ed { border: 0; background: none; color: var(--muted); font-size: .8rem; line-height: 1; padding: 3px 2px; cursor: pointer; opacity: .55; }
.chip:hover .chip-ed, .chip .chip-ed:focus-visible { opacity: 1; }
.chip-edit { font: inherit; font-size: .92rem; padding: 3px 8px; border: 1.5px solid var(--blue); border-radius: 6px; outline: none; background: #fff; }
mark.hl.flash { outline: 2.5px solid var(--navy); outline-offset: 1px; border-radius: 2px; }
.chip.k-entity { background: var(--entity-bg); box-shadow: inset 0 0 0 1.5px var(--entity); }
.chip.k-attr { background: var(--attr-bg); box-shadow: inset 0 0 0 1.5px var(--attr); border-radius: 99px; }
.chip.key .chip-t { text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.chip.picked { outline: 2.5px solid var(--navy); outline-offset: 2px; }
.eattrs .chip.before { box-shadow: inset 0 0 0 1.5px var(--attr), 3px 0 0 0 var(--navy); }

.ecards { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.drawing .ecards { grid-template-columns: 1fr; }
.ecard { border: 1.5px solid var(--rule); border-radius: 8px; padding: 8px; background: #fff; min-height: 84px; }
.ecard.over, .has-picked .ecard, .has-picked .pool { border-color: var(--blue); }
.ecard.over { background: var(--sky); }
.ecard-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 8px; }
.ecard-head .ename { font-weight: 700; }
.ecard-head > .chip-x { border: 0; background: none; color: var(--muted); font-size: 1.05rem; cursor: pointer; }
.eattrs { display: flex; flex-wrap: wrap; gap: 5px; }
.ecard-hint { color: var(--muted); font-size: .85rem; }
.ecard.new { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; border-style: dashed; color: var(--muted); background: var(--tint); }
.ecard.new strong { color: var(--navy); }
.ecard.new span { font-size: .82rem; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } .split-story { position: static; max-height: none; } }

/* stages 3-4: the table beside the story; intros keep the normal width */
.stages > .step.wide.show-intro { max-width: 780px; }
.split .sheet select { min-width: 0; }

/* entity list / relationship table floating over the editor */
.float-bar { display: none; }
.drawing .float-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.float-title { font-weight: 700; color: var(--navy); }
.drawing #relBlock > .field-label { display: none; }
.drawing .floating { position: fixed; z-index: 90; max-width: calc(100vw - 16px); max-height: calc(100vh - 16px); min-width: 240px; min-height: 120px; overflow: auto; resize: both; background: #fff; border: 1px solid var(--rule); border-radius: 10px; padding: 0 12px 12px; box-shadow: 0 10px 30px rgba(22, 32, 46, .18); }
.drawing .floating .float-bar { position: sticky; top: 0; z-index: 2; margin: 0 -12px 8px; padding: 6px 12px; background: var(--tint); border-bottom: 1px solid var(--rule); cursor: move; touch-action: none; user-select: none; }
body:not(.drawing) [data-floatable] { width: auto !important; height: auto !important; }
.moving-float .editor-frame { pointer-events: none; }

/* ready-made diagrams menu in the editor bar */
.tpl { position: relative; }
.tpl-list { position: absolute; top: calc(100% + 4px); inset-inline-start: 0; z-index: 20; display: flex; flex-direction: column; min-width: 220px; padding: 4px; background: #fff; border: 1px solid var(--rule); border-radius: 8px; box-shadow: 0 8px 24px rgba(22, 32, 46, .14); }
.tpl-list[hidden] { display: none; }
.tpl-list button { border: 0; background: none; font: inherit; font-size: .88rem; text-align: start; padding: 7px 10px; border-radius: 6px; cursor: pointer; color: var(--ink); }
.tpl-list button:hover { background: var(--sky); }
.editor-bar .status .linkish { border: 0; background: none; padding: 0; font: inherit; color: var(--blue); text-decoration: underline; cursor: pointer; }

/* class demo controls (instructor build) */
.demo-bar { position: fixed; left: 16px; bottom: 76px; z-index: 95; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; max-width: calc(100vw - 32px); padding: 8px 12px; background: #fff; border: 1.5px solid var(--navy); border-radius: 10px; box-shadow: 0 10px 30px rgba(22, 32, 46, .18); font-size: .88rem; }
.demo-tag { background: var(--navy); color: #fff; font-weight: 700; padding: 2px 8px; border-radius: 4px; }
.demo-what { font-weight: 600; color: var(--navy); margin-inline-end: 4px; }
.demo-bar .linkish { border: 0; background: none; padding: 0; font: inherit; color: var(--muted); text-decoration: underline; cursor: pointer; }
.lesson-bottom .demo-bar { position: static; flex: 1; justify-content: center; max-width: none; margin: 0 12px; padding: 4px 10px; box-shadow: none; }
.demo-bar .demo-what { flex: 1; text-align: center; }
.demo-bar .demo-next { padding-inline: 18px; }
.build-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 4px 0 18px; }
.build-row span { color: var(--muted); font-size: .9rem; flex: 1; min-width: 200px; }
.side-foot .rights { margin-top: 6px; }

/* logo: at the far end of each top bar */
.logo { display: block; height: 24px; width: auto; }
.lesson-top .logo, .topbar .logo { margin-inline-start: auto; }
.home-head .logo { height: 40px; }
@media (max-width: 600px) { .home-head .logo { height: 28px; } }

/* "בדיקת התכנון" (מסלול 2) */
.bsc textarea { min-height: 72px; }
.proposals { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 18px; }
.records td { font-family: var(--font-mono); font-size: .85rem; }
.pick { border: 0; padding: 0; margin: 0; }
.classify .q input { flex-basis: 100%; }
.classify .key { flex-basis: 100%; margin: 0; font-size: .9rem; color: var(--ink-2); }
.check-note { margin: 0; font-size: .9rem; color: var(--ink-2); }
.check-note:empty { display: none; }
.answers .q-label { margin: 10px 0 2px; font-size: .85rem; color: var(--muted); }
.answers .a { margin: 0; white-space: pre-wrap; }
.answers .a.none { color: var(--muted); }

/* ---------- part 3: building the database (src/db) ---------- */
/* code: coloured SQL (notation colours), the copy button in the top corner, above the code */
pre.code { margin: 0; background: var(--tint); border: 1px solid var(--rule); border-radius: 6px; padding: 14px 16px; overflow-x: auto; direction: ltr; text-align: left; font: .84rem/1.6 var(--font-mono); white-space: pre; }
pre.code code { font-size: inherit; }
.code-wrap { position: relative; margin: 10px 0 16px; min-width: 0; max-width: 100%; }
.code-wrap pre.code { padding-top: 42px; }
.code-wrap .copy { position: absolute; top: 8px; right: 8px; left: auto; background: #fff; }
.sql-hl .k { color: var(--entity); font-weight: 600; }
.sql-hl .s { color: var(--attr); }
.sql-hl .d { color: var(--warn); }
.sql-hl .c { color: var(--muted); }
/* commands and names in the text */
.cmd { font: 600 .84em var(--font-mono); color: var(--entity); background: var(--entity-bg); border-radius: 3px; padding: 1px 6px; }
.name { font: 500 .88em var(--font-mono); color: var(--rel); }
/* headings inside a task, with a bar in the relationship colour */
h3.sub { font: 700 1.02rem var(--font); color: var(--ink); border-inline-start: 3px solid var(--rel); padding-inline-start: 10px; margin: 28px 0 10px; }
.attempt > h3.sub:first-child, .feedback > h3.sub:first-child { margin-top: 6px; }
.feedback { margin-top: 22px; padding-top: 4px; border-top: 1px solid var(--rule); }
.task { margin: 0 0 12px; }
.steps-list { padding-inline-start: 1.3em; display: grid; gap: 26px; margin: 8px 0 22px; }
.steps-list > li { min-width: 0; max-width: 100%; }
.steps-list > li::marker { font-weight: 700; color: var(--rel); }
.choices { flex-wrap: wrap; }
/* numbers students report */
input.count { width: 6.5em; border: 1px solid var(--rule); border-radius: 4px; padding: 5px 8px; font: inherit; background: #fff; }
input.count.right { border-color: var(--ok); background: var(--attr-bg); }
input.count.wrong { border-color: var(--warn); background: var(--warn-bg); }
.count-row { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
.count-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px 26px; margin-top: 14px; }
.count-grid label { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: .93rem; }
/* SQL the students paste */
.sql-box { display: flex; flex-direction: column; gap: 6px; font-weight: 600; margin: 18px 0; min-width: 0; }
.sql-box > span:first-child { font-size: .93rem; }
.sql-box > span.ltr:first-child { color: var(--entity); font-family: var(--font-mono); font-size: .9rem; }
textarea.sql, .sql-under { direction: ltr; unicode-bidi: isolate; font: .82rem/1.55 var(--font-mono); text-align: left; white-space: pre; overflow-x: auto; padding: 9px 11px; border: 1px solid var(--rule); border-radius: 4px; margin: 0; tab-size: 4; }
textarea.sql { display: block; width: 100%; box-sizing: border-box; min-height: 200px; position: relative; background: transparent; color: transparent; caret-color: var(--ink); }
textarea.sql::placeholder { color: var(--muted); }
/* the selection is see-through, so the coloured text underneath stays readable */
textarea.sql::selection { color: transparent; background: rgba(79, 111, 150, .22); }
.sql-edit { position: relative; background: #fff; border-radius: 4px; }
.sql-under { position: absolute; inset: 0; overflow: hidden; color: var(--ink); background: #fff; border-color: transparent; font-weight: 400; pointer-events: none; }
.qtask textarea.sql { min-height: 120px; }
.qtask { margin-bottom: 26px; }
.qtask .count-row { margin-top: 0; }
.syntax section { margin: 0 0 8px; }
.syntax p { margin: 0 0 6px; }
.sql-notes { font-weight: 400; font-size: .88rem; }
.sql-notes .ok { color: var(--ok); }
.sql-notes .warn { display: block; background: var(--warn-bg); border-radius: 4px; padding: 8px 12px; }
.sql-notes .miss { list-style: none; margin: 4px 0 0; padding: 0; direction: ltr; text-align: left; font: .8rem/1.7 var(--font-mono); }
.agreed-label { margin: 18px 0 0; font-size: .9rem; color: var(--muted); }
/* the three documents: the event form beside the two confirmations */
.docs-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 16px 0 8px; }
.docs-row .doc:first-child { grid-row: span 2; }
.docs-row .doc-head .t { color: var(--rel); }
@media (max-width: 640px) { .docs-row { grid-template-columns: minmax(0, 1fr); } .docs-row .doc:first-child { grid-row: auto; } }
dl.fields { display: grid; grid-template-columns: auto 1fr; gap: 5px 14px; margin: 0; font-size: .9rem; }
dl.fields dt { color: var(--muted); }
dl.fields dd { margin: 0; }
/* the five tries: one box each */
.tries { list-style: none; counter-reset: try; padding: 0; display: grid; gap: 18px; margin: 8px 0 22px; }
.tries > li { counter-increment: try; border: 1px solid var(--rule); border-radius: 6px; padding: 14px 18px 12px; min-width: 0; }
.tries > li > p:first-child::before { content: counter(try) ". "; font-weight: 700; color: var(--ink); }
.tries p { margin: 0 0 4px; }
.tries .code-wrap { margin: 8px 0 10px; }
.tries .why { margin: 10px 0 0; font-size: .92rem; background: var(--tint); border-radius: 4px; padding: 8px 12px; }
.confirm { display: flex; gap: 8px; align-items: center; font-size: .93rem; cursor: pointer; }
/* side panels */
.panel-body .files li { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; border-bottom: 1px solid var(--rule); font-size: .9rem; }
.panel-body .files li span:last-child { color: var(--muted); }
.panel-body h3.ltr { color: var(--entity); font-family: var(--font-mono); font-size: .92rem; }
.panel-body .dict { font: .78rem/1.65 var(--font-mono); text-align: left; background: var(--tint); border-radius: 4px; padding: 8px 10px; margin: 4px 0 6px; }
.panel-body pre.code { font-size: .78rem; }
.tries .why .err { display: block; direction: ltr; text-align: left; font: 600 .8rem var(--font-mono); color: var(--warn); margin-bottom: 4px; }
.step.sub .attempt { border-top: 0; padding-top: 0; margin-top: 4px; }
.syntax, .syntax section, .intro .code-wrap { min-width: 0; max-width: 100%; }
.quiz .opt { white-space: normal; }
.checklist label, .checklist label > *, a > .ltr, .task .ltr { overflow-wrap: anywhere; min-width: 0; }

/* ---------- Python code and terminal output (session 2 on) ---------- */
.py-hl .b { color: var(--rel); }
pre.code.out-hl { background: #2B2627; color: #F3ECEE; border-color: #2B2627; }
.out-hl .ok { color: #A9E2BC; }
.out-hl .bad { color: #F0B8A8; }

/* ---------- reference pages (sqlref, pyref, setup): text beside an example ---------- */
  .ref main { padding-bottom: 60px; }
  .ref .jump { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 6px; }
  .ref .jump a { font: 600 .82rem var(--font-mono); text-decoration: none; color: var(--ink); border: 1px solid var(--rule); padding: 4px 10px; background: #fff; direction: ltr; }
  .ref .jump a:hover { border-color: var(--ink); }
  .ref .jump a.he { font-family: var(--font); direction: rtl; }
  .ref .err { flex-wrap: wrap; margin: 0 0 6px; }
  .ref table.types td:nth-child(2) { min-width: 150px; }
  .ref section.item { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 8px 32px; padding: 22px 0; border-bottom: 1px solid var(--rule); scroll-margin-top: 16px; }
  .ref section.item h2 { grid-column: 1 / -1; font-size: 1.35rem; margin: 0; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
  .ref section.item h2 .kw { font: 600 .95rem var(--font-mono); color: var(--entity); background: var(--entity-bg); padding: 2px 9px; direction: ltr; }
  .ref .txt p { margin: 0 0 10px; color: var(--ink-2); }
  .ref .txt ul { margin: 0 0 10px; padding-inline-start: 20px; color: var(--ink-2); }
  .ref .txt li { margin-bottom: 4px; }
  .ref .err { display: inline-flex; gap: 8px; align-items: baseline; font-size: .88rem; background: var(--warn-bg); color: var(--warn); padding: 4px 10px; border-inline-start: 3px solid var(--warn); }
  .ref .err code { font-weight: 600; }
  .ref .ex pre.code { margin-bottom: 10px; }
  .ref .ex .lbl { font: 600 .74rem var(--font); color: var(--muted); margin-bottom: 4px; display: block; }
  .ref .bad pre.code { border-color: #E9C9A0; background: #FFFBF4; }
  .ref table.types { width: 100%; border-collapse: collapse; font-size: .92rem; }
  .ref table.types th, .ref table.types td { border-bottom: 1px solid var(--rule); padding: 6px 8px; text-align: right; vertical-align: top; }
  .ref table.types th { color: var(--muted); font-weight: 600; font-size: .8rem; }
  .ref table.types td.ltr { font-family: var(--font-mono); font-size: .84rem; white-space: nowrap; }
  .ref .check { counter-reset: c; list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
  .ref .check li { counter-increment: c; position: relative; padding: 8px 30px 8px 0; border-bottom: 1px solid var(--rule); }
  .ref .check li::before { content: counter(c); position: absolute; right: 0; top: 8px; width: 20px; text-align: center; font: 600 .85rem var(--font-mono); color: var(--muted); }
  .ref section.item > .txt:last-child { grid-column: 1 / -1; max-width: 70ch; }
  .ref .ex { min-width: 0; overflow-x: auto; }
  @media (max-width: 900px) { .ref section.item { grid-template-columns: minmax(0, 1fr); } .ref table.types td.ltr { white-space: normal; overflow-wrap: anywhere; } .ref table.types { font-size: .85rem; } }
  @media print {
    .lesson-top, .site-foot, .jump, .copy { display: none !important; }
    .ref section.item { break-inside: avoid; }
    .code-wrap pre.code { padding-top: 14px; }
  }

/* ---------- home page: charcoal accents (approved 15 Nov 2026; home page only) ---------- */
body.home .hero-card { background: #2E2B2C; border-color: #2E2B2C; color: #F3ECEE; }
body.home .hero-card h1 { color: #fff; }
body.home .hero-card .label { color: #C9AEB4; }
body.home .hero-card p { color: #CFC6C8; }
body.home .band-tint { background: #2E2B2C; }
body.home .band-tint h2 { color: #fff; }
body.home .band-tint .sess-num .num { color: #C9AEB4; }
body.home .band-tint .sess-num .label { color: #A99FA2; }
body.home .band-tint .dotline::before { background: #EADFE1; }
body.home .band-tint .dotline::after { background: #4A4446; }
body.home .band-tint .card.soon h3 { color: #F3ECEE; }
body.home .band-tint .card.soon p { color: #BDB3B5; }
body.home .band-tint .next-list .card { border-bottom-color: #4A4446; }
/* the current session: a charcoal label under its number (move it to the next session each week) */
.sess-num .now-tag { display: inline-block; margin-top: 10px; font: 600 .74rem var(--font); letter-spacing: .06em; color: #fff; background: #2E2B2C; padding: 3px 10px; }
.sess:has(.now-tag) .sess-num .num { color: #2E2B2C; }

/* part 2 as a guided walkthrough (revised 18 Nov 2026): one decision per step; the story, the
   piece of the diagram, the tables under their entities, the rule; the step bar at the bottom */
.walk { max-width: 1000px; }
.walk-kicker { font-size: .85rem; font-weight: 600; color: var(--stamp); margin: 0 0 2px; }
.walk-title { font-size: 1.4rem; margin: 0 0 14px; }
.walk-quote { border-inline-start: 4px solid var(--blush-deep); background: var(--tint); padding: 10px 16px; margin: 0 0 18px; font-size: 1.02rem; }
.walk-quote small { display: block; color: var(--muted); font-size: .8rem; margin-bottom: 2px; }
.walk-label { font-size: .85rem; color: var(--muted); font-weight: 600; margin: 0 0 6px; }
.walk-diagram { display: block; border: 1px solid var(--rule); background: #fff; padding: 6px; cursor: zoom-in; }
.walk-diagram img { display: block; max-width: 100%; height: auto; margin: 0 auto; }
.walk-arrow { text-align: center; color: var(--muted); font-size: 1.15rem; line-height: 1; margin: 4px 0 6px; }
.walk-tables { display: grid; gap: 14px 28px; align-items: start; }
.walk-tables.n2 { grid-template-columns: 1fr 1fr; }
.walk-tables.n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.walk-tables .tcard { margin: 0; }
.walk-tables .sheet td { text-align: start; padding: 5px 8px; vertical-align: top; }
.walk-tables .he-sub { display: block; color: var(--muted); font-size: .78rem; line-height: 1.2; }
.walk-tables .why-cell { color: var(--ink-2); font-size: .86rem; }
.walk-tables tr.walk-hl td { box-shadow: inset 0 0 0 999px rgba(201, 174, 180, .38); }
.walk-tables tr.walk-hl td:first-child { border-inline-start: 3px solid var(--focus); }
.walk-tables tr.walk-fold td { text-align: center; padding: 3px; }
.walk-tables tr.walk-fold .linkish { font-size: .82rem; }
.walk-rule { border: 1px solid var(--rule); padding: 12px 16px; margin: 18px 0; }
.walk-rule p, .walk-rule ol, .walk-rule ul { margin: 5px 0; }
.walk-rule .nf { font: 600 .74rem var(--font-mono); color: var(--ink-2); border: 1px solid var(--rule); padding: 0 5px; margin-inline-start: 4px; }
.walk-rule .walk-src { color: var(--stamp); }
.walk-range { width: auto; margin: 6px 0; }
.walk-range td, .walk-range th { padding: 3px 12px; text-align: start; }
.walk-sofar { margin-bottom: 18px; }
.walk-sofar summary { cursor: pointer; font-weight: 600; }
.walk-lines p { font: .84rem/1.8 var(--font-mono); direction: ltr; text-align: left; margin: 2px 0; }
.walk-lines .pk { text-decoration: underline; }
.walk-lines .fk { color: var(--rel); }
.walk-nav { position: sticky; bottom: 0; z-index: 5; background: #fff; border-top: 1px solid var(--rule); padding: 12px 0 14px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.walk-nav .btn.ghost { justify-self: start; }
.walk-nav .btn:not(.ghost) { justify-self: end; }
.walk-nav-mid { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: .9rem; }
.walk-dots { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; }
.walk-dots button { width: 11px; height: 11px; padding: 0; border-radius: 50%; border: 1px solid var(--ink); background: #fff; cursor: pointer; }
.walk-dots button[aria-current] { background: var(--ink); }
.walk-page .lesson-bottom { display: none; }
.walk-full-erd { margin: 12px 0 18px; }
.walk-full-erd img { display: block; width: 100%; border: 1px solid var(--rule); background: #fff; }
.walk-full-erd figcaption { font-size: .82rem; color: var(--muted); margin-top: 4px; }
@media (max-width: 760px) { .walk-tables.n2, .walk-tables.n3 { grid-template-columns: 1fr; } }

.agreed-card .sheet td { text-align: start; padding: 4px 8px; font-size: .86rem; }
.agreed-card .why-cell { color: var(--ink-2); font-size: .82rem; min-width: 14em; }
.agreed-lines { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 6px; font-size: .85rem; }
.agreed-lines li { display: flex; flex-direction: column; gap: 1px; }
.agreed-lines code { text-align: left; color: var(--ink); white-space: pre-wrap; }
.agreed-lines span { color: var(--ink-2); }
.panel-body .agreed-card { padding: 0 8px 8px; }
.panel-body .agreed-card .tcard-head { margin: 0 -8px 6px; }
.panel-body .agreed-card .sheet td, .panel-body .agreed-card .sheet th { font-size: .8rem; padding: 3px 5px; }
.panel-body .agreed-card .ltr { font-size: .78rem; }
.panel-body .agreed-lines { font-size: .78rem; }

/* session solution page */
.sol .sol-part { padding: 24px 0; border-bottom: 1px solid var(--rule); scroll-margin-top: 16px; }
.sol .sol-part h2 { font-size: 1.35rem; margin: 0 0 8px; }
.sol .sol-part > p { color: var(--ink-2); max-width: 75ch; }
.sol .sol-erd img { display: block; width: 100%; height: auto; border: 1px solid var(--rule); background: #fff; }
.sol .sol-rels td { text-align: start; padding: 6px 8px; vertical-align: top; }
.sol .sol-rels td:last-child { color: var(--ink-2); font-size: .86rem; min-width: 16em; }
.sol .sol-notes { padding-inline-start: 20px; color: var(--ink-2); }
.sol .sol-notes li { margin-bottom: 6px; }
.sol .agreed-card { margin-bottom: 18px; }
.sol pre.code { direction: ltr; text-align: left; white-space: pre; overflow-x: auto; }
.walk-page .stages { padding-bottom: 0; }
.walk-tables tr.walk-fold .linkish { border: 0; background: none; padding: 2px 6px; color: var(--ink-2); text-decoration: underline; cursor: pointer; font: inherit; font-size: .82rem; }
.walk-one .walk-side .walk-rule:first-child { margin-top: 0; }
.walk-one .walk-side .walk-rule { margin-bottom: 12px; }
.walk-why ul { margin: 4px 0 0; padding-inline-start: 18px; font-size: .9rem; }
.walk-why li { margin-bottom: 3px; }
/* the step bar stays at the bottom of the screen, also when a step is short */
.walk-page .stages > .step:not([hidden]) { min-height: 100%; display: flex; flex-direction: column; }
.walk-page .stages > .step:not([hidden]) > .walk { flex: 1; display: flex; flex-direction: column; }
.walk-page .walk-nav { margin-top: auto; }

/* Content blocks: a system idea, Python syntax, and work students do on their own. */
.principle, .pysyntax, .selfwork { border-radius: 8px; padding: 14px 18px 8px; margin: 0 0 20px; min-width: 0; }
.principle .tag, .pysyntax .tag, .selfwork .tag { display: inline-block; font: 600 .74rem var(--font); padding: 2px 10px; border-radius: 999px; margin-bottom: 8px; }
.principle { background: #F7F1F2; border: 1px solid var(--blush); }
.principle .tag { background: var(--stamp); color: #fff; }
.principle > .tag + p { font-family: var(--font-serif); font-size: 1.08rem; line-height: 1.6; }
.principle > p, .principle > ul { margin: 0 0 8px; }
.principle .more { color: var(--ink-2); font-size: .92rem; }
.pysyntax { background: #fff; border: 1px solid var(--rule); }
.pysyntax .tag { background: #EEF0F3; color: #3E4A5A; font-family: var(--font-mono); font-weight: 500; }
.pysyntax > p { margin: 0 0 8px; }
.selfwork { background: var(--tint); border: 1px solid var(--rule); border-inline-start: 4px solid var(--ink); }
.selfwork .tag { background: var(--ink); color: #fff; }
.selfwork > p { margin: 0 0 8px; }
.selfwork .tries > li { background: #fff; }
.principle h3.sub, .pysyntax h3.sub { margin-top: 2px; }
.syntax section.principle { margin: 0 0 16px; }
.fig { margin: 4px 0 22px; }
.fig svg { width: 100%; height: auto; display: block; max-width: 640px; margin: 0 auto; }
.fig figcaption { font-size: .88rem; color: var(--ink-2); margin-top: 6px; text-align: center; }
.think { border: 1px solid var(--rule); border-radius: 8px; padding: 14px 18px 10px; margin: 0 0 20px; background: #fff; }
.think > p { margin: 0 0 8px; }
.think .hints { margin: 0 0 4px; }
.think h3.sub { margin-top: 0; }
