/* draft12, 12 Oct 2026: every section is one frame, no lines between frames, grounds separate them.
   Loaded after every page sheet and before mobile.css, so it settles the desktop frame rules in one place.
   The header is static and scrolls away, so the hero fills the screen under it and every later frame
   fills the whole screen: a frame scrolled to the top never shows the next one. */
:root { --hdr:57px; --frame-first:calc(100svh - var(--hdr)); --frame:100svh; --foot:400px;
  --g-white:#fff; --g-green:#e6f7ee; --g-grey:#f2f4f3; --g-ink:#18231e; }

/* No line under the header; the header keeps its 57px. */
.header { border-bottom:0; }
.header-inner { min-height:57px; }
/* No line between frames at any width. */
main section:not(section section), main .ref-section, .contact-section, .home-content { border-top:0; border-bottom:0; }

@media (min-width:900px) {
  /* The frame. Top-level sections only; the home film and the pinned check keep their own stages. */
  main section:not(section section):not(.m-only):not(#film):not(#platform):not(#finder):not(#open):not(.contact-section):not(.hero):not(.page-heading):not(.ch-section) {
    box-sizing:border-box; height:var(--frame); min-height:0; margin-block:0;
    padding-block:clamp(32px,6vh,72px); border-top:0; border-bottom:0; align-content:center;
  }
  /* Block sections become a one-column grid centred in the frame; flex columns centre on their own axis;
     sections with their own grid keep their columns and centre their rows. */
  main :is(#finder,#open,.contact-section,#sectors,.t-frame,.faq-sections,.reg-dates,.page-rows):not(section section) {
    display:grid; grid-template-columns:minmax(0,1fr); align-content:center; }
  /* Part frames (Jared, 12 Oct): the finder is half a screen, the open verifier a third. */
  main #finder:not(section section) { box-sizing:border-box; min-height:50svh; margin-block:0; padding-block:clamp(20px,3vh,40px); border-top:0; border-bottom:0; }
  main #finder .finder-intro { margin-top:20px; } main #finder > .finder-form { margin-top:24px; } main #finder > .finder-status:empty { min-height:0; margin:0; }
  main #open:not(section section) { box-sizing:border-box; min-height:34svh; margin-block:0; padding-block:clamp(28px,4vh,48px); border-top:0; border-bottom:0; }
  main :is(#finder,#open,.contact-section,#sectors,.t-frame,.faq-sections,.ch-section,.reg-dates) > :is(.wrap,.contact-inner,div) { width:100%; }
  main :is(#bundle,.ref-section:not(.reg-dates)):not(section section) { justify-content:center; }
  main .page-heading:not(section section) { height:var(--frame-first); min-height:0; padding-block:clamp(32px,6vh,72px);
    display:flex; flex-direction:column; justify-content:center; align-items:flex-start; }
  main .page-heading > h1, main .page-heading.frame h1 { margin-top:0; }

  /* The close and the footer share the last frame. */
  main section:not(section section):is(main > :last-child,.contact-section):not(.page-heading):not(.m-only):not(#film):not(#platform):not(.hero):not(.ch-section) { height:auto; min-height:calc(100svh - var(--foot)); padding-block:clamp(40px,6vh,64px); }
  main section.contact-section { background:var(--g-grey); }
  .site-footer { height:var(--foot); box-sizing:border-box; display:flex; flex-direction:column; justify-content:center; }
  .site-footer-inner { padding-block:0; width:100%; }
  .site-footer-bottom { margin-top:40px; }

  /* No frame lines. Rows inside tables and lists keep theirs. */
  .home-content, .homepage .home-content { border-top:0; }
  main section:not(section section) > h2:first-child,
  main section:not(section section) > .wrap > h2:first-child,
  .platform-overview h2, .infrastructure-heading, .proof-heading, .ref-section { border-top:0; }

  /* Grounds. Two neighbours never share one; a dark frame's text is white. */
  main section.gd-white, main section.gd-green, main section.gd-grey, main section.gd-ink { clip-path:inset(0 -100vmax); }
  main section.gd-white { background:var(--g-white); box-shadow:0 0 0 100vmax var(--g-white); }
  main section.gd-green { background:var(--g-green); box-shadow:0 0 0 100vmax var(--g-green); }
  main section.gd-grey  { background:var(--g-grey);  box-shadow:0 0 0 100vmax var(--g-grey); }
  main section.gd-ink   { background:var(--g-ink);   box-shadow:0 0 0 100vmax var(--g-ink); color:#fff; }
  main section.gd-ink :is(h1,h2,h3,h4,p,li,dt,dd,span,a,td,th,time) { color:#fff; }

  /* The change log is a long record, not a frame set: each part opens on a full frame and runs on. */
  main section.ch-section { height:auto; min-height:var(--frame); display:flow-root; }

  /* The close's subline is ink, never grey. */
  .contact-section .contact-copy p, .contact-section p { color:var(--ink); }

  /* Buttons and links on the ink ground. */
  main section.gd-ink .button { background:#fff; color:var(--g-ink); border-color:#fff; }
  main section.gd-ink .button * { color:var(--g-ink); }
  main section.gd-ink a { text-decoration-color:rgba(255,255,255,.6); border-color:rgba(255,255,255,.6); }
  main section.gd-ink :is(li,tr,td,th,div) { border-color:rgba(255,255,255,.28); }
}
