/* Homepage additions to system/case.css: the header nav, the hero with portrait,
   the project rows with their prototype previews, the about block.
   No new tokens: same column, same hairlines, same type scale as the cases. */

.site-nav { display: flex; gap: 24px; }

/* Wide sections: the section widens to --wide; its content keeps the left
   edge of the 680 column used by the rest of the page. */
main > section.hero--home,
main > section.home-section--wide { max-width: var(--wide); container-type: inline-size; }
.home-section--wide > * { margin-left: max(0px, (100cqw - var(--col)) / 2); }

/* ── Hero: name, role, hook, one line of scope; portrait to the right ── */
main > section.hero--home { padding-top: clamp(32px, 6vw, 72px); }
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(200px, 28cqw, 300px);
  column-gap: 40px;
  align-items: end;
  padding-left: max(0px, (100cqw - var(--col)) / 2);
}
.hero--home h1 { margin-bottom: 8px; }
.hero-role { font-size: 19px; line-height: 1.4; letter-spacing: -0.015em; color: var(--ink-3); }
.hero-hook { margin-top: 36px; font-size: clamp(22px, 2.5vw, 27px); font-weight: 500; line-height: 1.25; letter-spacing: -0.028em; color: var(--ink); text-wrap: pretty; max-width: 22em; }
.hero-intro { margin-top: 14px; color: var(--ink-2); text-wrap: pretty; max-width: 34em; }
.hero-photo img { width: 100%; height: auto; }
@container (max-width: 620px) {
  /* mobile: name and role first, a small portrait beside them */
  .hero-inner {
    grid-template-columns: minmax(0, 1fr) 92px;
    grid-template-areas: 'name photo' 'role photo' 'hook hook' 'intro intro';
    column-gap: 16px; align-items: center; padding-left: 0;
  }
  .hero-text { display: contents; }
  .hero--home h1 { grid-area: name; align-self: end; margin-bottom: 4px; }
  .hero-role { grid-area: role; align-self: start; font-size: 16px; }
  .hero-hook { grid-area: hook; margin-top: 28px; }
  .hero-intro { grid-area: intro; }
  .hero-photo { grid-area: photo; }
}

.home-section { padding-top: clamp(64px, 8vw, 88px); scroll-margin-top: 24px; }
.home-section > .label { margin-bottom: 12px; }

