/* ============================================================
   Luca Olovrap — Consulente SEO & GEO
   Design system v1 — Inter, blu/blu scuro, radius ≤ 20px
   ============================================================ */

:root {
  /* Colori principali */
  --blue-700: #1d4ed8;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --blue-300: #7fb0ff;
  --blue-100: rgba(127, 176, 255, 0.28);
  --blue-50: rgba(59, 130, 246, 0.14);

  --navy-950: #060f1f;
  --navy-900: #081527;
  --navy-800: #0a1b33;
  --navy-700: #10263f;
  --navy-600: #16324f;

  --ink: #e8eef7;
  --ink-2: #a9bcd6;
  --ink-3: #7f95b0;

  --bg: #060f1f;
  --bg-soft: #09172b;
  --surface: #0c1e38;
  --surface-2: #122a49;
  --border: #1a3353;
  --border-strong: #2a4a73;

  /* Stati */
  --green: #4ade80;
  --green-bg: rgba(74, 222, 128, 0.12);
  --amber: #fbbf24;
  --amber-bg: rgba(251, 191, 36, 0.12);
  --red: #f87171;
  --red-bg: rgba(248, 113, 113, 0.12);
  --violet: #c4b5fd;
  --violet-bg: rgba(196, 181, 253, 0.12);
  --cyan: #67e8f9;
  --cyan-bg: rgba(103, 232, 249, 0.12);

  /* Radius (mai oltre 20px) */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 20px;

  /* Ombre */
  --shadow-sm: 0 1px 2px rgba(2, 6, 14, 0.4), 0 1px 3px rgba(2, 6, 14, 0.35);
  --shadow-md: 0 8px 24px rgba(2, 6, 14, 0.45);
  --shadow-lg: 0 20px 48px rgba(2, 6, 14, 0.55);

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --maxw: 1200px;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }

a { color: var(--blue-300); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--ink);
}

h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }
p { margin: 0 0 1em; }

:focus-visible {
  outline: 3px solid var(--blue-500);
  outline-offset: 2px;
  border-radius: 4px;
}

