:root {
  --bg: #0f0e0b;
  --panel: #181510;
  --panel-2: #211d16;
  --line: #373126;
  --text: #f5efe3;
  --muted: #bdb29f;
  --soft: #8f8677;
  --brand: #f97316;
  --brand-2: #ffb267;
  --ok: #44c277;
  --warn: #f0b44e;
  --danger: #ef6666;
  --max: 1120px;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

a { color: inherit; }

.skip {
  position: absolute;
  left: -999px;
  top: 12px;
  background: var(--brand);
  color: #180b02;
  padding: 10px 14px;
  z-index: 99;
}

.skip:focus { left: 12px; }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 22px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(15, 14, 11, .92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.brand {
  text-decoration: none;
  font-weight: 850;
  font-size: 1.34rem;
  letter-spacing: 0;
  white-space: nowrap;
}

.brand span { color: var(--brand); }

.links {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: .94rem;
  color: var(--muted);
}

.links a {
  text-decoration: none;
  white-space: nowrap;
}

.links a:hover { color: var(--text); }

/* Link "Accedi" al portale riservato: distinto dagli altri link di nav. */
.links a.accedi {
  border: 1px solid var(--brand);
  color: var(--brand);
  border-radius: 8px;
  padding: 6px 14px;
  font-weight: 700;
}
.links a.accedi:hover { background: var(--brand); color: #16130c; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 8px;
  border: 1px solid var(--line);
  padding: 11px 17px;
  text-decoration: none;
  font-weight: 750;
  cursor: pointer;
  font-family: inherit;
  line-height: 1.2;
}

.btn.primary {
  background: var(--brand);
  border-color: var(--brand);
  color: #1b0d02;
}

.btn.ghost {
  background: rgba(255,255,255,.03);
  color: var(--text);
}

.hero {
  padding: 82px 0 54px;
  border-bottom: 1px solid var(--line);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(330px, .75fr);
  gap: 42px;
  align-items: start;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--brand-2);
  text-transform: uppercase;
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .13em;
  margin-bottom: 18px;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--brand);
}

h1, h2, h3 {
  margin: 0;
  line-height: 1.08;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(2.28rem, 5.6vw, 4rem);
  max-width: 860px;
}

h2 {
  font-size: clamp(1.65rem, 3.7vw, 2.55rem);
}

h3 { font-size: 1.12rem; }

.lead {
  color: var(--muted);
  font-size: clamp(1.04rem, 1.7vw, 1.22rem);
  max-width: 760px;
  margin: 22px 0 0;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.trust-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
  color: var(--muted);
  font-size: .94rem;
}

.trust-row span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255,255,255,.02);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
}

.form-panel h2 {
  font-size: 1.36rem;
  margin-bottom: 8px;
}

.form-panel p {
  color: var(--muted);
  margin: 0 0 18px;
  font-size: .95rem;
}

label {
  display: block;
  color: var(--muted);
  font-size: .84rem;
  font-weight: 700;
  margin: 14px 0 6px;
}

input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0d0c09;
  color: var(--text);
  font: inherit;
  padding: 12px 13px;
  min-height: 44px;
}

textarea { resize: vertical; }

.check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 14px 0;
  color: var(--muted);
  font-size: .9rem;
}

.check input {
  width: 18px;
  height: 18px;
  min-height: 18px;
  flex: none;
  margin-top: 2px;
}

.micro {
  color: var(--soft);
  font-size: .82rem;
  margin-top: 10px;
}

.section {
  padding: 70px 0;
  border-bottom: 1px solid var(--line);
}

.section.alt { background: #12100c; }

.section-head {
  max-width: 780px;
  margin-bottom: 30px;
}

.section-head p {
  color: var(--muted);
  margin: 14px 0 0;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 8px;
  padding: 20px;
}

.card p, .card li { color: var(--muted); }

.card p:last-child { margin-bottom: 0; }

.steps {
  display: grid;
  gap: 12px;
  counter-reset: step;
}

.step {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 14px;
  align-items: start;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 8px;
  padding: 18px;
}

.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  border-radius: 8px;
  background: var(--panel-2);
  color: var(--brand);
  border: 1px solid var(--line);
  font-weight: 850;
}

.step p { margin: 7px 0 0; color: var(--muted); }

.table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.table th, .table td {
  text-align: left;
  padding: 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.table th {
  color: var(--brand-2);
  background: var(--panel-2);
}

.table td { color: var(--muted); }

.notice {
  border-left: 3px solid var(--brand);
  padding: 14px 16px;
  background: rgba(249,115,22,.08);
  color: var(--muted);
  border-radius: 0 8px 8px 0;
}

.footer {
  padding: 42px 0;
  color: var(--soft);
  font-size: .92rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr .9fr;
  gap: 24px;
}

.footer a {
  display: inline-block;
  color: var(--muted);
  margin: 4px 12px 4px 0;
}

.success {
  border-color: rgba(68,194,119,.45);
  background: rgba(68,194,119,.08);
}

.warn {
  border-color: rgba(240,180,78,.5);
  background: rgba(240,180,78,.08);
}

.hidden-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

@media (max-width: 920px) {
  .hero-grid, .grid, .grid.two, .footer-grid {
    grid-template-columns: 1fr;
  }
  .links {
    display: none;
  }
  .hero {
    padding-top: 54px;
  }
}

@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .panel { padding: 18px; }
  .step { grid-template-columns: 1fr; }
  .table { display: block; overflow-x: auto; }
}
