/* Token dal design system Calm (@kei/ui, colorsLight) */
:root {
  --bg: #f4f1ea;
  --surface: #ffffff;
  --surface-2: #f7f3e8;
  --elev: #fbf8ee;
  --line: rgba(20, 20, 18, 0.1);
  --hairline: rgba(20, 20, 18, 0.06);
  --ink: #101312;
  --ink-soft: #434341;
  --muted: #7c7a71;
  --faint: #b0ada2;
  --accent: #0e7a8c;
  --accent-ink: #e8f7fb;
  --accent-faint: rgba(14, 122, 140, 0.06);
  --warn: #9a6b00;
  --ok: #2e5b42;
  --cat-1: #a55c31;
  --cat-2: #6c7623;
  --cat-3: #267e5c;
  --cat-4: #3173a5;
  --cat-5: #4e36b5;
  --cat-6: #b5366d;
  --glow-1: #e6b48f;
  --glow-2: #e8c6a2;
  --glow-3: #e3c79a;
  --radius-card: 24px;
  --radius-pill: 999px;
  --shadow-soft: 0 24px 60px -24px rgba(38, 32, 20, 0.28);
  --shadow-chip: 0 12px 32px -12px rgba(38, 32, 20, 0.3);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Nunito", "SF Pro Rounded", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--hairline);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 800;
  font-size: 21px;
  letter-spacing: -0.01em;
}

.brand img {
  width: 30px;
  height: 30px;
}

.nav-links {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-links a {
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 15px;
}

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

/* ---------- Bottoni ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 16px;
  padding: 13px 26px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 10px 24px -10px rgba(14, 122, 140, 0.55);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 30px -10px rgba(14, 122, 140, 0.6);
}

.btn-ghost {
  color: var(--ink-soft);
  border: 1.5px solid var(--line);
  background: transparent;
}

.btn-ghost:hover {
  border-color: var(--ink-soft);
  color: var(--ink);
}

.btn-small {
  font-size: 14px;
  padding: 9px 18px;
}

/* ---------- Eyebrow ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: clip;
  padding: 72px 0 96px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(40px, 5.4vw, 64px);
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -0.025em;
  margin: 22px 0 20px;
}

.hero h1 .kei {
  color: var(--accent);
}

.hero-sub {
  font-size: 19px;
  color: var(--ink-soft);
  max-width: 34em;
  margin-bottom: 32px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.hero-note {
  margin-top: 18px;
  font-size: 14px;
  color: var(--muted);
}

.hero-note span {
  white-space: nowrap;
}

/* Visual: device + glow + chip flottanti */

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero-glow {
  position: absolute;
  inset: -12% -18%;
  z-index: 0;
  pointer-events: none;
  filter: blur(52px);
  opacity: 0.85;
}

.hero-glow i {
  position: absolute;
  border-radius: 50%;
}

.hero-glow i:nth-child(1) {
  width: 62%;
  height: 52%;
  left: 2%;
  top: 6%;
  background: var(--glow-1);
}

.hero-glow i:nth-child(2) {
  width: 58%;
  height: 48%;
  right: 0;
  top: 30%;
  background: var(--glow-2);
}

.hero-glow i:nth-child(3) {
  width: 54%;
  height: 44%;
  left: 22%;
  bottom: 0;
  background: var(--glow-3);
}

.device {
  position: relative;
  z-index: 1;
  width: min(340px, 78vw);
  border-radius: 54px;
  border: 10px solid #101312;
  background: #101312;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.device img {
  border-radius: 44px;
}

.float-chip {
  position: absolute;
  z-index: 2;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 18px;
  box-shadow: var(--shadow-chip);
  padding: 12px 16px;
}

.chip-planned {
  bottom: 18%;
  left: max(-16px, 2%);
  display: flex;
  align-items: center;
  gap: 10px;
}

.chip-planned .tag {
  background: var(--elev);
  border: 1px solid var(--hairline);
  color: var(--warn);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
}

.chip-planned .amount {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  font-size: 15px;
}

.chip-cat {
  top: 47%;
  right: max(-14px, 1%);
  min-width: 158px;
}

.chip-cat .row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  font-size: 15px;
}

.chip-cat .name {
  font-weight: 700;
}

