/* ============================================================
   Product pages, /work/<slug>/ — written by tools/build-products.mjs
   Round 2 (2026-09-27), from docs/research/2026-09-27-product-pages/D-components.md:
   one column at every width, nothing beside the name, the screens staggered on a panel
   tinted with the product's own colour (--pc): the site still has no accent of its own.
   ============================================================ */

.nav__link.is-here { color: var(--ink); }
.nav__link.is-here i { color: var(--ink); }

.pp-k { margin: 0; color: var(--mute); }
.pp-k::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--pc); margin-right: 10px; vertical-align: 1px; }

/* ---------- head: one column, the name never shares a row with anything that can grow ---------- */

.pp-head { padding: clamp(112px, 17vh, 168px) var(--pad) clamp(48px, 8vh, 88px); }
.pp-crumb { margin: 0 0 clamp(26px, 4.5vh, 44px); display: flex; gap: 10px; color: var(--faint); }
.pp-crumb a { color: var(--mute); text-decoration: none; border-bottom: 1px solid var(--rule-strong); }
.pp-crumb a:hover { color: var(--ink); border-color: var(--ink); }

.pp-id { display: flex; align-items: center; gap: clamp(14px, 1.6vw, 24px); }
.pp-icon { width: clamp(56px, 5.8vw, 88px); height: auto; aspect-ratio: 1; flex: none; }
.pp-name {
  margin: 0;
  font-size: clamp(3rem, 6.2vw, 5.6rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.045em;
  padding-bottom: 0.06em;
}
.pp-pitch {
  margin: clamp(18px, 3vh, 28px) 0 0;
  font-size: clamp(1.3rem, 2.2vw, 2rem);
  font-weight: 300;
  line-height: 1.22;
  letter-spacing: -0.02em;
  max-width: 24ch;
  text-wrap: balance;
}
.pp-acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: clamp(24px, 4vh, 36px); }

/* facts are text, not controls: one row under a hairline, label over value */
.pp-facts {
  margin: clamp(44px, 8vh, 80px) 0 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px clamp(20px, 2.4vw, 36px);
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}
.pp-facts dt { color: var(--faint); margin-bottom: 8px; }
.pp-facts dd { margin: 0; color: var(--ink); text-transform: none; letter-spacing: 0.02em; line-height: 1.5; font-size: 12.5px; max-width: 30ch; }

/* ---------- stage: two screens staggered on the product's tint, what it does beside them ---------- */

.pp-stage {
  padding: 0 var(--pad) clamp(72px, 12vh, 148px);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(20px, 2.4vw, 36px);
  align-items: end;
}
.pp-panel {
  grid-column: 1 / 8;
  background: color-mix(in srgb, var(--pc) 26%, var(--bone));
  border-radius: 24px;
  padding: clamp(32px, 5vw, 72px) clamp(16px, 4vw, 64px);
}
.pp-panel--dark { background: var(--pc); }

.pp-phones {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 272px));
  justify-content: center;
  gap: clamp(14px, 2.6vw, 40px);
  align-items: start;
}
/* the stagger: the second phone sits lower by a fifth of its own height (a phone is about 2.2 widths tall) */
.pp-phones .pp-phone:nth-child(1) { margin-bottom: 44%; }
.pp-phones .pp-phone:nth-child(2) { margin-top: 44%; }
/* the device the screen lives in: an ink bezel rounded like the phone, no shadow (DESIGN.md) */
.pp-phone {
  margin: 0;
  background: var(--ink);
  border-radius: 15% / 7%;
  padding: 3%;
}
.pp-phone img { display: block; width: 100%; height: auto; border-radius: 12.5% / 5.8%; }

