/* Global ownership: shell, subject layout and reusable presentation components.
   Loaded last. Legacy module selectors are adapted here, never by page-specific headers. */
:root {
  --font-body: Inter, Manrope, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: var(--font-body);
  --site-h1-size: 46px;
  --site-h2-size: 28px;
  --site-h3-size: 22px;
  --site-h4-size: 18px;
  --site-max-width: 1420px;
  --site-gutter: clamp(12px, 2.2vw, 32px);
  --page-top-space: 20px;
  --page-hero-height: 330px;
  --page-hero-gap: 32px;
  --page-hero-copy-width: 660px;
  --page-hero-copy-padding-x: clamp(24px,4vw,56px);
  --page-hero-title-size: var(--site-h1-size);
  --sidebar-width: 210px;
  --content-gap: 20px;
  --layout-gap: var(--content-gap);
  --reading-width: 1000px;
  --max-width: var(--site-max-width);
  --space-xs: 6px;
  --space-sm: 12px;
  --fold-closed-gap: var(--space-sm);
  --fold-summary-padding-y: var(--space-sm);
  --fold-title-size: 22px;
  --space-md: 20px;
  --space-lg: 32px;
  --space-xl: 48px;
  --space-section: 60px;
  --radius-sm: 7px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --color-text: var(--ink, #102927);
  --color-muted: var(--muted, #607471);
  --color-primary: var(--green-dark, #14543f);
  --color-primary-soft: #e8f0ea;
  --color-border: #dfe6e1;
  --color-surface: #fff;
  --article-reading-width: var(--reading-width);
  --article-wide-width: 100%;
  --figure-small-width: 500px;
  --figure-standard-width: 800px;
  --figure-wide-width: 100%;
  --figure-space-before: 28px;
  --figure-caption-space: 12px;
  --figure-space-after: 52px;
  --figure-pair-gap: 24px;
}

/* Colour system, approved 31 October 2026: warm neutral shell, quiet page tints.
   Only presentation colours change; scientific models retain their own codes. */
:root {
  --palette-paper:#f5f2ea;
  --palette-note:#f5f4f0;
  --palette-ink:#252b29;
  --palette-secondary:#46514b;
  --palette-muted:#666c66;
  --palette-forest:#183f35;
  --palette-green:#2d6650;
  --palette-line:#dcded6;
  --palette-sage:#e4ece1;
  --palette-sea:#dfebef;
  --palette-sand:#efe7d8;
  --palette-lavender:#e9e5ef;
  --palette-slate:#e6ebee;
  --palette-clay:#f1e3d8;
  --palette-ochre:#c28b35;
  --palette-ochre-ink:#77541f;
  --palette-biology:#37694b;
  --palette-geography:#2c6f8a;
  --palette-science:#74578f;
  --dictionary-biology-border:#6b9979;
  --dictionary-geography-border:#6d98ad;
  --dictionary-science-border:#9781b1;
}
body:not(.pg-game-host-page) {
  color:var(--color-text);
  background-color:var(--paper);
  --article-copy:var(--palette-ink);
  --article-ink:var(--palette-ink);
  --article-muted:var(--palette-muted);
  --article-background:#fff;
  --page-background:var(--palette-paper);
  --article-line:var(--palette-line);
  --article-line-strong:var(--palette-line);
  --article-accent:var(--color-primary);
  --article-accent-soft:var(--theme-soft);
  --article-note:var(--surface-soft);
  --ink:var(--palette-ink);
  --ink-soft:var(--palette-secondary);
  --muted:var(--palette-muted);
  --paper:var(--palette-paper);
  --surface:#fff;
  --green-dark:var(--palette-forest);
  --green:var(--palette-green);
  --blue:var(--palette-geography);
  --blue-dark:#25566c;
  --amber:var(--palette-ochre);
  --color-text:var(--ink);
  --color-muted:var(--muted);
  --color-primary:var(--theme-ink);
  --color-primary-hover:color-mix(in srgb, var(--color-primary) 85%, black);
  --color-primary-soft:var(--theme-soft);
  --color-accent:var(--amber);
  --color-button:var(--color-primary);
  --line:var(--palette-line);
  --color-border:var(--line);
  --theme-soft:var(--palette-sand);
  --theme-ink:#5b4b37;
  --page-tint:239,231,216;
  --surface-soft:color-mix(in srgb, var(--theme-soft) 45%, white);
  --table-header:var(--theme-soft);
  --table-rowhead:color-mix(in srgb, var(--theme-soft) 55%, white);
  --table-stripe:color-mix(in srgb, var(--theme-soft) 22%, white);
  --table-hover:color-mix(in srgb, var(--theme-soft) 65%, white);
  --table-unavailable:#e5e5df;
}
body[data-current-page="forside"] { --theme-soft:var(--palette-paper); --page-tint:245,242,234; --color-primary:var(--palette-forest); --color-primary-soft:var(--palette-sage); --color-primary-hover:var(--palette-green); }
body[data-current-page="biologi"] { --theme-soft:var(--palette-sage); --theme-ink:#254c36; --page-tint:228,236,225; }
body[data-current-page="naturgeografi"] {
  --theme-soft:var(--palette-sea); --theme-ink:#25566c; --page-tint:223,235,239;
  --green-dark:var(--theme-ink); --green:var(--palette-geography); --mint:var(--palette-sea);
  --ink-soft:#47545c; --muted:#64717a;
  --hero-fallback-start:#112a3a; --hero-fallback-middle:#1b4055; --hero-fallback-end:#35677f;
  --hero-overlay-rgb:10,25,38;
}
body[data-current-page="skriftlighed"] { --theme-soft:var(--palette-lavender); --theme-ink:#514365; --page-tint:233,229,239; }
body[data-current-page="ordbog"] { --theme-soft:var(--palette-slate); --theme-ink:#435863; --page-tint:230,235,238; }
body[data-current-page="om-mark"] { --theme-soft:var(--palette-clay); --theme-ink:#714c37; --page-tint:241,227,216; }
body:not(.pg-game-host-page)::before {
  background:radial-gradient(ellipse at center, rgba(245,242,234,.95) 0%, rgba(var(--page-tint),.84) 58%, rgba(var(--page-tint),.72) 100%), rgba(245,242,234,.60);
}
body:not(.pg-game-host-page) .page-background { background:var(--paper); }
/* Preserve the original UI palette inside interactive teaching models and games. */
:is(.subject-model,.inheritance-lab,.pg-standalone,.pg-game-page,.gb-protein-game,[data-protein-game]) {
  --ink:#18231e; --ink-soft:#45534c; --muted:#647069;
  --paper:#f7f8f4; --surface:#fff; --surface-soft:#eaf1ec; --line:#dde3de;
  --green:#285f49; --green-dark:#214d3c; --blue:#3e6f70; --blue-dark:#31595a; --amber:#c79443;
  --color-text:var(--ink); --color-muted:var(--muted); --color-primary:var(--green-dark);
  --color-primary-soft:#e8f0ea; --color-primary-hover:var(--green); --color-border:var(--line);
}

.site-header, .site-header * { box-sizing:border-box; font-family:var(--font-body, "Segoe UI", sans-serif); }
.site-header {
  position: sticky; z-index: 100; top: 10px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  width: min(calc(100% - 2 * var(--site-gutter)), var(--site-max-width));
  height: 62px; min-height: 62px; margin: 10px auto 0; padding: 7px 14px;
  isolation: isolate; border: 0; border-radius: var(--radius-lg); background: transparent;
}
.site-header::before { content: ''; position: absolute; z-index: -1; inset: 0; background: rgba(250,248,243,.88); border: 1px solid rgba(27,32,30,.17); border-radius: inherit; box-shadow: 0 8px 28px rgba(24,35,30,.09); backdrop-filter: blur(18px); pointer-events:none; }
.site-header .logo { display:flex; align-items:center; flex:0 0 auto; gap:9px; color:var(--color-text); text-decoration:none; }
.site-header .logo-mark { display:grid; place-items:center; width:40px; height:40px; overflow:hidden; border-radius:50%; }
.site-header .logo-mark img { display:block; width:100%; height:100%; object-fit:contain; }
.site-header .logo-copy { display:grid; gap:2px; }
.site-header .logo-text { font-size:16px; font-weight:850; line-height:1.1; }
.site-header .logo-tagline { font-size:10px; font-weight:650; line-height:1.2; }
.site-header .main-nav { display:flex; align-items:center; gap:3px; min-width:0; overflow-x:auto; scrollbar-width:none; }
.site-header .main-nav::-webkit-scrollbar { display:none; }
.site-header .nav-button { display:inline-flex; align-items:center; justify-content:center; flex:0 0 auto; height:38px; padding:7px 10px; color:var(--palette-ink, #252b29); border:0; border-radius:var(--radius-sm); background:transparent; font-size:14px; font-weight:650; line-height:1.3; white-space:nowrap; text-decoration:none; }
.site-header .nav-button:is(:hover,.is-active) { color:var(--theme-ink, var(--color-primary)); background:var(--theme-soft, var(--color-primary-soft)); }
.site-header .nav-button.is-active { box-shadow:inset 0 -2px var(--theme-ink, var(--color-primary)); }
body #main-content, body .site-footer { width:min(calc(100% - 2 * var(--site-gutter)),var(--site-max-width)); max-width:none; margin-inline:auto; }
/* Every ordinary page starts the same calm distance below the toolbar.
   Subject pages already own this value through their shared shell. */
body:not(.subject-page) #main-content > .page { padding-top:var(--page-top-space); }
body[data-current-page="forside"] #main-content > #forside { padding-top:0; }
body[data-current-page="forside"] #forside .home-opening > .hero { padding-top:0; }
body[data-current-page="forside"] .home-opening {
  display:flex;
  flex-direction:column;
  min-height:calc(100svh - 72px);
}
body[data-current-page="forside"] .home-opening > .subject-hub-section { margin-top:auto; }
@media (max-width:640px) {
  body[data-current-page="forside"] .home-opening { min-height:calc(100svh - 62px); }
}
body[data-current-page="ordbog"] #main-content .dictionary-tools { margin-top:0; }
/* Dictionary search: one clear working area with a quiet reviewer aside. */
body[data-current-page="ordbog"] #main-content .dictionary-tools {
  width:100%;
  grid-template-columns:minmax(0,1fr);
  grid-template-areas:"title" "search" "tabs" "topics";
  margin:0;
  gap:12px 36px;
  align-items:center;
  padding:24px 32px;
  isolation:isolate;
  background:linear-gradient(135deg,#fff 25%,var(--surface-soft));
  border:1px solid var(--color-border);
  border-radius:22px;
  box-shadow:inset 0 0 0 5px rgba(255,255,255,.72),
    0 12px 32px rgba(37,43,41,.08),0 2px 5px rgba(37,43,41,.03);
}
body[data-current-page="ordbog"] #main-content .dictionary-search-title {
  grid-area:title; margin:0; color:var(--color-primary);
  font-size:22px; font-weight:750; line-height:1.3;
}
body[data-current-page="ordbog"] #main-content .dictionary-search-row { grid-area:search; }
body[data-current-page="ordbog"] #main-content .dictionary-search-field input {
  min-height:64px; border-radius:14px; background:rgba(255,255,255,.96);
  border-color:var(--color-border); font-size:17px; font-weight:500;
  box-shadow:0 4px 14px rgba(16,41,39,.045),inset 0 1px 0 #fff;
}
body[data-current-page="ordbog"] #main-content .dictionary-search-field input:focus {
  border-color:var(--color-primary); box-shadow:0 0 0 3px color-mix(in srgb,var(--color-primary) 15%,transparent);
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tabs {
  grid-area:tabs; width:100%; justify-self:start;
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tabs legend {
  position:absolute; width:1px; height:1px; margin:-1px; padding:0;
  overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap;
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tabs .dictionary-filter-options {
  display:flex; flex-wrap:wrap; gap:8px; padding:0; border:0;
  border-radius:0; background:none; box-shadow:none; overflow:visible;
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tab {
  width:auto; min-height:40px; padding:9px 18px; border-radius:999px;
  color:var(--subject-strong); background:var(--subject-soft);
  border:1px solid var(--subject-line); box-shadow:none;
  font-size:14px; font-weight:650; transform:none;
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tab::after { display:none; }
body[data-current-page="ordbog"] #main-content .dictionary-subject-tab:hover {
  border-color:var(--subject-color); transform:none; box-shadow:none;
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tab.is-active {
  color:white; background:var(--subject-strong); border-color:var(--subject-strong);
  box-shadow:none; transform:none;
}
body[data-current-page="ordbog"] #main-content .dictionary-subject-tab:focus-visible {
  outline:2px solid var(--subject-strong); outline-offset:3px;
}
body[data-current-page="ordbog"] #main-content .dictionary-search-panel { display:grid; grid-template-columns:minmax(0,1fr) 220px; gap:24px; align-items:start; margin:28px 0; }
body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip {
  position:relative; display:flex; flex-direction:column-reverse;
  align-items:center; gap:8px; margin:0; padding:22px 18px 18px;
  border:0; border-radius:0;
  background:linear-gradient(145deg,#fff2a9,#f6e48a); color:#24416c;
  box-shadow:2px 8px 18px rgba(56,49,24,.16);
  transform:rotate(1.5deg);
  font-family:"Segoe Print","Bradley Hand","Comic Sans MS",cursive;
}
body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip::before { content:""; position:absolute; top:-10px; left:calc(50% - 34px); width:68px; height:24px; background:rgba(255,253,231,.65); transform:rotate(-4deg); }
body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip p {
  margin:0; padding:0; border:0; background:none; box-shadow:none;
  color:inherit; font-family:inherit; font-size:15px; line-height:1.55; text-align:left;
}
body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip p::after { display:none; }
body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip img {
  width:100px; height:84px; object-fit:contain;
}
body[data-current-page="ordbog"] #main-content .dictionary-topic-group { grid-area:topics; }
@media(max-width:980px) {
  body[data-current-page="ordbog"] #main-content .dictionary-tools {
    gap:12px; padding:24px;
  }

}
@media(max-width:760px) {
  body[data-current-page="ordbog"] #main-content .dictionary-tools {
    grid-template-columns:minmax(0,1fr);
    grid-template-areas:"title" "search" "tabs" "topics";
    gap:12px; padding:20px 16px;
  }
  body[data-current-page="ordbog"] #main-content .dictionary-search-title { font-size:20px; }
  body[data-current-page="ordbog"] #main-content .dictionary-search-field input { font-size:16px; min-height:54px; }
  body[data-current-page="ordbog"] #main-content .dictionary-subject-tab { padding:8px 12px; font-size:13px; }
  body[data-current-page="ordbog"] #main-content .dictionary-search-panel { grid-template-columns:minmax(0,1fr); gap:0; }
  body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip {
    width:100%; justify-self:stretch; margin:10px 0 0; padding:12px 14px;
    flex-direction:row-reverse; gap:12px; transform:none;
    background:var(--palette-note); border:1px solid var(--color-border);
    border-radius:var(--radius-sm); box-shadow:none;
  }
  body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip::before { display:none; }
  body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip img { flex:0 0 56px; width:56px; height:48px; }
  body[data-current-page="ordbog"] #main-content .dictionary-feedback-tip p { font-size:14px; line-height:1.45; }
}
/* Dictionary cards have different amounts of useful content. On a wide screen,
   their measured row spans pack the next card into the available space. */
@media(min-width:981px) {
  body[data-current-page="ordbog"] #main-content .dictionary-grid[data-masonry-ready="true"] {
    /* Spacing is included in the measured row span, avoiding variable gaps. */
    row-gap:0;
    column-gap:32px;
    grid-auto-flow:row dense;
    grid-auto-rows:1px;
  }
  body[data-current-page="ordbog"] #main-content .dictionary-grid[data-masonry-ready="true"] .dictionary-card {
    align-self:start;
  }
}
/* Canonical ordinary academic type and reading measure for every subject page. */
body { font-family:var(--font-body); }
button, input, select, textarea { font-family:var(--font-body); }
body #main-content :is(h1,h2,h3,h4,p,li,dt,dd,summary) { font-family:var(--font-body); }
body.subject-page { --fold-content-padding-top:20px; --article-reading-width:var(--reading-width); --article-wide-width:100%; --article-frame-padding-x:clamp(36px,4vw,56px); --article-frame-padding-y:var(--article-frame-padding-x); }
body.subject-page,
body[data-current-page="om-mark"] {
  /* Content hierarchy; hero H1 and exceptional pages keep their own scale. */
  --site-h2-size:26px;
  --site-h3-size:22px;
  --site-h4-size:20px;
  /* One surface palette; legacy names remain aliases for existing markup. */
  --color-border:var(--line);
  --radius:var(--radius-sm);
  --radius-card:10px;
  --shadow-card:none;
  --subject-body-size:18px;
  --subject-body-line-height:1.78;
  --subject-paragraph-space:28px;
  --subject-space-before-h2:60px;
  --subject-space-before-h3:38px;
  --subject-space-after-heading:24px;
  --subject-space-before-h4:28px;
  --subject-space-after-h4:10px;
}
body.subject-page #main-content { padding:20px 0 0; }
body.subject-page #main-content > .page, body.subject-page .writing-hub { padding-top:0; }
body.subject-page #main-content .subject-layout { display:grid; grid-template-columns:var(--sidebar-width) minmax(0,1fr); gap:var(--layout-gap); width:100%; max-width:none; margin:0; padding:0 0 var(--space-xl); align-items:start; }
body.subject-page #main-content .article-column { min-width:0; width:100%; max-width:none; }
body.subject-page #main-content .subject-sidebar { display:block; position:sticky; top:92px; width:var(--sidebar-width); max-height:calc(100dvh - 112px); margin:0; padding:8px; overflow-y:auto; scrollbar-width:thin; background:var(--color-surface); border:1px solid var(--color-border); border-radius:var(--radius-md); box-shadow:0 6px 20px rgba(22,48,36,.035); }
body.subject-page #main-content .subject-mobile-menu { display:none; }
body.subject-page #main-content .subject-mobile-menu > summary { list-style:none; }
body.subject-page #main-content .subject-mobile-menu > summary::-webkit-details-marker { display:none; }
body.subject-page #main-content .subject-mobile-menu > summary::marker { content:""; }
body.subject-page #main-content :is(.subject-sidebar,.subject-mobile-menu) { --subject-menu-font-size:14px; --subject-menu-line-height:1.3; --subject-menu-font-weight:650; --subject-menu-item-gap:3px; --subject-menu-indent:12px; }
body.subject-page #main-content :is(.subject-sidebar,.subject-mobile-menu) :is(.subject-menu-section,nav) { min-width:0; }
body.subject-page #main-content :is(.subject-sidebar,.subject-mobile-menu) nav { display:grid; gap:var(--subject-menu-item-gap); }
body.subject-page #main-content .subject-menu-group { display:grid; min-width:0; gap:var(--subject-menu-item-gap); }
body.subject-page #main-content .subject-menu-link { box-sizing:border-box; display:flex; min-width:0; align-items:center; gap:6px; width:100%; min-height:32px; padding:7px 8px; overflow-wrap:anywhere; color:var(--ink-soft); border:0; border-radius:var(--radius-sm); font-family:inherit; font-size:var(--subject-menu-font-size); font-weight:var(--subject-menu-font-weight); line-height:var(--subject-menu-line-height); text-decoration:none; background:transparent; cursor:pointer; }
body.subject-page #main-content .subject-menu-link:hover,
body.subject-page #main-content .subject-menu-link:focus-visible { color:var(--color-primary); background:var(--surface-soft); }
body.subject-page #main-content .subject-menu-link:focus-visible { outline:2px solid var(--color-primary); outline-offset:2px; }
body.subject-page #main-content .subject-menu-link:is(.is-active,[aria-current="page"]) { color:var(--theme-ink); background:var(--theme-soft); box-shadow:inset 2px 0 var(--theme-ink); }
body.subject-page #main-content .subject-menu-link.is-parent-active { color:var(--color-primary); background:var(--surface-soft); }
body.subject-page #main-content .subject-menu-children { display:grid; min-width:0; gap:var(--subject-menu-item-gap); margin:2px 0 4px var(--subject-menu-indent); padding-left:8px; border-left:1px solid var(--color-border); }
body.subject-page #main-content .subject-menu-children .subject-menu-children { margin-left:8px; }
body.subject-page #main-content .subject-menu-children[hidden] { display:none; }
body.subject-page #main-content .subject-menu-group > summary { list-style:none; }
body.subject-page #main-content .subject-menu-group > summary::-webkit-details-marker { display:none; }
body.subject-page #main-content .subject-menu-group > summary::marker { content:""; }
body.subject-page #main-content .article-surface { --article-reading-width:var(--reading-width); display:block; width:100%; min-width:0; margin:0; padding:var(--article-frame-padding-y) var(--article-frame-padding-x); color:var(--color-text); background:var(--color-surface); border:1px solid var(--color-border); border-radius:var(--radius-lg); box-shadow:var(--shadow-card); }
body.subject-page #main-content :is(.biology-home-chapter,.biology-eukaryote-chapter,.subject-overview-chapter) { padding:var(--article-frame-padding-y) var(--article-frame-padding-x); }
/* Biology article surfaces clip the full-bleed in-content hero to the surface frame. */
body.subject-page[data-current-page="biologi"] #main-content .article-surface { overflow:hidden; }
body.subject-page #main-content .article-page :is(.article-content,.writing-reading,.article-section) { max-width:none; margin-inline:0; }
body.subject-page #main-content .writing-reading { width:100%; padding:0; border:0; background:transparent; box-shadow:none; }
/* Common textbook rhythm. These selectors deliberately exclude navigation and named UI components. */
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(p, ul, ol, dl),
body.subject-page #main-content .article-page .biology-section-heading > p {
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin:0 auto var(--subject-paragraph-space);
  color:var(--color-text);
  font-size:var(--subject-body-size);
  font-weight:400;
  line-height:var(--subject-body-line-height);
}
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(p, ul, ol, dl) :is(strong,b) { font-weight:700; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(p, ul, ol, dl) :is(em,i) { font-style:italic; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(p, ul, ol, dl) a:not(.button-primary, .button-secondary, .primary-button, .secondary-button) { color:var(--color-primary); text-decoration:underline; text-underline-offset:2px; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > p + p,
body.subject-page #main-content .article-page .biology-section-heading > p + p { margin-top:0; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(ul, ol) { padding-left:1.35em; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(ul, ol) > li { margin:0; font-size:inherit; line-height:inherit; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > :is(ul, ol) > li + li { margin-top:6px; }
body.subject-page #main-content .article-page :is(h1,h2,h3,h4) { overflow-wrap:anywhere; }
body.subject-page #main-content .article-page h1 { font-size:var(--site-h1-size); line-height:1.1; font-weight:700; }
body.subject-page #main-content .article-page :is(.article-content, .writing-reading > section) > h2 { width:min(100%,var(--reading-width)); max-width:var(--reading-width); margin:0 auto var(--subject-space-after-heading); font-size:var(--site-h2-size); font-weight:650; line-height:1.25; letter-spacing:0; }
body.subject-page #main-content .article-page .article-section > h2,
body.subject-page #main-content .article-page .biology-section-heading > h2 { width:min(100%,var(--reading-width)); max-width:var(--reading-width); margin:var(--subject-space-before-h2) auto var(--subject-space-after-heading); font-size:var(--site-h2-size); font-weight:650; line-height:1.25; letter-spacing:0; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > h3,
body.subject-page #main-content .article-page .biology-section-heading > h3 { width:min(100%,var(--reading-width)); max-width:var(--reading-width); margin:var(--subject-space-before-h3) auto var(--subject-space-after-heading); font-size:var(--site-h3-size); font-weight:650; line-height:1.3; letter-spacing:0; }
body.subject-page #main-content .article-page :is(.article-content, .article-section, .writing-reading > section) > h4 { width:min(100%,var(--reading-width)); max-width:var(--reading-width); margin:var(--subject-space-before-h4) auto var(--subject-space-after-h4); font-size:var(--site-h4-size); font-weight:650; line-height:1.4; letter-spacing:0; }
body.subject-page #main-content .article-page :is(.article-content, .writing-reading > section) > h2:not(:first-child) { margin-top:var(--subject-space-before-h2); }
body.subject-page #main-content .article-page .article-section { margin-block:0; padding-block:0; border-block:0; }
body.subject-page #main-content .article-page .writing-reading > section { margin-block:var(--subject-space-before-h2) 0; padding-block:0; border-block:0; }
/* A new paper already supplies its frame padding, including after a summary. */
body.subject-page #main-content .article-page > .writing-reading:first-child > section:first-child,
body.subject-page #main-content .article-page > .writing-reading.report-paper-content > section:first-child { margin-top:0; }
body.subject-page #main-content .subject-section-divider { display:none; }
/* Shared roles cover nested legacy prose without changing grids or models.
   The class is assigned by prepareTypography after each subject render. */
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) .subject-text-heading {
  max-width:var(--reading-width);
  color:var(--color-text);
  font-family:var(--font-heading);
  font-weight:650;
  letter-spacing:0;
  text-wrap:balance;
  margin-bottom:var(--subject-space-after-heading);
}
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) h2.subject-text-heading { font-size:var(--site-h2-size); line-height:1.25; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) h3.subject-text-heading { font-size:var(--site-h3-size); line-height:1.3; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) h4.subject-text-heading { font-size:var(--site-h4-size); line-height:1.4; margin-bottom:var(--subject-space-after-h4); }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) h3.subject-text-heading:not(.subject-compact-heading) { margin-top:var(--subject-space-before-h3); }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) h4.subject-text-heading:not(.subject-compact-heading) { margin-top:var(--subject-space-before-h4); }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) :is(h3,h4).subject-text-heading:first-child { margin-top:0; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) .subject-compact-heading { margin-top:0; margin-bottom:12px; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) h2.subject-compact-heading { font-size:var(--site-h3-size); line-height:1.3; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) .subject-copy {
  width:min(100%,var(--reading-width)); max-width:var(--reading-width);
  margin:0 auto var(--subject-paragraph-space);
  color:var(--color-text); font-size:var(--subject-body-size); font-weight:400; line-height:var(--subject-body-line-height);
}
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) :is(.subject-copy,.subject-compact-copy) :is(strong,b) { font-weight:700; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) :is(ul,ol).subject-copy { padding-left:1.35em; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) :is(ul,ol).subject-copy > li { font-size:inherit; line-height:inherit; }
body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) .subject-compact-copy { color:var(--color-muted); font-size:17px; font-weight:400; line-height:1.7; }
/* The article frame owns the introduction inset; nested prose adds none. */
body.subject-page #main-content .biology-materials-overview { padding:0; }
/* One academic heading scale across the subject pages. Hero colour may follow
   its background, but ordinary content never gets a page-specific scale. */
body.subject-page #main-content .article-page:not(.pg-standalone) h1:not(.pg-back),
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(.writing-overview-head,.writing-subpage-head) h1 {
  font-size:var(--site-h1-size);
  font-weight:700;
  line-height:1.1;
  letter-spacing:0;
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(.writing-overview-head,.writing-subpage-head) h1 {
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin-inline:auto;
  text-align:left;
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(.writing-intro-panel,.writing-reading,.writing-start,.writing-situation-guide) > h2,
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page .writing-reading > section > h2,
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page .writing-downloads h2 {
  color:var(--color-text);
  font-size:var(--site-h2-size);
  font-weight:650;
  line-height:1.25;
  letter-spacing:0;
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(h3,h4):not(.writing-guide-item summary *) {
  color:var(--color-text);
  font-weight:650;
  letter-spacing:0;
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page h3:not(.writing-guide-item summary *) {
  font-size:var(--site-h3-size);
  line-height:1.3;
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page h4:not(.writing-guide-item summary *) {
  font-size:var(--site-h4-size);
  line-height:1.4;
}

/* Writing prose shares the academic roles even inside examples and disclosures.
   Keep only genuine compact UI/card text at the overview component scale. */
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(.writing-before-after,.writing-example,.subject-callout,.writing-guide-answer) :is(p,ul,ol,dl).subject-copy {
  font-family:var(--font-body);
  font-size:var(--subject-body-size);
  line-height:var(--subject-body-line-height);
  font-weight:400;
  margin-block:0 var(--subject-paragraph-space);
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(.writing-before-after,.writing-example,.subject-callout,.writing-guide-answer) > :last-child.subject-copy,
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page .writing-before-after > div > :last-child.subject-copy { margin-bottom:0; }
body.subject-page[data-current-page="skriftlighed"] #main-content .article-page.writing-page :is(.srp-topic,.writing-four-grid,.writing-term-grid,.writing-interest-grid) .subject-compact-copy {
  font-size:16px;
  line-height:1.55;
}
body:is([data-current-page="skriftlighed"], [data-writing-view="srp"]) #main-content .writing-page :is(.mini-example,.writing-checklist) {
  font-family:var(--font-body);
  font-size:var(--subject-body-size);
  line-height:var(--subject-body-line-height);
}

/* "Om siden" keeps its personal opening header, while its content hierarchy
   uses the same H3/H4 scale as the academic pages. */
body[data-current-page="om-mark"] #main-content #om-mark :is(h3,h4) {
  color:var(--color-text);
  font-weight:650;
  letter-spacing:0;
}
body[data-current-page="om-mark"] #main-content #om-mark h3 {
  font-size:var(--site-h3-size);
  line-height:1.3;
}
body[data-current-page="om-mark"] #main-content #om-mark h4 {
  font-size:var(--site-h4-size);
  line-height:1.4;
}
/* Canonical subject overviews: wide, flat information surfaces that follow
   ordinary prose without becoming unrelated cards. */
body.subject-page #main-content :is(.biology-method-list,.biology-level-list,.biology-home-paths,.biology-career-list,.subject-career-list) {
  box-sizing:border-box;
  width:100%;
  max-width:none;
  margin:28px 0 0;
  padding:0;
  color:var(--color-text);
  border-top:1px solid var(--color-border);
  border-bottom:1px solid var(--color-border);
  background:transparent;
  box-shadow:none;
}
body.subject-page[data-current-page="biologi"] #main-content .biology-method-list {
  display:grid;
  list-style:none;
}
body.subject-page[data-current-page="biologi"] #main-content .biology-method-list li {
  display:grid;
  gap:4px;
  padding:20px 0;
  border-bottom:1px solid var(--color-border);
}
body.subject-page[data-current-page="biologi"] #main-content .biology-method-list li:last-child { border-bottom:0; }
body.subject-page[data-current-page="biologi"] #main-content .biology-method-list strong,
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) strong {
  color:var(--color-primary);
  font-size:18px;
  font-weight:650;
  line-height:1.35;
}
body.subject-page[data-current-page="biologi"] #main-content .biology-method-list span,
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) span,
body.subject-page #main-content .biology-level-list p,
body.subject-page #main-content .biology-home-paths p {
  margin:0;
  color:var(--color-muted);
  font-size:16px;
  font-weight:400;
  line-height:1.55;
}
body.subject-page #main-content .biology-level-list { display:grid; }
body.subject-page #main-content .biology-level-list > .biology-level-row {
  display:grid;
  grid-template-columns:minmax(180px,.28fr) minmax(0,1fr);
  gap:32px;
  align-items:start;
  padding:24px;
  color:inherit;
  border-bottom:1px solid var(--color-border);
  text-decoration:none;
  transition:background-color .15s ease;
}
body.subject-page #main-content .biology-level-list > .biology-level-row:last-child { border-bottom:0; }
body.subject-page #main-content .biology-level-list h3,
body.subject-page #main-content .biology-home-paths h3 {
  margin:0 0 6px;
  color:var(--color-text);
  font-size:22px;
  font-weight:650;
  line-height:1.3;
}
body.subject-page #main-content .biology-level-list > .biology-level-row > div:first-child p {
  color:var(--color-primary);
  font-size:16px;
  font-weight:650;
}
body.subject-page #main-content :is(.biology-level-list > .biology-level-row,.biology-home-paths > a):is(:hover,:focus-visible) {
  background:var(--color-primary-soft);
  box-shadow:none;
  outline:0;
}
body.subject-page #main-content .biology-home-paths {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
}
body.subject-page #main-content .biology-home-paths > a {
  display:block;
  min-width:0;
  padding:24px;
  color:inherit;
  text-decoration:none;
  transition:background-color .15s ease;
}
body.subject-page #main-content .biology-home-paths > a:nth-child(even) { border-left:1px solid var(--color-border); }
body.subject-page #main-content .biology-home-paths > a:nth-child(n + 3) { border-top:1px solid var(--color-border); }
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  column-gap:34px;
  list-style:none;
}
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li {
  display:grid;
  gap:6px;
  min-width:0;
  padding:20px 24px;
  border-bottom:1px solid var(--color-border);
}
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li:nth-last-child(-n + 2):not(:last-child:nth-child(odd)),
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li:last-child:nth-child(even) { border-bottom:0; }
body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li:last-child:nth-child(odd) {
  grid-column:1 / -1;
  border-bottom:0;
}
@media(max-width:640px) {
  body.subject-page #main-content .biology-level-list > .biology-level-row { grid-template-columns:1fr; gap:8px; padding:20px 0; }
  body.subject-page #main-content .biology-home-paths,
  body.subject-page #main-content :is(.biology-career-list,.subject-career-list) { grid-template-columns:1fr; }
  body.subject-page #main-content .biology-home-paths > a { padding:20px 0; }
  body.subject-page #main-content .biology-home-paths > a + a { border-top:1px solid var(--color-border); border-left:0; }
  body.subject-page #main-content :is(.biology-career-list,.subject-career-list) { column-gap:0; }
  body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li,
  body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li:nth-last-child(-n + 2):not(:last-child:nth-child(odd)) { padding:20px 0; border-bottom:1px solid var(--color-border); }
  body.subject-page #main-content :is(.biology-career-list,.subject-career-list) li:last-child { border-bottom:0; }
}
/* “Om siden” keeps its own visual composition, but ordinary copy follows the
   same academic type scale as the subject pages. Named visual elements remain
   local exceptions. */
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) > p:not(.about-lede, .about-signoff, .about-quote) {
  width:min(100%,var(--reading-width));
  margin:0 auto var(--subject-paragraph-space);
  color:var(--color-text);
  font-size:var(--subject-body-size);
  font-weight:400;
  line-height:var(--subject-body-line-height);
}
body[data-current-page="om-mark"] #om-mark .about-copy > p:not(.about-lede, .about-signoff) { max-width:var(--reading-width); }
body[data-current-page="om-mark"] #om-mark .about-copy > :is(h1,p) {
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin-inline:auto;
}
body[data-current-page="om-mark"] #om-mark .about-copy > p:not(.about-lede, .about-signoff) {
  margin-bottom:var(--subject-paragraph-space);
}
body[data-current-page="om-mark"] #om-mark .about-copy > .about-lede {
  margin-bottom:var(--subject-paragraph-space);
}
body[data-current-page="om-mark"] #om-mark .about-copy > .about-signoff {
  margin:0 auto;
}
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) :is(h2,h3,h4):not(.about-ai-points *) {
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin-inline:auto;
  color:var(--color-text);
  font-weight:650;
  letter-spacing:0;
}
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) h2 { margin:0 auto var(--subject-space-after-heading); font-size:var(--site-h2-size); line-height:1.25; }
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) h3 { margin:var(--subject-space-before-h3) auto var(--subject-space-after-heading); font-size:var(--site-h3-size); line-height:1.3; }
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) h4 { margin:var(--subject-space-before-h4) auto var(--subject-space-after-h4); font-size:var(--site-h4-size); line-height:1.4; }
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) > :is(ul,ol):not(.about-ai-points *) {
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin:0 auto var(--subject-paragraph-space);
  padding-left:1.35em;
  color:var(--color-text);
  font-size:var(--subject-body-size);
  line-height:var(--subject-body-line-height);
}
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) > :is(ul,ol):not(.about-ai-points *) > li + li { margin-top:6px; }
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) :is(p,li) :is(strong,b) { font-weight:700; }
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) :is(p,li) :is(em,i) { font-style:italic; }
body[data-current-page="om-mark"] #om-mark :is(.about-copy, .about-section-card, .about-text-flow) :is(p,li) a:not(.button-primary, .button-secondary, .primary-button, .secondary-button) { color:var(--color-primary); text-decoration:underline; text-underline-offset:2px; }
/* Om siden: welcome first, balanced project columns, AI disclosure last. */
body[data-current-page="om-mark"] #om-mark {
  display:flex;
  flex-direction:column;
  width:100%;
  max-width:none;
  margin-inline:auto;
  gap:32px;
}
body[data-current-page="om-mark"] #om-mark > :is(section,aside) { margin:0; min-width:0; }
body[data-current-page="om-mark"] #om-mark > .about-hero { order:-1; width:100% !important; }
body[data-current-page="om-mark"] #om-mark > .about-ai-note { order:1; }
body[data-current-page="om-mark"] #om-mark .about-card-columns { columns:2; column-gap:24px; }
body[data-current-page="om-mark"] #om-mark .about-card-columns > .about-section-card {
  display:flow-root;
  width:100%;
  margin:0 0 24px;
  break-inside:avoid;
}
@media(max-width:980px) {
  body[data-current-page="om-mark"] #om-mark .about-card-columns { columns:1; }
  body[data-current-page="om-mark"] #om-mark .about-card-columns > .about-section-card:last-child { margin-bottom:0; }
}
body[data-current-page="om-mark"] #om-mark .about-hero {
  grid-template-columns:minmax(0,1fr) minmax(280px,320px);
  gap:28px;
  padding:0;
}
body[data-current-page="om-mark"] #om-mark .about-copy,
body[data-current-page="om-mark"] #om-mark .about-section-card,
body[data-current-page="om-mark"] #om-mark .about-ai-note { border:1px solid var(--color-border); border-radius:var(--radius-lg); box-shadow:var(--shadow-card); }
body[data-current-page="om-mark"] #om-mark .about-copy { padding:clamp(30px,4vw,46px); }
body[data-current-page="om-mark"] #om-mark .about-text-flow {
  width:100%;
  max-width:none;
  margin-inline:auto;
}
body[data-current-page="om-mark"] #om-mark .about-section-card {
  --subject-paragraph-space:18px;
}
body[data-current-page="om-mark"] #om-mark .about-section-card :is(h2,p),
body[data-current-page="om-mark"] #om-mark .about-section-card .about-text-flow > :is(h2,p) {
  width:100%;
  max-width:none;
  margin-inline:0;
}
body[data-current-page="om-mark"] #om-mark .about-section-card p:last-child { margin-bottom:0; }
body[data-current-page="om-mark"] #om-mark .about-reality-card {
  background:linear-gradient(135deg,#fff,#edf5ed);
}
body[data-current-page="om-mark"] #om-mark [data-section="about.portal"] {
  background:linear-gradient(135deg,#fff,#fcf4e8);
}
body[data-current-page="om-mark"] #om-mark [data-section="about.independence"] {
  background:linear-gradient(135deg,#fff,#edf5fa);
}
body[data-current-page="om-mark"] #om-mark .about-mascot-card {
  background:linear-gradient(135deg,#fff,#edf5ed);
}
body[data-current-page="om-mark"] #om-mark .about-ai-card {
  background:linear-gradient(135deg,#fff,#edf5fa);
}
body[data-current-page="om-mark"] #om-mark .about-disclaimer-card {
  background:linear-gradient(135deg,#fff,#fcf4e8);
}

