@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --bg: #09090b;
  --surface: #0d0d10;
  --surface-2: #111114;

  --line: #242429;
  --line-soft: #19191d;

  --text: #f4f4f5;
  --muted: #a1a1aa;
  --dim: #68686f;

  --accent-live: #6ee7a8;

  --sans: "Inter", sans-serif;
  --mono: "JetBrains Mono", monospace;

  --max-width: 1180px;
}

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

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 72% 4%, rgba(255, 255, 255, 0.035), transparent 28%),
    var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
img { display: block; max-width: 100%; }
::selection { background: #f4f4f5; color: #09090b; }

.container { width: min(var(--max-width), calc(100% - 48px)); margin-inline: auto; }
.section { padding: 120px 0; }
.mono { font-family: var(--mono); }

.nav-wrap {
  position: fixed; z-index: 100; top: 0; left: 0; right: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(9, 9, 11, 0.96), rgba(9, 9, 11, 0.72), transparent);
}

.nav { height: 82px; display: flex; align-items: center; justify-content: space-between; pointer-events: auto; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; letter-spacing: -0.035em; }
.brand-mark {
  width: 30px; height: 30px; display: grid; place-items: center;
  border: 1px solid var(--line); background: rgba(255, 255, 255, 0.025);
  font-family: var(--mono); font-size: 9px; font-weight: 600;
}

.nav-links { display: flex; align-items: center; gap: 30px; color: var(--muted); font-size: 13px; }
.nav-links a { position: relative; transition: color 0.2s ease, opacity 0.2s ease; }
.nav-links a:not(.nav-cta)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -7px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform 0.25s ease;
}
.nav-links a:not(.nav-cta):hover { color: var(--text); }
.nav-links a:not(.nav-cta):hover::after { transform: scaleX(1); transform-origin: left; }

.nav-cta {
  padding: 9px 15px; border: 1px solid var(--line); border-radius: 999px;
  color: var(--text) !important; background: rgba(255, 255, 255, 0.025);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}
.nav-cta:hover { border-color: #3a3a40; background: rgba(255, 255, 255, 0.055); transform: translateY(-1px); }

.menu-toggle { display: none; width: 40px; height: 40px; border: 0; background: transparent; cursor: pointer; }
.menu-toggle span { display: block; width: 19px; height: 1px; margin: 5px auto; background: var(--text); transition: transform 0.25s ease, opacity 0.25s ease; }
.menu-open .menu-toggle span:first-child { transform: translateY(3px) rotate(45deg); }
.menu-open .menu-toggle span:last-child { transform: translateY(-3px) rotate(-45deg); }

.hero { min-height: 100svh; display: flex; align-items: center; padding-top: 150px; padding-bottom: 100px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr); gap: 80px; align-items: center; }

.eyebrow { display: flex; align-items: center; gap: 9px; margin-bottom: 25px; color: var(--muted); font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; }
.status-dot { width: 7px; height: 7px; border: 1px solid #aaa; border-radius: 50%; box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.02); }

.hero h1 { max-width: 900px; font-size: clamp(48px, 7vw, 88px); line-height: 0.98; font-weight: 700; letter-spacing: -0.068em; }
.hero h1 em { color: #85858d; font-style: normal; }
.hero-text { max-width: 650px; margin-top: 28px; color: var(--muted); font-size: 18px; line-height: 1.7; }
.hero-actions { display: flex; align-items: center; gap: 12px; margin-top: 36px; }

.button {
  min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 24px;
  padding: 0 20px; border: 1px solid var(--line); border-radius: 999px; font-size: 13px; font-weight: 600;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { border-color: #fff; background: #fff; color: #09090b; }
.button-primary:hover { background: #e8e8ea; }
.button-secondary { background: rgba(255, 255, 255, 0.025); }
.button-secondary:hover { border-color: #3b3b41; background: rgba(255, 255, 255, 0.05); }

.hero-meta { display: flex; align-items: center; gap: 12px; margin-top: 64px; color: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.09em; }
.hero-meta .meta-line { width: 44px; height: 1px; background: var(--line); }

.hero-aside { display: flex; justify-content: flex-end; }
.hero-card {
  position: relative; width: min(360px, 100%); aspect-ratio: 0.82; overflow: hidden; border: 1px solid var(--line);
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.025), transparent 42%), #0b0b0e;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.32);
}
.hero-card::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 70px 70px; opacity: 0.45;
}
.hero-card::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at center, transparent 0, transparent 42%, rgba(0, 0, 0, 0.18) 100%); pointer-events: none; }

.hero-card-top, .hero-card-bottom { position: absolute; z-index: 3; left: 18px; right: 18px; display: flex; justify-content: space-between; color: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.08em; }
.hero-card-top { top: 17px; }
.hero-card-bottom { bottom: 17px; }
.hero-card-body { position: absolute; inset: 58px 24px; display: grid; place-items: center; }

.orbit { position: absolute; border: 1px solid rgba(255, 255, 255, 0.10); border-radius: 50%; }
.orbit-one { width: 240px; height: 240px; }
.orbit-two { width: 155px; height: 155px; transform: rotate(62deg) scaleX(0.42); }

.hero-symbol {
  position: relative; z-index: 2; width: 74px; height: 74px; display: grid; place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.5); background: #0b0b0e; font-family: var(--mono); font-size: 32px; font-weight: 400;
}
.hero-card-label { position: absolute; left: 0; right: 0; bottom: 0; text-align: center; color: var(--dim); font-size: 9px; }

