:root {
  --bg: #000000;
  --card: #0e0e10;
  --ink: #ffffff;
  --muted: #a7a9ae;
  --line: #2a2b2f;
  /* Brand identity Gruppo Maffei (0.2): rosso #A60D22, grigio #575957, verde #00632E */
  --red: #a60d22;
  --red-hi: #c41230;
  --gray: #575957;
  --green: #00632e;
  --error: #ff6b6b;
  --radius: 16px;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Poppins", system-ui, -apple-system, sans-serif;
  line-height: 1.5;
  overflow-x: hidden;
}

.glow {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background:
    radial-gradient(60% 40% at 0% 0%, rgba(255, 255, 255, .10), transparent 70%),
    radial-gradient(70% 35% at 50% 100%, rgba(166, 13, 34, .35), transparent 70%),
    radial-gradient(40% 40% at 100% 45%, rgba(166, 13, 34, .18), transparent 70%);
}

.wrap { position: relative; z-index: 1; max-width: 760px; margin: 0 auto; padding: 36px 16px 64px; }

.hero { text-align: center; margin-bottom: 32px; }
.logo { width: min(300px, 75vw); height: auto; }

.title {
  position: relative; display: inline-flex; flex-direction: column; align-items: center;
  margin: 28px auto 20px; padding: 6px 36px 10px;
  font-family: "Poppins", sans-serif; font-weight: 900; text-transform: uppercase;
  font-size: clamp(56px, 15vw, 112px); line-height: .9; letter-spacing: -.01em;
}
.title::before, .title::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 22px; border: 5px solid var(--red);
}
.title::before { left: 0; border-right: 0; }
.title::after { right: 0; border-left: 0; }
.title .red { color: var(--red); }

.sub { margin: 0; font-size: clamp(20px, 4.5vw, 28px); line-height: 1.25; }
.sub strong { font-weight: 700; text-transform: uppercase; }

.card {
  background: rgba(14, 14, 16, .88);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  backdrop-filter: blur(6px);
}

section + section { margin-top: 26px; }
h2 { display: flex; align-items: center; gap: 10px; font-size: 19px; margin: 0 0 14px; font-weight: 700; }
.step {
  display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
  background: var(--red); color: #fff; font-size: 15px; font-weight: 700;
}

.brands { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 10px; }
.brand {
  position: relative; display: flex; flex-direction: column; gap: 8px; padding: 8px 8px 12px;
  border: 2px solid var(--line); border-radius: 12px; background: #151518; cursor: pointer;
  text-align: center; transition: border-color .15s, transform .15s;
}
.brand:hover { border-color: #4a4b50; }
.brand input { position: absolute; opacity: 0; pointer-events: none; }
.brand .tile {
  display: grid; place-items: center; height: 64px; border-radius: 8px; background: #fff; padding: 8px;
}
.brand .tile img { max-width: 100%; max-height: 48px; object-fit: contain; }
.brand .tile .solo-nome { color: #111; font-size: 20px; font-weight: 900; }
.brand .nome { font-size: 14px; font-weight: 700; }
.brand .offerta { font-size: 12.5px; line-height: 1.3; color: var(--muted); }
.brand:has(input:checked) { border-color: var(--red-hi); box-shadow: 0 0 0 3px rgba(196, 18, 48, .25); }
.brand:has(input:checked) .offerta { color: #fff; }
.brand:has(input:focus-visible) { outline: 2px solid #fff; outline-offset: 2px; }

.nota { color: var(--muted); font-size: 12.5px; margin: 10px 0 0; }

.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; margin-bottom: 12px; }
input:not([type]), input[type="email"] {
  font: inherit; font-weight: 400; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 10px;
  background: #18181b; color: var(--ink);
}
input:focus { outline: none; border-color: var(--red-hi); box-shadow: 0 0 0 3px rgba(196, 18, 48, .25); }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.check { display: flex; align-items: flex-start; gap: 10px; font-weight: 400; margin: 20px 0 8px; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--red-hi); flex: none; }
.check { font-size: 14px; }
.check + .check { margin-top: 4px; }
.check a { color: #fff; font-weight: 600; }
.check em { color: var(--muted); font-style: normal; }
.check-marketing {
  margin-top: 10px; padding: 12px 14px; border: 1.5px solid rgba(166, 13, 34, .55); border-radius: 12px;
  background: rgba(166, 13, 34, .10); cursor: pointer;
}
.check-marketing strong { color: #fff; }
.check-marketing:has(input:checked) { border-color: var(--red-hi); background: rgba(166, 13, 34, .18); }

.error { color: var(--error); font-size: 14px; margin: 8px 0 0; }

button, .button {
  display: block; width: 100%; margin-top: 16px; padding: 16px 18px; border: 0;
  border-radius: 6px 22px 6px 22px;
  background: var(--red); color: #fff; font: inherit; font-weight: 700; font-size: 19px;
  text-transform: uppercase; letter-spacing: .01em; text-align: center; text-decoration: none; cursor: pointer;
  transition: background .15s;
}
button:hover, .button:hover { background: var(--red-hi); }
button:disabled { opacity: .6; cursor: progress; }
.after { text-align: center; margin: 10px 0 0; font-size: 18px; }

.result { margin-top: 24px; text-align: center; }
.result img { width: 100%; max-width: 420px; border-radius: 10px; border: 1px solid var(--line); }
.result .button { max-width: 420px; margin: 16px auto 0; font-size: 17px; }
.hint { color: var(--muted); font-size: 14px; }

.footer { margin-top: 32px; text-align: center; color: var(--muted); font-size: 13px; }
.footer p { margin: 4px 0; }
.footer strong { color: #fff; }
.footer a { color: #fff; }
/* Linea tricolore come nel logotipo: segno di italianità della brand identity */
.footer::before {
  content: ""; display: block; width: 160px; height: 3px; margin: 0 auto 16px;
  background: linear-gradient(90deg, var(--green) 0 48%, transparent 48% 52%, var(--red) 52% 100%);
}

.hero-small { margin-bottom: 20px; }
.legal { line-height: 1.65; font-size: 15px; }
.legal .eyebrow { margin: 0; color: var(--red-hi); font-weight: 700; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.legal h1 { margin: 6px 0 2px; font-size: clamp(26px, 6vw, 34px); font-weight: 900; }
.legal .meta { margin: 0 0 18px; color: var(--muted); font-size: 13px; }
.legal h2 { display: block; margin: 26px 0 8px; font-size: 17px; font-weight: 700; padding-left: 12px; border-left: 4px solid var(--red); }
.legal ul { padding-left: 20px; margin: 8px 0; }
.legal li { margin: 6px 0; }
.legal a { color: #fff; }
.legal .back { margin-top: 28px; }
.legal .back .button { max-width: 320px; margin: 0 auto; font-size: 16px; }

@media (max-width: 520px) {
  .wrap { padding-top: 28px; }
  .card { padding: 18px 16px; }
  .row { grid-template-columns: 1fr; gap: 0; }
  .brands { grid-template-columns: repeat(2, 1fr); }
  .title { padding: 4px 26px 8px; }
  .title::before, .title::after { width: 16px; border-width: 4px; }
}