body[data-current-page="om-mark"] #om-mark .about-disclaimer-layout {
  display:block;
}
body[data-current-page="om-mark"] #om-mark .about-disclaimer-layout .about-text-flow { display:flow-root; }
body[data-current-page="om-mark"] #om-mark .about-reality-layout {
  display:block;
}
body[data-current-page="om-mark"] #om-mark .about-reality-layout .about-text-flow {
  display:flow-root;
}
body[data-current-page="om-mark"] #om-mark .about-section-card,
body[data-current-page="om-mark"] #om-mark .about-ai-note {
  animation:none;
  transition:none;
  transform:none;
}
body[data-current-page="om-mark"] #om-mark .about-section-card:hover {
  transform:none;
  box-shadow:var(--shadow-card);
}
body[data-current-page="om-mark"] #om-mark .about-mascot-card {
  display:flow-root;
  margin:0;
}
@media(min-width:901px) {
  body[data-current-page="om-mark"] #om-mark .about-mascot-card .lunde-scene {
    float:right;
    width:min(36%,180px);
    max-width:180px;
    margin:0 0 16px 20px;
  }
}
body[data-current-page="om-mark"] #om-mark .about-reality-figure {
  float:right;
  display:block;
  width:clamp(220px,24vw,280px);
  max-width:280px;
  min-height:0;
  margin:0 0 var(--subject-paragraph-space) clamp(24px,3vw,40px);
  padding:0;
  overflow:visible;
}
body[data-current-page="om-mark"] #om-mark .about-reality-figure::before { right:0; left:0; bottom:2px; }
body[data-current-page="om-mark"] #om-mark .about-reality-figure::after { display:none; }
body[data-current-page="om-mark"] #om-mark .about-reality-lars { display:block; width:100%; max-width:280px; height:auto; }
body[data-current-page="om-mark"] #om-mark .about-ai-content {
  grid-template-columns:minmax(0,1fr) minmax(270px,.42fr);
  gap:clamp(24px,3vw,36px);
  align-items:start;
}
body[data-current-page="om-mark"] #om-mark .about-ai-copy > p {
  margin:0 0 var(--subject-paragraph-space);
  color:var(--color-text);
  font-size:var(--subject-body-size);
  line-height:var(--subject-body-line-height);
}
body[data-current-page="om-mark"] #om-mark .about-ai-copy > p:last-child { margin-bottom:0; }
body[data-current-page="om-mark"] #om-mark .about-ai-figure {
  float:none;
  display:grid;
  grid-template-columns:minmax(0,1fr) 220px;
  align-items:end;
  gap:20px;
  width:min(100%,500px);
  max-width:500px;
  min-width:0;
  margin:20px auto 0;
  padding:0;
  border-bottom:1px solid rgba(62,111,112,.18);
  transform:none;
}
body[data-current-page="om-mark"] #om-mark .about-ai-copy { display:flow-root; }
body[data-current-page="om-mark"] #om-mark .about-ai-lars { display:block; width:100%; max-width:220px; height:auto; }
body[data-current-page="om-mark"] #om-mark .about-ai-speech { margin:0 0 16px; padding:12px 14px; font-size:15px; font-weight:500; line-height:1.45; }
body[data-current-page="om-mark"] #om-mark .about-ai-speech::after { display:none; }
body[data-current-page="om-mark"] #om-mark .about-ai-figure::before { display:none; }
body[data-current-page="om-mark"] #om-mark .about-ai-lars { filter:none; }
body[data-current-page="om-mark"] #om-mark .about-ai-notes { display:grid; gap:28px; align-self:start; justify-self:end; width:min(100%,340px); }
@media(min-width:901px) {
  body[data-current-page="om-mark"] #om-mark .about-ai-card { display:grid; grid-template-columns:minmax(0,1fr) minmax(270px,.42fr); column-gap:clamp(24px,3vw,36px); overflow:visible; }
  body[data-current-page="om-mark"] #om-mark .about-ai-content { display:contents; }
  body[data-current-page="om-mark"] #om-mark .about-ai-heading { grid-column:1; grid-row:1; }
  body[data-current-page="om-mark"] #om-mark .about-ai-copy { grid-column:1; grid-row:2; }
  body[data-current-page="om-mark"] #om-mark .about-ai-notes { grid-column:2; grid-row:1 / span 2; margin-top:-48px; }
}
body[data-current-page="om-mark"] #om-mark .about-ai-points {
  position:relative;
  align-self:start;
  justify-self:end;
  width:min(100%,380px);
  margin:0;
  padding:26px 22px 20px;
  color:#24416c;
  background:linear-gradient(145deg,#fff2a9,#f6e48a);
  border:0;
  border-radius:0;
  box-shadow:2px 8px 18px rgba(56,49,24,.16);
  transform:rotate(1.5deg);
  font-family:"Segoe Print","Bradley Hand","Comic Sans MS",cursive;
  font-size:15px;
  line-height:1.55;
}
body[data-current-page="om-mark"] #om-mark .about-ai-points::before { content:""; position:absolute; top:-10px; left:calc(50% - 34px); width:68px; height:24px; background:rgba(255,253,231,.65); transform:rotate(-4deg); }
body[data-current-page="om-mark"] #om-mark .about-ai-points:nth-child(2) { transform:rotate(-1.5deg); }
body[data-current-page="om-mark"] #main-content #om-mark .about-ai-points :is(h3,h4,p,li) { font-family:inherit; color:inherit; }
body[data-current-page="om-mark"] #om-mark .about-ai-points h3 { margin:0 0 16px; font-size:19px; font-weight:700; line-height:1.4; }
body[data-current-page="om-mark"] #om-mark .about-ai-points h4 { margin:20px 0 12px; font-size:15px; font-weight:700; line-height:1.45; }
body[data-current-page="om-mark"] #om-mark .about-ai-points h4:nth-of-type(2) { padding-top:20px; border-top:1px solid rgba(36,65,108,.2); }
body[data-current-page="om-mark"] #om-mark .about-ai-points ul { gap:8px; margin:0; }
body[data-current-page="om-mark"] #om-mark .about-ai-points li { gap:10px; font-size:15px; font-weight:400; line-height:1.55; }
body[data-current-page="om-mark"] #om-mark .about-ai-points li::before { width:5px; height:5px; margin-top:9px; background:currentColor; }
body[data-current-page="om-mark"] #om-mark .about-ai-points > p { margin:16px 0 0; font-size:15px; line-height:1.55; }
body[data-current-page="om-mark"] #om-mark .about-disclaimer-figure {
  float:none;
  display:block;
  width:min(100%,280px);
  max-width:280px;
  margin:18px auto 0;
  padding:0;
  border-bottom:1px solid rgba(62,111,112,.18);
  transform:none;
}
body[data-current-page="om-mark"] #om-mark .about-disclaimer-lars { display:block; width:100%; max-width:280px; height:auto; }
body[data-current-page="om-mark"] #om-mark .about-disclaimer-figure::before { display:none; }
body[data-current-page="om-mark"] #om-mark .about-disclaimer-lars { filter:none; }
@media(max-width:900px) {
  body[data-current-page="om-mark"] #om-mark { gap:20px; row-gap:var(--space-xl); }
  body[data-current-page="om-mark"] #om-mark .about-hero,
  body[data-current-page="om-mark"] #om-mark .about-ai-content,
  body[data-current-page="om-mark"] #om-mark .about-disclaimer-layout { grid-template-columns:1fr; }
  body[data-current-page="om-mark"] #om-mark .about-profile { max-width:460px; }
  body[data-current-page="om-mark"] #om-mark .about-reality-figure { float:none; width:min(100%,280px); margin:16px auto 20px; }
}
@media(max-width:520px) {
  body[data-current-page="om-mark"] #om-mark .about-ai-figure { grid-template-columns:1fr; justify-items:center; gap:0; max-width:280px; }
  body[data-current-page="om-mark"] #om-mark .about-ai-points { width:calc(100% - 12px); padding:24px 20px 20px; justify-self:center; transform:rotate(1deg); }
}
/* GymBio's common in-page hero.  The global toolbar intentionally lives above this component. */
body.subject-page #main-content .gymbio-page-hero { position:relative; isolation:isolate; display:grid; align-items:center; width:100%; max-width:none; min-height:var(--page-hero-height); height:var(--page-hero-height); margin:0 0 var(--page-hero-gap); padding:0; overflow:hidden; color:#fff; border:0; border-radius:var(--radius-md); background:var(--hero-fallback-start,#102523); box-shadow:none; text-align:left; }
body.subject-page #main-content .gymbio-page-hero > .gymbio-page-hero-image { position:absolute; z-index:-2; inset:0; display:block; width:100% !important; max-width:none; height:100% !important; margin:0; padding:0; object-fit:cover; object-position:65% center; border:0; border-radius:inherit; }
body.subject-page #main-content .gymbio-page-hero::after { position:absolute; z-index:-1; inset:0; content:""; pointer-events:none; background:linear-gradient(90deg,rgba(var(--hero-overlay-rgb,7,22,23),.92) 0%,rgba(var(--hero-overlay-rgb,7,22,23),.78) 27%,rgba(var(--hero-overlay-rgb,7,22,23),.45) 51%,rgba(var(--hero-overlay-rgb,7,22,23),.04) 78%); }
body.subject-page #main-content .gymbio-page-hero-copy { box-sizing:border-box; width:62%; min-width:0; max-width:var(--page-hero-copy-width); padding:34px var(--page-hero-copy-padding-x); }
body.subject-page #main-content .gymbio-page-hero > :not(.gymbio-page-hero-image) { position:relative; z-index:1; }
body.subject-page #main-content .gymbio-page-hero :is(h1,.article-title) { max-width:var(--page-hero-copy-width); margin:0; color:#fff; font-family:var(--font-heading); font-size:var(--page-hero-title-size); font-weight:700; line-height:1.1; letter-spacing:0; text-align:left; text-shadow:0 2px 14px rgba(0,0,0,.2); text-wrap:balance; }
body.subject-page #main-content .gymbio-page-hero :is(.article-subtitle,p) { max-width:470px; margin:18px 0 0; color:#f0f6f4; font-size:18px; font-weight:400; line-height:1.55; text-align:left; text-wrap:pretty; }
/* The two subject front pages use the same short orientation text below their hero. */
body.subject-page #main-content .article-page :is(.article-content,.article-section) > .article-lead { width:min(100%,var(--reading-width)); max-width:var(--reading-width); margin:0 auto 36px; color:var(--color-muted); font-size:20px; font-weight:400; line-height:1.65; }
/* One hero grammar: legacy page-specific rules must not move the copy or change its scale. */
body.subject-page #main-content .gymbio-page-hero .gymbio-page-hero-copy { width:62%; max-width:var(--page-hero-copy-width); text-align:left; }
body.subject-page #main-content .gymbio-page-hero .gymbio-page-hero-copy > .article-title { max-width:var(--page-hero-copy-width); margin:0; font-family:var(--font-heading); font-size:var(--page-hero-title-size); line-height:1.1; text-align:left; }
body.subject-page #main-content .gymbio-page-hero .gymbio-page-hero-copy > .article-subtitle { max-width:470px; margin:18px 0 0; color:#f0f6f4; font-size:18px; line-height:1.55; text-align:left; }
body.subject-page #main-content .gymbio-page-hero .writing-back { display:inline-block; margin:0 0 18px; color:#d8e8e1; font-size:.9rem; font-weight:650; text-decoration:none; }
body.subject-page #main-content .gymbio-page-hero .writing-back:hover { color:#fff; text-decoration:underline; }
/* Every ordinary subject-page hero reaches the article frame; wide content below can remain independent. */
body.subject-page #main-content .article-surface:not(.pg-game-page) > .gymbio-page-hero {
  width:calc(100% + 2 * var(--article-frame-padding-x));
  max-width:none;
  margin:calc(-1 * var(--article-frame-padding-y)) calc(-1 * var(--article-frame-padding-x)) calc(var(--page-hero-gap) + var(--article-frame-padding-y));
  padding:0;
  border-bottom:0;
}
/* The open band below every image hero is intentional page rhythm, including
   when the following content belongs to the same white article surface. */
