/* ==========================================================
   Variabili
   ========================================================== */
:root {
  --navy: #0F1E27;
  --navy-deep: #0A151C;
  --blue: #006FFE;
  --white: #FFFFFF;
  --grey-100: #F4F6F8;
  --grey-400: #8A97A3;

  --font: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 3px;
  --container: 1120px;
  --narrow: 760px;
  --header-h: 72px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* ==========================================================
   Reset e base
   ========================================================== */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.7;
  color: var(--navy);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

ul, ol { margin: 0; padding: 0; }

h1, h2, h3 { margin: 0; line-height: 1.1; letter-spacing: -0.02em; }

a { color: inherit; }

button { font: inherit; color: inherit; cursor: pointer; }

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}
.container--narrow { max-width: var(--narrow); }

/* ==========================================================
   Header
   ========================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid rgba(15, 30, 39, 0.12);
}
.site-header .container {
  display: flex;
  align-items: center;
  height: 60px;
}
.site-header__logo { height: 32px; width: auto; }

/* ==========================================================
   Sezioni comuni
   ========================================================== */
.section { padding: 80px 0; }
.section--light { background: var(--white); color: var(--navy); }
.section--grey  { background: var(--grey-100); color: var(--navy); }
.section--dark  { background: var(--navy); color: var(--white); }

.section__title {
  font-size: clamp(2rem, 6vw, 3.25rem);
  font-weight: 800;
  margin-bottom: 40px;
}

/* ==========================================================
   Sezione 1: Hero
   ========================================================== */
.hero {
  position: relative;
  min-height: calc(100vh - 60px);
  display: flex;
  align-items: center;
  background: var(--navy);
  color: var(--white);
  padding: 96px 0 120px;
}
.hero__title {
  font-size: clamp(2.5rem, 9vw, 5.5rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.02;
  max-width: 16ch;
}
.hero__sub {
  margin-top: 32px;
  font-size: clamp(1.1rem, 2.4vw, 1.4rem);
  line-height: 1.5;
  max-width: 44ch;
  color: rgba(255, 255, 255, 0.85);
}
.hero__payoff {
  margin-top: 48px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--grey-400);
}
.hero__scroll {
  position: absolute;
  left: 20px;
  bottom: 32px;
  width: 1px;
  height: 56px;
  overflow: hidden;
}
.hero__scroll-line {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--grey-400);
  transform-origin: top;
  animation: scroll-hint 2.2s var(--ease) infinite;
}
@keyframes scroll-hint {
  0%   { transform: scaleY(0); transform-origin: top; }
  50%  { transform: scaleY(1); transform-origin: top; }
  51%  { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ==========================================================
   Sezione 2: Filtro
   ========================================================== */
.filter__list {
  list-style: none;
  counter-reset: filtro;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}
.filter__list li {
  counter-increment: filtro;
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 16px;
  padding: 28px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 1.1rem;
  line-height: 1.6;
}
.filter__list li::before {
  content: counter(filtro, decimal-leading-zero);
  font-weight: 800;
  font-size: 1rem;
  color: var(--grey-400);
  padding-top: 4px;
}
.filter__close {
  margin-top: 40px;
  font-size: clamp(1.3rem, 3vw, 1.75rem);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

/* ==========================================================
   Sezione 3: Chi sono
   ========================================================== */
.about__story { font-size: 1.1rem; max-width: 60ch; }
.about__story p:first-child {
  font-size: 1.35rem;
  font-weight: 700;
}
.about__note {
  margin-top: 24px;
  padding-left: 20px;
  border-left: 3px solid var(--blue);
  color: rgba(15, 30, 39, 0.85);
}
.about__block { margin-top: 72px; }
.about__subtitle,
.edge__subtitle {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 700;
  margin-bottom: 20px;
}

/* ==========================================================
   Carosello
   ========================================================== */
.carousel {
  position: relative;
  margin-top: 32px;
  background: var(--grey-100);
  border: 1px solid rgba(15, 30, 39, 0.12);
  border-radius: var(--radius);
  overflow: hidden;
  user-select: none;
}
.carousel__viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--grey-100);
}
.carousel__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.5s var(--ease);
  pointer-events: none;
}
.carousel__slide.is-active {
  opacity: 1;
  pointer-events: auto;
}
.carousel__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 16px;
  cursor: zoom-in;
}
.carousel__caption {
  padding: 14px 16px;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  background: var(--white);
  border-top: 1px solid rgba(15, 30, 39, 0.12);
  min-height: 52px;
}
.carousel__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: 1px solid rgba(15, 30, 39, 0.2);
  border-radius: var(--radius);
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  z-index: 2;
}
.carousel__arrow:hover { border-color: var(--navy); }
.carousel__arrow--prev { left: 12px; }
.carousel__arrow--next { right: 12px; }
.carousel__arrow::before {
  content: "";
  width: 10px;
  height: 10px;
  border-top: 2px solid var(--navy);
  border-right: 2px solid var(--navy);
}
.carousel__arrow--prev::before { transform: translateX(2px) rotate(-135deg); }
.carousel__arrow--next::before { transform: translateX(-2px) rotate(45deg); }