::selection { background: var(--blue-100); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

section { scroll-margin-top: 88px; }

.section { padding: 96px 0; }
.section--soft { background: var(--bg-soft); }
.section--dark {
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(37, 99, 235, 0.22), transparent 60%),
    radial-gradient(700px 420px at 5% 110%, rgba(37, 99, 235, 0.14), transparent 55%),
    var(--navy-900);
  color: #dce6f5;
}
.section--dark h2, .section--dark h3 { color: #ffffff; }

.section-head { max-width: 760px; margin-bottom: 48px; }
.section-head h2::before {
  content: "";
  display: block;
  width: 38px; height: 4px;
  background: linear-gradient(90deg, var(--blue-500), var(--blue-300));
  border-radius: 3px;
  margin-bottom: 18px;
}
.section-head .eyebrow { margin-bottom: 14px; }
.section-head p.lead { font-size: 1.15rem; color: var(--ink-2); margin: 0; }
.section--dark .section-head p.lead { color: #a8bcd6; }

/* ---------- Eyebrow / badge / chip ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blue-300);
}
.eyebrow::before {
  content: "";
  width: 22px; height: 2px;
  background: var(--blue-500);
  border-radius: 2px;
}
.section--dark .eyebrow { color: var(--blue-500); }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--r-sm);
  background: var(--blue-50);
  color: var(--blue-700);
  border: 1px solid var(--blue-100);
}
.badge .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--amber);
  flex: none;
}
.badge--dark {
  background: rgba(37, 99, 235, 0.12);
  border-color: rgba(59, 130, 246, 0.35);
  color: #bcd3fb;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--r-sm);
  white-space: nowrap;
}
.chip--blue   { background: var(--blue-50);   color: #a9c6f8; }
.chip--green  { background: var(--green-bg);  color: var(--green); }
.chip--amber  { background: var(--amber-bg);  color: var(--amber); }
.chip--red    { background: var(--red-bg);    color: var(--red); }
.chip--violet { background: var(--violet-bg); color: var(--violet); }
.chip--cyan   { background: var(--cyan-bg);   color: var(--cyan); }
.chip--grey   { background: var(--surface-2); color: var(--ink-2); }

/* ---------- Bottoni ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 26px;
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  border-radius: var(--r-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
  text-decoration: none;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background: var(--blue-600);
  color: #fff;
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.35);
}
.btn--primary:hover { background: var(--blue-700); box-shadow: 0 12px 28px rgba(37, 99, 235, 0.45); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--border-strong);
}
.btn--ghost:hover { border-color: var(--blue-500); color: var(--blue-600); }

.btn--light {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.22);
}
.btn--light:hover { background: rgba(255, 255, 255, 0.16); }

.btn--sm { padding: 10px 18px; font-size: 16px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: rgba(6, 15, 31, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 36px; height: 36px;
  border-radius: var(--r-sm);
  background: linear-gradient(135deg, var(--blue-600), var(--navy-800));
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 16px;
  font-weight: 800;
  flex: none;
}
.main-nav { display: flex; align-items: center; gap: 6px; }
.main-nav a {
  padding: 9px 14px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-2);
  border-radius: var(--r-sm);
  transition: color 0.15s ease, background 0.15s ease;
}
.main-nav a:hover { color: var(--blue-300); background: var(--blue-50); text-decoration: none; }
.main-nav .nav-cta { display: none; }
.header-cta { display: flex; align-items: center; gap: 12px; }

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  background: var(--surface);
  cursor: pointer;
  padding: 10px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--ink);
  margin: 5px 0;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 168px 0 104px;
  background:
    radial-gradient(1000px 560px at 88% -12%, rgba(37, 99, 235, 0.28), transparent 60%),
    radial-gradient(760px 480px at -5% 108%, rgba(37, 99, 235, 0.16), transparent 55%),
    linear-gradient(180deg, var(--navy-900), var(--navy-800));
  color: #dce6f5;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(120, 160, 220, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(120, 160, 220, 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, #000 30%, transparent 75%);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 64px;
  align-items: center;
}
.hero h1 { color: #fff; margin-bottom: 20px; }
.hero h1 .accent {
  background: linear-gradient(100deg, #7fb0ff, #3b82f6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero .lead {
  font-size: 1.2rem;
  color: #b3c5dd;
  max-width: 560px;
  margin-bottom: 28px;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  padding: 11px 18px;
  border: 1px solid rgba(127, 176, 255, 0.45);
  border-radius: var(--r-sm);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.22), rgba(37, 99, 235, 0.08));
  box-shadow: 0 0 24px rgba(37, 99, 235, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #bcd3fb;
}
.hero-eyebrow .he-sep { opacity: 0.55; font-weight: 500; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 26px; }
.hero-availability {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  max-width: 520px;
  padding: 14px 18px;
  border: 1px solid rgba(217, 119, 6, 0.35);
  background: rgba(217, 119, 6, 0.08);
  border-radius: var(--r-md);
  font-size: 16px;
  color: #e8d3ae;
}
.hero-availability .dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--amber);
  margin-top: 7px;
  flex: none;
  box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.18);
}
.hero-availability strong { color: #f5e3bd; }

.hero-portrait {
  position: relative;
  border-radius: var(--r-xl);
  border: 1px dashed rgba(158, 190, 240, 0.45);
  background:
    radial-gradient(240px 240px at 50% 38%, rgba(37, 99, 235, 0.22), transparent 70%),
    rgba(255, 255, 255, 0.03);
  min-height: 480px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 40px 28px;
}
.hero-portrait svg { margin: 0 auto 18px; opacity: 0.75; }
.hero-portrait .ph-title { font-weight: 700; color: #cfe0f7; margin-bottom: 6px; }
.hero-portrait .ph-sub { font-size: 16px; color: #8fa9cb; max-width: 260px; margin: 0; }
.hero-portrait .ph-tag {
  position: absolute;
  top: 14px; left: 14px;
}
.hero-card {
  position: absolute;
  background: rgba(13, 32, 56, 0.92);
  border: 1px solid rgba(127, 176, 255, 0.28);
  border-radius: var(--r-md);
  padding: 12px 16px;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(8px);
}
.hero-card .hc-label { font-size: 16px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: #8fa9cb; }
.hero-card .hc-value { font-size: 1.05rem; font-weight: 700; color: #fff; }
.hero-card--tl { top: 26px; right: -18px; }
.hero-card--br { bottom: 30px; left: -22px; }

.hero-proof {
  position: relative;
  margin-top: 72px;
  padding-top: 32px;
  border-top: 1px solid rgba(158, 190, 240, 0.16);
  display: flex;
  flex-wrap: wrap;
  gap: 20px 48px;
}
.hero-proof .hp { font-size: 16px; color: #9db4d4; display: flex; gap: 10px; align-items: center; }
.hero-proof .hp strong { color: #fff; font-size: 1.15rem; font-weight: 800; }

/* ---------- Clienti / logo wall ---------- */
.logo-wall {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}
.logo-tile {
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--surface);
  padding: 22px 18px 18px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 14px;
  text-align: center;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.logo-tile:hover {
  border-color: var(--blue-500);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}
.logo-tile-img {
  background: #fff;
  border-radius: var(--r-md);
  height: 64px;
  display: grid;
  place-items: center;
  padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.logo-tile-img img {
  max-height: 42px;
  max-width: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}
.logo-tile-img--mono img { display: none; }
.logo-tile-img .logo-fallback {
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  color: #14304f;
}
.logo-tile-body { display: flex; flex-direction: column; gap: 7px; align-items: center; }
.logo-name { font-weight: 800; font-size: 16px; color: var(--ink); line-height: 1.3; margin: 0; }
.logo-desc {
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink-2);
  margin: 0;
}

/* ---------- Card grid (problemi / competenze) ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card-grid--4 { grid-template-columns: repeat(4, 1fr); }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 28px 26px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.card:hover {
  border-color: var(--blue-500);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}
.card-icon {
  width: 46px; height: 46px;
  border-radius: var(--r-md);
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  color: var(--blue-600);
}
.card h3 { font-size: 1.08rem; margin-bottom: 8px; }
.card p { font-size: 16px; color: var(--ink-2); margin: 0; }
.card ul {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}
.card ul li {
  position: relative;
  padding-left: 20px;
  font-size: 16px;
  color: var(--ink-2);
  margin-bottom: 6px;
}
.card ul li::before {
  content: "";
  position: absolute;
  left: 0; top: 8px;
  width: 8px; height: 8px;
  border-radius: 2px;
  background: var(--blue-500);
}
.card--span { grid-column: span 2; }

/* ---------- Metodo (pipeline) ---------- */
.pipeline {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  counter-reset: step;
  margin-bottom: 24px;
}
.pipe-step {
  position: relative;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 18px 18px;
  cursor: pointer;
  font-family: var(--font);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.pipe-step:hover { border-color: var(--blue-500); transform: translateY(-3px); box-shadow: var(--shadow-md); }
.pipe-step.is-active {
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px var(--blue-50), var(--shadow-md);
}
.pipe-num {
  width: 34px; height: 34px;
  border-radius: var(--r-sm);
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  color: #a9c6f8;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 16px;
  margin-bottom: 14px;
}
.pipe-step.is-active .pipe-num { background: var(--blue-600); color: #fff; border-color: var(--blue-600); }
.pipe-step h3 { font-size: 1rem; margin-bottom: 6px; }
.pipe-step p { font-size: 16px; color: var(--ink-2); margin: 0; }
.pipe-connector {
  position: absolute;
  top: 50%; right: -14px;
  width: 14px; height: 2px;
  background: var(--border-strong);
}
.pipe-step:last-child .pipe-connector { display: none; }

.pipe-detail {
  background: var(--navy-800);
  color: #d3e0f2;
  border-radius: var(--r-lg);
  padding: 30px 32px;
  border: 1px solid rgba(127, 176, 255, 0.2);
}
.pipe-detail h3 { color: #fff; margin-bottom: 10px; }
.pipe-detail p { color: #a9bedb; max-width: 860px; margin-bottom: 18px; }
.pipe-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.pipe-detail .chip--blue { background: rgba(37, 99, 235, 0.16); color: #a9c6f8; }

/* ---------- Piattaforma (dashboard) ---------- */
.platform-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 56px;
  align-items: center;
}
.platform-points { display: grid; gap: 16px; margin-top: 28px; }
.platform-point {
  display: flex;
  gap: 16px;
  padding: 18px 20px;
  border: 1px solid rgba(127, 176, 255, 0.2);
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.platform-point:hover { border-color: rgba(127, 176, 255, 0.45); background: rgba(37, 99, 235, 0.08); }
.platform-point .card-icon {
  margin: 0;
  flex: none;
  background: rgba(37, 99, 235, 0.15);
  border-color: rgba(59, 130, 246, 0.3);
  color: #7fb0ff;
}
.platform-point h3 { font-size: 1.02rem; margin-bottom: 4px; }
.platform-point p { font-size: 16px; color: #a8bcd6; margin: 0; }

/* Dashboard frame — finestra 16:9 con contenuto tagliato */
.dash-clip {
  position: relative;
  aspect-ratio: 16 / 9;
  min-height: 380px;
  overflow: hidden;
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}
.dash-clip::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 96px;
  background: linear-gradient(180deg, transparent, rgba(6, 15, 31, 0.92));
  pointer-events: none;
}
.dash {
  background: var(--surface);
  color: var(--ink);
  height: 100%;
  overflow: hidden;
}
.dash-topbar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 18px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
}
.dash-dots { display: flex; gap: 6px; }
.dash-dots i { width: 11px; height: 11px; border-radius: 50%; background: var(--border-strong); }
.dash-dots i:nth-child(1) { background: #f29a97; }
.dash-dots i:nth-child(2) { background: #f5cf8e; }
.dash-dots i:nth-child(3) { background: #9fd9a8; }
.dash-url {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 7px 12px;
  font-size: 16px;
  color: var(--ink-3);
}
.dash-url svg { flex: none; }
.dash-body {
  display: grid;
  grid-template-columns: 200px 1fr;
  min-height: 520px;
}
.dash-side {
  background: var(--navy-800);
  padding: 18px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.dash-side .ds-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px 18px;
  color: #fff;
  font-weight: 800;
  font-size: 16px;
}
.dash-side .ds-brand .brand-mark { width: 30px; height: 30px; font-size: 16px; }
.dash-tab {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: #9db4d4;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s ease, color 0.15s ease;
}
.dash-tab:hover { background: rgba(255, 255, 255, 0.06); color: #dce6f5; }
.dash-tab.is-active { background: var(--blue-600); color: #fff; }
.dash-tab .tab-count {
  margin-left: auto;
  font-size: 16px;
  background: rgba(255, 255, 255, 0.14);
  padding: 2px 7px;
  border-radius: 6px;
}
.dash-tab.is-active .tab-count { background: rgba(255, 255, 255, 0.22); }
.dash-main { padding: 22px 24px; background: var(--bg-soft); overflow: hidden; }
.dash-panel { display: none; }
.dash-panel.is-active { display: block; animation: fadeUp 0.35s ease; }

.dash-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}
.dash-head h3 { margin: 0; font-size: 1.05rem; }
.dash-head p { margin: 2px 0 0; font-size: 16px; color: var(--ink-3); }

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 14px 16px;
}
.kpi .k-label { font-size: 16px; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; }
.kpi .k-value { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; margin: 4px 0 2px; }
.kpi .k-delta { font-size: 16px; font-weight: 700; }
.kpi .k-delta.up { color: var(--green); }
.kpi .k-delta.down { color: var(--red); }

.dash-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 18px 20px;
  margin-bottom: 16px;
}
.dash-card:last-child { margin-bottom: 0; }
.dash-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 12px;
}
.dash-card-head h4 { margin: 0; font-size: 16px; font-weight: 700; }
.dash-card-head .hint { font-size: 16px; color: var(--ink-3); }

.range-btns { display: flex; gap: 6px; }
.range-btn {
  padding: 6px 12px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink-2);
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: all 0.15s ease;
}
.range-btn:hover { border-color: var(--blue-500); color: var(--blue-600); }
.range-btn.is-active { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }

.chart-wrap { position: relative; }
.chart-wrap svg { width: 100%; height: auto; }
.chart-legend { display: flex; gap: 18px; margin-top: 10px; font-size: 16px; color: var(--ink-2); }
.chart-legend i {
  display: inline-block;
  width: 10px; height: 10px;
  border-radius: 3px;
  margin-right: 6px;
}

/* Tabelle dati */
.data-table { width: 100%; border-collapse: collapse; font-size: 16px; }
.data-table th {
  text-align: left;
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-3);
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
}
.data-table td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--ink-2);
  vertical-align: middle;
}
.data-table tr:last-child td { border-bottom: 0; }
.data-table td strong { color: var(--ink); font-weight: 600; }
.data-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.data-table th.num { text-align: right; }

/* Kanban */
.kanban { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.kanban-col {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 12px;
}
.kanban-col > .kanban-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 10px;
  padding: 0 4px;
}
.kanban-title .count { margin-left: auto; font-size: 16px; color: var(--ink-3); }
.kanban-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 12px 14px;
  margin-bottom: 10px;
  font-size: 16px;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}
.kanban-card:last-child { margin-bottom: 0; }
.kanban-card:hover { border-color: var(--blue-500); box-shadow: var(--shadow-sm); }
.kanban-card .kc-title { font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.kanban-card .kc-meta { display: flex; gap: 6px; flex-wrap: wrap; }

/* Avvisi */
.alert-item {
  display: flex;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-top-width: 3px;
  border-radius: var(--r-sm);
  background: var(--surface);
  margin-bottom: 10px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.alert-item:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.alert-item:last-child { margin-bottom: 0; }
.alert-item--crit { border-top-color: var(--red); }
.alert-item--warn { border-top-color: var(--amber); }
.alert-item--info { border-top-color: var(--blue-500); }
.alert-item--ok   { border-top-color: var(--green); }
.alert-item .a-icon { flex: none; margin-top: 2px; }
.alert-item .a-title { font-weight: 700; font-size: 16px; margin-bottom: 2px; }
.alert-item .a-desc { font-size: 16px; color: var(--ink-2); margin: 0; }
.alert-item .a-time { margin-left: auto; flex: none; font-size: 16px; color: var(--ink-3); }

/* ---------- Simulatore di ricerca ---------- */
.search-lab { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 48px; align-items: start; }
.search-lab-copy .badge { margin-bottom: 18px; }
.surface-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 26px;
}
.surface-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 700;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface);
  color: var(--ink-2);
  cursor: pointer;
  transition: all 0.15s ease;
}
.surface-btn:hover { border-color: var(--blue-500); color: var(--blue-600); }
.surface-btn.is-active {
  background: var(--blue-600);
  border-color: var(--blue-600);
  color: #fff;
  box-shadow: var(--shadow-md);
}
.search-lab-note {
  margin-top: 18px;
  font-size: 16px;
  color: var(--ink-3);
}

/* Frame condiviso */
.surface-stage { position: relative; }
.surface-panel { display: none; }
.surface-panel.is-active { display: block; animation: fadeUp 0.3s ease; }
.surface-frame {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.surface-titlebar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-2);
}
.surface-titlebar .st-icon {
  width: 26px; height: 26px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  flex: none;
}
.state-block { display: none; }
.state-block.is-visible { display: block; }

