/* Shuffle your football — landing. Palette and type mirror the Android app (FootballStyle.kt). */
@font-face { font-family: "Barlow Condensed"; src: url("../assets/fonts/barlowcondensed_bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Barlow Condensed"; src: url("../assets/fonts/barlowcondensed_extrabold.ttf") format("truetype"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../assets/fonts/inter_variable.ttf") format("truetype"); font-weight: 100 900; font-display: swap; }

:root {
  --background: #F7FAF1;
  --surface: #FFFFFF;
  --surface-raised: #EDF4E4;
  --border: #D7E2CB;
  --text: #173C2A;
  --text-2: #48634E;
  --muted: #63705D;
  --accent: #17633D;
  --accent-pressed: #104D2F;
  --accent-deep: #124C30;
  --accent-subtle: #E6F1D7;
  --highlight: #F4D84A;
  --highlight-subtle: #FFF7C5;
  --on-highlight: #24432C;
  --error: #AC3634;
  /* driven by js/main.js while scrolling */
  --bg-a: #F7FAF1;
  --bg-b: #E6F1D7;
  --pitch: #17633D;
  --sun: #F4D84A;
  --scroll: 0;
  --radius-card: 16px;
  --radius-sheet: 24px;
  --display: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--body);
  color: var(--text);
  background: var(--bg-a);
  line-height: 1.55;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--accent); }
h1, h2, h3 { font-family: var(--display); font-weight: 800; line-height: .95; letter-spacing: -.01em; margin: 0; }

/* ---------- fixed 3D backdrop ---------- */
.stage {
  position: fixed; inset: 0; z-index: -1; overflow: hidden;
  background: radial-gradient(120% 90% at 70% 10%, var(--bg-b) 0%, var(--bg-a) 60%);
  perspective: 900px;
  transition: background .2s linear;
}
.stage__sun {
  position: absolute; width: 38vmin; height: 38vmin; border-radius: 50%;
  right: 8vw; top: calc(8vh + var(--scroll) * 30vh);
  background: var(--sun);
  box-shadow: 0 0 120px color-mix(in srgb, var(--sun) 55%, transparent);
  transform: translateZ(-200px) scale(calc(1 + var(--scroll) * .4));
  opacity: .9;
}
.stage__pitch {
  position: absolute; left: 50%; bottom: calc(-62vh + var(--scroll) * 14vh); width: 160vw; height: 110vh;
  transform-origin: 50% 100%;
  transform: translateX(-50%) rotateX(calc(68deg - var(--scroll) * 18deg)) rotateZ(calc(var(--scroll) * 24deg - 6deg));
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,.06) 0 8%, transparent 8% 16%),
    var(--pitch);
  border-radius: 40px;
  box-shadow: inset 0 0 0 6px rgba(255,255,255,.55);
}
.stage__pitch::before, .stage__pitch::after { content: ""; position: absolute; border: 6px solid rgba(255,255,255,.55); }
.stage__pitch::before { left: 50%; top: 50%; width: 26vh; height: 26vh; border-radius: 50%; transform: translate(-50%, -50%); }
.stage__pitch::after { left: 50%; top: 0; bottom: 0; width: 0; border-width: 0 0 0 6px; }
.stage__box { position: absolute; top: 30%; height: 40%; width: 12%; border: 6px solid rgba(255,255,255,.55); }
.stage__box--l { left: -6px; border-left: 0; }
.stage__box--r { right: -6px; border-right: 0; }

