/* ---------------------------------------------------------------
   Header test (home-test.html, Breno 2026-11-06).
   Direction h15 "Hybrid" from the v2 bake-off: the nav sits on the
   white page, then one grey panel with the line on the left and a
   For humans / For AI frame on the right. After it, the cases.
   Buttons on this page are rounded pills with no shadow.
   --------------------------------------------------------------- */

.home-test {
  --ink-soft: #5a4847;
  /* tokens from the h15 header, used on the whole page */
  /* --radius: the site-wide corner, set once in case-shared.css */
  /* --line, --line-strong, --shadow-frame(-up): components.css */
  --ease-soft: var(--ease-out);
}

/* The old hero (lockup, photo, "Hi, I'm Breno") is gone on this page */
.home-test :is(.card, .type-layer, .content) { display: none !important; }

/* ---------- Header ---------- */
.h15 {
  --n: clamp(0.75, var(--u, 1), 1.5);
  /* the white frame around the grey panel at the top of the page */
  --it: calc(var(--n) * 98px);
  --is: calc(var(--n) * 16px);
  --ib: calc(var(--n) * 16px);
  --r: var(--radius);
  --k: calc(1 - var(--grow, 0)); /* home-test.js: 0 → 1 over the first scroll */
}
/* The panel is full bleed and runs straight into the grey of the cases.
   The white frame is a mat fixed to the screen: its window opens evenly
   on all four sides as you scroll, so the grey grows to fill the page
   and no white seam ever shows between the header and the cases */
.h15__panel {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: 24px;
  align-items: center;
  min-height: 100vh;
  padding: calc(var(--it) + 48px) calc(var(--is) + 48px) calc(var(--ib) + 48px) calc(var(--is) + var(--n) * 16px);
  background: var(--grey);
}
.h15__mat {
  position: fixed;
  z-index: 45; /* over the page, under the nav */
  top: calc(var(--it) * var(--k));
  right: calc(var(--is) * var(--k));
  bottom: calc(var(--ib) * var(--k));
  left: calc(var(--is) * var(--k));
  border-radius: calc(var(--r) * var(--k));
  box-shadow: 0 0 0 200vmax var(--white);
  pointer-events: none;
}
.h15[data-grown] .h15__mat { display: none; }
/* Desktop: the header holds still while the grey grows (40vh of scroll,
   the same distance home-test.js uses), then the page scrolls on */
@media (min-width: 1024px) {
  .h15 { height: 140vh; }
  .h15__panel { position: sticky; top: 0; height: 100vh; min-height: 0; }
}
/* Scroll cue (components.css): on the edge of the grey panel, which moves
   out as the mat opens, in the panel's grey */
