:root {
  --bg-color:    #ffffff;
  --navy:        #181c2e; 
  --navy-2:      #21273d;
  --violet:      #8c52ff; 
  --cyan:        #00e5ff;
  --text-main:   #181c2e;
  --gray:        #4a5568;
  --gray-2:      #a0aec0;
  --line:        rgba(24, 28, 46, 0.15);
  --line-light:  rgba(255, 255, 255, 0.1);
}

*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: auto; }

body {
  font-family:'Work Sans', sans-serif;
  background: var(--bg-color);
  color: var(--text-main);
  overflow-x: hidden;
}

/* ─── NAV & LOGO VETTORIALE ─── */
nav {
  position:fixed; top:0; left:0; right:0; z-index:1000;
  display:flex; align-items:center; justify-content:space-between;
  padding:20px 60px; transition:padding .3s, background .3s, border-color .3s;
  border-bottom:1px solid transparent;
  gap: 20px;
  /* Sempre leggibile: sfondo semi-opaco leggero di default */
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
nav.scrolled { background:rgba(255,255,255,.98); border-color:var(--line); padding:12px 60px; }

.nav-logo img { height: 45px; width: auto; max-width: 180px; object-fit: contain; display: block; }

.nav-links { display:flex; align-items:center; gap:40px; list-style:none; }
.nav-links a { font-size:12px; font-weight:700; letter-spacing:.1em; text-transform:uppercase; color:var(--navy); text-decoration:none; cursor: pointer; transition:color .2s; }
.nav-links a:hover { color:var(--violet); }
.nav-cta {
  font-family: 'Work Sans', sans-serif; font-size:12px; font-weight:700; letter-spacing:.1em; text-transform:uppercase;
  color:var(--bg-color); background:var(--navy); padding:14px 28px; text-decoration:none; cursor: pointer;
  transition:background .2s, transform .2s; white-space: nowrap;
}
.nav-cta:hover { background:var(--violet); transform:translateY(-2px); }

/* ─── HAMBURGER (nascosto su desktop) ─── */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 200;
  flex-shrink: 0;
}
.nav-toggle .bar {
  width: 24px;
  height: 2px;
  background: var(--navy);
  transition: transform .3s ease, opacity .3s ease;
}
.nav-toggle.open .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open .bar:nth-child(2) { opacity: 0; }
.nav-toggle.open .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-overlay { display: none; }

/* ─── HERO ─── */
.hero {
  min-height:95vh; display:grid; grid-template-columns:1fr 1fr; align-items:end;
  padding:140px 60px 80px; position:relative; overflow:hidden; background: #ffffff; gap:60px;
}
.hero-bg-word {
  position:absolute; bottom:-40px; right:-20px;
  font-family:'Archivo Black', sans-serif; font-size:clamp(180px,28vw,380px); 
  color:transparent; -webkit-text-stroke:2px var(--line); opacity: 0.3;
  white-space:nowrap; letter-spacing:-.05em; pointer-events:none; z-index:0;
}
.hero-left, .hero-right { position:relative; z-index:2; padding-bottom: 40px; }
.hero-right { display:flex; flex-direction:column; justify-content:flex-end; }
.hero-index { font-size:12px; font-weight:700; letter-spacing:.18em; color:var(--violet); margin-bottom:24px; text-transform:uppercase; }
.hero-title {
  font-family:'Archivo Black', sans-serif; font-size:clamp(48px, 6.5vw, 92px); 
  line-height:0.95; letter-spacing:-.02em; color:var(--navy); margin-bottom:0; text-transform:uppercase;
}
.hero-title .accent { color:var(--violet); }
.hero-sub { font-size:16px; font-weight:500; line-height:1.6; color:var(--gray); max-width:440px; margin-bottom:40px; }

/* ─── SEZIONI BASE ─── */
.section { padding:120px 60px; position:relative; }
.section-dark { background: var(--navy); color: var(--bg-color); }
.section-eye {
  display:flex; align-items:center; gap:16px; font-size:12px; font-weight:700; 
  letter-spacing:.2em; text-transform:uppercase; margin-bottom:72px; color:var(--navy);
}
.section-dark .section-eye { color:var(--bg-color); }
.section-eye::after { content:''; flex:1; height:2px; background:currentColor; max-width:60px; opacity: 0.2; }
.section-eye .eye-num { color:var(--violet); }

