/* =========================================================
   1 KM E SI MANGIA
   STYLES.CSS
========================================================= */

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


:root {

  --verde: #075c3b;
  --verde-scuro: #03452d;
  --verde-chiaro: #0d7950;

  --arancio: #f59b16;

  --bianco: #ffffff;

  --sfondo: #f5f7f4;

  --testo: #18352b;

  --grigio: #66736d;

}


/* =========================================================
   BASE
========================================================= */

html {
  scroll-behavior: smooth;
}


body {

  font-family:
    "Roboto Condensed",
    Arial,
    Helvetica,
    sans-serif;

  background:
    var(--sfondo);

  color:
    var(--testo);

  min-height:
    100vh;

}


/* =========================================================
   HEADER
========================================================= */

.topbar {

  height: 76px;

  background:
    var(--verde);

  color:
    white;

  display:
    flex;

  align-items:
    center;

  justify-content:
    space-between;

  padding:
    0 6%;

  box-shadow:
    0 3px 12px
    rgba(0,0,0,0.15);

  position:
    relative;

  z-index:
    1000;

}


.logo {

  display:
    flex;

  align-items:
    center;

  gap:
    12px;

}


.logo-pin {

  width:
    48px;

  height:
    55px;

  display:
    flex;

  align-items:
    center;

  justify-content:
    center;

}


.logo-pin svg {

  width:
    48px;

  height:
    55px;

  display:
    block;

}


.logo-text {

  display:
    flex;

  flex-direction:
    column;

  line-height:
    1;

}


.logo-text strong {

  font-size:
    25px;

  font-weight:
    800;

  letter-spacing:
    1px;

}


.logo-text span {

  color:
    var(--arancio);

  font-size:
    14px;

  font-weight:
    bold;

  letter-spacing:
    1.5px;

  margin-top:
    5px;

}


.menu-button {

  border:
    none;

  background:
    transparent;

  color:
    white;

  font-size:
    28px;

  cursor:
    pointer;

  width:
    48px;

  height:
    48px;

  display:
    flex;

  align-items:
    center;

  justify-content:
    center;

}


/* =========================================================
   MENU MOBILE
========================================================= */

.mobile-menu {

  position:
    fixed;

  top:
    0;

  right:
    0;

  width:
    min(390px, 88vw);

  height:
    100vh;

  background:
    var(--verde-scuro);

  color:
    white;

  z-index:
    3000;

  transform:
    translateX(100%);

  transition:
    transform 0.3s ease;

  box-shadow:
    -8px 0 30px
    rgba(0,0,0,0.25);

  overflow-y:
    auto;

}


.mobile-menu.active {

  transform:
    translateX(0);

}


.mobile-menu-inner {

  min-height:
    100%;

  padding:
    24px;

  position:
    relative;

}


.menu-close {

  position:
    absolute;

  top:
    20px;

  right:
    20px;

  width:
    45px;

  height:
    45px;

  border:
    1px solid
    rgba(255,255,255,0.5);

  background:
    transparent;

  color:
    white;

  font-size:
    34px;

  line-height:
    1;

  cursor:
    pointer;

}


.menu-close:hover {

  background:
    white;

  color:
    var(--verde-scuro);

}


.mobile-menu-title {

  padding:
    10px 0 35px;

  border-bottom:
    1px solid
    rgba(255,255,255,0.2);

}


.mobile-menu-title strong {

  display:
    block;

  font-size:
    32px;

  line-height:
    1;

  font-weight:
    800;

}


.mobile-menu-title span {

  display:
    block;

  margin-top:
    6px;

  color:
    var(--arancio);

  font-size:
    13px;

  font-weight:
    800;

  letter-spacing:
    2px;

}


.menu-links {

  display:
    flex;

  flex-direction:
    column;

  padding-top:
    20px;

}


.menu-link {

  display:
    flex;

  flex-direction:
    column;

  gap:
    4px;

  padding:
    18px 5px;

  color:
    white;

  text-decoration:
    none;

  border-bottom:
    1px solid
    rgba(255,255,255,0.12);

  transition:
    0.2s ease;

}


