:root {
  --ink: #23232a;
  --ink-2: #2d2d34;
  --ink-soft: #3c3c44;
  --red: #c94940;
  --red-2: #e15a50;
  --grey: #5a5a5f;
  --muted: #747174;
  --paper: #ffffff;
  --cream: #f6f3f1;
  --cream-2: #ebe6e3;
  --line: rgba(35, 35, 42, .13);
  --shadow: 0 24px 90px rgba(35, 35, 42, .16);
  --radius: 28px;
  --good: #238459;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.5;
  overflow-x: hidden;
}
a { color: inherit; }
.container { width: min(1160px, calc(100% - 34px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(246, 243, 241, .84);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(35,35,42,.08);
}
.nav { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; gap: 18px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; min-width: 260px; }
.brand-logo { width: 66px; height: 66px; object-fit: contain; background: transparent; }
.brand strong { display: block; font-size: 17px; letter-spacing: -.02em; }
.brand small { display: block; color: var(--muted); margin-top: 1px; }
.nav-links { display: flex; align-items: center; gap: 22px; font-weight: 700; color: var(--grey); font-size: 14px; }
.nav-links a { text-decoration: none; }
.nav-links a:hover { color: var(--red); }
.nav-cta, .button {
  border-radius: 999px;
  padding: 13px 19px;
  text-decoration: none;
  font-weight: 800;
  border: 1px solid transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
}
.nav-cta, .button.primary {
  color: #fff;
  background: linear-gradient(135deg, var(--red), var(--red-2));
  box-shadow: 0 14px 34px rgba(201, 73, 64, .28);
}
.button:hover, .nav-cta:hover { transform: translateY(-2px); }
.button.ghost {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.22);
  color: #fff;
}
.button.ghost.dark { color: var(--ink); border-color: var(--line); background: rgba(255,255,255,.8); box-shadow: none; }
.button.full { width: 100%; }

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background:
    radial-gradient(circle at 88% 18%, rgba(201,73,64,.42), transparent 28%),
    radial-gradient(circle at 10% 0%, rgba(255,255,255,.13), transparent 32%),
    linear-gradient(135deg, #202027 0%, #2d2d34 48%, #18181d 100%);
  color: #fff;
  padding: 86px 0 64px;
}
.hero::before {
  content: "";
  position: absolute;
  inset: auto -8% -25% auto;
  width: 560px;
  height: 560px;
  background: rgba(201,73,64,.22);
  filter: blur(18px);
  border-radius: 48% 52% 50% 50%;
  transform: rotate(-18deg);
  z-index: -2;
}
.hero-noise {
  position: absolute;
  inset: 0;
  opacity: .26;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, #000, transparent 94%);
  z-index: -1;
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(360px, .72fr); gap: 44px; align-items: center; }
.eyebrow { color: var(--red-2); text-transform: uppercase; letter-spacing: .15em; font-size: 12px; font-weight: 900; margin: 0 0 12px; }
.eyebrow.small { font-size: 11px; margin-bottom: 5px; }
h1 { font-size: clamp(44px, 6.6vw, 82px); letter-spacing: -0.075em; line-height: .92; margin: 0 0 22px; max-width: 850px; }
h2 { font-size: clamp(32px, 4.5vw, 54px); letter-spacing: -0.058em; line-height: .98; margin: 0 0 16px; }
h3 { margin: 0 0 10px; font-size: 23px; letter-spacing: -.035em; }

.hero-form-note {
  margin: 16px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  font-weight: 800;
  color: var(--accent);
}

.lead { font-size: clamp(18px, 2vw, 22px); color: rgba(255,255,255,.78); max-width: 760px; margin: 0; }
.hero-actions { display: flex; gap: 13px; flex-wrap: wrap; margin-top: 30px; }
.trust-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.trust-row span {
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.08);
  padding: 8px 12px;
  border-radius: 999px;
  color: rgba(255,255,255,.78);
  font-size: 14px;
}

