/* Hallmark · pre-emit critique: P5 H5 E5 S4 R5 V4
 * Hallmark · genre: editorial · macrostructure: Marquee Hero · theme: Almanac
 * H1 Marquee knobs: size=xl, alignment=left-bias, underlay=single rule below
 * S2 Hanging · F3 Tabular spec knobs: columns=2, rules=every row, numbers=tabular
 * C3 Typographic link knobs: underline=solid, hover=thicken, arrow=none
 * nav: N9 edge-aligned minimal (CTA=text+arrow, wordmark=serif, padding=spacious)
 * footer: Ft4 dense colophon (family=sans, layout=single block, includes=date+attribution)
 * enrichment: none — typography-only fold; photography as full-bleed bands, uncaptioned
 *   (a place-caption would be a false claim: the stock frames are not Lehmijärvi)
 * tone: austere · lang: fi · anchor hue: 238 cool-lake
 * outlier (Geist Mono) is reserved for ONE role: the telephone number.
 * verified in-browser: 320/375/414/768/1280 no overflow · no 2-line clickable text
 *   contrast light 5.51–16.27:1, dark 5.67–16.69:1 · fold complete at 1280x800
 */

@import url("tokens.css");

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

html {
  overflow-x: clip;              /* clip, not hidden — preserves sticky */
  -webkit-text-size-adjust: 100%;
}

body {
  overflow-x: clip;
  margin: 0;
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-style: normal;            /* roman only — italic headers are banned */
  font-optical-sizing: auto;
  letter-spacing: -0.025em;
  overflow-wrap: anywhere;
  min-width: 0;
  text-wrap: balance;
  margin: 0;
}

p { margin: 0; }

a { color: inherit; }

::selection { background: var(--color-accent); color: var(--color-paper); }

:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 3px;
  transition: none;              /* focus rings never animate in */
}

/* ------------------------------------------------------------ page frame */
.shell {
  max-width: 92rem;
  margin-inline: auto;
  padding-inline: var(--page-gutter);
}

.rule-thick {
  border: 0;
  border-top: var(--rule-thick) solid var(--color-ink);
  margin: 0;
}

/* ------------------------------------------------- N9 edge-aligned nav */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  padding-block: var(--space-xl) var(--space-lg);
}

.nav__wordmark {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: var(--text-md);
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-decoration: none;
  white-space: nowrap;
}

.nav__call {
  font-family: var(--font-outlier);
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  white-space: nowrap;           /* never wrap a clickable to two lines */
  text-decoration: none;
  color: var(--color-accent);
  position: relative;
  padding-bottom: var(--space-3xs);
}
.nav__call::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: var(--color-accent);
  transform: scaleY(0.5);
  transform-origin: bottom;
  transition: transform var(--dur-micro) var(--ease-out);
}
.nav__call:hover::after { transform: scaleY(1); }
.nav__call:active { color: var(--color-ink); }

/* ----------------------------------------------------- H1 Marquee hero */
.hero {
  display: grid;
  align-content: end;
  min-height: min(78dvh, 46rem);
  padding-block: var(--space-2xl) var(--space-3xl);
}

.hero__display {
  font-weight: 100;              /* 300 units of contrast against body 400 */
  font-size: var(--text-display);
  line-height: 1.04;
  max-width: 18ch;
}

/* ------------------------------------------------------- full-bleed band */
.band {
  position: relative;
  width: 100%;
  margin: 0;
}

.band__img {
  width: 100%;
  object-position: 50% 45%;
  height: clamp(16rem, 46vh, 30rem);
  object-fit: cover;
}

.band--tall .band__img { height: clamp(20rem, 62vh, 38rem); }

/* ------------------------------------------------------------- sections */
.section { padding-block: var(--space-3xl); }
.section--tight { padding-block: var(--space-2xl) var(--space-3xl); }

/* S2 Hanging — heading floats above in negative space, stacked single column */
.head-hang {
  padding-block: 0 var(--space-xl);
  max-width: 24ch;
}

.head-hang h2 {
  font-weight: 200;
  font-size: var(--text-2xl);
  line-height: 1.12;
}

/* asymmetric prose block — deliberately off-centre, not a centred column */
.lede {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: var(--space-2xl);
  align-items: start;
}

.lede__body {
  max-width: 58ch;
  font-size: var(--text-md);
  line-height: 1.62;
  color: var(--color-muted);
}

.lede__body p + p { margin-top: var(--space-lg); }

.lede__body strong {
  font-weight: 400;
  color: var(--color-ink);
}

.lede__aside {
  font-size: var(--text-sm);
  line-height: 1.8;
  letter-spacing: 0.04em;
  color: var(--color-neutral);
  border-top: var(--rule-hair) solid var(--color-rule);
  padding-top: var(--space-sm);
}