.big-title {
  font-family:'Archivo Black', sans-serif; font-size:clamp(38px,5vw,64px); 
  line-height:1.0; letter-spacing:-.02em; margin-bottom:36px; text-transform:uppercase; color:var(--navy);
}
.section-dark .big-title { color:var(--bg-color); }
.big-title .cy { color:var(--cyan); }
.body-text { font-size:16px; font-weight:500; line-height:1.7; max-width:600px; }
.section-dark .body-text { color:var(--gray-2); }

/* ─── METODO ─── */
.method-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 80px; }
.method-col { border-top: 2px solid var(--violet); padding-top: 32px; }
.method-title { font-family: 'Archivo Black', sans-serif; font-size: 28px; color: var(--bg-color); text-transform: uppercase; margin-bottom: 16px; }
.method-text { font-size: 15px; font-weight: 500; line-height: 1.7; color: var(--gray-2); }

/* ─── SERVIZI OGILVY STYLE ─── */
.ogilvy-services { display: flex; flex-direction: column; gap: 0; }
.og-service {
  position: relative; height: 90vh; min-height: 700px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; background: #000; border-bottom: 2px solid var(--navy);
}
.og-bg { position: absolute; top: -10%; left: 0; width: 100%; height: 120%; z-index: 1; pointer-events: none; }
.og-bg img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(100%) opacity(0.3);
  transition: filter 0.8s ease, transform 1.2s ease;
}
.og-service:hover .og-bg img { filter: grayscale(0%) opacity(0.5); transform: scale(1.05); }

.og-content {
  position: relative; z-index: 2; width: 100%; max-width: 1400px; padding: 0 60px;
  display: flex; flex-direction: column; justify-content: center;
}
.og-title {
  font-family: 'Archivo Black', sans-serif; font-size: clamp(50px, 8vw, 130px);
  line-height: 0.85; text-transform: uppercase; color: var(--bg-color); margin-bottom: 0;
  transition: color 0.4s ease;
}
.og-title-outline { color: transparent; -webkit-text-stroke: 2px rgba(255,255,255,0.6); transition: -webkit-text-stroke 0.4s ease, color 0.4s ease; }
.og-service:hover .og-title-outline { color: var(--cyan); -webkit-text-stroke: 2px transparent; }

.og-desc-box {
  background: var(--bg-color); padding: 40px; max-width: 500px;
  margin-top: 40px; transform: translateY(40px); opacity: 0;
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.6s ease;
  border-left: 4px solid var(--violet);
}
.og-service:hover .og-desc-box { transform: translateY(0); opacity: 1; }
.og-desc-title { font-family: 'Archivo Black', sans-serif; font-size: 20px; color: var(--navy); text-transform: uppercase; margin-bottom: 16px; }
.og-desc-text { font-size: 15px; font-weight: 500; line-height: 1.6; color: var(--gray); margin-bottom: 24px; }
.og-link { 
  font-size: 13px; font-weight: 700; color: var(--bg-color); background: var(--navy); 
  padding: 12px 24px; text-transform: uppercase; letter-spacing: 0.1em; text-decoration: none; 
  display: inline-flex; align-items: center; gap: 8px; transition: background .2s;
}
.og-link:hover { background: var(--violet); }

/* ─── FORM CONTATTI STILE AGENZIA ─── */
.ct-layout { display:grid; grid-template-columns:1fr 1fr; gap:80px; align-items:start; }
.f-group { margin-bottom:32px; }
.f-label { display:block; font-size:12px; font-weight:700; letter-spacing:.1em; text-transform:uppercase; color:var(--gray-2); margin-bottom:12px; }
.f-input {
  width:100%; background:transparent; border:none; border-bottom:2px solid rgba(255,255,255,0.2);
  padding:12px 0; font-family:'Work Sans',sans-serif; font-size:18px; font-weight:500; color:var(--bg-color); outline:none;
  transition:border-color .3s;
}
.f-input:focus { border-color:var(--cyan); }
.f-input::placeholder { color:rgba(255,255,255,0.3); font-weight:400; }
textarea.f-input { resize:none; height:80px; }
.btn-submit {
  background:var(--cyan); color:var(--navy); border:none; padding:18px 40px;
  font-family:'Work Sans',sans-serif; font-size:14px; font-weight:700;
  letter-spacing:.1em; text-transform:uppercase; cursor:pointer;
  transition:background .2s, transform .2s; margin-top: 16px;
}
.btn-submit:hover { background:var(--violet); color: white; transform:translateY(-2px); }