/* Google SERP */
.g-serp { padding: 0; }
.g-searchbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
}
.g-logo { font-weight: 800; font-size: 1.15rem; letter-spacing: -0.03em; }
.g-logo b:nth-child(1) { color: #4285f4; }
.g-logo b:nth-child(2) { color: #ea4335; }
.g-logo b:nth-child(3) { color: #fbbc05; }
.g-logo b:nth-child(4) { color: #4285f4; }
.g-logo b:nth-child(5) { color: #34a853; }
.g-logo b:nth-child(6) { color: #ea4335; }
.g-input {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #3c455c;
  border-radius: var(--r-xl);
  padding: 10px 18px;
  font-size: 16px;
  color: #e8eaed;
  box-shadow: var(--shadow-sm);
  background: #20293a;
}
.g-input svg { flex: none; color: var(--ink-3); }
.g-tabs {
  display: flex;
  gap: 4px;
  padding: 0 20px;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
}
.g-tabs span {
  padding: 12px 12px 10px;
  font-size: 16px;
  color: var(--ink-2);
  border-bottom: 3px solid transparent;
  white-space: nowrap;
}
.g-tabs span.is-active { color: #8ab4f8; border-bottom-color: #8ab4f8; font-weight: 700; }
.g-results { padding: 18px 20px 22px; }
.g-stats { font-size: 16px; color: var(--ink-3); margin-bottom: 16px; }

.g-result { margin-bottom: 24px; }
.g-result:last-child { margin-bottom: 0; }
.g-site { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.g-favicon {
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid #3c455c;
  display: grid;
  place-items: center;
  font-size: 16px;
  font-weight: 800;
  background: #20293a;
  color: #bdc1c6;
  flex: none;
}
.g-favicon--client { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }
.g-site-meta { line-height: 1.3; }
.g-site-name { font-size: 16px; color: var(--ink); font-weight: 600; }
.g-site-url { font-size: 16px; color: var(--ink-3); }
.g-title {
  font-size: 1.12rem;
  color: #8ab4f8;
  font-weight: 500;
  line-height: 1.35;
  margin-bottom: 3px;
}
.g-title:hover { text-decoration: underline; cursor: pointer; }
.g-snippet { font-size: 16px; color: #9fb0c6; margin: 0; }
.g-snippet .g-date { color: var(--ink-3); }
.g-result--highlight {
  position: relative;
  border: 1px solid var(--blue-100);
  border-radius: var(--r-md);
  padding: 14px 16px;
  background: linear-gradient(180deg, var(--blue-50), transparent 80%);
  margin-bottom: 20px;
}
.g-result--highlight .pos-badge {
  position: absolute;
  top: -11px; right: 14px;
  background: var(--blue-600);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 6px;
  letter-spacing: 0.04em;
}

/* AI Overview */
.aio-box {
  margin: 0 20px 20px;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.aio-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: linear-gradient(90deg, rgba(66, 133, 244, 0.18), rgba(154, 114, 203, 0.18));
  font-weight: 700;
  font-size: 1rem;
  color: var(--ink);
}
.aio-body { padding: 16px 18px; font-size: 16px; color: #c3d2e4; }
.aio-body p { margin-bottom: 10px; }
.aio-cite {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  margin: 0 2px;
  border-radius: 5px;
  background: rgba(66, 133, 244, 0.2);
  color: #8ab4f8;
  font-size: 16px;
  font-weight: 700;
  vertical-align: 2px;
  cursor: pointer;
}
.aio-cite--client { background: var(--blue-600); color: #fff; }
.aio-sources {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 0 18px 18px;
}
.aio-source {
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 12px 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.aio-source:hover { border-color: var(--blue-500); box-shadow: var(--shadow-sm); }
.aio-source .as-site { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.aio-source .as-name { font-size: 16px; font-weight: 600; color: var(--ink-2); }
.aio-source .as-title { font-size: 16px; color: #8ab4f8; line-height: 1.35; }
.aio-source--client { border-color: var(--blue-500); background: var(--blue-50); }

/* Gemini */
.gemini-frame { background: #fff; }
.gemini-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--ink);
}
.gemini-head .gem-spark { color: #4285f4; }
.gemini-head .gem-badge {
  margin-left: auto;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-3);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 6px;
}
.gemini-chat { padding: 22px 20px; }
.gem-msg-user {
  margin-left: auto;
  max-width: 75%;
  background: var(--navy-600);
  border-radius: var(--r-lg) var(--r-lg) var(--r-sm) var(--r-lg);
  padding: 12px 16px;
  font-size: 16px;
  color: #e8eef7;
  margin-bottom: 20px;
  width: fit-content;
}
.gem-msg { display: flex; gap: 12px; }
.gem-avatar {
  width: 32px; height: 32px;
  flex: none;
  display: grid;
  place-items: center;
  color: #4285f4;
}
.gem-text { font-size: 16px; color: #d7e1ee; }
.gem-text p { margin-bottom: 10px; }
.gem-text strong { color: var(--blue-300); }
.gem-sources {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.gem-sources .gs-label {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}
.gem-source-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--r-sm);
  font-size: 16px;
}
.gem-source-row:hover { background: var(--bg-soft); }
.gem-source-row .gs-title { color: var(--ink); font-weight: 600; }
.gem-source-row .gs-domain { color: var(--ink-3); font-size: 16px; }
.gem-inputbar {
  margin: 0 20px 20px;
  border: 1px solid #3c455c;
  border-radius: var(--r-xl);
  padding: 13px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink-3);
  font-size: 16px;
  background: #20293a;
  box-shadow: var(--shadow-sm);
}
.gem-inputbar svg { margin-left: auto; color: var(--ink-3); }

/* ChatGPT Search */
.gpt-frame { background: #fff; }
.gpt-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 20px;
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 16px;
}
.gpt-head .gpt-icon {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: #10a37f;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 16px;
  font-weight: 800;
}
.gpt-head .gpt-model { color: var(--ink-3); font-weight: 600; font-size: 16px; }
.gpt-chat { padding: 22px 20px; }
.gpt-msg-user {
  margin-left: auto;
  width: fit-content;
  max-width: 75%;
  background: var(--navy-600);
  border-radius: var(--r-lg);
  padding: 12px 16px;
  font-size: 16px;
  color: #e8eef7;
  margin-bottom: 20px;
}
.gpt-answer { font-size: 16px; color: #dbe4ef; }
.gpt-answer p { margin-bottom: 10px; }
.gpt-cite {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 9px;
  margin: 0 2px;
  border-radius: 8px;
  background: var(--navy-600);
  border: 1px solid var(--border-strong);
  font-size: 16px;
  font-weight: 600;
  color: #a9bcd6;
  white-space: nowrap;
  cursor: pointer;
  vertical-align: 1px;
}
.gpt-cite:hover { background: var(--navy-700); }
.gpt-cite--client { background: var(--blue-50); border-color: var(--blue-100); color: #a9c6f8; }
.gpt-sources-panel {
  margin-top: 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
}
.gpt-sources-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--bg-soft);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-2);
}
.gpt-source-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-top: 1px solid var(--border);
  font-size: 16px;
}
.gpt-source-item .si-title { font-weight: 600; color: var(--ink); }
.gpt-source-item .si-domain { color: var(--ink-3); font-size: 16px; margin-left: auto; }
.gpt-inputbar {
  margin: 0 20px 20px;
  border: 1px solid #3c455c;
  border-radius: var(--r-xl);
  padding: 13px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink-3);
  font-size: 16px;
  background: #20293a;
  box-shadow: var(--shadow-sm);
}
.gpt-inputbar .gpt-send {
  margin-left: auto;
  width: 30px; height: 30px;
  border-radius: 8px;
  background: #0d0d0d;
  color: #fff;
  display: grid;
  place-items: center;
  flex: none;
}

/* ---------- Widget dati ---------- */
.widget-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
}
.widget {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.widget:hover { border-color: var(--blue-500); box-shadow: var(--shadow-md); }
.widget--w2 { grid-column: span 2; }
.widget--w3 { grid-column: span 3; }
.widget--w4 { grid-column: span 4; }
.widget-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}
.widget-head h3 { margin: 0; font-size: 16px; }
.widget-head .chip { flex: none; }

/* Crawl log */
.crawl-log {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 16px;
  min-height: 190px;
}
.crawl-line {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  animation: fadeUp 0.4s ease;
}
.crawl-line .cl-status { font-weight: 800; width: 34px; text-align: center; border-radius: 5px; font-size: 16px; padding: 1px 0; }
.cl-status--ok { color: var(--green); background: var(--green-bg); }
.cl-status--redir { color: var(--amber); background: var(--amber-bg); }
.cl-status--err { color: var(--red); background: var(--red-bg); }
.crawl-line .cl-url { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
.crawl-line .cl-ms { color: var(--ink-3); font-size: 16px; flex: none; font-variant-numeric: tabular-nums; }
.crawl-foot {
  display: flex;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  font-size: 16px;
  color: var(--ink-2);
}
.crawl-foot strong { color: var(--ink); font-variant-numeric: tabular-nums; }

/* Core Web Vitals — barre orizzontali stile PageSpeed */
.cwv-bars { display: grid; gap: 22px; }
.cwv-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.cwv-head .cwv-name { font-weight: 800; font-size: 16px; color: var(--ink); }
.cwv-head .cwv-full { font-weight: 500; font-size: 16px; color: var(--ink-3); }
.cwv-head .cwv-value { margin-left: auto; font-weight: 800; font-size: 1.05rem; color: var(--green); font-variant-numeric: tabular-nums; }
.cwv-track {
  position: relative;
  height: 10px;
  border-radius: 6px;
  background: var(--surface-2);
}
.cwv-track::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 6px;
  background: var(--cwv-scale);
  opacity: 0.25;
}
.cwv-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  border-radius: 6px;
  background: var(--green);
  box-shadow: 0 0 12px rgba(74, 222, 128, 0.45);
  transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.cwv-marker {
  position: absolute;
  top: -4px; bottom: -4px;
  width: 3px;
  margin-left: -1px;
  border-radius: 2px;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.18);
  opacity: 0;
  transition: opacity 0.3s ease 1s;
}
.cwv-item.is-done .cwv-marker { opacity: 1; }
.cwv-thresholds { margin-top: 8px; font-size: 16px; color: var(--ink-3); }
.cwv-thresholds b { color: var(--ink-2); font-weight: 600; }

/* Sparkline */
.spark-wrap { position: relative; margin-top: 4px; }
.spark-wrap svg { width: 100%; height: auto; }
.spark-delta { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; }
.spark-delta .sd-value { font-size: 1.8rem; font-weight: 800; letter-spacing: -0.02em; }

/* Query mini-table */
.query-bar {
  display: inline-block;
  height: 6px;
  border-radius: 3px;
  background: var(--blue-500);
  vertical-align: middle;
  margin-right: 8px;
}

/* ---------- Casi studio: teaser + pagine dedicate ---------- */
.case-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.case-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 24px 24px 22px;
  text-decoration: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.case-card:hover {
  border-color: var(--blue-500);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
  text-decoration: none;
}
.case-card .logo-tile-img { height: 72px; }
.case-card h3 { font-size: 1.2rem; margin: 0; color: var(--ink); }
.case-card .case-sub { color: var(--ink-2); font-size: 16px; margin: 0; }
.case-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.case-card .case-link {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 16px;
  color: var(--blue-300);
}
.case-card .case-link svg { transition: transform 0.18s ease; }
.case-card:hover .case-link svg { transform: translateX(4px); }

/* Pagina dedicata caso studio */
.case-hero {
  padding: 152px 0 56px;
}
.case-hero .back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 26px;
}
.case-hero .back-link:hover { color: var(--blue-300); text-decoration: none; }
.case-hero-head {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.case-hero .logo-tile-img { width: 132px; height: 84px; flex: none; }
.case-hero h1 { margin: 0 0 6px; }
.case-hero .case-sub { color: var(--ink-2); font-size: 1.08rem; max-width: 760px; }
.case-hero .case-tags { margin-top: 16px; }
.case-body-section { padding: 24px 0 88px; }
.case-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px 40px;
}
.case-block h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--blue-700);
  margin-bottom: 8px;
}
.case-block h4::before {
  content: "";
  width: 14px; height: 3px;
  background: var(--blue-600);
  border-radius: 2px;
}
.case-block p, .case-block li { font-size: 16px; color: var(--ink-2); }
.case-block p { margin: 0; }
.case-block ul { margin: 0; padding-left: 18px; }
.case-block ul li { margin-bottom: 5px; }
.case-block--full { grid-column: 1 / -1; }

.metric-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 6px;
}
.metric-ph {
  border: 1px dashed var(--border-strong);
  border-radius: var(--r-md);
  background: var(--bg-soft);
  padding: 18px;
  text-align: center;
}
.metric-ph .mp-label { font-size: 16px; font-weight: 700; color: var(--ink-2); text-transform: uppercase; letter-spacing: 0.05em; }
.metric-ph .mp-value {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-3);
  margin-top: 8px;
  font-style: italic;
}

/* ---------- Autorevolezza ---------- */
.authority-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
.authority-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 18px 18px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  align-items: stretch;
  text-align: center;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.authority-card:hover { border-color: var(--blue-500); transform: translateY(-4px); box-shadow: var(--shadow-md); }
.authority-card .a-logo {
  background: #fff;
  border-radius: var(--r-md);
  height: 64px;
  display: grid;
  place-items: center;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.authority-card .a-logo img {
  max-height: 44px;
  max-width: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}
.authority-card .a-event { font-weight: 800; font-size: 16px; margin: 0; color: var(--ink); line-height: 1.35; }
.authority-card .a-role { font-size: 16px; color: var(--ink-2); margin: 0; }
.authority-card .a-year { margin-top: auto; }

/* ---------- Su di me ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 56px;
  align-items: center;
  margin-bottom: 40px;
}
.about-photo {
  position: relative;
  border-radius: var(--r-xl);
  border: 1px dashed rgba(158, 190, 240, 0.4);
  background:
    radial-gradient(240px 240px at 50% 38%, rgba(37, 99, 235, 0.2), transparent 70%),
    var(--surface);
  min-height: 460px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 40px 28px;
}
.about-photo svg { margin: 0 auto 18px; opacity: 0.75; }
.about-photo .ph-title { font-weight: 700; color: #cfe0f7; margin-bottom: 6px; }
.about-photo .ph-sub { font-size: 16px; color: #8fa9cb; max-width: 250px; margin: 0; }
.about-photo .ph-tag { position: absolute; top: 14px; left: 14px; }

.timeline { position: relative; padding-left: 34px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 10px; top: 6px; bottom: 6px;
  width: 2px;
  background: linear-gradient(180deg, var(--blue-500), var(--border));
  border-radius: 2px;
}
.tl-item { position: relative; padding-bottom: 32px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: "";
  position: absolute;
  left: -30px; top: 5px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--bg);
  border: 3px solid var(--blue-500);
}
.tl-year {
  display: inline-block;
  font-size: 16px;
  font-weight: 800;
  color: #a9c6f8;
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  padding: 3px 10px;
  border-radius: 6px;
  margin-bottom: 8px;
}
.tl-item h3 { font-size: 1.15rem; margin-bottom: 6px; }
.tl-item p { font-size: 16px; color: var(--ink-2); margin: 0; }

.principles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.principle {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px 20px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.principle:hover { border-color: var(--blue-500); transform: translateY(-3px); }
.principle .card-icon { margin: 0; flex: none; }
.principle h3 { font-size: 16px; margin-bottom: 4px; }
.principle p { font-size: 16px; color: var(--ink-2); margin: 0; }

/* ---------- Contatti ---------- */
.contact-points {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  list-style: none;
  margin: 0 0 34px;
  padding: 0;
}
.contact-points li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 16px;
  color: var(--ink-2);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 18px 20px;
  margin: 0;
}
.contact-points li svg { flex: none; margin-top: 3px; color: var(--blue-500); }
.contact-points li strong { color: var(--ink); display: block; font-size: 1rem; }

.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 38px 36px;
  box-shadow: var(--shadow-lg);
  color: var(--ink);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-field { display: flex; flex-direction: column; gap: 7px; }
.form-field--full { grid-column: 1 / -1; }
.form-field label { font-size: 16px; font-weight: 700; color: var(--ink); }
.form-field label .req { color: var(--red); }
.form-field input,
.form-field select,
.form-field textarea {
  font-family: var(--font);
  font-size: 16px;
  color: var(--ink);
  padding: 13px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--r-sm);
  background: var(--bg-soft);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  width: 100%;
}
.form-field select:invalid { color: var(--ink-3); }
.form-field textarea { min-height: 130px; resize: vertical; }
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--blue-600);
  box-shadow: 0 0 0 3px var(--blue-100);
}
.form-field .hint { font-size: 16px; color: var(--ink-3); }
.form-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 24px;
  flex-wrap: wrap;
}
.form-foot .privacy { font-size: 16px; color: var(--ink-3); max-width: 380px; margin: 0; }
.form-note {
  margin-top: 18px;
  padding: 13px 16px;
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  border-radius: var(--r-sm);
  font-size: 16px;
  color: var(--blue-700);
}

