/* =========================================================
   Nexa Sports AI — sito pubblico (anteprima)
   Token presi da sport-nexa/src/index.css (tema .dark) + logo SVG.
   ========================================================= */
:root {
  /* Token rilevati dall'app live, 11-nov-2026 */
  --bg-page: #070a14;
  --bg-surface: rgba(18, 22, 38, .72);
  --bg-elevated: rgba(18, 22, 38, .88);
  --text: #f8fafc;
  --muted: #a9b0c6;
  --soft: #8595a6;
  --border: #334155;
  --hairline: rgba(255, 255, 255, .08);
  --brand: #10b981;
  --brand-soft: rgba(16, 185, 129, .16);
  --secondary: #60a5fa;
  --live: #f43f5e;
  --live-strong: #f43f5e;
  --live-soft: rgba(244, 63, 94, .12);
  --live-border: rgba(244, 63, 94, .4);
  --card: rgba(18, 22, 38, .72);
  --card-border: rgba(255, 255, 255, .1);
  --glass: rgba(18, 22, 38, .72);
  --glass-border: rgba(255, 255, 255, .1);
  --glass-fx: saturate(150%) blur(16px);
  --shadow-raised: 0 10px 22px rgba(0, 0, 0, .35);
  --shadow-overlay: 0 16px 32px rgba(2, 6, 23, .5), 0 24px 60px rgba(0, 0, 0, .5);
  /* accenti */
  --lime: #c8ff3d;               /* CTA primaria app */
  --lime-2: #b6ce74;
  --violet: #8b5cf6;             /* bordi / glow / tab attivo */
  --violet-soft: #a78bfa;
  --lavender: #c4b5fd;
  --violet-glow: 0 0 16px -6px rgba(139, 92, 246, .7);
  --aurora: radial-gradient(120% 80% at 50% -10%, rgba(91, 33, 182, .35), transparent 55%);
  --pink: #f06292;
  /* alias usati nel file */
  --logo-green: var(--lime);
  --logo-green-2: var(--lime-2);
  /* momentum */
  --home: #10b981;
  --away: #8b5cf6;
  --amber: #fbbf24;
  /* shape + motion */
  --r-card: .95rem;
  --r-control: .8rem;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-em: cubic-bezier(.2, .8, .2, 1);
  --t-fast: 120ms; --t-mid: 180ms; --t-slow: 280ms;
  --gutter: 16px;
  --maxw: 1200px;
  --nav-h: 64px;
  color-scheme: dark;
}
@media (min-width: 760px) { :root { --gutter: 28px; --nav-h: 72px; } }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--aurora), linear-gradient(180deg, #0a0d1a 0%, var(--bg-page) 40%, #05070f 100%) no-repeat, var(--bg-page); background-size: 100% 100vh, 100% 100%; background-repeat: no-repeat; color: var(--text);
  font-family: 'Rajdhani', system-ui, sans-serif; font-size: 1.05rem; line-height: 1.5; font-weight: 500;
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
.mono, .nexa-score { font-family: 'JetBrains Mono', ui-monospace, monospace; font-feature-settings: "tnum" 1, "lnum" 1; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.ico { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.accent { color: var(--logo-green); }
/* nascosto sopra la pagina (non a sinistra: in RTL un offset orizzontale allarga l'area scorribile), visibile al focus */
.skip { position: fixed; inset-inline-start: 8px; top: 8px; z-index: 100; background: var(--brand); color: #021; padding: 10px 16px; min-height: 44px; display: inline-flex; align-items: center; border-radius: 8px; font-weight: 700; transform: translateY(calc(-100% - 20px)); opacity: 0; }
.skip:focus { transform: none; opacity: 1; }
main:focus { outline: none; }
:focus-visible { outline: 2px solid var(--logo-green); outline-offset: 3px; border-radius: 6px; }

/* ---------- buttons / chips ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  height: 48px; padding: 0 22px; border-radius: 999px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; font-size: .95rem;
  transition: transform var(--t-mid) var(--ease), box-shadow var(--t-slow) var(--ease), background var(--t-mid);
}
.btn--primary {
  background: linear-gradient(135deg, var(--lime), #d9ff7a 55%, var(--lime));
  color: #0b1220; font-weight: 800; box-shadow: 0 6px 18px rgba(200, 255, 61, .35);
}
.btn--primary:hover { box-shadow: 0 0 0 1px rgba(200, 255, 61, .9), 0 10px 34px rgba(200, 255, 61, .5); filter: brightness(1.05); }
.btn--ghost { background: rgba(18, 22, 38, .6); border: 1px solid rgba(139, 92, 246, .5); box-shadow: var(--violet-glow); backdrop-filter: var(--glass-fx); }
.btn--ghost:hover { background: rgba(255, 255, 255, .1); }
.btn--sm { height: 40px; padding: 0 16px; font-size: .85rem; }
.btn--block { width: 100%; }
.btn .ico { width: 1.05em; height: 1.05em; }
.iconbtn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; border: 1px solid var(--glass-border); background: rgba(255, 255, 255, .04); transition: background var(--t-mid); }
.iconbtn:hover { background: rgba(255, 255, 255, .1); }
.iconbtn[aria-pressed="true"] { color: var(--lime); border-color: rgba(139, 92, 246, .55); box-shadow: var(--violet-glow); }
.chipbtn { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--glass-border); background: rgba(255,255,255,.04); font-size: .82rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.chipbtn:hover { color: var(--text); }
.chipbtn .ico { width: 14px; height: 14px; }

.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 18px; font-size: .9rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.ico--live { color: var(--live); }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; flex: none; }
.dot--live { background: var(--live-strong); animation: livedot 1.6s ease-in-out infinite; }
.dot--demo { background: var(--amber); }

/* LIVE chip = NexusMatchCard live chip */
.livechip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; background: var(--live-soft); border: 1px solid var(--live-border); color: var(--live); font-size: .72rem; font-weight: 700; letter-spacing: .16em; }
.livechip__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: livedot 1.6s ease-in-out infinite; }
@keyframes livedot { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .5; transform: scale(.82); } }

/* ========================= INTRO LOGO ========================= */
.intro { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; background: var(--aurora), radial-gradient(40% 40% at 50% 55%, rgba(124, 58, 237, .22), transparent 70%), #070a14; transition: opacity .6s var(--ease), visibility .6s; }
.intro.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
.intro__logo { width: min(300px, 62vw); }
.intro__logo svg { width: 100%; height: auto; overflow: visible; }
.intro .cls-3 { animation: iChev .8s .1s var(--ease-em) both; }
.intro .cls-1 { animation: iTriTop .8s .3s var(--ease-em) both; }
.intro .cls-2 { animation: iTriBot .8s .3s var(--ease-em) both; }
.intro .cls-4, .intro .cls-5, .intro .cls-6 { animation: iText .6s var(--ease) both; animation-delay: calc(.75s + var(--i, 0) * 45ms); }
.intro__logo::after { content: ""; display: block; height: 2px; margin: 26px auto 0; width: 0; background: linear-gradient(90deg, transparent, var(--lime), transparent); animation: iLine .9s 1.1s var(--ease) forwards; }
@keyframes iChev { from { opacity: 0; transform: translateX(-160px); } }
@keyframes iTriTop { from { opacity: 0; transform: translate(120px, -120px); } }
@keyframes iTriBot { from { opacity: 0; transform: translate(120px, 120px); } }
@keyframes iText { from { opacity: 0; transform: translateY(30px); } }
@keyframes iLine { to { width: 100%; } }

/* ========================= NAV ========================= */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; height: var(--nav-h); transition: background var(--t-slow), border-color var(--t-slow), backdrop-filter var(--t-slow); border-bottom: 1px solid transparent; }
.nav.is-scrolled { background: rgba(2, 6, 23, .72); backdrop-filter: var(--glass-fx); -webkit-backdrop-filter: var(--glass-fx); border-bottom-color: var(--hairline); }
.nav__inner { height: 100%; display: flex; align-items: center; gap: 24px; }
.nav__brand { display: inline-flex; align-items: center; min-height: 44px; }
.nav__brand img { height: 26px; width: auto; }
.nav__links { display: none; gap: 4px; margin-left: auto; padding: 4px; border-radius: 999px; background: rgba(18, 22, 38, .72); border: 1px solid var(--glass-border); backdrop-filter: var(--glass-fx); }
.nav__links a { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 16px; border-radius: 999px; font-weight: 700; font-size: .92rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); transition: color var(--t-mid), background var(--t-mid); }
.nav__links a:hover { color: var(--text); }
.nav__links a.is-active { color: #fff; background: linear-gradient(145deg, rgba(124, 58, 237, .55), rgba(76, 29, 149, .6)); box-shadow: 0 0 0 1px rgba(139, 92, 246, .25), 0 0 14px rgba(139, 92, 246, .3); }
.nav__actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.nav__cta { display: none; }
@media (min-width: 960px) {
  .nav__links { display: flex; }
  .nav__actions { margin-left: 0; }
  .nav__cta { display: inline-flex; }
  .nav__burger { display: none; }
  .nav__brand img { height: 29px; }
}

.sheet { position: fixed; inset: 0; z-index: 60; background: rgba(2, 6, 23, .96); backdrop-filter: blur(20px); display: flex; flex-direction: column; animation: sheetIn var(--t-slow) var(--ease); }
.sheet[hidden] { display: none; }
.sheet__top { height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; }
.sheet__links { display: grid; gap: 4px; margin-top: 12px; }
.sheet__links a { display: flex; align-items: center; gap: 14px; padding: 18px 4px; border-bottom: 1px solid var(--hairline); font-size: 1.9rem; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; opacity: 0; transform: translateY(12px); animation: sheetLink .45s var(--ease) forwards; }
.sheet__links a:nth-child(2) { animation-delay: .05s; } .sheet__links a:nth-child(3) { animation-delay: .1s; } .sheet__links a:nth-child(4) { animation-delay: .15s; }
.sheet__links a .ico { margin-left: auto; color: var(--logo-green); }
.sheet__num { font-family: 'JetBrains Mono', monospace; font-size: .8rem; color: var(--soft); width: 2ch; }
.sheet__foot { margin-top: auto; padding-bottom: max(20px, env(safe-area-inset-bottom)); }
@keyframes sheetIn { from { opacity: 0; } }
@keyframes sheetLink { to { opacity: 1; transform: none; } }

/* ========================= HERO ========================= */
.hero { position: relative; min-height: 100svh; display: flex; flex-direction: column; isolation: isolate; overflow: hidden; }
.hero__media { position: absolute; inset: 0; z-index: -1; }
.hero__img, .hero__video { width: 100%; height: 100%; object-fit: cover; object-position: 70% 50%; }
.hero__img { animation: kenburns 26s ease-in-out infinite alternate; transform-origin: 72% 40%; }
.bgvideo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s var(--ease); }
.bgvideo.is-playing { opacity: 1; }
.hero__video { object-position: 70% 50%; }
.ml__video { object-position: 20% 50%; opacity: 0; }
.ml__video.is-playing { opacity: .6; }
@media (max-width: 759px) { .hero__video { object-position: 50% 60%; } }
@keyframes kenburns { from { transform: scale(1.04); } to { transform: scale(1.14) translate3d(-1%, 1%, 0); } }
.hero__shade { position: absolute; inset: 0;
  background:
    radial-gradient(70% 55% at 30% 0%, rgba(124, 58, 237, .38), transparent 70%),
    radial-gradient(45% 40% at 100% 100%, rgba(74, 222, 128, .12), transparent 70%),
    linear-gradient(90deg, rgba(7,10,20,.96) 0%, rgba(7,10,20,.8) 34%, rgba(13,19,51,.2) 70%, rgba(7,10,20,.35) 100%),
    linear-gradient(180deg, rgba(7,10,20,.5) 0%, transparent 22%, transparent 62%, var(--bg-page) 100%); }