.carousel__dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 12px 0 16px;
  background: var(--white);
}
.carousel__dot {
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
}
.carousel__dot::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--grey-400);
  transition: transform 0.2s var(--ease), background-color 0.2s;
}
.carousel__dot.is-active::before {
  background: var(--blue);
  transform: scale(1.4);
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(10, 21, 28, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.lightbox[hidden] { display: none; }
.lightbox__img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: var(--radius);
  background: var(--grey-100);
}
.lightbox__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white);
  font-size: 1.4rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.lightbox__close:hover { border-color: var(--white); }

/* ==========================================================
   Sezione 4: Edge
   ========================================================== */
.edge__block { max-width: 60ch; font-size: 1.1rem; }
.edge__block + .edge__block { margin-top: 64px; }
.edge__block--vision {
  padding: 40px;
  background: var(--white);
  border-left: 4px solid var(--blue);
  max-width: none;
}
.edge__block--vision p:first-of-type {
  font-size: 1.35rem;
  font-weight: 700;
}

/* ==========================================================
   Sezione 5: Per chi è / non è
   ========================================================== */
.fit__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}
.fit__title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  padding-bottom: 16px;
  margin-bottom: 8px;
  border-bottom: 2px solid var(--blue);
}
.fit__col--no .fit__title { border-bottom-color: var(--grey-400); }
.fit__list { list-style: none; font-size: 1.1rem; }
.fit__list li {
  padding: 18px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

/* ==========================================================
   Sezione 6: Cosa c'è dentro
   ========================================================== */
.inside__list { list-style: none; font-size: 1.1rem; max-width: 60ch; }
.inside__list li {
  padding: 16px 0 16px 28px;
  border-bottom: 1px solid rgba(15, 30, 39, 0.12);
  position: relative;
}
.inside__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 27px;
  width: 12px;
  height: 2px;
  background: var(--blue);
}
.inside__quote {
  margin: 56px 0 0;
  padding: 32px 0 0;
  border-top: 3px solid var(--navy);
  font-size: clamp(1.15rem, 2.4vw, 1.4rem);
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: -0.01em;
}

/* ==========================================================
   Sezione 7: Le due strade
   ========================================================== */
