:root{
  --bg:#020308;
  --panel:#040812;

  --text:#ffffff;
  --muted:#a9afbc;

  --brand:#20f2d0;
  --brand-2:#49ffc7;
  --accent:#1be8c4;

  --radius:18px;
  --shadow:0 16px 36px rgba(0,0,0,.55);
}

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

html,body{
  height:100%;
}

body{
  background:
    radial-gradient(
      900px 1200px at 0% 50%,
      rgba(32,242,208,.18) 0%,
      transparent 55%
    ),
    radial-gradient(
      900px 1200px at 100% 50%,
      rgba(73,255,199,.15) 0%,
      transparent 55%
    ),
    linear-gradient(
      180deg,
      #020308 0%,
      #030712 40%,
      #020308 100%
    );
  background-color:#020308;
  background-attachment: fixed;
  color:var(--text);
  font:400 16px/1.6 "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  padding-bottom:env(safe-area-inset-bottom);
}

.container{
  width:min(1150px, 92%);
  margin-inline:auto;
}

/* TITOLI */
.section-title{
  font-size:34px;
  margin-bottom:14px;
  position:relative;
}

.section-title::after{
  content:"";
  width:56px;
  height:3px;
  border-radius:999px;
  margin-top:8px;
  display:block;
  background:linear-gradient(90deg,var(--brand),var(--brand-2));
}

.section-subtitle{
  font-size:24px;
  margin:32px 0 14px;
  font-weight:600;
}

.section-title span,
.section-subtitle span{
  background:linear-gradient(90deg,var(--brand),var(--brand-2));
  -webkit-background-clip:text;
  background-clip:text;
  color:transparent;
}

/* offset anchor */
section{
  scroll-margin-top:100px;
}

/* HEADER */
.header-tot{
  position:fixed;
  top:0;
  left:0;
  right:0;
  background:linear-gradient(180deg,#030411,#020308);
  backdrop-filter:blur(8px);
  border-bottom:1px solid rgba(255,255,255,.06);
  z-index:1000;
}

.header-inner{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:10px 0;
  position:relative;
}

.brand-logo{
  height:72px;
  width:auto;
}

#navbar{
  display:flex;
  gap:22px;
  align-items:center;
  margin-left:-50px;
}

#navbar a{
  color:var(--text);
  opacity:.85;
  text-decoration:none;
  position:relative;
  font-size:15px;
  font-weight:500;
}

#navbar a::after{
  content:"";
  position:absolute;
  bottom:-2px;
  left:0;
  height:2px;
  width:0;
  border-radius:99px;
  background:linear-gradient(90deg,var(--brand),var(--brand-2));
  transition:.2s ease;
}

#navbar a:hover{
  opacity:1;
}

#navbar a:hover::after{
  width:100%;
}

.social-logo{
  height:48px;
  width:auto;
}

.hamburger{
  background:none;
  border:0;
  font-size:26px;
  display:none;
  color:#fff;
  cursor:pointer;
}

/* HERO */
.hero{
  position:relative;
  padding-top:120px;
  padding-bottom:90px;
  overflow:hidden;
}

.hero-inner{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:40px;
}

.hero-text{
  max-width:620px;
  position:relative;
  z-index:1;
}

.hero-kicker{
  text-transform:uppercase;
  letter-spacing:2px;
  color:var(--brand);
  font-size:12px;
  margin-bottom:8px;
}

.hero-text h1{
  font-size:clamp(50px,6vw,60px);
  margin-bottom:10px;
  line-height:1.05;
}

.hero-subtitle{
  color:var(--muted);
  margin:22px 0;
  max-width:600px;
}

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

/* COLLABORAZIONI HERO */
.hero-clients{
  min-width:220px;
  margin-top:32px;
  display:flex;
  flex-direction:column;
  gap:14px;
}

.clients-title{
  font-size:12px;
  letter-spacing:2px;
  text-transform:uppercase;
  color:var(--brand);
  opacity:.9;
}

.clients-list{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.clients-list span{
  font-size:14px;
  color:var(--muted);
  padding-left:10px;
  border-left:2px solid rgba(32,242,208,.4);
}

.clients-extra{
  opacity:.6;
  font-style:italic;
}

/* logo grande di sfondo */
.hero::after{
  content:"";
  position:absolute;
  right:-8%;
  top:50%;
  width:520px;
  height:520px;
  background:url("img/hero-da.png") no-repeat center/contain;
  opacity:0.08;
  filter:blur(1px);
  transform:translateY(-50%);
  pointer-events:none;
}

/* BOTTONI */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:99px;
  padding:12px 20px;
  font-weight:600;
  text-decoration:none;
  border:1px solid transparent;
  cursor:pointer;
}

