/* ═══════════════════════════════════════════════════════════════════════════
   Nervi Drone Brescia – style.css  (v13)
   Condiviso da: index.html, portfolio.html, chi-siamo.html, faq.html
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Variabili ────────────────────────────────────────────────────────────── */
:root {
    --blu:    #2563EB;
    --blu2:   #1D4ED8;
    --bg:     #F0F4F8;
    --testo:  #1E293B;
    --sub:    #64748B;
    --bordo:  #CBD5E1;
    --bianco: #ffffff;
    --accent: #EFF6FF;
    --r: 8px;
}

/* ── Reset ────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
section[id] { scroll-margin-top: 80px; }
body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--bg);
    color: var(--testo);
    line-height: 1.6;
}
img { display: block; max-width: 100%; }
a  { text-decoration: none; color: inherit; }
h1, h2, h3, h4 { line-height: 1.25; }

/* ── Header / Nav ─────────────────────────────────────────────────────────── */
header {
    position: sticky; top: 0; z-index: 900;
    background: rgba(255,255,255,.95);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--bordo);
}
.header-inner {
    max-width: 1200px; margin: 0 auto;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 24px; height: 64px;
}
.logo {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; color: var(--testo);
}
.logo img { height: 40px; width: auto; }
.logo-text  { display: flex; flex-direction: column; line-height: 1.1; }
.logo-name  { font-size: 17px; font-weight: 700; color: var(--testo); }
.logo-city  { font-size: 11px; font-weight: 600; color: var(--blu);
              text-transform: uppercase; letter-spacing: 1px; }
nav { display: flex; align-items: center; gap: 8px; }
nav a {
    font-size: 14px; font-weight: 500; color: var(--sub);
    padding: 8px 14px; border-radius: var(--r);
    transition: color .2s, background .2s;
}
nav a:hover { color: var(--testo); background: var(--accent); }
nav a.active { color: var(--blu); font-weight: 600; }
.nav-cta {
    background: var(--blu) !important; color: var(--bianco) !important;
    font-weight: 700; padding: 9px 18px;
}
.nav-cta:hover { background: var(--blu2) !important; color: var(--bianco) !important; }

/* ── Hamburger ────────────────────────────────────────────────────────────── */
.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 26px; height: 18px;
    background: none; border: none;
    cursor: pointer; padding: 0; flex-shrink: 0;
}
.nav-hamburger span {
    display: block; width: 100%; height: 2px;
    background: var(--testo); border-radius: 2px;
    transition: transform .25s, opacity .25s;
}
.nav-hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ── Pulsanti condivisi ───────────────────────────────────────────────────── */
.btn-solid {
    display: inline-block;
    background: var(--blu); color: var(--bianco);
    padding: 14px 28px; border-radius: var(--r);
    font-weight: 700; font-size: 15px;
    transition: background .2s, transform .15s;
}
.btn-solid:hover { background: var(--blu2); transform: translateY(-1px); }
.btn-line {
    display: inline-block;
    border: 2px solid rgba(255,255,255,.55); color: var(--bianco);
    padding: 12px 24px; border-radius: var(--r);
    font-weight: 600; font-size: 15px;
    transition: border-color .2s, background .2s;
}
.btn-line:hover { border-color: #fff; background: rgba(255,255,255,.12); }

/* ── Intestazioni sezione condivise ──────────────────────────────────────── */
.section-kicker {
    display: inline-block;
    font-size: 12px; font-weight: 700; color: var(--blu);
    text-transform: uppercase; letter-spacing: 1.5px;
    margin-bottom: 8px;
}
.section-h2 {
    font-size: clamp(26px, 4vw, 38px); font-weight: 800;
    color: var(--testo); margin-bottom: 14px;
}
.section-sub {
    font-size: 16px; color: var(--sub); max-width: 620px;
}

/* ── Page hero (banner sottopagine) ──────────────────────────────────────── */
.page-hero {
    background: linear-gradient(135deg, #1E293B 60%, #2563EB);
    color: var(--bianco);
    padding: 60px 24px 50px;
    text-align: center;
}
.page-hero .ph-kicker {
    font-size: 12px; font-weight: 700; color: rgba(255,255,255,.6);
    text-transform: uppercase; letter-spacing: 2px; margin-bottom: 12px;
}
.page-hero h1 {
    font-size: clamp(28px, 5vw, 44px); font-weight: 800;
    margin-bottom: 14px;
}
.page-hero p {
    font-size: 17px; color: rgba(255,255,255,.8);
    max-width: 600px; margin: 0 auto;
}

/* ── Breadcrumb ───────────────────────────────────────────────────────────── */
.breadcrumb {
    background: var(--bianco);
    border-bottom: 1px solid var(--bordo);
    padding: 10px 24px;
    font-size: 13px; color: var(--sub);
}
.breadcrumb a { color: var(--blu); }
.breadcrumb span { margin: 0 6px; }

/* ── Hero (homepage) ──────────────────────────────────────────────────────── */
.hero {
    display: grid; grid-template-columns: 1fr 1fr;
    min-height: 85vh;
}
.hero-left {
    display: flex; flex-direction: column; justify-content: center;
    padding: 80px 60px 80px 80px;
    max-width: 640px; margin-left: auto;
}
.hero-tag {
    display: inline-block; margin-bottom: 18px;
    font-size: 12px; font-weight: 700; color: var(--blu);
    text-transform: uppercase; letter-spacing: 1.5px;
    background: var(--accent); padding: 6px 14px; border-radius: 20px;
    border: 1px solid rgba(37,99,235,.2);
}
.hero h1 {
    font-size: clamp(30px, 4.5vw, 48px); font-weight: 800;
    line-height: 1.15; color: var(--testo); margin-bottom: 20px;
}
.hero h1 strong { display: block; color: var(--blu); }
.hero-desc {
    font-size: 17px; color: var(--sub); line-height: 1.7; margin-bottom: 32px;
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 32px; }
.hero-cta .btn-line { border-color: var(--blu); color: var(--blu); }
.hero-cta .btn-line:hover { background: var(--accent); }
.hero-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.hero-badge {
    font-size: 12px; font-weight: 600; color: var(--sub);
    background: var(--bianco); border: 1px solid var(--bordo);
    padding: 5px 12px; border-radius: 20px;
}
.hero-right {
    position: relative; overflow: hidden;
    min-height: 400px;
}
.hero-right img {
    width: 100%; height: 100%; object-fit: cover;
}
.hero-right-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to right, var(--bg) 0%, transparent 25%);
}