/* ------------------------------------------- F3 tabular spec sheet */
.spec {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
  text-align: left;
}

.spec th,
.spec td {
  border-top: var(--rule-hair) solid var(--color-rule);
  padding-block: var(--space-lg);
  padding-inline: 0 var(--space-lg);
  vertical-align: baseline;
  font-weight: 400;
}

.spec tr:last-child th,
.spec tr:last-child td { border-bottom: var(--rule-hair) solid var(--color-rule); }

.spec th {
  width: 34%;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: var(--text-md);
  letter-spacing: -0.015em;
  color: var(--color-ink);
}

.spec td {
  color: var(--color-muted);
  max-width: 52ch;
  padding-inline-end: 0;
}

/* ------------------------------------------------------ practical info */
.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(15rem, 100%), 1fr));
  gap: var(--space-xl) var(--space-2xl);
}

.facts__item { display: grid; gap: var(--space-2xs); align-content: start; }

.facts__label {
  font-size: var(--text-sm);
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--color-neutral);
}

.facts__value {
  font-size: var(--text-base);
  line-height: 1.5;
  color: var(--color-ink);
}

.facts__value a {
  color: var(--color-ink);
  text-decoration-color: var(--color-rule);
  text-underline-offset: 0.28em;
  transition: text-decoration-color var(--dur-micro) var(--ease-out);
}
.facts__value a:hover { text-decoration-color: var(--color-accent); }
.facts__value a:active { color: var(--color-accent); }

/* --------------------------------------------- C3 typographic call CTA */
.call {
  display: grid;
  gap: var(--space-md);
  padding-block: var(--space-3xl) var(--space-4xl);
}

.call__prompt {
  font-family: var(--font-display);
  font-weight: 200;
  font-size: var(--text-xl);
  line-height: 1.2;
  max-width: 20ch;
}

.call__number {
  font-family: var(--font-outlier);
  font-weight: 500;
  font-size: clamp(1.9rem, 6.4vw, 3.6rem);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  line-height: 1.1;
  white-space: nowrap;
  width: max-content;
  max-width: 100%;
  color: var(--color-accent);
  text-decoration: none;
  position: relative;
  padding-bottom: var(--space-3xs);
}
.call__number::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 3px;
  background: var(--color-accent);
  transform: scaleY(0.66);
  transform-origin: bottom;
  transition: transform var(--dur-short) var(--ease-out);
}
.call__number:hover::after { transform: scaleY(1); }
.call__number:active { color: var(--color-ink); }
.call__number:active::after { background: var(--color-ink); }

.call__note {
  font-size: var(--text-sm);
  color: var(--color-neutral);
  max-width: 46ch;
}

/* -------------------------------------------- Ft4 dense colophon footer */
.colophon {
  border-top: var(--rule-hair) solid var(--color-rule);
  padding-block: var(--space-xl) var(--space-2xl);
  font-size: var(--text-sm);
  line-height: 1.9;
  letter-spacing: 0.03em;
  color: var(--color-neutral);
  max-width: 72ch;
}

.colophon a { color: var(--color-neutral); text-underline-offset: 0.25em; }
.colophon a:hover { color: var(--color-accent); }
.colophon a:active { color: var(--color-ink); }

/* --------------------------------------------------------- reveal motion */
.reveal {
  opacity: 0;
  transform: translateY(8px);
  animation: reveal var(--dur-long) var(--ease-out) forwards;
  animation-delay: calc(var(--i, 0) * 60ms);
}

@keyframes reveal { to { opacity: 1; transform: none; } }

/* -------------------------------------------------------------- mobile */
@media (max-width: 60rem) {
  .lede { grid-template-columns: minmax(0, 1fr); gap: var(--space-xl); }
  .head-hang { max-width: 100%; }
}

@media (max-width: 40rem) {
  .nav { padding-block: var(--space-lg) var(--space-md); }
  .nav__wordmark { font-size: var(--text-base); }
  .nav__wordmark-pre { display: none; }
  .hero { min-height: min(70dvh, 34rem); padding-block: var(--space-xl) var(--space-2xl); }
  .hero__display { max-width: 100%; }
  .section { padding-block: var(--space-2xl); }
  .spec th, .spec td { display: block; max-width: 100%; padding-inline-end: 0; }
  .spec th { width: auto; padding-block: var(--space-md) var(--space-2xs); }
  .spec td { border-top: 0; padding-block: 0 var(--space-md); }
  .spec tr:last-child th { border-bottom: 0; }
}

/* ------------------------------------------------------ reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 150ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 150ms !important;
  }
  .reveal { animation: reveal-reduced 150ms linear forwards; }
  @keyframes reveal-reduced { to { opacity: 1; transform: none; } }
}
