/* Ski Baron site. Apple-style product page for a cute 3D game, on Arc fundamentals: semantic tokens,
   sentence case, 400/500 text weights, keyboard-only focus rings, reduced motion, light and dark. */

@font-face {
  font-family: "Lilita One";
  src: url("/fonts/lilita-one.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --background: #ffffff;          /* equals the top of hero-light: the image melts into the page */
  --surface: #f4f7fb;
  --foreground: #14305a;          /* the game's ink */
  --text-secondary: #4d5f7b;
  --text-muted: #5f7190;
  --border: #e2e9f3;
  --accent: #2563c8;
  --ink: #14305a;
  --on-art: #ffffff;
  --cta-bg: #14305a;
  --cta-fg: #ffffff;
  --device: #0d1626;
  --flake: rgb(255 255 255 / 0.85);
  --header-bg: rgb(255 255 255 / 0.72);
  --shadow-device: 0 40px 80px -24px rgb(20 48 90 / 0.35), 0 12px 24px -12px rgb(20 48 90 / 0.25);

  --font-display: "Lilita One", ui-rounded, system-ui, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", system-ui, "Segoe UI", Roboto, sans-serif;
  --text-sm: 13px;
  --text-base: 15px;
  --text-lg: 17px;
  --text-xl: 20px;
  --text-2xl: 22px;
  --radius-control: 14px;
  --radius-surface: 24px;
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --page-max: 1320px;
  --gutter: clamp(20px, 5vw, 64px);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --background: #0b1830;        /* equals the top of hero-dark */
    --surface: #10223f;
    --foreground: #f2f6fc;
    --text-secondary: #aebfd8;
    --text-muted: #98abc8;
    --border: #1d3459;
    --accent: #8cc8ff;
    --cta-bg: #ffffff;
    --cta-fg: #14305a;
    --device: #050b16;
    --header-bg: rgb(11 24 48 / 0.72);
    --shadow-device: 0 40px 80px -24px rgb(0 0 0 / 0.7), 0 12px 24px -12px rgb(0 0 0 / 0.5);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --background: #0b1830;
  --surface: #10223f;
  --foreground: #f2f6fc;
  --text-secondary: #aebfd8;
  --text-muted: #98abc8;
  --border: #1d3459;
  --accent: #8cc8ff;
  --cta-bg: #ffffff;
  --cta-fg: #14305a;
  --device: #050b16;
  --header-bg: rgb(11 24 48 / 0.72);
  --shadow-device: 0 40px 80px -24px rgb(0 0 0 / 0.7), 0 12px 24px -12px rgb(0 0 0 / 0.5);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0;
  overflow-x: clip;
  background: var(--background);
  color: var(--foreground);
  font: 400 var(--text-lg) / 1.5 var(--font-body);
  letter-spacing: -0.012em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; font-weight: 500; line-height: 1.1; letter-spacing: -0.02em; }
p { margin: 0; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus:not(:focus-visible) { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.container { width: 100%; max-width: var(--page-max); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -9999px; }
.skip:focus-visible { left: 16px; top: 12px; z-index: 50; padding: 8px 12px; background: var(--background); color: var(--foreground); border: 1px solid var(--border); }

/* Header: sticky, translucent */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--header-bg); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 52px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--foreground); text-decoration: none; font-weight: 500; font-size: var(--text-lg); }
.brand img { width: 28px; height: 28px; border-radius: 7px; }
.nav { display: flex; gap: 2px; }
.nav a { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 12px; color: var(--text-secondary); text-decoration: none; font-size: var(--text-sm); font-weight: 400; border-radius: 10px; transition: color 0.2s; }
.nav a:hover { color: var(--foreground); }

/* Display type */
.display { font-family: var(--font-display); font-weight: 400; letter-spacing: 0.01em; }
.outlined { color: var(--on-art); -webkit-text-stroke: 0.11em var(--ink); paint-order: stroke fill; text-shadow: 0 0.045em 0 var(--ink); }