.menu-link strong {

  font-size:
    18px;

  letter-spacing:
    0.5px;

}


.menu-link span {

  color:
    rgba(255,255,255,0.65);

  font-size:
    13px;

}


.menu-link:hover {

  padding-left:
    10px;

}


.menu-link:hover strong {

  color:
    var(--arancio);

}


/* =========================================================
   HERO
========================================================= */

.hero {

  min-height:
    595px;

  background:

    linear-gradient(
      90deg,
      rgba(3,69,45,0.98),
      rgba(3,69,45,0.40)
    ),

    linear-gradient(
      135deg,
      #2c614c,
      #82a08f
    );

  display:
    flex;

  align-items:
    center;

  padding:
    70px 8%;

  position:
    relative;

  overflow:
    hidden;

}


.hero::before {

  content:
    "";

  position:
    absolute;

  inset:
    18px;

  border:
    2px solid
    rgba(255,255,255,0.9);

  pointer-events:
    none;

}


.hero::after {

  content:
    "";

  position:
    absolute;

  right:
    -50px;

  bottom:
    -80px;

  width:
    430px;

  height:
    330px;

  border-right:
    6px solid
    rgba(255,255,255,0.15);

  border-bottom:
    6px solid
    rgba(255,255,255,0.15);

  border-radius:
    0 0 330px 0;

  transform:
    rotate(-8deg);

  pointer-events:
    none;

}


.hero-content {

  max-width:
    620px;

  position:
    relative;

  z-index:
    2;

  color:
    white;

}


.small-title {

  color:
    var(--arancio);

  font-size:
    14px;

  font-weight:
    800;

  letter-spacing:
    2px;

  margin-bottom:
    20px;

}


.hero h1 {

  font-family:
    "Roboto Condensed",
    Arial,
    Helvetica,
    sans-serif;

  font-size:
    clamp(55px, 8vw, 90px);

  line-height:
    0.9;

  text-transform:
    uppercase;

  letter-spacing:
    -2px;

  font-weight:
    800;

  margin-bottom:
    28px;

}


.description {

  font-size:
    20px;

  line-height:
    1.5;

  max-width:
    520px;

  margin-bottom:
    32px;

  color:
    rgba(255,255,255,0.92);

}


.hero-buttons {

  display:
    flex;

  flex-wrap:
    wrap;

  gap:
    10px;

}


.location-button,
.map-button {

  padding:
    16px 23px;

  border-radius:
    0;

  font-family:
    inherit;

  font-weight:
    800;

  font-size:
    15px;

  cursor:
    pointer;

  transition:
    0.2s;

}


.location-button {

  border:
    none;

  background:
    var(--arancio);

  color:
    #222;

}


.map-button {

  border:
    2px solid white;

  background:
    transparent;

  color:
    white;

}


.location-button:hover {

  transform:
    translateY(-2px);

}


.map-button:hover {

  background:
    white;

  color:
    var(--verde);

}


/* =========================================================
   PUBBLICITÀ
========================================================= */

.ad-space {

  width:
    100%;

  padding:
    18px 8%;

  background:
    #f5f7f4;

}


.ad-box {

  width:
    100%;

  max-width:
    728px;

  min-height:
    90px;

  margin:
    auto;

  border:
    1px solid
    #dfe5e1;

  background:
    #fafbfa;

  display:
    flex;

  flex-direction:
    column;

  align-items:
    center;

  justify-content:
    center;

  position:
    relative;

}


.ad-label {

  position:
    absolute;

  top:
    6px;

  left:
    8px;

  color:
    #a2aaa5;

  font-size:
    8px;

  letter-spacing:
    1.5px;

}


.ad-placeholder {

  color:
    #aab1ad;

  font-size:
    10px;

  letter-spacing:
    1.5px;

}


/* =========================================================
   MAPPA
========================================================= */

.map-section {

  background:
    white;

  padding:
    65px 8% 75px;

}


.map-header {

  max-width:
    1100px;

  margin:
    0 auto 25px;

}


.map-label {

  color:
    var(--arancio);

  font-size:
    13px;

  font-weight:
    800;

  letter-spacing:
    2px;

  margin-bottom:
    8px;

}