.section-head { display: flex; align-items: center; gap: 12px; padding-bottom: 22px; border-bottom: 1px solid var(--line-soft); color: var(--dim); font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; }
.section-number { color: #c4c4ca; }
.section-kicker { font-weight: 400; }

.about-grid { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 100px; margin-top: 60px; }
.about-title h2, .projects-intro h2, .journey-intro h2 { font-size: clamp(44px, 6vw, 74px); line-height: 0.98; font-weight: 700; letter-spacing: -0.065em; }
.about-title h2 span, .projects-intro h2 span, .journey-intro h2 span { color: #85858d; }
.about-copy .large-copy { max-width: 680px; font-size: clamp(22px, 2.4vw, 31px); line-height: 1.42; letter-spacing: -0.025em; }
.about-copy > p + p { max-width: 600px; margin-top: 27px; color: var(--muted); line-height: 1.8; }
.tech-line { display: flex; flex-wrap: wrap; gap: 0; margin-top: 34px; color: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.09em; }
.tech-line span + span::before { content: "·"; margin: 0 12px; color: #44444a; }

.projects { border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); background: linear-gradient(to bottom, rgba(255, 255, 255, 0.008), transparent 40%); }
.projects-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 50px; margin: 54px 0 62px; }
.projects-intro p { max-width: 400px; color: var(--muted); line-height: 1.75; }

.project-feature { display: grid; grid-template-columns: 1.28fr 0.72fr; gap: 48px; align-items: center; padding: 24px; border: 1px solid var(--line); background: var(--surface); }
.project-preview { overflow: hidden; border: 1px solid var(--line); background: #09090b; }
.window-bar { height: 38px; display: flex; align-items: center; gap: 7px; padding: 0 12px; border-bottom: 1px solid var(--line); }
.window-bar > span { width: 6px; height: 6px; border: 1px solid #555; border-radius: 50%; }
.window-url { margin-left: 7px; color: #555; font-size: 8px; }

.outreach-ui { display: grid; grid-template-columns: 48px 1fr; height: 430px; }
.outreach-side { padding: 13px 10px; border-right: 1px solid var(--line); }
.mini-logo { width: 28px; height: 28px; display: grid; place-items: center; margin-bottom: 30px; border: 1px solid #444; font-family: var(--mono); font-size: 10px; }
.side-line { width: 100%; height: 6px; margin: 16px 0; background: #1d1d21; }
.side-line.active { background: #68686f; }
.outreach-main { padding: 20px; }
.mini-top { display: flex; justify-content: space-between; color: #62626a; font-family: var(--mono); font-size: 8px; }
.mini-heading { display: flex; justify-content: space-between; align-items: center; margin-top: 26px; font-size: 21px; letter-spacing: -0.04em; }
.mini-badge { padding: 5px 7px; border: 1px solid #38383e; color: #898991; font-family: var(--mono); font-size: 7px; }
.mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 24px; }
.mini-stat { padding: 13px; border: 1px solid var(--line); }
.mini-stat strong { display: block; font-size: 24px; font-weight: 500; letter-spacing: -0.05em; }
.mini-stat small { display: block; margin-top: 5px; color: #5e5e65; font-family: var(--mono); font-size: 7px; }
.mini-table { margin-top: 25px; border-top: 1px solid var(--line); }
.mini-row { min-height: 38px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line-soft); color: #898991; font-size: 9px; }
.mini-row.head { color: #62626a; font-family: var(--mono); font-size: 8px; }
.mini-row b { color: #bbb; font-family: var(--mono); font-size: 7px; font-weight: 500; }

.project-feature-copy { padding-right: 15px; }
.project-topline, .meta { display: flex; align-items: center; justify-content: space-between; color: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.08em; text-transform: uppercase; }
.project-index { color: #c4c4ca; }
.project-feature-copy h3 { margin-top: 20px; font-size: clamp(40px, 5vw, 66px); line-height: 1; letter-spacing: -0.065em; }
.project-feature-copy p { margin-top: 19px; color: var(--muted); font-size: 16px; line-height: 1.75; }
.tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 25px; }
.tags span { padding: 7px 9px; border: 1px solid var(--line); color: #85858d; font-family: var(--mono); font-size: 8px; }

.text-link { display: inline-flex; align-items: center; gap: 10px; margin-top: 27px; padding-bottom: 7px; border-bottom: 1px solid #3b3b41; font-size: 13px; font-weight: 600; transition: gap 0.25s ease, border-color 0.25s ease; }
.text-link:hover { gap: 16px; border-color: #77777e; }
.text-link.disabled { color: var(--dim); border-color: var(--line-soft); cursor: default; }
.text-link.disabled:hover { gap: 10px; border-color: var(--line-soft); }

.project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 18px; }
.project-card { overflow: hidden; border: 1px solid var(--line); background: var(--surface); }
.project-thumb { position: relative; height: 280px; overflow: hidden; border-bottom: 1px solid var(--line); }
.project-thumb img { width: 100%; height: 100%; object-fit: cover; }

.project-card-copy { min-height: 255px; padding: 22px; }
.project-card-copy h3 { margin-top: 20px; font-size: 27px; line-height: 1; letter-spacing: -0.05em; }
.project-card-copy p { margin-top: 13px; color: var(--muted); font-size: 14px; line-height: 1.75; }

/* --- CLIENTI --- */

.clients { background: #0b0b0e; }
.clients-block { max-width: 850px; padding: 90px 0 30px; }
.clients-status { display: flex; align-items: center; gap: 9px; color: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.1em; }
.status-ring { width: 8px; height: 8px; border: 1px solid #888; border-radius: 50%; }
.status-ring.is-live { border-color: var(--accent-live); background: var(--accent-live); box-shadow: 0 0 0 4px rgba(110, 231, 168, 0.12); }
.clients-status:has(.is-live) { color: var(--accent-live); }

.clients-block h2 { margin-top: 25px; font-size: clamp(52px, 8vw, 96px); line-height: 0.9; letter-spacing: -0.075em; }
.clients-block h2 span { color: #85858d; }
.clients-block p { max-width: 555px; margin-top: 28px; color: var(--muted); line-height: 1.8; }

.client-card {
  margin-top: 45px;
  padding: 32px;
  border: 1px solid var(--line);
  background: var(--surface);
  max-width: 640px;
}

.client-quote {
  font-size: 19px;
  line-height: 1.55;
  letter-spacing: -0.01em;
  color: var(--text);
  font-style: normal;
}

.client-card-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line-soft);
}

.client-card-meta { display: flex; flex-direction: column; gap: 5px; }
.client-name { font-size: 14px; font-weight: 600; }
.client-business { color: var(--dim); font-size: 10px; letter-spacing: 0.06em; }
.client-card-footer .text-link { margin-top: 0; }

/* --- PERCORSO --- */

.journey-intro { margin: 54px 0 70px; }
.timeline { border-top: 1px solid var(--line); }
.timeline-item { min-height: 126px; display: grid; grid-template-columns: 62px 150px 1fr; gap: 22px; align-items: center; border-bottom: 1px solid var(--line); }
.timeline-marker { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line); color: var(--dim); font-family: var(--mono); font-size: 8px; }
.timeline-year { color: var(--dim); font-size: 8px; letter-spacing: 0.12em; }
.timeline-content h3 { font-size: 21px; line-height: 1.2; letter-spacing: -0.03em; }
.timeline-content p { max-width: 650px; margin-top: 5px; color: var(--muted); font-size: 14px; line-height: 1.65; }
.timeline-item.current .timeline-marker { border-color: #fff; background: #fff; color: #09090b; }
.timeline-item.current .timeline-year { color: #ddd; }
.timeline-item.upcoming { opacity: 0.7; }

.contact { padding-top: 90px; padding-bottom: 90px; }
.contact-panel { overflow: hidden; border: 1px solid var(--line); background: var(--surface); padding: 28px; }
.contact-content { display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; padding: 72px 50px 55px; }
.contact-content h2 { font-size: clamp(52px, 8vw, 92px); line-height: 0.9; letter-spacing: -0.08em; }
.contact-content h2 span { color: #85858d; }
.contact-content p { margin-top: 24px; color: var(--muted); }

.contact-button {
  min-width: 245px; min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 0 21px; border: 1px solid #38383e; background: rgba(255, 255, 255, 0.025); font-size: 13px; font-weight: 600;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}
.contact-button:hover { border-color: #56565f; background: rgba(255, 255, 255, 0.045); transform: translateY(-2px); }

.footer { border-top: 1px solid var(--line-soft); }
.footer-inner { min-height: 90px; display: flex; align-items: center; justify-content: space-between; color: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.07em; text-transform: uppercase; }
.footer-links { display: flex; gap: 22px; }
.footer-links a { transition: color 0.2s ease; }
.footer-links a:hover { color: var(--text); }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.75s ease, transform 0.75s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal-delay { transition-delay: 0.1s; }
.reveal-delay-1 { transition-delay: 0.12s; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 55px; }
  .hero-aside { justify-content: flex-start; }
  .hero-card { width: 300px; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .projects-intro { display: block; }
  .projects-intro p { margin-top: 24px; }
  .project-feature { grid-template-columns: 1fr; }
  .project-grid { grid-template-columns: repeat(2, 1fr); }
  .project-card:last-child { grid-column: 1 / -1; }
  .contact-content { flex-direction: column; align-items: flex-start; }
  .contact-button { width: 100%; }
  .client-card-footer { flex-direction: column; align-items: flex-start; gap: 18px; }
}

@media (max-width: 700px) {
  .container { width: calc(100% - 32px); }
  .section { padding: 85px 0; }
  .nav { height: 72px; }
  .nav-links {
    display: none; position: fixed; top: 72px; left: 16px; right: 16px;
    flex-direction: column; align-items: stretch; gap: 2px; padding: 8px;
    border: 1px solid var(--line); background: rgba(12, 12, 15, 0.97); backdrop-filter: blur(18px);
  }
  .menu-open .nav-links { display: flex; }
  .nav-links a { padding: 14px 12px; }
  .nav-cta { text-align: center; }
  .menu-toggle { display: block; }
  .hero { min-height: auto; padding-top: 130px; padding-bottom: 80px; }
  .hero h1 { font-size: clamp(44px, 13vw, 70px); }
  .hero-text { font-size: 16px; }
  .hero-actions { flex-direction: column; }
  .button { width: 100%; }
  .hero-meta { margin-top: 40px; font-size: 8px; }
  .hero-card { width: 100%; max-width: 300px; }
  .about-copy .large-copy { font-size: 22px; }
  .tech-line { line-height: 2; }
  .tech-line span + span::before { margin: 0 8px; }
  .project-feature { padding: 12px; }
  .outreach-ui { height: 310px; }
  .outreach-main { padding: 14px; }
  .mini-stats { gap: 5px; }
  .mini-stat { padding: 9px; }
  .mini-stat strong { font-size: 19px; }
  .mini-table { margin-top: 18px; }
  .project-grid { grid-template-columns: 1fr; }
  .project-card:last-child { grid-column: auto; }
  .project-thumb { height: 245px; }
  .client-card { padding: 22px; }
  .client-quote { font-size: 17px; }
  .timeline-item { grid-template-columns: 42px 1fr; gap: 13px; min-height: auto; padding: 22px 0; align-items: start; }
  .timeline-marker { grid-column: 1; grid-row: 1 / span 2; }
  .timeline-year { grid-column: 2; grid-row: 1; }
  .timeline-content { grid-column: 2; grid-row: 2; }
  .contact-panel { padding: 18px; }
  .contact-content { padding: 55px 18px 30px; }
  .contact-content h2 { font-size: clamp(48px, 14vw, 75px); }
  .contact-button { min-width: 0; }
  .footer-inner { min-height: 110px; flex-direction: column; justify-content: center; gap: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}