/* The focused variant (doomsun.com/next2). These rules sit on top of styles.css and materials.css:
   - the only fixed chrome is the logo and the nav, without glass boxes;
   - text sits on the field, not in panels, along one left edge (the gutter);
   - each system keeps one proof below its opener, and the system map is four systems and six handoffs. */

/* Header: no glass boxes. The logo and the last nav link sit on the gutter. */
.wordmark{padding:6px 0}
@media(min-width:801px){.nav-links{padding:9px 0}}

/* Content fades out before it reaches the header, so it never slides under the logo or nav. */
#chapters{
  --fade-start:84px;--fade-end:140px;
  -webkit-mask-image:linear-gradient(to bottom,transparent var(--fade-start),#000 var(--fade-end));
  mask-image:linear-gradient(to bottom,transparent var(--fade-start),#000 var(--fade-end));
}
@media(max-width:800px){#chapters{--fade-start:66px;--fade-end:112px}}

/* Studio appears only with ?studio in the URL. */
.studio-dock{position:fixed;z-index:10;right:var(--gutter);bottom:24px}
.studio-dock[hidden]{display:none}
.studio-dock #display-toggle{padding:10px 14px}
.display-panel{bottom:84px}

/* Hero: the four systems rest as plain links on a hairline. On hover each becomes a glass tile, with the
   etched dot field following the cursor (glass-texture.js). */
.system-card.smoked-glass{min-height:0;align-items:start;padding:20px 22px 22px;background:transparent;border-color:transparent;border-top-color:var(--line);backdrop-filter:none;-webkit-backdrop-filter:none}
.system-card.smoked-glass:hover,.system-card.smoked-glass:focus-visible{background:var(--smoked-glass-hover-fill);border-color:var(--smoked-glass-hover-edge);backdrop-filter:var(--smoked-glass-filter);-webkit-backdrop-filter:var(--smoked-glass-filter)}

/* Each product's features, as short lines under its opening paragraph. */
.feature-list{list-style:none;display:grid;gap:9px;max-width:54ch;margin:22px 0 0;padding:0}
.feature-list li{position:relative;padding-left:20px;color:#c1c7bc;font:400 15px/1.5 var(--sans);text-wrap:pretty}
.feature-list li::before{content:'';position:absolute;left:0;top:.6em;width:6px;height:6px;background:var(--section-accent)}
.support-text .support-observation:first-child{margin-top:0}
/* On phones the figures sit behind the opening text; a soft dark halo keeps it crisp. */
@media(max-width:800px){.expanded-chapter .chapter-opening :is(.description,.feature-list li){text-shadow:0 0 10px rgb(0 0 0 / .9),0 0 3px rgb(0 0 0 / .9)}}

/* One left edge: opener text, detail text, figures, the map and the team all start on the gutter. */
.expanded-chapter .chapter-opening .chapter-content{padding-left:0}
.support-heading{display:block;max-width:920px}
.support-heading h3{max-width:none}
.support-heading>p,.support-heading>p:last-child{grid-column:auto;max-width:62ch;margin:24px 0 0;color:#c1c7bc;font:16px/1.7 var(--sans)}
.support-heading>p+p{margin-top:14px}

/* Detail sections are shorter: less padding above and below. */
.nova-support,.system-support{padding-top:clamp(90px,9vw,140px);padding-bottom:clamp(100px,10vw,150px)}

/* Figures share one width. Screenshots sit beside their text on wide screens, below it on narrow ones. */
.cyclotron-figure,.nova-lifecycle-diagram,.map-figure,.support-split{max-width:1100px}
.cyclotron-figure{margin-top:clamp(56px,6vw,90px)}
.support-split{margin-top:clamp(40px,4vw,60px)}
.support-text p{max-width:62ch;margin:0;color:#c1c7bc;font:16px/1.7 var(--sans);text-wrap:pretty}
.support-text .support-observation{max-width:22ch;margin:clamp(36px,4vw,56px) 0 0;padding:0;font:300 clamp(25px,2.4vw,34px)/1.2 var(--headline);letter-spacing:-.03em;color:#e1e4dd;text-wrap:balance}
.support-screen{margin:0}
@media(min-width:1100px){.support-split{display:grid;grid-template-columns:minmax(0,5fr) minmax(0,7fr);column-gap:clamp(48px,5vw,88px);align-items:start}}
@media(max-width:1099px){.support-screen{margin-top:clamp(40px,6vw,60px)}}
.support-actions,.daylight-support .support-next{margin-top:clamp(56px,6vw,90px)}
.support-heading>p,.nova-lifecycle-copy>p,.map-heading p,.team-intro-copy p{text-wrap:pretty}

/* NOVA: the lifecycle is the section's one proof. */
.nova-support h3,.nova-lifecycle h3{margin:0;max-width:none;font-size:clamp(36px,4.5vw,70px)}
.nova-lifecycle{margin-top:0}
.nova-lifecycle-copy{max-width:920px}
.nova-lifecycle-copy>p:last-child{max-width:62ch;margin-top:24px;color:#c1c7bc;font:16px/1.7 var(--sans)}
.nova-lifecycle-diagram{margin-top:clamp(56px,6vw,90px)}
.nova-lifecycle-track li{min-height:0;padding:18px 24px 0 0;background:none;border:0;border-top:1px solid rgb(229 198 109 / .45)}
.nova-return{text-align:left}
@media(min-width:801px){.nova-return span{padding-left:37.5%}}

/* The system map. */
.system-map{--map-line:rgb(201 206 195 / .6);position:relative;padding:clamp(110px,11vw,160px) var(--gutter) clamp(100px,10vw,150px);color:var(--paper)}
.map-heading{max-width:920px}
body[data-type] .system-map h2{margin:0;font:500 clamp(36px,4.5vw,70px)/1.04 var(--headline);letter-spacing:-.055em;text-transform:none}
.map-heading p{max-width:62ch;margin:24px 0 0;color:#c1c7bc;font:16px/1.7 var(--sans)}
.map-figure{margin:clamp(44px,5vw,72px) 0 0}
.map-diagram{display:block;width:100%;height:auto;overflow:visible}
/* Only the node's own box: the Stellarator mark has a mask rect inside it that must stay white. */
.map-node>rect{fill:rgb(6 8 10 / .8);stroke:var(--node);stroke-opacity:.55;stroke-width:1}
.map-name{fill:#eef0e8;font:500 24px var(--headline);letter-spacing:-.02em}
.map-purpose{fill:#a9b0a5;font:14px var(--sans)}
.map-edge path{fill:none;stroke:var(--map-line);stroke-width:1.5}
.map-arrowhead{stroke:var(--map-line)}
.map-label{fill:#c9cec3;font:15px var(--sans)}
/* The list carries the handoffs for screen readers everywhere, and for everyone on narrow screens. */
.map-handoffs{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;list-style:none}
.map-actions{display:flex;flex-wrap:wrap;align-items:flex-start;gap:24px 42px;margin-top:clamp(56px,6vw,90px)}
.map-actions .chapter-link{margin-top:0}
/* The diagram is the way into the full map: the cursor turns to a magnifier over it. */
.map-zoom{display:block;width:100%;padding:0;border:0;background:none;color:inherit;text-align:left;cursor:zoom-in}
.map-zoom:focus-visible{outline:2px solid var(--paper);outline-offset:8px}

/* The full system map, in a dialog: the expanded prototype's graph, unchanged, given the whole screen. */
.network-dialog.system-network{width:min(1640px,calc(100vw - 48px));height:min(1000px,calc(100dvh - 48px));max-width:none;max-height:none;margin:auto;padding:0;border:1px solid var(--line);background:#000;color:var(--paper);overflow:hidden}
.network-dialog[open]{display:flex;flex-direction:column}
.network-dialog::backdrop{background:rgb(0 0 0 / .72)}
.network-dialog-head{display:flex;align-items:baseline;flex-wrap:wrap;gap:8px 24px;padding:22px 28px 0}
body[data-type] .network-dialog h2{margin:0;font:500 26px/1.1 var(--headline);letter-spacing:-.03em;text-transform:none}
.network-dialog-head p{color:#a9b0a5;font:14px/1.5 var(--sans)}
.network-dialog-close{margin-left:auto;padding:0 6px;background:none;border:0;color:#c9cec3;font:30px/1 var(--sans);cursor:pointer}
.network-dialog-close:hover{color:var(--paper)}
.network-dialog-close:focus-visible{outline:2px solid var(--accent);outline-offset:4px}
.network-dialog .network-workspace{flex:1 1 auto;height:auto;min-height:0;margin:0}
@media(max-width:999px){
  .network-dialog.system-network{width:100vw;height:100dvh;border:0}
  .network-dialog-head{position:relative;display:block;padding:16px calc(var(--gutter) + 44px) 12px var(--gutter)}
  .network-dialog-head p{margin-top:6px}
  .network-dialog-close{position:absolute;top:10px;right:calc(var(--gutter) - 6px)}
  .network-dialog .network-workspace{overflow:auto;overscroll-behavior:contain}
  .network-dialog .network-viewport{position:relative;inset:auto;width:1800px;height:1020px;touch-action:pan-x pan-y pinch-zoom}
  .network-dialog .network-toolbar{position:sticky;top:12px;left:12px;transform:none;flex-wrap:nowrap;width:max-content;max-width:none;margin:12px 0 -64px 12px}
}
/* Narrow screens get the stacked diagram with short labels. */
.map-compact{display:none;max-width:460px}
.map-compact .map-name{font-size:17px}
.map-compact .map-label{font-size:13px}
@media(max-width:999px){.map-wide{display:none}.map-compact{display:block}}

/* Team: title, then copy, on the same edge. */
.team-chapter{align-items:flex-start}
.team-chapter .team-intro{display:block;width:100%;max-width:none}
.team-intro-copy{max-width:62ch;margin-top:28px}

/* Closing footer small print. */
.site-end-bottom{flex-wrap:wrap}
.site-end-bottom p{margin:0}
