/* goMoE. One room of the model, close up: the first screen crops it, the second opens all of it to click, then the
   suite as an index, our own numbers on the dark sheet, and the docs beside the way in. Dusk is the only accent,
   and it comes from data-step="build". Everything else is the kit. */

/* ---------- motion shared with the other pages about things we built (page-built.js adds the classes) ---------- */
.is-rise { opacity: 0; translate: 0 22px; }
.is-rise.is-in { opacity: 1; translate: none; transition: opacity 0.6s var(--out) calc(var(--rise-i, 0) * 60ms), translate 0.7s var(--out) calc(var(--rise-i, 0) * 60ms); }

/* ---------- the first screen ---------- */
/* The claim is long, so it sets smaller than a k-display and the column holds it in four lines at 1440. */
.gm-hero .k-display { font-size: clamp(32px, 3.5vw, 64px); line-height: 1; }
.gm-hero .k-hero-words { justify-content: space-between; }
/* The camera pushes in on the room as the page opens. */
@media (prefers-reduced-motion: no-preference) {
  .gm-hero .k-scene { animation: gm-push 0.9s var(--out) both; }
  @keyframes gm-push { from { scale: 1.08; } }
}
.gm-rail { display: none; }

/* On a wide screen three marks carry their names and the other three wait for the room below. */
@media (min-width: 700px) and (min-aspect-ratio: 41/50) {
  .gm-hero .k-mark:not(.is-named) { display: none; }
  .gm-hero .k-mark.is-named > b { opacity: 1; translate: -50% 0; font-size: 12px; padding: 6px 9px; }
}
html:not(.js) .k-mark { display: none; }

/* ---------- the room ---------- */
.gm-room { position: relative; }
.gm-room .k-pin { gap: 1.6em; padding: 8px 11px; }
.gm-room .k-pin span { color: var(--stone); }
.gm-shot { --ar: 16 / 9; --sq-r: 10px; }
/* With script the cards live in kit.js's layer, so their list is empty. With script off they read here as a list. */
.js .gm-cards { display: none; }
.gm-cards { padding-block: var(--k-gap); }
.gm-cards-head { margin-bottom: 18px; }
html:not(.js) .gm-shot { display: none; }
/* Stepping by button is for the sheet, where there is no arrow key. On a wide screen the arrow keys walk the marks. */
.k-pop footer.gm-step { display: none; }

/* ---------- the suite ---------- */
.gm-suite-h { max-width: 16em; }
.gm-suite { --cols: minmax(0, 3.2fr) minmax(0, 7fr) minmax(0, 2.5fr); --cols-s: minmax(0, 1fr); }
.gm-suite .k-row:not(details), .gm-suite .k-row > summary { align-items: center; padding-block: clamp(18px, 1.8vw, 28px); }
.gm-suite .k-row > summary::before, .gm-suite .k-row > summary::after { top: 50%; }
.gm-suite .k-row.is-dim small { color: var(--dim); }
/* A row that does not open keeps the room the plus takes in the rows that do, so the columns line up. */
.gm-suite .k-row:not(details) { padding-right: 28px; }
.gm-suite .k-row-more { padding-bottom: clamp(18px, 1.8vw, 28px); }
.gm-suite .k-row-more .k-text { max-width: 36em; }
/* A row opens over 0.42 s where the browser can animate to its own height. */
@media (prefers-reduced-motion: no-preference) {
  @supports (interpolate-size: allow-keywords) {
    .gm-suite { interpolate-size: allow-keywords; }
    .gm-suite details::details-content { block-size: 0; overflow: clip; transition: block-size 0.42s var(--out), content-visibility 0.42s allow-discrete; }
    .gm-suite details[open]::details-content { block-size: auto; }
  }
}

/* ---------- our numbers ---------- */
.gm-num { display: block; text-align: left; cursor: help; }
.gm-num b { display: block; }
.gm-built .k-figures { gap: clamp(28px, 7vw, 132px); }
.gm-built .k-lede { max-width: 38em; }
.gm-built-on { justify-content: flex-end; }
.gm-built .k-figure span { text-wrap: balance; }
/* The bar fills from the left as it comes into view. */
.gm-share.is-rise .k-meter > .is-on { scale: 0 1; transform-origin: 0 50%; }
.gm-share.is-rise.is-in .k-meter > .is-on { scale: 1 1; transition: scale 1.2s var(--out) 0.15s; }

/* ---------- the docs and the way in ---------- */
.gm-way .k-split { align-items: center; }
.gm-docs { max-width: 34em; }
.gm-docs .k-doc { padding: clamp(18px, 2vw, 30px); }
.gm-doc-rows > li { align-items: center; padding: 0; }
.gm-doc-rows > li > span { color: var(--stone); }
.gm-doc-rows button { display: block; width: 100%; min-height: 44px; text-align: left; font-size: 14px; color: var(--stone); transition: color 0.2s; }
.gm-doc-rows button b { color: inherit; }
.gm-doc-rows button:is(:hover, :focus-visible, [aria-expanded="true"]) { color: var(--ink); }
.gm-doc-rows > li:has(button:is(:hover, :focus-visible, [aria-expanded="true"])) { background: var(--paper); margin-inline: -10px; padding-inline: 10px; }
.gm-docs .k-doc-head a { display: inline-block; margin-block: -15px; padding-block: 15px; text-decoration-color: var(--faint); text-underline-offset: 0.2em; color: var(--ink); }

/* ---------- narrower ---------- */
@media (max-width: 899px) {
  .gm-built-on { justify-content: flex-start; }
  .gm-docs { max-width: none; }
}

/* A phone or an upright tablet. The first screen takes over the room's job: its band holds all six marks, a row of
   chips opens them as sheets, and the wide room below is put away. */
@media (max-width: 699px), (max-aspect-ratio: 41/50) {
  .gm-hero .k-display { font-size: clamp(28px, 7.4vw, 46px); line-height: 1.02; }
  .gm-hero .k-scene { --fx: 0.5; }
  .js .gm-rail { display: grid; gap: 10px; width: 100%; min-width: 0; }
  .js .gm-room .k-band { display: none; }
  .js .k-pop footer.gm-step { display: flex; justify-content: space-between; }
}

/* A phone. The kit sets a big row as name and status, then the sentence. A long status wraps in its own column. */
@media (max-width: 699px) {
  .gm-suite .k-row:not(details), .gm-suite .k-row > summary { grid-template-columns: minmax(0, 1fr) minmax(0, 9.5em); align-items: start; }
  .gm-suite .k-row > summary::before, .gm-suite .k-row > summary::after { top: 32px; }
  .gm-suite .k-row small { padding-top: 5px; }
}

@media (prefers-reduced-motion: reduce) {
  .gm-doc-rows button { transition-duration: 0.01s; }
}