body.subject-page #main-content .article-surface:not(.pg-game-page):has(> .gymbio-page-hero) {
  position:relative;
  isolation:isolate;
  background:transparent;
  border-color:transparent;
  box-shadow:none;
}
body.subject-page #main-content .article-surface:not(.pg-game-page,.biology-home-document,.biology-eukaryote-page,.subject-overview-document):has(> .gymbio-page-hero)::before {
  content:"";
  position:absolute;
  inset:calc(var(--page-hero-height) + var(--page-hero-gap)) 0 0;
  z-index:-1;
  border-radius:var(--radius-lg);
  background:var(--color-surface);
  pointer-events:none;
}
/* Kept for course-cover pages that are not article-surface pages. */
body.subject-page #main-content .biology-course-cover:not(.pg-game-page):not(.article-surface) > .gymbio-page-hero {
  width:calc(100% + 2 * clamp(20px,3.5vw,48px));
  margin:calc(-1 * clamp(20px,3.5vw,48px)) calc(-1 * clamp(20px,3.5vw,48px)) 32px;
}
body.subject-page #main-content .gymbio-page-hero--fallback { background:linear-gradient(135deg,var(--hero-fallback-start,#102a25) 0%,var(--hero-fallback-middle,#173d34) 58%,var(--hero-fallback-end,#315a50) 100%); }
body.subject-page #main-content .gymbio-page-hero--fallback::after { background:linear-gradient(90deg,rgba(var(--hero-overlay-rgb,7,24,21),.2),rgba(var(--hero-overlay-rgb,7,24,21),0) 58%,rgba(var(--hero-overlay-rgb,7,24,21),.12)); }
body.subject-page #main-content .subject-hero:not(.gymbio-page-hero) { position:relative; display:flex; flex-direction:column; align-items:flex-start; justify-content:center; width:100%; max-width:none; min-height:260px; height:auto; aspect-ratio:auto; margin:0 0 var(--space-xl); padding:clamp(24px,4vw,48px); border:0; border-radius:var(--radius-md); overflow:hidden; }
body.subject-page #main-content .subject-hero--area:not(.gymbio-page-hero) { min-height:330px; }
body.subject-page #main-content .subject-hero:not(.gymbio-page-hero) :is(h1,.article-title) { margin:0 0 16px; }
body.subject-page #main-content .subject-hero:not(.gymbio-page-hero) :is(.article-subtitle,p) { max-width:var(--reading-width); margin:0; line-height:1.5; }
body.subject-page #main-content .subject-hero:not(.gymbio-page-hero) > :is(div,h1,p) { z-index:1; }
body.subject-page #main-content .subject-accordion { margin:14px 0; padding:0; background:var(--color-surface); border:1px solid var(--color-border); border-radius:var(--radius-md); box-shadow:none; overflow:hidden; }
body.subject-page #main-content .subject-accordion > summary { display:flex; align-items:center; gap:12px; min-height:62px; padding:16px 20px; margin:0; font-size:18px; font-weight:650; line-height:1.4; list-style:none; cursor:pointer; background:transparent; border:0; }
.subject-accordion > summary::-webkit-details-marker { display:none; }
body.subject-page #main-content .subject-accordion > summary::after { display:none; }
body.subject-page #main-content .subject-accordion > summary > :not(.subject-chevron,.subject-level-badge) { min-width:0; }
.subject-accordion > summary small { display:block; font-weight:400; color:var(--color-muted); }
.subject-chevron { margin-left:auto; flex:0 0 auto; transition:transform .15s; }
.subject-accordion[open] > summary > .subject-chevron { transform:rotate(180deg); }
body.subject-page #main-content .subject-accordion[open] > summary { border-bottom:1px solid var(--color-border); }
body.subject-page #main-content .subject-accordion > :not(summary) { padding:var(--fold-content-padding-top) 22px 22px; }
.subject-level-badge { margin-left:auto; font-size:12px; padding:2px 7px; border-radius:5px; background:var(--color-primary-soft); color:var(--color-primary); }
.subject-level-badge + .subject-chevron { margin-left:0; }
body.subject-page #main-content .subject-callout { display:block; max-width:var(--reading-width); padding:20px; margin:24px auto; background:var(--surface-soft); border:1px solid var(--color-border); border-radius:var(--radius-md); box-shadow:none; }
/* Canonical Lars Lunde comment: a self-contained teaching note, never a float
   or side column beside ordinary article text. */