.map-header h2 {

  color:
    var(--verde-scuro);

  font-size:
    38px;

  font-weight:
    800;

  margin-bottom:
    8px;

}


.map-header p {

  color:
    var(--grigio);

}


#map {

  width:
    100%;

  max-width:
    1100px;

  height:
    520px;

  margin:
    auto;

  border-radius:
    4px;

  overflow:
    hidden;

  box-shadow:
    0 10px 35px
    rgba(0,0,0,0.14);

  border:
    4px solid white;

}


.map-legend {

  max-width:
    1100px;

  margin:
    15px auto 0;

  display:
    flex;

  gap:
    25px;

  color:
    var(--grigio);

  font-size:
    14px;

}


.map-legend div {

  display:
    flex;

  align-items:
    center;

  gap:
    7px;

}


.legend-dot {

  width:
    13px;

  height:
    13px;

  background:
    var(--arancio);

  border-radius:
    50%;

}


.legend-route {

  width:
    28px;

  height:
    4px;

  background:
    var(--verde);

  border-radius:
    5px;

}


/* =========================================================
   COME FUNZIONA
========================================================= */

.how-it-works {

  padding:
    70px 8%;

  text-align:
    center;

  background:
    white;

}


.how-it-works h2,
.rules h2 {

  font-size:
    34px;

  font-weight:
    800;

  margin-bottom:
    40px;

  color:
    var(--verde-scuro);

}


.steps {

  display:
    grid;

  grid-template-columns:
    repeat(3,1fr);

  gap:
    25px;

  max-width:
    1100px;

  margin:
    auto;

}


.step {

  padding:
    35px 25px;

  border-radius:
    6px;

  background:
    var(--sfondo);

  border:
    1px solid
    #e2e8e4;

}


.step-icon {

  width:
    65px;

  height:
    65px;

  background:
    var(--verde);

  color:
    white;

  border-radius:
    50%;

  margin:
    0 auto 20px;

  display:
    flex;

  align-items:
    center;

  justify-content:
    center;

  font-size:
    28px;

}


.step h3 {

  color:
    var(--verde-scuro);

  margin-bottom:
    12px;

  font-size:
    20px;

}


.step p {

  color:
    var(--grigio);

  line-height:
    1.5;

}


/* =========================================================
   REGOLE
========================================================= */

.rules {

  padding:
    70px 8%;

  text-align:
    center;

}


.rule-list {

  max-width:
    950px;

  margin:
    auto;

  display:
    grid;

  grid-template-columns:
    repeat(3,1fr);

  gap:
    20px;

}


.rule {

  border-radius:
    6px;

  padding:
    25px;

  display:
    flex;

  flex-direction:
    column;

  gap:
    8px;

  color:
    white;

}


.rule strong {

  font-size:
    28px;

}


.rule span {

  font-size:
    14px;

  font-weight:
    bold;

  letter-spacing:
    1px;

}


.green {

  background:
    #08764d;

}


.yellow {

  background:
    #e59a13;

  color:
    #222;

}


.red {

  background:
    #b52e2e;

}


/* =========================================================
   FOOTER
========================================================= */

footer {

  background:
    var(--verde-scuro);

  color:
    white;

  text-align:
    center;

  padding:
    35px;

}


footer strong {

  font-size:
    20px;

}


footer p {

  margin-top:
    8px;

  color:
    rgba(255,255,255,0.75);

}


/* =========================================================
   MARKER CASELLO
========================================================= */

.custom-marker {

  width:
    36px;

  height:
    36px;

  background:
    var(--arancio);

  border:
    4px solid white;

  border-radius:
    50%;

  box-shadow:
    0 3px 10px
    rgba(0,0,0,0.35);

}


.exit-popup {

  min-width:
    180px;

  text-align:
    center;

}


.exit-popup strong {

  color:
    var(--verde-scuro);

  font-size:
    17px;

}


