/* gadi.crtv
   Black and white page; color comes from the work and the inquiry block only. */

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

:root {
  --paper: #F4F4F1;
  --ink: #000000;
  --graphite: #6B6B66;
  --rule: #DADAD5;
  --placeholder: #E4E4DF;  /* empty image slots */
  /* ACCENT: flat yellow (from the inspo, chosen by Gadi). Black on it: 11.4:1. */
  --accent: #F4B33E;

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --narrow: 75%;   /* headlines */
  --semi: 87.5%;   /* the form sentence */

  --gutter: clamp(20px, 5vw, 56px);
  --max: 1320px;
  --space: clamp(72px, 12vw, 160px); /* between sections */
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 16px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.5;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
::selection { background: var(--accent); color: var(--ink); }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

/* ---------- Language switching ----------
   Elements carry data-l="en" or data-l="es"; the root's data-lang decides which show. */
html[data-lang="en"] [data-l="es"],
html[data-lang="es"] [data-l="en"] { display: none !important; }

.vh {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  background: var(--ink); color: var(--paper);
  padding: 10px 16px; border-radius: 999px; text-decoration: none;
}
.skip:focus { top: 12px; }

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

/* ---------- Header ---------- */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 18px;
}

.wordmark {
  font-stretch: var(--narrow);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  line-height: 1;
  text-decoration: none;
}

.nav { display: flex; align-items: center; gap: clamp(14px, 2.5vw, 28px); }
.nav a { text-decoration: none; font-weight: 500; padding-block: 10px; }
.nav a:hover { text-decoration: underline; }
.nav-wide { display: none; }

.lang { display: flex; }
.lang button {
  font: inherit;
  font-weight: 500;
  font-size: 0.9375rem;
  color: var(--graphite);
  background: none;
  border: 0;
  padding: 10px 6px;
  min-width: 36px;
  min-height: 44px;
  cursor: pointer;
}
.lang button[aria-pressed="true"] {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
}

/* ---------- Hero ---------- */
.hero { padding-top: clamp(40px, 9vw, 120px); }

.hero h1 {
  font-stretch: var(--narrow);
  font-weight: 700;
  font-size: clamp(2.5rem, 6.4vw, 5.75rem);
  line-height: 0.96;
  letter-spacing: -0.025em;
  max-width: 15ch;
  text-wrap: balance;
}

.hero-sub {
  margin-top: 20px;
  font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
  color: var(--graphite);
  max-width: 40ch;
}

.text-cta {
  display: inline-block;
  margin-top: 20px;
  font-weight: 600;
  font-size: 1.125rem;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  padding-block: 8px;
}

/* Horizontal strip: thumb-swipe on phones, a row of work on desktop. */
.strip {
  display: flex;
  gap: 10px;
  margin-top: clamp(40px, 7vw, 88px);
  --edge: max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter)));
  padding-inline: var(--edge);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--edge);
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
.strip::-webkit-scrollbar { display: none; }
.strip li {
  flex: none;
  height: clamp(300px, 46vw, 560px);
  scroll-snap-align: start;
}
.strip .tall   { aspect-ratio: 4 / 5; }
.strip .square { aspect-ratio: 1; }
.strip .wide   { aspect-ratio: 3 / 2; }
.strip img, .strip .ph { width: 100%; height: 100%; object-fit: cover; display: block; }

.ph { background: var(--placeholder); width: 100%; height: 100%; }

/* ---------- Sections ---------- */
.section { padding-top: var(--space); }

.section-title {
  font-weight: 500;
  font-size: 1.0625rem;
  color: var(--graphite);
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ink);
}

.rows .row { border-bottom: 1px solid var(--rule); }

.row-name {
  font-stretch: var(--narrow);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
}

/* Services */
.services .row {
  display: grid;
  gap: 8px;
  padding-block: 22px 24px;
}
.services .row-name { font-size: clamp(2.25rem, 5.2vw, 4rem); }
.services .row-desc { max-width: 42ch; }

/* Work */
.work-row {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  grid-template-areas:
    "thumb name year"
    "thumb type year";
  column-gap: 16px;
  align-items: center;
  align-content: center;
  padding-block: 14px;
}
.work-row .thumb { grid-area: thumb; aspect-ratio: 1; overflow: hidden; }
.work-row .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.work-row .row-name { grid-area: name; font-size: clamp(1.5rem, 2.6vw, 2.25rem); align-self: end; }
.work-type { grid-area: type; color: var(--graphite); align-self: start; padding-top: 4px; }
.work-year { grid-area: year; color: var(--graphite); font-variant-numeric: tabular-nums; }
.is-placeholder .row-name { color: var(--graphite); }