.floaters { position: fixed; inset: 0; z-index: -1; pointer-events: none; perspective: 1000px; }
.floater {
  position: absolute; width: 96px; height: 124px; border-radius: 14px;
  background: var(--surface); border: 3px solid var(--accent);
  box-shadow: 8px 10px 0 #CEE2B6;
  transform-style: preserve-3d;
  will-change: transform;
  opacity: .85;
}
.floater::before { content: ""; position: absolute; left: 10px; right: 10px; top: 10px; height: 52px; border-radius: 8px; background: var(--highlight); }
.floater::after { content: ""; position: absolute; left: 10px; right: 22px; top: 76px; height: 7px; border-radius: 4px; background: var(--accent); box-shadow: 0 16px 0 #A6C495; }
.floater--green::before { background: var(--accent-subtle); }
.floater--red::before { background: #E0574F; }
.ball {
  position: absolute; width: 90px; height: 90px; will-change: transform;
  background: url("../assets/favicon.svg") center/170% no-repeat;
  border-radius: 50%;
  filter: drop-shadow(0 14px 18px rgba(18, 76, 48, .25));
}

/* ---------- layout ---------- */
.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
.nav {
  position: fixed; top: 14px; left: 50%; transform: translateX(-50%); z-index: 20;
  width: min(1160px, 100% - 28px);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px 12px 10px 14px; border-radius: 20px;
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-family: var(--display); font-weight: 800; font-size: 22px; letter-spacing: .01em; }
.brand img { width: 38px; height: 38px; border-radius: 10px; }
.nav__links { display: flex; align-items: center; gap: 22px; }
.nav__links a { text-decoration: none; color: var(--text-2); font-weight: 600; font-size: 15px; }
.nav__links a:hover { color: var(--accent); }
@media (max-width: 760px) { .nav__links a:not(.btn) { display: none; } .floater { display: none; } }
@media (max-width: 480px) { .brand span { display: none; } .nav .btn { padding: 0 14px; font-size: 14px; min-height: 42px; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 22px; border-radius: 12px;
  font-family: var(--body); font-weight: 700; font-size: 16px; text-decoration: none;
  background: var(--accent); color: #fff !important; border: 2px solid var(--accent);
  transition: transform .12s ease, background .18s ease;
}
.btn:hover { background: var(--accent-pressed); transform: translateY(-2px); }
.btn--yellow { background: var(--highlight-subtle); color: var(--on-highlight) !important; border-color: #AD9430; }
.btn--yellow:hover { background: var(--highlight); }
.btn--big { min-height: 60px; padding: 0 28px; font-size: 18px; }
.btn svg { width: 22px; height: 22px; }

.eyebrow { font-weight: 800; letter-spacing: .08em; font-size: 14px; color: var(--accent); text-transform: none; margin: 0 0 14px; }
.lead { font-size: clamp(17px, 1.6vw, 20px); color: var(--text-2); max-width: 34ch; }

section { position: relative; padding: 120px 0; }

/* ---------- hero ---------- */
.hero { min-height: 100vh; display: flex; align-items: center; padding-top: 120px; }
.hero__grid > *, .modes__grid > *, .score__grid > * { min-width: 0; }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; }
.hero h1 { font-size: clamp(56px, 9vw, 128px); }
.hero h1 span { display: inline-block; background: var(--highlight); padding: 0 .14em; border-radius: 14px; transform: rotate(-2deg); }
.hero .lead { margin: 26px 0 34px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero__note { margin-top: 18px; font-size: 14px; color: var(--muted); }

/* ---------- 3D phone ---------- */
.scene { perspective: 1400px; display: grid; place-items: center; min-height: 640px; }
.phone {
  --rx: 8deg; --ry: -22deg; --rz: 2deg;
  position: relative; width: 300px; aspect-ratio: 9 / 20; border-radius: 46px;
  background: #1B1F1C; padding: 11px;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry)) rotateZ(var(--rz));
  box-shadow: 0 0 0 2px #2C332E, 0 50px 80px -20px rgba(18, 76, 48, .5), inset 0 0 0 2px #3A423C;
  transition: transform .08s linear;
}
.phone::before { /* side thickness */
  content: ""; position: absolute; inset: 0; border-radius: 46px; background: #0F1310;
  transform: translateZ(-16px); box-shadow: 0 0 0 2px #17633D;
}
.phone__screen { position: relative; width: 100%; height: 100%; border-radius: 36px; overflow: hidden; background: var(--background); transform: translateZ(1px); }
.phone__screen img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .45s ease, transform .45s ease; }
.phone__screen img:not(.is-on) { opacity: 0; transform: scale(1.04); }
.phone__glare { position: absolute; inset: 0; border-radius: 36px; pointer-events: none; background: linear-gradient(115deg, rgba(255,255,255,.35) 0%, transparent 32%, transparent 70%, rgba(255,255,255,.12) 100%); transform: translateZ(2px); }
.phone--small { width: 240px; border-radius: 38px; padding: 9px; }
.phone--small::before { border-radius: 38px; }
.phone--small .phone__screen, .phone--small .phone__glare { border-radius: 30px; }

.pod { position: absolute; bottom: 10px; width: 340px; height: 70px; border-radius: 50%; background: var(--highlight); box-shadow: 0 18px 0 #D9BD32, 0 40px 60px rgba(18,76,48,.25); transform: rotateX(70deg) translateZ(-60px); z-index: -1; }

.chip {
  position: absolute; display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: 16px; background: var(--surface); border: 1px solid var(--border);
  box-shadow: 0 16px 40px -12px rgba(18,76,48,.35);
  font-weight: 700; font-size: 14px; white-space: nowrap;
  transform: translateZ(70px);
}
.chip small { display: block; font-weight: 500; color: var(--muted); font-size: 12px; }
.chip i { width: 14px; height: 20px; border-radius: 3px; background: var(--highlight); display: inline-block; border: 1px solid #AD9430; }
.chip b { font-family: var(--display); font-size: 28px; color: var(--accent); }
.chip--a { left: -120px; top: 22%; }
.chip--b { right: -110px; top: 58%; }
.chip--c { left: -70px; bottom: 9%; }

/* ---------- steps ---------- */
.section-head { max-width: 720px; margin-bottom: 56px; }
.section-head h2 { font-size: clamp(44px, 6vw, 84px); }
.section-head p { color: var(--text-2); font-size: 18px; margin: 18px 0 0; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; perspective: 1200px; }
.step {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sheet);
  padding: 28px; transform-style: preserve-3d; transition: transform .25s ease, box-shadow .25s ease;
  box-shadow: 0 10px 0 #CEE2B6;
}
.step:hover { transform: translateY(-6px) rotateX(6deg); box-shadow: 0 16px 0 #CEE2B6; }
.step__n { width: 54px; height: 54px; border-radius: 14px; display: grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 30px; background: var(--highlight); color: var(--on-highlight); margin-bottom: 22px; }
.step h3 { font-size: 38px; margin-bottom: 10px; }
.step p { margin: 0; color: var(--text-2); }

/* ---------- modes (sticky 3D showcase) ---------- */
.modes { padding: 0; }
.modes__track { height: 330vh; position: relative; }
.modes__sticky { position: sticky; top: 0; height: 100vh; display: flex; align-items: center; overflow: hidden; }
.modes__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.mode-list { display: grid; gap: 14px; margin-top: 34px; }
.mode {
  display: grid; grid-template-columns: 88px 1fr; gap: 18px; align-items: center;
  padding: 16px; border-radius: var(--radius-card); background: var(--surface); border: 2px solid var(--border);
  transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease, opacity .3s ease;
  opacity: .6;
}
.mode.is-on { border-color: var(--accent); opacity: 1; transform: translateX(14px); box-shadow: 0 18px 40px -18px rgba(18,76,48,.45); }
.mode__art { width: 88px; height: 64px; border-radius: 12px; background: var(--accent-subtle); display: grid; place-items: center; }
.mode__art svg { width: 76px; height: 52px; }
.mode h3 { font-size: 30px; }
.mode p { margin: 4px 0 0; color: var(--text-2); font-size: 15px; }
.mode .tag { display: inline-block; margin-top: 6px; font-size: 12px; font-weight: 700; color: var(--accent); }

/* ---------- dark band ---------- */
.band { color: #fff; }
.band .eyebrow { color: var(--highlight); }
.band .section-head p { color: #D9E8CC; }
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.feature { padding: 24px; border-radius: var(--radius-sheet); background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.16); backdrop-filter: blur(6px); }
.feature svg { width: 34px; height: 34px; color: var(--highlight); margin-bottom: 16px; }
.feature h3 { font-size: 28px; margin-bottom: 8px; }
.feature p { margin: 0; color: #D9E8CC; font-size: 15px; }

/* ---------- gallery carousel 3D ---------- */
.gallery__ring { position: relative; height: 640px; perspective: 1600px; display: grid; place-items: center; }
.ring { position: relative; width: 240px; height: 533px; transform-style: preserve-3d; will-change: transform; }
.ring .phone { position: absolute; inset: 0; width: 240px; --rx: 0deg; --ry: 0deg; --rz: 0deg; }
.ring .phone::before { display: none; }
.ring .phone { backface-visibility: hidden; -webkit-backface-visibility: hidden; }

/* ---------- score ---------- */
.score__grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: center; }
.render { border-radius: 28px; overflow: hidden; box-shadow: 0 40px 80px -30px rgba(18,76,48,.55); transform: perspective(1200px) rotateY(calc(10deg - var(--local, 0) * 20deg)); transition: transform .1s linear; max-width: 420px; justify-self: center; }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 30px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); padding: 18px; }
.stat b { display: block; font-family: var(--display); font-size: 44px; line-height: 1; color: var(--accent); }
.stat span { color: var(--text-2); font-size: 14px; }

/* ---------- cta ---------- */
.cta { text-align: center; }
.cta__card { position: relative; overflow: hidden; border-radius: 36px; padding: 72px 28px; background: var(--accent-deep); color: #fff; }
.cta__card::before { content: ""; position: absolute; inset: 0; background: url("../assets/banner.jpg") center/cover; opacity: .22; }
.cta__card > * { position: relative; }
.cta__card h2 { font-size: clamp(48px, 7vw, 96px); }
.cta__card p { color: #D9E8CC; font-size: 19px; margin: 18px auto 32px; max-width: 46ch; }
.cta__icon { width: 108px; height: 108px; border-radius: 26px; margin: 0 auto 26px; box-shadow: 0 20px 40px rgba(0,0,0,.3); }

footer { padding: 40px 0 60px; color: var(--text-2); font-size: 14px; }
.footer__row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px; align-items: center; border-top: 1px solid var(--border); padding-top: 28px; }
.footer__links { display: flex; gap: 22px; }
.footer__links a { color: var(--text); font-weight: 600; text-decoration: none; }
.footer__links a:hover { color: var(--accent); text-decoration: underline; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(40px) rotateX(10deg); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .hero__grid, .modes__grid, .score__grid { grid-template-columns: 1fr; }
  .hero { text-align: left; }
  .scene { min-height: 560px; }
  .chip--a { left: -40px; } .chip--b { right: -40px; } .chip--c { left: -20px; }
  .steps { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr 1fr; }
  .modes__track { height: auto; }
  .modes__sticky { position: relative; height: auto; padding: 100px 0; }
  .modes .scene { display: none; }
  .mode { opacity: 1; }
  .gallery__ring { height: 560px; }
}
@media (max-width: 560px) {
  section { padding: 84px 0; }
  .features { grid-template-columns: 1fr; }
  .phone { width: 250px; }
  .chip { font-size: 12px; padding: 9px 12px; }
  .chip--a { left: -16px; } .chip--b { right: -12px; } .chip--c { display: none; }
  .ring, .ring .phone { width: 200px; height: 444px; }
  .stats { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .floaters { display: none; }
}

/* ---------- legal pages ---------- */
.legal { padding: 130px 0 60px; }
.legal__card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sheet); padding: clamp(24px, 5vw, 56px); max-width: 860px; margin-inline: auto; box-shadow: 0 12px 0 #CEE2B6; }
.legal h1 { font-size: clamp(48px, 7vw, 80px); margin-bottom: 8px; }
.legal h2 { font-size: 32px; margin: 36px 0 10px; }
.legal p, .legal li { color: var(--text-2); }
.legal .updated { color: var(--muted); font-size: 14px; margin-bottom: 28px; }
.legal ul { padding-left: 20px; }
