/* Landing CamLive — design system: blu "fiducia" + arancione per le azioni, tema chiaro predefinito */
:root {
  --primary: #2563eb;
  --primary-ink: #ffffff;
  --primary-soft: #e8efff;
  --accent: #ea580c;
  --accent-hover: #c2410c;
  --accent-ink: #111111;
  --bg: #f8fafc;
  --bg-alt: #eef3fa;
  --card: #ffffff;
  --text: #1e293b;
  --muted: #475569;
  --border: #e2e8f0;
  --ring: #2563eb;
  --live: #dc2626;
  --ok: #15803d;
  --shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 8px 24px rgba(15, 23, 42, .06);
  --shadow-lg: 0 24px 60px rgba(15, 23, 42, .16);
  --radius: 16px;
  --space-1: 8px; --space-2: 16px; --space-3: 24px; --space-4: 40px; --space-5: 64px; --space-6: 96px;
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --primary: #60a5fa; --primary-ink: #0b1220; --primary-soft: #14223d;
    --accent: #fb923c; --accent-hover: #fdba74; --accent-ink: #111111;
    --bg: #0b1120; --bg-alt: #0f172a; --card: #131c2e; --text: #e2e8f0; --muted: #a3b1c6; --border: #24324a;
    --ring: #93c5fd; --shadow: 0 1px 2px rgba(0, 0, 0, .3); --shadow-lg: 0 24px 60px rgba(0, 0, 0, .5);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 16px/1.6 var(--font); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg { display: block; max-width: 100%; }
a { color: var(--primary); }
h1, h2, h3 { line-height: 1.15; letter-spacing: -.02em; margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(820px, 100% - 32px); }
.muted { color: var(--muted); }
.small { font-size: 14px; }
:focus-visible { outline: 3px solid var(--ring); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 8px; background: var(--primary); color: var(--primary-ink); text-decoration: none; }
.skip:focus { top: 12px; }

/* Icone (stile linea) */
svg[viewBox="0 0 24 24"] { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
svg .fill { fill: currentColor; stroke: none; }

/* Pulsanti */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 10px 20px; border-radius: 12px;
  font: 650 16px/1.2 var(--font); text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: background-color .2s, color .2s, border-color .2s, transform .2s, box-shadow .2s; }
.btn svg { width: 20px; height: 20px; }
.btn-cta { background: var(--accent); color: var(--accent-ink); box-shadow: 0 6px 18px color-mix(in srgb, var(--accent) 35%, transparent); }
.btn-cta:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-cta:active { transform: translateY(0); }
.btn-ghost { background: var(--card); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }
.btn-lg { min-height: 52px; padding: 14px 24px; font-size: 17px; }
.btn-sm { min-height: 40px; padding: 8px 16px; font-size: 15px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }

/* Navigazione */
.nav { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
.nav.is-scrolled { border-bottom-color: var(--border); box-shadow: 0 4px 20px rgba(15, 23, 42, .05); }
.nav-in { position: relative; display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 16px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; color: var(--text); text-decoration: none; letter-spacing: -.02em; }
.logo-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 5px color-mix(in srgb, var(--live) 18%, transparent); }
.menu { display: flex; align-items: center; gap: 6px; }
.menu a:not(.btn) { padding: 10px 12px; border-radius: 10px; color: var(--muted); text-decoration: none; font-weight: 550; font-size: 15px; transition: color .2s, background-color .2s; }
.menu a:not(.btn):hover { color: var(--text); background: var(--bg-alt); }
.menu .btn { margin-left: 6px; }
.nav-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); color: var(--text); cursor: pointer; place-items: center; }
.nav-toggle svg { width: 22px; height: 22px; }
@media (max-width: 900px) {
  .nav-toggle { display: grid; }
  .menu { position: absolute; left: 0; right: 0; top: 72px; flex-direction: column; align-items: stretch; gap: 2px; padding: 10px;
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg);
    opacity: 0; transform: translateY(-8px); pointer-events: none; visibility: hidden; transition: opacity .2s, transform .2s, visibility .2s; }
  .menu.is-open { opacity: 1; transform: none; pointer-events: auto; visibility: visible; }
  .menu a:not(.btn) { padding: 12px 14px; font-size: 16px; }
  .menu .btn { margin: 8px 0 0; }
}

/* Hero */
.hero { position: relative; isolation: isolate; overflow: hidden; padding: var(--space-5) 0 var(--space-6); }
.hero-bg { position: absolute; inset: -20% -10% auto; height: 120%; z-index: -1;
  background:
    radial-gradient(600px 400px at 85% 20%, color-mix(in srgb, var(--primary) 22%, transparent), transparent 70%),
    radial-gradient(500px 360px at 10% 0%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%); }
