/* eromanov.cc — "The wall".
   He matches the wall he stands against, so every surface is a wall: the rider on sage, the bike on white,
   the race on carbon. Three colours, colour photos only against a wall, road shots in one duotone. */
:root {
  --wall: #b9cfc8;
  --carbon: #111413;
  --chalk: #f4f5f0;
  --tan: #a8744f;
  --soft: rgb(17 20 19 / .62);
  --hair: rgb(17 20 19 / .16);
  --hair-light: rgb(244 245 240 / .2);
  --gutter: clamp(1rem, 3.9vw, 3.5rem);
  --wide: "wdth" 125;
  /* The wall and the floor of each photo, continued to the left from the picture's own left edge */
  --rider-wall: linear-gradient(#d1e4df 0%, #d4e8e6 3.6%, #d3e9e7 7.1%, #d2e8e6 10.7%, #cde6e3 14.3%, #cce2e0 17.9%, #cbe1de 21.4%, #c6dcd9 25%, #c2d9d4 28.6%, #c1d8d2 32.1%, #bfd4cd 35.7%, #bcd1ca 39.3%, #b8cdc6 42.9%, #b3c8c1 46.4%, #adc2bb 50%, #a4b8b2 53.6%, #a0b3ad 57%, #98aba5 60%, #92a39d 63%, #899a94 65%, #7e8e8b 67%, #7a8a87 70%, #748483 73%, #6d7d7c 75.7%, #80868c 75.7%, #82878d 77.6%, #5f6b7b 77.6%, #6f7c8d 82%, #74819a 86%, #76839a 92%, #8491a4 100%);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--chalk); color: var(--carbon);
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(1rem, 0.94rem + 0.25vw, 1.125rem); line-height: 1.55; -webkit-font-smoothing: antialiased;
}
img { display: block; width: 100%; height: auto; }
picture { display: block; }
figure { margin: 0; }
a { color: inherit; text-decoration-color: var(--tan); text-decoration-thickness: 2px; text-underline-offset: 0.3em; }
a:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
p { margin: 0 0 1em; max-width: 56ch; }
ul, ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3 { margin: 0; }
h1 { font-variation-settings: var(--wide); font-weight: 600; letter-spacing: -0.025em; line-height: 0.98; }
h2 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2rem); font-weight: 500; letter-spacing: -0.015em; line-height: 1.15; }
h3 { font-size: 1em; font-weight: 600; }
.wrap { padding-inline: var(--gutter); max-width: 90rem; margin-inline: auto; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.mark { font-variation-settings: var(--wide); font-weight: 600; text-decoration: none; }
.intro, .bike { padding-block: clamp(4rem, 9vw, 8rem); }

/* 1. Hero: the wall is the page. Name on the wall, links on the floor. */
.hero { position: relative; height: 100svh; min-height: 34rem; max-height: 62rem; background: var(--rider-wall); overflow: hidden; }
.hero-photo { position: absolute; inset: 0; }
.hero-photo img { position: absolute; right: 0; top: 0; height: 100%; width: auto; max-width: none; }
.bar { position: absolute; inset: 0 0 auto 0; display: flex; gap: 2rem; align-items: baseline; padding: 1.1rem var(--gutter); font-size: 0.9375rem; }

.hero-text { position: absolute; left: var(--gutter); bottom: 36%; max-width: 46rem; }
.hero-text h1 { font-size: clamp(3rem, 6.4vw, 6.25rem); }
.hero-text p { margin: 1.4rem 0 0; max-width: 30ch; font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.3rem); line-height: 1.35; }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 24%; background: linear-gradient(transparent, rgb(17 20 19 / .5)); pointer-events: none; }
.hero-links { position: absolute; z-index: 1; left: var(--gutter); bottom: 7.5%; display: flex; gap: 2.25rem; color: #fff; font-variation-settings: var(--wide); font-weight: 600; font-size: clamp(1.15rem, 1rem + 0.7vw, 1.5rem); text-shadow: 0 1px 10px rgb(17 20 19 / .45); }
.hero-links a { text-decoration-color: currentColor; text-decoration-thickness: 2px; }

/* 2. Intro on chalk, three road plates in one duotone */
.intro-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: end; }
.intro-text { grid-column: 1 / span 5; }
.intro-text h2 { font-size: clamp(1.7rem, 1.1rem + 2.3vw, 2.9rem); line-height: 1.08; letter-spacing: -0.025em; margin-bottom: 0.8em; max-width: 14ch; }
.intro-text p { color: var(--soft); margin: 0; max-width: 44ch; }
.plates { grid-column: 7 / span 6; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(0.5rem, 1.6vw, 1.5rem); }

