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

:root {
  --navy: #0C2253;
  --navy-2: #16306b;
  --orange: #FD7507;
  --ink: #0a1834;
  --paper: #ffffff;
  --mist: #f3f5fa;
  --mist-2: #e9edf6;
  --line: #d7deec;
  --muted: #5b6885;
  --display: 'Sora', system-ui, sans-serif;
  --body: 'Inter', system-ui, sans-serif;
  --mono: 'JetBrains Mono', monospace;
  --shadow-sm: 0 4px 12px rgba(12, 34, 83, 0.05);
  --shadow-md: 0 8px 24px rgba(12, 34, 83, 0.08);
  --shadow-lg: 0 16px 32px rgba(12, 34, 83, 0.12);
  --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --nav-height: 150px;
  --logo-height: 150px;
  --footer-logo-height: 150px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 28px;
}

/* Typography & Badges */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--orange);
  display: inline-flex;
  align-items: center;
  gap: 0.7em;
}

.eyebrow::before {
  content: "";
  width: 34px;
  height: 1.5px;
  background: var(--orange);
  position: relative;
}

.eyebrow.dark {
  color: var(--navy);
}

.eyebrow.dark::before {
  background: var(--navy);
}

/* Header & Navigation */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
}

.nav img {
  height: var(--logo-height);
  display: block;
  width: auto;
}

.menu {
  display: flex;
  gap: 34px;
  align-items: center;
}

.menu a {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--navy);
  position: relative;
  padding: 4px 0;
}

.menu a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  height: 2px;
  width: 0;
  background: var(--orange);
  transition: width 0.25s ease;
}

.menu a:hover::after {
  width: 100%;
}

.menu a:hover {
  color: var(--orange);
}

/* Buttons */
.btn {
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.86rem;
  padding: 11px 22px;
  border-radius: 2px;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary {
  background: var(--orange);
  color: #fff;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px -10px rgba(253, 117, 7, 0.6);
}

.btn-ghost {
  background: transparent;
  color: var(--navy);
  border: 1.5px solid var(--navy);
}

.btn-ghost:hover {
  background: var(--navy);
  color: #fff;
}

.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  z-index: 110;
}

.burger span {
  width: 24px;
  height: 2px;
  background: var(--navy);
  transition: var(--transition);
  transform-origin: center;
}

.burger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger.open span:nth-child(2) {
  opacity: 0;
}

.burger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hero Section */
.hero {
  position: relative;
  padding: 120px 0 110px;
  overflow: hidden;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 2;
}

.hero-content .eyebrow {
  margin-bottom: 22px;
}

.hero h1 {
  font-family: var(--display);
  font-weight: 800;
  color: var(--navy);
  font-size: clamp(2.5rem, 5.2vw, 4.2rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 22px 0 22px;
}

.hero h1 .accent {
  color: var(--orange);
}

.hero p.lead {
  font-size: 1.12rem;
  color: var(--muted);
  max-width: 33em;
  margin: 0 auto 34px;
}

.hero-cta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}

.hero-figure {
  position: relative;
  height: 420px;
}

.blueprint {
  position: absolute;
  inset: 0;
  background: linear-gradient(var(--mist-2) 1px, transparent 1px) 0 0/40px 40px,
              linear-gradient(90deg, var(--mist-2) 1px, transparent 1px) 0 0/40px 40px,
              var(--mist);
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.blueprint svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.node {
  animation: pulse 2.6s ease-in-out infinite;
}

.node:nth-child(2) {
  animation-delay: 0.5s;
}

.node:nth-child(3) {
  animation-delay: 1s;
}

@keyframes pulse {
  0%, 100% {
    opacity: 0.35;
  }
  50% {
    opacity: 1;
  }
}

.dash {
  stroke-dasharray: 6 8;
  animation: flow 3s linear infinite;
}

@keyframes flow {
  to {
    stroke-dashoffset: -56;
  }
}

.float-tag {
  position: absolute;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 3px solid var(--orange);
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--navy);
  padding: 8px 12px;
  border-radius: 2px;
  box-shadow: 0 8px 24px -16px rgba(12, 34, 83, 0.5);
  pointer-events: none;
}

.tag-1 {
  top: 26px;
  left: 24px;
}

.tag-2 {
  bottom: 30px;
  right: 22px;
}

/* General Sections */
section.block {
  padding: 92px 0;
}

#azienda,
#prodotti,
#contatti {
  scroll-margin-top: calc(var(--nav-height) + 20px);
}

.sec-head {
  max-width: 46em;
  margin-bottom: 54px;
}

.sec-head h2 {
  font-family: var(--display);
  font-weight: 700;
  color: var(--navy);
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 18px 0 16px;
}

.sec-head p {
  color: var(--muted);
  font-size: 1.05rem;
  text-align: justify;
}

/* Azienda Section */
.azienda {
  background: var(--mist);
}

.profile-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 54px;
  align-items: center;
}

.profile-text h2 {
  font-family: var(--display);
  font-weight: 700;
  color: var(--navy);
  font-size: clamp(1.8rem, 3.4vw, 2.5rem);
  line-height: 1.12;
  margin: 16px 0 18px;
  letter-spacing: -0.015em;
}