.hero-in { display: grid; grid-template-columns: 1.05fr 1fr; gap: var(--space-5); align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; padding: 6px 14px; border-radius: 999px; background: var(--primary-soft); color: var(--primary); font-weight: 650; font-size: 14px; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--live); animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 50%, transparent); } 50% { box-shadow: 0 0 0 6px transparent; } }
.hero h1 { margin-top: var(--space-3); font-size: clamp(36px, 5.2vw, 60px); font-weight: 800; }
.hl { background: linear-gradient(90deg, var(--primary), color-mix(in srgb, var(--primary) 55%, var(--accent))); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { margin-top: var(--space-3); font-size: clamp(17px, 1.6vw, 20px); color: var(--muted); max-width: 36em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: var(--space-4); }
.hero-points { list-style: none; padding: 0; margin: var(--space-4) 0 0; display: grid; gap: 10px; color: var(--muted); font-size: 15px; }
.hero-points li { display: flex; align-items: center; gap: 10px; }
.hero-points svg { width: 20px; height: 20px; color: var(--ok); flex: none; stroke-width: 2.4; }

.hero-visual { position: relative; }
.device { position: relative; border-radius: 18px; background: var(--card); border: 1px solid var(--border); box-shadow: var(--shadow-lg); overflow: hidden; transform: perspective(1400px) rotateY(-6deg) rotateX(2deg); transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.hero-visual:hover .device { transform: perspective(1400px) rotateY(-2deg) rotateX(1deg); }
.device-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--bg-alt); }
.device-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--border); }
.device-bar span { margin-left: 10px; padding: 3px 12px; border-radius: 8px; background: var(--card); color: var(--muted); font-size: 12.5px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.screen { position: relative; aspect-ratio: 16 / 9; background: #0b1220; overflow: hidden; }
.screen iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.screen-fallback { position: absolute; inset: 0; }
.sky { position: absolute; inset: 0 0 42%; background: linear-gradient(180deg, #1e3a8a 0%, #f97316 85%, #fdba74 100%); }
.sea { position: absolute; inset: 58% 0 0; background: linear-gradient(180deg, #1d4ed8, #0b1f4d); }
.sea::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(180deg, rgba(255, 255, 255, .12) 0 2px, transparent 2px 12px); animation: waves 6s linear infinite; }
@keyframes waves { to { background-position: 0 48px; } }
.sun { position: absolute; left: 50%; top: 40%; width: 18%; aspect-ratio: 1; transform: translate(-50%, -20%); border-radius: 50%; background: radial-gradient(circle, #fff7ed, #fdba74 60%, transparent 70%); }
.screen.has-live .screen-fallback, .screen.has-live .chip { display: none; }
.chip { position: absolute; z-index: 2; color: #fff; font-size: 12px; border-radius: 8px; padding: 5px 10px;
  background: rgba(15, 23, 42, .45); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, .2); }
.chip-live { left: 12px; top: 12px; display: inline-flex; align-items: center; gap: 6px; background: var(--live); border-color: transparent; font-weight: 750; letter-spacing: .06em; }
.chip-live i { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: blink 1.6s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.chip-logo { right: 12px; top: 12px; font-weight: 700; }
.chip-sponsor { left: 50%; bottom: 14px; transform: translateX(-50%); white-space: nowrap; font-size: 12.5px; padding: 7px 14px; }
.chip-sponsor b { color: #fdba74; margin-right: 6px; }

.float { position: absolute; z-index: 3; display: flex; gap: 10px; padding: 12px 14px; border-radius: 14px;
  background: color-mix(in srgb, var(--card) 80%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid color-mix(in srgb, var(--border) 70%, transparent); box-shadow: var(--shadow-lg); animation: float 6s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px); } }
.float-stats { left: -28px; bottom: -34px; flex-direction: column; gap: 2px; min-width: 170px; }
.float-label { font-size: 12.5px; color: var(--muted); }
.float-num { font-size: 26px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.spark { width: 140px; height: 32px; }
.spark path { fill: none; stroke: var(--primary); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.float-alert { right: -18px; top: -22px; align-items: center; animation-delay: -3s; }
.float-alert svg { width: 34px; height: 34px; padding: 7px; border-radius: 10px; background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); }
.float-alert span { display: flex; flex-direction: column; font-size: 13.5px; }
.float-alert small { color: var(--muted); font-size: 12px; }
.visual-note { margin-top: 46px; text-align: right; font-size: 12.5px; color: var(--muted); }

@media (max-width: 960px) {
  .hero-in { grid-template-columns: 1fr; }
  .hero { padding-top: var(--space-4); }
  .device { transform: none; }
  .float-stats { left: 8px; bottom: -40px; }
  .float-alert { right: 8px; top: -26px; }
}
@media (max-width: 480px) {
  .float-alert { display: none; }
  .chip-sponsor { font-size: 11px; max-width: 92%; overflow: hidden; text-overflow: ellipsis; }
}

/* Striscia tecnologie */
.strip { border-block: 1px solid var(--border); background: var(--card); }
.strip-in { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 36px; padding: 18px 0; color: var(--muted); font-weight: 650; font-size: 14px; letter-spacing: .03em; }

/* Sezioni */
.section { padding: var(--space-6) 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 720px; margin: 0 auto var(--space-5); text-align: center; }
.kicker { color: var(--primary); font-weight: 750; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; }
.section h2 { margin-top: 10px; font-size: clamp(28px, 3.6vw, 42px); font-weight: 800; }
.sub { margin-top: 16px; color: var(--muted); font-size: 18px; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); }
.step { position: relative; padding: var(--space-4) var(--space-3) var(--space-3); background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.step-n { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--primary); color: var(--primary-ink); font-weight: 800; font-size: 18px; margin-bottom: var(--space-2); }
.step h3, .feature h3, .use h3, .pillar h3 { font-size: 20px; font-weight: 750; }
.step p, .feature p, .use p, .pillar p { margin-top: 8px; color: var(--muted); }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); }
.feature { padding: var(--space-3); background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); transition: transform .25s, box-shadow .25s, border-color .25s, opacity .5s; }
.feature:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--primary) 35%, var(--border)); box-shadow: var(--shadow-lg); }
.ico { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--primary-soft); color: var(--primary); margin-bottom: var(--space-2); }
.ico svg { width: 24px; height: 24px; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-5); align-items: center; }
.split-copy h2 { margin-top: 10px; }
.checks { list-style: none; padding: 0; margin: var(--space-3) 0 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 34px; }
.checks li::before { content: ""; position: absolute; left: 0; top: 2px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--primary-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232563eb' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E") center / 14px no-repeat; }

.report { padding: var(--space-3); background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.report-head { display: flex; justify-content: space-between; align-items: baseline; }
.report-head span { color: var(--muted); font-size: 14px; }
.report-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: var(--space-3); }
.report-kpis div { padding: 12px; border-radius: 12px; background: var(--bg-alt); }
.report-kpis small { color: var(--muted); font-size: 13px; }
.report-kpis strong { display: block; font-size: clamp(18px, 2.4vw, 24px); font-weight: 800; font-variant-numeric: tabular-nums; }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 140px; margin-top: var(--space-3); }
.bars i { flex: 1; height: var(--h); border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, var(--primary), color-mix(in srgb, var(--primary) 50%, transparent)); transform-origin: bottom; }
.report.is-in .bars i { animation: grow .7s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes grow { from { transform: scaleY(0); } }
.report-note { margin-top: 10px; font-size: 12.5px; color: var(--muted); text-align: right; }

.uses { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); }
.use { padding: var(--space-3); border-radius: var(--radius); background: var(--card); border: 1px solid var(--border); }
.use svg { width: 32px; height: 32px; color: var(--accent); margin-bottom: 12px; }