.btn-primary{
  background:linear-gradient(90deg,var(--brand),var(--brand-2));
  color:#001410;
  box-shadow:0 0 35px rgba(32,242,208,.45);
}

.btn-primary:hover{
  transform:translateY(-2px);
}

.btn-secondary{
  color:var(--brand);
  border:1px solid rgba(32,242,208,.7);
  background:rgba(32,242,208,.08);
}

.btn-secondary:hover{
  background:rgba(32,242,208,.16);
}

/* SEZIONI */
.portfolio-section{
  padding:0 0 40px;
}

.services-section{
  padding:80px 0;
}

.about-section{
  padding:70px 0;
}

.contact-section{
  padding:70px 0 90px;
}

/* GRID */
.portfolio-grid,
.services-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(230px,1fr));
  gap:18px;
}

/* IMMAGINI PORTFOLIO */
.portfolio-grid img{
  width:100%;
  border-radius:18px;
  box-shadow:var(--shadow);
  border:1px solid rgba(255,255,255,.12);
  transition:.3s;
  background:#000;
  cursor:zoom-in;
}

.portfolio-grid img:hover{
  transform:scale(1.04);
}

/* CARD SERVIZI */
.service-card{
  background:rgba(0,0,0,.35);
  border-radius:var(--radius);
  padding:20px;
  border:1px solid rgba(255,255,255,.12);
  box-shadow:var(--shadow);
}

.service-note{
  display:inline-block;
  margin-top:6px;
  padding:6px 10px;
  font-size:13px;
  font-weight:600;
  line-height:1.3;
  color:var(--brand);
  background:rgba(32,242,208,.08);
  border:1px solid rgba(32,242,208,.35);
  border-radius:999px;
  box-shadow:0 0 12px rgba(32,242,208,.25);
}

.service-card h3{
  margin-bottom:8px;
  font-size:20px;
}

.service-card p{
  margin-bottom:8px;
  color:var(--muted);
}

/* ABOUT / CONTATTI */
.about-content{
  max-width:720px;
  color:var(--muted);
}

.about-content p + p{
  margin-top:10px;
}

.contact-text{
  color:var(--muted);
  margin:0 0 18px;
}

.contact-info p{
  margin-bottom:6px;
}

.contact-info a{
  color:var(--brand);
  text-decoration:none;
}

.contact-info a:hover{
  text-decoration:underline;
}

/* FOOTER */
footer{
  background:#020308;
  text-align:center;
  padding:20px 0 calc(20px + env(safe-area-inset-bottom));
  border-top:1px solid rgba(255,255,255,.06);
  color:var(--muted);
  font-size:14px;
}

/* LIGHTBOX */
.lightbox{
  position:fixed;
  inset:0;
  background:rgba(2,3,8,.96);
  backdrop-filter:blur(5px);
  display:flex;
  align-items:center;
  justify-content:center;
  opacity:0;
  pointer-events:none;
  transition:opacity .2s ease;
  z-index:5000;
}

.lightbox.open{
  opacity:1;
  pointer-events:auto;
}

.lightbox-img{
  max-width:92vw;
  max-height:92vh;
  object-fit:contain;
  border-radius:18px;
  box-shadow:0 0 60px rgba(0,0,0,.9);
  animation:lb-zoom .18s ease;
}

.lightbox-close{
  position:absolute;
  top:18px;
  right:24px;
  font-size:40px;
  color:#fff;
  cursor:pointer;
  opacity:.7;
}

.lightbox-close:hover{
  opacity:1;
}

@keyframes lb-zoom{
  from{ transform:scale(.92); opacity:.7; }
  to  { transform:scale(1);   opacity:1; }
}

/* RECENSIONI / CAROSELLO */
.reviews-section{
  padding:80px 0;
}

.reviews-cta-row{
  text-align:center;
  margin:14px 0 24px;
}

.reviews-wrapper{
  position:relative;
  margin-top:8px;
  background:rgba(0,0,0,.35);
  border-radius:var(--radius);
  border:1px solid rgba(255,255,255,.12);
  box-shadow:var(--shadow);
  overflow:hidden;
}

/* Messaggio quando è vuoto */
.reviews-empty{
  text-align:center;
  padding:26px 18px 30px;
  color:var(--muted);
}

.reviews-empty h3{
  margin-bottom:6px;
}

.review-track{
  display:flex;
  transition:transform .4s ease;
}