/* ─── SCROLL REVEAL ─── */
.rv-base { opacity:0; transition:opacity 1s cubic-bezier(0.19, 1, 0.22, 1), transform 1s cubic-bezier(0.19, 1, 0.22, 1); }
.rv-up { transform:translateY(80px); }
.rv-base.in { opacity:1; transform:translateY(0) !important; }
.rv-trigger .rv-child { opacity: 0; transform: translateY(60px); transition: opacity 0.8s cubic-bezier(0.19, 1, 0.22, 1), transform 0.8s cubic-bezier(0.19, 1, 0.22, 1); }
.rv-trigger.in .rv-child { opacity: 1; transform: translateY(0); }

/* Evita che la nav fissa copra l'inizio della sezione dopo lo scroll da menu */
section[id] { scroll-margin-top: 90px; }

/* ─── MOBILE ─── */
@media(max-width:768px){

  nav { padding:16px 20px; }
  nav.scrolled { padding:12px 20px; }

  .nav-toggle { display: flex; }

  .nav-links {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: min(78vw, 320px);
    background: var(--navy);
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 32px;
    padding: 40px 32px;
    transform: translateX(100%);
    transition: transform .4s cubic-bezier(0.77, 0, 0.175, 1);
    z-index: 150;
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links a { color: var(--bg-color); font-size: 16px; }
  .nav-links a:hover { color: var(--cyan); }

  /* L'overlay resta SOTTO la nav (z-index minore di nav) così l'hamburger
     rimane sempre visibile e cliccabile sopra di esso quando il menu è aperto. */
  .nav-overlay {
    display: none;
    position: fixed; inset: 0;
    background: rgba(24, 28, 46, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 500;
  }
  .nav-overlay.open { display: block; }

  /* Quando il drawer è aperto, dietro l'hamburger c'è lo sfondo scuro del
     drawer stesso: le barre devono diventare chiare per restare visibili. */
  .nav-toggle.open { background: rgba(255,255,255,0.08); border-radius: 50%; }
  .nav-toggle.open .bar { background: var(--bg-color); }

  .nav-cta { display: none; }
  .nav-links .nav-cta-mobile {
    display: inline-block;
    font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
    color: var(--navy); background: var(--cyan); padding: 14px 28px; text-decoration: none;
  }

  .hero { grid-template-columns:1fr; padding:110px 20px 40px; }
  .hero-title { font-size: clamp(32px, 8.5vw, 54px); line-height: 1.05; word-break: break-word; }
  .hero-bg-word { font-size: clamp(80px, 26vw, 140px); }

  .section { padding:70px 20px; }
  .big-title { font-size: clamp(26px, 7vw, 42px); line-height: 1.1; }
  .method-grid, .ct-layout { grid-template-columns: 1fr; gap: 40px; }
  .og-content { padding: 0 20px; }
  .og-title { font-size: clamp(32px, 9.5vw, 60px); line-height: 0.95; word-break: break-word; hyphens: auto; }
  .og-desc-box { transform: translateY(0); opacity: 1; padding: 24px; margin-top: 24px; }

  footer > div { flex-direction: column; gap: 20px; text-align: center; }
}


/* ─── LANG SWITCHER ─── */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 4px;
}
.lang-btn {
  background: transparent;
  border: 1px solid rgba(24,28,46,0.2);
  color: var(--navy);
  font-family: 'Work Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 6px 10px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  text-transform: uppercase;
}
.lang-btn:hover { background: var(--navy); color: var(--bg-color); }
.lang-btn.active { background: var(--violet); color: #fff; border-color: var(--violet); }

/* ─── SERVICE PAGE LAYOUT ─── */
.svc-hero {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 140px 60px 80px;
  background: var(--navy);
  position: relative;
  overflow: hidden;
}
.svc-hero-bg {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  z-index: 0;
}
.svc-hero-bg img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(100%) opacity(0.15);
}
.svc-hero-content { position: relative; z-index: 2; max-width: 1400px; }
.svc-eyebrow { font-size: 12px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--violet); margin-bottom: 24px; }
.svc-title {
  font-family: 'Archivo Black', sans-serif;
  font-size: clamp(50px, 7vw, 110px);
  line-height: 0.9;
  text-transform: uppercase;
  color: var(--bg-color);
  margin-bottom: 32px;
}
.svc-title span { color: transparent; -webkit-text-stroke: 2px rgba(255,255,255,0.5); }
.svc-subtitle { font-size: 18px; font-weight: 500; line-height: 1.6; color: var(--gray-2); max-width: 640px; }

