/* Zanzara — design system pubblico + componenti condivisi */
:root {
  --bg: #eef2f6;
  --ink: #0b1020;
  --muted: #3f4b5f;
  --line: #cfd8e6;
  --surface: #ffffff;
  --accent: #0f766e;
  --accent-deep: #0b5f58;
  --accent-soft: #ccfbf1;
  --danger: #b91c1c;
  --danger-soft: #fef2f2;
  --ok: #047857;
  --ok-soft: #ecfdf5;
  --warn: #b45309;
  --warn-soft: #fffbeb;
  --warn-line: #fcd34d;
  --shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
  --radius: 18px;
  --radius-sm: 12px;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --sans: "Manrope", system-ui, sans-serif;
  --display: "Syne", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--sans);
  color: var(--ink);
  background:
    radial-gradient(1000px 480px at 0% -10%, #d9f3ef 0%, transparent 55%),
    radial-gradient(900px 420px at 100% 0%, #e8eef8 0%, transparent 50%),
    var(--bg);
}

a { color: var(--accent); }
a:hover { color: var(--accent-deep); }

.wrap {
  width: min(1080px, calc(100% - 2rem));
  margin: 0 auto;
}
.wrap-narrow { width: min(820px, calc(100% - 2rem)); margin: 0 auto; }
.wrap-live { width: min(720px, calc(100% - 2rem)); margin: 0 auto; }

/* —— Nav pubblica —— */
.site-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 0;
  gap: 1rem;
  flex-wrap: wrap;
}
.site-brand {
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
  text-decoration: none;
  color: var(--ink);
}
.site-brand span { color: var(--accent); font-weight: 700; font-size: 0.78rem; margin-left: 0.35rem; letter-spacing: 0; }
.site-links {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}
.site-links a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
}
.site-links a:hover,
.site-links a.active { color: var(--accent); }

/* —— Tipografia —— */
.eyebrow {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
h1, .h1 {
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.2rem, 7vw, 4rem);
  letter-spacing: -0.05em;
  line-height: 0.95;
}
h2, .h2 {
  margin: 0 0 0.4rem;
  font-family: var(--display);
  font-size: clamp(1.45rem, 3vw, 2rem);
  letter-spacing: -0.03em;
}
h3, .h3 {
  margin: 0 0 0.35rem;
  font-family: var(--display);
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}
.lead {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  line-height: 1.55;
  font-weight: 500;
  max-width: 36rem;
}
.muted { color: var(--muted); font-weight: 500; }
.mono { font-family: var(--mono); font-size: 0.85rem; }

/* —— Bottoni —— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.85rem 1.2rem;
  border-radius: 14px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, filter 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { filter: brightness(1.05); color: #fff; }
.btn-ghost {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--line);
  box-shadow: var(--shadow);
}
.btn-ghost:hover { color: var(--ink); }
.btn-sm { padding: 0.5rem 0.9rem; border-radius: 10px; font-size: 0.9rem; }
.btn .meta { font-size: 0.78rem; font-weight: 600; opacity: 0.85; }

.cta { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 0.35rem; }

/* —— Card / panel —— */
.card, .panel {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.35rem 1.4rem;
}
.card + .card, .panel + .panel { margin-top: 1rem; }

/* —— Form —— */
.field { display: grid; gap: 0.4rem; margin-bottom: 0.9rem; }
.field label {
  font-weight: 700;
  font-size: 0.88rem;
}
.field .hint { font-size: 0.8rem; color: var(--muted); font-weight: 500; }
input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="number"],
input[type="date"],
input[type="search"],
select,
textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line);
  font: inherit;
  background: #fff;
  color: var(--ink);
}
input:focus, select:focus, textarea:focus {
  outline: 2px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
}
textarea { min-height: 5rem; resize: vertical; }

/* —— Feedback —— */
.flash, .note, .err, .ok-box {
  margin: 0 0 1rem;
  padding: 0.9rem 1.05rem;
  border-radius: 14px;
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.45;
}
.flash, .note {
  background: var(--accent-soft);
  color: #115e59;
}
.err {
  background: var(--danger-soft);
  border: 1.5px solid #fecaca;
  color: var(--danger);
}
.ok-box {
  background: var(--ok-soft);
  border: 1.5px solid #bbf7d0;
  color: var(--ok);
}
.warn-box {
  margin: 0 0 1rem;
  padding: 0.9rem 1.05rem;
  border-radius: 14px;
  background: var(--warn-soft);
  border: 1px solid var(--warn-line);
  color: #7c2d12;
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.45;
}