body.subject-page #main-content .lars-callout { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:center; gap:20px; width:min(100%,var(--reading-width)); margin:32px auto; padding:20px 20px 20px 22px; color:var(--color-text); background:var(--surface-soft); border:1px solid var(--color-border); border-radius:var(--radius-md); box-shadow:var(--shadow-card); }
body.subject-page #main-content .lars-callout__content { min-width:0; }
body.subject-page #main-content .lars-callout__text { margin:0; color:var(--color-text); font-size:17px; font-weight:400; line-height:1.65; }
body.subject-page #main-content .lars-callout__image { display:block; width:96px; max-height:120px; object-fit:contain; object-position:right bottom; }
body.subject-page #main-content .lars-callout { float:none; position:relative; }
body.subject-page #main-content .lars-callout::after { display:none; }
body.subject-page #main-content .lars-callout > .lars-callout__content { display:block; padding:0; color:var(--color-text); background:transparent; border:0; box-shadow:none; }
body.subject-page #main-content .lars-callout .lars-callout__text { color:var(--color-text); font-size:17px; font-weight:400; font-style:normal; line-height:1.65; }
body.subject-page #main-content .lars-callout .lars-callout__text + .lars-callout__text { margin-top:12px; }
body.subject-page #main-content .lars-callout > .lars-callout__image { width:96px; height:auto; max-height:120px; align-self:center; float:none; position:static; }
/* Canonical source note for official curriculum context and compact source lists.
   It documents the basis without competing with the teaching content. */
