:root {
  --bg: #f5f5f3;
  --bg-alt: #ecebe8;
  --ink: #0b0b0c;
  --ink-soft: #2a2a2e;
  --muted: #6f6f74;
  --grey: #8a8a8a;
  --red: #e0194f;
  --red-deep: #b5103c;
  --red-glow: rgba(224, 25, 79, 0.08);
  --red-soft: #fde4eb;
  --teal: #0fa596;
  --teal-deep: #0b7f74;
  --teal-soft: #d8f3ef;
  --teal-glow: rgba(15, 165, 150, 0.10);
  --hairline: #d8d7d3;
  --dark: #0d0d10;
  --dark-2: #17171c;

  --sans: "Montserrat", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --max: 1280px;
  --gutter: clamp(1rem, 4vw, 3rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.6;
  font-size: clamp(15px, 1.02vw, 17px);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 50% at 100% 0%, var(--red-glow), transparent 60%),
    radial-gradient(ellipse 50% 45% at 0% 45%, var(--teal-glow), transparent 60%),
    radial-gradient(ellipse 60% 50% at 100% 100%, var(--red-glow), transparent 65%);
}
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; }
h1 { font-size: clamp(2.3rem, 5.2vw, 4.4rem); font-weight: 700; }
h2 { font-size: clamp(1.8rem, 3.6vw, 3rem); }
h3 { font-size: 1.2rem; letter-spacing: -0.01em; }
h1 em, h2 em { font-style: normal; font-weight: 300; color: var(--grey); }
p { margin: 0; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--mono); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; }
.eyebrow {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--red); display: flex; align-items: center; gap: .6rem; margin-bottom: 1.25rem;
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: var(--red); }
.eyebrow span { color: var(--ink); }
.lead { font-size: clamp(1rem, 1.25vw, 1.15rem); color: var(--ink-soft); max-width: 62ch; margin-top: 1.25rem; font-weight: 400; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  background: var(--ink); color: #fff; padding: .85rem 1.35rem; border-radius: 999px;
  font-weight: 600; font-size: .9rem; border: 1px solid var(--ink);
  transition: background .2s, transform .2s, border-color .2s;
}
.btn:hover { background: var(--red); border-color: var(--red); transform: translateY(-1px); }
.btn span { transition: transform .2s; }
.btn:hover span { transform: translateX(3px); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { color: #fff; }
.btn--small { padding: .55rem 1rem; font-size: .82rem; }
.btn--light { background: #fff; color: var(--ink); border-color: #fff; }
.btn--light:hover { color: #fff; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245,245,243,.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.nav.is-scrolled { border-color: var(--hairline); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.nav__brand img { width: 168px; }
.nav__links { display: flex; align-items: center; gap: 1.75rem; font-size: .88rem; font-weight: 500; }
.nav__links a:not(.btn):hover { color: var(--red); }
.lang { display: inline-flex; border: 1px solid var(--hairline); border-radius: 999px; padding: 2px; }
.lang a { padding: .3rem .55rem; border-radius: 999px; color: var(--muted); }
.lang a[aria-current] { background: var(--ink); color: #fff; }
.lang a:not([aria-current]):hover { color: var(--red); }
.nav__toggle { display: none; background: none; border: 0; width: 40px; height: 40px; cursor: pointer; padding: 10px; }
.nav__toggle span { display: block; height: 2px; background: var(--ink); margin: 5px 0; transition: transform .2s; }

/* Hero */
.hero { padding: clamp(3rem, 8vw, 6.5rem) 0 clamp(2.5rem, 5vw, 4rem); }
.hero__grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero__copy h1 em { display: block; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }

/* Media placeholders — show a branded pattern until the real image is added */
.media {
  position: relative; margin: 0; overflow: hidden; border-radius: 18px;
  background:
    radial-gradient(circle at 72% 28%, rgba(224,25,79,.22), transparent 42%),
    radial-gradient(circle at 25% 75%, rgba(15,165,150,.22), transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(255,196,77,.25), transparent 35%),
    linear-gradient(140deg, #fffdfa, #f3efe8);
}
.media::after {
  content: attr(data-label); position: absolute; left: 1rem; bottom: .9rem;
  font-family: var(--mono); font-size: .65rem; letter-spacing: .08em; color: rgba(0,0,0,.35);
}
.media img { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; }
.media--hero { aspect-ratio: 4 / 4.4; }
.media--wide { aspect-ratio: 21 / 8; margin-top: 3rem; }
.media--product { aspect-ratio: 16 / 10; border-radius: 12px; }
.media__tag { position: absolute; z-index: 2; bottom: 1rem; left: 1rem; color: var(--ink); background: rgba(255,255,255,.8); padding: .35rem .6rem; border-radius: 6px; }

/* Stats */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr); margin: clamp(3rem, 6vw, 5rem) 0 0;
  border-top: 1px solid var(--hairline);
}
.stats div { padding: 1.5rem 1.25rem 0 0; position: relative; }
.stats div::before { content: ""; position: absolute; top: -1px; left: 0; width: 40px; height: 3px; background: var(--red); }
.stats div:nth-child(even)::before { background: var(--teal); }
.stats div + div::before { left: 1.25rem; }
.stats div + div { padding-left: 1.25rem; border-left: 1px solid var(--hairline); }
.stats dt { font-size: clamp(2rem, 3.6vw, 3rem); font-weight: 700; letter-spacing: -.03em; color: var(--ink); }
.stats dd { margin: .25rem 0 0; color: var(--muted); font-size: .9rem; }

/* Sections */
.section { padding: clamp(4rem, 9vw, 7.5rem) 0; }
.section--alt { background: var(--bg-alt); }
.section__head { margin-bottom: clamp(2.5rem, 5vw, 4rem); max-width: 880px; }

/* Production line */
.line {
  list-style: none; padding: 0; margin: 0 0 3rem;
  display: grid; grid-template-columns: repeat(5, 1fr); counter-reset: s;
  border: 1px solid var(--hairline); border-radius: 16px; overflow: hidden; background: #fff;
}
.line li { padding: 1.5rem 1.25rem; position: relative; }
.line li + li { border-left: 1px solid var(--hairline); }
.line li + li::before {
  content: "→"; position: absolute; left: -.6rem; top: 1.4rem; background: #fff; color: var(--red);
  font-size: .9rem; line-height: 1; padding: .15rem 0;
}
.line span { color: var(--red); display: block; margin-bottom: .75rem; }
.line strong { display: block; font-weight: 600; margin-bottom: .4rem; }
.line p { font-size: .88rem; color: var(--muted); }

/* Open columns — text separated by hairlines, no boxes */
.cols { display: grid; column-gap: clamp(1.5rem, 3vw, 3rem); row-gap: 2.5rem; }
.cols--3 { grid-template-columns: repeat(3, 1fr); }
.cols--4 { grid-template-columns: repeat(4, 1fr); }
.col { border-top: 1px solid var(--hairline); padding-top: 1.5rem; position: relative; display: flex; flex-direction: column; }
.col::before { content: ""; position: absolute; top: -2px; left: 0; width: 48px; height: 3px; background: var(--red); transition: width .4s ease; }
.col:nth-child(even)::before { background: var(--teal); }
.col:hover::before { width: 100%; }
.col__num { color: var(--red); margin-bottom: 1rem; }
.col:nth-child(even) .col__num { color: var(--teal); }
.col h3 { margin-bottom: .6rem; font-size: 1.35rem; }
.col p:not(.col__num) { color: var(--ink-soft); font-size: .95rem; }
.col--cta .link { margin-top: auto; padding-top: 1.5rem; font-weight: 600; color: var(--ink); display: inline-flex; gap: .4rem; }
.col--cta .link:hover { color: var(--red); }

/* Principles: big airy statements */
#principi .col h3, #principles .col h3 { font-size: clamp(1.4rem, 2vw, 1.75rem); font-weight: 500; }

/* Contact: bright gradient band */
.section--contact {
  background:
    radial-gradient(ellipse 60% 80% at 0% 0%, var(--teal-soft), transparent 60%),
    radial-gradient(ellipse 60% 80% at 100% 100%, var(--red-soft), transparent 60%),
    #fffdfa;
}
.section--contact .col { border-color: rgba(0,0,0,.12); }

/* Products */
.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.product {
  background: #fff; border: 1px solid var(--hairline); border-radius: 18px; padding: .75rem;
  display: flex; flex-direction: column; transition: transform .25s, box-shadow .25s;
}
.product:hover { transform: translateY(-4px); box-shadow: 0 24px 50px -28px rgba(0,0,0,.3); }
.product__body { padding: 1.25rem .75rem .75rem; display: flex; flex-direction: column; gap: .7rem; flex: 1; }
.product h3 { font-size: 1.45rem; }
.product__body > p:not(.tag):not(.status) { color: var(--ink-soft); font-size: .93rem; }
.tag { color: var(--red); }
.product:nth-child(even) .tag { color: var(--teal); }
.status { margin-top: auto; padding-top: .9rem; border-top: 1px solid var(--hairline); color: var(--muted); display: flex; align-items: center; gap: .5rem; }
.status i { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 4px var(--teal-glow); }
.product--cta { background: var(--ink); color: #fff; border-color: var(--ink); justify-content: center; }
.product--cta .product__body { padding: 1.75rem; justify-content: center; }
.product--cta .product__body > p:not(.tag) { color: #c9c9cc; }
.product--cta .btn { background: var(--red); border-color: var(--red); align-self: flex-start; margin-top: .75rem; }
.product--cta .btn:hover { background: #fff; color: var(--ink); border-color: #fff; }

/* Platform (dark) */
.section--dark { background: var(--dark); color: #fff; }
.section--dark .eyebrow span { color: #fff; }
.section--dark h2 em { color: #8d8d93; }
.section--dark .lead { color: #b9b9be; }
.platform { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.platform .section__head { margin-bottom: 0; }
.chips { list-style: none; padding: 0; margin: 1.75rem 0 2rem; display: flex; flex-wrap: wrap; gap: .5rem; }
.chips li { font-family: var(--mono); font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; border: 1px solid #34343b; padding: .45rem .75rem; border-radius: 999px; color: #d6d6da; }
.stack { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.stack li {
  display: grid; grid-template-columns: 2.5rem 1fr; column-gap: 1rem; align-items: baseline;
  padding: 1rem 1.25rem; border-radius: 12px; background: var(--dark-2); border: 1px solid #25252c;
  transition: border-color .25s, transform .25s;
}
.stack li:hover { border-color: var(--red); transform: translateX(-4px); }
.stack li:first-child { background: linear-gradient(90deg, rgba(224,25,79,.22), var(--dark-2)); border-color: rgba(224,25,79,.5); }
.stack li:last-child { background: linear-gradient(90deg, rgba(15,165,150,.2), var(--dark-2)); border-color: rgba(15,165,150,.45); }
.stack li:last-child span { color: #3fd1c2; }
.stack span { color: var(--red); grid-row: span 2; }
.stack strong { font-weight: 600; }
.stack em { font-style: normal; color: #8d8d93; font-size: .85rem; }

/* Steps */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 1.25rem; }
.steps li { border-top: 2px solid var(--ink); padding-top: 1.25rem; }
.steps li:first-child { border-color: var(--red); }
.steps li:last-child { border-color: var(--teal); }
.steps span { color: var(--red); }
.steps li:nth-child(even) span { color: var(--teal); }
.steps h3 { margin: .6rem 0 .5rem; }
.steps p { color: var(--muted); font-size: .92rem; }

/* Footer */
.footer { border-top: 1px solid var(--hairline); padding: 3rem 0; }
.footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; }
.footer__tag { color: var(--muted); margin-top: .5rem; }
.footer__links { display: flex; flex-wrap: wrap; gap: 1.5rem; font-size: .88rem; }
.footer__links a:hover { color: var(--red); }
.footer__copy { color: var(--muted); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* Responsive */
@media (max-width: 1024px) {
  .products, .cols--4 { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .line { grid-template-columns: repeat(3, 1fr); }
  .line li:nth-child(4) { border-left: 0; }
  .line li:nth-child(n+4) { border-top: 1px solid var(--hairline); }
  .line li:nth-child(4)::before { display: none; }
  .platform { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .nav__toggle { display: block; }
  .nav__links {
    position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; align-items: flex-start;
    background: var(--bg); padding: 1.25rem var(--gutter) 1.75rem; gap: 1.1rem; border-bottom: 1px solid var(--hairline);
    display: none;
  }
  .nav.is-open .nav__links { display: flex; }
  .nav.is-open .nav__toggle span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .nav.is-open .nav__toggle span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
  .hero__grid { grid-template-columns: 1fr; }
  .media--hero { aspect-ratio: 4 / 3; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats div:nth-child(3) { border-left: 0; padding-left: 0; }
  .cols--3 { grid-template-columns: 1fr; }
  .media--wide { aspect-ratio: 16 / 9; }
}
@media (max-width: 600px) {
  .products, .cols--4, .steps { grid-template-columns: 1fr; }
  .line { grid-template-columns: 1fr; }
  .line li + li { border-left: 0; border-top: 1px solid var(--hairline); }
  .line li + li::before { content: "↓"; left: 1.25rem; top: -.55rem; padding: 0 .3rem; }
  .line li:nth-child(4)::before { display: block; }
  .nav__brand img { width: 140px; }
}
