/* ------------------------------------------------------------------
   Design tokens
------------------------------------------------------------------ */
:root {
  --ink: rgb(15, 17, 17);
  --ink-soft: rgba(15, 17, 17, 0.6);
  --paper: #ffffff;
  --accent: rgb(0, 71, 204);
  --accent-wash: rgb(224, 234, 255);
  --sticker: #f3c04b;
  --line: rgba(15, 17, 17, 0.14);
  --ph-bg: #f1f1f0;
  --ph-stripe: rgba(15, 17, 17, 0.05);

  --serif: "Crimson Pro", "Times New Roman", serif;
  --sans: "Plus Jakarta Sans", "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --pixel: "VT323", monospace;

  --gutter: clamp(20px, 6.7vw, 96px);
  --measure: 620px;
  --radius: 16px;
  --radius-pill: 999px;

  --space-hero: 150px;
  --space-section: 150px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.02em;
  -webkit-font-smoothing: antialiased;
}

h1, h2, p, ol { margin: 0; }
ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
em { font-style: italic; }

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

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  padding: 8px 12px;
  background: var(--ink);
  color: #fff;
  border-radius: 8px;
}
.skip-link:focus { left: 8px; z-index: 100; }

/* ------------------------------------------------------------------
   Header
------------------------------------------------------------------ */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  pointer-events: none;
}
.site-header__inner {
  margin-inline: auto;
  padding: 44px var(--gutter) 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.site-header__inner > * { pointer-events: auto; }

.wordmark {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 24px;
  letter-spacing: -0.04em;
  line-height: 40px;
  padding: 0 2px;
  background: var(--paper);
  border-radius: 6px;
}

.btn {
  display: inline-flex;
  align-items: center;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 1;
  padding: 14px 22px;
  border-radius: var(--radius-pill);
  transition: transform 0.2s ease, background 0.2s ease;
}
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { transform: translateY(-1px); background: #000; }

/* ------------------------------------------------------------------
   Hero
------------------------------------------------------------------ */
.hero { padding-top: var(--space-hero); }

.hero__eyebrow {
  margin-bottom: 28px;
  font-family: var(--mono);
  font-weight: 400;
  font-size: 13px;
  letter-spacing: -0.02em;
  color: var(--ink-soft);
}

.hero__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 48px;
  line-height: 1.09;
  letter-spacing: -0.05em;
  max-width: var(--measure);
}
.hero__line { display: block; }
.hero__highlight {
  background: var(--accent-wash);
  color: var(--accent);
  padding: 0 0.06em;
  border-radius: 4px;
}
.hero__em { font-style: italic; }
.hero__icon {
  width: 0.52em;
  height: 0.52em;
  vertical-align: 0.02em;
  margin: 0 0.04em;
}

.hero__sub {
  margin-top: 44px;
  max-width: 560px;
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.02em;
}

/* ------------------------------------------------------------------
   Project highlights
------------------------------------------------------------------ */
.work { padding-top: 88px; }

.pill-label {
  display: inline-block;
  font-family: var(--serif);
  font-weight: 300;
  font-size: 24px;
  line-height: 1.09;
  letter-spacing: -0.05em;
  padding: 12px 20px;
  border: 1px solid var(--ink);
  border-radius: var(--radius-pill);
}

.tiles {
  margin-top: 36px;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 12px;
}
.tile {
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.35s ease;
}
.tile:hover { transform: translateY(-3px); }
.tile--narrow .tile__media { aspect-ratio: 234 / 390; }
.tile--wide .tile__media { aspect-ratio: 476 / 390; }
.tile__media { width: 100%; }

/* ------------------------------------------------------------------
   Placeholder surfaces
------------------------------------------------------------------ */
.tile__media,
.gallery__item {
  position: relative;
  background-color: var(--ph-bg);
  background-image: repeating-linear-gradient(
    -45deg,
    transparent 0 14px,
    var(--ph-stripe) 14px 15px
  );
  border-radius: var(--radius);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.tile__media > img, .tile__media > video,
.gallery__item > img, .gallery__item > video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ph-label {
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0;
  text-align: center;
  color: var(--ink-soft);
  padding: 6px 10px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.6);
}

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

.adventures__title {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  font-family: var(--sans);
  font-weight: 400;
  letter-spacing: -0.05em;
  line-height: 0.9;
}
.adventures__word--top { font-size: 40px; padding-right: 4px; }
.adventures__word--bottom {
  font-size: 54px;
  font-style: italic;
  letter-spacing: -0.06em;
}

.timeline { margin-top: 56px; border-top: 1px solid var(--line); }
.timeline__row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: center;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  font-size: 20px;
  line-height: 1.1;
  letter-spacing: -0.05em;
}
.timeline__org { font-size: 19px; }
.timeline__years { text-align: right; white-space: nowrap; }

/* ------------------------------------------------------------------
   More from the field
------------------------------------------------------------------ */
.more { padding-top: var(--space-section); }

.more__label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--pixel);
  font-weight: 400;
  font-size: 24px;
  line-height: 1.15;
  letter-spacing: -0.05em;
}
.more__square { width: 12px; height: 12px; background: var(--ink); display: inline-block; }

