/* Plomberie DX - design system
   Type: Archivo variable (wght 100-900, wdth 62-125), self-hosted.
   Radius rule: every surface, image, button, input and chip uses --r (6px). Nothing else.
   Accent rule: brand yellow #ffec53 is only ever a FILL or an underline, never text on a light ground.
   z-index scale: header 40, lightbox 60, skip-link 70. */

@font-face {
  font-family: "Archivo";
  src: url("/assets/fonts/archivo-latin-standard-normal.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Archivo";
  src: url("/assets/fonts/archivo-latin-standard-italic.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: italic;
  font-display: swap;
}

:root {
  --bg: #f3f3f1;
  --bg-2: #e9e9e6;
  --surface: #fbfbfa;
  --ink: #1b1817;
  --ink-2: #3a3634;
  --muted: #5d5855;
  --line: rgb(31 24 24 / 0.12);
  --line-strong: rgb(31 24 24 / 0.22);
  --accent: #ffec53;
  --accent-ink: #1f1818;
  --accent-soft: rgb(255 236 83 / 0.28);
  --night: #1f1818;
  --night-2: #2a2322;
  --night-ink: #f1eee8;
  --night-muted: #b5aea8;
  --shadow: 0 1px 0 rgb(31 24 24 / 0.04), 0 18px 40px -24px rgb(31 24 24 / 0.35);
  --r: 6px;
  --wrap: 1320px;
  --gutter: clamp(16px, 4vw, 40px);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --header-h: 72px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131110;
    --bg-2: #1b1817;
    --surface: #1d1a19;
    --ink: #f1eee8;
    --ink-2: #d9d4ce;
    --muted: #a9a29c;
    --line: rgb(255 255 255 / 0.1);
    --line-strong: rgb(255 255 255 / 0.2);
    --accent-soft: rgb(255 236 83 / 0.16);
    --night: #0d0b0b;
    --night-2: #181514;
    --shadow: 0 1px 0 rgb(0 0 0 / 0.3), 0 18px 40px -24px rgb(0 0 0 / 0.8);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.6;
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--accent); color: var(--accent-ink); }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

.skip { position: absolute; left: 12px; top: -60px; z-index: 70; background: var(--accent); color: var(--accent-ink); padding: 10px 14px; border-radius: var(--r); font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- Type ---------- */
.display, h1, h2, h3 { font-stretch: 118%; letter-spacing: -0.022em; line-height: 1.04; margin: 0; font-weight: 750; text-wrap: balance; }
h1 { font-size: clamp(2.35rem, 1.4rem + 3.6vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 1.3rem + 2.2vw, 3.1rem); }
h3 { font-size: clamp(1.2rem, 1.05rem + 0.5vw, 1.45rem); letter-spacing: -0.012em; line-height: 1.15; }
p { margin: 0; text-wrap: pretty; }
.lead { font-size: clamp(1.06rem, 1rem + 0.3vw, 1.22rem); color: var(--muted); max-width: 58ch; line-height: 1.55; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); font-stretch: 112%; }
.eyebrow::before { content: ""; width: 22px; height: 3px; background: var(--accent); border-radius: 2px; }
.mark { background: linear-gradient(transparent 62%, var(--accent) 62%, var(--accent) 92%, transparent 92%); padding-inline: 0.06em; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
@media (prefers-color-scheme: dark) { .mark { background: none; color: var(--accent); } }
.num { font-variant-numeric: tabular-nums; }

/* ---------- Buttons & links ---------- */
.btn {
  --btn-bg: var(--accent); --btn-ink: var(--accent-ink);
  display: inline-flex; align-items: center; gap: 10px; white-space: nowrap;
  min-height: 48px; padding: 0 20px; border-radius: var(--r);
  background: var(--btn-bg); color: var(--btn-ink);
  font-weight: 650; font-size: 0.98rem; font-stretch: 108%; text-decoration: none;
  border: 1px solid transparent; cursor: pointer;
  transition: transform 0.25s var(--ease), background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.btn svg { width: 18px; height: 18px; flex: none; transition: transform 0.3s var(--ease); }
.btn:hover { box-shadow: 0 10px 24px -14px rgb(31 24 24 / 0.55); }
.btn:hover svg.arrow { transform: translateX(3px); }
.btn:active { transform: translateY(1px) scale(0.985); }
.btn--ghost { --btn-bg: transparent; --btn-ink: var(--ink); border-color: var(--line-strong); }
.btn--ghost:hover { --btn-bg: var(--surface); box-shadow: none; }
.btn--night { --btn-bg: var(--night); --btn-ink: var(--night-ink); }
@media (prefers-color-scheme: dark) { .btn--night { --btn-bg: var(--accent); --btn-ink: var(--accent-ink); } }

.link { font-weight: 600; text-decoration: none; background: linear-gradient(var(--accent), var(--accent)) 0 100% / 100% 3px no-repeat; padding-bottom: 2px; transition: background-size 0.3s var(--ease); display: inline-flex; align-items: center; gap: 8px; width: fit-content; justify-self: start; }
.link svg { width: 16px; height: 16px; transition: transform 0.3s var(--ease); }
.link:hover svg { transform: translateX(3px); }

/* ---------- Header ---------- */
.header { position: sticky; top: 0; z-index: 40; height: var(--header-h); background: var(--night); color: var(--night-ink); border-bottom: 3px solid var(--accent); }
.header__in { height: 100%; display: flex; align-items: center; gap: 28px; }
.header__logo { display: block; flex: none; }
.header__logo img { height: 34px; width: auto; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a { position: relative; padding: 8px 12px; border-radius: var(--r); font-size: 0.95rem; font-weight: 550; font-stretch: 106%; text-decoration: none; color: var(--night-muted); transition: color 0.2s; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--night-ink); }
.nav a[aria-current="page"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 0; height: 2px; background: var(--accent); }
.header__tools { display: flex; align-items: center; gap: 10px; }
.lang { display: inline-grid; place-items: center; min-width: 44px; height: 40px; border: 1px solid rgb(255 255 255 / 0.22); border-radius: var(--r); font-size: 0.85rem; font-weight: 650; letter-spacing: 0.06em; text-decoration: none; color: var(--night-ink); transition: border-color 0.2s, background-color 0.2s; }
.lang:hover { border-color: var(--accent); background: rgb(255 236 83 / 0.08); }
.header .btn { min-height: 40px; padding: 0 14px; font-size: 0.92rem; }
.menu-btn { display: none; width: 44px; height: 44px; place-items: center; background: transparent; border: 1px solid rgb(255 255 255 / 0.22); border-radius: var(--r); cursor: pointer; color: var(--night-ink); }
.menu-btn svg { width: 22px; height: 22px; }

.drawer { display: none; }
@media (max-width: 960px) {
  .nav, .header__tools .btn { display: none; }
  .header__tools { margin-left: auto; }
  .menu-btn { display: grid; }
  .drawer { display: block; position: fixed; inset: var(--header-h) 0 0 0; z-index: 39; background: var(--night); color: var(--night-ink); padding: 28px var(--gutter) 40px; transform: translateY(-8px); opacity: 0; visibility: hidden; transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0s linear 0.3s; overflow-y: auto; }
  .drawer[data-open="true"] { opacity: 1; transform: none; visibility: visible; transition-delay: 0s; }
  .drawer nav { display: grid; gap: 2px; }
  .drawer nav a { font-size: 1.8rem; font-weight: 700; font-stretch: 115%; letter-spacing: -0.02em; text-decoration: none; padding: 10px 0; border-bottom: 1px solid rgb(255 255 255 / 0.08); }
  .drawer nav a[aria-current="page"] { color: var(--accent); }
  .drawer .btn { margin-top: 28px; width: 100%; justify-content: center; }
  .drawer__meta { margin-top: 28px; color: var(--night-muted); font-size: 0.95rem; display: grid; gap: 6px; }
}

/* ---------- Hero ---------- */
.hero { padding: clamp(28px, 4vw, 56px) 0 clamp(40px, 5vw, 72px); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); gap: clamp(28px, 4vw, 64px); align-items: center; min-height: min(calc(100dvh - var(--header-h) - 96px), 720px); }
.hero__copy { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; align-content: center; }
.hero__copy h1 { font-size: clamp(2.3rem, 1.3rem + 2.9vw, 3.75rem); font-stretch: 110%; overflow-wrap: break-word; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.hero__media { position: relative; aspect-ratio: 1 / 1.04; border-radius: var(--r); overflow: hidden; background: var(--bg-2); box-shadow: var(--shadow); }
.hero__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s var(--ease); }
.hero__media img.is-on { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .hero__media img { transform: scale(1.05); transition: opacity 1.2s var(--ease), transform 6.5s linear; }
  .hero__media img.is-on { transform: scale(1); }
}
.hero__dots { position: absolute; left: 16px; bottom: 16px; display: flex; gap: 6px; padding: 8px 10px; border-radius: var(--r); background: rgb(20 17 16 / 0.55); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.hero__dots button { width: 22px; height: 4px; padding: 0; border: 0; border-radius: 2px; background: rgb(255 255 255 / 0.35); cursor: pointer; transition: background-color 0.3s, width 0.3s var(--ease); }
.hero__dots button[aria-current="true"] { background: var(--accent); width: 34px; }
.hero__dots button::before { content: ""; display: block; height: 24px; margin-top: -10px; }
@media (max-width: 960px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .hero__media { aspect-ratio: 16 / 10; order: -1; }
}

/* ---------- Proof strip ---------- */
.proof { border-block: 1px solid var(--line); background: var(--surface); }
.proof__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.proof__item { padding: 28px clamp(16px, 2.4vw, 32px); display: grid; gap: 4px; align-content: start; }
.proof__item + .proof__item { border-left: 1px solid var(--line); }
.proof__big { font-size: clamp(2rem, 1.5rem + 1.6vw, 2.9rem); font-weight: 800; font-stretch: 120%; letter-spacing: -0.03em; line-height: 1; }
.proof__mid { font-size: 1.15rem; font-weight: 700; font-stretch: 112%; line-height: 1.2; padding-top: 6px; }
.proof__label { color: var(--muted); font-size: 0.95rem; }
.proof__cmmtq { height: 30px; width: auto; filter: invert(1); opacity: 0.85; margin-top: 4px; }
@media (prefers-color-scheme: dark) { .proof__cmmtq { filter: none; } }
@media (max-width: 860px) {
  .proof__grid { grid-template-columns: 1fr 1fr; }
  .proof__item:nth-child(3) { border-left: 0; }
  .proof__item:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 8vw, 120px); }
.section--tight { padding-block: clamp(48px, 6vw, 88px); }
.section__head { display: grid; gap: 16px; margin-bottom: clamp(32px, 4vw, 56px); max-width: 760px; }

/* Trades row */
.trades { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--line-strong); }
.trade { padding: 26px 22px 30px 0; display: grid; gap: 18px; align-content: start; }
.trade + .trade { padding-left: 22px; border-left: 1px solid var(--line); }
.trade__icon { width: 52px; height: 52px; display: grid; place-items: center; border-radius: var(--r); background: var(--accent); color: var(--accent-ink); }
.trade__icon svg { width: 26px; height: 26px; }
.trade h3 { font-size: 1.12rem; }
.trade p { color: var(--muted); font-size: 0.95rem; line-height: 1.5; }
@media (max-width: 1000px) {
  .trades { grid-template-columns: 1fr 1fr; }
  .trade, .trade + .trade { padding: 22px 16px 24px 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .trade:nth-child(even) { padding-left: 16px; border-left: 1px solid var(--line); }
}
@media (max-width: 520px) {
  .trades { grid-template-columns: 1fr; }
  .trade:nth-child(even) { padding-left: 0; border-left: 0; }
  .trade { grid-template-columns: 52px 1fr; column-gap: 16px; row-gap: 4px; }
  .trade__icon { grid-row: span 2; }
}

/* Bento of featured projects (5 items -> 5 cells) */
.bento { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: clamp(150px, 15vw, 210px); gap: 14px; }
.tile { position: relative; overflow: hidden; border-radius: var(--r); background: var(--night); color: #f6f3ee; text-decoration: none; isolation: isolate; }
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 0.9s var(--ease); }
.tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgb(15 12 11 / 0) 40%, rgb(15 12 11 / 0.82) 100%); }
.tile__body { position: absolute; left: 0; right: 0; bottom: 0; padding: clamp(16px, 2vw, 24px); display: grid; gap: 4px; }
.tile__title { font-weight: 700; font-stretch: 114%; font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.4rem); letter-spacing: -0.015em; line-height: 1.15; }
.tile__meta { font-size: 0.88rem; color: rgb(246 243 238 / 0.78); }
.tile:hover img { transform: scale(1.045); }
.tile--a { grid-column: span 4; grid-row: span 2; }
.tile--b { grid-column: span 2; grid-row: span 2; }
.tile--c, .tile--d, .tile--e { grid-column: span 2; grid-row: span 1; }
.tile--more { background: var(--accent); color: var(--accent-ink); display: grid; align-content: space-between; padding: clamp(16px, 2vw, 24px); }
.tile--more::after { display: none; }
.tile--more .tile__title { font-size: clamp(1.15rem, 1rem + 0.6vw, 1.6rem); }
.tile--more svg { width: 28px; height: 28px; transition: transform 0.35s var(--ease); }
.tile--more:hover svg { transform: translateX(6px); }
@media (max-width: 860px) {
  .bento { grid-template-columns: 1fr 1fr; grid-auto-rows: 180px; }
  .tile--a { grid-column: span 2; grid-row: span 2; }
  .tile--b { grid-column: span 1; grid-row: span 2; }
  .tile--c, .tile--d, .tile--e { grid-column: span 1; }
  .tile--e { grid-column: span 2; }
}
@media (max-width: 560px) {
  .bento { grid-template-columns: 1fr; grid-auto-rows: 210px; }
  .tile--a, .tile--b, .tile--c, .tile--d, .tile--e { grid-column: auto; grid-row: auto; }
  .tile--a { grid-row: span 1; height: 260px; }
  .tile--e { height: 150px; }
}