/* ---------- CTA finale / footer ---------- */
.final-cta { text-align: center; max-width: 720px; margin: 0 auto; }
.final-cta h2 { color: #fff; }
.final-cta p { color: #a8bcd6; font-size: 1.1rem; margin-bottom: 30px; }
.final-cta .badge { margin-bottom: 20px; }

.site-footer {
  background: var(--navy-950);
  color: #8fa3c0;
  padding: 48px 0 32px;
  font-size: 16px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(158, 190, 240, 0.14);
  margin-bottom: 26px;
}
.footer-grid h4 { color: #fff; font-size: 16px; margin-bottom: 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.footer-grid a { color: #8fa3c0; }
.footer-grid a:hover { color: #fff; }
.footer-brand p { margin: 12px 0 0; max-width: 340px; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: #6e83a3;
  font-size: 16px;
}

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.is-visible { opacity: 1; transform: none; }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .hero-portrait { min-height: 380px; max-width: 440px; }
  .hero-card--tl { right: 8px; }
  .hero-card--br { left: 8px; }
  .logo-wall { grid-template-columns: repeat(3, 1fr); }
  .case-cards { grid-template-columns: 1fr; }
  .principles { grid-template-columns: repeat(2, 1fr); }
  .contact-points { grid-template-columns: 1fr; }
  .card-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .pipeline { grid-template-columns: repeat(3, 1fr); }
  .pipe-connector { display: none; }
  .platform-grid, .search-lab, .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .dash-clip { aspect-ratio: auto; min-height: 460px; }
  .authority-grid { grid-template-columns: repeat(3, 1fr); }
  .widget-grid { grid-template-columns: repeat(2, 1fr); }
  .widget--w2, .widget--w3, .widget--w4 { grid-column: span 2; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .section { padding: 64px 0; }
  .hero { padding: 128px 0 72px; }
  .main-nav, .header-cta .btn { display: none; }
  .nav-toggle { display: block; }
  .site-header.is-open { background: var(--navy-900); border-color: var(--border); }
  .site-header.is-open .main-nav {
    display: flex;
    position: absolute;
    top: 72px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    background: var(--navy-900);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    padding: 14px 20px 20px;
  }
  .site-header.is-open .main-nav a { padding: 13px 14px; font-size: 1rem; }
  .site-header.is-open .main-nav .nav-cta { display: inline-flex; margin-top: 8px; justify-content: center; }
  .logo-wall { grid-template-columns: repeat(2, 1fr); }
  .principles { grid-template-columns: 1fr; }
  .card-grid, .card-grid--4 { grid-template-columns: 1fr; }
  .card--span { grid-column: span 1; }
  .pipeline { grid-template-columns: 1fr; }
  .dash-body { grid-template-columns: 1fr; }
  .dash-side { flex-direction: row; overflow-x: auto; padding: 10px; }
  .dash-side .ds-brand { display: none; }
  .dash-tab { white-space: nowrap; width: auto; }
  .kanban { grid-template-columns: 1fr; }
  .cwv-head .cwv-full { display: none; }
  .widget-grid { grid-template-columns: 1fr; }
  .widget--w2, .widget--w3, .widget--w4 { grid-column: span 1; }
  .case-grid { grid-template-columns: 1fr; }
  .case-hero { padding: 128px 0 40px; }
  .case-hero-head { gap: 18px; }
  .metric-row { grid-template-columns: 1fr; }
  .authority-grid { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .form-card { padding: 26px 20px; }
  .aio-sources { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
}

/* ---------- Metriche casi: etichette su righe separate ---------- */
.metric-ph strong { display: block; margin-bottom: 4px; }
.metric-ph span { display: block; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
