/* Epitrope coming-soon page. Swiss layout, a red-figure terracotta for authority. */

:root {
  --paper: #ffffff;
  --ink: #111418;
  --muted: #4a4f57;
  --rule: #d9dce1;
  --clay: #b8422a;
  --clay-ink: #ffffff;
  /* The hero band and the closing slab each have their own pair, so dark mode can keep the
     Greek word and the slab readable instead of reusing the page's ink. */
  --band: #b8422a;
  --band-ink: #ffffff;
  --band-word: #111418;
  --slab: #111418;
  --slab-ink: #ffffff;
  --code-bg: #111418;
  --code-ink: #e8e6e1;
  --code-key: #f08a6c;
  --code-str: #a8c7a0;
  --code-num: #e7c07a;

  --font-display: "GFS Didot", Didot, "Bodoni 72", serif;
  --font-body: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --font-code: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --text-base: clamp(1rem, 0.94rem + 0.3vw, 1.125rem);
  --text-lede: clamp(1.15rem, 1rem + 0.8vw, 1.5rem);
  --text-hero: clamp(3.5rem, 1.2rem + 11vw, 10rem);
  --text-h3: clamp(1.25rem, 1.1rem + 0.6vw, 1.6rem);

  --gutter: clamp(1rem, 0.5rem + 3vw, 3rem);
  --space-section: clamp(3.5rem, 2.5rem + 5vw, 8rem);
  --measure: 38rem;

  --duration-slow: 900ms;
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0e1013;
    --ink: #f2f1ed;
    --muted: #a7acb4;
    --rule: #2a2e35;
    --clay: #d9603f;
    --clay-ink: #0e1013;
    --band: #8f2f1c;
    --band-ink: #f6e9e4;
    --band-word: #f2f1ed;
    --slab: #1a1d23;
    --slab-ink: #f2f1ed;
    --code-bg: #171a1f;
  }
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

a:focus-visible {
  outline: 3px solid var(--clay);
  outline-offset: 4px;
}

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

/* Header */

.top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 1.5rem var(--gutter);
  border-bottom: 1px solid var(--rule);
}

.wordmark {
  font-family: var(--font-display);
  font-size: 1.5rem;
  text-decoration: none;
  letter-spacing: 0.01em;
}

.status {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clay);
}

/* Hero: the Greek word sits across the edge of a terracotta band */

.hero {
  position: relative;
  padding: var(--space-section) var(--gutter) calc(var(--space-section) * 0.6);
  isolation: isolate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0 0 58% 0;
  background: var(--band);
  z-index: -1;
}

.kicker {
  margin: 0 0 1rem;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--band-ink);
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--text-hero);
  line-height: 0.95;
  letter-spacing: -0.01em;
  color: var(--band-word);
  overflow-wrap: anywhere;
  animation: rise var(--duration-slow) var(--ease-out-expo) both;
}

.gloss {
  margin: 1.25rem 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.lede {
  max-width: var(--measure);
  margin: 2rem 0 0;
  font-size: var(--text-lede);
  line-height: 1.45;
  text-wrap: pretty;
}

/* Code sample, offset from the grid */

.sample {
  padding: 0 var(--gutter) var(--space-section);
}

.sample figure {
  margin: 0 0 0 auto;
  max-width: 46rem;
}

.file {
  margin: 0;
  padding: 0.6rem 1.25rem;
  background: var(--clay);
  color: var(--clay-ink);
  font-family: var(--font-code);
  font-size: 0.85rem;
  display: inline-block;
}

pre {
  margin: 0;
  padding: 1.5rem 1.25rem;
  background: var(--code-bg);
  color: var(--code-ink);
  font-family: var(--font-code);
  font-size: clamp(0.78rem, 0.7rem + 0.35vw, 0.95rem);
  line-height: 1.6;
  overflow-x: auto;
  box-shadow: 0.75rem 0.75rem 0 var(--rule);
}

.k { color: var(--code-key); }
.s { color: var(--code-str); }
.n { color: var(--code-num); }

figcaption {
  margin-top: 1.75rem;
  max-width: var(--measure);
  color: var(--muted);
}

/* Points: one leads, two follow */

.points {
  display: grid;
  gap: 2.5rem;
  padding: var(--space-section) var(--gutter);
  border-top: 1px solid var(--rule);
}

.point h3 {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--text-h3);
  line-height: 1.2;
}

.point p {
  margin: 0;
  color: var(--muted);
  max-width: 30rem;
}

.point--lead h3 {
  font-size: calc(var(--text-h3) * 1.5);
}

.point {
  padding-left: 1.25rem;
  border-left: 3px solid var(--rule);
}

.point--lead {
  border-left-color: var(--clay);
}

@media (min-width: 60rem) {
  .points {
    grid-template-columns: 1.4fr 1fr 1fr;
    align-items: start;
  }

  .point--lead {
    grid-row: span 2;
  }
}

/* Coming soon */

.soon {
  padding: var(--space-section) var(--gutter);
  background: var(--slab);
  color: var(--slab-ink);
  border-top: 4px solid var(--clay);
}

.soon h2 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.25rem, 1.5rem + 3vw, 4rem);
  line-height: 1.05;
}

.soon p {
  margin: 0;
  max-width: var(--measure);
  font-size: var(--text-lede);
  line-height: 1.45;
}

/* Footer */

.bottom {
  padding: 2rem var(--gutter);
  color: var(--muted);
  font-size: 0.9rem;
}

.bottom p {
  margin: 0;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(0.15em);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero h1 {
    animation: none;
  }
}