/* 3. The race, on carbon */
.race { background: var(--carbon); color: var(--chalk); padding-block: clamp(3.5rem, 8vw, 7rem); }
.race-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.5rem 2rem; }
.race h2 { font-variation-settings: var(--wide); font-weight: 600; font-size: clamp(1.6rem, 1.1rem + 2vw, 2.75rem); color: var(--wall); letter-spacing: -0.02em; }
.countdown { margin: 0; font-variant-numeric: tabular-nums; }
.countdown span { font-variation-settings: var(--wide); font-weight: 600; font-size: 1.5em; margin-right: 0.2em; }
.race-intro { margin-top: 1.5rem; max-width: 60ch; color: rgb(244 245 240 / .72); }
.profile { margin-top: clamp(2.5rem, 6vw, 4.5rem); }
.profile figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.2rem 2rem; margin: 0 0 0.5rem; font-size: 0.875rem; }
.profile-read { color: var(--wall); font-variant-numeric: tabular-nums; }
#profile { display: block; width: 100%; height: clamp(21rem, 36vw, 31rem); touch-action: pan-y; cursor: crosshair; }
#profile .area { fill: var(--wall); }
#profile .lead { stroke: rgb(244 245 240 / .38); stroke-width: 1; }
#profile .dot { fill: var(--chalk); }
#profile text { font-family: inherit; font-size: 12px; fill: var(--chalk); }
#profile text .alt { fill: var(--wall); }
#profile .axis text { fill: rgb(244 245 240 / .55); font-size: 11px; font-variant-numeric: tabular-nums; }
#profile .axis line { stroke: rgb(244 245 240 / .3); }
#profile .cursor { stroke: var(--chalk); stroke-width: 1; }
.rows { border-top: 1px solid var(--hair-light); }
.rows li { display: grid; grid-template-columns: 7rem 15rem 6rem 1fr; gap: 1rem; padding-block: 0.9rem; border-bottom: 1px solid var(--hair-light); }
.rows span:first-child { color: var(--wall); font-weight: 600; font-variant-numeric: tabular-nums; }
.rows span:last-child { color: rgb(244 245 240 / .72); }
.stages { margin-top: clamp(2rem, 5vw, 3.5rem); }
.race h3 { margin: clamp(2.5rem, 6vw, 4.5rem) 0 1rem; font-weight: 500; font-size: 1.15em; }

/* 4. The bike, on white */
.bike-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: end; }
.bike-photos { grid-column: 1 / span 7; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(0.5rem, 1.6vw, 1.5rem); }
.bike-photos img { aspect-ratio: 4 / 5; object-fit: cover; }
.bike-text { grid-column: 9 / span 4; }
dl { margin: clamp(1.25rem, 3vw, 2rem) 0 0; }
dl div { padding-block: 0.7rem; border-top: 1px solid var(--hair); }
dl div:last-child { border-bottom: 1px solid var(--hair); }
dt { font-size: 0.8125rem; color: var(--soft); }
dd { margin: 0; font-weight: 500; }

/* 5. Close: back on the wall, links standing on the floor (the footer) */
.outro { background: var(--wall); padding-block: clamp(4rem, 9vw, 8rem) clamp(2.5rem, 5vw, 4rem); }
.outro h2 { font-variation-settings: var(--wide); font-weight: 600; font-size: clamp(1.9rem, 1rem + 4.2vw, 4.75rem); letter-spacing: -0.025em; line-height: 1; }
.outro p { margin: 1.4rem 0 0; max-width: 40ch; }
.outro ul { display: flex; flex-wrap: wrap; gap: 0.5rem 2.5rem; margin-top: clamp(2.5rem, 6vw, 5rem); font-variation-settings: var(--wide); font-weight: 600; font-size: clamp(1.2rem, 1rem + 1vw, 1.75rem); }

.foot { background: var(--carbon); color: var(--chalk); padding-block: 1.6rem; font-size: 0.9375rem; }
.foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.75rem 2rem; }
.foot a { text-decoration-thickness: 1px; }
.copy { color: rgb(244 245 240 / .55); }

@media (max-width: 820px) {
  /* Phone: the photo is the whole first screen */
  .hero { height: auto; min-height: 0; max-height: none; background: #d1e4df; }
  .hero-photo img { position: static; width: 100%; }
  .hero-photo { position: static; }
  .hero-photo img { height: auto; }
  .hero-text { top: 3.6rem; bottom: auto; max-width: 52%; }
  .hero-text h1 { font-size: clamp(1.6rem, 8.4vw, 2.6rem); }
  .hero-text p { margin-top: 0.8rem; font-size: 0.9375rem; }
  .hero-links { bottom: 2.6%; gap: 1.4rem; font-size: 1.0625rem; }
  .hero::after { height: 16%; }
  .intro-grid, .bike-grid { display: block; }
  .plates { margin-top: 3rem; }

  .rows li { grid-template-columns: 1fr auto; gap: 0.15rem 1rem; }
  .rows span:nth-child(1) { grid-column: 1 / -1; font-size: 0.875rem; }
  .rows span:nth-child(4) { grid-column: 1 / -1; font-size: 0.9rem; }
  .bike-text { margin-top: 3rem; }
  .foot { padding-block: 2rem; }
  .foot .wrap { flex-direction: column; align-items: flex-start; gap: 0.9rem; }
  .foot .copy { margin-top: 0.6rem; font-size: 0.8125rem; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