.profile-text p {
  color: var(--muted);
  margin-bottom: 16px;
  text-align: justify;
}

.profile-card {
  background: var(--navy);
  color: #fff;
  border-radius: 4px;
  padding: 42px 38px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.profile-card::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -40px;
  width: 180px;
  height: 180px;
  border: 1.5px solid rgba(253, 117, 7, 0.4);
  border-radius: 50%;
  pointer-events: none;
}

.profile-card h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.4rem;
  margin-bottom: 18px;
}

.profile-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  z-index: 2;
}

.profile-card li {
  display: flex;
  gap: 12px;
  font-size: 0.96rem;
  color: #d6deef;
}

.profile-card li b {
  color: #fff;
  font-weight: 600;
}

.profile-card li::before {
  content: "";
  flex: 0 0 8px;
  height: 8px;
  margin-top: 9px;
  background: var(--orange);
  border-radius: 1px;
}

/* Products Section */
.product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.product-info {
  padding: 48px 44px;
  background: #fff;
}

.product-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--orange);
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 5px 11px;
  margin-bottom: 22px;
  background: var(--mist);
}

.product-badge .dot {
  width: 7px;
  height: 7px;
  background: var(--orange);
  border-radius: 50%;
}

.product-info h3 {
  font-family: var(--display);
  font-weight: 800;
  color: var(--navy);
  font-size: 2rem;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
}

.product-info .tagline {
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 20px;
}

.product-info p {
  color: var(--muted);
  margin-bottom: 26px;
  font-size: 0.98rem;
  text-align: justify;
}

.feat {
  list-style: none;
  display: grid;
  gap: 14px;
  margin-bottom: 30px;
}

.feat li {
  display: flex;
  gap: 12px;
  font-size: 0.94rem;
  color: var(--ink);
  align-items: flex-start;
}

.feat li svg {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin-top: 3px;
}

.feat li svg path {
  stroke: var(--orange);
  stroke-width: 2.2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.product-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Product Visual & Phone Mockup */
.product-visual {
  background: var(--navy);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 440px;
}

.product-visual::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px) 0 0/34px 34px,
              linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px) 0 0/34px 34px;
  pointer-events: none;
}

.phone {
  position: relative;
  z-index: 2;
  width: 210px;
  height: 420px;
  background: #0a1a40;
  border-radius: 32px;
  border: 3px solid #25407e;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.5);
  padding: 14px 12px;
  transition: var(--transition);
}

.phone:hover {
  transform: translateY(-4px);
}

.phone .notch {
  width: 60px;
  height: 5px;
  background: #25407e;
  border-radius: 3px;
  margin: 2px auto 12px;
}

.phone .screen {
  background: #fff;
  border-radius: 18px;
  width: 180px;
  height: 362px;
  overflow: hidden;
  position: relative;
}

.screen-slider {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.screen-slider .slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  object-position: top;
  display: block;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
}

.screen-slider .slide.active {
  opacity: 1;
}

.scr-top {
  background: var(--navy);
  color: #fff;
  padding: 14px 14px 12px;
  display: flex;
  align-items: center;
  gap: 9px;
}

.scr-top span {
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.78rem;
  margin-left: 4px;
}

.scr-logo {
  display: inline-flex;
  gap: 3px;
  align-items: flex-end;
}

.scr-logo i {
  display: inline-block;
  width: 6px;
  border-radius: 1px;
}

.scr-logo i.a { height: 14px; background: #9fb0d6; }
.scr-logo i.b { height: 24px; background: #fff; }
.scr-logo i.c { height: 18px; background: var(--orange); }

.scr-body {
  padding: 13px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.scr-card {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 9px 10px;
  background: #fff;
}

.scr-card .t {
  font-size: 0.62rem;
  color: var(--muted);
  font-family: var(--mono);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.scr-card .v {
  font-size: 0.82rem;
  color: var(--navy);
  font-weight: 600;
  margin-top: 3px;
}

.scr-bar {
  height: 6px;
  border-radius: 3px;
  background: var(--mist-2);
  margin-top: 7px;
  overflow: hidden;
}

.scr-bar i {
  display: block;
  height: 100%;
  background: var(--orange);
}

.scr-row {
  display: flex;
  gap: 8px;
}

.scr-row .scr-card {
  flex: 1;
}

.float-chip {
  position: absolute;
  z-index: 3;
  background: #fff;
  border-radius: 6px;
  padding: 8px 11px;
  box-shadow: 0 12px 30px -14px rgba(0, 0, 0, 0.4);
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--navy);
  display: flex;
  align-items: center;
  gap: 7px;
  pointer-events: none;
}

.float-chip .pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #1a9e5a;
}

.chip-a {
  top: 46px;
  right: 30px;
}

.chip-b {
  bottom: 54px;
  left: 26px;
}

/* Contact Section (Contatti) */
.contact {
  background: var(--navy);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.contact .wrap {
  position: relative;
  z-index: 2;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 54px;
  align-items: start;
}

.contact h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.contact h2 .accent {
  color: var(--orange);
}

.contact .lead {
  color: #aebbda;
  margin: 18px 0 8px;
  max-width: 30em;
}

.cinfo {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 8px;
}

.cinfo .row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.cinfo .row svg {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  margin-top: 3px;
}

.cinfo .row svg path,
.cinfo .row svg circle {
  stroke: var(--orange);
  stroke-width: 1.6;
  fill: none;
}

.cinfo .k {
  font-size: 0.74rem;
  color: #8497c2;
  font-family: var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cinfo .v {
  font-size: 1rem;
  color: #fff;
}

.cinfo a.v:hover {
  color: var(--orange);
}

/* Contact Form */
.form {
  background: #fff;
  border-radius: 8px;
  padding: 34px;
  box-shadow: var(--shadow-md);
  color: var(--ink);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 20px;
  margin-bottom: 22px;
}

.form-grid .field {
  margin-bottom: 0;
}

.form-grid .field.full-width {
  grid-column: span 2;
}

.form label {
  display: block;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--navy);
  margin: 0 0 6px;
  letter-spacing: 0.01em;
}

.form label .req {
  color: #d93025;
  margin-left: 2px;
}

.form input,
.form select,
.form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px 14px;
  font-family: var(--body);
  font-size: 0.95rem;
  color: var(--ink);
  background: #fff;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(12, 34, 83, 0.03);
}

.form input:focus,
.form select:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(253, 117, 7, 0.35), 0 1px 2px rgba(12, 34, 83, 0.03);
}

.form select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2316306b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px;
  padding-right: 40px;
  cursor: pointer;
}

