:root {
  --navy: #16478a;       /* blu brand ufficiale */
  --navy-dark: #0f3168;  /* variante più scura, per gradienti/hover */
  --light-blue: #5B9BD5;
  --accent: #F2762E;
  --text: #222222;
  --text-muted: #5a5a5a;
  --bg: #ffffff;
  --bg-alt: #f5f7fa;
  --border: #e2e6ea;
  --footer-text: #dbe3f0;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh; /* garantisce che il footer resti in fondo anche su pagine con poco contenuto */
}

main {
  flex: 1 0 auto; /* il main si espande, spingendo il footer in fondo */
}

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

a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--light-blue); }

/* Header */
.site-header {
  background: #ffffff;
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
}
.logo {
  display: flex;
  align-items: center;
}
.logo img {
  display: block;
  height: 42px;
  width: auto;
}
.main-nav ul {
  list-style: none;
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.main-nav a {
  color: var(--navy);
  font-weight: 600;
}
.main-nav a:hover {
  color: var(--accent);
}

/* Hero */
.hero {
  background-size: cover;
  background-position: center;
  color: #fff;
  padding: 90px 0;
  text-align: center;
}
.hero h1 { font-size: 2.1rem; margin-bottom: 16px; max-width: 720px; margin-left: auto; margin-right: auto; }
.hero p { margin-bottom: 24px; color: #dbe3f0; }

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 4px;
  font-weight: bold;
}
.btn-primary {
  background: var(--accent);
  color: var(--navy-dark);
}
.btn-primary:hover {
  background: #d9631c;
  color: var(--navy-dark);
}
.btn-outline {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.5);
}
.btn-outline:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

/* Contenuto pagina */
.page-content {
  padding: 48px 0;
}
.page-content h1 {
  color: var(--navy);
  margin-bottom: 24px;
}
.page-body h2 {
  color: var(--navy);
  margin: 32px 0 12px;
}
.page-body p {
  margin-bottom: 16px;
  color: var(--text-muted);
}

/* FAQ */
.faq-section { margin-top: 40px; }
.faq-item {
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}
.faq-item h3 {
  color: var(--navy);
  margin-bottom: 8px;
}

/* Footer */
.site-footer {
  background: var(--navy);
  color: var(--footer-text);
  margin-top: 64px;
  flex-shrink: 0; /* non si comprime mai, resta sempre ancorato in fondo */
}
/* Se l'ultima sezione della pagina è un banner a tutta larghezza (es. CTA
   in homepage), il footer si attacca direttamente senza striscia bianca. */
main:has(> .cta-banner:last-child) + .site-footer,
main:has(> .reviews-section:last-child) + .site-footer {
  margin-top: 0;
  border-top: 4px solid var(--accent);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  padding: 48px 20px;
}
.footer-col p {
  color: var(--footer-text);
}
.footer-col h3 {
  color: var(--accent);
  margin-bottom: 12px;
  font-size: 1rem;
}
.footer-col a {
  color: var(--footer-text);
}
.footer-col a:hover {
  color: var(--accent);
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 6px; }
.footer-col-brand .footer-logo {
  margin-bottom: 16px;
}
.footer-icon-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.footer-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--accent);
}
.footer-disclaimer {
  margin-top: 8px;
  font-size: 0.75rem;
  color: #8ca3c9;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}
.footer-bottom {
  text-align: center;
  padding: 16px 20px;
  font-size: 0.85rem;
  color: #a9bcd8;
  border-top: 1px solid rgba(255,255,255,0.15);
}

/* Responsive */
@media (max-width: 768px) {
  .header-inner { flex-direction: column; gap: 12px; }
  .main-nav ul { justify-content: center; }
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: -200px; /* nascosto di default, fuori dallo schermo */
  background: var(--navy-dark);
  color: #fff;
  z-index: 1000;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.2);
  transition: bottom 0.3s ease;
}
.cookie-banner--visible {
  bottom: 0;
}
.cookie-banner-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.cookie-banner-inner p {
  flex: 1 1 480px;
  font-size: 0.9rem;
  color: #dbe3f0;
  margin: 0;
}
.cookie-banner-inner a {
  color: var(--accent);
  text-decoration: underline;
}
.cookie-banner-actions {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}
.cookie-banner-actions .btn {
  padding: 10px 20px;
  font-size: 0.9rem;
  cursor: pointer;
  border: none;
}