.hero__grain { position: absolute; inset: 0; opacity: .18; mix-blend-mode: overlay;
  background-image: radial-gradient(rgba(255,255,255,.35) 1px, transparent 1px); background-size: 3px 3px; }
.hero__beams { position: absolute; inset: -20% -10% 0 30%; mix-blend-mode: screen; pointer-events: none; }
.hero__beams i { position: absolute; top: 0; width: 38%; height: 120%; transform-origin: 50% 0;
  background: linear-gradient(180deg, rgba(186, 230, 253, .28), rgba(96, 165, 250, .08) 45%, transparent 75%);
  clip-path: polygon(46% 0, 54% 0, 100% 100%, 0 100%); filter: blur(6px); animation: beam 9s ease-in-out infinite alternate; }
.hero__beams i:nth-child(1) { left: 48%; transform: rotate(18deg); }
.hero__beams i:nth-child(2) { left: 30%; transform: rotate(8deg); animation-delay: -3s; opacity: .7; }
.hero__beams i:nth-child(3) { left: 62%; transform: rotate(28deg); animation-delay: -6s; background: linear-gradient(180deg, rgba(167, 139, 250, .26), rgba(124, 58, 237, .07) 45%, transparent 75%); }
@keyframes beam { 0% { opacity: .35; translate: 0 0; } 50% { opacity: .9; } 100% { opacity: .5; translate: -4% 0; } }
.hero__pitch { position: absolute; left: 0; right: 0; bottom: 0; height: 46%; width: 100%; fill: none; stroke: rgba(167, 139, 250, .28); stroke-width: 1.2; }
.hero__pitch path, .hero__pitch circle { stroke-dasharray: 2600; stroke-dashoffset: 2600; animation: draw 2.6s .5s var(--ease) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.hero__grid { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: center; padding-top: calc(var(--nav-h) + 28px); padding-bottom: 28px; }
.hero__title { margin: 0; font-weight: 700; text-transform: uppercase; line-height: .9; letter-spacing: -.01em; font-size: clamp(3.1rem, 13vw, 7.6rem); }
.hero__title .line { display: block; }
.hero__title .accent { background: linear-gradient(100deg, #e9ffb0, var(--lime) 35%, #a3e635 60%, var(--lime) 80%, #e9ffb0); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shimmer 6s linear infinite; }
@keyframes shimmer { to { background-position: -220% 0; } }
.hero__lead { margin: 22px 0 0; max-width: 34rem; font-size: clamp(1.1rem, 2.6vw, 1.3rem); color: #cbd5e1; font-weight: 500; }
.br-d { display: none; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.services { list-style: none; padding: 0; margin: 30px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; max-width: 520px; }
.services a { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 14px; border-radius: var(--r-control); background: var(--glass); border: 1px solid var(--glass-border); backdrop-filter: var(--glass-fx); -webkit-backdrop-filter: var(--glass-fx); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; font-size: .92rem; transition: border-color var(--t-mid), transform var(--t-mid) var(--ease); }
.services a:hover { border-color: rgba(139, 92, 246, .7); box-shadow: inset 0 0 0 1px rgba(139, 92, 246, .35), var(--violet-glow); background: rgba(40, 35, 76, .6); }
.services .ico { color: var(--logo-green); }
.services li:first-child .ico { color: var(--live); }
@media (min-width: 560px) { .services { display: flex; flex-wrap: wrap; max-width: none; } .services a { padding: 0 16px; white-space: nowrap; } }

/* phone mockup */
.hero__device { position: relative; justify-self: center; width: min(300px, 80vw); }
.phone { position: relative; aspect-ratio: 9 / 18.6; border-radius: 42px; padding: 10px; background: linear-gradient(160deg, #273449, #0b1222 40%, #1e293b); box-shadow: 0 0 0 1px rgba(255,255,255,.08), var(--shadow-overlay), 0 0 90px rgba(124, 58, 237, .35); }
.phone__notch { position: absolute; top: 18px; left: 50%; width: 84px; height: 22px; translate: -50% 0; border-radius: 999px; background: #000; z-index: 2; }
.phone__screen { position: relative; height: 100%; border-radius: 33px; overflow: hidden; background: var(--aurora), linear-gradient(180deg, #0a0d1a, #070a14 40%, #05070f); padding: 46px 12px 12px; display: flex; flex-direction: column; gap: 10px; }
.app-top { display: flex; align-items: center; gap: 8px; }
.app-top__title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; font-size: 1.15rem; letter-spacing: .02em; }
.demo-tag { margin-left: auto; font-size: .6rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--amber); border: 1px solid rgba(251, 191, 36, .4); background: rgba(251, 191, 36, .1); padding: 2px 7px; border-radius: 999px; }
.app-tabs { display: flex; gap: 6px; font-size: .74rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--soft); }
.app-tabs span { padding: 5px 10px; border-radius: 999px; background: rgba(255,255,255,.04); }
.app-tabs .is-on { color: #fff; background: linear-gradient(145deg, rgba(124, 58, 237, .55), rgba(76, 29, 149, .6)); box-shadow: 0 0 10px rgba(139, 92, 246, .35); }
.app-tabs b { color: var(--live); margin-left: 3px; }
.app-league { font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--soft); padding: 2px 2px 0; }
.app-list { display: grid; gap: 7px; }

/* NexusMatchCard */
.mcard { position: relative; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 6px; padding: 10px 10px 9px; border-radius: .75rem; background: var(--card); border: 1px solid var(--card-border); transition: transform var(--t-mid) var(--ease), box-shadow var(--t-slow); }
.mcard.is-live { box-shadow: inset 0 0 0 1px var(--live-border); }
.mcard__meta { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; margin-bottom: 2px; }
.mcard__live { display: inline-flex; align-items: center; gap: 4px; font-size: 9px; font-weight: 800; letter-spacing: .16em; color: var(--live); background: var(--live-soft); border: 1px solid var(--live-border); padding: 1px 6px; border-radius: 999px; }
.mcard__live i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; animation: livedot 1.6s ease-in-out infinite; }
.mcard__min { font: 700 11px 'JetBrains Mono', monospace; color: var(--live); }
.mcard__team { display: flex; align-items: center; gap: 6px; min-width: 0; font-weight: 700; font-size: .82rem; }
.mcard__team span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mcard__team--away { flex-direction: row-reverse; text-align: right; }
.mcard__score { font: 800 1.2rem 'JetBrains Mono', monospace; letter-spacing: -.02em; color: var(--live); padding: 0 4px; }
.mcard.is-ft .mcard__score { color: var(--text); }
.mcard.is-ft .mcard__live { color: var(--soft); background: rgba(255,255,255,.05); border-color: var(--hairline); }
.mcard.is-ft .mcard__live i { display: none; }
.mcard.flash { animation: cardflash 1.4s var(--ease); }
@keyframes cardflash { 0% { box-shadow: inset 0 0 0 1px var(--live-border), 0 0 0 0 rgba(239, 68, 68, .55); transform: scale(1.02); } 100% { box-shadow: inset 0 0 0 1px var(--live-border), 0 0 0 14px rgba(239, 68, 68, 0); transform: none; } }

.crest { --c1: #3b1c74; --c2: #6a28e5; width: 22px; height: 22px; flex: none; border-radius: 50%; display: grid; place-items: center; font: 700 8.5px 'JetBrains Mono', monospace; color: #fff; background: linear-gradient(135deg, var(--c1), var(--c2)); box-shadow: inset 0 0 0 1px rgba(255,255,255,.18); }

.float-card { position: absolute; display: grid; gap: 4px; padding: 10px 12px; border-radius: 14px; background: rgba(18, 22, 38, .78); border: 1px solid var(--glass-border); backdrop-filter: var(--glass-fx); -webkit-backdrop-filter: var(--glass-fx); box-shadow: var(--shadow-raised); }
.float-card__k { font-size: .62rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--soft); }
.float-card__v { font-weight: 700; font-size: .95rem; }
.float-card--goal { left: -28px; top: 34%; border-color: var(--live-border); opacity: 0; transform: translateX(-10px) scale(.96); transition: opacity var(--t-slow), transform var(--t-slow) var(--ease); }
.float-card--goal .float-card__k { color: var(--live); }
.float-card--goal.show { opacity: 1; transform: none; }
.float-card--mom { right: -30px; bottom: 16%; width: 150px; animation: floaty 6s ease-in-out infinite; }
.mini-mom { width: 100%; height: 34px; }
@keyframes floaty { 50% { transform: translateY(-8px); } }

/* ticker */
.ticker { position: relative; display: flex; align-items: center; height: 46px; border-top: 1px solid var(--hairline); background: rgba(2, 6, 23, .7); backdrop-filter: blur(10px); }
.ticker__label { flex: none; height: 100%; display: grid; place-items: center; padding: 0 14px; font-size: .68rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--amber); border-right: 1px solid var(--hairline); }
.ticker__viewport { overflow: hidden; flex: 1; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.ticker__track { display: flex; width: max-content; animation: marquee 40s linear infinite; }
.ticker__item { display: inline-flex; align-items: center; gap: 10px; padding: 0 22px; font-weight: 700; font-size: .92rem; white-space: nowrap; border-right: 1px solid var(--hairline); }
.ticker__item .mono { color: var(--live); font-weight: 700; }
.ticker__item .t-min { font: 600 .75rem 'JetBrains Mono', monospace; color: var(--soft); }
@keyframes marquee { to { transform: translateX(-50%); } }

@media (min-width: 760px) {
  .br-d { display: inline; }
}
@media (min-width: 960px) {
  .hero__grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 32px; }
  .hero__device { width: 310px; justify-self: end; margin-right: 40px; }
}
@media (max-width: 759px) {
  .hero__grid { gap: 28px; padding-top: calc(var(--nav-h) + 18px); }
  .eyebrow { font-size: .74rem; letter-spacing: .14em; margin-bottom: 14px; }
  .hero__lead { margin-top: 16px; font-size: 1.08rem; line-height: 1.45; }
  .hero__ctas { margin-top: 22px; gap: 10px; }
  .hero__ctas .btn { height: 46px; padding: 0 16px; font-size: .84rem; flex: 1 1 auto; }
  .services { display: flex; overflow-x: auto; scrollbar-width: none; margin: 16px calc(var(--gutter) * -1) 0; padding: 6px var(--gutter) 8px; max-width: none; gap: 8px; }
  .services::-webkit-scrollbar { display: none; }
  .services li { flex: none; }
  .services a { height: 40px; font-size: .84rem; padding: 0 14px; border-radius: 999px; }
  .hero__img { object-position: 50% 60%; }
  .hero__shade { background: linear-gradient(180deg, rgba(2,6,23,.7) 0%, rgba(2,6,23,.55) 38%, rgba(2,6,23,.55) 62%, var(--bg-page) 100%); }
  .hero__beams { inset: 10% -40% 0 -10%; }
  .hero__device { width: min(270px, 74vw); margin-top: 8px; }
  .float-card--goal { left: -14px; }
  .float-card--mom { right: -14px; width: 128px; }
}

/* reveal on load / scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .8s var(--ease), transform .9s var(--ease); transition-delay: calc(var(--d, 0) * 90ms); }
.reveal.in { opacity: 1; transform: none; }

/* ========================= MATCH LIVE ========================= */
.ml { position: relative; padding: 96px 0 88px; isolation: isolate; }
.ml__band { position: absolute; inset: 0 0 auto; height: 620px; z-index: -1; overflow: hidden; -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 55%, transparent 100%); mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 55%, transparent 100%); }
.ml__band img { width: 100%; height: 100%; object-fit: cover; object-position: 20% 50%; opacity: .55; transform: translateY(var(--py, 0)); }
.ml__band::after { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 60% at 80% 30%, rgba(91, 33, 182, .3), transparent 70%), linear-gradient(180deg, var(--bg-page) 0%, rgba(7,10,20,.35) 30%, rgba(7,10,20,.6) 65%, var(--bg-page) 100%), linear-gradient(90deg, rgba(7,10,20,.1), rgba(7,10,20,.85) 70%); }
.sec-head { display: grid; gap: 8px; margin-bottom: 40px; }
.sec-head__num { font: 700 .9rem 'JetBrains Mono', monospace; color: var(--logo-green); }
.sec-title { margin: 0; font-size: clamp(2.3rem, 7vw, 4.6rem); line-height: .95; font-weight: 700; text-transform: uppercase; letter-spacing: -.005em; }
.sec-lead { margin: 18px 0 0; max-width: 38rem; color: #cbd5e1; font-size: 1.15rem; }
@media (min-width: 960px) {
  .sec-head { grid-template-columns: 80px 1fr; margin-left: auto; max-width: 760px; }
  .sec-head__num { padding-top: 8px; }
}

.console { position: relative; border-radius: 24px; padding: 12px; background: radial-gradient(120% 90% at 0% 0%, rgba(139, 92, 246, .18), transparent 60%), radial-gradient(120% 90% at 100% 100%, rgba(56, 189, 248, .1), transparent 60%), rgba(11, 12, 32, .92); border: 1px solid rgba(139, 92, 246, .35); backdrop-filter: var(--glass-fx); -webkit-backdrop-filter: var(--glass-fx); box-shadow: var(--shadow-overlay), 0 0 60px -20px rgba(139, 92, 246, .6); }
.console__bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 4px 6px 12px; }
.demo-note { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--amber); }
.console__grid { display: grid; gap: 12px; }
@media (min-width: 960px) { .console { padding: 16px; } .console__grid { grid-template-columns: 320px 1fr; } }

.console__list { border-radius: 18px; background: rgba(2, 6, 23, .55); border: 1px solid var(--hairline); padding: 10px; }
.list-head { display: flex; justify-content: space-between; padding: 4px 6px 10px; font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--soft); }
.list-head .mono { color: var(--live); }
.match-list { display: grid; gap: 8px; }
.match-list .mcard { cursor: pointer; text-align: left; width: 100%; }
.match-list .mcard:hover { box-shadow: inset 0 0 0 1px rgba(196, 181, 253, .45); }
.match-list .mcard[aria-selected="true"], .match-list .mcard[aria-selected="true"].is-live { box-shadow: inset 0 0 0 1px rgba(196, 181, 253, .6), 0 0 16px -4px rgba(139, 92, 246, .7); background: rgba(40, 35, 76, .76); }
@media (max-width: 959px) {
  .match-list { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 8px; padding: 4px 2px 6px; scrollbar-width: none; }
  .match-list::-webkit-scrollbar { display: none; }
  .match-list .mcard { flex: 0 0 78%; scroll-snap-align: start; }
}