.svc-intro { padding: 100px 60px; background: var(--bg-color); }
.svc-intro-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; max-width: 1400px; margin: 0 auto; }
.svc-intro-label { font-size: 12px; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; color: var(--violet); margin-bottom: 20px; }
.svc-intro h2 { font-family: 'Archivo Black', sans-serif; font-size: clamp(32px, 4vw, 52px); text-transform: uppercase; color: var(--navy); line-height: 1.0; margin-bottom: 24px; }
.svc-intro p { font-size: 16px; line-height: 1.7; color: var(--gray); font-weight: 500; }

.svc-cards { padding: 0 60px 100px; background: var(--bg-color); }
.svc-cards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 2px; max-width: 1400px; margin: 0 auto; }
.svc-card {
  background: var(--navy);
  padding: 48px 40px;
  position: relative;
  overflow: hidden;
  transition: background 0.3s;
}
.svc-card::before {
  content: '';
  position: absolute; top: 0; left: 0; width: 100%; height: 4px;
  background: var(--violet);
}
.svc-card.accent-cyan::before { background: var(--cyan); }
.svc-card:hover { background: #1e2440; }
.svc-card-tag { font-size: 10px; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; color: var(--violet); margin-bottom: 20px; display: block; }
.svc-card.accent-cyan .svc-card-tag { color: var(--cyan); }
.svc-card h3 { font-family: 'Archivo Black', sans-serif; font-size: 22px; text-transform: uppercase; color: var(--bg-color); margin-bottom: 16px; line-height: 1.1; }
.svc-card p { font-size: 14px; line-height: 1.7; color: var(--gray-2); font-weight: 500; }

.svc-cta-band { background: var(--violet); padding: 80px 60px; text-align: center; }
.svc-cta-band h2 { font-family: 'Archivo Black', sans-serif; font-size: clamp(28px, 4vw, 48px); text-transform: uppercase; color: #fff; margin-bottom: 24px; }
.svc-cta-band p { font-size: 16px; color: rgba(255,255,255,0.8); margin-bottom: 40px; font-weight: 500; max-width: 560px; margin-left: auto; margin-right: auto; }
.svc-cta-band a { display: inline-block; background: #fff; color: var(--violet); font-family: 'Work Sans', sans-serif; font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; padding: 18px 48px; text-decoration: none; transition: background 0.2s, transform 0.2s; }
.svc-cta-band a:hover { background: var(--navy); color: #fff; transform: translateY(-2px); }

/* ─── FOOTER RESPONSIVE ─── */
footer > div { max-width: 1400px; margin: 0 auto; }

/* ─── FORM SUCCESS ─── */
.form-success {
  display: none;
  text-align: center;
  padding: 40px;
  color: var(--cyan);
  font-family: 'Archivo Black', sans-serif;
  font-size: 24px;
  text-transform: uppercase;
}

@media(max-width: 768px) {
  .lang-switcher { gap: 2px; }
  .lang-btn { font-size: 10px; padding: 5px 8px; }
  .svc-hero { padding: 110px 20px 60px; }
  .svc-title { font-size: clamp(32px, 9vw, 56px); line-height: 1.0; word-break: break-word; }
  .svc-subtitle { font-size: 16px; }
  .svc-intro { padding: 60px 20px; }
  .svc-intro-grid { grid-template-columns: 1fr; gap: 40px; }
  .svc-cards { padding: 0 20px 60px; }
  .svc-cards-grid { grid-template-columns: 1fr; }
  .svc-cta-band { padding: 60px 20px; }
}

/* ─── FORM FEEDBACK BANNER ─── */
.form-feedback {
  margin-top: 24px;
  padding: 16px 20px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 12px;
  animation: fadeIn 0.3s ease-in-out;
}
.form-feedback.success {
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid var(--cyan);
  color: var(--cyan);
}
.form-feedback.error {
  background: rgba(255, 82, 82, 0.12);
  border: 1px solid #ff5252;
  color: #ff8a80;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