@media (max-width: 600px) {
  .cookie-banner-inner {
    flex-direction: column;
    align-items: stretch;
  }
  .cookie-banner-inner p {
    flex: 0 0 auto;
  }
  .cookie-banner-actions {
    justify-content: stretch;
  }
  .cookie-banner-actions .btn {
    flex: 1;
  }
}

/* Homepage: highlight cards — immagine piena, la descrizione si rivela
   al passaggio del mouse (hover), al focus da tastiera, o al tocco su
   schermi touch (gestito via JS con la classe .is-revealed). */
.home-highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding: 56px 20px;
}
.highlight-card {
  position: relative;
  display: block;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  color: #fff;
  text-decoration: none;
  outline-offset: 3px;
}
.highlight-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease, filter 0.4s ease;
}
.highlight-card::after {
  /* velo scuro permanente in basso, per leggibilità del titolo sull'immagine */
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15,49,104,0.85) 0%, rgba(15,49,104,0.15) 45%, rgba(15,49,104,0) 65%);
  transition: background 0.35s ease;
}
.highlight-card-title {
  position: absolute;
  left: 20px;
  bottom: 18px;
  right: 20px;
  z-index: 2;
  font-size: 1.25rem;
  font-weight: bold;
  text-shadow: 0 1px 3px rgba(0,0,0,0.4);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.highlight-card-reveal {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  background: linear-gradient(to top, rgba(15,49,104,0.97) 0%, rgba(15,49,104,0.88) 60%, rgba(15,49,104,0.55) 100%);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}
.highlight-card-reveal-text {
  font-size: 0.92rem;
  line-height: 1.5;
  color: #eef2f8;
  margin-bottom: 14px;
}
.highlight-card-reveal .link-arrow {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
}

/* Stato "rivelato": hover mouse, focus da tastiera, o tocco (.is-revealed via JS) */
.highlight-card:hover .highlight-card-img,
.highlight-card:focus-visible .highlight-card-img,
.highlight-card.is-revealed .highlight-card-img {
  transform: scale(1.06);
  filter: brightness(0.7);
}
.highlight-card:hover .highlight-card-title,
.highlight-card:focus-visible .highlight-card-title,
.highlight-card.is-revealed .highlight-card-title {
  opacity: 0;
  transform: translateY(6px);
}
.highlight-card:hover .highlight-card-reveal,
.highlight-card:focus-visible .highlight-card-reveal,
.highlight-card.is-revealed .highlight-card-reveal {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .highlight-card-img, .highlight-card-title, .highlight-card-reveal {
    transition: opacity 0.15s linear;
  }
  .highlight-card:hover .highlight-card-img,
  .highlight-card:focus-visible .highlight-card-img,
  .highlight-card.is-revealed .highlight-card-img {
    transform: none;
  }
}

/* Homepage: trust section */
.trust-section {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.trust-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  padding: 48px 20px;
}
.trust-icon { display:flex; align-items:center; justify-content:center; width:52px; height:52px; border-radius:50%; background:#fff; color:var(--orange,#F2762E); border:1px solid var(--border); margin-bottom:14px; }
.trust-icon svg { width:26px; height:26px; }
.trust-item h3 {
  color: var(--navy);
  font-size: 1rem;
  margin-bottom: 10px;
}
.trust-item p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .home-highlights { grid-template-columns: 1fr; }
  .trust-inner { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 500px) {
  .trust-inner { grid-template-columns: 1fr; }
}

/* Stats band (sotto l'hero) */
.stats-band {
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}
.stats-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px;
}
.stat-item {
  display: flex;
  align-items: center;
  gap: 10px;
}
.stat-icon {
  width: 22px;
  height: 22px;
  color: var(--accent);
  flex-shrink: 0;
}
.stat-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy);
}
.stat-item-badge img {
  display: block;
}