.detail { position: relative; border-radius: 18px; background: rgba(2, 6, 23, .55); border: 1px solid var(--hairline); overflow: hidden; min-width: 0; }
.detail__head { position: relative; padding: 18px 14px 16px; background: radial-gradient(70% 140% at 50% -40%, rgba(124, 58, 237, .4), transparent 70%), linear-gradient(180deg, #131c2f, rgba(15, 23, 42, .4)); border-bottom: 1px solid var(--hairline); }
.detail__league { text-align: center; font-size: .72rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--soft); margin-bottom: 12px; }
.detail__score { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; }
.team { display: grid; justify-items: center; gap: 8px; text-align: center; min-width: 0; }
.team .crest { width: 52px; height: 52px; font-size: 14px; }
.team__name { font-weight: 700; font-size: 1rem; line-height: 1.1; text-transform: uppercase; letter-spacing: .02em; overflow-wrap: anywhere; }
.scorebox { display: grid; justify-items: center; gap: 8px; }
.scorebox__score { font-weight: 800; font-size: clamp(2.2rem, 9vw, 3.6rem); line-height: 1; letter-spacing: -.04em; padding: 6px 14px; border-radius: var(--r-control); border: 1px solid var(--hairline); background: rgba(255,255,255,.03); color: var(--text); transition: color var(--t-slow), text-shadow var(--t-slow), transform var(--t-slow) var(--ease); }
.scorebox__score.goal { color: var(--live); text-shadow: 0 0 22px rgba(239, 68, 68, .7); transform: scale(1.06); }
.scorebox__meta { display: flex; align-items: center; gap: 8px; }
.livepill { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 9px; border-radius: 999px; background: var(--live-soft); border: 1px solid var(--live-border); color: var(--live); font-size: 10px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.livepill__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: pillpulse 1.8s ease-out infinite; }
@keyframes pillpulse { 0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, .38); } 100% { box-shadow: 0 0 0 8px rgba(239, 68, 68, 0); } }
.livepill.is-ft { color: var(--soft); background: rgba(255,255,255,.05); border-color: var(--hairline); }
.livepill.is-ft .livepill__dot { display: none; }
.minute { font-weight: 700; color: var(--live); font-size: .95rem; min-width: 4ch; }
.goal-flash { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; opacity: 0; }
.goal-flash span { font-weight: 700; font-size: clamp(3rem, 14vw, 6rem); letter-spacing: .2em; color: var(--live); text-shadow: 0 0 40px rgba(239, 68, 68, .8); }
.goal-flash.go { animation: goalflash 1.6s var(--ease-em); }
@keyframes goalflash { 0% { opacity: 0; transform: scale(.7); } 18% { opacity: 1; transform: scale(1.05); } 60% { opacity: .9; } 100% { opacity: 0; transform: scale(1.25); } }
.goal-flash.go ~ * { }

