/* Stessa identità visiva del software reale (public/css/common.css):
   palette ispirata ai colori ufficiali Serie A. Condiviso tra index.html
   e assistenza.html. */
:root {
  --bg: #0a0926;
  --bg-elev: #14124a;
  --bg-elev-2: #1c1a5e;
  --border: #322f78;
  --text: #f5f6fb;
  --text-dim: #a9a6cf;
  --accent: #0578ff;
  --accent-dark: #0032a0;
  --accent-2: #00a346;
  --danger: #db052b;
  --success: #00a346;
  --gold: #f2b705;
  --pitch: #14b8a6;
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  background: radial-gradient(1100px 550px at 50% -10%, #1a1766 0%, transparent 60%), var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}
body::before {
  content: ""; position: fixed; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--accent) 0%, var(--accent-2) 50%, var(--danger) 100%);
  z-index: 1000;
}
a { color: var(--accent); text-decoration: none; }
h1, h2, h3 { margin: 0 0 .5em; font-weight: 800; letter-spacing: -.01em; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* Nav */
header.top { padding: 22px 0; }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; }
.logo { font-weight: 900; font-size: 20px; color: var(--text); display: flex; align-items: center; gap: 9px; }
.logo span { color: var(--accent); }
.logo svg { flex: 0 0 auto; }
nav a { color: var(--text-dim); font-size: 15px; margin-left: 28px; font-weight: 600; }
nav a:hover { color: var(--text); text-decoration: none; }

/* Buttons (identici al software reale) */
.btn {
  display: inline-block; cursor: pointer; font-size: .98rem; font-weight: 800;
  padding: 14px 28px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--bg-elev-2); color: var(--text); transition: transform .08s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn.primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #fff; border-color: var(--accent); box-shadow: 0 6px 20px rgba(5,120,255,.35);
}
.btn.ghost { background: transparent; }