/* About */
.about-body { display: grid; gap: 28px; padding-top: 28px; }
.portrait { aspect-ratio: 4 / 5; width: min(100%, 280px); }
.portrait img { width: 100%; height: 100%; object-fit: cover; display: block; }
.about-text { display: grid; gap: 1em; max-width: 34em; font-size: clamp(1.125rem, 1.6vw, 1.375rem); line-height: 1.45; }

/* ---------- Inquiry ---------- */
.inquire {
  margin-top: var(--space);
  background: var(--accent);
  padding-block: clamp(56px, 9vw, 128px);
}

.inquire-title {
  font-stretch: var(--narrow);
  font-weight: 700;
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 0.96;
  letter-spacing: -0.025em;
  margin-bottom: clamp(28px, 4vw, 48px);
}

.sentence-text {
  font-stretch: var(--semi);
  font-weight: 500;
  font-size: clamp(1.5rem, 3.4vw, 2.75rem);
  line-height: 1.6;
  letter-spacing: -0.01em;
  max-width: 30em;
}

/* Blanks: a solid black underline and an in-field hint, so they read as inputs, never as links. */
.blank {
  font: inherit;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 2px solid var(--ink);
  border-radius: 0;
  padding: 0 0.12em;
  margin: 0 0 0 0.12em;
  min-width: 4ch;
  max-width: 100%;
  vertical-align: baseline;
  line-height: 1.2;
  field-sizing: content;
  -webkit-appearance: none;
  appearance: none;
  transition: background-color 120ms ease;
}
.blank::placeholder { color: color-mix(in srgb, var(--accent), #000 60%); opacity: 1; }
.blank:focus { outline: none; background: rgba(255, 255, 255, 0.45); border-bottom-width: 3px; }
.blank:focus-visible { outline: none; }
.blank[aria-invalid="true"] { border-bottom-style: dashed; }

.select-wrap { position: relative; display: inline-block; max-width: 100%; }
.select-wrap select { padding-right: 1.1em; cursor: pointer; }
.select-wrap::after {
  content: "";
  position: absolute;
  right: 0.3em;
  top: 50%;
  width: 0.28em; height: 0.28em;
  border-right: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  transform: translateY(-60%) rotate(45deg);
  pointer-events: none;
}
.select-wrap select:invalid { color: color-mix(in srgb, var(--accent), #000 60%); }
.select-wrap option { color: var(--ink); background: var(--paper); }

.sentence-extra {
  display: grid;
  gap: 4px;
  margin-top: clamp(24px, 3vw, 36px);
  max-width: 34em;
}
.sentence-extra label { font-weight: 500; }
.blank-small {
  font-size: 1.0625rem;
  margin: 0;
  padding-block: 6px;
  width: 100%;
  field-sizing: fixed;
}

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.form-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 24px;
  margin-top: clamp(28px, 4vw, 44px);
}

.pill {
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  color: var(--paper);
  background: var(--ink);
  border: 0;
  border-radius: 999px;
  padding: 12px 22px;
  min-height: 44px;
  cursor: pointer;
}
.pill:hover { background: #262626; }
.pill:disabled { cursor: progress; opacity: 0.7; }

.direct { font-size: 0.9375rem; }

.form-error { margin-top: 20px; font-weight: 500; max-width: 40em; }
.form-error:empty { display: none; }

.turnstile:empty { display: none; }
.turnstile { margin-top: 16px; }

.sent:focus { outline: none; }

/* ---------- Footer ---------- */
.foot {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 24px;
  padding-block: 28px 36px;
  font-size: 0.9375rem;
}
.foot a { padding-block: 8px; }
.wordmark-small { font-size: 1.125rem; }
.foot-year { color: var(--graphite); margin-left: auto; }

/* ---------- Wider screens ---------- */
@media (min-width: 720px) {
  .nav-wide { display: inline; }

  .services .row {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    align-items: baseline;
    gap: 32px;
    padding-block: 28px 30px;
  }
  .services .row-desc { font-size: 1.125rem; }

  .work-row {
    grid-template-columns: 160px minmax(0, 1.4fr) minmax(0, 1fr) auto;
    grid-template-areas: "thumb name type year";
    column-gap: 32px;
    padding-block: 18px;
  }
  .work-row .thumb { aspect-ratio: 4 / 3; }
  .work-row .row-name, .work-type { align-self: center; padding-top: 0; }

  .about-body { grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: 48px; align-items: end; }
  .portrait { width: 100%; }
  .hero h1 { max-width: 17ch; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