/* Hero: copy on the clean page, the render full-bleed right below; its peaks dissolve into the page */
.hero { position: relative; text-align: center; }
.hero-copy { position: relative; z-index: 2; padding-top: clamp(48px, 6vw, 104px); }
.hero h1 { font-size: clamp(60px, 7.4vw, 124px); line-height: 0.95; }
.pitch { text-wrap: balance; margin: clamp(12px, 1.2vw, 18px) auto 0; font-size: clamp(19px, 1.75vw, 26px); line-height: 1.3; color: var(--text-secondary); letter-spacing: -0.02em; }
.cta { margin-top: clamp(20px, 2.2vw, 30px); display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 20px; }
.badge-soon { display: inline-flex; align-items: center; min-height: 52px; padding-inline: 26px; border-radius: 999px; background: var(--cta-bg); color: var(--cta-fg); font-size: var(--text-lg); font-weight: 500; }
.facts { font-size: var(--text-sm); color: var(--text-muted); }

.hero-art { position: relative; margin-top: clamp(-48px, -2vw, -12px); overflow: hidden; pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 18%, #000 90%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 18%, #000 90%, transparent 100%); }
.hero-art img { width: 100%; height: clamp(380px, 40vw, 900px); object-fit: cover; object-position: 60% 100%; transform-origin: 62% 85%; animation: kenburns 38s ease-in-out infinite alternate; }
@keyframes kenburns { from { transform: scale(1); } to { transform: scale(1.05) translate3d(-0.5%, -0.6%, 0); } }
@media (max-width: 900px) {
  .hero-art img { height: clamp(360px, 92vw, 640px); object-position: 62% 100%; }
}

/* Slow, faint snowfall over the hero art */
.snow { position: absolute; inset: -260px 0 0; pointer-events: none; background-repeat: repeat; }
.snow-1 { background-image: radial-gradient(circle, var(--flake) 0 1.6px, transparent 2.2px), radial-gradient(circle, var(--flake) 0 1.2px, transparent 1.8px); background-size: 190px 190px, 190px 190px; background-position: 0 0, 95px 110px; opacity: 0.55; animation: fall-1 26s linear infinite; }
.snow-2 { background-image: radial-gradient(circle, var(--flake) 0 2.4px, transparent 3px); background-size: 260px 260px; background-position: 60px 40px; opacity: 0.4; animation: fall-2 38s linear infinite; }
@keyframes fall-1 { to { transform: translate3d(-30px, 190px, 0); } }
@keyframes fall-2 { to { transform: translate3d(40px, 260px, 0); } }

/* Sections */
.section { padding-block: clamp(72px, 12vw, 184px); }
.section.tint { background: var(--surface); }
.headline { text-wrap: balance; font-family: var(--font-display); font-weight: 400; letter-spacing: 0.005em; font-size: clamp(44px, 6.4vw, 96px); line-height: 0.98; color: var(--foreground); }
.lede { text-wrap: pretty; margin-top: clamp(16px, 1.6vw, 24px); font-size: clamp(19px, 1.7vw, 25px); line-height: 1.4; color: var(--text-secondary); max-width: 30ch; letter-spacing: -0.018em; }
.center { text-align: center; }
.center .lede { margin-inline: auto; }

.feature { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); align-items: center; gap: clamp(48px, 7vw, 120px); }
.feature.flip .feature-media { order: -1; }
.feature-media { display: flex; justify-content: center; }
.device { width: clamp(270px, 27vw, 400px); padding: clamp(9px, 0.8vw, 12px); border-radius: clamp(44px, 4.2vw, 62px); background: var(--device); box-shadow: var(--shadow-device); }
.device img { width: 100%; border-radius: clamp(36px, 3.4vw, 50px); }
.device-row { margin-top: clamp(48px, 6vw, 88px); display: flex; justify-content: center; }

/* Crew */
.crew { margin: clamp(48px, 6vw, 80px) auto 0; max-width: 1040px; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(32px, 4vw, 56px) 24px; }
.crew li { text-align: center; }
.crew img { width: clamp(108px, 10vw, 144px); margin: 0 auto 14px; }
.crew b { display: block; font-weight: 500; font-size: var(--text-lg); }
.crew span { display: block; margin-top: 2px; font-size: var(--text-sm); color: var(--text-secondary); }

/* Mountains */
.peaks { margin: clamp(48px, 6vw, 88px) 0 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 40px); align-items: end; }
.peaks li { text-align: center; }
.peaks img { width: 100%; max-width: 200px; margin: 0 auto 14px; }
.peaks b { display: block; font-weight: 500; }
.peaks span { font-size: var(--text-sm); color: var(--text-secondary); }