/* ── Servizi ──────────────────────────────────────────────────────────────── */
section#servizi { background: var(--bg); }
.servizi-inner {
    max-width: 1100px; margin: 0 auto; padding: 80px 24px;
}
.servizi-head { margin-bottom: 48px; }
.servizi-list { display: flex; flex-direction: column; gap: 0; }
.servizio-row {
    display: grid;
    grid-template-columns: 60px 1fr auto;
    align-items: center; gap: 24px;
    padding: 28px 0;
    border-bottom: 1px solid var(--bordo);
    cursor: default;
    transition: background .2s;
    border-radius: var(--r);
}
.servizio-row:hover { background: var(--bianco); padding-left: 12px; padding-right: 12px; }
.servizio-num {
    font-size: 28px; font-weight: 900; color: var(--bordo);
    line-height: 1; font-variant-numeric: tabular-nums;
    transition: color .2s;
}
.servizio-row:hover .servizio-num { color: var(--blu); }
.servizio-text h3 { font-size: 19px; font-weight: 700; margin-bottom: 6px; }
.servizio-text p  { font-size: 14px; color: var(--sub); line-height: 1.6; }
.servizio-seo {
    font-size: 12px; color: var(--sub); margin-top: 6px;
    font-style: italic; line-height: 1.5;
    border-left: 2px solid var(--blu);
    padding-left: 8px;
}
.servizio-thumb {
    width: 130px; height: 100px; object-fit: cover;
    border-radius: var(--r); flex-shrink: 0;
    filter: grayscale(0%);
    transition: filter .4s, transform .3s;
}
.servizio-row:hover .servizio-thumb { filter: grayscale(100%); transform: scale(1.04); }