.h15 .scroll-cue { --scroll-cue-edge: calc(var(--ib) * var(--k)); --scroll-cue-bg: var(--grey); }
.h15__text { grid-column: 1 / 7; display: grid; gap: 32px; padding-right: 24px; align-content: center; }
.h15__h {
  margin: 0;
  font-family: "GT America";
  font-weight: 300;
  font-size: clamp(2.75rem, 1rem + 2.8vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  color: var(--black);
}
.h15__btns { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }
.h15__right { grid-column: 7 / 13; display: grid; gap: 12px; }
.h15__switch { display: flex; justify-content: flex-end; }

/* ---------- Pills (the rounded button style for this page) ---------- */
.hbtn {
  display: inline-flex;
  align-items: center;
  height: 52px;   /* main CTA: the usual 48–56 of product sites */
  padding: 0 28px;
  border-radius: 999px;
  font-family: "GT America";
  font-weight: 400;
  font-size: 17px;
  color: var(--black);
  text-decoration: none;
  white-space: nowrap;
  transition: background-color var(--dur-xs), box-shadow var(--dur-xs);
}
.hbtn--ink { background: var(--black); color: var(--white); }
.hbtn--ink:hover { background: #3a1e1e; }
.hbtn--line { box-shadow: inset 0 0 0 1px rgba(28, 3, 3, 0.3); }
.hbtn--line:hover { background: rgba(28, 3, 3, 0.06); box-shadow: inset 0 0 0 1px rgba(28, 3, 3, 0.45); }
.hbtn:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* The border beam on See my work lives in beam.css (Libraries.dev's Border Beam, ported) */

/* Segmented switch */
.seg { position: relative; display: inline-flex; padding: 3px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
/* One white thumb slides under the labels and takes the width of the one
   it lands on, stretching a little on the way (home-test.js places it) */
.seg__thumb {
  position: absolute;
  top: 3px; bottom: 3px; left: 0;
  width: var(--w, 0px);
  translate: var(--x, 0px) 0;
  border-radius: 999px;
  background: var(--white);
  box-shadow: inset 0 0 0 1px var(--line-strong), 0 2px 6px -2px rgba(28, 3, 3, 0.2);
  transition: translate var(--dur-m) var(--ease-spring), width var(--dur-m) var(--ease-spring), scale var(--dur-xs) ease;
  pointer-events: none;
}
.seg.is-moving .seg__thumb { scale: 1.04 0.94; }
.seg:not(.is-ready) .seg__thumb { transition: none; }
.seg button { position: relative; z-index: 1; transition: color var(--dur-s); }
.seg button {
  font: inherit; font-family: "GT America"; font-size: 15px;
  height: 36px; padding: 0 16px; border: 0; border-radius: 999px;
  background: none; color: var(--ink-soft); cursor: pointer;
}
.seg button[aria-pressed="true"] { color: var(--black); }
@media (prefers-reduced-motion: reduce) { .seg__thumb, .h15__tabs button::before { transition: none; } .seg.is-moving .seg__thumb { scale: none; } }

/* ---------- The frame ---------- */
.h15__frame {
  background: var(--white);
  border-radius: var(--radius);
  padding: 8px;
  box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgba(28, 3, 3, 0.04), 0 16px 40px -20px rgba(28, 3, 3, 0.18);
}
.h15__bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 48px; padding: 0 4px 8px 12px; }
.h15__bar--human { padding: 0 0 8px; }
.h15__fname { display: inline-flex; align-items: center; gap: 10px; font-family: "GT America Mono"; font-size: 13px; color: var(--black); }
.h15__fname i { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--red); }
.h15__acts { display: flex; gap: 4px; }
.h15__act {
  font: inherit; font-family: "GT America Mono"; font-size: 12px; letter-spacing: 0.01em;
  height: 32px; padding: 0 14px; border: 0; border-radius: 999px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  background: var(--grey); color: var(--black); text-decoration: none;
  transition: background-color var(--dur-xs);
}
.h15__act:hover { background: #c1c1c1; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Copy button: icon morphs copy → check, label rolls Copy → Copied */
.h15__copy { gap: 7px; }
.h15__ic { position: relative; width: 14px; height: 14px; }
.h15__ic svg { position: absolute; inset: 0; transition: opacity var(--dur-xs), scale var(--dur-s) var(--ease-spring); }
.h15__ic-check { opacity: 0; scale: 0.6; }
.h15__ic-check path { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset var(--dur-s) var(--ease-in-out) 0.08s; }
.h15__copy-label { display: grid; height: 1.3em; overflow: hidden; text-align: left; }
.h15__copy-label span { grid-area: 1 / 1; line-height: 1.3em; transition: translate var(--dur-s) var(--ease-out), opacity var(--dur-xs); }
.h15__copy-label [data-l="copied"] { translate: 0 100%; opacity: 0; }
.h15__copy.is-copied { background: var(--black); color: var(--white); }
.h15__copy.is-copied .h15__ic-copy { opacity: 0; scale: 0.6; }
.h15__copy.is-copied .h15__ic-check { opacity: 1; scale: 1; }
.h15__copy.is-copied .h15__ic-check path { stroke-dashoffset: 0; }
.h15__copy.is-copied [data-l="copy"] { translate: 0 -100%; opacity: 0; }
.h15__copy.is-copied [data-l="copied"] { translate: 0 0; opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .h15__ic svg, .h15__ic-check path, .h15__copy-label span { transition: opacity var(--dur-xs); }
}
.h15__tabs { position: relative; display: flex; gap: 4px; }
/* Same sliding thumb as the switch, in the tabs' grey */
.h15__tabs .seg__thumb { top: 0; bottom: 0; background: var(--grey); box-shadow: none; }
.h15__tabs button { position: relative; z-index: 1; transition: color var(--dur-s); }
/* the red dot grows in on the chosen tab instead of popping */
.h15__tabs button::before {
  content: ""; display: inline-block; width: 0; height: 6px; margin-right: -8px;
  border-radius: 50%; background: var(--red); scale: 0;
  transition: width var(--dur-s) var(--ease-out), margin var(--dur-s) var(--ease-out), scale var(--dur-s) var(--ease-spring) 0.1s;
}
.h15__tabs button[aria-selected="true"]::before { width: 6px; margin-right: 0; scale: 1; }
.h15__tabs button {
  font: inherit; font-family: "GT America"; font-size: 15px;
  height: 40px; padding: 0 18px; border: 0; border-radius: 999px;
  background: none; color: var(--ink-soft); cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
}
.h15__tabs button[aria-selected="true"] { color: var(--black); }

.h15__field {
  height: var(--fh, min(62vh, 560px)); /* home-test.js: fits the tallest tab */
  background: var(--grey);
  border-radius: var(--radius);
}
.h15__human {
  overflow: hidden;
}
.h15__ai {
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(28, 3, 3, 0.2) transparent;
}
@media (max-width: 1023px) {
  .h15__ai { overscroll-behavior: auto; }
}
.h15__field:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.h15__right[data-reader="ai"] :is(.h15__bar--human, .h15__human),
.h15__right[data-reader="human"] :is(.h15__bar--ai, .h15__ai) { display: none; }
.h15__right[data-reader="human"] .h15__human,
.h15__right[data-reader="ai"] .h15__ai { animation: h15-in 400ms var(--ease-soft); }
@keyframes h15-in { from { opacity: 0; } to { opacity: 1; } }

/* For AI: breno.md as a quiet file, line numbers, markers in red */
.h15__ai { height: var(--fh-ai, var(--fh, min(62vh, 560px))); padding: 24px 8px 24px 0; }
/* the line above the file: what it is for (Breno, 2026-11-08) */
.h15__hint {
  margin: 0 24px 20px 16px; padding: 12px 16px; border-radius: 12px; background: var(--white); /* full width, its edge on the line numbers */
  font-family: "GT America"; font-weight: 400; font-size: 15px; line-height: 1.4; letter-spacing: -0.005em; color: var(--black);
}
.mdfile { font-family: "GT America Mono"; font-size: 13px; line-height: 1.85; color: var(--black); }
.mdfile p { margin: 0; }
.mdfile__l { display: grid; grid-template-columns: 44px 1fr; }
.mdfile__n { text-align: right; padding-right: 18px; color: rgba(28, 3, 3, 0.28); user-select: none; }
.mdfile__t { white-space: pre-wrap; overflow-wrap: anywhere; padding-right: 24px; }
.mdfile .m { color: #9c2a2a; }
.mdfile .u, .mdfile .q { color: var(--ink-soft); }
.mdfile b { font-weight: 400; }

/* For humans: the facts */
.h15__human { padding: 28px 32px 8px; display: flex; flex-direction: column; gap: 4px; }
/* For humans opens with a face: portrait, name, previous roles */
.h15__me { display: flex; align-items: center; gap: 16px; padding-bottom: 20px; }
.h15__photo {
  flex: none; width: 64px; height: 64px; border-radius: 50%;
  /* the photo is a wide shot: zoom in on head and shoulders */
  background: url("../img/photo-breno.webp") 20% 8% / 220% auto no-repeat #2a3550;
  box-shadow: 0 0 0 3px var(--white), 0 4px 12px -4px rgba(28, 3, 3, 0.3);
}
.h15__who { display: grid; gap: 2px; margin: 0; font-family: "GT America"; }
.h15__name { font-size: 18px; color: var(--black); }
.h15__prev { font-size: 15px; color: var(--ink-soft); }
.h15__prev span { font-size: 13px; margin-right: 6px; }
.h15__pane { display: grid; }
/* the card's height comes from the tallest tab; in the others the rows
   share the spare room, so the lines spread evenly instead of leaving a
   gap at the bottom (Breno, 2026-11-08) */
.h15__human .h15__pane:not([hidden]) { flex: 1 0 auto; display: flex; flex-direction: column; }
.h15__human .h15__pane > .h15__row { flex: 1 0 auto; }
.h15__pane[hidden] { display: none; }
.h15__row { display: grid; grid-template-columns: 11.5rem 1fr; gap: 24px; align-items: start; border-top: 1px solid var(--line); padding: 20px 0 24px; }

.h15__row p { margin: 0; font-family: "GT America"; }
.h15__n { font-weight: 300; font-size: 3rem; line-height: 1; letter-spacing: -0.04em; color: var(--black); }
.h15__row p:last-child { color: var(--ink-soft); max-width: 22em; padding-top: 4px; font-size: 16px; line-height: 1.45; }

/* ---------- Rounded buttons everywhere on this page ---------- */
/* Two button sizes: large (52px) for the header CTAs (.hbtn), small (40px)
   for the cases' Read more */
/* no lift and no shadow on hover: the fill shifts, like the pills */

/* ---------- Smaller screens ---------- */
@media (max-width: 1023px) {
  .h15 { position: relative; overflow: hidden; }
  .h15__mat { position: absolute; }
  .h15__panel { grid-template-columns: minmax(0, 1fr); row-gap: 48px; padding: calc(var(--it) + 64px) calc(var(--is) + 24px) calc(var(--ib) + 24px); min-height: 0; }
  .h15__text, .h15__right { grid-column: 1 / -1; padding-right: 0; min-width: 0; grid-template-columns: minmax(0, 1fr); }
  .h15__frame { min-width: 0; }
  .h15__switch { justify-content: flex-start; }
}
@media (max-width: 767px) {
  .h15 { --it: 68px; --is: 8px; --ib: 8px; }
  .h15__panel { padding: calc(var(--it) + 32px) calc(var(--is) + 16px) calc(var(--ib) + 20px); row-gap: 32px; }
  .h15__text { gap: 24px; }
  .h15__acts .h15__act:nth-child(2) { display: none; }
  .h15__row { grid-template-columns: 7.25rem 1fr; gap: 16px; padding: 16px 0 20px; }
  .h15__n { font-size: 2rem; }
  .h15__n--word { font-size: 1.35rem; white-space: normal; line-height: 1.12; padding-top: 2px; }
  .h15__human { padding: 20px; }
  .h15__bar--human { overflow-x: auto; max-width: 100%; scrollbar-width: none; touch-action: pan-x pan-y; }
  .h15__bar--human::-webkit-scrollbar { display: none; }
  .h15__tabs { gap: 2px; width: 100%; justify-content: space-between; }
  .h15__tabs button { font-size: 13px; height: 36px; padding: 0 11px; flex: 1 1 auto; justify-content: center; white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) { .h15__human, .h15__ai { animation: none !important; } }


/* ---------------------------------------------------------------
   The header's tokens on everything below it: a hairline stroke and
   the soft frame shadow instead of the 1px border + small shadow,
   20 / 14 radii instead of 4 / 8, pill chips instead of square tags
   --------------------------------------------------------------- */
/* What I'm up to: flat white frames, no texture */
html.home-test .social {
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-frame);
}
html.home-test .social.is-settled:hover { box-shadow: var(--shadow-frame-up); }
html.home-test .social .pill {
  padding: calc(var(--u) * 3px) calc(var(--u) * 9px);
  border-radius: 999px;
  background: var(--grey);
  box-shadow: none;
  filter: none;
}

/* Latest articles: thumbnails use the same radius */
html.home-test .article__thumb, html.home-test .article:focus-visible { border-radius: var(--radius); }

/* Footer buttons: pills (this beats the stage rule that keeps them square) */


/* The case cards (.cs, .cx) live in components.css, shared by every page. The old
   scroll-driven cases (.case, .cc) were archived on 2026-11-12 (assets/archive). */

/* Button tokens (looks, hover, press, focus) now live in case-shared.css,
   for every page. Only home-test's own sizes stay here. */
html.home-test .hbtn { height: var(--btn-lg-h); padding: 0 var(--btn-lg-px); font-size: var(--btn-lg-fs); }
html.home-test .cx__cta { height: var(--btn-sm-h); padding: 0 var(--btn-sm-px); font-size: var(--btn-sm-fs); }


/* Building with AI: a row led by a name instead of a number */
.h15__n--word { font-size: 1.75rem; letter-spacing: -0.03em; padding-top: 6px; }
/* One weight per title (Breno, 2026-11-07): no more mixing the identity's
   thin compressed italic with the black expanded cut. Section titles use the
   header's voice: GT America Light, tight tracking */
html.home-test :is(.upto__title, .latest) {
  font-family: "GT America"; font-weight: 300; font-style: normal; letter-spacing: -0.03em;
}

/* Cases → What I'm up to: no empty screen between them. The pinned stage
   slides up under the cases (they sit above it), so "What I'm up to"
   arrives right after the last card */
html.home-test .cs { position: relative; z-index: 31; padding-bottom: 0; }
/* "What I'm up to" arrives one --section-gap under the last case (its stage
   position, State 19, is 470 frame units down) */
html.home-test.is-stage .hero { margin-top: calc(var(--u) * -470px + var(--section-gap)); }
/* phones: the same gap between the sections in the flow */
html.home-test:not(.is-stage) .cs { padding-bottom: var(--section-gap); }
html.home-test:not(.is-stage) .articles { padding-bottom: var(--section-gap); }

.h15__n { white-space: nowrap; }
/* phones (no stage): the same large title size as the rest of the site */
html.home-test:not(.is-stage) :is(.upto__title, .latest) { font-size: var(--title-lg); line-height: 1.04; }

/* End section between the articles and the footer, now holding the
   contact card (the closing quote was removed, Breno, 2026-11-11).
   home-test.js moves it on the stage; phones keep it in the flow. */
.endquote {
  position: absolute; z-index: 28; top: 0; left: 50%;
  display: flex; flex-direction: column; align-items: center;
  visibility: hidden; will-change: transform, opacity;
}
html:not(.is-stage) .endquote {
  order: 9; position: relative; top: auto; left: auto; width: auto;
  background: var(--grey);
  transform: none !important; opacity: 1 !important; visibility: visible !important;
}

/* Type roles on the remaining home pieces (audit, 2026-11-08): the article
   cards and the social card tags speak the site's roles too */
html.home-test .article__line { font-family: "GT America"; font-weight: 400; font-style: normal; letter-spacing: -0.01em; }
html.home-test .article__desc { font-family: "GT America"; font-weight: 300; letter-spacing: -0.005em; color: var(--text-soft); }
html.home-test .article__date { font-family: "GT America Mono"; font-weight: 400; letter-spacing: 0.01em; text-transform: none; color: var(--text-faint); }
html.home-test .social .pill { font-family: "GT America Mono"; font-weight: 400; letter-spacing: 0.01em; }

/* For humans tabs: no red dot (Breno, 2026-11-08: used nowhere else) */
.h15__tabs button::before, .h15__tabs button[aria-selected="true"]::before { content: none; display: none; }
/* the cards widen for the mono tags (Breno, 2026-11-08); home-test.js
   spaces them to match */
html.home-test.is-stage .social { width: calc(var(--u) * 245px); }
/* the name one step up from the mono tag: GT America Regular, 23
   (Breno, 2026-11-08: a clearer hierarchy) */
html.home-test .social__name { font-family: "GT America"; font-weight: 400; font-size: calc(var(--u) * 23px); line-height: 1.2; letter-spacing: -0.01em; color: var(--text); }
html.home-test:not(.is-stage) .social__name { font-size: 22px; }

/* Latest articles: title and description on two clearly different roles
   (Breno, 2026-11-08): the title a step up, full ink; the description the
   small body, soft */
html.home-test .article__title { font-family: "GT America"; font-weight: 400; font-size: calc(var(--u) * 22px); line-height: 1.25; letter-spacing: -0.015em; color: var(--text); }
html.home-test .article__desc { font-size: calc(var(--u) * 15px); line-height: 1.45; color: var(--text-soft); margin-top: calc(var(--u) * 4px); }
html.home-test:not(.is-stage) .article__title { font-size: 21px; }
html.home-test:not(.is-stage) .article__desc { font-size: 15px; }

/* home-test.js puts one --section-gap above the end section and one
   before the footer (2026-11-11) */
html.home-test.is-stage .endquote { width: calc(100vw - 32px); }
html.home-test:not(.is-stage) .endquote { padding: 0 0 var(--section-gap); }
html.home-test:not(.is-stage) .talk { padding-inline: 24px; }
html.home-test:not(.is-stage) .page .footer { order: 10; }

@media (max-width: 767px) {
  html.home-test:root:root body .h15__tabs { width: 100%; max-width: 100%; padding: 3px; gap: 2px; }
  html.home-test:root:root body .h15__tabs button { height: 34px; padding: 0 7px; font-size: 12px; gap: 4px; flex: 1 1 0; min-width: 0; }
  html.home-test:not(.is-stage) .upto { grid-template-columns: 1fr; padding: 16px 16px 48px; gap: 12px; }
  html.home-test:not(.is-stage) .upto__title { margin-bottom: 12px; }
  html.home-test:not(.is-stage) .social { max-width: none; padding: 20px; }
  html.home-test:not(.is-stage) .latest { padding: 16px 16px 20px; }
  html.home-test:not(.is-stage) .articles { padding: 8px 16px var(--section-gap); }
  html.home-test:not(.is-stage) .talk { padding-inline: 16px; }
}