.paths__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
.path {
  padding: 36px 28px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
}
.path__title {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 800;
  margin-bottom: 20px;
}
.path__price {
  font-size: clamp(3rem, 8vw, 4.5rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  margin: 0;
}
.path__price-note {
  color: var(--grey-400);
  font-weight: 600;
  margin: 8px 0 24px;
}
.path__small {
  margin-top: 14px;
  font-size: 0.9rem;
  color: var(--grey-400);
}
.path p:not(.path__price):not(.path__price-note):not(.path__small) { color: rgba(255, 255, 255, 0.85); }

.btn {
  display: inline-block;
  margin-top: auto;
  padding: 18px 28px;
  font-weight: 700;
  font-size: 1.05rem;
  text-align: center;
  text-decoration: none;
  border-radius: var(--radius);
  border: 2px solid var(--blue);
  transition: background-color 0.2s, color 0.2s;
}
.path p + .btn { margin-top: 28px; }
.btn--primary {
  background: var(--blue);
  color: var(--white);
}
.btn--primary:hover { background: #0059CC; border-color: #0059CC; }
.btn--secondary {
  background: transparent;
  color: var(--white);
}
.btn--secondary:hover { background: rgba(0, 111, 254, 0.15); }
.btn:focus-visible { outline-color: var(--white); }

/* ==========================================================
   Sezione 8: FAQ
   ========================================================== */
.accordion { border-top: 1px solid rgba(15, 30, 39, 0.15); }
.accordion__item { border-bottom: 1px solid rgba(15, 30, 39, 0.15); }
.accordion__heading { font-size: inherit; font-weight: inherit; }
.accordion__trigger {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 22px 0;
  background: transparent;
  border: 0;
  text-align: left;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.4;
}
.accordion__trigger::after {
  content: "";
  flex: 0 0 12px;
  width: 12px;
  height: 12px;
  border-right: 2px solid var(--navy);
  border-bottom: 2px solid var(--navy);
  transform: rotate(45deg) translateY(-3px);
  transition: transform 0.25s var(--ease);
}
.accordion__trigger[aria-expanded="true"]::after {
  transform: rotate(-135deg) translateY(-3px);
}
.accordion__panel { padding: 0 0 26px; max-width: 62ch; }
.accordion__panel[hidden] { display: none; }

/* ==========================================================
   Footer
   ========================================================== */
.site-footer {
  background: var(--navy-deep);
  color: var(--white);
  padding: 64px 0 40px;
}
.site-footer__top {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}
.site-footer__logo { height: 28px; width: auto; }
.site-footer__payoff {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--grey-400);
}
.site-footer__disclaimer {
  padding: 32px 0;
  font-size: 0.95rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.85);
  max-width: 78ch;
}
.site-footer__bottom {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 0.9rem;
  color: var(--grey-400);
}
.site-footer__legal { display: flex; gap: 20px; }
.site-footer__legal a { color: var(--white); text-decoration: underline; text-underline-offset: 3px; }

/* ==========================================================
   Micro-animazioni (reveal)
   ========================================================== */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}
.no-observer .reveal {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__scroll-line { animation: none; transform: none; }
  .carousel__slide, .accordion__trigger::after, .carousel__dot::before, .btn { transition: none; }
}

/* ==========================================================
   Breakpoint: tablet
   ========================================================== */
@media (min-width: 768px) {
  body { font-size: 18px; }
  .container { padding: 0 32px; }
  .site-header .container { height: var(--header-h); }
  .site-header__logo { height: 40px; }
  .section { padding: 112px 0; }
  .hero { min-height: calc(100vh - var(--header-h)); padding: 120px 0 140px; }
  .hero__scroll { left: 32px; bottom: 40px; }
  .carousel__viewport { aspect-ratio: 16 / 10; }
  .carousel__img { padding: 24px; }
  .fit__grid { grid-template-columns: 1fr 1fr; gap: 64px; }
  .paths__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .path { padding: 44px 40px; }
  .site-footer__top { flex-direction: row; align-items: center; justify-content: space-between; }
  .site-footer__bottom { flex-direction: row; justify-content: space-between; align-items: center; }
}

/* ==========================================================
   Breakpoint: desktop
   ========================================================== */
@media (min-width: 1440px) {
  .section { padding: 140px 0; }
  .edge__block--vision { padding: 56px; }
}
