/* Font self-hosted (GDPR): variabili, sottoinsiemi latin + latin-ext */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400 600; font-display: swap; src: url('fonts/inter-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400 600; font-display: swap; src: url('fonts/inter-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Unbounded'; font-style: normal; font-weight: 500 900; font-display: swap; src: url('fonts/unbounded-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Unbounded'; font-style: normal; font-weight: 500 900; font-display: swap; src: url('fonts/unbounded-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --bg: #0d0d10;
  --bg-2: #16161b;
  --ink: #f4f1ea;
  --muted: #9a97a0;
  --line: rgba(244, 241, 234, .12);
  --pink: #f0437e;
  --lime: #d4ff3a;
  --cream: #f4f1ea;
  --dark-ink: #0d0d10;
  --radius: 24px;
  --gutter: clamp(16px, 4vw, 56px);
  --display: "Unbounded", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); line-height: 1.02; margin: 0; letter-spacing: -.02em; }
h2 { font-size: clamp(2.2rem, 6vw, 4.8rem); font-weight: 700; }
h2 em, .accent-text { font-style: normal; color: var(--pink); }
.accent { color: var(--pink); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6em;
  padding: 1em 1.6em;
  background: var(--pink); color: #fff;
  border: 0; border-radius: 999px;
  font: 600 1rem var(--body); text-decoration: none; cursor: pointer;
  transition: transform .25s, background .25s, color .25s;
}
.btn:hover { transform: translateY(-2px); background: var(--lime); color: var(--dark-ink); }
.btn span { transition: transform .25s; }
.btn:hover span { transform: translateX(4px); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover { background: var(--ink); color: var(--dark-ink); }
.btn-small { padding: .7em 1.2em; font-size: .9rem; }
.btn-full { width: 100%; justify-content: center; }

.eyebrow {
  font: 500 .8rem var(--body); text-transform: uppercase; letter-spacing: .16em;
  color: var(--muted); margin: 0 0 1.4rem; display: flex; align-items: center; gap: .6em;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 4px rgba(212,255,58,.2); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(212,255,58,0); } }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50;
  display: flex; align-items: center; gap: 2rem;
  padding: 18px var(--gutter);
  transition: background .3s, backdrop-filter .3s;
}
/* sfocatura su uno strato separato: un backdrop-filter sul .nav "intrappolerebbe" il menu mobile fixed */
.nav::before { content: ""; position: absolute; inset: 0; z-index: -2; opacity: 0; transition: opacity .3s;
  background: rgba(13,13,16,.75); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.nav.scrolled::before { opacity: 1; }
.logo { display: block; color: #fff; line-height: 0; transition: opacity .2s; }
.logo svg { width: 150px; height: 66px; }
.logo:hover { opacity: .75; }
.nav-links { display: flex; gap: 2rem; margin-left: auto; }
.nav-links a { text-decoration: none; font-weight: 500; font-size: .95rem; opacity: .8; transition: opacity .2s, color .2s; }
.nav-links a:hover { opacity: 1; color: var(--lime); }
.menu-toggle { display: none; background: none; border: 0; width: 40px; height: 40px; cursor: pointer; padding: 8px; }
.menu-toggle span { display: block; height: 2px; background: var(--ink); margin: 7px 0; transition: transform .3s; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  padding: 130px var(--gutter) 60px;
  display: flex; flex-direction: column; justify-content: flex-end;
  overflow: hidden;
}
.hero-title {
  font-size: clamp(3.2rem, 13vw, 12rem); font-weight: 900;
  line-height: .9; letter-spacing: -.05em; text-transform: uppercase;
  position: relative; z-index: 2;
}
.hero-title .line { display: block; opacity: 0; transform: translateY(40px); animation: rise .9s cubic-bezier(.2,.7,.2,1) forwards; }
.hero-title .line:nth-child(2) { animation-delay: .08s; }
.hero-title .line:nth-child(3) { animation-delay: .16s; }
.hero-title .line:nth-child(4) { animation-delay: .24s; }
.outline { color: var(--pink); font-style: italic; }
@keyframes rise { to { opacity: 1; transform: none; } }

.hero-bottom {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap;
  margin-top: 3rem; position: relative; z-index: 2;
}
.hero-lead { max-width: 30rem; margin: 0; color: var(--muted); font-size: 1.1rem; }
.hero-ctas { display: flex; gap: .8rem; flex-wrap: wrap; }
.hero-blob {
  position: absolute; z-index: 1; right: -10vw; top: 8vh;
  width: min(60vw, 720px); aspect-ratio: 1;
  background: radial-gradient(circle at 30% 30%, var(--pink), #7b2cff 55%, transparent 70%);
  filter: blur(60px); opacity: .55;
  animation: float 12s ease-in-out infinite;
}
@keyframes float { 50% { transform: translate(-6%, 8%) scale(1.08); } }

/* ---------- Marquee ---------- */
.marquee { background: var(--lime); color: var(--dark-ink); overflow: hidden; padding: 18px 0; transform: rotate(-1.5deg) scale(1.02); margin: 20px 0; }
.marquee-track { display: flex; width: max-content; gap: 1.6rem; animation: scroll 30s linear infinite; font: 700 clamp(1.2rem, 3vw, 2rem) var(--display); text-transform: uppercase; white-space: nowrap; align-items: center; }
.marquee i { font-style: normal; color: var(--pink); }
@keyframes scroll { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { padding: clamp(80px, 12vw, 160px) var(--gutter); }
.section-head { margin-bottom: clamp(40px, 6vw, 80px); }
.section-dark { background: var(--bg-2); }

/* Services */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.service {
  position: relative; padding: 36px 30px 32px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--bg-2);
  transition: transform .35s, background .35s, color .35s, border-color .35s;
  overflow: hidden;
}
.service:hover { transform: translateY(-6px); background: var(--pink); border-color: var(--pink); color: #fff; }
.service:nth-child(2):hover { background: var(--lime); border-color: var(--lime); color: var(--dark-ink); }
.service:nth-child(3):hover { background: var(--cream); border-color: var(--cream); color: var(--dark-ink); }
.service-num { font: 900 4.5rem var(--display); opacity: .18; display: block; line-height: 1; margin-bottom: 2rem; }
.service h3 { font-size: 1.6rem; margin-bottom: 1rem; }
.service p { margin: 0 0 1.6rem; opacity: .8; }
.tags { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { font-size: .8rem; font-weight: 500; padding: .35em .85em; border-radius: 999px; border: 1px solid currentColor; opacity: .7; }

/* Works */
.works { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.work { text-decoration: none; display: block; }
.work-wide { grid-column: span 2; }
.work-media {
  position: relative; aspect-ratio: 4/3; border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--brand) 70%, #fff 12%), var(--brand) 60%, color-mix(in srgb, var(--brand) 60%, #000));
  display: flex; align-items: flex-end; justify-content: center;
  padding: 9% 9% 0;
}
.work-wide .work-media { aspect-ratio: 16/8; padding: 6% 16% 0; }
.browser {
  width: 100%; background: #fff; border-radius: 12px 12px 0 0; overflow: hidden;
  box-shadow: 0 30px 60px -10px rgba(0,0,0,.55);
  transform: translateY(8%); transition: transform .7s cubic-bezier(.2,.7,.2,1);
}
.work:hover .browser { transform: translateY(2%); }
.browser-bar { display: flex; align-items: center; gap: 6px; padding: 9px 12px; background: #ececef; }
.browser-bar i { width: 9px; height: 9px; border-radius: 50%; background: #d0d0d5; }
.browser-bar i:first-child { background: #ff5f57; } .browser-bar i:nth-child(2) { background: #febc2e; } .browser-bar i:nth-child(3) { background: #28c840; }
.browser-bar span { flex: 1; margin: 0 8%; padding: 3px 10px; border-radius: 6px; background: #fff; color: #6b6870; font: 500 .72rem var(--body); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.browser img { display: block; width: 100%; aspect-ratio: 16/10; object-fit: cover; object-position: top; }
.work-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: 18px 4px 0; }
.work-meta h3 { font-size: 1.2rem; }
.work-meta p { margin: 0; color: var(--muted); font-size: .9rem; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-block: 1px solid var(--line); }
.stat { padding: 48px var(--gutter); border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat strong { display: block; font: 900 clamp(2.6rem, 6vw, 5rem) var(--display); line-height: 1; }
.stat strong::after { content: "+"; color: var(--pink); }
.stat:last-child strong::after { content: ""; }
.stat span { color: var(--muted); }

/* Steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: s; }
.step { padding-top: 28px; border-top: 2px solid var(--line); position: relative; }
.step::before { content: ""; position: absolute; top: -2px; left: 0; height: 2px; width: 0; background: var(--pink); transition: width .8s .2s; }
.step.visible::before { width: 100%; }
.step span { font: 700 .9rem var(--display); color: var(--pink); }
.step h3 { font-size: 1.4rem; margin: .8rem 0; }
.step p { margin: 0; color: var(--muted); }

/* About */
.about { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(40px, 6vw, 100px); align-items: center; }
.about-text p:not(.eyebrow) { color: var(--muted); max-width: 34rem; }
.about-text h2 { margin-bottom: 1.6rem; }
.about-text .btn { margin-top: 1rem; }
.about-card {
  background: var(--pink); color: #fff; border-radius: var(--radius);
  padding: clamp(32px, 5vw, 56px); transform: rotate(2deg);
  box-shadow: 0 30px 80px -20px rgba(240,67,126,.5);
}
.quote { font: 700 clamp(1.5rem, 3vw, 2.2rem) var(--display); line-height: 1.15; margin: 0 0 2rem; }
.about-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.about-badges span { background: var(--dark-ink); padding: .4em 1em; border-radius: 999px; font-size: .85rem; font-weight: 500; }

/* Contact */
.contact { background: var(--cream); color: var(--dark-ink); padding: clamp(80px, 12vw, 160px) var(--gutter); border-radius: 40px 40px 0 0; }
.contact .eyebrow { color: #6b6870; }
.contact-title { font-size: clamp(2.6rem, 8vw, 7rem); font-weight: 900; text-transform: uppercase; letter-spacing: -.04em; margin-bottom: clamp(40px, 6vw, 80px); }
.contact-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(40px, 6vw, 100px); }
.field { margin: 0 0 22px; border: 0; padding: 0; }
.field label, .field legend { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 8px; padding: 0; }
.field input, .field textarea {
  width: 100%; font: inherit; color: inherit; background: transparent;
  border: 0; border-bottom: 2px solid rgba(13,13,16,.2); padding: 10px 0; border-radius: 0;
  transition: border-color .2s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--pink); }
.field textarea { resize: vertical; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips label { margin: 0; cursor: pointer; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips span { display: inline-block; padding: .55em 1.1em; border-radius: 999px; border: 1.5px solid rgba(13,13,16,.25); font-weight: 500; font-size: .9rem; transition: all .2s; }
.chips input:checked + span { background: var(--dark-ink); color: var(--lime); border-color: var(--dark-ink); }
.chips input:focus-visible + span { outline: 2px solid var(--pink); outline-offset: 2px; }
.privacy { display: flex; gap: .6em; align-items: flex-start; font-size: .85rem; margin-bottom: 22px; color: #55525a; }
.privacy input { margin-top: .3em; accent-color: var(--pink); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note.err { color: #c4153f; }
.form-note { min-height: 1.4em; font-weight: 500; margin: 12px 0 0; }
.contact .btn:disabled { opacity: .6; cursor: wait; transform: none; }
.contact .btn:hover { background: var(--dark-ink); color: var(--lime); }

.contact-info { display: flex; flex-direction: column; gap: 14px; }
.contact-big {
  display: block; text-decoration: none; padding: 26px 28px; border-radius: var(--radius);
  background: #fff; font: 700 clamp(1.1rem, 2.2vw, 1.6rem) var(--display); line-height: 1.25;
  transition: transform .25s, background .25s, color .25s; overflow-wrap: anywhere;
}
a.contact-big:hover { transform: translateX(6px); background: var(--dark-ink); color: var(--lime); }
.contact-big small { display: block; font: 500 .75rem var(--body); text-transform: uppercase; letter-spacing: .14em; opacity: .55; margin-bottom: 6px; }

/* Footer */
.footer { background: var(--cream); color: var(--dark-ink); padding: 40px var(--gutter); border-top: 1px solid rgba(13,13,16,.12); display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; justify-content: space-between; font-size: .85rem; }
.footer p { margin: 0; color: #55525a; }
.footer-logo { line-height: 0; color: #000; }
.footer-logo svg { width: 140px; height: 61px; }

/* WhatsApp */
.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 60;
  width: 58px; height: 58px; border-radius: 50%; background: #25d366; color: #fff;
  display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0,0,0,.35);
  transition: transform .25s;
}
.wa-float:hover { transform: scale(1.08); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.visible { opacity: 1; transform: none; }
.about-card.reveal.visible { transform: rotate(2deg); }


/* Pagine legali */
.logo-img { display: block; width: 150px; height: auto; filter: invert(1); }
.logo-img.logo-dark { width: 140px; filter: none; }
.legal { max-width: 760px; margin: 0 auto; padding: 150px var(--gutter) 100px; }
.legal h1 { font-size: clamp(2.4rem, 7vw, 4.5rem); font-weight: 900; margin-bottom: 2rem; }
.legal h2 { font-size: 1.3rem; margin: 2.6rem 0 .8rem; scroll-margin-top: 110px; }
.legal p, .legal li { color: #c9c6cf; }
.legal ul { padding-left: 1.2rem; }
.legal li { margin-bottom: .5rem; }
.legal a:not(.btn) { color: var(--lime); }
.legal strong { color: var(--ink); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .services, .steps { grid-template-columns: 1fr 1fr; }
  .services .service:last-child { grid-column: span 2; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .about, .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .nav { gap: 1rem; }
  .nav .btn-small { margin-left: auto; }
  .menu-toggle { display: block; }
  .nav-links {
    position: fixed; inset: 0; background: var(--bg); flex-direction: column; justify-content: center;
    padding: var(--gutter); gap: 1.2rem; transform: translateY(-100%); visibility: hidden;
    transition: transform .45s cubic-bezier(.7,0,.2,1), visibility 0s .45s;
    z-index: -1;
  }
  .nav-links a { font: 700 2.2rem var(--display); opacity: 1; }
  .nav.open .nav-links { transform: none; visibility: visible; transition: transform .45s cubic-bezier(.7,0,.2,1); }
  .logo svg, .logo-img { width: 118px; height: 52px; }
  .logo-img { height: auto; }
  .nav.open .menu-toggle span:first-child { transform: translateY(4.5px) rotate(45deg); }
  .nav.open .menu-toggle span:last-child { transform: translateY(-4.5px) rotate(-45deg); }
  .services, .steps, .works { grid-template-columns: 1fr; }
  .work-wide { grid-column: auto; }
  .work-wide .work-media { aspect-ratio: 4/3; padding: 9% 9% 0; }
  .services .service:last-child { grid-column: auto; }
  .work-meta { flex-direction: column; gap: 2px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .hero-title .line, .reveal { opacity: 1; transform: none; }
}
