/* Angel Group — foglio di stile principale */

:root {
  --lime: #cfdc28;
  --lime-deep: #a9b814;
  --lime-soft: #f4f7d2;
  --ink: #1d1f23;
  --ink-2: #3c4047;
  --muted: #6b7079;
  --line: #e6e8ec;
  --bg: #ffffff;
  --bg-alt: #f6f7f4;
  --dark: #17191d;
  --dark-2: #22252b;
  --sunset: #f08a3c;
  --radius: 18px;
  --shadow: 0 10px 30px -12px rgba(20, 24, 30, .18);
  --wrap: 1160px;
  --header-h: 68px;
  --safe-l: env(safe-area-inset-left, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}

body {
  margin: 0;
  font-family: "Ubuntu", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
p { margin: 0 0 1em; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: calc(20px + var(--safe-l));
  padding-right: calc(20px + var(--safe-r));
}

.skip {
  position: absolute; left: -999px; top: 8px;
  background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100;
}
.skip:focus { left: 12px; }

:focus-visible { outline: 3px solid var(--lime-deep); outline-offset: 3px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .88);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.scrolled { border-color: var(--line); box-shadow: 0 4px 20px -12px rgba(0,0,0,.2); }

.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}

.brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; font-weight: 700; font-size: 20px; color: var(--ink);
}
.brand img { width: 44px; height: 44px; }
.brand span b { color: var(--lime-deep); font-weight: 700; }

.menu {
  display: flex; align-items: center; gap: 6px;
  list-style: none; margin: 0; padding: 0;
}
.menu a {
  display: block; padding: 10px 14px; border-radius: 999px;
  text-decoration: none; font-weight: 500; color: var(--ink-2);
  transition: background .2s, color .2s;
}
.menu a:hover { background: var(--bg-alt); color: var(--ink); }
.menu .menu-cta a { background: var(--ink); color: #fff; padding: 10px 18px; }
.menu .menu-cta a:hover { background: var(--lime); color: var(--ink); }

.nav-right { display: flex; align-items: center; gap: 8px; }
.nav-right nav { order: 1; }
.lang {
  order: 2;
  display: inline-grid; place-items: center;
  min-width: 46px; height: 42px; padding: 0 12px; border-radius: 999px;
  border: 1.5px solid var(--line); background: #fff;
  font-size: 14px; font-weight: 700; letter-spacing: .04em; text-decoration: none; color: var(--ink-2);
  transition: border-color .2s, background .2s;
}
.lang:hover { border-color: var(--lime-deep); background: var(--lime-soft); }

.menu-toggle {
  order: 3;
  display: none;
  width: 46px; height: 46px; border: 0; border-radius: 12px;
  background: var(--bg-alt); cursor: pointer; padding: 0;
  align-items: center; justify-content: center;
  -webkit-tap-highlight-color: transparent;
}
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after {
  display: block; width: 20px; height: 2px; background: var(--ink); border-radius: 2px;
  position: relative; transition: transform .25s, background .25s;
}
.menu-toggle span::before, .menu-toggle span::after { content: ""; position: absolute; left: 0; }
.menu-toggle span::before { top: -6px; }
.menu-toggle span::after { top: 6px; }
.nav-open .menu-toggle span { background: transparent; }
.nav-open .menu-toggle span::before { transform: translateY(6px) rotate(45deg); }
.nav-open .menu-toggle span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 24px; border-radius: 999px;
  font: inherit; font-weight: 500; text-decoration: none; cursor: pointer; border: 0;
  transition: transform .15s, background .2s, box-shadow .2s;
  -webkit-tap-highlight-color: transparent;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--lime); color: var(--ink); box-shadow: 0 8px 24px -10px rgba(169, 184, 20, .9); }
