@import url('https://fonts.googleapis.com/css2?family=Dela+Gothic+One&family=DM+Mono:wght@400;500&family=Google+Sans+Flex:opsz,wght@12..144,400..700&display=swap');

:root {
  color-scheme: dark;
  --bg: #0f0d14;
  --surface: #17141f;
  --surface-2: #1e1a29;
  --ink: #f3f1f7;
  --muted: #a39dae;
  --line: rgb(255 255 255 / .09);
  --violet: #8c52ff;
  --violet-soft: #c5a5ff;
  --gothic: 'Dela Gothic One', 'Segoe UI', sans-serif;
  --mono: 'DM Mono', 'SFMono-Regular', Consolas, monospace;
  font-family: 'Google Sans Flex', 'Segoe UI', sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); }
a { color: inherit; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--violet-soft); outline-offset: 4px; }
.wrap { width: min(1120px, calc(100% - 48px)); margin-inline: auto; }
.eyebrow { margin: 0 0 14px; color: var(--violet-soft); font: 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.section { padding: 96px 0; }
.section-heading { margin-bottom: 44px; }
.section-heading h2, .faq-title { margin: 0; font-size: clamp(36px, 5.5vw, 64px); font-weight: 500; letter-spacing: -.055em; line-height: 1; }

/* Background shader (bg.js); CSS gradient is the fallback */
.shader-bg { position: absolute; z-index: 0; inset: 0; overflow: hidden; pointer-events: none; background: radial-gradient(60% 55% at 25% 20%, rgb(140 82 255 / .5), transparent 70%), var(--bg); }
.shader-bg canvas { display: block; width: 100%; height: 100%; }

/* Header: no box, just a progressive blur under the grid */
.progressive-blur { position: fixed; z-index: 3; inset: 0 0 auto; height: 170px; pointer-events: none; }
.progressive-blur i { position: absolute; inset: 0; }
.progressive-blur i:nth-child(1) { backdrop-filter: blur(2px); mask-image: linear-gradient(to top, transparent 0, #000 25%, #000 50%, transparent 65%); }
.progressive-blur i:nth-child(2) { backdrop-filter: blur(5px); mask-image: linear-gradient(to top, transparent 25%, #000 50%, #000 70%, transparent 85%); }
.progressive-blur i:nth-child(3) { backdrop-filter: blur(12px); mask-image: linear-gradient(to top, transparent 50%, #000 70%, #000 90%, transparent 100%); }
.progressive-blur i:nth-child(4) { backdrop-filter: blur(24px); mask-image: linear-gradient(to top, transparent 70%, #000 90%); }
.site-header { position: fixed; z-index: 4; inset: 0 0 auto; pointer-events: none; }
.nav { display: flex; height: 76px; align-items: center; justify-content: space-between; }
.nav > * { pointer-events: auto; }
.brand { display: block; padding: 9px 16px; border-radius: 99px; background: #fff; transition: background .35s ease, padding .35s ease; }
.brand img { display: block; width: 100px; height: auto; filter: brightness(0); transition: filter .35s ease; }
.is-scrolled .brand { padding: 9px 0; background: transparent; }
.is-scrolled .brand img { filter: none; }

/* Buttons */
.button { display: inline-flex; min-height: 46px; align-items: center; justify-content: center; gap: 10px; padding: 0 22px; border: 1px solid transparent; border-radius: 99px; font-size: 14px; font-weight: 500; text-decoration: none; transition: background .2s, transform .2s; }
.button:hover { transform: translateY(-2px); }
.button-primary { background: #fff; color: #17141f; }
.button-primary:hover { background: var(--violet-soft); }
.button-ghost { border-color: rgb(255 255 255 / .25); color: #fff; }
.button-ghost:hover { background: rgb(255 255 255 / .1); }

/* Hero */
.hero { position: relative; display: flex; min-height: min(860px, 100svh); overflow: hidden; }
.hero .shader-bg { -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent); mask-image: linear-gradient(to bottom, #000 60%, transparent); }
.hero-content { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 120px 0 90px; text-align: center; }
.pill { margin: 0 0 26px; padding: 7px 15px; border: 1px solid rgb(255 255 255 / .2); border-radius: 99px; background: rgb(15 13 20 / .35); color: #ece6f5; font: 11px var(--mono); letter-spacing: .04em; }
.hero h1 { margin: 0; font-size: clamp(46px, 8vw, 100px); font-weight: 500; letter-spacing: -.06em; line-height: .97; }
.hero h1 em { color: var(--violet-soft); font-style: normal; }
.hero-sub { max-width: 440px; margin: 24px 0 0; color: #d7d1e0; font-size: 17px; line-height: 1.55; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 30px; }

/* Tabs (struttura Uiverse cir-tabs): vetro scuro, indicatore viola che scorre */
.cir-tabs { position: relative; display: inline-flex; align-items: center; gap: 4px; padding: 6px; border: 1px solid rgb(255 255 255 / .2); border-radius: 999px; background: rgb(15 13 20 / .82); box-shadow: 0 14px 34px -14px rgb(0 0 0 / .7), inset 0 1px 0 rgb(255 255 255 / .1); }
.cir-tabs::before { position: absolute; top: 6px; bottom: 6px; left: var(--x, 6px); width: var(--w, 0px); border-radius: 999px; background: linear-gradient(135deg, #a77bff, #7440e8); box-shadow: 0 6px 20px -4px rgb(140 82 255 / .8), inset 0 1px 0 rgb(255 255 255 / .35); opacity: var(--o, 0); content: ''; transition: left .55s cubic-bezier(.34,1.35,.5,1), width .55s cubic-bezier(.34,1.35,.5,1), opacity .3s ease; }
.cir-tabs__r { position: absolute; opacity: 0; pointer-events: none; }
.cir-tabs__t { position: relative; z-index: 1; display: inline-flex; height: 36px; align-items: center; justify-content: center; padding: 0 18px; border-radius: 999px; color: rgb(255 255 255 / .62); font-size: 14px; font-weight: 500; text-decoration: none; white-space: nowrap; cursor: pointer; transition: color .25s ease, transform .2s ease; }
.cir-tabs__t:hover { color: #fff; }
.cir-tabs__t:active { transform: scale(.94); }
.cir-tabs__r:checked + .cir-tabs__t, .cir-tabs__t[aria-current="true"] { color: #fff; }
.cir-tabs__r:focus-visible + .cir-tabs__t, a.cir-tabs__t:focus-visible { outline: 2px solid var(--violet-soft); outline-offset: 2px; }
/* hero: due metà uguali, indicatore via CSS */
.choice-tabs .cir-tabs { display: grid; width: 280px; grid-template-columns: 1fr 1fr; --w: calc((100% - 16px) / 2); --o: 1; }
.choice-tabs .cir-tabs:has(#cir-r-cloud:checked) { --x: calc(6px + (100% - 16px) / 2 + 4px); }

.choice-tabs { display: flex; flex-direction: column; align-items: center; width: min(420px, 100%); margin-top: 52px; }
.tab-panels { margin-top: 14px; }
.tab-panel { margin: 0; color: #d7d1e0; font-size: 15px; line-height: 1.5; text-align: center; }
.tab-panel--cloud, .choice-tabs:has(#cir-r-cloud:checked) .tab-panel--self { display: none; }
.choice-tabs:has(#cir-r-cloud:checked) .tab-panel--cloud { display: block; animation: tab-in .35s ease; }
@keyframes tab-in { from { opacity: 0; transform: translateY(5px); } }

/* Features */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.feature { padding: 32px 28px 34px; border: 1px solid var(--line); border-radius: 22px; background: linear-gradient(180deg, var(--surface-2), var(--surface)); transition: transform .35s, border-color .3s; }
.feature:hover { transform: translateY(-5px); border-color: rgb(197 165 255 / .4); }
.feature svg { width: 48px; height: 48px; margin-bottom: 52px; color: var(--violet-soft); }
.feature h3 { margin: 0 0 8px; font-size: 22px; font-weight: 500; letter-spacing: -.03em; }
.feature p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }

/* Projects */
.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.project-card { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); transition: transform .35s, border-color .3s; }
.project-card:hover { transform: translateY(-5px); border-color: rgb(197 165 255 / .4); }
.project-art { position: relative; display: grid; height: 200px; place-items: center; overflow: hidden; background: radial-gradient(70% 90% at 30% 20%, var(--a, #8c52ff), transparent 75%), radial-gradient(70% 80% at 85% 90%, var(--b, #3a2470), transparent 75%), #1b1626; }
.project-art span { position: relative; z-index: 1; color: #fff; font: italic 84px/1 Georgia, serif; text-shadow: 0 6px 30px rgb(0 0 0 / .4); }
.project-art.ramo { --a: #5c7cff; --b: #2a1f6e; }
.project-art.traccia { --a: #c552ff; --b: #4a1d6e; }
.project-body { padding: 22px 24px 70px; }
.project-body h3 { margin: 0 0 6px; font-size: 26px; font-weight: 500; letter-spacing: -.04em; }
.project-body p { margin: 0; color: var(--muted); font-size: 15px; }
.badge { position: absolute; right: 22px; bottom: 22px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 99px; color: var(--violet-soft); font: 11px var(--mono); }

/* FAQ */
.faq-layout { display: grid; grid-template-columns: .7fr 1.3fr; align-items: start; gap: 60px; }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-list { border-top: 1px solid var(--line); }
.faq-item summary { position: relative; padding: 22px 36px 22px 0; cursor: pointer; font-size: 16px; font-weight: 500; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { position: absolute; right: 4px; color: var(--violet-soft); content: '+'; font: 20px var(--mono); }
.faq-item[open] summary::after { content: '−'; }
.faq-item p { margin: -4px 0 22px; color: var(--muted); font-size: 15px; line-height: 1.6; }

/* Contatti */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact-card { display: flex; flex-direction: column; gap: 12px; padding: 32px 28px; border: 1px solid var(--line); border-radius: 22px; background: linear-gradient(180deg, var(--surface-2), var(--surface)); text-decoration: none; transition: transform .35s, border-color .3s; }
.contact-card:hover { transform: translateY(-4px); border-color: rgb(197 165 255 / .45); }
.contact-card h3 { margin: 0; font-size: 24px; font-weight: 500; letter-spacing: -.04em; }
.contact-card p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.6; }
.contact-mail { margin-top: auto; padding-top: 12px; color: var(--violet-soft); font: 14px var(--mono); }
@media (max-width: 760px) { .contact-grid { grid-template-columns: 1fr; } }

/* CTA + footer */
.cta-section { padding: 0 0 100px; }
.cta-card { position: relative; display: flex; min-height: 340px; flex-direction: column; align-items: flex-start; justify-content: center; gap: 28px; overflow: hidden; padding: 56px; border: 1px solid var(--line); border-radius: 28px; background: radial-gradient(70% 120% at 100% 0%, rgb(140 82 255 / .45), transparent 70%), var(--surface); }
.cta-card h2 { margin: 0; font-size: clamp(36px, 5.5vw, 62px); font-weight: 500; letter-spacing: -.055em; line-height: 1; }
.footer { padding: 0 0 36px; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.footer-bottom a { text-decoration: none; }
.footer-bottom a:hover { color: #fff; }

/* Secondary pages */
.page-hero { position: relative; padding: 170px 0 80px; overflow: hidden; }
.page-hero .wrap { position: relative; z-index: 1; }
.page-hero .shader-bg { -webkit-mask-image: linear-gradient(to bottom, #000 50%, transparent); mask-image: linear-gradient(to bottom, #000 50%, transparent); }
.page-hero h1 { max-width: 780px; margin: 0; font-size: clamp(42px, 7vw, 76px); font-weight: 500; letter-spacing: -.055em; line-height: 1; }
.page-hero p:not(.eyebrow) { max-width: 600px; margin: 20px 0 0; color: #d7d1e0; font-size: 17px; line-height: 1.6; }
.editorial { max-width: 760px; padding: 64px 0 100px; }
.editorial .lead { color: #d7d1e0; font-size: 19px; line-height: 1.65; }
.editorial h2 { margin: 44px 0 12px; font-size: 26px; font-weight: 500; letter-spacing: -.035em; }
.editorial p, .editorial li { color: var(--muted); font-size: 16px; line-height: 1.75; }
.editorial ul { display: grid; gap: 10px; padding-left: 20px; }
.license-callout { margin: 32px 0; padding: 22px 24px; border: 1px solid rgb(197 165 255 / .3); border-radius: 18px; background: rgb(140 82 255 / .1); color: #dcd0f5; font-size: 15px; line-height: 1.7; }
.not-found { position: relative; display: grid; min-height: 100svh; place-items: center; padding: 35px 24px; background: radial-gradient(60% 55% at 30% 20%, rgb(140 82 255 / .4), transparent 70%), var(--bg); text-align: center; }
.not-found-content { max-width: 560px; }
.not-found img { width: 140px; margin-bottom: 52px; }
.error-code { color: var(--violet-soft); font: 11px var(--mono); letter-spacing: .1em; }
.not-found h1 { margin: 14px 0; font-size: clamp(40px, 8vw, 72px); font-weight: 500; letter-spacing: -.055em; line-height: 1; }
.not-found p { margin: 0 auto 26px; color: var(--muted); font-size: 16px; line-height: 1.6; }

/* Reveal */
.motion-ready .reveal { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .7s cubic-bezier(.2,.75,.25,1); }
.motion-ready .reveal.is-visible { opacity: 1; transform: none; }
.reveal[data-reveal-delay="1"] { transition-delay: 80ms; }
.reveal[data-reveal-delay="2"] { transition-delay: 160ms; }

@media (max-width: 900px) {
  .features, .projects-grid { grid-template-columns: 1fr; }
  .feature svg { margin-bottom: 28px; }
  .faq-layout { grid-template-columns: 1fr; gap: 30px; }
}
@media (max-width: 680px) {
  .wrap { width: min(100% - 36px, 500px); }
  .section { padding: 72px 0; }
  .nav { height: 64px; }
  .brand img { width: 96px; }
      .progressive-blur { height: 130px; }
  .hero-content { padding: 100px 0 60px; }
  .hero-sub { font-size: 15px; }
  .cta-card { padding: 36px 26px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

.ticly { font-family: var(--gothic); font-weight: 400; letter-spacing: 0; text-transform: lowercase; }
.footer-links .ticly { font-size: 20px; color: #fff; }
.footer-main { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding: 8px 0 28px; }
.footer-main img { display: block; width: 120px; height: auto; }
.footer-links { display: flex; flex-wrap: wrap; gap: 12px 26px; }
.footer-links a { color: var(--muted); font-size: 14px; text-decoration: none; }
.footer-links a:hover { color: #fff; }

/* Lenis */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* Problem / solution */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.split-card { padding: 36px 32px; border: 1px solid var(--line); border-radius: 24px; background: var(--surface); }
.split-card h3 { margin: 0 0 28px; font-size: 24px; font-weight: 500; letter-spacing: -.03em; }
.split-card ul { display: grid; gap: 20px; margin: 0; padding: 0; list-style: none; }
.split-card li { display: flex; align-items: flex-start; gap: 14px; font-size: 16px; line-height: 1.5; }
.split-card li svg { flex: 0 0 auto; width: 26px; height: 26px; padding: 5px; border-radius: 50%; }
.split-problem { color: var(--muted); }
.split-problem li svg { background: rgb(255 255 255 / .07); color: #8d8697; }
.split-solution { border-color: rgb(197 165 255 / .35); background: radial-gradient(90% 90% at 100% 0%, rgb(140 82 255 / .28), transparent 70%), var(--surface-2); }
.split-solution li svg { background: var(--violet); color: #fff; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

.editorial code { padding: 2px 6px; border-radius: 6px; background: rgb(255 255 255 / .08); color: #fff; font: 14px var(--mono); }
.editorial a:not(.button), .faq-item p a { color: var(--violet-soft); }
.editorial strong { color: #fff; font-weight: 600; }

.footer-bottom .ticly-link { transition: color .2s; }
.footer-bottom .ticly-link .ticly { color: #fff; }
.footer-bottom .ticly-link:hover { color: var(--violet-soft); }
.footer-bottom .ticly-link:hover .ticly { color: var(--violet-soft); }