.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); }
.pillar { padding: var(--space-3) 0 0; border-top: 3px solid var(--primary); }

.faq { display: grid; gap: 12px; }
.faq details { background: var(--card); border: 1px solid var(--border); border-radius: 14px; transition: border-color .2s, opacity .5s, transform .5s; }
.faq details[open] { border-color: color-mix(in srgb, var(--primary) 40%, var(--border)); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 56px; padding: 14px 20px; font-weight: 650; font-size: 17px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 10px; height: 10px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg) translateY(-3px); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(-135deg) translateY(-3px); }
.faq details p { padding: 0 20px 18px; color: var(--muted); }

/* Contatti */
.contact { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-alt) 100%); }
.form { position: relative; display: grid; gap: 16px; padding: var(--space-4) var(--space-3); background: var(--card); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow-lg); }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.fld { display: grid; gap: 6px; }
.fld span { font-weight: 650; font-size: 14.5px; }
.fld input, .fld select, .fld textarea { width: 100%; min-height: 48px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border); background: var(--bg); color: var(--text); font: 400 16px/1.4 var(--font); transition: border-color .2s, box-shadow .2s; }
.fld textarea { resize: vertical; min-height: 110px; }
.fld input:focus, .fld select:focus, .fld textarea:focus { outline: none; border-color: var(--ring); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ring) 22%, transparent); }
[aria-invalid="true"] { border-color: var(--live) !important; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; color: var(--muted); }
.consent input { width: 20px; height: 20px; margin-top: 2px; flex: none; accent-color: var(--primary); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-msg { min-height: 1.4em; font-weight: 600; }
.form-msg.ok { color: var(--ok); }
.form-msg.err { color: var(--live); }

/* Footer */
.footer { padding: var(--space-5) 0 var(--space-3); border-top: 1px solid var(--border); background: var(--card); }
.footer-in { display: flex; justify-content: space-between; gap: var(--space-3); flex-wrap: wrap; margin-bottom: var(--space-3); }
.footer-in p { margin-top: 8px; }
.footer nav { display: flex; flex-wrap: wrap; gap: 0 22px; }
.footer nav a { color: var(--muted); text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.footer nav a:hover { color: var(--text); }

/* Comparsa allo scorrimento (solo se JavaScript è attivo) */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s cubic-bezier(.2, .8, .2, 1); }
.js .reveal.is-in { opacity: 1; transform: none; }

@media (max-width: 900px) {
  .steps, .features, .uses, .pillars { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; gap: var(--space-4); }
  .section { padding: var(--space-5) 0; }
}
@media (max-width: 600px) {
  .steps, .features, .uses, .pillars, .row { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; }
  .form { padding: var(--space-3) var(--space-2); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .device, .hero-visual:hover .device { transform: none; }
}