.gallery { margin-top: 80px; display: grid; gap: 40px; }
.gallery__row { display: grid; gap: 12px; }
.gallery__row--2 { grid-template-columns: 1fr 1fr; }
.gallery__row--3 { grid-template-columns: repeat(3, 1fr); }
.gallery__row--uneven { grid-template-columns: 1fr 1fr; align-items: start; }
.gallery__row--3 .gallery__item { aspect-ratio: 222 / 224; }
.gallery__row--2 .gallery__item { aspect-ratio: 345 / 348; }
.gallery__item--full { width: 100%; }
.gallery__item--tall { aspect-ratio: 714 / 783; }
.gallery__item--video { aspect-ratio: 714 / 404; }
.gallery__item--poster { aspect-ratio: 714 / 720; }
.gallery__item--portrait { aspect-ratio: 345 / 637; }
.gallery__item--offset { aspect-ratio: 1; margin-top: 64px; }

/* ------------------------------------------------------------------
   About
------------------------------------------------------------------ */
.about { padding-top: var(--space-section); }
.about__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr);
  gap: 48px;
  align-items: start;
}

.about__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 36px;
  line-height: 1.09;
  letter-spacing: -0.05em;
}
.about__columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}
.about__col p {
  font-family: var(--mono);
  font-weight: 300;
  font-size: 14px;
  line-height: 1.8;
  letter-spacing: -0.05em;
}
.about__col p + p { margin-top: 24px; }
.about__signature { margin-top: 24px; width: 220px; color: var(--ink); }
.about__signature svg { width: 100%; height: auto; display: block; }

/* ------------------------------------------------------------------
   Footer
------------------------------------------------------------------ */
.site-footer { padding-top: 120px; padding-bottom: 140px; }
.site-footer__rule { border-top: 1.5px dashed rgba(15, 17, 17, 0.35); }
.site-footer__title {
  margin-top: 28px;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(44px, 6.6vw, 96px);
  line-height: 1;
  letter-spacing: -0.05em;
  white-space: nowrap;
}
.site-footer__links {
  margin-top: 56px;
  display: flex;
  gap: 76px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.05em;
}
.site-footer__meta {
  margin-top: 48px;
  font-size: 13px;
  color: var(--ink-soft);
}
.site-footer__links a { position: relative; }
.site-footer__links a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.site-footer__links a:hover::after { transform: scaleX(1); }

/* ------------------------------------------------------------------
   Back to top (floating pill)
------------------------------------------------------------------ */
.back-to-top {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 22px 12px 18px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  font-family: var(--serif);
  font-weight: 300;
  font-size: 28px;
  letter-spacing: -0.05em;
  line-height: 1;
  transform: translate(-50%, 24px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.back-to-top svg { width: 20px; height: 20px; }
.back-to-top.is-visible { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }

/* ------------------------------------------------------------------
   Placeholder markers (hidden in production: remove data-placeholder)
------------------------------------------------------------------ */
[data-placeholder] { outline: 1px dashed transparent; }
body.show-placeholders [data-placeholder] { outline-color: var(--accent); outline-offset: 3px; }

/* ------------------------------------------------------------------
   Responsive
------------------------------------------------------------------ */
@media (max-width: 1000px) {
  .about__inner { grid-template-columns: 1fr; gap: 28px; }
  .timeline__row { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 0.7fr); }
}

@media (max-width: 760px) {
  :root { --space-hero: 120px; --space-section: 100px; }
  .site-header__inner { padding-top: 24px; }
  .hero__title { font-size: 36px; }
  .hero__eyebrow { font-size: 12px; margin-bottom: 20px; }
  .wordmark { font-size: 20px; }
  .hero__sub { margin-top: 32px; }
  .br-desktop { display: none; }
  .tiles { grid-template-columns: 1fr; }
  .tile--narrow .tile__media { aspect-ratio: 4 / 3; }
  .tile--wide .tile__media { aspect-ratio: 4 / 3; }
  .adventures__word--top { font-size: 32px; }
  .adventures__word--bottom { font-size: 42px; }
  .timeline__row {
    grid-template-columns: 1fr auto;
    grid-template-areas: "role years" "org org";
    gap: 6px 16px;
    font-size: 17px;
  }
  .timeline__role { grid-area: role; }
  .timeline__org { grid-area: org; font-size: 17px; color: var(--ink-soft); }
  .timeline__years { grid-area: years; }
  .gallery { gap: 20px; margin-top: 48px; }
  .gallery__row--3 { grid-template-columns: 1fr 1fr; }
  .gallery__item--offset { margin-top: 32px; }
  .about__inner { grid-template-columns: 1fr; gap: 28px; }
  .about__title { font-size: 30px; }
  .about__columns { grid-template-columns: 1fr; gap: 24px; }
  .site-footer { padding-top: 80px; }
  .site-footer__title { white-space: normal; }
  .site-footer__links { gap: 36px; flex-wrap: wrap; }
  .back-to-top { font-size: 22px; bottom: 20px; }
}

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