/* Titoli di sezione generici */
.section-title {
  text-align: center;
  color: var(--navy);
  font-size: 1.6rem;
  margin-bottom: 40px;
}

/* Come funziona */
.process-section {
  padding: 64px 20px;
}
.process-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}
.process-step {
  text-align: center;
  position: relative;
}
.process-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--bg-alt);
  border: 2px solid var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
}
.process-icon svg {
  width: 26px;
  height: 26px;
}
.process-number {
  display: block;
  font-size: 0.75rem;
  font-weight: bold;
  color: var(--accent);
  margin-bottom: 6px;
}
.process-step h3 {
  color: var(--navy);
  font-size: 1rem;
  margin-bottom: 8px;
}
.process-step p {
  color: var(--text-muted);
  font-size: 0.88rem;
}

/* CTA banner finale */
.cta-banner {
  background-size: cover;
  background-position: center;
  color: #fff;
  text-align: center;
  padding: 72px 20px;
}
.cta-banner h2 {
  font-size: 1.6rem;
  margin-bottom: 12px;
}
.cta-banner p {
  color: #dbe3f0;
  margin-bottom: 24px;
}

@media (max-width: 900px) {
  .process-steps { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 500px) {
  .process-steps { grid-template-columns: 1fr; }
  .stats-inner { justify-content: center; text-align: center; }
}

/* ===== Pagine pubbliche: vetrina, blog, partner ===== */

.page-intro {
  color: var(--text-muted);
  margin-bottom: 24px;
  max-width: 700px;
}

/* Filtri categoria (vetrina) */
.category-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 32px;
}
.filter-pill {
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--navy);
  font-size: 0.9rem;
  font-weight: 600;
}
.filter-pill:hover { border-color: var(--navy); }
.filter-pill-active {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}
.filter-pill-active:hover { color: #fff; }

/* Grid generico per card (prodotti/blog/partner) */
.product-grid, .blog-grid, .partner-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 48px;
}

.product-card, .blog-card, .partner-card {
  display: block;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  color: var(--text);
}
.product-card:hover, .blog-card:hover, .partner-card:hover {
  border-color: var(--navy);
}

.product-card-img-wrap, .blog-card-img-wrap {
  position: relative;
  height: 200px;
  background: #e9edf2;
}
.blog-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.product-card-noimg {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.product-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: bold;
  padding: 4px 10px;
  border-radius: 4px;
}

.product-card-body, .blog-card-body, .partner-card {
  padding: 20px;
}
.product-card-cat {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--accent);
  margin-bottom: 6px;
}
.product-card h2, .blog-card h2, .partner-card h2 {
  color: var(--navy);
  font-size: 1.05rem;
  margin-bottom: 6px;
}
.product-card-condition {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 8px;
}
.product-card-price {
  color: var(--navy);
  font-weight: bold;
  font-size: 1.1rem;
}
.blog-card p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 8px; }
.blog-card time { color: var(--text-muted); font-size: 0.8rem; }

