/* =====================================================================
   Assistenza Informatica Ticino — stile ispirato a gargaDesign.com
   Palette bianco e nero, layout pulito e moderno
   ===================================================================== */

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

:root {
  --blue-900: #0a0a0a;
  --blue-800: #171717;
  --blue-700: #262626;
  --blue-600: #3a3a3a;
  --teal-500: #000000;
  --teal-400: #4d4d4d;
  --accent: #000000;
  --ink: #111111;
  --ink-soft: #555555;
  --paper: #ffffff;
  --paper-soft: #f4f4f4;
  --border: #e2e2e2;
  --radius: 0;
  --shadow: 0 12px 30px rgba(0, 0, 0, 0.14);
  --shadow-sm: 0 4px 14px rgba(0, 0, 0, 0.08);
  --font-heading: 'Poppins', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
#come-funziona,
#cosa-risolviamo,
#form-contatto { scroll-margin-top: 96px; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-heading); color: var(--blue-900); margin: 0 0 .5em; line-height: 1.2; }
p { margin: 0 0 1em; }
ul { padding-left: 0; list-style: none; margin: 0; }

.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header / Nav ---------- */
/* Niente barra bianca: l'header resta fisso ma trasparente, con una leggera
   ombreggiatura in alto che mantiene leggibili logo e menu bianchi anche
   quando si scorre su sezioni chiare della pagina. */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  background: rgba(0,0,0,.35);
  border-bottom: none;
  pointer-events: none;
}
.site-header .container,
.site-header a,
.site-header button {
  pointer-events: auto;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 96px;
  gap: 16px;
}
/* Logo: solo scritta bianca, senza icona né sfondo, sempre sopra l'immagine */
.logo {
  display: flex;
  align-items: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: .01em;
  color: #fff;
}

/* Menu a schermo intero, testi molto grandi, squadrato (come richiesto) */
.main-nav {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 190;
  background: var(--blue-900);
  border: none;
  border-radius: 0;
  box-shadow: none;
  padding: 120px 8vw 60px;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 40px;
  overflow-y: auto;
}
.main-nav.open { display: flex; }
.main-nav ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.main-nav a {
  display: inline-block;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: clamp(2.4rem, 7vw, 5rem);
  line-height: 1.1;
  color: #fff;
  padding: 6px 0;
  border-radius: 0;
  border-bottom: none;
  transition: color .2s ease, opacity .2s ease;
  white-space: nowrap;
  opacity: .55;
}
.main-nav a:hover,
.main-nav a.active {
  color: #fff;
  background: none;
  opacity: 1;
}
.nav-contact {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  font-size: .85rem;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, .2);
}
.main-nav a.nav-phone,
.main-nav a.nav-email {
  font-size: .95rem;
  font-weight: 500;
  opacity: 1;
  padding: 0;
  white-space: normal;
}
.nav-phone { font-weight: 700; color: #fff; }
.nav-email { color: rgba(255, 255, 255, .7); }
.nav-phone i,
.nav-email i {
  color: #fff;
  width: 16px;
  text-align: center;
  margin-right: 2px;
}

.nav-toggle {
  position: relative;
  z-index: 210;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  box-shadow: none;
  cursor: pointer;
  flex: none;
}
.nav-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  transition: transform .25s ease, opacity .2s ease;
  background: #fff;
  border-radius: 0;
}
/* L'icona diventa una X quando il menu a schermo intero è aperto */
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 0;
  font-weight: 600;
  font-family: var(--font-heading);
  font-size: .98rem;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