body #main-content .gymbio-source-note {
  box-sizing:border-box;
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin:40px auto 0;
  padding:15px 18px;
  color:var(--color-muted);
  background:#f4f8f5;
  border:1px solid #d7e6dc;
  border-left:3px solid var(--color-primary);
  border-radius:var(--radius-sm);
}
body #main-content .gymbio-source-note p { margin:0; font-size:14px; font-weight:400; line-height:1.65; }
body #main-content .gymbio-source-note strong { color:var(--color-text); font-weight:700; }
body #main-content .gymbio-source-note a { color:var(--color-primary); font-weight:650; }
/* Standalone chapter papers: compact closed rows, full spacing after open content. */
body.subject-page #main-content .writing-page.article-surface.srp-idea-bank {
  background: #faf9f4;
}

body.subject-page #main-content .article-surface + .writing-shared-ideas {
  margin-top:var(--space-xl);
}
body.subject-page #main-content .writing-shared-ideas > .writing-chapter {
  margin-top:0;
}
body.subject-page #main-content .article-page.article-surface.subject-chapter-document {
  padding:0; background:transparent; border:0; box-shadow:none; overflow:visible;
}
body.subject-page #main-content .subject-chapter-document::before { display:none; }
body.subject-page #main-content :is(.subject-chapter-document, [data-chapter-mode="continuous"]) [id] { scroll-margin-top:100px; }
body.subject-page #main-content .article-page.article-surface.subject-chapter-document > .gymbio-page-hero {
  width:100%; max-width:none; margin:0 0 var(--page-hero-gap); border-radius:var(--radius-md);
}
body.subject-page #main-content .subject-chapter-document > .subject-intro-paper { margin:0; }
body.subject-page #main-content .subject-chapter-document > .subject-chapter-paper {
  margin:var(--space-xl) 0 0; padding:0; overflow:hidden; border-radius:var(--radius-lg); background:var(--color-surface); box-shadow:none;
}
body.subject-page #main-content .subject-chapter-paper.article-surface { padding:0; overflow:hidden; }
body.subject-page #main-content .subject-chapter-paper.article-surface:not([open]) + .subject-chapter-paper.article-surface,
body.subject-page #main-content .subject-chapter-document > .subject-chapter-paper:not([open]) + .subject-reading-paper { margin-top:var(--fold-closed-gap); }
body.subject-page #main-content .subject-chapter-paper:not([open]) > .subject-chapter-summary { padding-block:var(--fold-summary-padding-y); }
body.subject-page #main-content .subject-chapter-paper > .subject-chapter-summary {
  display:flex; flex-wrap:wrap; align-items:center; gap:12px 20px; padding:var(--fold-summary-padding-y) var(--article-frame-padding-x); font-size:var(--fold-title-size); font-weight:650; list-style:none; cursor:pointer; background:var(--color-surface);
}
body.subject-page #main-content .subject-chapter-paper > .subject-chapter-summary small { display:block; font-size:18px; font-weight:400; line-height:1.5; color:var(--color-muted); }
.subject-chapter-summary::-webkit-details-marker { display:none; }
body.subject-page #main-content .subject-chapter-summary::after { content:'⌄'; flex:0 0 auto; margin-left:auto; color:#625e55; font-size:24px; line-height:1; }
body.subject-page #main-content .subject-chapter-paper[open] > .subject-chapter-summary::after { transform:rotate(180deg); }
body.subject-page #main-content .subject-chapter-summary:hover { background:#faf8f1; }
body.subject-page #main-content .subject-chapter-summary:focus-visible { outline:3px solid var(--color-primary); outline-offset:-4px; }
body.subject-page #main-content .subject-chapter-summary > :is(h2,h3).subject-chapter-title {
  flex:1 1 65%; width:auto; max-width:none; margin:0; font-size:var(--fold-title-size); line-height:1.4; color:var(--color-text); font-weight:650;
}
body.subject-page #main-content .subject-chapter-content { padding:var(--fold-content-padding-top) var(--article-frame-padding-x) var(--article-frame-padding-y); }
body.subject-page #main-content .subject-chapter-paper > .report-paper-content { padding:var(--fold-content-padding-top) var(--article-frame-padding-x) var(--article-frame-padding-y); box-sizing:border-box; }
body.subject-page #main-content .subject-chapter-content > :is(.article-section,.subject-unfolded-section) { margin-top:0; padding:0; border:0; }
body.subject-page #main-content .subject-chapter-content .article-section::before { display:none; }
body.subject-page #main-content :is(.subject-intro-paper,.subject-chapter-content) .biology-eukaryote-chapter { margin:0; padding:0; background:transparent; border:0; box-shadow:none; }
body.subject-page #main-content .subject-unfolded-section { margin-top:var(--subject-space-before-h3); }
body.subject-page #main-content .subject-unfolded-section > h3 { margin-top:0; }
body.subject-page #main-content .subject-chapter-orientation { margin-top:var(--subject-paragraph-space); }
.subject-chapter-tags { display:flex; flex-wrap:wrap; align-items:center; gap:6px; }
.subject-content-tag { display:inline-block; padding:3px 8px; border-radius:5px; font:650 12px/1.4 var(--font-body); color:#355549; background:#e8f0ea; }
.subject-content-tag--level-b { color:#245273; background:#e7f0f7; }
.subject-content-tag--level-a { color:#644777; background:#efeaf5; }
.subject-content-tag--perspectives { color:#775229; background:#f7eedf; }
.subject-content-tag--research { color:#27625f; background:#e3f1ef; }
.subject-content-tag--example { color:#486052; background:#edf1ec; }
body.subject-page #main-content .subject-paper-sources {
  --subject-body-size:14px; --subject-body-line-height:1.65; --subject-paragraph-space:12px;
  box-sizing:border-box; width:100%; margin:0; padding:18px var(--article-frame-padding-x); color:var(--color-muted); background:#edf5fb; border-top:1px solid #dce8f1; font:400 14px/1.65 var(--font-body);
}
body.subject-page #main-content .article-surface:not(.subject-chapter-document):not(.subject-chapter-paper) > .subject-paper-sources {
  width:calc(100% + 2 * var(--article-frame-padding-x)); margin:var(--space-lg) calc(-1 * var(--article-frame-padding-x)) calc(-1 * var(--article-frame-padding-y)); border-radius:0 0 var(--radius-lg) var(--radius-lg);
}
body.subject-page #main-content .subject-paper-sources :is(p,li,small) { font-size:14px; line-height:1.65; }
body.subject-page #main-content .subject-paper-sources p { margin:0; }
body.subject-page #main-content .subject-paper-sources ul { margin:8px 0; padding-left:20px; }
body.subject-page #main-content .subject-paper-source-entry + .subject-paper-source-entry { margin-top:12px; }
body.subject-page #main-content .subject-paper-sources-title { display:block; margin-bottom:8px; color:var(--color-text); }
body.subject-page #main-content .subject-paper-sources a { color:var(--color-primary); }
body.subject-page #main-content .article-page.article-surface .subject-paper-sources :is(p,li,small,a,strong) { font-size:14px; font-weight:400; line-height:1.65; }
body.subject-page #main-content .article-page.article-surface .subject-paper-sources .subject-paper-sources-title { font-weight:650; }
body.subject-page #main-content .subject-paper-sources p + p { margin-top:12px; }
body.subject-page #main-content .subject-paper-sources a + :is(small,span) { margin-left:.3em; }
body.subject-page #main-content .subject-paper-sources .article-content { width:100%; max-width:none; margin:0; padding:0; }
body #main-content .gymbio-source-note.subject-direct-source { width:100%; max-width:none; margin:12px 0 0; padding:0; background:transparent; border:0; border-radius:0; }
body #main-content .subject-direct-source p { font-size:13px; line-height:1.55; }
body.subject-page #main-content .article-page .gymbio-source-note.subject-direct-source,
body.subject-page #main-content .article-page .gymbio-source-note.subject-direct-source :is(p,a,strong) { font-size:13px; font-weight:400; line-height:1.55; }
body.subject-page #main-content .article-page .gymbio-source-note.subject-direct-source strong { font-weight:650; }
@media(max-width:640px) {
  body.subject-page #main-content :is(.subject-chapter-document, [data-chapter-mode="continuous"]) [id] { scroll-margin-top:82px; }
  body.subject-page #main-content .subject-chapter-summary { gap:10px; }
  body.subject-page #main-content .subject-chapter-summary > :is(h2,h3).subject-chapter-title { flex-basis:calc(100% - 42px); }
  body.subject-page #main-content .subject-chapter-summary > .subject-chapter-tags { order:3; flex-basis:100%; }
}
@media print {
  .subject-chapter-paper:not([open]) > :not(summary) { display:block!important; }
}
body.subject-page #main-content .subject-model { width:100%; max-width:none; padding:clamp(12px,2vw,24px); background:#fcfdfc; border:1px solid var(--color-border); border-radius:var(--radius-md); box-shadow:none; }
body.subject-page #main-content .subject-model .subject-model { padding:0; border:0; box-shadow:none; }
/* Canonical academic figures. Heroes, Lars and interactive models never use
   these classes, so their visuals remain component-owned. */
body.subject-page #main-content .article-page :is(.article-figure, .figure-block[data-figure="academic"]) { width:100%; max-width:var(--figure-standard-width); margin:var(--figure-space-before) auto var(--figure-space-after); padding:0; border:0; box-shadow:none; }
body.subject-page #main-content .article-page :is(.article-figure, .figure-block[data-figure="academic"]).figure-small { max-width:var(--figure-small-width); }
body.subject-page #main-content .article-page :is(.article-figure, .figure-block[data-figure="academic"]).figure-standard { max-width:var(--figure-standard-width); }
body.subject-page #main-content .article-page :is(.article-figure, .figure-block[data-figure="academic"]).figure-wide { max-width:var(--figure-wide-width); }
body.subject-page #main-content .article-page .article-figure .figure-media { display:block; width:100%; max-width:100%; overflow:visible; background:transparent; border:0; border-radius:0; box-shadow:none; }
body.subject-page #main-content .article-page .article-figure .figure-media-button:is(:hover,:focus-visible) { border-color:transparent; box-shadow:none; }
body.subject-page #main-content .article-page .article-figure :is(img,svg) { display:block; width:auto; max-width:100%; height:auto; margin-inline:0; object-fit:contain; }
body.subject-page #main-content .article-page .article-figure :is(figcaption,.figure-caption) { width:100%; max-width:none; margin:var(--figure-caption-space) 0 0; padding:0; color:var(--color-text); background:transparent; border:0; border-radius:0; box-shadow:none; text-align:left; }
body.subject-page #main-content .article-page .article-figure :is(.figure-title,.figure-caption-title) { display:block; margin:0 0 4px; color:var(--color-text); font-size:16px; font-weight:650; line-height:1.45; }
body.subject-page #main-content .article-page .article-figure :is(.figure-description,.figure-caption-text) { margin:0 0 6px; color:var(--color-muted); font-size:15px; font-weight:400; line-height:1.6; }
body.subject-page #main-content .article-page .article-figure :is(.figure-source,.figure-caption-source) { margin:0; color:var(--color-muted); font-size:13px; font-weight:400; line-height:1.55; }
body.subject-page #main-content .article-page .article-figure .figure-source-label { display:inline; color:var(--color-text); font-size:inherit; font-weight:650; }
body.subject-page #main-content .article-page .article-figure .figure-media-button { display:block; width:100%; padding:0; border:0; background:transparent; cursor:zoom-in; }
body.subject-page #main-content .article-page .article-figure .figure-media-button:focus-visible { outline:3px solid var(--color-primary); outline-offset:4px; }
body.subject-page #main-content .article-page .article-figure .figure-media :is(img,svg) { width:100%; height:auto; max-height:none; }
body.subject-page #main-content .article-page .article-figure :is(.student-core-diagram,.figure-description p) { padding:0; background:transparent; border:0; border-radius:0; }
body.subject-page #main-content .article-page .article-figure.model-figure { position:static; padding:0; background:transparent; border:0; border-radius:0; }
body.subject-page #main-content .article-page .article-figure .figure-caption > .chart-title { text-align:left; }
body.subject-page #main-content .article-page .article-figure .figure-description :is(p,strong,em) { font-size:inherit; line-height:inherit; }
/* Faglige fotos kan bruge samme rytme uden automatisk figurnummer. */
body.subject-page #main-content .article-page .figure-photo .figure-title::before { content:none; }
/* Use .article-figure-side with .article-figure-side__copy and an existing
   .article-figure.figure-small when copy and a compact figure belong together. */
body.subject-page #main-content .article-figure-side { display:grid; grid-template-columns:minmax(0,800px) minmax(280px,var(--figure-small-width)); gap:var(--figure-pair-gap); justify-content:center; width:100%; max-width:var(--figure-wide-width); margin:var(--figure-space-before) auto var(--figure-space-after); align-items:start; }
body.subject-page #main-content .article-figure-side.article-figure-side--left { grid-template-columns:minmax(280px,var(--figure-small-width)) minmax(0,800px); }
body.subject-page #main-content .article-figure-side--left > .article-figure { order:-1; }
body.subject-page #main-content .article-figure-side.article-figure-side--tall { --figure-small-width:360px; }
body.subject-page #main-content .article-figure-side__copy { min-width:0; }
body.subject-page #main-content .article-figure-side__copy > :is(p,ul,ol,dl,h2,h3,h4) { width:100%; max-width:var(--reading-width); margin-left:0; margin-right:0; }
body.subject-page #main-content .article-page .article-figure-side > .article-figure { min-width:0; width:100%; margin:0; }
body.subject-page #main-content .figure-pair { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:var(--figure-pair-gap); width:100%; max-width:var(--figure-wide-width); margin:var(--figure-space-before) auto var(--figure-space-after); align-items:start; }
body.subject-page #main-content .figure-pair > :is(figure,.article-figure) { min-width:0; width:100%; margin:0; }
body.subject-page #main-content .figure-pair > .article-figure :is(figcaption,.figure-caption) { width:100%; }
/* Editorial chapter breaks: use these only where the reader changes subject,
   never between ordinary H2 sections. The open gutter lets the page backdrop
   show through, so a new chapter reads as a fresh page rather than another row. */
body.subject-page #main-content .article-column > .article-surface + .article-surface,
body.subject-page #main-content .writing-shared-srp > .article-surface + .article-surface,
body.subject-page #main-content .subject-chapter-document > .subject-reading-paper + .subject-reading-paper,
body.subject-page #main-content .subject-chapter-document > .subject-chapter-paper[open] + .subject-reading-paper { margin-top:var(--space-xl); }
body.subject-page #main-content :is(.biology-home-document,.subject-overview-document).article-surface {
  padding:0;
  overflow:visible;
  background:transparent;
  border:0;
  box-shadow:none;
}
body.subject-page #main-content :is(.biology-home-document,.subject-overview-document) > .gymbio-page-hero {
  width:100% !important;
  margin:0 0 var(--page-hero-gap) !important;
}
body.subject-page #main-content :is(.biology-home-content,.subject-overview-content) {
  display:grid;
  gap:var(--space-xl);
  padding:0;
}
body.subject-page #main-content :is(.biology-home-chapter,.subject-overview-chapter) {
  background:rgba(255,255,255,.93);
  border:1px solid var(--color-border);
  border-radius:var(--radius-lg);
  box-shadow:var(--shadow-card);
}
body.subject-page #main-content :is(.biology-admission-panel,.subject-admission-panel) {
  padding:var(--space-lg);
  background:rgba(23,107,142,.055);
  border:1px solid var(--color-border);
  border-radius:var(--radius-md);
}
body.subject-page #main-content :is(.biology-admission-panel,.subject-admission-panel) > h3 { margin-top:0; }
body[data-current-page="biologi"] #main-content .biology-home-chapter > .biology-home-section {
  margin:0;
  padding:0;
  border:0;
}
body[data-current-page="biologi"] #main-content .biology-home-chapter > .biology-home-section::before { display:none; }
body[data-current-page="biologi"] #main-content .biology-home-chapter > .biology-home-section + .biology-home-section {
  margin-top:var(--subject-space-before-h2);
}
body[data-current-page="biologi"] #main-content .biology-home-chapter > .biology-home-section > .biology-section-heading > h2 {
  margin-top:0;
}
/* Eukaryot is one complete chapter now. The opening continues directly from
   the hero; the quiet gaps between later cards mark genuine subject shifts. */