/* Scheda prodotto */
.product-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.product-main-img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--border);
  display: block;
}
.product-thumbs {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}
.product-thumb {
  width: 64px;
  height: 64px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  border: 2px solid var(--border);
}
.product-thumb:hover { border-color: var(--accent); }
.product-brand { color: var(--text-muted); margin-bottom: 12px; }
.product-price-big { font-size: 1.8rem; color: var(--navy); font-weight: bold; margin-bottom: 8px; }
.product-condition-badge { color: var(--text-muted); margin-bottom: 20px; }
.product-status-note {
  background: #fff3e0;
  color: #b45309;
  padding: 10px 14px;
  border-radius: 6px;
  margin-bottom: 20px;
  font-size: 0.9rem;
}
.product-description { color: var(--text-muted); margin-bottom: 20px; }
.product-specs {
  list-style: none;
  margin-bottom: 24px;
}
.product-specs li {
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Articolo blog */
.blog-article { max-width: 760px; }
.blog-article-date { color: var(--text-muted); font-size: 0.85rem; display: block; margin-bottom: 20px; }
.blog-article-cover { width: 100%; border-radius: 8px; margin-bottom: 24px; max-height: 400px; object-fit: cover; }
.blog-article-body :is(h2, h3) { color: var(--navy); margin: 28px 0 10px; }
.blog-article-body p { color: var(--text-muted); margin-bottom: 14px; }
.blog-article-back { margin-top: 32px; font-weight: 600; }

/* Partner */
.partner-card-logo { max-height: 40px; margin-bottom: 12px; }
.partner-card-city { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 8px; }
.partner-card-stat { color: var(--accent); font-weight: bold; font-size: 0.85rem; margin-top: 10px; }

.partner-cover { width: 100%; max-height: 320px; object-fit: cover; border-radius: 8px; margin-bottom: 24px; }
.partner-detail-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 32px;
}
.partner-detail-logo { max-height: 60px; }
.partner-detail-stat { color: var(--accent); font-weight: bold; }
.partner-detail-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
}
.partner-detail-side {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
  align-self: start;
}
.partner-detail-side h2 { color: var(--navy); font-size: 1rem; margin: 16px 0 10px; }
.partner-detail-side h2:first-child { margin-top: 0; }
.partner-detail-side .footer-icon-row { color: var(--text); margin-bottom: 10px; }
.partner-detail-side .footer-icon { color: var(--accent); }
.partner-detail-side .btn-outline {
  display: inline-block;
  margin-top: 16px;
  background: transparent;
}