/* Bottone semplice per sfondi chiari: bordo sottile scuro, nessun riempimento */
.btn-primary {
  background: transparent;
  border-color: var(--ink);
  color: var(--ink);
}
.btn-primary:hover { background: var(--ink); color: #fff; }
.btn-outline {
  background: transparent;
  border-color: var(--blue-700);
  color: var(--blue-700);
}
.btn-outline:hover { background: var(--blue-700); color: #fff; }
/* Bottone semplice per sfondi scuri (hero, banner): bordo sottile bianco, nessun riempimento */
.btn-accent {
  background: transparent;
  border-color: #fff;
  color: #fff;
}
.btn-accent:hover { background: #fff; color: #000; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: #fff;
  overflow: hidden;
  background-color: var(--blue-900);
  background-image: url('../img/hero-tramonto.jpg');
  background-position: center 62%;
  background-size: cover;
  background-repeat: no-repeat;
  padding: 90px 0 110px;
}
.hero-fullscreen {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: stretch;
  padding: 140px 0 50px;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 90px;
  background: radial-gradient(ellipse at 50% 120%, rgba(255,255,255,.18), transparent 70%);
}
.hero-inner { position: relative; z-index: 1; max-width: 760px; }
/* Righe della home (hero a schermo intero): ognuna è un elemento a sé nel
   flusso verticale, così il box dei testi resta allineato col logo (stessa
   classe "container" dell'header) mentre lo slogan può invece occupare
   tutta la larghezza dello schermo. */
.hero-row {
  position: relative;
  z-index: 1;
}
.hero .eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .8rem;
  font-weight: 600;
  color: #cfcfcf;
  margin-bottom: 14px;
}
.hero h1 {
  color: #fff;
  font-size: clamp(2rem, 4.5vw, 3.1rem);
  margin-bottom: .4em;
}
/* Slogan della home: molto grande, in basso a sinistra, larga tutto lo schermo */
.hero-slogan {
  font-size: clamp(2.2rem, 5.5vw, 4.2rem);
  line-height: 1.15;
  margin-bottom: .5em;
}
.hero-slogan-full {
  max-width: none;
  width: 100%;
  padding-left: max(20px, calc(50vw - 550px));
  padding-right: max(20px, calc(50vw - 550px));
  box-sizing: border-box;
}
.hero .lead {
  font-size: 1.2rem;
  color: #e6e6e6;
  margin-bottom: 1.4em;
}
.hero .price-badge {
  display: inline-block;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.3);
  border-radius: 0;
  padding: 10px 20px;
  font-weight: 600;
  line-height: 1.5;
  margin-bottom: 1.6em;
  max-width: 100%;
}
.hero .price-badge strong { color: #fff; font-size: 1.1em; }
/* Freccia che scorre alla sezione successiva (es. pagina assistenza online) */
.scroll-down {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px; height: 46px;
  border: 1.5px solid #fff;
  color: #fff;
  font-size: 1.1rem;
  margin-bottom: 1.6em;
  animation: scroll-down-bounce 1.8s ease-in-out infinite;
}
.scroll-down:hover { background: #fff; color: #000; }
@keyframes scroll-down-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}
/* Riga prezzo della home: solo testo, senza riquadro né icona */
.hero .price-line {
  font-weight: 600;
  margin-bottom: 1.6em;
}
.hero .price-line strong { color: #fff; font-size: 1.1em; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-shapes {
  position: absolute;
  right: -80px;
  top: -60px;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,.18), transparent 60%);
  filter: blur(6px);
}

/* ---------- Sections ---------- */
.section { padding: 76px 0; }
.section-soft { background: var(--paper-soft); }
.section-head { max-width: 640px; margin: 0 auto 44px; text-align: center; }
.section-head .eyebrow {
  display: block;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .8rem;
  font-weight: 700;
  color: var(--teal-500);
  margin-bottom: 10px;
}
.section-head h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.section-head p { color: var(--ink-soft); }