body[data-current-page="biologi"] #main-content .biology-eukaryote-page.article-surface {
  padding:0;
  overflow:visible;
  background:transparent;
  border:0;
  box-shadow:none;
}
body[data-current-page="biologi"] #main-content .biology-eukaryote-page > .gymbio-page-hero {
  width:100% !important;
  margin:0 0 var(--page-hero-gap) !important;
  border-radius:var(--radius-md);
}
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-chapter {
  margin:0 0 var(--space-xl);
  background:rgba(255,255,255,.93);
  border:1px solid var(--color-border);
  border-radius:var(--radius-lg);
  box-shadow:var(--shadow-card);
}
/* The first text section finishes the opening surface. It is not a page break. */
body[data-current-page="biologi"] #main-content .biology-eukaryote-page > .biology-eukaryote-chapter:first-of-type {
  margin-top:0;
  border-top:0;
  border-radius:0 0 var(--radius-lg) var(--radius-lg);
}
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-cell-explorer,
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-organisation-flow,
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-differentiation,
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-endosymbiosis-depth-disclosure {
  width:min(100%,var(--reading-width));
  max-width:var(--reading-width);
  margin-right:auto;
  margin-left:auto;
}
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-cell-explorer,
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-organisation-flow,
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-differentiation {
  margin-top:28px;
}
body[data-current-page="biologi"] #main-content .biology-eukaryote-page :is(.biology-eukaryote-type-copy,.biology-eukaryote-type-intro,.biology-eukaryote-structure-details) p {
  font-size:var(--subject-body-size);
  line-height:var(--subject-body-line-height);
}
body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-table-wrap {
  margin-top:28px;
}
.subject-table-scroll { max-width:100%; overflow-x:auto; margin:24px 0; }
body.subject-page #main-content .subject-table { width:100%; margin:0; border-collapse:collapse; font-size:15px; background:var(--color-surface); }
body.subject-page #main-content .subject-table :is(th,td) { padding:12px 16px; border:1px solid var(--color-border); text-align:left; }
body.subject-page #main-content .subject-table th { color:var(--theme-ink); background:var(--table-header); font-weight:650; }
body.subject-page #main-content .subject-table tbody tr:nth-child(even) { background:var(--table-stripe); }
/* Header colour follows the page; unavailable curriculum cells keep their meaning. */
body.subject-page #main-content .subject-table tbody th { background:var(--table-rowhead); }
body.subject-page #main-content .subject-table tbody tr:hover { background:var(--table-hover); }
body.subject-page #main-content .subject-table tbody td.is-not-separate-core { background:var(--table-unavailable); }
/* Simple column tables become labelled rows; specialised/span tables keep their layout. */
@media(max-width:640px) {
  body.subject-page #main-content table.subject-table--mobile-cards { display:block; min-width:0; width:100%; table-layout:auto; }
  body.subject-page #main-content table.subject-table--mobile-cards caption { display:block; box-sizing:border-box; width:100%; }
  body.subject-page #main-content table.subject-table--mobile-cards colgroup { display:none; }
  body.subject-page #main-content table.subject-table--mobile-cards thead { position:absolute; width:1px; height:1px; padding:0; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
  body.subject-page #main-content table.subject-table--mobile-cards tbody { display:grid; gap:12px; width:100%; }
  body.subject-page #main-content table.subject-table--mobile-cards tbody + tbody { margin-top:12px; }
  body.subject-page #main-content table.subject-table--mobile-cards tbody tr { display:block; width:100%; overflow:hidden; border:1px solid var(--color-border); border-radius:var(--radius-sm); background:var(--color-surface); }
  body.subject-page #main-content table.subject-table--mobile-cards tbody :is(th,td) { display:block; box-sizing:border-box; width:100%; min-width:0; border:0; border-bottom:1px solid var(--color-border); padding:12px 16px; overflow-wrap:anywhere; }
  body.subject-page #main-content table.subject-table--mobile-cards tbody tr > :last-child { border-bottom:0; }
  body.subject-page #main-content table.subject-table--mobile-cards tbody :is(th,td)::before { display:block; margin-bottom:4px; content:attr(data-label); color:var(--color-primary); font-size:13px; font-weight:650; }
}
:is(.button-primary,.button-secondary,.primary-button,.secondary-button,.card-button) { display:inline-flex; align-items:center; justify-content:center; min-height:42px; padding:10px 18px; border:1px solid var(--color-primary); border-radius:var(--radius-sm); font:650 15px/1.4 var(--font-body); text-decoration:none; }
:is(.button-primary,.primary-button,.card-button) { color:white; background:var(--color-primary); }
:is(.button-secondary,.secondary-button) { color:var(--color-primary); background:var(--color-surface); }
:is(.button-primary,.primary-button,.card-button):hover { background:var(--color-primary-hover, var(--green)); }
:is(.button-secondary,.secondary-button):hover { background:var(--color-primary-soft); }
/* Subject actions reuse the existing button standard. Navigation, filters,
   cards and model controls retain their own component styles. */