.exit-popup small {

  display:
    block;

  margin-top:
    5px;

  color:
    #666;

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width:700px) {

  .topbar {

    height:
      68px;

    padding:
      0 18px;

  }


  .logo-pin {

    width:
      40px;

    height:
      46px;

  }


  .logo-pin svg {

    width:
      40px;

    height:
      46px;

  }


  .logo-text strong {

    font-size:
      20px;

  }


  .logo-text span {

    font-size:
      11px;

  }


  .hero {

    min-height:
      600px;

    padding:
      55px 25px;

  }


  .hero::before {

    inset:
      12px;

  }


  .hero h1 {

    font-size:
      58px;

  }


  .description {

    font-size:
      17px;

  }


  .hero-buttons {

    flex-direction:
      column;

  }


  .location-button,
  .map-button {

    width:
      100%;

  }


  .ad-space {

    padding:
      14px 15px;

  }


  .ad-box {

    min-height:
      70px;

  }


  .map-section {

    padding:
      50px 15px 60px;

  }


  .map-header h2 {

    font-size:
      30px;

  }


  #map {

    height:
      450px;

  }


  .map-legend {

    flex-wrap:
      wrap;

  }


  .steps {

    grid-template-columns:
      1fr;

  }


  .rule-list {

    grid-template-columns:
      1fr;

  }


  .how-it-works,
  .rules {

    padding:
      55px 20px;

  }


  .how-it-works h2,
  .rules h2 {

    font-size:
      28px;

  }

}/* =====================================================
   MENU MOBILE - 1 KM E SI MANGIA
   ===================================================== */

.site-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;

  display: flex;
  justify-content: flex-end;
  align-items: stretch;

  background: rgba(0, 0, 0, 0.55);

  opacity: 0;
  visibility: hidden;

  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}


.site-menu-overlay.is-open {
  opacity: 1;
  visibility: visible;
}


/* =====================================================
   PANNELLO
   ===================================================== */

.site-menu {
  width: min(390px, 88vw);
  height: 100%;

  background: #075c3b;

  color: #ffffff;

  box-shadow:
    -10px 0 35px rgba(0, 0, 0, 0.25);

  transform: translateX(100%);

  transition:
    transform 0.3s ease;

  display: flex;
  flex-direction: column;
}


.site-menu-overlay.is-open .site-menu {
  transform: translateX(0);
}


/* =====================================================
   TESTATA MENU
   ===================================================== */

.site-menu-header {
  min-height: 90px;

  padding:
    20px 22px;

  display: flex;
  align-items: center;
  justify-content: space-between;

  border-bottom:
    1px solid rgba(255, 255, 255, 0.25);
}


.site-menu-brand {
  display: flex;
  flex-direction: column;
}


.site-menu-brand strong {
  font-family:
    "Roboto Condensed",
    sans-serif;

  font-size: 28px;

  line-height: 1;

  letter-spacing: 1px;
}


.site-menu-brand span {
  margin-top: 5px;

  font-family:
    "Roboto Condensed",
    sans-serif;

  font-size: 11px;

  font-weight: 700;

  letter-spacing: 2px;

  color: #f5a900;
}


/* =====================================================
   PULSANTE CHIUDI
   ===================================================== */

.site-menu-close {
  width: 46px;
  height: 46px;

  border: 1px solid
    rgba(255, 255, 255, 0.45);

  background: transparent;

  color: #ffffff;

  font-size: 34px;

  line-height: 1;

  cursor: pointer;

  display: flex;
  align-items: center;
  justify-content: center;

  transition:
    background 0.2s ease,
    color 0.2s ease;
}


.site-menu-close:hover {
  background: #f5a900;

  color: #075c3b;
}


/* =====================================================
   NAVIGAZIONE
   ===================================================== */

.site-menu-nav {
  padding: 22px 18px;

  display: flex;
  flex-direction: column;

  gap: 10px;
}


.site-menu-nav .menu-link {
  width: 100%;

  min-height: 64px;

  padding:
    12px 16px;

  border: 1px solid
    rgba(255, 255, 255, 0.22);

  background:
    rgba(255, 255, 255, 0.06);

  color: #ffffff;

  font-family:
    "Roboto Condensed",
    sans-serif;

  cursor: pointer;

  display: flex;
  align-items: center;

  gap: 15px;

  text-align: left;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}