/* Gallery */
.gallery { margin: clamp(40px, 5vw, 72px) 0 0; padding: 8px max(var(--gutter), calc((100% - var(--page-max)) / 2 + var(--gutter))) 24px; list-style: none; display: grid; grid-auto-flow: column; grid-auto-columns: clamp(232px, 22vw, 320px); gap: clamp(16px, 2vw, 28px); overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scroll-padding-inline: max(var(--gutter), calc((100% - var(--page-max)) / 2 + var(--gutter))); scrollbar-width: none; }
.gallery::-webkit-scrollbar { display: none; }
.gallery li { scroll-snap-align: start; }
.gallery img { width: 100%; border-radius: 28px; }

/* FAQ */
.faq-wrap { max-width: 880px; }
.faq { margin-top: clamp(32px, 4vw, 56px); border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; padding: 18px 4px; font-weight: 500; font-size: clamp(var(--text-lg), 1.4vw, var(--text-xl)); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 10px; height: 10px; margin-right: 6px; border-right: 1.75px solid var(--text-muted); border-bottom: 1.75px solid var(--text-muted); transform: translateY(-3px) rotate(45deg); transition: transform 0.25s var(--ease-out); }
.faq details[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.faq details p { padding: 0 4px 24px; color: var(--text-secondary); font-size: var(--text-lg); line-height: 1.6; max-width: 68ch; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); }
.site-footer .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; padding-block: 28px 40px; font-size: var(--text-sm); color: var(--text-muted); }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 0 22px; }
.site-footer a { color: var(--text-secondary); text-decoration: none; display: inline-flex; min-height: 44px; align-items: center; }
.site-footer a:hover { color: var(--foreground); text-decoration: underline; }

/* Reveal on scroll. Visible by default; hidden only once site.js has added .js-reveal (it also runs a
   1.5 s watchdog that reveals everything if IntersectionObserver never reports). */
.js-reveal .reveal:not(.in) { opacity: 0; transform: translate3d(0, 32px, 0); }
.js-reveal .reveal { transition: opacity 0.9s var(--ease-out), transform 1.1s var(--ease-out); }
.js-reveal .reveal.d1 { transition-delay: 0.08s; }
.js-reveal .reveal.d2 { transition-delay: 0.16s; }
.js-reveal .reveal.d3 { transition-delay: 0.24s; }

/* Legal and support pages */
.doc { max-width: 760px; margin-inline: auto; padding: clamp(40px, 6vw, 72px) var(--gutter) clamp(64px, 8vw, 120px); }
.doc h1 { font-size: clamp(36px, 6vw, 56px); letter-spacing: -0.03em; }
.doc .meta { margin-top: 10px; color: var(--text-muted); font-size: var(--text-sm); }
.doc h2 { font-size: clamp(var(--text-xl), 2.4vw, 26px); margin-top: 48px; }
.doc h3 { font-size: var(--text-lg); margin-top: 28px; }
.doc p, .doc li { color: var(--text-secondary); font-size: var(--text-lg); line-height: 1.65; }
.doc p { margin-top: 14px; }
.doc ul { margin: 14px 0 0; padding-left: 22px; }
.doc li + li { margin-top: 8px; }
.doc strong { color: var(--foreground); font-weight: 500; }
.doc .callout { margin-top: 28px; padding: 20px 24px; border-radius: var(--radius-surface); background: var(--surface); font-size: var(--text-lg); line-height: 1.65; color: var(--text-secondary); }
.doc .callout p:first-child { margin-top: 0; }
.doc .faq { margin-top: 20px; }
.doc .faq details p { margin: 0; }
.doc-page .site-header .container, .doc-page .site-footer .container { max-width: 1080px; }

/* Responsive */
@media (max-width: 900px) {
  .feature, .feature.flip { grid-template-columns: minmax(0, 1fr); text-align: center; }
  .feature .lede { margin-inline: auto; }
  .feature.flip .feature-media { order: 0; }
  .peaks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .crew { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .peaks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .peaks li:last-child { grid-column: 1 / -1; }
  .peaks li:last-child img { max-width: 50%; }
  .gallery { grid-auto-columns: 70%; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-art img, .snow { animation: none; }
  .js-reveal .reveal, .js-reveal .reveal:not(.in) { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