.btn-primary:hover { background: #dbe83c; }
.btn-ghost { background: rgba(255,255,255,.12); color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.4); }
.btn-ghost:hover { background: rgba(255,255,255,.2); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #000; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(120% 90% at 85% 10%, #3a2a36 0%, var(--dark) 55%);
  color: #fff;
  padding: 72px 0 88px;
}
.hero::before {
  content: ""; position: absolute; inset: auto -20% -40% auto;
  width: 70vw; height: 70vw; max-width: 900px; max-height: 900px;
  background: radial-gradient(circle, rgba(240,138,60,.28), transparent 65%);
  pointer-events: none;
}
.hero-grid {
  position: relative;
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  color: var(--lime); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 26px; height: 2px; background: currentColor; }
.hero h1 { font-size: clamp(34px, 5.4vw, 60px); font-weight: 700; margin-bottom: 20px; }
.hero h1 em { font-style: normal; color: var(--lime); }
.hero .lead { font-size: clamp(17px, 1.6vw, 20px); color: rgba(255,255,255,.78); max-width: 34em; margin-bottom: 32px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero-points {
  display: flex; flex-wrap: wrap; gap: 10px 22px;
  list-style: none; padding: 0; margin: 36px 0 0;
  color: rgba(255,255,255,.7); font-size: 15px;
}
.hero-points li { display: flex; align-items: center; gap: 8px; }
.hero-points svg { width: 18px; height: 18px; color: var(--lime); flex: none; }

.hero-visual { position: relative; }
.hero-visual picture img {
  width: 100%; aspect-ratio: 1 / 1; object-fit: cover;
  border-radius: 28px;
  box-shadow: 0 40px 80px -30px rgba(0,0,0,.7);
}
.hero-badge {
  position: absolute; right: -22px; top: 28px;
  display: flex; align-items: center; gap: 12px;
  background: #fff; color: var(--ink); border-radius: 16px;
  padding: 12px 16px 12px 12px; box-shadow: var(--shadow);
  font-size: 14px; line-height: 1.3;
}
.hero-badge .dot {
  width: 40px; height: 40px; border-radius: 12px; background: var(--lime);
  display: grid; place-items: center; flex: none;
}
.hero-badge .dot svg { width: 22px; height: 22px; }
.hero-badge strong { display: block; font-size: 15px; }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 680px; margin-bottom: 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head .eyebrow { color: var(--lime-deep); }
.section-head.center .eyebrow::before { display: none; }
.section-head h2 { font-size: clamp(28px, 3.6vw, 42px); }
.section-head p { color: var(--muted); font-size: 18px; margin: 0; }

/* Servizi */
.services {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
  counter-reset: svc;
}
.service {
  position: relative;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px 26px;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.service:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.service .num {
  position: absolute; top: 22px; right: 22px;
  font-size: 14px; font-weight: 700; color: var(--line);
}
.service .ico {
  width: 56px; height: 56px; border-radius: 16px;
  display: grid; place-items: center; margin-bottom: 20px;
  background: var(--c, var(--lime-soft)); color: var(--ci, var(--ink));
}
.service .ico svg { width: 28px; height: 28px; }
.service h3 { font-size: 21px; margin-bottom: 8px; }
.service p { color: var(--muted); font-size: 16px; margin: 0; }
.service.s1 { --c: #fdecd9; --ci: #c96a14; }
.service.s2 { --c: #dde6ee; --ci: #2e4a63; }
.service.s3 { --c: #e3f2d6; --ci: #4a8a1c; }
.service.s4 { --c: #d6f0f3; --ci: #16808f; }

/* Chi siamo */
.about {
  display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; align-items: center;
}
.about-logo {
  background: #fff; border-radius: 32px; padding: 40px;
  box-shadow: var(--shadow);
  max-width: 440px; width: 100%; justify-self: center;
}
.about h2 { font-size: clamp(28px, 3.6vw, 42px); }
.about p { color: var(--ink-2); font-size: 18px; }
.checks { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.checks li { display: flex; gap: 14px; align-items: flex-start; }
.checks .tick {
  width: 28px; height: 28px; border-radius: 50%; background: var(--lime);
  display: grid; place-items: center; flex: none; margin-top: 1px;
}
.checks .tick svg { width: 16px; height: 16px; }
.checks strong { display: block; }
.checks span.t { color: var(--muted); font-size: 16px; }

/* Partner */
.partners-viewport {
  --per-view: 3;
  --gap: 16px;
  --speed: 4.5s; /* tempo per far scorrere un logo */
  max-width: 760px; margin: 0 auto;
  overflow: hidden;
  padding: 10px 0 24px;
  container-type: inline-size;
}
.partners-viewport.is-marquee {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.partners {
  display: flex; width: max-content;
  list-style: none; padding: 0; margin: 0;
}
.partners.marquee {
  animation: marquee calc(var(--speed) * var(--count, 7)) linear infinite;
  will-change: transform;
}
.partners-viewport:hover .partners.marquee { animation-play-state: paused; }
@keyframes marquee {
  to { transform: translate3d(-50%, 0, 0); }
}
.partners li {
  /* margin invece di gap: così le due metà del nastro sono identiche */
  flex: 0 0 220px;
  flex-basis: calc((100cqw - (var(--per-view) - 1) * var(--gap)) / var(--per-view));
  margin-right: var(--gap);
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  display: grid; place-items: center; padding: 22px 16px; min-height: 96px;
  transition: box-shadow .25s, transform .25s;
}
/* Senza animazione (riduci movimento): griglia statica */
.partners:not(.marquee) { width: auto; flex-wrap: wrap; justify-content: center; row-gap: var(--gap); }
.partners li:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.partners img { width: 150px; max-width: 100%; height: auto; }
.partner-groups { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--line);
  font-size: 15px; color: var(--ink-2);
}
.chip i { width: 8px; height: 8px; border-radius: 50%; background: var(--lime-deep); }

/* Testimonianze */
.testimonials { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.quote {
  margin: 0; position: relative;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 36px 32px 28px; display: flex; flex-direction: column;
}
.quote::before {
  content: "\201C"; position: absolute; top: -8px; left: 26px;
  font-size: 96px; line-height: 1; font-family: Georgia, serif; color: var(--lime);
}
.quote blockquote { margin: 0 0 24px; color: var(--ink-2); font-size: 17px; }
.quote blockquote p:last-child { margin: 0; }
.quote figcaption {
  margin-top: auto; display: flex; align-items: center; gap: 14px;
  padding-top: 20px; border-top: 1px solid var(--line);
}
.quote figcaption img { width: 48px; height: 48px; border-radius: 50%; }
.quote figcaption strong { display: block; }
.quote figcaption span { color: var(--muted); font-size: 14px; }
.stars { display: flex; gap: 2px; color: #f2b01e; margin-bottom: 14px; }
.stars svg { width: 18px; height: 18px; }

/* Contatti */
.contact {
  background: var(--dark); color: #fff; position: relative; overflow: hidden;
}
.contact::before {
  content: ""; position: absolute; left: -15%; top: -40%;
  width: 60vw; height: 60vw; max-width: 760px; max-height: 760px;
  background: radial-gradient(circle, rgba(207,220,40,.16), transparent 65%);
  pointer-events: none;
}
.contact .section-head .eyebrow { color: var(--lime); }
.contact .section-head p { color: rgba(255,255,255,.7); }
.contact-grid {
  position: relative;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.contact-card {
  display: flex; align-items: center; gap: 16px;
  padding: 22px; border-radius: var(--radius);
  background: var(--dark-2); border: 1px solid rgba(255,255,255,.08);
  text-decoration: none; color: #fff;
  transition: background .2s, transform .2s, border-color .2s;
  min-width: 0;
}
.contact-card:hover { background: #2b2f36; border-color: rgba(207,220,40,.5); transform: translateY(-2px); }
.contact-card .ico {
  width: 52px; height: 52px; border-radius: 14px; background: var(--lime); color: var(--ink);
  display: grid; place-items: center; flex: none;
}
.contact-card .ico svg { width: 24px; height: 24px; }
.contact-card small { display: block; color: rgba(255,255,255,.6); font-size: 14px; }
.contact-card strong { display: block; font-size: 18px; font-weight: 500; overflow-wrap: anywhere; }

.social-row {
  position: relative;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px;
  margin-top: 40px; padding: 26px 28px; border-radius: var(--radius);
  background: linear-gradient(100deg, rgba(207,220,40,.14), rgba(240,138,60,.12));
  border: 1px solid rgba(255,255,255,.08);
}
.social-row p { margin: 0; font-size: 18px; }
.social-row p span { display: block; color: rgba(255,255,255,.65); font-size: 15px; }
.socials { display: flex; gap: 10px; }
.socials a {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  background: rgba(255,255,255,.08); color: #fff; transition: background .2s, color .2s;
}
.socials a:hover { background: var(--lime); color: var(--ink); }
.socials svg { width: 22px; height: 22px; }

/* ---------- Pagina 404 ---------- */
.notfound {
  position: relative; overflow: hidden;
  background: radial-gradient(120% 90% at 85% 10%, #3a2a36 0%, var(--dark) 55%);
  color: #fff;
  min-height: calc(100vh - var(--header-h) - 80px);
  min-height: calc(100svh - var(--header-h) - 80px);
  display: flex; align-items: center;
  padding: 72px 0;
}
.notfound::before {
  content: ""; position: absolute; right: -20%; bottom: -40%;
  width: 70vw; height: 70vw; max-width: 900px; max-height: 900px;
  background: radial-gradient(circle, rgba(240,138,60,.28), transparent 65%);
  pointer-events: none;
}
.notfound-inner { position: relative; text-align: center; max-width: 720px; }
.notfound-code {
  margin: 0 0 8px;
  font-size: clamp(96px, 22vw, 180px); font-weight: 700; line-height: 1; letter-spacing: -.04em;
  color: var(--lime);
  text-shadow: 0 20px 60px rgba(207, 220, 40, .25);
}
.notfound h1 { font-size: clamp(28px, 4.4vw, 44px); margin-bottom: 16px; }
.notfound .lead { font-size: clamp(17px, 1.6vw, 19px); color: rgba(255,255,255,.8); margin: 0 auto 8px; max-width: 34em; }
.notfound .lead-en { font-size: 15px; color: rgba(255,255,255,.55); margin: 0 auto 32px; max-width: 36em; }
.notfound-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.notfound-contacts {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 24px;
  margin-top: 40px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.1);
}
.notfound-contacts a {
  display: inline-flex; align-items: center; gap: 8px;
  color: rgba(255,255,255,.8); text-decoration: none; font-size: 15px;
}
.notfound-contacts a:hover { color: var(--lime); }
.notfound-contacts svg { width: 18px; height: 18px; color: var(--lime); flex: none; }

@media (max-width: 600px) {
  .notfound { padding: 48px 0; }
  .notfound-actions .btn { flex: 1 1 100%; }
  .notfound-contacts { flex-direction: column; align-items: center; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: #0f1013; color: rgba(255,255,255,.6);
  font-size: 14px;
  padding: 28px 0 calc(28px + var(--safe-b));
}
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; }
.site-footer a { color: rgba(255,255,255,.8); text-decoration: none; }
.site-footer a:hover { color: var(--lime); }

/* Barra di contatto rapido (solo mobile) */
.quickbar { display: none; }

/* ---------- Animazioni ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { transition-duration: .01ms !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .services { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr 1fr; }
  .contact-grid .contact-card:last-child { grid-column: 1 / -1; }
}

@media (max-width: 860px) {
  :root { --header-h: 62px; }
  .menu-toggle { display: inline-flex; }
  .menu {
    position: fixed; left: 0; right: 0; top: var(--header-h);
    flex-direction: column; align-items: stretch; gap: 4px;
    padding: 12px calc(16px + var(--safe-r)) 20px calc(16px + var(--safe-l));
    background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: 0 20px 30px -20px rgba(0,0,0,.25);
    transform: translateY(-8px); opacity: 0; visibility: hidden;
    transition: opacity .2s, transform .2s, visibility .2s;
  }
  .nav-open .menu { transform: none; opacity: 1; visibility: visible; }
  .menu a { padding: 14px 16px; border-radius: 12px; font-size: 18px; }
  .menu .menu-cta a { text-align: center; margin-top: 6px; }

  .hero { padding: 40px 0 64px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual { max-width: 520px; width: 100%; margin: 0 auto; }
  .hero-badge { right: 12px; top: 12px; }

  .about { grid-template-columns: 1fr; gap: 40px; }
  .about-logo { max-width: 300px; padding: 28px; }

  .testimonials { grid-template-columns: 1fr; }
  .section { padding: 72px 0; }
}

@media (max-width: 600px) {
  body { font-size: 16px; padding-bottom: calc(68px + var(--safe-b)); }
  .wrap { padding-left: calc(16px + var(--safe-l)); padding-right: calc(16px + var(--safe-r)); }
  .brand { font-size: 18px; }
  .brand img { width: 40px; height: 40px; }

  .hero-actions .btn { flex: 1 1 100%; }
  .hero-badge {
    top: -16px; right: 8px;
    gap: 8px; padding: 7px 12px 7px 7px; border-radius: 12px;
    font-size: 11.5px;
  }
  .hero-badge .dot { width: 28px; height: 28px; border-radius: 8px; }
  .hero-badge .dot svg { width: 16px; height: 16px; }
  .hero-badge strong { font-size: 12.5px; }
  .hero-points { margin-top: 28px; }

  .services { grid-template-columns: 1fr; gap: 14px; }
  .service { display: grid; grid-template-columns: 56px 1fr; gap: 0 16px; padding: 20px; }
  .service .ico { margin: 0; grid-row: span 2; }
  .service h3 { font-size: 19px; margin-bottom: 4px; }
  .service p { font-size: 15px; }

  .section { padding: 60px 0; }
  .section-head { margin-bottom: 32px; }
  .section-head p, .about p { font-size: 16px; }

  .partners-viewport { --per-view: 2; --gap: 12px; }
  .partners li { min-height: 80px; padding: 16px 12px; }

  .quote { padding: 32px 22px 22px; }
  .quote blockquote { font-size: 16px; }

  .contact-grid { grid-template-columns: 1fr; gap: 12px; }
  .social-row { flex-direction: column; align-items: flex-start; padding: 22px; }

  .site-footer .wrap { flex-direction: column; }

  .quickbar {
    display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    padding: 10px calc(12px + var(--safe-r)) calc(10px + var(--safe-b)) calc(12px + var(--safe-l));
    background: rgba(255,255,255,.92);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    backdrop-filter: saturate(180%) blur(14px);
    border-top: 1px solid var(--line);
  }
  .quickbar .btn { min-height: 48px; padding: 0 12px; font-size: 16px; }
}