.form textarea {
  resize: vertical;
  min-height: 120px;
}

.checkbox-field {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 4px;
}

.checkbox-field input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 3px;
  cursor: pointer;
  flex-shrink: 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  accent-color: var(--orange);
}

.checkbox-label {
  font-size: 0.82rem;
  font-weight: 500 !important;
  color: var(--muted) !important;
  line-height: 1.45;
  margin-bottom: 0 !important;
  cursor: pointer;
  user-select: none;
}

.checkbox-label a {
  color: var(--navy-2);
  text-decoration: underline;
}

.checkbox-label a:hover {
  color: var(--orange);
}

.form .btn-primary {
  width: 100%;
  padding: 13px 22px;
  font-size: 0.95rem;
  border-radius: 6px;
}

.form .note {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 12px;
  text-align: center;
}

@media (max-width: 600px) {
  .form-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .form-grid .field.full-width {
    grid-column: span 1;
  }
}

/* Footer Section */
footer {
  background: #08183c;
  color: #9fb0d6;
  padding: 54px 0 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.foot-top {
  display: grid;
  grid-template-columns: 1.4fr 1.6fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

footer img {
  height: var(--footer-logo-height);
  background: #ffffff;
  border-radius: 4px;
  padding: 10px;
  opacity: 0.95;
  margin-bottom: 16px;
  width: auto;
  display: inline-block;
}

.foot-top p {
  font-size: 0.9rem;
  max-width: 30em;
}

.foot-col h5 {
  font-family: var(--display);
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 14px;
}

.foot-col a {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 9px;
  color: #9fb0d6;
}

.foot-col a:hover {
  color: var(--orange);
}

.foot-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 24px;
  font-size: 0.8rem;
  color: #6f81a8;
}

.foot-bottom span b {
  color: #aebbda;
}

.foot-bottom a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.foot-bottom a:hover {
  color: var(--orange);
}

.foot-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

/* Animations */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* Responsive queries */
@media (max-width: 900px) {
  :root {
    --nav-height: 120px;
    --logo-height: 85px;
    --footer-logo-height: 100px;
  }

  .hero-grid,
  .profile-grid,
  .contact-grid,
  .product {
    grid-template-columns: 1fr;
  }
  
  .hero-figure {
    height: 320px;
    order: -1;
  }
  
  .product-visual {
    min-height: 380px;
    padding: 40px 0;
  }
  
  .foot-top {
    grid-template-columns: 1fr 1fr;
  }
  .foot-spacer {
    display: none;
  }
}

@media (max-width: 620px) {
  :root {
    --nav-height: 74px;
    --logo-height: 38px;
    --footer-logo-height: 80px;
  }

  .menu {
    position: fixed;
    top: var(--nav-height);
    right: 0;
    left: 0;
    background: #fff;
    flex-direction: column;
    gap: 0;
    border-bottom: 1px solid var(--line);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    box-shadow: var(--shadow-md);
  }
  
  .menu.open {
    max-height: 340px;
  }
  
  .menu a {
    padding: 16px 28px;
    width: 100%;
    border-top: 1px solid var(--line);
    display: flex;
  }
  
  .menu .btn {
    margin: 14px 28px;
    text-align: center;
    width: calc(100% - 56px);
  }
  
  .burger {
    display: flex;
  }
  
  .product-info {
    padding: 36px 26px;
  }
  
  .foot-top {
    grid-template-columns: 1fr;
  }
}

/* Accessibility settings */
@media (prefers-reduced-motion: reduce) {
  .dash, .node {
    animation: none;
  }
}