/* —— Badge —— */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-fail { background: var(--danger-soft); color: var(--danger); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-neutral { background: #f1f5f9; color: var(--ink); }
.badge-live { background: #d1fae5; color: #047857; }

/* —— Tables —— */
.table-wrap { overflow-x: auto; }
table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
table.data th,
table.data td {
  text-align: left;
  padding: 0.6rem 0.5rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
table.data th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

/* —— Sezioni landing —— */
.section { padding: 1.75rem 0 2.75rem; }
.section-head { margin-bottom: 1.25rem; max-width: 40rem; }
.section-head p { margin: 0; color: var(--muted); font-weight: 500; line-height: 1.5; }

.hero {
  padding: clamp(2rem, 6vw, 4rem) 0 clamp(2.5rem, 5vw, 3.25rem);
  display: grid;
  gap: 1.75rem;
  align-items: center;
}
@media (min-width: 900px) {
  .hero {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 2.5rem;
  }
}
.hero-copy { display: grid; gap: 1.15rem; max-width: 40rem; }
.hero-visual {
  margin: 0;
  border-radius: 22px;
  overflow: hidden;
  border: 1.5px solid var(--line);
  box-shadow: var(--shadow);
  background: var(--surface);
}
.hero-visual img,
.hero-visual video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #e8eef4;
}

.pillars {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .pillars { grid-template-columns: 1fr 1fr; }
}
.pillar {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.25rem;
  box-shadow: var(--shadow);
}
.pillar .tag {
  margin: 0 0 0.45rem;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.pillar p { margin: 0; color: var(--muted); font-size: 0.92rem; line-height: 1.45; font-weight: 500; }

.keys {
  display: grid;
  gap: 0.65rem;
}
@media (min-width: 720px) {
  .keys { grid-template-columns: 1fr 1fr; }
}
.key-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.45rem 0;
  border-top: 1px solid var(--line);
  font-size: 0.92rem;
}
.key-row:first-of-type { border-top: 0; }
.key-row code {
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 600;
  background: #f1f5f9;
  padding: 0.2rem 0.45rem;
  border-radius: 8px;
  white-space: nowrap;
}
.key-row span { color: var(--muted); font-weight: 500; text-align: right; }

.plans {
  display: grid;
  gap: 0.85rem;
}
@media (min-width: 800px) {
  .plans { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}
.plan {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 20px;
  padding: 1.35rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.plan.featured {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: linear-gradient(180deg, #f0fdfa 0%, #fff 55%);
}
.plan .price {
  font-family: var(--display);
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.plan .price small { font-size: 0.9rem; color: var(--muted); font-weight: 600; }
.plan ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.5;
  flex: 1;
}
.plan .old { text-decoration: line-through; color: #94a3b8; font-size: 0.95rem; margin-right: 0.35rem; }

.download-grid {
  display: grid;
  gap: 0.85rem;
}
@media (min-width: 720px) {
  .download-grid { grid-template-columns: 1fr 1fr; }
}
.dl {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 20px;
  padding: 1.4rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.dl p { margin: 0; color: var(--muted); font-weight: 500; line-height: 1.45; flex: 1; }
.dl ol {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.5;
}

.faq details {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 14px;
  padding: 0.9rem 1.1rem;
  box-shadow: var(--shadow);
  margin-bottom: 0.65rem;
}
.faq summary {
  cursor: pointer;
  font-weight: 700;
  font-family: var(--display);
}
.faq details p {
  margin: 0.65rem 0 0;
  color: var(--muted);
  font-weight: 500;
  line-height: 1.5;
}

.site-footer {
  padding: 2rem 0 2.75rem;
  color: #8b95a5;
  font-size: 0.82rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  justify-content: space-between;
}
.site-footer a { color: var(--muted); font-weight: 600; text-decoration: none; }
.site-footer a:hover { color: var(--accent); }

/* checkout helpers */
.plan-summary {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 1.2rem;
  border-radius: 16px;
  background: linear-gradient(180deg, #f0fdfa 0%, #ffffff 70%);
  border: 1.5px solid color-mix(in srgb, var(--accent) 35%, var(--line));
  margin-bottom: 1.2rem;
}
.method-grid { display: grid; gap: 0.65rem; }
.method-option {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.95rem 1rem;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  cursor: pointer;
  background: #fff;
}
.method-option:has(input:checked) {
  border-color: color-mix(in srgb, var(--accent) 50%, var(--line));
  background: #f0fdfa;
}
.token-box {
  font-family: var(--mono);
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  background: #0b1220;
  color: #f8fafc;
  word-break: break-all;
}

.page-pad { padding: 1.5rem 0 3rem; }

/* steps / how-it-works */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.step {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
  display: grid;
}
@media (min-width: 760px) {
  .step { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.95fr); min-height: 240px; }
  .step:nth-child(even) { grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.25fr); }
  .step:nth-child(even) .step-media { order: 2; }
  .step:nth-child(even) .step-body { order: 1; }
}
.step-media {
  margin: 0;
  background: #dfe7ef;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
}
.step-media img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 320px;
  object-fit: contain;
  padding: 0.65rem;
}
.step-body { padding: 1.25rem 1.35rem; display: flex; flex-direction: column; justify-content: center; }
.step .n {
  display: inline-flex;
  width: 1.7rem; height: 1.7rem;
  align-items: center; justify-content: center;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 800;
  font-size: 0.85rem;
  margin-bottom: 0.65rem;
}
.step strong { display: block; font-family: var(--display); font-size: 1.05rem; margin-bottom: 0.35rem; }
.step span { color: var(--muted); font-size: 0.92rem; line-height: 1.45; font-weight: 500; }

.video-card {
  border-radius: 20px;
  overflow: hidden;
  border: 1.5px solid var(--line);
  box-shadow: var(--shadow);
  background: #0b1220;
}
.video-card video { display: block; width: 100%; aspect-ratio: 16/9; }
.video-caption {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  justify-content: space-between;
  padding: 0.85rem 1.1rem;
  background: var(--surface);
  color: var(--muted);
  font-weight: 600;
  font-size: 0.88rem;
}
.video-badge {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.plan-picks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.55rem;
  margin: 0.75rem 0 1.1rem;
}
.plan-pick { position: relative; cursor: pointer; display: block; }
.plan-pick input { position: absolute; opacity: 0; pointer-events: none; }
.plan-pick-box {
  border: 1.5px solid var(--line);
  border-radius: 13px;
  padding: 0.75rem;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.plan-pick input:checked + .plan-pick-box {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.plan-pick-box strong { font-size: 0.9rem; }
.pick-price { font-family: var(--display); font-weight: 800; font-size: 1.15rem; }
.pick-days { font-size: 0.75rem; color: var(--muted); font-weight: 600; }

.pay-methods-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.6rem;
}
.pay-method-opt { position: relative; cursor: pointer; display: block; }
.pay-method-opt input { position: absolute; opacity: 0; pointer-events: none; }
.pay-method-box {
  border: 1.5px solid var(--line);
  border-radius: 13px;
  padding: 0.7rem 0.85rem;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.pay-method-opt input:checked + .pay-method-box {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.pay-method-box strong { font-size: 0.9rem; }
.pay-method-box span { font-size: 0.73rem; color: var(--muted); font-weight: 600; }

.summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.75rem;
  margin: 1.1rem 0;
}
.summary-item span {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 0.25rem;
}
.summary-item strong { font-size: 0.95rem; }
.pay-box {
  padding: 1.15rem;
  border-radius: 16px;
  border: 1.5px solid color-mix(in srgb, var(--accent) 35%, var(--line));
  background: linear-gradient(180deg, #f0fdfa 0%, #ffffff 100%);
  margin: 1rem 0;
}
.token-success {
  padding: 1.35rem;
  border-radius: 18px;
  border: 2px solid #10b981;
  background: #ecfdf5;
  margin: 1.1rem 0;
  text-align: center;
}
.token-success .token-code {
  font-family: var(--mono);
  font-size: clamp(1.2rem, 3.5vw, 1.6rem);
  font-weight: 700;
  color: #065f46;
  letter-spacing: 0.06em;
  user-select: all;
  display: block;
  margin: 0.5rem 0;
}

.overlay-box {
  margin: 0;
  padding: 1.15rem 1.2rem;
  border-radius: 16px;
  min-height: 7rem;
  background: #0b1220;
  color: #f8fafc;
  font-family: var(--mono);
  font-size: 1.05rem;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}
.hist { display: grid; gap: 0.55rem; margin-top: 1rem; }
.hist-item {
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: #f8fafc;
  font-size: 0.88rem;
}
.toolbar-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding: 0.9rem 1.1rem;
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.dot {
  display: inline-block;
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 999px;
  background: #94a3b8;
  margin-right: 0.35rem;
  vertical-align: middle;
}
.dot.on { background: #10b981; box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.18); }

.key-card {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem;
  box-shadow: var(--shadow);
}
.key-card h3 { margin: 0 0 0.75rem; }