/* ── Portfolio ────────────────────────────────────────────────────────────── */
.portfolio-inner {
    max-width: 1200px; margin: 0 auto; padding: 80px 24px;
}
.portfolio-head { margin-bottom: 56px; }
.portfolio-category { margin-bottom: 56px; }
.portfolio-cat-bar {
    display: flex; align-items: center; gap: 16px; margin-bottom: 8px;
}
.portfolio-cat-name { font-size: 18px; font-weight: 700; white-space: nowrap; }
.portfolio-cat-line { flex: 1; height: 1px; background: var(--bordo); }
.portfolio-cat-sub  { font-size: 14px; color: var(--sub); margin-bottom: 24px; }
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}
.portfolio-item {
    position: relative; overflow: hidden;
    border-radius: var(--r); cursor: pointer;
    aspect-ratio: 4/3;
    background: var(--bordo);
}
.portfolio-item img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform .4s;
}
.portfolio-item:hover img { transform: scale(1.06); }
.portfolio-item-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.65) 0%, transparent 55%);
    display: flex; align-items: flex-end; padding: 14px;
    opacity: 0; transition: opacity .3s;
}
.portfolio-item:hover .portfolio-item-overlay { opacity: 1; }
.portfolio-item-label {
    color: #fff; font-size: 13px; font-weight: 600; line-height: 1.3;
}
.portfolio-item-count {
    position: absolute; top: 10px; right: 10px;
    background: rgba(0,0,0,.55); color: #fff;
    font-size: 11px; font-weight: 700; padding: 3px 9px;
    border-radius: 12px; opacity: 0; transition: opacity .3s;
}
.portfolio-item:hover .portfolio-item-count { opacity: 1; }

/* ── Lightbox ─────────────────────────────────────────────────────────────── */
.lightbox {
    display: none; position: fixed; inset: 0; z-index: 9999;
    background: rgba(0,0,0,.93);
    flex-direction: column; align-items: center; justify-content: center;
}
.lightbox.open { display: flex; }
#lightbox-img {
    max-width: 88vw; max-height: 72vh;
    object-fit: contain;
    border-radius: 4px;
    transition: opacity .2s;
}
#lightbox-img.fading { opacity: 0; }
.lb-caption {
    color: rgba(255,255,255,.75); font-size: 13px;
    margin-top: 12px; text-align: center;
}
.lb-counter {
    position: absolute; top: 18px; right: 24px;
    color: rgba(255,255,255,.55); font-size: 13px;
}
.lb-close {
    position: absolute; top: 14px; left: 20px;
    color: #fff; font-size: 28px; cursor: pointer;
    background: none; border: none; line-height: 1;
    transition: color .2s;
}
.lb-close:hover { color: var(--blu); }
.lb-prev, .lb-next {
    position: absolute; top: 50%; transform: translateY(-50%);
    background: rgba(255,255,255,.1); color: #fff;
    border: none; font-size: 28px; cursor: pointer;
    padding: 16px 20px; border-radius: var(--r);
    transition: background .2s;
}
.lb-prev { left: 16px; }
.lb-next { right: 16px; }
.lb-prev:hover, .lb-next:hover { background: rgba(255,255,255,.2); }
.lb-prev.hidden, .lb-next.hidden { display: none; }
.lb-thumbs {
    display: flex; gap: 8px; margin-top: 16px;
    max-width: 90vw; overflow-x: auto; padding-bottom: 6px;
}
.lb-thumb {
    width: 56px; height: 42px; object-fit: cover;
    border-radius: 4px; cursor: pointer;
    opacity: .5; transition: opacity .2s;
    flex-shrink: 0; border: 2px solid transparent;
}
.lb-thumb.active, .lb-thumb:hover { opacity: 1; border-color: var(--blu); }