.review-card{
  min-width:100%;
 padding:22px 64px 26px;
}

.review-text{
  font-size:17px;
  line-height:1.7;
  color:var(--muted);
  margin-bottom:18px;
}

.review-author{
  font-weight:600;
  font-size:15px;
}

.review-role{
  font-size:14px;
  color:var(--muted);
}

/* frecce */
.reviews-arrow{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:32px;
  height:32px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.35);
  background:rgba(0,0,0,.7);
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  font-size:20px;
  z-index:2;
  opacity:.85;
}

.reviews-arrow.prev{ left:10px; }
.reviews-arrow.next{ right:10px; }

.reviews-arrow:hover{
  opacity:1;
  background:rgba(0,0,0,.9);
}

/* pallini */
.reviews-dots{
  display:flex;
  justify-content:center;
  gap:8px;
  padding:0 0 16px;
}

.reviews-dot{
  width:9px;
  height:9px;
  border-radius:999px;
  border:none;
  padding:0;
  background:rgba(255,255,255,.25);
  cursor:pointer;
}

.reviews-dot.active{
  width:22px;
  background:linear-gradient(90deg,var(--brand),var(--brand-2));
}

/* MODALE RECENSIONI */
.review-modal{
  position:fixed;
  inset:0;
  background:rgba(2,3,8,.9);
  backdrop-filter:blur(5px);
  display:flex;
  align-items:center;
  justify-content:center;
  opacity:0;
  pointer-events:none;
  z-index:6000;
  transition:.2s ease;
}

.review-modal.open{
  opacity:1;
  pointer-events:auto;
}

.review-modal-content{
  background:#020308;
  border-radius:18px;
  width:min(380px,92%);
  padding:22px;
  box-shadow:0 0 36px rgba(0,0,0,.8);
  border:1px solid rgba(255,255,255,.12);
  position:relative;
}

.review-modal h3{
  margin-bottom:14px;
  text-align:center;
}

.review-modal input,
.review-modal textarea{
  width:100%;
  margin-bottom:10px;
  padding:9px 11px;
  border-radius:12px;
  background:#040812;
  border:1px solid rgba(255,255,255,.12);
  color:#fff;
}

.review-modal textarea{
  min-height:90px;
  resize:vertical;
}

.review-modal-close{
  position:absolute;
  top:10px;
  right:14px;
  background:none;
  border:none;
  color:#fff;
  font-size:26px;
  cursor:pointer;
  opacity:.7;
}

.review-modal-close:hover{
  opacity:1;
}

#reviewMessage{
  margin-top:8px;
  font-size:14px;
}

/* MOBILE */
@media(max-width:900px){
  .hero-inner{
    flex-direction:column;
  }

  .hero::after{
    width:380px;
    right:-25%;
    opacity:0.06;
  }

  .hero-clients{
    margin-top:26px;
    width:100%;
    border-top:1px solid rgba(255,255,255,.08);
    padding-top:18px;
  }

  .clients-list{
    flex-direction:row;
    flex-wrap:wrap;
    gap:12px 18px;
  }

  .clients-list span{
    border-left:0;
    padding-left:0;
    font-size:13px;
  }
}

@media(max-width:768px){
  body{
    /* stesso gradiente, ma senza fixed per evitare problemi su mobile */
    background:
      radial-gradient(
        900px 1200px at 0% 50%,
        rgba(32,242,208,.18) 0%,
        transparent 55%
      ),
      radial-gradient(
        900px 1200px at 100% 50%,
        rgba(73,255,199,.15) 0%,
        transparent 55%
      ),
      linear-gradient(
        180deg,
        #020308 0%,
        #030712 40%,
        #020308 100%
      );
    background-color:#020308;
    background-attachment:scroll;
  }

  .hamburger{
    display:block;
    color:#fff;
    position:absolute;
    right:16px;
    top:50%;
    transform:translateY(-50%);
  }

  .social-logo{
    display:none;
  }

  .header-inner{
    position:relative;
  }

  #navbar{
    display:none;
    position:absolute;
    background:#020308;
    right:10px;
    top:72px;
    margin-left:0 !important;
    min-width:180px;
    flex-direction:column;
    gap:14px;
    border-radius:16px;
    padding:18px;
    border:1px solid rgba(255,255,255,.16);
    box-shadow:0 10px 30px rgba(0,0,0,.65);
  }

  #navbar.open{
    display:flex;
  }

  .hero::after{
    display:none;
  }

  .review-card{
    padding:22px 64px 26px;
  }
}
