/* Shared header / footer / lead-modal, aligned to the /services design
   system. Loaded on every page because these are shared includes, so it is
   scoped strictly to .topnav / .footer / .whatsapp / #modal-lead and never
   touches page content. Markup: _inc/header.php, _inc/footer.php. */

:root{
  --svc-bg:#0a0a0c;
  --svc-panel:#131316;
  --svc-panel2:#1a1b1f;
  --svc-ink:#f2f4f7;
  --svc-muted:#9aa0ab;
  --svc-line:rgba(255,255,255,.11);
  --svc-line-strong:rgba(255,255,255,.18);
  --svc-gold-light:#4ade80;
  --svc-gold:#22c55e;
  --svc-gold-deep:#16a34a;
  --svc-gold-glow:rgba(34,197,94,.35);
  --svc-mint:linear-gradient(135deg,#86efac 0%,#4ade80 48%,#22c55e 100%);
  --svc-num:"JetBrains Mono", ui-monospace, "SF Mono", Consolas, monospace;
}

/* =============================================================== HEADER */
.topnav{
  position:sticky; top:0; z-index:60;
  background:rgba(10,10,12,.78);
  backdrop-filter:blur(16px) saturate(140%);
  -webkit-backdrop-filter:blur(16px) saturate(140%);
  border-bottom:1px solid var(--svc-line);
  box-shadow:none;
  color:var(--svc-ink);
}
.topnav .container{ position:relative; }
.topnav .navrow{
  display:flex; align-items:center; gap:22px;
  min-height:66px; padding:0; flex-wrap:nowrap;
}

/* brand */
.topnav .brand{
  display:inline-flex; align-items:center; gap:10px;
  flex:0 0 auto; color:var(--svc-ink); text-decoration:none;
}
.topnav .brand .dot{
  width:9px; height:9px; border-radius:50%;
  background:var(--svc-gold);
  box-shadow:0 0 0 5px rgba(34,197,94,.12), 0 0 16px rgba(34,197,94,.55);
}
.topnav .brand-word{
  font:700 12.5px/1 var(--svc-num);
  letter-spacing:.14em; text-transform:uppercase; white-space:nowrap;
}

/* menu */
.topnav .nav-panel{ min-width:0; }
.topnav .menu{ display:flex; align-items:center; gap:4px; flex-wrap:nowrap; }
.topnav .menu > a,
.topnav .menu .dd > button{
  all:unset;
  box-sizing:border-box;
  display:inline-flex; align-items:center; gap:7px;
  padding:9px 12px; border-radius:10px;
  font-size:14px; font-weight:600; line-height:1;
  color:rgba(242,244,247,.7);
  cursor:pointer; white-space:nowrap;
  transition:color .18s ease, background .18s ease;
}
.topnav .menu > a:hover,
.topnav .menu .dd > button:hover{ color:var(--svc-ink); background:rgba(255,255,255,.05); }
.topnav .menu > a.active,
.topnav .menu .dd > button.active{ color:var(--svc-ink); }
.topnav .menu > a.active{ position:relative; border-bottom:0; padding-bottom:9px; }
.topnav .menu > a.active::after{
  content:""; position:absolute; left:12px; right:12px; bottom:2px;
  height:2px; border-radius:999px; background:var(--svc-gold);
  box-shadow:0 0 12px var(--svc-gold-glow);
}
.topnav .chev{ opacity:.6; transition:transform .2s ease; }
.topnav .dd.open .chev{ transform:rotate(180deg); opacity:1; }

/* dropdowns */
.topnav .ddmenu{
  position:absolute; top:calc(100% + 10px); left:0; right:auto;
  min-width:240px; padding:8px;
  background:rgba(19,19,22,.98);
  border:1px solid var(--svc-line);
  border-radius:16px;
  box-shadow:0 30px 80px rgba(0,0,0,.6);
  backdrop-filter:blur(18px);
}
.topnav .ddmenu.ddmenu-end{ left:auto; right:0; }
.topnav .ddmenu a{
  display:block; padding:10px 12px; border-radius:10px;
  color:rgba(242,244,247,.82); font-size:14px; font-weight:600; opacity:1;
}
.topnav .ddmenu a:hover{ background:rgba(34,197,94,.1); color:var(--svc-gold-light); }
.topnav .ddmenu a.active{ background:rgba(34,197,94,.14); color:var(--svc-gold-light); }

/* language pill */
.topnav .lang-switcher{ flex:0 0 auto; margin-left:auto; }
.topnav .lang-switcher .dd > button{
  all:unset;
  box-sizing:border-box;
  display:inline-flex; align-items:center; gap:8px;
  height:40px; padding:0 14px; border-radius:999px;
  border:1px solid var(--svc-line-strong);
  background:rgba(255,255,255,.04);
  color:var(--svc-ink);
  font:700 12px/1 var(--svc-num); letter-spacing:.06em;
  cursor:pointer; white-space:nowrap;
  transition:background .18s ease, border-color .18s ease;
}
.topnav .lang-switcher .dd > button:hover{ background:rgba(255,255,255,.09); border-color:rgba(255,255,255,.28); }
.topnav .lang-switcher .ddmenu{ left:auto; right:0; max-height:70vh; overflow-y:auto; }
.topnav .lang-switcher-ch > summary{ border-radius:10px; font-weight:600; color:rgba(242,244,247,.82); }
.topnav .lang-switcher-ch > summary:hover{ background:rgba(34,197,94,.1); }

/* account buttons */
.topnav .cta{ display:flex; align-items:center; gap:10px; flex:0 0 auto; }
.topnav .btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  min-height:40px; padding:10px 16px; border-radius:999px;
  font-size:13.5px; font-weight:700; line-height:1; white-space:nowrap;
  transition:background .18s ease, border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.topnav .btn.dark{
  background:rgba(255,255,255,.05);
  border:1px solid var(--svc-line-strong);
  color:var(--svc-ink);
  box-shadow:none;
}
.topnav .btn.dark:hover{ background:rgba(255,255,255,.1); border-color:rgba(255,255,255,.28); }
.topnav .btn.primary{
  background:var(--svc-mint);
  border:1px solid transparent;
  color:#05140b;
  box-shadow:0 8px 24px rgba(34,197,94,.26), inset 0 1px 0 rgba(255,255,255,.35);
}
.topnav .btn.primary:hover{ transform:translateY(-1px); box-shadow:0 14px 32px rgba(34,197,94,.36), inset 0 1px 0 rgba(255,255,255,.35); }
.topnav .welcome-btn .welcome-name{ max-width:14ch; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.topnav a:focus-visible,
.topnav button:focus-visible,
.topnav summary:focus-visible{ outline:2px solid var(--svc-gold-light); outline-offset:2px; border-radius:10px; }

/* mobile drawer toggle (checkbox + label, no JS) */
.topnav .nav-check{
  position:absolute; width:1px; height:1px; opacity:0; pointer-events:none;
}
.topnav .nav-toggle{
  display:none;
  width:44px; height:44px; flex:0 0 auto; order:4;
  align-items:center; justify-content:center;
  border:1px solid var(--svc-line-strong); border-radius:999px;
  background:rgba(255,255,255,.04); cursor:pointer;
}
.topnav .nav-check:focus-visible + .nav-toggle{ outline:2px solid var(--svc-gold-light); outline-offset:2px; }
.topnav .nav-bars,
.topnav .nav-bars::before,
.topnav .nav-bars::after{
  display:block; width:16px; height:1.6px; border-radius:2px;
  background:var(--svc-ink); transition:transform .2s ease, opacity .2s ease;
}
.topnav .nav-bars{ position:relative; }
.topnav .nav-bars::before,
.topnav .nav-bars::after{ content:""; position:absolute; left:0; }
.topnav .nav-bars::before{ top:-5px; }
.topnav .nav-bars::after{ top:5px; }
.topnav .nav-check:checked ~ .nav-toggle .nav-bars{ background:transparent; }
.topnav .nav-check:checked ~ .nav-toggle .nav-bars::before{ transform:translateY(5px) rotate(45deg); }
.topnav .nav-check:checked ~ .nav-toggle .nav-bars::after{ transform:translateY(-5px) rotate(-45deg); }

@media (min-width: 981px){
  .topnav .nav{ flex:1 1 auto; min-width:0; }
  .topnav .nav-panel{
    display:flex;
    align-items:center; justify-content:space-between; gap:20px;
  }
}
@media (max-width: 980px){
  .topnav .navrow{ gap:10px; min-height:60px; flex-wrap:wrap; }
  .topnav .nav{ order:3; }
  .topnav .nav-toggle{ display:flex; }
  .topnav .lang-switcher{ margin-left:auto; }
  .topnav .nav-panel{
    display:none;
    position:absolute; left:0; right:0; top:calc(100% + 1px);
    gap:16px;
    padding:18px 16px 22px;
    background:rgba(13,13,16,.98);
    backdrop-filter:blur(18px);
    border-bottom:1px solid var(--svc-line);
    box-shadow:0 30px 70px rgba(0,0,0,.55);
  }
  .topnav .nav-check:checked ~ .nav .nav-panel{ display:grid; }
  .topnav .menu{ flex-direction:column; align-items:stretch; gap:2px; }
  .topnav .menu > a,
  .topnav .menu .dd > button{
    width:100%; padding:13px 12px; font-size:15.5px;
    justify-content:space-between; border-radius:12px;
  }
  .topnav .menu > a.active::after{ left:12px; right:auto; width:16px; bottom:8px; }
  .topnav .menu .dd{ position:static; }
  .topnav .menu .ddmenu{
    position:static; min-width:0; margin:2px 0 6px;
    background:rgba(255,255,255,.03); box-shadow:none;
    border-radius:12px;
  }
  .topnav .cta{ flex-direction:column; align-items:stretch; gap:10px; }
  .topnav .cta .btn{ width:100%; min-height:46px; font-size:15px; }
  .topnav .client-menu{ width:100%; }
  .topnav .client-menu .btn{ justify-content:space-between; }
  .topnav .client-menu .ddmenu{ position:static; margin-top:8px; }
  /* styles.css pins every .topnav .ddmenu as a fixed popover at top:118px on
     phones — a leftover from the old two-row header. The menu and account
     dropdowns already escape it (static inside the drawer); the language one
     still needs anchoring to its own button, or it floats well below the bar
     and flush against the screen edge. */
  .topnav .lang-switcher .ddmenu{
    position:absolute; top:calc(100% + 10px); left:auto; right:0;
    min-width:220px; max-height:min(70vh,420px);
  }
  .topnav .lang-switcher .dd > button{ height:40px; padding:0 12px; font-size:0; gap:6px; }
  .topnav .lang-switcher .dd > button::after{ content:"\25BE"; font-size:11px; color:var(--svc-muted); }
  .topnav .lang-switcher .dd > button img{ margin-right:0 !important; }
}
@media (max-width: 400px){
  .topnav .brand-word{ font-size:11px; letter-spacing:.12em; }
}

/* =============================================================== FOOTER */
.footer{
  position:relative;
  background:linear-gradient(180deg, rgba(19,19,22,.9), var(--svc-bg));
  border-top:1px solid var(--svc-line);
  color:rgba(242,244,247,.72);
  padding:clamp(40px,6vw,64px) 0 28px;
  margin-top:0;
}
.footer::before{
  content:""; position:absolute; top:-1px; left:15%; right:15%; height:1px;
  background:linear-gradient(90deg, transparent, rgba(74,222,128,.5), transparent);
}
.footer .footcols{
  display:grid; grid-template-columns:1.7fr 1fr 1fr 1fr; gap:clamp(24px,4vw,48px);
}
.footer .footbrand{ display:grid; gap:14px; align-content:start; }
.footer .footlogo{ display:flex; align-items:center; gap:10px; font-weight:400; }
.footer .footlogo .dot{
  width:9px; height:9px; border-radius:50%;
  background:var(--svc-gold);
  box-shadow:0 0 0 5px rgba(34,197,94,.12), 0 0 16px rgba(34,197,94,.55);
}
.footer .footlogo .brand-word{
  font:700 12.5px/1 var(--svc-num);
  letter-spacing:.14em; text-transform:uppercase; color:var(--svc-ink);
}
.footer .footdesc{
  color:var(--svc-muted); font-size:13.5px; line-height:1.75; max-width:42ch; opacity:1;
}
.footer .footcol{ display:grid; gap:10px; align-content:start; }
.footer .foottitle{
  color:var(--svc-ink);
  font-size:13.5px; font-weight:700; letter-spacing:-.005em;
  margin-bottom:4px;
}
.footer .footcol a{
  color:rgba(242,244,247,.72); font-size:14px; opacity:1;
  transition:color .18s ease;
}
.footer .footcol a:hover,
.footer a:hover{ color:var(--svc-gold-light); }
.footer .footbottom{
  display:flex; align-items:center; justify-content:space-between; gap:14px; flex-wrap:wrap;
  margin-top:clamp(28px,4vw,44px); padding-top:18px;
  border-top:1px solid var(--svc-line);
}
.footer .footcopy,
.footer .footmail{
  color:var(--svc-muted);
  font:500 11.5px/1.6 var(--svc-num); letter-spacing:.04em;
}
.footer .footmail{ color:rgba(242,244,247,.78); }
@media (max-width: 900px){
  .footer .footcols{ grid-template-columns:1fr 1fr; gap:28px; }
  .footer .footbrand{ grid-column:1 / -1; }
}
@media (max-width: 520px){
  .footer .footcols{ grid-template-columns:1fr; }
  .footer .footbottom{ flex-direction:column; align-items:flex-start; gap:8px; }
}

/* floating WhatsApp */
.whatsapp{
  background:var(--svc-mint);
  color:#05140b;
  border:1px solid rgba(255,255,255,.2);
  box-shadow:0 14px 36px rgba(34,197,94,.3);
  transition:transform .2s ease, box-shadow .2s ease;
}
.whatsapp:hover{ transform:translateY(-2px); box-shadow:0 20px 44px rgba(34,197,94,.42); }

/* ====================================================== LEAD MODAL ====== */
#modal-lead .modal-card{
  background:var(--svc-panel2);
  border:1px solid var(--svc-line);
  color:var(--svc-ink);
  border-radius:22px;
}
#modal-lead .modal-head{
  background:var(--svc-panel2);
  border-bottom:1px solid var(--svc-line);
}
#modal-lead .modal-close{
  background:rgba(255,255,255,.08);
  color:var(--svc-ink);
  border-radius:999px;
}
#modal-lead .input,
#modal-lead textarea,
#modal-lead select{
  background:var(--svc-panel);
  border:1px solid var(--svc-line);
  color:var(--svc-ink);
  border-radius:12px;
}
#modal-lead .input:focus,
#modal-lead textarea:focus,
#modal-lead select:focus{
  outline:0;
  border-color:rgba(74,222,128,.6);
  box-shadow:0 0 0 4px rgba(34,197,94,.12);
}
#modal-lead .wizprog{ background:rgba(255,255,255,.08); }
#modal-lead .wizprog > div{ background:var(--svc-mint); }
#modal-lead .wizpill{
  background:rgba(255,255,255,.06);
  border:1px solid var(--svc-line);
  color:var(--svc-muted);
  font-family:var(--svc-num);
}
#modal-lead .btn{
  background:rgba(255,255,255,.06);
  border:1px solid var(--svc-line-strong);
  color:var(--svc-ink);
  border-radius:999px;
}
#modal-lead .btn.primary{
  background:var(--svc-mint);
  border-color:transparent;
  color:#05140b;
  box-shadow:0 10px 30px rgba(34,197,94,.28);
}
#modal-lead .note{ color:var(--svc-muted); }