.hero-panel {
  border: 1px solid rgba(255,255,255,.16);
  background: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,.08));
  backdrop-filter: blur(20px);
  border-radius: 34px;
  padding: 20px;
  box-shadow: 0 28px 120px rgba(0,0,0,.34);
}
.panel-top { display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,.78); font-size: 13px; margin-bottom: 14px; }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.dot.red { background: var(--red); }
.dot.grey { background: #9b9ba0; }
.dot.dark { background: #111116; }
.panel-top strong { margin-left: auto; }
.ai-card { background: #fff; color: var(--ink); border-radius: 26px; padding: 24px; }
.ai-label { color: var(--muted); margin: 0 0 6px; font-weight: 800; font-size: 13px; text-transform: uppercase; letter-spacing: .1em; }
.ai-card h2 { font-size: 32px; margin-bottom: 18px; }
.meter { height: 11px; background: #ede9e6; border-radius: 999px; overflow: hidden; }
.meter span { display: block; height: 100%; background: linear-gradient(90deg, var(--red), var(--ink)); border-radius: inherit; }
.score { margin: 13px 0 0; color: var(--red); font-weight: 900; }
.mini-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; margin-top: 12px; }
.mini-grid div { background: rgba(255,255,255,.11); border: 1px solid rgba(255,255,255,.13); border-radius: 20px; padding: 14px; }
.mini-grid small { display: block; color: rgba(255,255,255,.58); text-transform: uppercase; letter-spacing: .08em; font-size: 11px; }
.mini-grid strong { color: #fff; font-size: 16px; }
.panel-note { color: rgba(255,255,255,.66); margin: 14px 4px 0; font-size: 14px; }

.strip { background: var(--red); color: #fff; }
.strip-grid { display: grid; grid-template-columns: repeat(4,1fr); }
.strip-grid div { display: grid; gap: 2px; padding: 22px 24px; border-left: 1px solid rgba(255,255,255,.2); }
.strip-grid div:last-child { border-right: 1px solid rgba(255,255,255,.2); }
.strip-grid strong { font-size: 14px; opacity: .75; }
.strip-grid span { font-weight: 850; letter-spacing: -.02em; }

.section { padding: 72px 0; }
.section-head { max-width: 760px; margin-bottom: 24px; }
.section-head p:not(.eyebrow), .muted { color: var(--muted); font-size: 18px; margin: 0; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card, .form-card, .result-card, .contact-card, .method-list div {
  background: rgba(255,255,255,.82);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
}
.feature-card { position: relative; overflow: hidden; min-height: 250px; }
.feature-card::after { content: ""; position: absolute; inset: auto -40px -65px auto; width: 150px; height: 150px; border-radius: 50%; background: rgba(201,73,64,.08); }
.accent-card { background: var(--ink); color: #fff; border-color: rgba(255,255,255,.08); }
.accent-card p { color: rgba(255,255,255,.7)!important; }
.card-icon { display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 20px; border-radius: 18px; background: rgba(201,73,64,.12); color: var(--red); font-weight: 900; }
.accent-card .card-icon { background: var(--red); color: #fff; }
.card p { color: var(--muted); margin: 0; }

.method-section { background: #fff; }
.method-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: 34px; align-items: center; }
.method-list { display: grid; gap: 12px; }
.method-list div { box-shadow: none; display: grid; grid-template-columns: 150px 1fr; gap: 20px; align-items: baseline; }
.method-list strong { color: var(--red); font-size: 20px; }
.method-list span { color: var(--muted); }

.section-form {
  background:
    radial-gradient(circle at 8% 20%, rgba(201,73,64,.12), transparent 25%),
    linear-gradient(180deg, var(--cream), #fff);
  padding-bottom: 84px;
}
.form-grid { display: grid; grid-template-columns: .82fr 1.18fr; gap: 28px; align-items: start; }
.sticky-info { position: sticky; top: 104px; }
.form-card { display: grid; gap: 16px; background: #fff; }
.form-title { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); padding-bottom: 14px; margin-bottom: 3px; }
.form-title span { font-size: 22px; font-weight: 900; letter-spacing: -.04em; }
.form-title strong { color: #fff; background: var(--ink); border-radius: 999px; padding: 7px 11px; font-size: 12px; }
.two-cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
label { display: grid; gap: 8px; color: var(--ink); font-weight: 760; }
input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 13px 14px;
  font: inherit;
  background: #fbfaf9;
  color: var(--ink);
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
input:focus, select:focus, textarea:focus { border-color: rgba(201,73,64,.7); box-shadow: 0 0 0 4px rgba(201,73,64,.12); background: #fff; }
textarea { resize: vertical; }
fieldset { border: 1px solid var(--line); border-radius: 20px; padding: 15px; display: grid; gap: 9px; background: #fbfaf9; }
legend { font-weight: 900; padding: 0 9px; }
.check { display: flex; align-items: flex-start; gap: 9px; font-weight: 520; color: var(--muted); }
.check input { width: auto; margin-top: 5px; accent-color: var(--red); }
.privacy { font-size: 14px; }
.form-note { margin: -4px 0 0; color: var(--muted); font-size: 13px; text-align: center; }
.result-card { margin-top: 22px; border-color: rgba(201,73,64,.3); box-shadow: 0 18px 58px rgba(201,73,64,.12); }
.result-card h3 { color: var(--ink); font-size: 28px; }
#scoreText { font-weight: 900; color: var(--red); }
.coherence-meter { margin: 18px 0 16px; }
.meter-track {
  position: relative;
  height: 16px;
  border-radius: 999px;
  background: linear-gradient(90deg, #b43a34 0%, #d78a39 34%, #d4bd5d 62%, #4f9f67 100%);
  box-shadow: inset 0 1px 3px rgba(0,0,0,.18);
}
.meter-track span {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-bottom: 17px solid var(--ink);
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.22));
}
.meter-track span::after {
  content: "";
  position: absolute;
  left: -5px;
  top: 15px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ink);
}
.meter-labels {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-top: 9px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .055em;
}
.meter-labels span:nth-child(1) { text-align: left; }
.meter-labels span:nth-child(2), .meter-labels span:nth-child(3) { text-align: center; }
.meter-labels span:nth-child(4) { text-align: right; }
.result-card[data-level="non-coerente"] #scoreText { color: #b43a34; }
.result-card[data-level="da-rivedere"] #scoreText, .result-card[data-level="da-studiare"] #scoreText { color: #b46f25; }
.result-card[data-level="coerente"] #scoreText, .result-card[data-level="coerente-alto"] #scoreText { color: #3f8f5b; }

.result-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.contact-card { display: flex; gap: 16px; align-items: center; box-shadow: none; margin-top: 18px; padding: 18px; }
.contact-card img { width: 82px; height: 82px; object-fit: contain; flex: 0 0 auto; }
.contact-card span { display: block; color: var(--muted); font-size: 14px; }

.site-footer { background: var(--ink); color: rgba(255,255,255,.76); padding: 34px 0; }
.footer-grid { display: flex; justify-content: space-between; gap: 26px; flex-wrap: wrap; align-items: center; }
.footer-grid > div:first-child { display: flex; align-items: center; gap: 18px; }
.footer-logo { width: 96px; height: 96px; object-fit: contain; background: #fff; border-radius: 20px; padding: 5px; }
.footer-grid p { margin: 0; }
.footer-links { display: flex; gap: 16px; flex-wrap: wrap; }
.footer-links a { color: #fff; text-decoration: none; border-bottom: 1px solid rgba(255,255,255,.35); }

.reveal { animation: rise .75s ease both; }
.delay-1 { animation-delay: .12s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 980px) {
  .hero-grid, .form-grid, .method-grid { grid-template-columns: 1fr; }
  .hero-panel { max-width: 560px; }
  .sticky-info { position: static; }
  .nav-links { display: none; }
  .cards { grid-template-columns: 1fr; }
  .strip-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 620px) {
  .container { width: min(100% - 24px, 1160px); }
  .hero { padding: 58px 0 44px; }
  .brand { min-width: 0; }
  .brand-logo { width: 56px; height: 56px; }
  .brand small { display: none; }
  .nav-cta { display: none; }
  .hero-grid { gap: 28px; }
  .hero-panel { border-radius: 26px; padding: 14px; }
  .ai-card h2 { font-size: 26px; }
  .strip-grid { grid-template-columns: 1fr; }
  .strip-grid div { border-left: 0; border-right: 0!important; border-top: 1px solid rgba(255,255,255,.18); }
  .two-cols { grid-template-columns: 1fr; }
  .method-list div { grid-template-columns: 1fr; gap: 4px; }
  .footer-grid > div:first-child { align-items: flex-start; }
}