body:is([data-current-page="biologi"],[data-current-page="naturgeografi"],[data-current-page="skriftlighed"]) #main-content :is(.button-primary,.button-secondary,.primary-button,.secondary-button,.card-button):not(.subject-model *, .pg-game-page *, .pg-standalone *, [data-protein-game] *, .inheritance-lab *, .protein-synthesis-game *, .gb-protein-game *) {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:10px 18px;
  border:1px solid var(--color-primary);
  border-radius:var(--radius-sm);
  font:650 15px/1.4 var(--font-body);
  text-decoration:none;
}
body:is([data-current-page="biologi"],[data-current-page="naturgeografi"],[data-current-page="skriftlighed"]) #main-content :is(.button-primary,.primary-button,.card-button):not(.subject-model *, .pg-game-page *, .pg-standalone *, [data-protein-game] *, .inheritance-lab *, .protein-synthesis-game *, .gb-protein-game *) { color:#fff; background:var(--color-primary); }
body:is([data-current-page="biologi"],[data-current-page="naturgeografi"],[data-current-page="skriftlighed"]) #main-content :is(.button-secondary,.secondary-button):not(.subject-model *, .pg-game-page *, .pg-standalone *, [data-protein-game] *, .inheritance-lab *, .protein-synthesis-game *, .gb-protein-game *) { color:var(--color-primary); background:var(--color-surface); }
body:is([data-current-page="biologi"],[data-current-page="naturgeografi"],[data-current-page="skriftlighed"]) #main-content :is(.button-primary,.primary-button,.card-button):not(.subject-model *, .pg-game-page *, .pg-standalone *, [data-protein-game] *, .inheritance-lab *, .protein-synthesis-game *, .gb-protein-game *):hover { background:var(--color-primary-hover, var(--green)); }
body:is([data-current-page="biologi"],[data-current-page="naturgeografi"],[data-current-page="skriftlighed"]) #main-content :is(.button-secondary,.secondary-button):not(.subject-model *, .pg-game-page *, .pg-standalone *, [data-protein-game] *, .inheritance-lab *, .protein-synthesis-game *, .gb-protein-game *):hover { background:var(--color-primary-soft); }
@media(max-width:640px) {
  body:is([data-current-page="biologi"],[data-current-page="naturgeografi"],[data-current-page="skriftlighed"]) #main-content :is(.button-primary,.button-secondary,.primary-button,.secondary-button,.card-button):not(.subject-model *, .pg-game-page *, .pg-standalone *, [data-protein-game] *, .inheritance-lab *, .protein-synthesis-game *, .gb-protein-game *) { min-height:44px; }
}
body.subject-page #main-content .subject-accordion > summary [hidden] { display:none; }
body.subject-page #main-content .writing-intro-panel { margin-inline:0; }
body #main-content.pg-standalone { padding:24px 0 30px; }
.pg-standalone .gb-protein-game__navigation-row { top:82px; }
.pg-back { position:static; display:block; width:fit-content; margin:18px auto 0; transform:none; }
.pg-back:hover { transform:none; }
a:focus-visible,button:focus-visible,summary:focus-visible,[tabindex="0"]:focus-visible { outline:3px solid #568d72; outline-offset:3px; }
@media(max-width:1180px) { :root { --site-h1-size:40px; } }
@media(max-width:980px) {
  .site-header { gap:10px; }
  .site-header .main-nav { flex:1 1 auto; }
  body.subject-page #main-content .subject-layout { grid-template-columns:minmax(0,1fr); }
  body.subject-page #main-content .subject-sidebar { display:none; }
  body.subject-page #main-content .subject-mobile-menu { display:block; width:100%; margin:0 0 18px; padding:0; border:1px solid var(--color-border); border-radius:var(--radius-md); background:white; }
  body.subject-page #main-content .subject-mobile-menu > summary { padding:14px 18px; cursor:pointer; }
  body.subject-page #main-content .subject-mobile-menu > div { padding:8px; }
  body.subject-page #main-content .subject-mobile-menu .subject-menu-link { min-height:44px; }
  body.subject-page #main-content .article-figure-side { grid-template-columns:minmax(0,1fr); }
  body.subject-page #main-content .article-figure-side.article-figure-side--left { grid-template-columns:minmax(0,1fr); }
  body.subject-page #main-content .article-figure-side--left > .article-figure { order:0; }
  body.subject-page #main-content .article-figure-side--left > .article-figure-side__copy { order:-1; }
  body.subject-page #main-content .article-figure-side__copy { width:min(100%,var(--reading-width)); margin-inline:auto; }
  body.subject-page #main-content .article-page .article-figure-side > .article-figure { width:min(100%,var(--figure-small-width)); margin-inline:auto; }
}
@media(max-width:600px) {
  :root { --site-h1-size:29px; --site-h2-size:24px; --site-h3-size:20px; }
}
@media(max-width:640px) {
  :root { --space-section:44px; --space-xl:32px; }
  body.subject-page { --page-hero-height:280px; --article-frame-padding-x:20px; --article-frame-padding-y:30px; }
  body.subject-page,
  body[data-current-page="om-mark"] { --subject-body-size:16px; --subject-body-line-height:1.7; --subject-paragraph-space:18px; --subject-space-before-h2:44px; --subject-space-before-h3:36px; --subject-space-after-heading:18px; --subject-space-before-h4:24px; --subject-space-after-h4:8px; }
  .site-header { top:6px; height:56px; min-height:56px; margin-top:6px; padding:6px 8px; }
  .site-header .logo-copy { display:none; }
  .site-header .logo-mark { width:34px; height:34px; }
  .site-header .nav-button { font-size:13px; padding-inline:9px; }
  body.subject-page #main-content .gymbio-page-hero { min-height:var(--page-hero-height); height:var(--page-hero-height); align-items:end; }
  body.subject-page #main-content .gymbio-page-hero > .gymbio-page-hero-image { object-position:65% 35%; }
  body.subject-page #main-content .gymbio-page-hero::after { background:linear-gradient(180deg,rgba(var(--hero-overlay-rgb,7,22,23),.04) 0%,rgba(var(--hero-overlay-rgb,7,22,23),.18) 22%,rgba(var(--hero-overlay-rgb,7,22,23),.83) 52%,rgba(var(--hero-overlay-rgb,7,22,23),.98) 100%); }
  body.subject-page #main-content .gymbio-page-hero--fallback::after { background:linear-gradient(180deg,rgba(var(--hero-overlay-rgb,7,24,21),.08),rgba(var(--hero-overlay-rgb,7,24,21),.82)); }
  body.subject-page #main-content .gymbio-page-hero-copy { width:100%; max-width:none; padding:20px; }
  body.subject-page #main-content .gymbio-page-hero :is(h1,.article-title) { font-size:var(--page-hero-title-size); line-height:1.1; hyphens:auto; }
  body.subject-page #main-content .gymbio-page-hero :is(.article-subtitle,p) { margin-top:10px; font-size:15px; line-height:1.45; }
  body.subject-page #main-content .gymbio-page-hero .gymbio-page-hero-copy { width:100%; max-width:none; }
  body.subject-page #main-content .gymbio-page-hero .gymbio-page-hero-copy > .article-title { font-size:var(--page-hero-title-size); line-height:1.1; }
  body.subject-page #main-content .gymbio-page-hero .gymbio-page-hero-copy > .article-subtitle { margin-top:10px; font-size:15px; line-height:1.45; }
  body.subject-page #main-content .article-page :is(.article-content,.article-section) > .article-lead { margin-bottom:28px; font-size:17px; line-height:1.6; }
  body.subject-page #main-content .gymbio-page-hero .writing-back { margin-bottom:12px; }
  body.subject-page #main-content .subject-hero:not(.gymbio-page-hero) { min-height:240px; padding:24px 20px; }
  body.subject-page #main-content .subject-hero--area:not(.gymbio-page-hero) { min-height:280px; }
  body.subject-page #main-content .figure-pair { grid-template-columns:minmax(0,1fr); }
  body.subject-page #main-content .lars-callout { grid-template-columns:minmax(0,1fr); }
  body.subject-page #main-content .lars-callout__image { width:82px; justify-self:end; }
  body.subject-page #main-content .lars-callout > .lars-callout__image { width:82px; }
  body.subject-page #main-content .article-page:not(.pg-standalone):not(.pg-game-page) .subject-compact-copy { font-size:16px; }
  body.subject-page #main-content .subject-accordion > summary { padding-inline:18px; }
}

/* The comparison stays readable on a phone: one complete comparison at a time,
   rather than four squeezed table columns. */
@media(max-width:760px) {
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-table-wrap { overflow:visible; }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table,
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody,
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tr,
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table th,
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table td {
    display:block;
    width:100%;
  }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table thead {
    position:absolute;
    width:1px;
    height:1px;
    overflow:hidden;
    clip:rect(0 0 0 0);
    clip-path:inset(50%);
    white-space:nowrap;
  }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody { display:grid; gap:14px; }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody tr {
    overflow:hidden;
    background:rgba(255,255,255,.96);
    border:1px solid rgba(31,122,85,.16);
    border-radius:14px;
    box-shadow:0 5px 16px rgba(24,35,30,.04);
  }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody th,
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody td { border-right:0; }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody th {
    color:#fffdf7;
    background:var(--green-dark);
  }
  body[data-current-page="biologi"] #main-content .biology-eukaryote-page .biology-eukaryote-comparison-table tbody td::before {
    display:block;
    margin-bottom:5px;
    color:var(--green-dark);
    font-size:.76rem;
    font-weight:900;
    letter-spacing:.04em;
    text-transform:uppercase;
  }
}

