/* Archivo (variable, self-hosted). latin-ext carries Ž, č, š. */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 500 800;
  font-display: swap;
  src: url("assets/fonts/archivo-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 500 800;
  font-display: swap;
  src: url("assets/fonts/archivo-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --soot: #0f0c0b;
  --paper: #efe7dd;
  --paper-dim: #b3a79a;
  --paper-faint: rgba(239, 231, 221, 0.62);
  --molten: #ff6a1a;
  --molten-hot: #ffc857;
  --line: #2a221e;
  --font-display: "Archivo", "Helvetica Neue", "Segoe UI", system-ui, sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --pad: clamp(1.25rem, 4vw, 4rem);
}

* { box-sizing: border-box; }

html {
  color-scheme: dark;
  background: var(--soot);
  color: var(--paper);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

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

::selection {
  background: var(--molten);
  color: #1a0c05;
}

/* ---------- Header ---------- */

.site-header {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem var(--pad);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
}

.logo-mark {
  width: 1.1em;
  height: 1.1em;
  fill: var(--molten);
}

.site-nav {
  display: flex;
  gap: 1.75rem;
  font-size: 0.95rem;
  font-weight: 500;
}

/* Padding grows the tap target; the negative margin keeps the layout. */
.site-nav a {
  padding: 0.75rem 0.5rem;
  margin: -0.75rem -0.5rem;
  text-decoration: none;
  color: var(--paper-dim);
}

.site-nav a:hover { color: var(--paper); }

/* ---------- Hero ----------
   Small screens: copy above the scene.
   1024px and up: copy floats over the sky of the scene. Its sizes use
   cqh (hero height), because the scene scales with the hero height. */

.hero {
  display: flex;
  flex-direction: column;
}

.foundry {
  display: block;
  width: 100%;
  height: 75vw;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.hero-copy {
  order: -1;
  padding: 1.5rem var(--pad) 1.75rem;
}

h1 {
  margin: 0 0 1.25rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.2rem, 7vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
}

h1 span { color: var(--molten); }

.lede {
  max-width: 32em;
  margin: 0 0 1.75rem;
  font-size: 1.05rem;
  color: var(--paper-dim);
}

.btn {
  display: inline-block;
  padding: 0.85rem 1.4rem;
  border-radius: 999px;
  background: var(--molten);
  color: #1a0c05;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.2s, background 0.2s;
}

.btn:hover {
  background: #ff8136;
  transform: translateY(-1px);
}

.btn:active {
  background: #f05c10;
  transform: translateY(0);
}

.hero-hint {
  margin: 0;
  padding: 0.6rem var(--pad) 0;
  font-size: 0.8rem;
  color: var(--paper-faint);
}

.hint-touch { display: none; }

@media (hover: none) {
  .hint-mouse { display: none; }
  .hint-touch { display: inline; }
}

@media (min-width: 700px) {
  .foundry { height: 50vw; }
}

@media (min-width: 1024px) {
  .site-header {
    position: absolute;
    inset: 0 0 auto 0;
  }

  .hero {
    display: block;
    position: relative;
    height: min(50vw, 100svh);
    container-type: size;
  }

  .foundry { height: 100%; }

  .hero-copy {
    position: absolute;
    top: max(5rem, 13cqh);
    right: var(--pad);
    width: min(80cqh, 42rem);
    padding: 0;
    pointer-events: none;
  }

  .hero-copy a { pointer-events: auto; }

  h1 {
    margin-bottom: 2.5cqh;
    font-size: min(6.6cqh, 4.25rem);
  }

  .lede {
    margin-bottom: 3.5cqh;
    font-size: clamp(15px, 2.5cqh, 1.3rem);
  }

  .hero-copy .btn {
    padding: clamp(0.7rem, 1.6cqh, 1rem) clamp(1.2rem, 3cqh, 1.75rem);
    font-size: clamp(14px, 2.2cqh, 1.15rem);
  }

  .hero-hint {
    position: absolute;
    left: var(--pad);
    bottom: 1.4cqh;
    padding: 0;
    pointer-events: none;
  }
}

/* ---------- Sections: heading left, body right ---------- */

.section {
  max-width: 1400px;
  margin: 0 auto;
  padding: clamp(4.5rem, 9vw, 8rem) var(--pad);
}

.section + .section { padding-top: 0; }

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 1.5rem 4rem;
  align-items: start;
}

h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 3.6vw, 3.25rem);
  line-height: 1.05;
  letter-spacing: -0.018em;
  text-wrap: balance;
}

.lead {
  max-width: 24em;
  margin: 0 0 1.5rem;
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 2.4vw, 2.2rem);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.005em;
  text-wrap: pretty;
}

.split-body p:not(.lead) {
  max-width: 36em;
  margin: 0 0 1rem;
  font-size: 1.1rem;
  color: var(--paper-dim);
  text-wrap: pretty;
}

.btn-big {
  margin-top: 0.5rem;
  padding: 1rem 2rem;
  font-size: clamp(1rem, 2vw, 1.25rem);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  padding: 1.5rem var(--pad);
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
  color: var(--paper-faint);
}

@media (max-width: 1023px) {
  .split { grid-template-columns: 1fr; }
}

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