/* Sectors split */
.sectors { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2vw, 24px); }
.sector { display: grid; grid-template-rows: auto 1fr; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.sector__img { aspect-ratio: 16 / 8; overflow: hidden; }
.sector__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.sector:hover .sector__img img { transform: scale(1.03); }
.sector__body { padding: clamp(22px, 2.6vw, 36px); display: grid; gap: 14px; align-content: start; }
.sector__body > p { color: var(--muted); }
.chips { list-style: none; margin: 6px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.chips li { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: var(--r); background: var(--bg); font-size: 0.93rem; line-height: 1.3; font-weight: 500; }
.chips svg { width: 20px; height: 20px; flex: none; color: var(--ink-2); }
@media (max-width: 860px) { .sectors { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .chips { grid-template-columns: 1fr; } }

/* Story / timeline */
.story { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.story__img { position: relative; border-radius: var(--r); overflow: hidden; aspect-ratio: 5 / 6; box-shadow: var(--shadow); }
.story__img img { width: 100%; height: 100%; object-fit: cover; }
.timeline { list-style: none; margin: 28px 0 32px; padding: 0; display: grid; gap: 0; }
.timeline li { display: grid; grid-template-columns: 96px 1fr; gap: 20px; padding: 18px 0; border-top: 1px solid var(--line); }
.timeline li:last-child { border-bottom: 1px solid var(--line); }
.timeline__year { font-weight: 800; font-stretch: 120%; font-size: 1.5rem; letter-spacing: -0.02em; line-height: 1.1; }
.timeline p { color: var(--muted); }
.timeline strong { color: var(--ink); font-weight: 650; display: block; margin-bottom: 2px; }
@media (max-width: 860px) { .story { grid-template-columns: 1fr; } .story__img { aspect-ratio: 4 / 3; } }

/* Contact block */
.contact { background: var(--night); color: var(--night-ink); border-radius: var(--r); overflow: hidden; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.contact__main { padding: clamp(28px, 4.5vw, 64px); display: grid; gap: 22px; align-content: start; }
.contact__main .lead { color: var(--night-muted); }
.contact__phone { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.6rem); font-weight: 800; font-stretch: 118%; letter-spacing: -0.03em; line-height: 1; text-decoration: none; color: var(--accent); width: fit-content; }
.contact__phone:hover { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; }
.contact__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.contact .btn--ghost { --btn-ink: var(--night-ink); border-color: rgb(255 255 255 / 0.24); }
.contact .btn--ghost:hover { --btn-bg: rgb(255 255 255 / 0.06); }
.contact__side { background: var(--night-2); padding: clamp(28px, 4.5vw, 64px); display: grid; gap: 26px; align-content: start; }
.contact__row { display: grid; grid-template-columns: 24px 1fr; gap: 14px; }
.contact__row svg { width: 22px; height: 22px; color: var(--accent); margin-top: 2px; }
.contact__row h3 { font-size: 0.8rem; font-weight: 650; letter-spacing: 0.12em; text-transform: uppercase; font-stretch: 110%; color: var(--night-muted); margin-bottom: 4px; }
.contact__row a, .contact__row p { color: var(--night-ink); text-decoration: none; display: block; line-height: 1.5; }
.contact__row a:hover { color: var(--accent); }
.contact__row small { color: var(--night-muted); font-size: 0.88rem; display: block; }
.contact__side .contact__phone { font-size: clamp(1.7rem, 1.2rem + 1.4vw, 2.4rem); }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; } }

/* Quote form (on the dark contact block) */
.qform { display: grid; gap: 20px; margin-top: 6px; }
.qform__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.field { display: grid; gap: 7px; align-content: start; }
.field--wide { grid-column: 1 / -1; }
.field label { font-size: 0.92rem; font-weight: 600; color: var(--night-ink); }
.req { color: var(--accent); margin-left: 3px; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 12px 14px; border-radius: var(--r);
  border: 1px solid rgb(255 255 255 / 0.22); background: rgb(255 255 255 / 0.06); color: var(--night-ink);
  font: inherit; font-size: 1rem; transition: border-color 0.2s, background-color 0.2s;
}
.field textarea { resize: vertical; min-height: 132px; line-height: 1.5; }
.field select { appearance: none; padding-right: 40px; background-image: linear-gradient(45deg, transparent 50%, var(--night-ink) 50%), linear-gradient(135deg, var(--night-ink) 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
.field select option { color: #1b1817; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: rgb(255 255 255 / 0.38); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); background-color: rgb(255 255 255 / 0.09); box-shadow: 0 0 0 3px rgb(255 236 83 / 0.25); }
.field input[type="file"] { padding: 9px; cursor: pointer; color: var(--night-muted); }
.field input[type="file"]::file-selector-button { margin-right: 12px; padding: 8px 14px; border: 0; border-radius: var(--r); background: var(--night-ink); color: var(--night); font: inherit; font-weight: 600; font-size: 0.9rem; cursor: pointer; }
.field__help { font-size: 0.86rem; color: var(--night-muted); line-height: 1.45; }
.field__err { font-size: 0.88rem; font-weight: 600; color: #ffb4a6; }
.field [aria-invalid="true"] { border-color: #ff8f7d; }
.qform__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.qform__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; }
.qform__privacy { font-size: 0.86rem; color: var(--night-muted); max-width: 40ch; }
.qform__error { padding: 12px 14px; border-radius: var(--r); background: rgb(255 143 125 / 0.12); border: 1px solid rgb(255 143 125 / 0.45); color: #ffd3cb; font-size: 0.95rem; }
.qform .btn[disabled] { opacity: 0.7; cursor: progress; }
.qform__ok { display: grid; grid-template-columns: 32px 1fr; gap: 14px; padding: 22px; border-radius: var(--r); background: rgb(255 236 83 / 0.1); border: 1px solid rgb(255 236 83 / 0.4); outline: none; }
.qform__ok svg { width: 30px; height: 30px; color: var(--accent); }
.qform__ok h3 { font-size: 1.25rem; color: var(--night-ink); margin-bottom: 4px; }
.qform__ok p { color: var(--night-muted); }
@media (max-width: 560px) { .qform__grid { grid-template-columns: 1fr; } }

/* ---------- Page header (inner pages) ---------- */
.phead { padding: clamp(40px, 6vw, 88px) 0 clamp(32px, 4vw, 56px); }
.phead__grid { display: grid; gap: 20px; max-width: 900px; }
.phead h1 { font-size: clamp(2.4rem, 1.5rem + 3.4vw, 4.4rem); }
.crumbs { display: flex; gap: 8px; font-size: 0.88rem; color: var(--muted); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--ink); }

/* About */
.about { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.about__aside { position: sticky; top: calc(var(--header-h) + 32px); display: grid; gap: 0; }
.about__aside .timeline { margin: 0; }
.about__aside .timeline li { grid-template-columns: 64px 1fr; gap: 16px; }
.about__aside .timeline__year { font-size: 1.25rem; }
.prose { display: grid; gap: 1.4em; font-size: clamp(1.06rem, 1rem + 0.25vw, 1.2rem); line-height: 1.7; max-width: 66ch; color: var(--ink-2); }
.prose p:first-child { font-size: 1.18em; color: var(--ink); line-height: 1.55; font-weight: 450; }
.about__photo { margin-top: clamp(48px, 6vw, 80px); display: grid; grid-template-columns: 1.4fr 1fr; grid-auto-rows: clamp(260px, 34vw, 480px); gap: 14px; }
.about__photo figure { margin: 0; border-radius: var(--r); overflow: hidden; }
.about__photo img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px) { .about { grid-template-columns: 1fr; } .about__aside { position: static; } .about__photo { grid-template-columns: 1fr; grid-auto-rows: auto; } .about__photo figure { aspect-ratio: 4 / 3; } }

.team { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2vw, 24px); }
.person { padding: clamp(24px, 3vw, 40px); border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); display: grid; gap: 6px; align-content: start; }
.person__role { color: var(--muted); }
.person__name { font-size: clamp(1.5rem, 1.2rem + 1vw, 2.1rem); font-weight: 750; font-stretch: 118%; letter-spacing: -0.02em; line-height: 1.1; }
.person .link { margin-top: 18px; width: fit-content; }
@media (max-width: 700px) { .team { grid-template-columns: 1fr; } }

.creds { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2vw, 24px); }
.cred { display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: center; padding: clamp(22px, 3vw, 34px); border-radius: var(--r); border: 1px solid var(--line); }
.cred__badge { width: 132px; height: 64px; display: grid; place-items: center; border-radius: var(--r); background: var(--night); color: var(--accent); font-weight: 800; font-stretch: 122%; font-size: 1.35rem; letter-spacing: 0.02em; }
.cred__badge img { height: 34px; width: auto; }
.cred h3 { font-size: 1.1rem; margin-bottom: 4px; }
.cred p { color: var(--muted); font-size: 0.95rem; }
@media (max-width: 760px) { .creds { grid-template-columns: 1fr; } .cred { grid-template-columns: 1fr; } }

/* Services page */
.svc { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-block: clamp(40px, 5vw, 72px); }
.svc + .svc { border-top: 1px solid var(--line); }
.svc--flip .svc__media { order: 2; }
.svc__media { border-radius: var(--r); overflow: hidden; aspect-ratio: 5 / 4; box-shadow: var(--shadow); }
.svc__media img { width: 100%; height: 100%; object-fit: cover; }
.svc__body { display: grid; gap: 16px; }
.svc__body > p { color: var(--muted); max-width: 52ch; }
.svc__proof { font-size: 0.93rem; color: var(--muted); }
@media (max-width: 860px) { .svc { grid-template-columns: 1fr; } .svc--flip .svc__media { order: 0; } }

/* Projects page */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.filter { min-height: 42px; padding: 0 16px; border-radius: var(--r); border: 1px solid var(--line-strong); background: transparent; cursor: pointer; font-weight: 600; font-size: 0.93rem; display: inline-flex; align-items: center; gap: 8px; transition: background-color 0.2s, border-color 0.2s, color 0.2s; }
.filter span { color: var(--muted); font-variant-numeric: tabular-nums; font-weight: 500; }
.filter:hover { border-color: var(--ink); }
.filter[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.filter[aria-pressed="true"] span { color: inherit; opacity: 0.7; }

.pgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 2.4vw, 32px) clamp(16px, 2vw, 24px); }
.pcard { display: grid; gap: 14px; align-content: start; text-align: left; background: none; border: 0; padding: 0; cursor: pointer; }
.pcard[hidden] { display: none; }
.pcard__media { position: relative; overflow: hidden; border-radius: var(--r); aspect-ratio: 4 / 3; background: var(--bg-2); }
.pcard__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.pcard:hover .pcard__media img { transform: scale(1.04); }
.pcard__count { position: absolute; right: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: var(--r); background: rgb(20 17 16 / 0.62); color: #f6f3ee; font-size: 0.82rem; font-weight: 600; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.pcard__count svg { width: 15px; height: 15px; }
.pcard__title { font-size: 1.22rem; font-weight: 700; font-stretch: 114%; letter-spacing: -0.015em; line-height: 1.2; }
.pcard__desc { color: var(--muted); font-size: 0.97rem; line-height: 1.55; }
.pcard__sector { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.pcard--wide { grid-column: span 2; }
.pcard--wide .pcard__media { aspect-ratio: 16 / 8.4; }
@media (max-width: 1000px) { .pgrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .pgrid { grid-template-columns: 1fr; } .pcard--wide { grid-column: auto; } .pcard--wide .pcard__media { aspect-ratio: 4 / 3; } }

/* Lightbox */
.lb { position: fixed; inset: 0; z-index: 60; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgb(12 10 10 / 0.94); color: #f6f3ee; }
.lb::backdrop { background: transparent; }
.lb[open] { display: grid; grid-template-rows: auto 1fr auto; }
@media (prefers-reduced-motion: no-preference) { .lb[open] { animation: lb-in 0.35s var(--ease); } }
@keyframes lb-in { from { opacity: 0; } to { opacity: 1; } }
.lb__top { display: flex; align-items: center; gap: 16px; padding: 14px var(--gutter); }
.lb__title { font-weight: 700; font-stretch: 112%; }
.lb__count { color: rgb(246 243 238 / 0.65); font-variant-numeric: tabular-nums; margin-left: auto; }
.lb__stage { position: relative; display: grid; place-items: center; min-height: 0; padding: 0 clamp(8px, 6vw, 96px); touch-action: pan-y; }
.lb__stage img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: var(--r); user-select: none; -webkit-user-drag: none; }
@media (prefers-reduced-motion: no-preference) { .lb__stage img.is-enter { animation: lb-img 0.4s var(--ease); } }
@keyframes lb-img { from { opacity: 0; transform: scale(0.985); } to { opacity: 1; transform: none; } }
.lb__btn { width: 48px; height: 48px; display: grid; place-items: center; border-radius: var(--r); border: 1px solid rgb(255 255 255 / 0.18); background: rgb(255 255 255 / 0.06); color: #f6f3ee; cursor: pointer; transition: background-color 0.2s, border-color 0.2s; }
.lb__btn:hover { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.lb__btn svg { width: 22px; height: 22px; }
.lb__prev, .lb__next { position: absolute; top: 50%; transform: translateY(-50%); }
.lb__prev { left: var(--gutter); } .lb__next { right: var(--gutter); }
.lb__thumbs { display: flex; gap: 8px; justify-content: center; padding: 14px var(--gutter) 18px; overflow-x: auto; }
.lb__thumbs button { flex: none; width: 64px; height: 48px; padding: 0; border: 2px solid transparent; border-radius: var(--r); overflow: hidden; cursor: pointer; opacity: 0.55; background: none; transition: opacity 0.2s, border-color 0.2s; }
.lb__thumbs button[aria-current="true"] { opacity: 1; border-color: var(--accent); }
.lb__thumbs img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 640px) { .lb__prev, .lb__next { top: auto; bottom: 8px; transform: none; } .lb__stage { padding-bottom: 64px; } }

/* CTA band (inner pages) */
.cta { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 48px; align-items: center; padding: clamp(28px, 4vw, 52px); border-radius: var(--r); background: var(--accent); color: var(--accent-ink); }
.cta h2 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.5rem); max-width: 22ch; }
.cta p { margin-top: 10px; max-width: 52ch; opacity: 0.82; }
.cta__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.cta .btn--night { --btn-bg: var(--accent-ink); --btn-ink: var(--accent); }
.cta .btn--ghost { --btn-ink: var(--accent-ink); border-color: rgb(31 24 24 / 0.35); }
.cta .btn--ghost:hover { --btn-bg: rgb(31 24 24 / 0.06); }
@media (max-width: 860px) { .cta { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.footer { margin-top: clamp(64px, 8vw, 120px); background: var(--night); color: var(--night-muted); padding: clamp(48px, 6vw, 80px) 0 28px; font-size: 0.95rem; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; }
.footer__brand img { height: 36px; width: auto; }
.footer__brand p { margin-top: 18px; max-width: 34ch; }
.footer h2 { font-size: 0.8rem; font-weight: 650; letter-spacing: 0.12em; text-transform: uppercase; font-stretch: 110%; color: var(--accent); margin-bottom: 14px; line-height: 1.4; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer a { color: var(--night-ink); text-decoration: none; }
.footer a:hover { color: var(--accent); }
.footer__creds { display: flex; align-items: center; gap: 18px; margin-top: 22px; flex-wrap: wrap; }
.footer__creds img { height: 34px; width: auto; }
.footer__rbq { color: var(--night-ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.footer__base { margin-top: 48px; padding-top: 22px; border-top: 1px solid rgb(255 255 255 / 0.1); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 0.88rem; }
@media (max-width: 960px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer__grid { grid-template-columns: 1fr; } }

/* ---------- Reveal on scroll ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); transition-delay: calc(var(--i, 0) * 70ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
  .js .hero__copy > * { animation: rise 0.9s var(--ease) both; animation-delay: calc(var(--i, 0) * 90ms + 80ms); }
  .js .hero__media { animation: fade 1.1s var(--ease) both 0.15s; }
}
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; transform: scale(0.985); } to { opacity: 1; transform: none; } }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