.pp-cards { display: grid; gap: clamp(22px, 3vw, 36px); max-width: 540px; margin: 0 auto; }
.pp-card { margin: 0; }
.pp-card:nth-child(1) { margin-right: 10%; }
.pp-card:nth-child(2) { margin-left: 10%; }
.pp-card .wcard { margin: 0 7px 7px 0; }
/* on a dark panel the product draws a light ring around card and shadow, as it does on a dark desktop */
.pp-panel--dark .wcard { box-shadow: 5px 5px 0 var(--wc-ink), 0 0 0 1.5px #D9D8D2, 5px 5px 0 1.5px #D9D8D2; }

/* Edit Mode, as card_styles.py draws it: blue band, numbered presets, the instruction under them */
.wcard--edit .wcard__bar { background: #7FDBFF; }
.wcard__doc { width: 14px; height: 14px; color: var(--wc-ink); flex: none; }
.wcard__n { font-family: var(--mono); font-size: 11px; font-weight: 500; color: rgba(13, 13, 15, 0.62); }
.wcard--edit .wcard__lvl { margin-left: 2px; }
.wcard__chips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 12px 14px 0; }
.wcard__chips span {
  display: flex; align-items: center; gap: 8px; min-width: 0;
  padding: 6px 8px; border: 1.5px solid #D6D2C4; border-radius: 8px;
  font-size: 13.5px; font-weight: 500; color: #8C887B; white-space: nowrap; overflow: hidden;
}
.wcard__chips b { flex: none; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 4px; background: #E4E0D3; font: 600 10.5px/1 var(--mono); color: #6F6B5F; }
.wcard__you { font: 500 10.5px/1 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: #8C887B; margin-right: 10px; vertical-align: 2px; }

.pp-about { grid-column: 9 / 13; padding-bottom: 8px; }
.pp-about__t {
  margin: 18px 0 0;
  font-size: clamp(1.15rem, 1.45vw, 1.35rem);
  font-weight: 300;
  line-height: 1.5;
  letter-spacing: -0.008em;
  max-width: 34ch;
}

/* ---------- the why: label left, prose right, signed ---------- */

.pp-why {
  padding: clamp(72px, 12vh, 148px) var(--pad);
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(20px, 2.4vw, 36px);
}
.pp-why > .pp-k { grid-column: 1 / 4; padding-top: 12px; }
.pp-why__body { grid-column: 4 / 11; max-width: 62ch; }
.pp-why__t {
  margin: 0 0 clamp(28px, 4.5vh, 44px);
  max-width: 18ch;
  text-wrap: balance;
  font-size: clamp(2rem, 4vw, 3.3rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.035em;
}
.pp-why__body > p { margin: 0 0 1.05em; font-size: clamp(1.06rem, 1.25vw, 1.2rem); font-weight: 300; line-height: 1.62; }
.pp-why__body > p:first-of-type { font-size: clamp(1.2rem, 1.6vw, 1.42rem); font-weight: 400; line-height: 1.45; letter-spacing: -0.01em; }
.pp-why__body em { font-style: italic; }
.pp-why__body a { text-decoration-color: var(--rule-strong); text-underline-offset: 3px; }
.pp-why__body > .pp-why__sign {
  margin: clamp(32px, 5vh, 48px) 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 18px;
  font-size: 1rem;
}
.pp-why__name { font-weight: 600; font-size: 18px; letter-spacing: -0.01em; }
.pp-why__sign .mono { color: var(--faint); }

/* ---------- more work: the other products, a whole tile each ---------- */

.pp-more { padding: 0 var(--pad) clamp(72px, 12vh, 132px); }
.pp-more__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: clamp(28px, 5vh, 44px); border-top: 1px solid var(--rule); margin-bottom: clamp(20px, 3vh, 28px); }
.pp-more__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.pp-tile {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: clamp(20px, 2.4vw, 32px);
  border: 1px solid var(--rule-strong);
  border-radius: 20px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.3s var(--ease), background-color 0.3s var(--ease);
}
.pp-tile--oss { border-style: dashed; }
.pp-tile:hover { border-color: var(--ink); background: var(--bone-2); }
.pp-tile:focus-visible { outline: 2px solid var(--crew); outline-offset: 4px; }
.pp-tile__top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: clamp(12px, 2.4vh, 22px); }
.pp-tile__top img { width: clamp(48px, 4.4vw, 64px); height: auto; aspect-ratio: 1; }
.pp-tile__top svg { width: 22px; height: 22px; transition: transform 0.35s var(--ease); }
.pp-tile:hover .pp-tile__top svg { transform: translateX(6px); }
.pp-tile__name { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 800; letter-spacing: -0.035em; line-height: 1; }
.pp-tile__say { font-weight: 300; font-size: clamp(1rem, 1.2vw, 1.12rem); line-height: 1.4; color: var(--mute); max-width: 34ch; }
.pp-tile__st { color: var(--faint); margin-top: 6px; }

/* ---------- narrower: everything stacks, the screens stay a pair ---------- */

@media (max-width: 1099px) {
  .pp-stage { display: block; }
  .pp-about { margin-top: clamp(32px, 5vh, 48px); }
  .pp-about__t { max-width: 58ch; }
  .pp-why { display: block; }
  .pp-why > .pp-k { padding: 0 0 clamp(22px, 3.5vh, 32px); }
}
@media (max-width: 900px) {
  .pp-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
  .pp-head { padding-top: 96px; }
  .pp-panel { border-radius: 20px; }
  .pp-more__grid { grid-template-columns: 1fr; }
  .wcard__chips { gap: 6px; padding: 12px 12px 0; }
  .wcard__chips span { gap: 6px; padding: 6px; font-size: 12.5px; }
  .wcard__chips b { width: 16px; height: 16px; }
  .pp-card:nth-child(1) { margin-right: 0; }
  .pp-card:nth-child(2) { margin-left: 0; }
}
@media (max-width: 360px) {
  .wcard__chips span { padding: 5px 4px; gap: 4px; font-size: 11.5px; }
  .wcard__chips b { width: 14px; height: 14px; font-size: 9.5px; }
}

/* ---------- critic pass (docs/research/2026-09-27-product-pages/F-critic-r2.md) ----------
   neutral panel: a 26% tint read as the rejected band and drowned the app's own accents;
   phones larger and never cropped (a cut screen is never shown) */
.pp-panel { background: var(--bone-2); }
.pp-phones { grid-template-columns: repeat(2, minmax(0, 320px)); }
.pp-head { padding-top: clamp(104px, 14vh, 136px); }
.pp-facts { margin-top: clamp(32px, 5vh, 56px); grid-template-columns: minmax(0, 1fr) minmax(0, 3fr); }
.pp-facts dd { max-width: none; }
/* Crew and Farro icons are renders with air around them, Wavetype's fills its square: same optical size */
.pp-icon[src*="wavetype"] { padding: calc(clamp(56px, 5.8vw, 88px) * 0.14); box-sizing: border-box; }
.pp-tile__top img { width: 72px; }
.pp-tile__top img[src*="wavetype"] { padding: 10px; box-sizing: border-box; }
/* Mori's icon fills its square too */
.pp-icon[src*="icon-mori"] { padding: calc(clamp(56px, 5.8vw, 88px) * 0.14); box-sizing: border-box; }
.pp-tile__top img[src*="icon-mori"] { padding: 10px; box-sizing: border-box; }
.pp-why__body > p:not(.pp-why__sign) { max-width: 31rem; }
.pp-why__body > p:first-of-type { font-size: clamp(1.15rem, 1.45vw, 1.3rem); }
.pp-why__t { max-width: 22ch; }
@media (min-width: 1100px) {
  .pp-about { grid-column: 8 / 13; padding-left: clamp(0px, 2.5vw, 40px); align-self: center; }
  .pp-about__t { max-width: 30rem; }
}
@media (max-width: 1099px) { .pp-about__t { max-width: 34rem; } }
@media (max-width: 480px) {
  .pp-acts { display: grid; grid-template-columns: 1fr 1fr; }
  .pp-acts .pill { justify-content: center; }
  .pp-acts .pill:first-child:not(:only-child) { grid-column: 1 / -1; }
  .pp-acts .pill:only-child { justify-self: start; }
  .pp-facts { grid-template-columns: 1fr; }
}

/* ---------- the film: same grid as the why, label in the margin, the picture wide ---------- */

.pp-film {
  padding: clamp(72px, 12vh, 148px) var(--pad);
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(20px, 2.4vw, 36px);
}
.pp-film > .pp-k { grid-column: 1 / 4; padding-top: 12px; }
.pp-film__v { grid-column: 4 / 13; display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; border-radius: 10px; background: #0D0D0F; }
.pp-film__c { grid-column: 4 / 13; margin: 0; color: var(--mute); }
.pp-film__c a { color: inherit; }
@media (max-width: 1099px) {
  .pp-film { display: block; }
  .pp-film > .pp-k { padding: 0 0 clamp(22px, 3.5vh, 32px); }
  .pp-film__c { padding-top: 14px; }
}