/* ── Chi Siamo ────────────────────────────────────────────────────────────── */
.chi-inner {
    max-width: 1100px; margin: 0 auto; padding: 80px 24px;
}
.chi-top {
    display: grid; grid-template-columns: 1fr 420px;
    gap: 60px; align-items: start; margin-bottom: 64px;
}
.chi-text p { font-size: 16px; color: var(--sub); margin-bottom: 14px; line-height: 1.75; }
.chi-img-wrap { position: relative; }
.chi-img {
    width: 100%; border-radius: 12px; object-fit: cover;
    max-height: 400px;
}
.chi-badge {
    position: absolute; bottom: -16px; left: -16px;
    background: var(--blu); color: #fff;
    padding: 14px 20px; border-radius: var(--r);
    text-align: center; box-shadow: 0 4px 20px rgba(37,99,235,.4);
}
.chi-badge strong { display: block; font-size: 18px; font-weight: 900; }
.chi-badge span   { font-size: 12px; opacity: .85; }
.cert-title {
    font-size: 20px; font-weight: 700; margin-bottom: 24px;
}
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px; margin-bottom: 28px;
}
.cert-card {
    display: flex; gap: 14px; align-items: flex-start;
    background: var(--bianco); border: 1px solid var(--bordo);
    border-radius: var(--r); padding: 16px;
}
.cert-icon { font-size: 24px; line-height: 1; }
.cert-info h4 { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.cert-info p  { font-size: 12px; color: var(--sub); line-height: 1.5; }
.cert-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.cbadge {
    font-size: 12px; font-weight: 600; color: var(--blu);
    background: var(--accent); border: 1px solid rgba(37,99,235,.2);
    padding: 5px 12px; border-radius: 20px;
}
/* Mini sezione SEO (visibile ma de-enfatizzata) */
.seo-region {
    margin-top: 48px; padding: 14px 20px;
    border-top: 1px solid var(--bordo);
    font-size: 12px; color: #b0b8c4;
    text-align: center; line-height: 1.7;
}

/* ── FAQ ──────────────────────────────────────────────────────────────────── */
.faq-inner {
    max-width: 820px; margin: 0 auto; padding: 80px 24px;
}
.faq-head { margin-bottom: 48px; }
.faq-list { display: flex; flex-direction: column; gap: 0; }
.faq-item {
    border-bottom: 1px solid var(--bordo);
}
.faq-item summary {
    list-style: none; cursor: pointer;
    display: flex; align-items: center; justify-content: space-between;
    padding: 22px 4px;
    font-size: 17px; font-weight: 600; color: var(--testo);
    transition: color .2s;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
    content: '+'; font-size: 24px; font-weight: 300;
    color: var(--blu); transition: transform .25s;
    flex-shrink: 0; margin-left: 16px;
}
.faq-item[open] summary { color: var(--blu); }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-answer {
    padding: 0 4px 22px;
    font-size: 15px; color: var(--sub); line-height: 1.75;
}
.faq-answer p { margin-bottom: 10px; }
.faq-cta {
    margin-top: 48px; text-align: center;
    background: var(--bianco); border: 1px solid var(--bordo);
    border-radius: 12px; padding: 36px 24px;
}
.faq-cta h3 { font-size: 20px; font-weight: 700; margin-bottom: 10px; }
.faq-cta p  { color: var(--sub); margin-bottom: 20px; }

/* ── Contatti / Form ──────────────────────────────────────────────────────── */
section#contatti { background: var(--bianco); }
.contatti-inner {
    max-width: 1100px; margin: 0 auto; padding: 80px 24px;
}
.contatti-inner > .section-h2 { margin-bottom: 8px; }
.contatti-inner > .section-sub { margin-bottom: 48px; }
.contatti-layout {
    display: grid; grid-template-columns: 1fr 1.2fr; gap: 60px;
}
.ref-label {
    font-size: 11px; font-weight: 700; color: var(--sub);
    text-transform: uppercase; letter-spacing: 1px; margin-bottom: 14px;
}
.ref-list { list-style: none; }
.ref-list li {
    display: flex; justify-content: space-between; align-items: baseline;
    padding: 10px 0; border-bottom: 1px solid var(--bordo);
    font-size: 14px;
}
.rl { color: var(--sub); flex-shrink: 0; margin-right: 16px; }
.rv { font-weight: 600; text-align: right; }
.rv a { color: var(--blu); }
.rv a:hover { text-decoration: underline; }
.ref-note {
    margin-top: 24px; padding: 18px;
    background: var(--accent); border-radius: var(--r);
    border-left: 3px solid var(--blu);
}
.ref-note strong { display: block; font-size: 14px; margin-bottom: 6px; }
.ref-note p { font-size: 13px; color: var(--sub); line-height: 1.6; }
.form-box {
    background: var(--bianco);
    border: 1px solid var(--bordo);
    border-radius: 12px; padding: 36px;
    box-shadow: 0 2px 24px rgba(0,0,0,.06);
}
.form-box-head h3 { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.form-box-head p  { font-size: 14px; color: var(--sub); margin-bottom: 24px; }
.form-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
    margin-bottom: 14px;
}
.fg { display: flex; flex-direction: column; margin-bottom: 14px; }
.fg label {
    display: block; margin-bottom: 6px;
    font-size: 11px; font-weight: 700; color: var(--sub);
    text-transform: uppercase; letter-spacing: .8px;
}
.fg input, .fg textarea, .fg select {
    width: 100%; padding: 11px 14px;
    border: 1.5px solid var(--bordo); border-radius: var(--r);
    font-family: inherit; font-size: 14px; color: var(--testo);
    background: var(--bianco);
    transition: border-color .2s, box-shadow .2s;
}
.fg input:focus, .fg textarea:focus, .fg select:focus {
    outline: none; border-color: var(--blu);
    box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.fg textarea { resize: vertical; min-height: 110px; }
.gdpr-wrap {
    display: flex; align-items: flex-start; gap: 12px;
    margin-bottom: 18px; margin-top: 6px;
    padding: 14px 16px;
    background: rgba(37,99,235,.05);
    border: 1px solid rgba(37,99,235,.15);
    border-radius: var(--r);
}
.gdpr-wrap input[type="checkbox"] {
    width: 18px; height: 18px; min-width: 18px; margin-top: 2px;
    accent-color: var(--blu); cursor: pointer;
}
.gdpr-label {
    font-size: 13px; color: var(--sub); line-height: 1.55; cursor: pointer;
}
.gdpr-label a { color: var(--blu); text-decoration: underline; text-underline-offset: 2px; }
.form-submit {
    background: var(--blu); color: var(--bianco);
    padding: 14px 28px; border: none; border-radius: var(--r);
    font-size: 14px; font-weight: 700; letter-spacing: .5px;
    text-transform: uppercase; cursor: pointer; width: 100%; margin-top: 4px;
    transition: background .2s, transform .2s;
}
.form-submit:hover { background: var(--blu2); transform: translateY(-1px); }

/* ── Luogo dell'intervento (modulo preventivo) ────────────────────────────── */
.luogo-box {
    margin: 6px 0 14px; padding: 18px 18px 4px;
    border: 1px solid var(--bordo); border-radius: var(--r);
    background: #FAFBFD;
}
.luogo-head {
    display: flex; align-items: center; gap: 8px;
    font-size: 12px; font-weight: 700; color: var(--testo);
    text-transform: uppercase; letter-spacing: .8px; margin-bottom: 10px;
}
.luogo-head svg { color: var(--blu); flex: none; }
.luogo-note {
    font-size: 13px; line-height: 1.55; color: var(--sub);
    background: var(--accent); border-left: 3px solid var(--blu);
    border-radius: 6px; padding: 10px 12px; margin-bottom: 16px;
}
.luogo-note strong { color: var(--testo); }
.fg .hint { font-size: 12px; color: var(--sub); margin-top: 5px; }
.form-grid.g-prov { grid-template-columns: 1fr 1.6fr; }
@media (max-width: 768px) { .form-grid.g-prov { grid-template-columns: 1fr; } }

/* ── Footer ───────────────────────────────────────────────────────────────── */
footer {
    background: var(--testo); color: rgba(255,255,255,.45);
    text-align: center; padding: 28px 20px;
}
footer p { font-size: 12px; margin-bottom: 4px; }
footer a { color: rgba(255,255,255,.5); text-decoration: none; transition: color .2s; }
footer a:hover { color: var(--bianco); }

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 960px) {
    .hero { grid-template-columns: 1fr; min-height: auto; }
    .hero-right { height: 320px; }
    .hero-left  { max-width: 100%; padding: 60px 28px 50px; margin-left: 0; }
    .chi-top    { grid-template-columns: 1fr; }
    .chi-img-wrap { display: none; }
    .contatti-layout { grid-template-columns: 1fr; gap: 40px; }
}
@media (max-width: 768px) {
    .servizio-row { grid-template-columns: 48px 1fr; }
    .servizio-thumb { display: none; }
    .servizio-seo   { display: none; }
    .hero h1 { font-size: 30px; }
    .form-grid { grid-template-columns: 1fr; }
    .form-box  { padding: 24px; }

    /* Hamburger visible, all nav links hidden by default */
    .nav-hamburger { display: flex; }
    nav[aria-label="Navigazione principale"] a { display: none; }

    /* Mobile dropdown when open */
    nav[aria-label="Navigazione principale"].nav-open {
        position: fixed;
        top: 64px; left: 0; right: 0;
        background: rgba(255,255,255,.98);
        backdrop-filter: blur(8px);
        border-bottom: 1px solid var(--bordo);
        box-shadow: 0 8px 24px rgba(0,0,0,.1);
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 12px 16px 20px;
        z-index: 899;
    }
    nav[aria-label="Navigazione principale"].nav-open a {
        display: block;
        font-size: 16px;
        padding: 12px 16px;
    }
    nav[aria-label="Navigazione principale"].nav-open .nav-cta {
        margin-top: 8px;
        text-align: center;
        border-radius: var(--r);
    }
}