.chip-cat .num {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.chip-cat .num small {
  color: var(--muted);
  font-weight: 600;
}

.chip-cat .bar {
  margin-top: 9px;
  height: 4px;
  border-radius: 4px;
  background: var(--hairline);
  overflow: hidden;
}

.chip-cat .bar i {
  display: block;
  height: 100%;
  width: 58%;
  border-radius: 4px;
  background: var(--cat-3);
}

/* ---------- Manifesto ---------- */

.manifesto {
  padding: 96px 0;
  text-align: center;
}

.manifesto blockquote {
  font-size: clamp(32px, 4.6vw, 54px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.12;
  max-width: 17em;
  margin: 0 auto 24px;
}

.manifesto blockquote em {
  font-style: normal;
  color: var(--accent);
}

.manifesto p {
  color: var(--ink-soft);
  max-width: 38em;
  margin: 0 auto;
  font-size: 18px;
}

/* ---------- Sezioni ---------- */

.section {
  padding: 40px 0 96px;
}

.section-head {
  max-width: 34em;
  margin-bottom: 48px;
}

.section-head h2 {
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-top: 14px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card-shot {
  height: 320px;
  overflow: hidden;
  background: var(--elev);
}

.card-shot img {
  width: 82%;
  margin: 26px auto 0;
  border-radius: 26px 26px 0 0;
  border: 6px solid #101312;
  border-bottom: 0;
  box-shadow: var(--shadow-soft);
}

.card-body {
  padding: 24px 26px 28px;
}

.card-body h3 {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.card-body p {
  color: var(--ink-soft);
  font-size: 15.5px;
}

.card-step {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--accent);
  text-transform: uppercase;
  display: block;
  margin-bottom: 10px;
}

/* Mini UI: barre categoria (card centrale) */

.mini-ui {
  height: 320px;
  background: var(--elev);
  padding: 34px 30px 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
}

.mini-row {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: 13px 16px 15px;
  box-shadow: 0 8px 20px -14px rgba(38, 32, 20, 0.25);
}

.mini-row .row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 14.5px;
}

.mini-row .name {
  font-weight: 700;
}

.mini-row .num {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.mini-row .num small {
  color: var(--muted);
  font-weight: 600;
}

.mini-row .bar {
  margin-top: 8px;
  height: 4px;
  border-radius: 4px;
  background: var(--hairline);
  overflow: hidden;
}

.mini-row .bar i {
  display: block;
  height: 100%;
  border-radius: 4px;
}

/* ---------- Privacy band ---------- */

.privacy-band {
  background: var(--surface-2);
  border: 1px solid var(--hairline);
  border-radius: 32px;
  padding: 56px 48px;
}

.privacy-band .grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin: 40px 0 36px;
}

.privacy-band h2 {
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-top: 14px;
}

.privacy-item .icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--accent-faint);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.privacy-item h3 {
  font-size: 17px;
  font-weight: 800;
  margin-bottom: 6px;
}

.privacy-item p {
  color: var(--ink-soft);
  font-size: 15px;
}

/* ---------- Footer ---------- */

.footer {
  border-top: 1px solid var(--hairline);
  padding: 40px 0 56px;
  margin-top: 96px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
  font-size: 14px;
}

.footer .brand {
  font-size: 17px;
}

.footer .brand img {
  width: 24px;
  height: 24px;
}

.footer nav {
  display: flex;
  gap: 20px;
}

.footer a {
  color: var(--ink-soft);
  font-weight: 600;
}

/* ---------- Prosa (privacy policy) ---------- */

.prose {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 24px 40px;
}

.prose h1 {
  font-size: clamp(32px, 4vw, 44px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 14px 0 10px;
}

.prose .date {
  color: var(--muted);
  font-size: 15px;
  margin-bottom: 36px;
}

.prose h2 {
  font-size: 23px;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 40px 0 12px;
}

.prose p,
.prose li {
  color: var(--ink-soft);
  margin-bottom: 12px;
}

.prose ul {
  padding-left: 22px;
  margin-bottom: 16px;
}

.prose .summary {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-left: 4px solid var(--accent);
  border-radius: 16px;
  padding: 20px 24px;
  margin: 24px 0 8px;
}

.prose .summary p {
  margin: 0;
  color: var(--ink);
  font-weight: 600;
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 56px 0;
}

.lang-note {
  font-size: 14px;
  color: var(--muted);
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .hero {
    padding: 48px 0 72px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .cards {
    grid-template-columns: 1fr;
  }

  .privacy-band {
    padding: 40px 28px;
  }

  .privacy-band .grid {
    grid-template-columns: 1fr;
  }

  .nav-links a.nav-link {
    display: none;
  }
}