/* Short pages fill the viewport; long pages keep the footer after their content. */
body:has(> .site-footer) {
  display:flex;
  flex-direction:column;
  min-height:100vh;
  min-height:100svh;
}
body:has(> .site-footer) > :is(.site-header, #main-content, .site-footer) {
  flex-shrink:0;
}
/* Shared footer: consistent placement, typography and compact reading rhythm. */
body .site-footer {
  margin-top:auto;
  justify-items:start;
  text-align:left;
  gap:4px;
  padding-block:20px 24px;
  font-family:var(--font-body);
  font-size:14px;
  line-height:1.5;
}
body .site-footer p {
  margin:0;
  font-family:inherit;
  font-size:inherit;
  line-height:inherit;
  font-weight:400;
}
body .site-footer p:first-child {
  font-weight:600;
}
body .site-footer .footer-links {
  justify-content:flex-start;
  gap:6px 10px;
  margin-top:6px;
  font-family:inherit;
  font-size:inherit;
  line-height:inherit;
}
body .site-footer .footer-links a {
  color:var(--color-primary);
  min-height:32px;
  font-family:inherit;
  font-size:inherit;
  font-weight:600;
}
@media (pointer:coarse) {
  body .site-footer .footer-links a { min-height:44px; }
}
body .site-footer .footer-author {
  display:block;
  margin:0;
  font-size:inherit;
  line-height:1.5;
  color:var(--muted);
}
body .site-footer .footer-author strong,
body .site-footer .footer-author span {
  color:inherit;
  font-size:inherit;
  font-weight:400;
}

/* Kort, let introduktion tættere på forsidens skillelinje. */
body[data-current-page="forside"] .subject-hub-section { padding-top: 12px; }
body[data-current-page="forside"] .subject-overview-card p { font-weight: 400; }

/* Computer: scale the complete opening together to the available window. */
@media (min-width:981px) {
  body[data-current-page="forside"] #main-content {
    width:min(calc(100% - 2 * var(--site-gutter)), 2200px);
  }
  #forside .home-screen.is-fitted { position:relative; }
  #forside .home-screen.is-fitted .home-opening {
    position:absolute;
    top:0;
    left:50%;
    width:1306px;
    margin-left:-653px;
    min-height:0;
    transform:scale(var(--home-scale, 1));
    transform-origin:center top;
  }
  #forside .home-screen.is-fitted .hero {
    column-gap:54px;
    min-height:0;
  }
  #forside .home-screen.is-fitted .hero h1 { font-size:205px; }
  #forside .home-screen.is-fitted .profile-image { height:697px; }
  #forside .home-screen.is-fitted .subject-hub-section { flex-shrink:0; padding:12px 0 16px; }
  #forside .home-screen.is-fitted .subject-overview-card { margin:0 auto; padding:0; }
  #forside .guestbook-display { max-width:1280px; margin-inline:auto; }
}
body[data-current-page="ordbog"] #main-content .dictionary-tools-heading {
  grid-area:title; display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap;
}
.dictionary-offline-download {
  display:inline-flex; align-items:center; gap:7px; min-height:36px; padding:6px 10px;
  border:1px solid #c6d9ce; border-radius:8px; color:var(--color-primary);
  background:rgba(255,255,255,.7); font-size:13px; font-weight:600; text-decoration:none;
}
.dictionary-offline-download:hover { background:var(--surface-soft); border-color:var(--green); }
.dictionary-offline-download:focus-visible { outline:2px solid var(--color-primary); outline-offset:3px; }

body[data-current-page="skriftlighed"][data-writing-view="afleveringscheck"] #main-content .writing-page.writing-check-hub {
  padding:16px 0 0;
  background:transparent;
  border:0;
  border-radius:0;
  box-shadow:none;
  overflow:visible;
}

/* Planned academic illustrations: the existing organelle placeholder's visual language. */
body.subject-page #main-content .article-page .subject-planned-figure {
  display:grid;
  width:100%;
  max-width:var(--figure-standard-width);
  gap:12px;
  margin:var(--figure-space-before) auto var(--figure-space-after);
  padding:0;
  color:var(--color-muted);
}
body.subject-page #main-content .article-page .subject-planned-figure__canvas {
  display:grid;
  min-height:140px;
  place-items:center;
  padding:24px;
  color:#416e5c;
  font-size:15px;
  text-align:center;
  background:linear-gradient(135deg, rgba(242,248,244,.98), rgba(231,242,235,.78));
  border:1px dashed rgba(65,110,92,.42);
  border-radius:18px;
}
body.subject-page #main-content .article-page .subject-planned-figure figcaption {
  display:grid;
  gap:4px;
  font-size:15px;
  font-style:normal;
  line-height:1.6;
}
body.subject-page #main-content .article-page .subject-planned-figure__title {
  color:var(--color-text);
  font-size:16px;
  font-weight:650;
}

/* Leave room for the checklist paper pin below the choices. */
body.subject-page[data-current-page="skriftlighed"][data-writing-view="afleveringscheck"] #main-content .article-column > .writing-check-hub ~ .writing-check-sheet {
  margin-top:32px;
}

/* Eksamen: fælles læseflader og roligt sideskift før niveauvalget. */
body.subject-page #main-content .biology-exam-section.subject-overview-chapter { margin:0; }
body.subject-page #main-content .biology-exam-section::before { display:none; }
body.subject-page #main-content .subject-overview-chapter > .exam-welcome { margin:0; }
body.subject-page #main-content .biology-exam-section.subject-overview-chapter > .biology-section-heading { margin-top:0; }

/* Eksamenshjælp: varme papirer og gennemgående niveau-farver. */
body.subject-page #main-content .subject-overview-chapter:has(> .exam-welcome) { background:#fcfaf4; }
body.subject-page #main-content .exam-note-paper {
  position:relative; box-sizing:border-box; width:100%; max-width:680px; margin:32px auto 0; padding:24px 28px;
  font-family:"Segoe Print","Comic Sans MS",cursive; color:#24416c;
  background:repeating-linear-gradient(to bottom,transparent 0,transparent 31px,#dce4df 32px),#fffef9;
  border:1px solid #e3dfd1; border-radius:3px 3px 14px 3px; box-shadow:2px 5px 12px #263e2d0b;
}
body.subject-page #main-content .exam-note-paper__scribble { display:block; margin-bottom:12px; color:#806427; font-family:"Segoe Print","Comic Sans MS",cursive; font-size:17px; }
body.subject-page #main-content .exam-note-paper :is(h3,p) { font-family:"Segoe Print","Comic Sans MS",cursive !important; color:inherit; }
body.subject-page #main-content .exam-note-paper h3 { font-size:22px; }
body.subject-page #main-content .exam-note-paper p { font-size:17px; line-height:1.8; margin-bottom:16px; }
body.subject-page #main-content .exam-note-paper > :last-child { margin-bottom:0; }
body.subject-page #main-content .biology-exam-level-tabs { border:0; gap:12px; }
body.subject-page #main-content .biology-exam-level-tabs button { border-radius:10px; background:var(--exam-level-soft); border-bottom:3px solid transparent; }
body.subject-page #main-content .biology-exam-level-tabs button[aria-selected="true"] { border-color:var(--exam-level-marker); box-shadow:inset 0 0 0 1px var(--exam-level-marker); }
body.subject-page #main-content .biology-exam-level-facts > div { background:var(--exam-level-soft); }
/* Geography's C/B controls use blue shades, including reused Biology components. */
body[data-current-page="naturgeografi"] :is(.biology-exam-level-tabs button, .biology-exam-level-panel) {
  --exam-level-accent:var(--color-primary); --exam-level-marker:var(--color-primary);
  --exam-level-soft:var(--surface-soft);
}
body[data-current-page="naturgeografi"] :is(.biology-exam-level-tabs button, .biology-exam-level-panel)[data-exam-level="b"] {
  --exam-level-soft:var(--theme-soft);
}
body.subject-page #main-content .biology-exam-level-flow .biology-exam-step-list { grid-template-columns:1fr; gap:20px; }
body.subject-page #main-content .exam-form-links button { padding:12px 18px; border:1px solid #d7dfd8; border-radius:8px; background:#fff; color:var(--color-text); font:inherit; cursor:pointer; }
body.subject-page #main-content .exam-form-links button[aria-pressed="true"] { background:#f5ecd9; border-color:#b58b40; }
body.subject-page #main-content .exam-form-links button:focus-visible { outline:3px solid #b58b40; outline-offset:3px; }
@media(max-width:640px) { body.subject-page #main-content .exam-note-paper { padding:20px 16px; } }

/* Afsluttende eksamensmodul med en påsat stikordsseddel. */
body.subject-page #main-content .exam-closing { display:grid; grid-template-columns:minmax(0,1.5fr) minmax(0,1fr); gap:36px; align-items:start; }
body.subject-page #main-content .exam-closing .exam-note-paper { width:100%; max-width:none; margin:12px 0 0; padding:28px 22px 20px; transform:rotate(1deg); box-shadow:3px 7px 14px #263e2d15; }
body.subject-page #main-content .exam-closing .exam-note-paper::before { content:""; position:absolute; width:90px; height:26px; top:-13px; left:calc(50% - 45px); background:#e9d9aab8; border:1px solid #d4c59966; transform:rotate(-5deg); }
body.subject-page #main-content .exam-closing .exam-note-paper h3 { font-size:20px; }
@media(max-width:980px) { body.subject-page #main-content .exam-closing { grid-template-columns:1fr; gap:24px; } body.subject-page #main-content .exam-closing .exam-note-paper { max-width:480px; margin:12px auto 0; transform:none; } }

body[data-current-page="klassevaerktoejer"] { --theme-soft:var(--palette-sand); --theme-ink:#5b4b37; --page-tint:239,231,216; }
