/* GDev shared base, taken from brand/gg-brand-kit v1.1.
   Palette 60 paper / 20 forest / 10 signal / 10 ink + stone. Square corners. Space, not lines. 8 px rhythm. */
:root {
  --b-paper: #EEE5D4;
  --b-forest: #1D4A35;
  --b-signal: #F4622A;
  --b-signal-hover: #F7794A;
  --b-ink: #111C16;
  --b-stone: #CFC6B2;

  --bg: #EEE5D4;
  --field: #E4D9C4;
  --card: #E4D9C4;
  --fg: #111C16;
  --muted: #3A4840;
  --mark: #1D4A35;
  --link: #1D4A35;
  --warn: #96391A;

  --f-display: 'Montserrat', 'Century Gothic', 'Avenir Next', system-ui, sans-serif;
  --f-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-code: 'JetBrains Mono', ui-monospace, Consolas, monospace;

  --t-small: 14px;
  --t-body: 17px;
  --t-lead: 20px;
  --t-h3: 24px;
  --t-xl: clamp(24px, 2.4vw, 34px);
  --t-h2: clamp(32px, 4vw, 56px);
  --t-display: clamp(40px, 5.6vw, 84px);

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-move: cubic-bezier(0.77, 0, 0.175, 1);
  --d-press: 140ms;
  --d-hover: 150ms;
  --d-enter: 250ms;

  --z-nav: 20;
  --z-skip: 40;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0E1A14; --field: #15271E; --card: #15271E; --fg: #EEE5D4; --muted: #BFC5B6;
    --mark: #EEE5D4; --link: #8FCBA9; --warn: #F08A60;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0E1A14; --field: #15271E; --card: #15271E; --fg: #EEE5D4; --muted: #BFC5B6;
  --mark: #EEE5D4; --link: #8FCBA9; --warn: #F08A60;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 var(--t-body)/1.6 var(--f-body); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg, canvas { display: block; }
h1, h2, h3, h4 { font-family: var(--f-display); font-weight: 600; line-height: 1.08; margin: 0; text-wrap: balance; letter-spacing: -0.025em; }
p { margin: 0; max-width: 64ch; }
a { color: var(--link); }
code { font-family: var(--f-code); }
:focus-visible { outline: 2px solid var(--b-signal); outline-offset: 3px; }
::selection { background: var(--b-signal); color: var(--b-ink); }

.wrap { max-width: 1184px; margin: 0 auto; padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
.wm, .mark { display: block; fill: currentColor; height: auto; }
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip { position: absolute; left: 16px; top: -80px; z-index: var(--z-skip); background: var(--b-forest); color: var(--b-paper); padding: 14px 18px; font: 600 var(--t-small)/1 var(--f-display); text-decoration: none; }
.skip:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }

/* buttons: square, ink on signal for the one loud action */
.btn { font: 600 var(--t-small)/1 var(--f-display); padding: 0 22px; min-height: 48px; border: 0; display: inline-flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; cursor: pointer; touch-action: manipulation; transition: transform var(--d-press) var(--ease-out), background-color var(--d-hover) ease, color var(--d-hover) ease; }
.btn:active { transform: scale(0.97); }
.btn.go { background: var(--b-signal); color: var(--b-ink); }
.btn.soft { background: color-mix(in srgb, currentColor 12%, transparent); color: inherit; }
.btn.solid { background: var(--b-forest); color: var(--b-paper); }
@media (hover: hover) and (pointer: fine) {
  .btn.go:hover { background: var(--b-signal-hover); }
  .btn.soft:hover { background: color-mix(in srgb, currentColor 20%, transparent); }
  .btn.solid:hover { background: #24593F; }
}
.btn svg { width: 18px; height: 18px; flex: none; }

.ico { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square; stroke-linejoin: miter; }

/* forms */
.field { display: grid; gap: 8px; }
.field label { font: 600 var(--t-small)/1.3 var(--f-display); }
.field input, .field textarea, .field select { font: 400 var(--t-body)/1.4 var(--f-body); color: inherit; background: color-mix(in srgb, currentColor 7%, transparent); border: 0; border-bottom: 2px solid color-mix(in srgb, currentColor 30%, transparent); border-radius: 0; padding: 12px 14px; min-height: 48px; width: 100%; transition: border-color var(--d-hover) ease, background-color var(--d-hover) ease; }
.field textarea { min-height: 128px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-bottom-color: var(--b-signal); background: color-mix(in srgb, currentColor 11%, transparent); }
.field .hint { font-size: var(--t-small); opacity: .85; }
.field .err { font-size: var(--t-small); color: var(--warn); min-height: 0; }
.field[data-invalid] input, .field[data-invalid] textarea { border-bottom-color: var(--warn); }
.form-status { font-size: var(--t-small); min-height: 22px; }

/* reveal on scroll: fade and rise, opacity only when motion is reduced */
.rv { opacity: 0; transform: translateY(14px); transition: opacity 400ms var(--ease-out), transform 400ms var(--ease-out); }
.rv.in { opacity: 1; transform: none; }
.no-js .rv { opacity: 1; transform: none; }

.concept-note { font-size: var(--t-small); opacity: .9; }

@media (prefers-reduced-motion: reduce) {
  .btn:active { transform: none; }
  .rv { transform: none; transition: opacity 240ms ease; }
}