.tabs { display: flex; gap: 4px; padding: 8px; border-bottom: 1px solid var(--hairline); overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 999px; font-size: .82rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--soft); transition: color var(--t-mid), background var(--t-mid); }
.tabs button .ico { width: 14px; height: 14px; }
.tabs button[aria-selected="true"] { color: #fff; background: linear-gradient(145deg, rgba(124, 58, 237, .55), rgba(76, 29, 149, .6)); box-shadow: 0 0 0 1px rgba(139, 92, 246, .25), 0 0 14px rgba(139, 92, 246, .3); }
.tabs button:not([aria-selected="true"]):hover { color: var(--text); background: rgba(255,255,255,.06); }

.panes { position: relative; min-height: 340px; }
.pane { display: none; padding: 14px; animation: paneIn .35s var(--ease); }
.pane.is-on { display: block; }
@keyframes paneIn { from { opacity: 0; transform: translateY(6px); } }

/* timeline (MatchDetailKeyEvents) */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; max-height: 360px; overflow: auto; }
.ev { display: grid; grid-template-columns: 1fr 52px 1fr; align-items: center; gap: 8px; animation: evIn .5s var(--ease); }
.ev__pill { justify-self: center; font: 700 .78rem 'JetBrains Mono', monospace; padding: 4px 8px; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid var(--hairline); color: var(--muted); }
.ev__body { display: flex; align-items: center; gap: 8px; padding: 9px 11px; border-radius: 12px; background: var(--card); border: 1px solid var(--card-border); font-weight: 600; font-size: .95rem; min-width: 0; }
.ev__body small { display: block; color: var(--soft); font-size: .78rem; font-weight: 600; }
.ev--away .ev__body { grid-column: 3; }
.ev--home .ev__body { grid-column: 1; flex-direction: row-reverse; text-align: right; }
.ev--away .ev__pill { grid-column: 2; grid-row: 1; }
.ev--home .ev__pill { grid-column: 2; grid-row: 1; }
.ev__icon { flex: none; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 6px; font-size: 12px; }
.ev__icon--goal { background: rgba(34, 197, 94, .18); color: var(--brand); }
.ev__icon--goal::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: currentColor; box-shadow: 0 0 10px currentColor; }
.ev__icon--yellow::before { content: ""; width: 9px; height: 12px; border-radius: 2px; background: #facc15; }
.ev__icon--red::before { content: ""; width: 9px; height: 12px; border-radius: 2px; background: #ef4444; }
.ev__icon--sub { color: var(--secondary); background: rgba(96, 165, 250, .14); }
.ev__icon--sub::before { content: "⇄"; font-weight: 700; }
.ev__icon--save { color: var(--violet); background: rgba(167, 139, 250, .14); }
.ev__icon--save::before { content: ""; width: 10px; height: 10px; border: 2px solid currentColor; border-radius: 3px; }
.ev.is-new .ev__body { box-shadow: 0 0 0 1px rgba(220, 38, 38, .45), 0 6px 18px rgba(220, 38, 38, .2); }
.ev--goal.is-new .ev__body { box-shadow: 0 0 0 1px rgba(34, 197, 94, .55), 0 6px 18px rgba(34, 197, 94, .25); }
@media (max-width: 640px) {
  .ev, .ev--home, .ev--away { grid-template-columns: 46px 1fr; gap: 8px; }
  .ev .ev__pill, .ev--home .ev__pill, .ev--away .ev__pill { grid-column: 1; grid-row: 1; }
  .ev .ev__body, .ev--home .ev__body, .ev--away .ev__body { grid-column: 2; flex-direction: row; text-align: left; }
  .ev--home .ev__body { border-left: 3px solid var(--home); }
  .ev--away .ev__body { border-left: 3px solid var(--away); }
  .console__bar { flex-wrap: wrap; }
  .demo-note { font-size: .7rem; letter-spacing: .08em; }
  .pane { padding: 10px; }
}
.ev-empty { color: var(--soft); text-align: center; padding: 30px 0; font-weight: 600; }
@keyframes evIn { from { opacity: 0; transform: translateY(-8px) scale(.98); } }
.ev--sep { display: flex; align-items: center; gap: 10px; color: var(--soft); font-size: .72rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
.ev--sep::before, .ev--sep::after { content: ""; flex: 1; height: 1px; background: var(--hairline); }

/* momentum */
.mom { border-radius: 16px; padding: 12px; background: linear-gradient(180deg, #131c2f, #0f172a); border: 1px solid var(--hairline); box-shadow: 0 10px 28px rgba(0,0,0,.3); }
.mom__legend { display: flex; justify-content: space-between; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 10px; }
.mom__legend span { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.sw--home { background: var(--home); } .sw--away { background: var(--away); }
.mom__plot { position: relative; }
.mom__chart { width: 100%; height: 200px; }
.mom__goal { position: absolute; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: #fff; border: 3px solid var(--home); box-shadow: 0 0 10px rgba(255,255,255,.4); }
.mom__goal--away { border-color: var(--away); }
.mom__axis { display: flex; justify-content: space-between; font-size: .7rem; color: var(--soft); margin-top: 6px; }
.mbar { transform-box: fill-box; transform-origin: 50% 100%; animation: barRise 280ms var(--ease) both; }
.mbar--away { transform-origin: 50% 0; }
@keyframes barRise { from { transform: scaleY(0); } }

/* stats — tre colonne stabili: valore CASA (estremità sinistra) · nome statistica (centro) · valore TRASFERTA (estremità destra);
   barre sotto, casa a sinistra e trasferta a destra. Il blocco è sempre LTR (anche in arabo); le etichette hanno la loro direzione. */
.stats-legend { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin: 2px 2px 14px; direction: ltr; }
.lg { display: inline-flex; align-items: center; gap: 8px; min-width: 0; font-weight: 700; font-size: .9rem; line-height: 1.15; }
.lg > span { display: grid; min-width: 0; }
.lg b { overflow-wrap: anywhere; }
.lg small { font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--soft); }
.lg--away { text-align: right; }
.sw--pattern { background: repeating-linear-gradient(135deg, var(--away) 0 3px, rgba(255,255,255,.55) 3px 4.5px); }
.stats { list-style: none; margin: 0; padding: 4px 2px; display: grid; gap: 16px; direction: ltr; }
.stat { display: grid; grid-template-columns: minmax(3.6ch, max-content) minmax(0, 1fr) minmax(3.6ch, max-content); grid-template-areas: "home label away" "bar bar bar"; column-gap: 12px; row-gap: 7px; align-items: center; }
.stat__v { font: 700 1rem 'JetBrains Mono', monospace; font-feature-settings: "tnum" 1, "lnum" 1; white-space: nowrap; }
.stat__v--home { grid-area: home; justify-self: start; text-align: left; color: #6ee7b7; }
.stat__v--away { grid-area: away; justify-self: end; text-align: right; color: var(--lavender); }
.stat__v.is-missing { color: var(--soft); font-weight: 600; }
.stat__label { grid-area: label; text-align: center; font-size: .82rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); overflow-wrap: anywhere; line-height: 1.2; }
.stat__bar { grid-area: bar; display: grid; grid-template-columns: 1fr 1fr; gap: 4px; height: 8px; }
.stat__half { display: block; height: 100%; border-radius: 999px; background: rgba(255,255,255,.07); position: relative; overflow: hidden; }
.stat__half b { position: absolute; top: 0; bottom: 0; border-radius: inherit; transition: width .7s var(--ease); }
.stat__half--home b { right: 0; background: var(--home); }
.stat__half--away b { left: 0; background: repeating-linear-gradient(135deg, var(--away) 0 5px, #a78bfa 5px 7px); }
.stat--nobar .stat__half { background: repeating-linear-gradient(90deg, rgba(255,255,255,.07) 0 4px, transparent 4px 8px); }

/* lineup */
.lineup { display: grid; place-items: center; }
.lineup__pitch { width: 100%; max-width: 300px; height: auto; border-radius: 14px; background: repeating-linear-gradient(180deg, #0e3d22 0 42px, #0c351e 42px 84px); }
.lineup__pitch .lines { fill: none; stroke: rgba(255,255,255,.25); stroke-width: 1.5; }
.pl circle { stroke: rgba(255,255,255,.7); stroke-width: 1.5; }
.pl text { font: 700 10px 'JetBrains Mono', monospace; fill: #fff; text-anchor: middle; dominant-baseline: central; }
.pl { opacity: 0; animation: plIn .5s var(--ease) forwards; }
@keyframes plIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.feats { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 12px; }
@media (min-width: 760px) { .feats { grid-template-columns: repeat(3, 1fr); } }
.feat { padding: 20px; border-radius: 16px; background: var(--bg-surface); border: 1px solid var(--glass-border); box-shadow: var(--shadow-raised); backdrop-filter: var(--glass-fx); }
.feat .ico { width: 22px; height: 22px; color: var(--logo-green); }
.feat h3 { margin: 12px 0 6px; font-size: 1.3rem; text-transform: uppercase; letter-spacing: .02em; }
.feat p { margin: 0; color: var(--muted); }

.foot { border-top: 1px solid var(--hairline); padding: 28px 0 calc(28px + env(safe-area-inset-bottom)); }
.foot__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
.foot__inner img { height: 22px; width: auto; }
.foot p { margin: 0; color: var(--soft); font-size: .92rem; }

/* ========================= MOVIMENTO RIDOTTO ========================= */
@media (prefers-reduced-motion: reduce) {
  html[data-motion="auto"] { scroll-behavior: auto; }
  html[data-motion="auto"] *, html[data-motion="auto"] *::before, html[data-motion="auto"] *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  html[data-motion="auto"] .hero__beams, html[data-motion="auto"] .hero__grain { display: none; }
  html[data-motion="auto"] .ticker__track { animation: none !important; }
  html[data-motion="auto"] .ticker__viewport { overflow-x: auto; }
}
html[data-motion="reduced"] { scroll-behavior: auto; }
html[data-motion="reduced"] *, html[data-motion="reduced"] *::before, html[data-motion="reduced"] *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
html[data-motion="reduced"] .hero__beams, html[data-motion="reduced"] .hero__grain { display: none; }
html[data-motion="reduced"] .ticker__track { animation: none !important; }
html[data-motion="reduced"] .ticker__viewport { overflow-x: auto; }

/* Schermi molto ampi: scala l'intero sistema (tutto è in rem) e allarga il contenitore */
@media (min-width: 1700px) { html { font-size: 18px; } :root { --maxw: 1360px; } }
@media (min-width: 2200px) { html { font-size: 21px; } :root { --maxw: 1560px; } }