/* ---------- Service cards / two-column list ---------- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}
.service-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow-sm);
}
.service-card h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.05rem;
  color: var(--blue-800);
  margin-bottom: 16px;
}
.service-card h3 .dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--ink);
  flex: none;
}
.service-list li {
  position: relative;
  padding: 9px 0 9px 26px;
  border-bottom: 1px dashed var(--border);
  color: var(--ink-soft);
}
.service-list li:last-child { border-bottom: none; }
.service-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 9px;
  color: var(--teal-500);
  font-weight: 700;
}

/* ---------- Service cards a 6 categorie con icone Font Awesome ---------- */
.services-grid-cats {
  grid-template-columns: repeat(3, 1fr);
}
.service-card h3 .cat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  flex: none;
  background: var(--ink);
  color: #fff;
  font-size: .95rem;
}
.service-list-icons li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 9px 0 9px 0;
}
.service-list-icons li::before { content: none; }
.service-list-icons li i {
  flex: none;
  width: 18px;
  text-align: center;
  color: var(--ink);
  margin-top: 3px;
  font-size: .95rem;
}
/* ---------- Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  counter-reset: step;
}
.step-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 22px;
  box-shadow: var(--shadow-sm);
  position: relative;
}
.step-card .step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  font-family: var(--font-heading);
  margin-bottom: 14px;
}
.step-card p { color: var(--ink-soft); margin: 0; font-size: .96rem; }

.note-box {
  background: #fff6ec;
  border: 1px solid #ffdcae;
  border-radius: var(--radius);
  padding: 20px 24px;
  color: #7a4a12;
  margin: 34px 0;
}

/* ---------- Download cards ---------- */
.downloads-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px;
}
.download-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.download-card .icon {
  width: 60px; height: 60px;
  margin: 0 auto 16px;
  border-radius: 0;
  background: var(--ink);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.6rem;
}
.download-card p { color: var(--ink-soft); }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 44px;
  align-items: start;
}
.contact-info-card {
  background: var(--blue-900);
  color: #fff;
  border-radius: var(--radius);
  padding: 34px;
}
.contact-info-card h3 { color: #fff; }
.contact-info-card p { color: #d9d9d9; }
.contact-info-card .row { display: flex; gap: 12px; margin-bottom: 16px; align-items: flex-start; }
.contact-info-card .row strong { display: block; color: #fff; }

.form-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 34px;
  box-shadow: var(--shadow-sm);
}
.form-row { margin-bottom: 18px; }
.form-row label {
  display: block;
  font-weight: 600;
  font-size: .9rem;
  margin-bottom: 6px;
  color: var(--blue-900);
}
.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  background: var(--paper-soft);
  color: var(--ink);
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--teal-500);
  background: #fff;
}
.form-row textarea { min-height: 140px; resize: vertical; }
.form-row select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink) 50%),
    linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position: calc(100% - 21px) center, calc(100% - 16px) center;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 38px;
  cursor: pointer;
}
.form-row .captcha-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.form-row .captcha-row span {
  font-weight: 600;
  white-space: nowrap;
}
.form-row .captcha-row input { width: 90px; flex: none; }
.form-alert {
  padding: 14px 18px;
  border-radius: 0;
  margin-bottom: 20px;
  font-weight: 500;
}
.form-alert.success { background: #e6f7e9; color: #1c6b31; border: 1px solid #b7e6c1; }
.form-alert.error { background: #fdeaea; color: #a32323; border: 1px solid #f4bcbc; }

/* ---------- CTA banner ---------- */
.cta-banner {
  background: var(--blue-900);
  color: #fff;
  border-radius: var(--radius);
  padding: 46px;
  text-align: center;
}
.cta-banner h2 { color: #fff; }
.cta-banner p { color: #e6e6e6; }

/* ---------- Footer ---------- */
.site-footer { background: var(--blue-900); color: #cfcfcf; padding-top: 56px; }
.footer-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.footer-logo { color: #fff; margin-bottom: 12px; }
.footer-col h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.footer-col a { color: #cfcfcf; }
.footer-col a:hover { color: var(--teal-400); }
.footer-menu li { margin-bottom: 8px; }
.footer-bottom { padding: 20px 0; font-size: .85rem; color: #9a9a9a; }
.footer-bottom a { color: #cfcfcf; text-decoration: underline; }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .services-grid, .steps, .downloads-grid, .contact-grid { grid-template-columns: 1fr; }
  .services-grid.services-grid-cats { grid-template-columns: 1fr 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .services-grid.services-grid-cats { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .main-nav { padding: 100px 8vw 40px; gap: 28px; }
  .main-nav a { font-size: clamp(1.8rem, 9vw, 2.6rem); white-space: normal; }
  .hero:not(.hero-fullscreen) { padding: 130px 0 60px; }
  .section { padding: 54px 0; }
}

@media (max-width: 480px) {
  .logo { font-size: 1.05rem; }
  .main-nav a { font-size: clamp(1.5rem, 9vw, 2rem); }
}

/* ---------- Link inline in evidenza (es. "tramite questo modulo", "da qui") ---------- */
.link-modal {
  display: inline;
  background: none;
  border: none;
  border-bottom: 1.5px solid var(--ink);
  padding: 0;
  margin: 0;
  font: inherit;
  font-weight: 700;
  color: var(--ink);
  cursor: pointer;
  text-decoration: none;
}
.link-modal:hover { opacity: .75; }
/* Sopra lo sfondo scuro dell'hero (es. il passo 1 dentro il box modale è su
   sfondo chiaro, ma altri usi futuri su sfondo scuro restano leggibili) */
.hero .link-modal { color: #fff; border-bottom-color: #fff; }

/* ---------- Popup / modale ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0,0,0,.65);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay[hidden] { display: none; }
.modal-box {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 0;
  max-width: 540px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 34px;
  box-shadow: var(--shadow);
}
.modal-box h3 { margin-bottom: 18px; padding-right: 30px; }
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px; height: 34px;
  border: 1.5px solid var(--border);
  background: transparent;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  color: var(--ink);
}
.modal-close:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