@media (max-width: 900px) {
  .product-grid, .blog-grid, .partner-grid { grid-template-columns: repeat(2, 1fr); }
  .product-detail-grid, .partner-detail-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .product-grid, .blog-grid, .partner-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   Pagina contatti / modulo
   ============================================================ */
.btn-outline-dark {
  background: transparent;
  color: var(--navy);
  border: 1px solid var(--navy);
}
.btn-outline-dark:hover { background: var(--navy); color: #fff; }

.contact-intro { max-width: 760px; margin-bottom: 28px; }
.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}
.contact-form-wrap h2, .contact-card h2 {
  color: var(--navy);
  font-size: 1.2rem;
  margin-bottom: 16px;
}
.contact-form-wrap {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
}
.form-row { margin-bottom: 18px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact-form label,
.contact-form legend { display: block; font-weight: bold; font-size: 0.9rem; margin-bottom: 6px; color: var(--text); }
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #b9c3cf;
  border-radius: 4px;
  font: inherit;
  background: #fff;
  color: var(--text);
}
.contact-form textarea { resize: vertical; min-height: 130px; }
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: 3px solid rgba(22,71,138,0.25);
  border-color: var(--navy);
}
.contact-form [aria-invalid="true"] { border-color: #c0392b; background: #fff8f7; }
.field-error { display: block; color: #b0301f; font-size: 0.85rem; margin-top: 5px; }

.form-radios { border: 0; padding: 0; }
.form-radios label { display: inline-block; font-weight: normal; margin-right: 20px; }
.form-radios input { margin-right: 6px; }

.form-consent label { display: flex; gap: 10px; align-items: flex-start; font-weight: normal; font-size: 0.9rem; }
.form-consent input { margin-top: 4px; flex-shrink: 0; }

/* campo trappola per i bot: fuori schermo, non display:none (alcuni bot lo ignorano) */
.hp-field { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

.recaptcha-box { min-height: 78px; margin-bottom: 14px; }
.btn-submit { border: 0; cursor: pointer; font-size: 1rem; }
.btn-submit:disabled { opacity: 0.7; cursor: wait; }
.form-note { font-size: 0.8rem; color: var(--text-muted); margin-top: 14px; }
.grecaptcha-badge { visibility: hidden; } /* l'informativa Google è riportata sotto al modulo */

.alert { padding: 14px 16px; border-radius: 4px; margin-bottom: 20px; font-size: 0.95rem; }
.alert-error { background: #fdecea; color: #8e2417; border: 1px solid #f1b9b1; }
.alert:focus { outline: 3px solid rgba(192,57,43,0.35); }

.contact-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 22px;
  margin-bottom: 20px;
}
.contact-row { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; }
.contact-icon { color: var(--accent); flex-shrink: 0; margin-top: 3px; }
.btn-whatsapp {
  display: inline-flex; align-items: center; gap: 8px;
  background: #1f9d55; color: #fff; margin-top: 6px;
}
.btn-whatsapp:hover { background: #17824a; color: #fff; }
.hours-list { list-style: none; }
.hours-list li { padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 0.95rem; }
.hours-list li:last-child { border-bottom: 0; }

.map-box {
  background: #e8edf3;
  border-radius: 6px;
  min-height: 200px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 16px; margin-bottom: 12px;
}
.map-box .map-hint { font-size: 0.78rem; color: var(--text-muted); margin-top: 10px; }
.map-box-loaded { padding: 0; display: block; overflow: hidden; }
.map-box iframe { width: 100%; height: 260px; border: 0; display: block; }

/* Pagina di ringraziamento */
.thanks-page { max-width: 720px; }
.thanks-lead { font-size: 1.1rem; margin: 16px 0; }
.thanks-actions { margin-top: 28px; display: flex; gap: 12px; flex-wrap: wrap; }

/* Recensioni */
.reviews-section { background: var(--bg-alt); padding: 56px 0; border-top: 1px solid var(--border); }
.reviews-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-top: 24px; }
.review-card { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 22px; }
.review-card blockquote { margin: 10px 0 14px; color: var(--text); font-size: 0.95rem; }
.review-card figcaption { font-weight: bold; color: var(--navy); font-size: 0.9rem; }
.review-date { font-weight: normal; color: var(--text-muted); }
.stars { display: inline-flex; gap: 2px; }
.star { fill: #d5dbe3; }
.star-on { fill: var(--accent); }

.footer-legal-links { margin-bottom: 10px; font-size: 0.85rem; }
.footer-legal-links a { color: var(--footer-text); text-decoration: underline; }
.footer-legal-links a:hover { color: #fff; }

@media (max-width: 860px) {
  .contact-layout { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .form-grid { grid-template-columns: 1fr; gap: 0; }
  .contact-form-wrap { padding: 20px 16px; }
}

/* ============================================================
   Pagina 404
   ============================================================ */
.error-page { padding-top: 48px; padding-bottom: 24px; }
.error-grid { display: flex; flex-direction: column; align-items: center; gap: 28px; text-align: center; max-width: 640px; margin: 0 auto; }
.error-visual { order: -1; width: 100%; max-width: 440px; }
.error-img { display: block; width: auto; max-width: 100%; max-height: 340px; height: auto; margin: 0 auto; }
.error-text { width: 100%; }
.error-code { color: var(--accent); font-weight: bold; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.85rem; margin-bottom: 8px; }
.error-text h1 { color: var(--navy); font-size: 2rem; line-height: 1.2; margin-bottom: 14px; }
.error-joke { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 22px; }
.diagnosi { text-align: left; max-width: 460px; margin-left: auto !important; margin-right: auto !important; list-style: none; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 8px; padding: 14px 18px; margin-bottom: 22px; font-size: 0.95rem; }
.diagnosi li { padding: 4px 0; }
.diagnosi span { display: inline-block; width: 1.4em; font-weight: bold; }
.diag-ok span { color: #1f9d55; }
.diag-ko { color: #b0301f; font-weight: bold; }
.diag-ko span { color: #b0301f; }
.diag-maybe { color: var(--text-muted); }
.diag-maybe span { color: var(--accent); }
.repair-bar { max-width: 460px; margin-left: auto; margin-right: auto; position: relative; height: 26px; background: #e8edf3; border-radius: 13px; overflow: hidden; margin-bottom: 26px; }
.repair-bar-fill {
  position: absolute; inset: 0 auto 0 0; width: 100%;
  background: repeating-linear-gradient(135deg, var(--accent) 0 14px, #f58c4d 14px 28px);
  background-size: 40px 40px;
  animation: repair-stripes 1.2s linear infinite;
}
.repair-bar-label { position: relative; display: block; text-align: center; font-size: 0.8rem; font-weight: bold; line-height: 26px; color: var(--navy-dark); }
@keyframes repair-stripes { from { background-position: 0 0; } to { background-position: 40px 0; } }
.error-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-bottom: 18px; }
.error-note { font-size: 0.9rem; color: var(--text-muted); }
@media (max-width: 860px) {
  .error-text h1 { font-size: 1.6rem; }
}
@media (prefers-reduced-motion: reduce) { .repair-bar-fill { animation: none; } }

/* Hero: doppia CTA (riparazioni + usato) */
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ============================================================
   Slider usato in homepage
   ============================================================ */
.used-showcase { padding: 56px 0 48px; background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.showcase-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 24px; }
.showcase-head h2 { color: var(--navy); font-size: 1.6rem; margin-bottom: 6px; }
.showcase-head p { color: var(--text-muted); }
.showcase-nav { display: flex; gap: 8px; flex-shrink: 0; }
.showcase-nav[hidden] { display: none; }
.showcase-btn {
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--navy); background: #fff; color: var(--navy);
  font-size: 1.2rem; line-height: 1; cursor: pointer;
}
.showcase-btn:hover:not(:disabled) { background: var(--navy); color: #fff; }
.showcase-btn:disabled { opacity: 0.35; cursor: default; }
.used-track {
  list-style: none; display: flex; gap: 20px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-left: 0;
  padding: 4px 2px 16px; margin: 0 -2px;
}
.used-track:focus-visible { outline: 3px solid rgba(22,71,138,0.35); outline-offset: 2px; }
.used-slide { flex: 0 0 270px; scroll-snap-align: start; }
.used-slide .product-card { height: 100%; background: #fff; }
.used-slide .product-card h3 { color: var(--navy); font-size: 1.05rem; margin-bottom: 6px; }
.product-badge-warranty { right: auto; left: 10px; background: var(--navy); }
.showcase-more { text-align: center; margin-top: 12px; }
@media (max-width: 560px) {
  .showcase-head { flex-direction: column; align-items: flex-start; }
  .used-slide { flex-basis: 78%; }
}
@media (prefers-reduced-motion: no-preference) { .used-track { scroll-behavior: smooth; } }

/* Slider usato: prodotto in primo piano, prezzo ben visibile, scorrimento automatico */
.used-slide { flex-basis: 262px; }

.product-price-tag {
  position: absolute; right: 10px; bottom: 10px;
  background: var(--accent); color: var(--navy-dark);
  font-weight: bold; font-size: 1.15rem; padding: 6px 14px; border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}
.product-price-tag-ask { font-size: 0.85rem; background: #fff; color: var(--navy); }
.used-slide .product-card { transition: transform .2s ease, box-shadow .2s ease; }
.used-slide .product-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(15,49,104,0.15); }
.used-slide .product-card-price { display: none; } /* il prezzo è già in evidenza sull'immagine */
.showcase-btn-pause { font-size: 0.9rem; }
.showcase-btn-pause[aria-pressed="true"] { background: var(--navy); color: #fff; }
@media (prefers-reduced-motion: reduce) { .used-slide .product-card { transition: none; } }

/* Avviso admin: manutenzione attiva */
.maintenance-bar { background: #b71c1c; color: #fff; text-align: center; font-size: 0.85rem; font-weight: bold; padding: 8px 16px; }

.process-illustration{display:block;width:100%;max-width:240px;aspect-ratio:1/0.9;height:auto;object-fit:contain;object-position:center bottom;margin:0 auto 18px}

/* Foto prodotti usati: mai ritagliate (formato quadrato, immagine intera) */
.product-card-img-wrap { height: auto; aspect-ratio: 1 / 1; background: #fff; border-bottom: 1px solid var(--border); }
.product-card-img-wrap img { width: 100%; height: 100%; object-fit: contain; display: block; }

/* ============================================================
   Pagina Chi siamo
   ============================================================ */
.about-hero { position: relative; background: #fff; overflow: hidden; border-bottom: 1px solid var(--border); }
.about-hero-img { display: block; width: 100%; height: auto; }
.about-hero-inner { position: absolute; inset: 0; display: flex; align-items: center; }
.about-hero-text { max-width: 46%; }
.about-hero-text h1 { color: var(--navy); font-size: clamp(2rem, 4vw, 3rem); line-height: 1.1; margin-bottom: 14px; }
.about-hero-text p { color: var(--text-muted); font-size: 1.1rem; line-height: 1.5; }
.about-body { padding-top: 48px; padding-bottom: 16px; }
.about-body .page-body { max-width: 820px; margin: 0 auto; }
.about-body .page-body p { font-size: 1.02rem; line-height: 1.7; }
.about-process { background: var(--bg-alt); }
@media (max-width: 800px) {
  .about-hero-img { height: 190px; object-fit: cover; object-position: 78% center; }
  .about-hero-inner { position: static; padding: 28px 20px 8px; display: block; }
  .about-hero-text { max-width: none; }
}
.about-body { background: #fff; }
.about-badge { text-align: center; background: #fff; margin: 28px 0 8px !important; }
.about-badge img { display: inline-block; max-width: 100%; height: auto; background: #fff; }

/* Dove siamo: laboratori e affiliati */
.places-section { margin-top: 36px; }
.places-section:first-of-type { margin-top: 8px; }
.places-section > h2 { color: var(--navy); font-size: 1.5rem; margin-bottom: 6px; padding-bottom: 8px; border-bottom: 2px solid var(--accent); display: inline-block; }
.places-section .page-intro { margin: 10px 0 22px; }
.partner-card h3 { color: var(--navy); font-size: 1.15rem; margin-bottom: 6px; }
.partner-card--lab { border-top: 3px solid var(--accent); }

/* ============================================================
   Pagina servizio: riparazione smartphone e tablet
   ============================================================ */
.service-hero { background: var(--bg-alt); border-bottom: 1px solid var(--border); padding: 56px 0 48px; text-align: center; }
.service-hero h1 { color: var(--navy); font-size: clamp(1.8rem, 4vw, 2.6rem); line-height: 1.15; margin-bottom: 14px; }
.service-hero p { max-width: 720px; margin: 0 auto 24px; color: var(--text-muted); font-size: 1.1rem; }
.service-hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.service-content { background: #fff; padding-top: 24px; padding-bottom: 24px; }
.service-block { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 48px; align-items: center; padding: 40px 0; }
.service-block + .service-block { border-top: 1px solid var(--border); }
.service-block--reverse .service-figure { order: 2; }
.service-figure { margin: 0; }
.service-figure--tall img { max-width: 280px; margin: 0 auto; }
.service-figure img { display: block; width: 100%; height: auto; border-radius: 10px; background: #fff; }
.service-text h2 { color: var(--navy); font-size: 1.7rem; margin-bottom: 14px; }
.service-text h3 { color: var(--navy); font-size: 1.05rem; margin: 20px 0 10px; }
.service-text p { color: var(--text-muted); line-height: 1.7; margin-bottom: 14px; }
.service-text p strong { color: var(--text); }
.brand-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0 0 18px; padding: 0; }
.brand-list li { background: var(--bg-alt); border: 1px solid var(--border); color: var(--navy); font-weight: bold; font-size: 0.9rem; padding: 5px 14px; border-radius: 999px; }
.tips-box { background: #fff8f2; border-left: 4px solid var(--accent); border-radius: 6px; padding: 14px 18px; margin: 20px 0; }
.tips-box h3 { margin-top: 0; }
.tips-box ul { margin: 0; padding-left: 20px; color: var(--text-muted); }
.tips-box li { margin-bottom: 6px; line-height: 1.6; }
.service-contact { background: var(--bg-alt); border-top: 1px solid var(--border); padding: 56px 0; }
.service-contact-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.service-contact h2 { color: var(--navy); margin-bottom: 10px; }
.service-contact p { color: var(--text-muted); margin-bottom: 16px; }
.service-contact-card { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 24px; }
.service-contact-card h3 { color: var(--navy); margin-bottom: 10px; }
.service-contact-card p { margin-bottom: 8px; }
.service-contact-card a:not(.btn) { color: var(--navy); font-weight: bold; text-decoration: none; }
.service-contact-card .btn { margin-top: 10px; }
@media (max-width: 800px) {
  .service-block, .service-contact-inner { grid-template-columns: 1fr; gap: 22px; }
  .service-block--reverse .service-figure { order: 0; }
  .service-figure { max-width: 420px; margin: 0 auto; }
}

/* Pagine servizio: hero con banner, blocchi senza immagine, pulsanti */
.service-hero-actions--left { justify-content: flex-start; margin-top: 18px; }
.about-hero-text .service-hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.service-block--text { grid-template-columns: minmax(0, 1fr); }
.service-block--text .service-text { max-width: 860px; }
.service-block--text .service-text h2 { font-size: 1.5rem; }
.service-block .btn { margin-top: 6px; }
.service-block--alt { background: var(--bg-alt); border-radius: 12px; padding: 40px; border-top: 0 !important; margin: 12px 0; }
@media (max-width: 800px) { .service-block--alt { padding: 24px 18px; } }

/* Gradi dell'usato e tipologia (usato / ricondizionato) */
.grade-badge { display:inline-block; min-width:30px; padding:2px 8px; border-radius:7px; color:#fff; font-weight:bold; text-align:center; font-size:.85rem; }
.grade-aplus { background:#1f8a3b; } .grade-a { background:#16478a; } .grade-b { background:#f29a0c; } .grade-c { background:#d32f2f; }
.grade-name { font-weight:bold; color:var(--navy); font-size:.9rem; }
.type-tag { display:inline-block; padding:2px 9px; border-radius:999px; font-size:.75rem; font-weight:bold; border:1px solid; white-space:nowrap; }
.type-usato { color:#F2762E; border-color:#F2762E; background:#fff6f0; }
.type-ricondizionato { color:#16478a; border-color:#16478a; background:#eef4fc; }
.product-card-condition { display:flex; flex-wrap:wrap; gap:6px; align-items:center; }
.product-condition-desc { color:var(--text-muted); font-size:.92rem; margin:0 0 12px; }

.used-guide { margin:8px 0 36px; }
.used-types { display:grid; grid-template-columns:1fr 1fr; gap:16px; margin-bottom:28px; }
.used-type { border-radius:14px; padding:18px 20px; text-align:center; }
.used-type h2 { margin:0 0 8px; font-size:1.3rem; color:#fff; padding:8px 12px; border-radius:10px; text-transform:uppercase; }
.used-type p { margin:0; font-weight:bold; color:var(--navy); }
.used-type--usato { background:#f5f5f5; } .used-type--usato h2 { background:#F2762E; }
.used-type--ricondizionato { background:#e8f2fd; } .used-type--ricondizionato h2 { background:#16478a; }
.used-guide-title { text-align:center; margin:0 0 16px; color:#fff; background:#F2762E; border-radius:12px; padding:10px 14px; text-transform:uppercase; font-size:1.4rem; }
.grade-legend { display:grid; grid-template-columns:repeat(4,1fr); gap:14px; }
.grade-card { border-radius:14px; padding:14px; border:1px solid transparent; }
.grade-card--aplus { background:#eaf7ee; border-color:#cfe9d6; } .grade-card--a { background:#e9f2fc; border-color:#cfe0f3; }
.grade-card--b { background:#fff6e0; border-color:#f5e2b0; } .grade-card--c { background:#fdecec; border-color:#f3cccc; }
.grade-card-head { display:flex; flex-direction:column; align-items:center; color:#fff; border-radius:10px; padding:8px 6px; line-height:1.1; }
.grade-card-code { font-size:2rem; font-weight:900; } .grade-card-name { font-size:.8rem; font-weight:bold; text-transform:uppercase; letter-spacing:.03em; }
.grade-card-tag { text-align:center; font-weight:bold; color:var(--navy); background:#fff; border-radius:8px; padding:6px; margin:12px 0 10px; text-transform:uppercase; font-size:.85rem; }
.grade-card-desc { margin:0; font-size:.88rem; color:var(--text-muted); }
.used-warranty { margin-top:16px; background:var(--navy); color:#fff; border-radius:14px; padding:14px 18px; text-align:center; }
.used-warranty strong { color:#ffb27a; }
@media (max-width:900px) { .grade-legend { grid-template-columns:repeat(2,1fr); } }
@media (max-width:560px) { .used-types, .grade-legend { grid-template-columns:1fr; } }
