/* Luce Internet Casa: foglio di stile unico, mobile first */
:root {
  --bg: #efeee3;
  --paper: #f9f8f1;
  --tint: #e4e7d9;
  --ink: #1c2d25;
  --ink-2: #435349;
  --sage: #2b4538;
  --sage-deep: #172820;
  --line: #cdd2c1;
  --energia: #85601a;
  --telco: #2e5667;
  --accent: var(--sage);
  --pending: #ffe14d;
  --font: "Avenir Next", Avenir, "Segoe UI", "Helvetica Neue", Roboto, "Noto Sans", Arial, sans-serif;
  --wrap: 1120px;
  --gutter: 16px;
  --callbar-h: 72px;
}
.sector-energia { --accent: var(--energia); }
.sector-telco { --accent: var(--telco); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.55;
  padding-bottom: var(--callbar-h);
}
img, svg { display: block; max-width: 100%; }
a { color: var(--sage); text-underline-offset: .18em; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -.012em; margin: 0; font-weight: 700; }
h1 { font-size: 1.62rem; }
h2 { font-size: 1.45rem; margin-bottom: 1.25rem; }
h3 { font-size: 1.06rem; margin-bottom: .35rem; }
p { margin: 0 0 1rem; }
abbr { text-decoration: none; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.wrap--narrow { max-width: 760px; }
.ico { width: 24px; height: 24px; flex: none; }

.skip { position: absolute; left: -999px; top: 0; background: var(--paper); padding: .5rem 1rem; z-index: 50; }
.skip:focus { left: 8px; top: 8px; }

/* Barra superior e intestazione */
.topbar { background: var(--sage-deep); color: #e9ecdf; font-size: .75rem; line-height: 1.35; padding: .4rem 0; }
.site-header { background: var(--paper); border-bottom: 3px solid var(--accent); }
.site-header__row { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 56px; }
.logo { display: flex; align-items: center; gap: .45rem; color: var(--ink); text-decoration: none; font-weight: 700; letter-spacing: -.02em; font-size: .98rem; line-height: 1.05; }
.logo__mark { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: var(--sage); color: #f3f1e4; }
.logo__mark .ico { width: 22px; height: 22px; }
.sector-both .logo__text { max-width: none; }
.site-nav { display: flex; gap: 1rem; font-size: .92rem; font-weight: 600; }
.site-nav a { text-decoration: none; color: var(--ink-2); }
.site-nav a:hover { color: var(--ink); text-decoration: underline; }

/* Pulsante di chiamata: un solo colore ovunque */
.btn-call {
  display: inline-flex; align-items: center; gap: .6rem;
  background: var(--sage); color: #fff; text-decoration: none;
  font-weight: 600; line-height: 1.1;
  padding: .7rem 1.1rem .7rem .7rem; border-radius: 14px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.14), 0 3px 0 var(--sage-deep);
  transition: transform .08s ease, box-shadow .08s ease, background-color .15s ease;
}
.btn-call:hover { background: #24392f; color: #fff; }
.btn-call:active { transform: translateY(2px); box-shadow: inset 0 0 0 1px rgba(255,255,255,.14), 0 1px 0 var(--sage-deep); }
.btn-call b { font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.btn-call__icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: #f3f1e4; color: var(--sage); flex: none; }
.btn-call__icon .ico { width: 20px; height: 20px; }
.btn-call--xl { font-size: 1.15rem; padding: .8rem 1.3rem .8rem .8rem; border-radius: 16px; }
.btn-call--xl .btn-call__icon { width: 44px; height: 44px; border-radius: 12px; }
.btn-call--xl b { font-size: 1.3rem; }
.btn-call--sm { font-size: .82rem; padding: .45rem .7rem .45rem .45rem; border-radius: 11px; gap: .4rem; box-shadow: inset 0 0 0 1px rgba(255,255,255,.14), 0 2px 0 var(--sage-deep); }
.btn-call--sm .btn-call__icon { width: 26px; height: 26px; border-radius: 8px; }
.btn-call--sm .btn-call__icon .ico { width: 16px; height: 16px; }

/* Hero */
.hero { padding: 1.1rem 0 2rem; }
.hero__grid { display: grid; grid-template-columns: 100%; grid-template-areas: "title" "cta" "box" "sub"; row-gap: .9rem; }
.hero__title { grid-area: title; }
.hero__sub { grid-area: sub; color: var(--ink-2); margin: .2rem 0 0; }
.hero__cta { grid-area: cta; }
.hero__cta .btn-call { width: 100%; }
.fine { font-size: .76rem; line-height: 1.4; color: var(--ink-2); margin: .55rem 0 0; }
.trasparenza {
  grid-area: box; display: flex; gap: .6rem; align-items: flex-start;
  background: var(--paper); border: 1px solid var(--line); border-left: 4px solid var(--accent);
  border-radius: 4px 12px 12px 4px; padding: .7rem .8rem; font-size: .8rem; line-height: 1.42;
}
.trasparenza p { margin: 0; }
.trasparenza__icon { flex: none; display: block; color: var(--accent); margin-top: .05rem; }
.trasparenza__icon .ico { width: 20px; height: 20px; }

/* Sezioni */
.section { padding: 3rem 0; }
.section--tint { background: var(--tint); }

.servizi { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.75rem; }
.servizi li { border-top: 2px solid var(--accent); padding-top: 1rem; }
.servizi p { margin: 0; color: var(--ink-2); }
.servizi__icon { display: block; color: var(--accent); margin-bottom: .6rem; }
.servizi__icon .ico { width: 30px; height: 30px; }

.passi { list-style: none; margin: 0; padding: 0; counter-reset: passo; display: grid; gap: 1.25rem; }
.passi li { counter-increment: passo; position: relative; padding-left: 3.4rem; min-height: 2.6rem; }
.passi li::before {
  content: counter(passo); position: absolute; left: 0; top: -.15rem;
  width: 2.4rem; height: 2.4rem; border-radius: 50%; display: grid; place-items: center;
  border: 2px solid var(--accent); color: var(--accent); background: var(--paper); font-weight: 700; font-size: 1.05rem;
}
.passi li:not(:last-child)::after { content: ""; position: absolute; left: 1.15rem; top: 2.4rem; bottom: -1.25rem; width: 2px; background: var(--accent); opacity: .45; }
.passi p { margin: 0; color: var(--ink-2); }
.cta-row { margin-top: 2rem; }

.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: .8rem; }
.checklist li { display: flex; gap: .7rem; align-items: flex-start; }
.checklist .ico { color: var(--accent); margin-top: .05rem; }

.tecnologie { display: grid; gap: 1.5rem; }
.tec { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 1.1rem 1.1rem 1.4rem; }
.tec p { color: var(--ink-2); margin: 0 0 1rem; }
.tec__line { display: block; height: 6px; border-radius: 3px; }
.tec--ftth .tec__line { background: var(--accent); }
.tec--fttc .tec__line { background: linear-gradient(90deg, var(--accent) 0 65%, transparent 65% 68%, #a77b53 68% 100%); height: 6px; }
.tec--fwa .tec__line { background: radial-gradient(circle, var(--accent) 2.5px, transparent 3px) 0 50% / 12px 6px repeat-x; }

.faq { border-top: 1px solid var(--line); }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary { cursor: pointer; list-style: none; padding: 1rem 2.2rem 1rem 0; font-weight: 600; position: relative; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: ""; position: absolute; right: .4rem; top: 1.35rem; width: .6rem; height: .6rem; border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(45deg); transition: transform .15s ease; }
.faq__item[open] summary::after { transform: rotate(-135deg); top: 1.6rem; }
.faq__a p { color: var(--ink-2); margin: 0 0 1.1rem; }

.closing { background: var(--paper); border-top: 4px solid var(--accent); padding: 2.75rem 0; }
.closing__inner { display: grid; gap: 1.25rem; justify-items: start; }
.closing h2 { margin: 0; }

/* Home */
.hero--home { padding: 1.6rem 0 2.5rem; }
.hero--home .hero__sub { margin: .8rem 0 1.5rem; max-width: 46rem; }
.settori { display: grid; gap: 1rem; }
.settore { background: var(--paper); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: 6px 6px 14px 14px; padding: 1.2rem; display: grid; justify-items: start; gap: .2rem; }
.settore--energia { --accent: var(--energia); }
.settore--telco { --accent: var(--telco); }
.settore__icon { color: var(--accent); margin-bottom: .3rem; }
.settore__icon .ico { width: 32px; height: 32px; }
.settore h2 { margin: 0; font-size: 1.3rem; }
.settore p { color: var(--ink-2); margin-bottom: .9rem; }
.settore__more { margin-top: .8rem; font-weight: 600; }

/* Pagine interne */
.page { padding: 2rem 0 3rem; }
.prose h1 { margin-bottom: 1.1rem; }
.prose h2 { font-size: 1.25rem; margin: 2rem 0 .7rem; }
.prose ul { padding-left: 1.2rem; margin: 0 0 1rem; }
.prose li { margin-bottom: .5rem; }
.note { font-size: .9rem; color: var(--ink-2); }
.dati { margin: 0 0 1rem; border-top: 1px solid var(--line); }
.dati div { display: grid; grid-template-columns: 100%; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.dati dt { font-size: .82rem; color: var(--ink-2); }
.dati dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.numeri { display: grid; gap: 1rem; margin: 1rem 0 1.5rem; }
.numeri__item { background: var(--paper); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 4px 12px 12px 4px; padding: 1rem; }
.numeri__item--energia { --accent: var(--energia); }
.numeri__item--telco { --accent: var(--telco); }
.numeri__item h3 { margin-bottom: .7rem; }
.bozza { background: var(--pending); color: var(--ink); font-weight: 700; padding: .5rem .8rem; border-radius: 6px; display: inline-block; }
mark.pending { background: var(--pending); color: var(--ink); padding: 0 .25em; border-radius: 3px; font-weight: 700; }

/* Avvertenza e piè di pagina */
.disclaimer { background: var(--tint); border-top: 1px solid var(--line); font-size: .82rem; color: var(--ink-2); padding: 1.5rem 0 .5rem; }
.site-footer { background: var(--sage-deep); color: #dfe4d6; font-size: .82rem; padding: 1.75rem 0 1.25rem; }
.site-footer a { color: #fff; }
.site-footer a:hover { color: #f3f1e4; }
.site-footer :focus-visible { outline-color: #f3f1e4; }
.site-footer .titolare { color: #fff; }
.footer-nav { display: flex; flex-wrap: wrap; gap: .35rem 1.1rem; margin: 0 0 1rem; }
.copy { margin: 0; opacity: .8; }

/* Barra di chiamata fissa (mobile) */
.callbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  background: rgba(249,248,241,.97); border-top: 1px solid var(--line);
  padding: 8px var(--gutter) calc(8px + env(safe-area-inset-bottom));
  display: grid; gap: 8px; transition: transform .2s ease;
}
.callbar--two { grid-template-columns: 1fr 1fr; }
.js .callbar { transform: translateY(110%); }
.js .callbar.is-visible { transform: none; }
.btn-call--bar { justify-content: center; min-height: 52px; font-size: .95rem; padding: .5rem .8rem .5rem .5rem; }
.btn-call--bar .btn-call__icon { width: 32px; height: 32px; }
.callbar--two .btn-call--bar { font-size: .78rem; gap: .4rem; padding: .4rem .5rem; }
.callbar--two .btn-call--bar > span:last-child { display: grid; text-align: left; }
.callbar--two .btn-call--bar .btn-call__icon { width: 26px; height: 26px; }
.callbar--two .btn-call--bar .btn-call__icon .ico { width: 16px; height: 16px; }

/* Banner Cookiebot: su mobile resta sopra la barra di chiamata */
@media (max-width: 899px) {
  #CybotCookiebotDialog { bottom: calc(var(--callbar-h) + 8px) !important; max-height: calc(100vh - var(--callbar-h) - 96px) !important; }
}

@media (min-width: 600px) {
  :root { --gutter: 24px; }
  h1 { font-size: 2.1rem; }
  .servizi { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .checklist { grid-template-columns: 1fr 1fr; gap: 1rem 2rem; }
  .settori, .numeri { grid-template-columns: 1fr 1fr; }
  .dati div { grid-template-columns: 11rem 1fr; gap: 1rem; }
  .hero__cta .btn-call { width: auto; }
  .trasparenza { font-size: .86rem; }
}

@media (min-width: 900px) {
  :root { --gutter: 32px; }
  body { font-size: 1.0625rem; padding-bottom: 0; }
  .callbar { display: none; }
  h1 { font-size: 2.75rem; }
  h2 { font-size: 2rem; margin-bottom: 1.75rem; }
  .topbar { font-size: .82rem; }
  .site-header__row { min-height: 68px; }
  .logo { font-size: 1.15rem; }
  .logo__mark { width: 38px; height: 38px; }
  .btn-call--sm { font-size: .92rem; padding: .5rem .9rem .5rem .5rem; }
  .btn-call--sm .btn-call__icon { width: 30px; height: 30px; }
  .hero { padding: 3rem 0 3.5rem; }
  .hero__grid {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    grid-template-areas: "title box" "sub box" "cta box";
    column-gap: 4rem; row-gap: 1.25rem; align-items: start;
  }
  .hero__sub { font-size: 1.15rem; margin: 0; }
  .hero__cta { margin-top: .5rem; }
  .fine { font-size: .82rem; max-width: 34rem; }
  .trasparenza { align-self: center; font-size: .95rem; padding: 1.4rem 1.5rem; gap: .9rem; }
  .trasparenza__icon .ico { width: 24px; height: 24px; }
  .section { padding: 4.5rem 0; }
  .servizi { grid-template-columns: repeat(3, 1fr); gap: 2.5rem 2.25rem; }
  .servizi--4 { grid-template-columns: repeat(4, 1fr); }
  .passi { grid-template-columns: repeat(3, 1fr); gap: 2rem; }
  .passi li { padding-left: 0; padding-top: 3.6rem; }
  .passi li::before { top: 0; }
  .passi li:not(:last-child)::after { left: 2.9rem; right: -1.5rem; top: 1.15rem; bottom: auto; width: auto; height: 2px; }
  .tecnologie { grid-template-columns: repeat(3, 1fr); }
  .closing { padding: 4rem 0; }
  .closing__inner { grid-template-columns: 1fr auto; align-items: center; gap: 2rem; }
  .closing h2 { font-size: 1.85rem; }
  .hero--home { padding: 3.5rem 0 4rem; }
  .hero--home .hero__title { max-width: 48rem; }
  .settore { padding: 1.75rem; }
  .page { padding: 3rem 0 4rem; }
  .prose h2 { font-size: 1.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

@media (max-width: 479px) {
  .site-nav { display: none; }
}