/* ── Project rows: text in the column, a cropped prototype to the right ── */
.projects { list-style: none; border-top: 1px solid var(--ink); }
.projects > li { border-bottom: 1px solid var(--rule); }
.project {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(240px, 30cqw, 320px);
  column-gap: 40px;
  align-items: center;
  padding: 28px 0;
  text-decoration: none;
}
.p-text { display: flex; flex-direction: column; min-width: 0; }
.project .label { margin-bottom: 10px; }
.p-head { display: flex; align-items: baseline; justify-content: space-between; gap: 24px; }
.p-title { font-size: 22px; font-weight: 500; line-height: 1.25; letter-spacing: -0.025em; color: var(--ink); text-wrap: pretty; }
.p-lede { margin-top: 10px; font-size: 16px; line-height: 1.55; color: var(--ink-2); text-wrap: pretty; }
.p-role { margin-top: 8px; font-size: 15px; line-height: 1.5; color: var(--ink-3); text-wrap: pretty; }
.p-fact { margin-top: 14px; font-size: 14px; line-height: 1.5; color: var(--ink); font-weight: 500; }
.project .arrow { flex: none; font-size: 22px; line-height: 1.25; transition: transform .2s cubic-bezier(.2,.8,.2,1); }
a.project:hover .arrow { transform: translateX(4px); }
a.project:hover .p-title { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.project--soon { display: block; padding: 20px 0 22px; }
.project--soon .label { margin-bottom: 4px; }
.project--soon .p-title { font-size: 17px; color: var(--ink-3); }

/* Preview: one whole phone on the canvas grey, centred. A visual anchor for
   the case, not a screen to read (Quentin, 2026-11-07). */
.preview {
  display: block; position: relative; overflow: hidden;
  height: 360px; border-radius: 14px; background: var(--surface);
}
.preview .proto { --s: .35; display: block; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.preview .row.fresh { animation: hero-in .6s cubic-bezier(.2,.8,.2,1) .1s both; transform-origin: 50% 100%; }
.preview .iphone .hw { box-shadow: inset 0 0 0 1.5px #8e8e93, inset 0 0 0 4px #2c2c2e, 0 20px 40px -20px rgba(0,0,0,.3); }
@container (max-width: 620px) {
  .project { grid-template-columns: minmax(0, 1fr); row-gap: 20px; padding: 22px 0 24px; }
  .preview { height: 300px; }
  .preview .proto { --s: .29; }
}

/* ── About ── */
.about p { color: var(--ink-2); text-wrap: pretty; }
.about p + p { margin-top: 1.1em; }
.about .brief { margin-top: 40px; }
.about .brief a { text-underline-offset: 3px; text-decoration-thickness: 1px; }

/* Facts still to confirm before publishing: visible on purpose */
.tbc { background: #FFF8E6; box-shadow: 0 0 0 2px #FFF8E6; outline: 1px dashed #E0B85A; outline-offset: 2px; border-radius: 2px; }

@media (max-width: 640px) {
  .site-nav { gap: 16px; }
  .p-title { font-size: 20px; }
  .p-lede { font-size: 15.5px; }
}

/* ── Ways of working: two dated rows, the current method first ── */
.ways-list { list-style: none; border-top: 1px solid var(--ink); }
.way { padding: 28px 0 30px; border-bottom: 1px solid var(--rule); }
.way .label { margin-bottom: 10px; }
.w-title { font-size: 22px; font-weight: 500; line-height: 1.25; letter-spacing: -0.025em; color: var(--ink); text-wrap: pretty; margin: 0; padding: 0; border: 0; }
.w-desc { margin-top: 10px; font-size: 16px; line-height: 1.55; color: var(--ink-2); text-wrap: pretty; }
.w-fact { margin-top: 14px; font-size: 15px; line-height: 1.5; color: var(--ink); font-weight: 500; text-wrap: pretty; }
.w-tools { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 14px; font-size: 13px; line-height: 1.5; color: var(--ink-3); }
.tool { display: inline-flex; align-items: center; gap: 6px; }
.tool-ico { width: 14px; height: 14px; flex: none; fill: currentColor; }
.way--before .w-title { color: var(--ink-2); }
@media (max-width: 640px) {
  .w-title { font-size: 20px; }
  .w-desc { font-size: 15.5px; }
}
.w-desc + .w-desc { margin-top: 0.8em; }

/* Company on each case card */
.p-text .company { align-self: flex-start; margin-bottom: 12px; font-size: 14px; }
.p-text .company svg { width: 20px; height: 20px; }

/* ── Short cases across the product: before/after cards ── */
.shorts { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 24px; align-items: start; border-top: 1px solid var(--ink); padding-top: 28px; }
.short { display: flex; flex-direction: column; text-decoration: none; }
.short-ba { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 12px; border-radius: 14px; background: var(--surface); aspect-ratio: 16 / 8.5; margin-bottom: 16px; }
.ba-half { position: relative; overflow: hidden; border-radius: 6px; background: #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.06); }
.ba-half img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top left; display: block; }
.ba-half .yr { position: absolute; left: 8px; bottom: 8px; padding: 3px 8px; border-radius: 999px; background: rgba(9,9,7,.82); color: #fff; font-size: 12px; line-height: 1.3; }
.short .company { align-self: flex-start; margin-bottom: 12px; font-size: 14px; }
.short .company svg { width: 20px; height: 20px; }
.short .label { margin-bottom: 8px; }
.short-title { font-size: 19px; font-weight: 500; line-height: 1.3; letter-spacing: -0.02em; color: var(--ink); text-wrap: pretty; }
.short .arrow { flex: none; font-size: 19px; line-height: 1.3; transition: transform .2s cubic-bezier(.2,.8,.2,1); }
.short:hover .arrow { transform: translateX(4px); }
.short-ba { box-shadow: inset 0 0 0 1px transparent; transition: box-shadow .2s ease; }
.short:hover .short-ba { box-shadow: inset 0 0 0 1px rgba(0,0,0,.16); }   /* the panel answers the pointer too */
.short:hover .short-title { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.short-fact { margin-top: 10px; font-size: 14px; line-height: 1.5; font-weight: 500; color: var(--ink); }
/* narrow: one row that swipes, the next card peeking at the edge */
@container (max-width: 760px) {
  .shorts { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: min(78%, 340px); gap: 16px;
    overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; padding-bottom: 4px; }
  .shorts::-webkit-scrollbar { display: none; }
  .shorts > li { scroll-snap-align: start; }
}
/* app screens: whole first screen, phone-shaped, centred in each half */
.short-ba--app .ba-half { background: none; box-shadow: none; border-radius: 0; }
.short-ba--app .ba-half img { object-fit: contain; object-position: center; filter: drop-shadow(0 8px 16px rgba(0,0,0,.12)); }
.short-ba--app .ba-half .yr { left: 50%; transform: translateX(-50%); bottom: 6px; }
.short-ba--app { aspect-ratio: 16 / 12; padding: 16px 12px 12px; gap: 0; }
/* the two app screens scroll on their own, like the product page in use */
.short-ba--app .ba-half { overflow: visible; }
.ba-phone { position: absolute; top: 0; bottom: 26px; left: 50%; transform: translateX(-50%); aspect-ratio: 402 / 874; overflow: hidden; border-radius: 16px; background: #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.08), 0 10px 22px -10px rgba(0,0,0,.25); }
.ba-phone .ba-scroll { position: absolute; top: 0; left: 0; width: 100%; height: auto; will-change: transform; }
.ba-phone .ba-bar { position: absolute; left: 0; bottom: 0; width: 100%; height: auto; }
.short-ba--app .ba-half .yr { bottom: 0; }
/* tags above the screens; the phone window follows the screen's own corner radius
   (iPhone 17 Pro: 55 pt on a 402 × 874 pt screen); the figure line reads like a lede */
.ba-phone { top: 30px; bottom: 0; border-radius: 13.7% / 6.3%; background: none; }
.short-ba--app .ba-half .yr { top: 0; bottom: auto; }
.short-ba--app { padding-top: 12px; }
.short-fact { margin-top: 10px; font-size: 16px; line-height: 1.55; font-weight: 400; color: var(--ink-2); }
/* the phone's own images ignore the generic card image rules */
.short-ba--app .ba-phone img { inset: auto; width: 100%; height: auto; object-fit: initial; object-position: initial; filter: none; }
.short-ba--app .ba-phone .ba-scroll { top: 0; left: 0; }
.short-ba--app .ba-phone .ba-bar { left: 0; bottom: 0; }
.ba-seq .ba-step { position: absolute; top: 0; left: 0; will-change: transform; }
.ba-seq .ba-step:not(:first-child) { transform: translateX(100%); }
.ba-seq .ba-bar { z-index: 3; }   /* the same tab bar on every step */
.short-ba--app .ba-phone { box-shadow: 0 0 0 1px rgba(0,0,0,.08), 0 10px 22px -10px rgba(0,0,0,.28); }