.site-menu-nav .menu-link:hover {
  background: #f5a900;

  border-color: #f5a900;

  color: #075c3b;

  transform: translateX(-4px);
}


.site-menu-nav .menu-link span {
  width: 28px;

  font-size: 21px;

  text-align: center;
}


.site-menu-nav .menu-link strong {
  font-size: 16px;

  letter-spacing: 0.5px;
}


/* =====================================================
   FOOTER MENU
   ===================================================== */

.site-menu-footer {
  margin-top: auto;

  padding:
    22px;

  border-top:
    1px solid rgba(255, 255, 255, 0.2);

  display: flex;
  flex-direction: column;

  gap: 7px;
}


.site-menu-footer strong {
  font-family:
    "Roboto Condensed",
    sans-serif;

  font-size: 18px;

  text-transform: uppercase;
}


.site-menu-footer span {
  font-size: 13px;

  line-height: 1.4;

  color:
    rgba(255, 255, 255, 0.7);
}


/* =====================================================
   BLOCCA LO SCROLL QUANDO IL MENU È APERTO
   ===================================================== */

body.menu-open {
  overflow: hidden;
}


/* =====================================================
   MOBILE
   ===================================================== */

@media (max-width: 700px) {

  .site-menu {
    width: 88vw;
    max-width: 360px;
  }

  .site-menu-header {
    min-height: 80px;

    padding:
      16px 18px;
  }

  .site-menu-brand strong {
    font-size: 25px;
  }

  .site-menu-nav {
    padding:
      18px 14px;
  }

  .site-menu-nav .menu-link {
    min-height: 60px;
  }

}


/* =====================================================
   DESKTOP
   ===================================================== */

@media (min-width: 701px) {

  .site-menu {
    width: 390px;
  }

}
/* =====================================================
   FIX DEFINITIVO LOGO
   ===================================================== */

   .logo-link {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: auto !important;
    height: auto !important;
    text-decoration: none !important;
    line-height: 0 !important;
  }
  
  .site-logo {
    width: 108px !important;
    height: 72px !important;
    max-width: 108px !important;
    max-height: 72px !important;
    object-fit: contain !important;
    display: block !important;
  }
  
  .mobile-menu-logo {
    display: block !important;
    width: 150px !important;
    height: auto !important;
    max-width: 150px !important;
    max-height: 150px !important;
    object-fit: contain !important;
    margin: 10px 0 0 !important;
  }
  
  .mobile-menu-title {
    width: 100% !important;
    height: auto !important;
    overflow: hidden !important;
  }
  
  @media (max-width: 750px) {
  
    .site-logo {
      width: 82px !important;
      height: 58px !important;
      max-width: 82px !important;
      max-height: 58px !important;
    }
  
    .mobile-menu-logo {
      width: 135px !important;
      max-width: 135px !important;
      max-height: 135px !important;
    }
  
  }
/* =========================================================
   LOGO USCITE AUTOSTRADALI
   Unico marchio per tutto ciò che riguarda "Esplora le uscite".
   L'immagine viene caricata da assets/uscite-autostradali.png.
   ========================================================= */
.uscite-logo-mark {
  display: inline-block;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  background: url('assets/uscite-autostradali.png') center / contain no-repeat;
  vertical-align: middle;
}

.menu-link .uscite-logo-mark,
.menu-links a .uscite-logo-mark {
  width: 38px;
  height: 38px;
  flex-basis: 38px;
  margin-right: 10px;
}

.uscite-menu-title {
  display: flex;
  align-items: center;
  gap: 0;
}

.uscite-menu-title strong {
  display: inline-flex;
  align-items: center;
}

.uscite-hero-title {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.uscite-hero-title .uscite-logo-mark {
  width: 54px;
  height: 54px;
  flex-basis: 54px;
}

.btn-icon .uscite-logo-mark {
  width: 42px;
  height: 42px;
}

@media (max-width: 750px) {
  .uscite-logo-mark {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
  }

  .menu-link .uscite-logo-mark,
  .menu-links a .uscite-logo-mark {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    margin-right: 8px;
  }

  .uscite-hero-title .uscite-logo-mark {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }
}