/* Hero */
.hero { padding: 56px 0 24px; text-align: center; }
.hero h1 { font-size: 50px; line-height: 1.1; margin-bottom: 18px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p.sub { font-size: 20px; color: var(--text-dim); max-width: 620px; margin: 0 auto 32px; font-weight: 500; }
.hero .ctas { margin-bottom: 8px; }
.hero .ctas .btn.ghost { margin-left: 12px; }
.hero .microcopy { font-size: 13px; color: var(--text-dim); margin-top: 14px; }

/* Pagina secondaria (assistenza) senza hero grande */
.page-head { padding: 44px 0 8px; text-align: center; }
.page-head h1 { font-size: 36px; margin-bottom: 10px; }
.page-head p { color: var(--text-dim); font-size: 17px; max-width: 560px; margin: 0 auto; }
.back-link { display: inline-block; margin-bottom: 10px; font-size: 14px; font-weight: 600; color: var(--text-dim); }
.back-link:hover { color: var(--text); }

/* Demo animata dal vivo: telefono + schermo condiviso ricreati con lo
   stesso CSS/markup del software reale, sincronizzati via JS. */
.showcase { padding: 40px 0 60px; }
.demo-caption { text-align: center; color: var(--text-dim); font-size: 14px; margin-bottom: 28px; font-weight: 600; }
.demo-caption .dot { display:inline-block; width:8px; height:8px; border-radius:50%; background: var(--success); margin-right:7px; box-shadow: 0 0 0 3px rgba(0,163,70,.25); }
.devices { display: flex; align-items: center; justify-content: center; gap: 56px; flex-wrap: wrap; }

.tv-frame {
  width: 560px; max-width: 90vw; border-radius: 16px; padding: 14px;
  background: linear-gradient(160deg, #26244f, #14132f);
  box-shadow: 0 30px 70px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.04) inset;
}
.tv-screen {
  background: var(--bg); border-radius: 8px; overflow: hidden; position: relative;
  border: 1px solid var(--border); aspect-ratio: 16/10;
  display: flex; flex-direction: column;
}
.tv-stand { width: 90px; height: 10px; background: #14132f; margin: 10px auto 0; border-radius: 0 0 6px 6px; }
.tv-stand::after { content:""; display:block; width:160px; height:6px; background:#0e0d24; margin: 4px auto 0; border-radius: 4px; }

.phone-frame {
  width: 230px; border-radius: 34px; padding: 12px 10px;
  background: linear-gradient(160deg, #26244f, #14132f);
  box-shadow: 0 24px 60px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.04) inset;
}
.phone-notch { width: 70px; height: 16px; background: #14132f; border-radius: 0 0 12px 12px; margin: 0 auto 6px; }
.phone-screen {
  background: var(--bg); border-radius: 22px; overflow: hidden; position: relative;
  border: 1px solid var(--border); aspect-ratio: 9/18.5;
  display: flex; flex-direction: column;
}

.badge {
  display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .68rem;
  font-weight: 800; letter-spacing: .02em; background: var(--bg-elev-2); border: 1px solid var(--border);
}
.badge.ruolo-P { color: var(--gold); border-color: var(--gold); background: rgba(242,183,5,.12); }
.badge.ruolo-D { color: var(--accent); border-color: var(--accent); background: rgba(5,120,255,.12); }
.badge.ruolo-C { color: var(--pitch); border-color: var(--pitch); background: rgba(20,184,166,.12); }
.badge.ruolo-A { color: #ff5c72; border-color: #ff5c72; background: rgba(219,5,43,.12); }

.d-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 12px; border-bottom: 1px solid var(--border); font-size: 11px; font-weight: 800;
}
.d-header .budget { color: var(--accent); background: rgba(5,120,255,.12); border: 1px solid rgba(5,120,255,.4); padding: 2px 9px; border-radius: 999px; font-size: 10px; }

.d-main { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 10px; text-align: center; }
.d-attesa { color: var(--text-dim); font-weight: 700; font-size: 11px; }
.d-nome { font-size: 15px; font-weight: 900; margin: 6px 0 1px; }
.d-squadra { color: var(--text-dim); font-size: 10px; font-weight: 600; margin-bottom: 6px; }
.d-prezzo { font-size: 30px; font-weight: 900; color: var(--accent); line-height: 1; text-shadow: 0 0 20px rgba(5,120,255,.5); }
.d-leader { font-size: 10px; font-weight: 700; margin-top: 4px; color: var(--text-dim); }
.d-leader.vincendo { color: var(--success); }
.d-timer { font-size: 13px; font-weight: 900; margin-top: 3px; font-variant-numeric: tabular-nums; }
.d-timer.urgente { color: var(--danger); }
.d-banner {
  background: linear-gradient(135deg, #17c26a 0%, var(--success) 100%); color: #04220c; font-weight: 900;
  text-align: center; padding: 6px; border-radius: 8px; font-size: 10px; margin: 6px 10px 0;
}
.d-assegnato {
  position: absolute; inset: 0; background: rgba(0,163,70,.94); display: flex; align-items: center;
  justify-content: center; text-align: center; font-weight: 900; font-size: 13px; color: #04220c;
  opacity: 0; transition: opacity .25s ease; padding: 20px;
}
.d-assegnato.show { opacity: 1; }

.d-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 8px 10px 12px; }
.d-buttons button {
  border: 1px solid var(--border); border-radius: 8px; padding: 8px 4px; font-weight: 900;
  font-size: 12px; color: var(--text); background: var(--bg-elev-2);
}
.d-buttons button.attivo.success { background: linear-gradient(135deg, #17c26a 0%, var(--success) 100%); color: #04220c; border-color: var(--success); }
.d-buttons button.attivo.primary { background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%); color: #fff; border-color: var(--accent); }
.d-buttons button:not(.attivo) { opacity: .3; }

.tv-body { flex: 1; display: flex; align-items: center; justify-content: center; gap: 22px; padding: 16px 22px; }
.tv-stage { flex: 2.2; text-align: center; }
.tv-nome { font-size: 22px; font-weight: 900; margin: 6px 0 0; }
.tv-squadra { color: var(--text-dim); font-size: 11px; font-weight: 600; margin-bottom: 6px; }
.tv-prezzo { font-size: 40px; font-weight: 900; color: var(--accent); line-height: 1; text-shadow: 0 0 26px rgba(5,120,255,.55); }
.tv-leader { font-size: 11px; font-weight: 700; margin-top: 6px; color: var(--text-dim); }
.tv-leader.vincendo { color: var(--success); }
.tv-timer { font-size: 15px; font-weight: 900; margin-top: 3px; }
.tv-timer.urgente { color: var(--danger); }
.tv-attesa { color: var(--text-dim); font-weight: 700; font-size: 12px; }
.tv-sidebar { flex: 1; font-size: 10px; }
.tv-sidebar .card { background: rgba(255,255,255,.03); border: 1px solid var(--border); border-radius: 8px; padding: 8px; margin-bottom: 8px; }
.tv-sidebar h4 { margin: 0 0 5px; font-size: 9px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-dim); font-weight: 800; }
.tv-sidebar table { width: 100%; border-collapse: collapse; }
.tv-sidebar td { padding: 2px 0; font-size: 9.5px; border-bottom: 1px solid var(--border); }
.tv-sidebar .feed div { padding: 2px 0; font-size: 9.5px; border-bottom: 1px solid var(--border); }

/* Screenshot reali del software (sezione di prova secondaria, sotto la demo) */
.shots { display: flex; align-items: flex-start; justify-content: center; gap: 28px; flex-wrap: wrap; }
.shot-frame {
  border-radius: 14px; overflow: hidden; background: linear-gradient(160deg, #26244f, #14132f);
  box-shadow: 0 30px 70px rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.04) inset;
  animation: shotIn .6s ease both;
}
.shot-frame.tall { width: 340px; max-width: 90vw; }
.shot-frame.wide { width: 640px; max-width: 90vw; }
.shot-frame.tall { animation-delay: .1s; }
.shot-bar { display: flex; gap: 6px; padding: 10px 12px; }
.shot-bar span { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.18); }
.shot-frame img { display: block; width: 100%; height: auto; background: var(--bg); }
.shot-caption { text-align: center; font-size: 12.5px; color: var(--text-dim); margin-top: 10px; font-weight: 600; }
@keyframes shotIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }

.mini-shot { margin-top: 34px; text-align: center; }
.mini-shot .shot-frame { display: inline-block; width: 640px; max-width: 100%; text-align: left; }

/* Sezioni */
section { padding: 64px 0; }
.section-head { text-align: center; margin-bottom: 42px; }
.section-head h2 { font-size: 30px; }
.section-head p { color: var(--text-dim); font-size: 17px; max-width: 620px; margin: 0 auto; }

.problema { max-width: 700px; margin: 0 auto; font-size: 17px; }
.problema p { margin-bottom: 16px; color: var(--text-dim); }
.problema p strong { color: var(--text); }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.step, .pilastro, .card {
  background: linear-gradient(180deg, var(--bg-elev) 0%, rgba(20,18,74,.6) 100%);
  border: 1px solid var(--border); border-radius: var(--radius); padding: 26px 22px;
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
}
.step .num {
  display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px;
  border-radius: 50%; background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #fff; font-weight: 900; margin-bottom: 16px;
}
.step h3, .pilastro h3 { font-size: 16px; margin-bottom: 8px; }
.step p, .pilastro p { font-size: 14.5px; color: var(--text-dim); margin: 0; }

.pilastri { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }

.prezzo-card { max-width: 440px; margin: 0 auto; text-align: center; border-color: var(--accent); }
.prezzo-card .cifra { font-size: 46px; font-weight: 900; color: var(--text); }
.prezzo-card .cifra span { font-size: 17px; font-weight: 500; color: var(--text-dim); }
.prezzo-card ul { text-align: left; margin: 22px 0; padding: 0; list-style: none; }
.prezzo-card li { padding: 6px 0; font-size: 14.5px; color: var(--text-dim); }
.prezzo-card li::before { content: "✓ "; color: var(--success); font-weight: 900; }
.prezzo-nota { text-align: center; color: var(--text-dim); font-size: 12.5px; margin-top: 14px; }

.garanzia {
  max-width: 440px; margin: 16px auto 0; text-align: center; padding: 18px 22px;
  border-style: dashed; border-color: var(--success); background: rgba(0,163,70,.06);
}
.garanzia h4 { font-size: 14px; margin-bottom: 6px; color: var(--success); }
.garanzia p { font-size: 13.5px; color: var(--text-dim); margin: 0 0 10px; }
.garanzia a.btn { padding: 9px 18px; font-size: 13.5px; }

/* Form assistenza/rimborso */
.form-card { max-width: 560px; margin: 0 auto; }
.form-card form { display: flex; flex-direction: column; gap: 14px; }
.form-card label { font-size: 13px; font-weight: 700; color: var(--text-dim); margin-bottom: -6px; }
.form-card label .req { color: var(--danger); }
.form-card label .facoltativo { font-weight: 500; color: var(--text-dim); text-transform: none; letter-spacing: 0; }
.form-card input[type=email], .form-card input[type=tel], .form-card input[type=text], .form-card textarea {
  width: 100%; background: var(--bg); border: 1px solid var(--border); color: var(--text);
  padding: 11px 13px; border-radius: 8px; font-size: 15px; font-family: inherit;
}
.form-card input:focus, .form-card textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.form-card textarea { min-height: 110px; resize: vertical; }
.form-card .file-field {
  border: 1px dashed var(--border); border-radius: 8px; padding: 14px; background: rgba(255,255,255,.02); font-size: 13.5px;
}
.form-card .file-field input[type=file] { display: block; margin-top: 8px; color: var(--text-dim); font-size: 13px; }
.form-card .hint { font-size: 12.5px; color: var(--text-dim); margin-top: -8px; }
.form-card .hint.obbligatorio { color: var(--gold); }
.form-msg { margin-top: 14px; padding: 10px 14px; border-radius: 8px; font-size: 13.5px; font-weight: 700; display: none; }
.form-msg.ok { display: block; background: rgba(0,163,70,.12); border: 1px solid var(--success); color: var(--success); }
.form-msg.err { display: block; background: rgba(219,5,43,.12); border: 1px solid var(--danger); color: #ff8b9c; }

footer { padding: 40px 0; text-align: center; color: var(--text-dim); font-size: 14px; border-top: 1px solid var(--border); }
footer .foot-links { margin-bottom: 10px; }
footer .foot-links a { margin: 0 10px; color: var(--text-dim); font-weight: 600; font-size: 13.5px; }
footer .foot-links a:hover { color: var(--text); }

@media (max-width: 720px) {
  .hero h1 { font-size: 34px; }
  .hero p.sub { font-size: 17px; }
  .steps, .pilastri { grid-template-columns: 1fr; }
  .shots { gap: 20px; }
  .shot-frame.wide, .shot-frame.tall { width: 100%; }
  .devices { gap: 30px; }
  .tv-frame { display: none; } /* su mobile mostriamo solo il telefono della demo, più leggibile */
}
