/* ***** STATION NODE ***** */

.node--type-station {
  width: 100%;
}

.node--type-station .node {
  margin-bottom: var(--margin-l);
}

.node--type-station .block-page-title-block {
  display: none;
}


/* ***** HERO SECTION ***** */

.station-hero {
  position: relative;
  width: 100vw;
  
  height: 100%;
  min-height: 500px;  
  overflow: hidden;
  margin-bottom: var(--margin-xl);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: flex-end;
}

.station-hero .cover-image {
  position: absolute;
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center;
  display: block;
  z-index: 3;

  margin: 0;
}

.station-hero .cover-image .field--type-image,
.station-hero .cover-image picture,
.station-hero .cover-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.station-hero::after {
  content: '';
  position: absolute;

  height: 50%;
  width: 100%;
  bottom: 0;

  background: linear-gradient(to top, var(--c-black-transparent-1) 0%, var(--c-black-transparent-2) 70%, transparent 100%);
  z-index: 5;
}

.station-hero .hero-content {
  position: relative ;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--margin-m) var(--margin-m);
  z-index: 7;

  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 0;
}

.station-hero .hero-content .title {
  color: var(--white);
  font-size: var(--fc-h1plus);
  font-weight: var(--fw-bold);
  margin: 0 0 var(--margin-s);
  text-shadow: 2px 2px 4px var(--c-black-transparent-1);
  background-color: var(--blue-base);
  margin: 0;
  padding: var(--margin-s) var(--margin-m);
}

.station-hero .hero-content .subtitle {
  color: var(--grey-light-2);
  font-size: var(--fc-h2);
  font-weight: var(--fw-normal);
  font-family: var(--ff-sans2);
  line-height: 1.1;
  text-wrap: balance;
  margin: 0;
  text-shadow: 1px 1px 2px var(--c-black-transparent-1);
  background-color: var(--blue-dark-1);
  padding: var(--margin-xs) var(--margin-m);
  
}

.station-hero .hero-content .chips {
  margin-top: var(--margin-l);
  

  &  > .field__items {
    display: flex;
    flex-wrap: wrap;
    gap: var(--margin-m);
  }
}

.station-hero .hero-content .chips .field__item {
  display: inline-flex;
  align-items: center;
  padding: var(--margin-xs) var(--margin-s);
  border-radius: 999px;
  background-color: var(--c-white-transparent-3);
  color: var(--white);
  font-size: var(--fs-small);
  font-weight: var(--fw-semibold);
  backdrop-filter: blur(6px);
  border: 1px solid var(--c-white-transparent-2);
}

@media all and (width <= 768px) {
  .station-hero {
  position: relative;
  width: 100vw;
  
  height: 100%;
  min-height: 300px;  
  overflow: hidden;
  margin-bottom: var(--margin-xl);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: flex-end;
}

  .station-hero .cover-image {
    position: absolute;
    width: 100%;
    height: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    object-position: center;
    display: block;
    z-index: 3;

    margin: 0;
  }

  .station-hero .hero-content .chips {
  margin-top: var(--margin-s);
  

  &  > .field__items {
    display: flex;
    flex-wrap: wrap;
    gap: var(--margin-xs);
    }
  }
}


/* ***** MAIN CONTENT: TWO COLUMN LAYOUT ***** */

.node--type-station .node-content {
  width: 100%;
  
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--margin-l);
  margin-bottom: var(--margin-xl);

  .body {
    flex: 1 1 66%;
  }
  .sidebar_first.sidebar {
    flex: 1 1 33.5%;
  }
}

@media all and (width < 900px) {
  .node--type-station .node-content {
    flex-direction: column;
  }

  .node--type-station .node-content .body,
  .node--type-station .node-content .sidebar_first.sidebar {
    flex: 1 1 100%;
  }
}

.block.station-details {

  .station-details__item {
    margin: 0 0 var(--margin-l) 0;
    padding: 0;
  }

  a {
    color: var(--blue-base);
    text-decoration: none;
    font-weight: var(--fw-semibold);

    &:hover {
      color: var(--blue-light-1);
    }
  }

  .field__label {
    font-size: var(--fs-small);
    font-weight: var(--fw-bold);
    margin-bottom: var(--margin-xs);
    display: block;
    color: var(--grey-dark-2);
    padding-top: var(--margin-s);
    border-top: 1px solid var(--grey-light-1);
    text-transform: uppercase;
  }

  .station-details__item .field__item {
    font-size: var(--fs-p);
    color: var(--black);
    line-height: 1.25;

    display: flex;
    flex-direction: row;
    align-items: flex-start;
    justify-content: flex-start;
  }

  .station-details__item .field__item::before {
    content: '';
    width: var(--fc-p2);
    height: var(--fc-p2);
    margin-right: var(--margin-s);
    margin-top: var(--margin-xxs);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center center;
    opacity: 0.6;
    position: relative;

  }

  .station-details__item.address .field__item::before {
    background-image: url('data:image/svg+xml,<%3Fxml version="1.0" encoding="utf-8"%3F><svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M5.36328 12.0523C4.01081 11.5711 3.33457 11.3304 3.13309 10.9655C2.95849 10.6492 2.95032 10.2673 3.11124 9.94388C3.29694 9.57063 3.96228 9.30132 5.29295 8.76272L17.8356 3.68594C19.1461 3.15547 19.8014 2.89024 20.2154 3.02623C20.5747 3.14427 20.8565 3.42608 20.9746 3.7854C21.1106 4.19937 20.8453 4.85465 20.3149 6.16521L15.2381 18.7078C14.6995 20.0385 14.4302 20.7039 14.0569 20.8896C13.7335 21.0505 13.3516 21.0423 13.0353 20.8677C12.6704 20.6662 12.4297 19.99 11.9485 18.6375L10.4751 14.4967C10.3815 14.2336 10.3347 14.102 10.2582 13.9922C10.1905 13.8948 10.106 13.8103 10.0086 13.7426C9.89876 13.6661 9.76719 13.6193 9.50407 13.5257L5.36328 12.0523Z" stroke="%231c58de" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>');
  }

  .station-details__item.telephone .field__item::before {
    background-image: url('data:image/svg+xml,<%3Fxml version="1.0" encoding="utf-8"%3F><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg height="800px" width="800px" version="1.1" id="_x32_" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 512 512" xml:space="preserve"><style type="text/css">.st0{fill:%231c58de;}</style><g><path class="st0" d="M94.811,21.696c-35.18,22.816-42.091,94.135-28.809,152.262c10.344,45.266,32.336,105.987,69.42,163.165c34.886,53.79,83.557,102.022,120.669,129.928c47.657,35.832,115.594,58.608,150.774,35.792c17.789-11.537,44.218-43.058,45.424-48.714c0,0-15.498-23.896-18.899-29.14l-51.972-80.135c-3.862-5.955-28.082-0.512-40.386,6.457c-16.597,9.404-31.882,34.636-31.882,34.636c-11.38,6.575-20.912,0.024-40.828-9.142c-24.477-11.262-51.997-46.254-73.9-77.947c-20.005-32.923-40.732-72.322-41.032-99.264c-0.247-21.922-2.341-33.296,8.304-41.006c0,0,29.272-3.666,44.627-14.984c11.381-8.392,26.228-28.286,22.366-34.242l-51.972-80.134c-3.401-5.244-18.899-29.14-18.899-29.14C152.159-1.117,112.6,10.159,94.811,21.696z"/></g></svg>');  
  }

    .station-details__item.whatsapp .field__item::before {
    background-image: url('data:image/svg+xml,<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>WhatsApp</title><path stroke="%231c58de" d="M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z"/></svg>');  
  }

  .station-details__item.email .field__item::before {
  background-image: url('data:image/svg+xml,<%3Fxml version="1.0" encoding="utf-8"%3F><svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M4 7.00005L10.2 11.65C11.2667 12.45 12.7333 12.45 13.8 11.65L20 7" stroke="%231c58de" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/><rect x="3" y="5" width="18" height="14" rx="2" stroke="%231c58de" stroke-width="2" stroke-linecap="round"/></svg>');  }

  .station-details__item.map-location .field__item::before {
  background-image: url('data:image/svg+xml,<%3Fxml version="1.0" encoding="utf-8"%3F><svg fill="%231c58de" width="800px" height="800px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M16.114-0.011c-6.559 0-12.114 5.587-12.114 12.204 0 6.93 6.439 14.017 10.77 18.998 0.017 0.020 0.717 0.797 1.579 0.797h0.076c0.863 0 1.558-0.777 1.575-0.797 4.064-4.672 10-12.377 10-18.998 0-6.618-4.333-12.204-11.886-12.204zM16.515 29.849c-0.035 0.035-0.086 0.074-0.131 0.107-0.046-0.032-0.096-0.072-0.133-0.107l-0.523-0.602c-4.106-4.71-9.729-11.161-9.729-17.055 0-5.532 4.632-10.205 10.114-10.205 6.829 0 9.886 5.125 9.886 10.205 0 4.474-3.192 10.416-9.485 17.657zM16.035 6.044c-3.313 0-6 2.686-6 6s2.687 6 6 6 6-2.687 6-6-2.686-6-6-6zM16.035 16.044c-2.206 0-4.046-1.838-4.046-4.044s1.794-4 4-4c2.207 0 4 1.794 4 4 0.001 2.206-1.747 4.044-3.954 4.044z"></path></svg>');  }
}

/*** RELATED ARTICLES VIEW *****/

.view-station-related-articles {

  .view-content ul {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--margin-m);
    list-style: none;
    margin-bottom: var(--margin-xl);

    li {
      border: 1px solid var(--grey-light-1);
      border-radius: var(--br-s);
      padding: var(--margin-m);
      box-shadow: 0 4px 20px rgba(5, 21, 46, 0.06);
      transition: transform 0.2s ease, box-shadow 0.2s ease;
      background-color: var(--white);

      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: flex-start;
      gap: var(--margin-s);

      &:hover {
        transform: translateY(-4px);
        box-shadow: 0 10px 30px rgba(5, 21, 46, 0.12);
      }

      .views-field-title {
        font-family: var(--ff-display1);
        font-size: var(--fc-h2);
        font-weight: var(--fw-bold);
        color: var(--blue-dark-1);
        line-height: 1;
        text-wrap: balance;


        a {
          color: var(--blue-base);
          text-decoration: none;
        }
      }

      .views-field-field-image {
        overflow: hidden;
        width: 100%;

        img, picture {
          aspect-ratio: 4 / 3;
          width: 100%;
          height: 100%;
          object-fit: cover;
          object-position: center;
          border-radius: var(--br-s);
        }
      }

      .views-field-body {
        font-size: var(--fc-small);
        color: var(--grey-dark-2);
      }
      
      .views-field-view-node {
        
        text-align: right;
        width: 100%;

        a {
          font-size: var(--fs-small2);
          color: var(--blue-base);
          text-decoration: none;
          font-weight: var(--fw-semibold);

          &:hover {
            text-decoration: underline;
          }

          &::after {
            content: ' →';
          }
        }
      }
    }
  }
}


/* ***** CAR GROUPS VIEW ***** */

.station-car-groups {
  max-width: 1200px;
  margin: var(--margin-xl) auto var(--margin-xxl);
  

  background-color: var(--white);
  border: 1px solid var(--grey-light-1);
  border-radius: var(--br-s);
  padding: var(--margin-l);
  box-shadow: 0 8px 30px var(--c-black-transparent-3);
}

.station-car-groups > .station-car-groups__header { 
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: var(--margin-xs);
  margin-bottom: var(--margin-l);
  
}

.station-car-groups > .station-car-groups__view {
  margin-top: var(--margin-m);
  
}

.station-car-groups__header,
.station-car-groups__view {
  padding: var(--margin-l);
}

.station-car-groups__header {
  display: flex;
  flex-direction: column;
  gap: var(--margin-xs);
  margin-bottom: var(--margin-m);
}

.station-car-groups__title {
  margin: 0;
  font-size: var(--fc-h2);
  color: var(--blue-light-1);
}

.station-car-groups__subtitle {
  margin: 0;
  color: var(--grey-dark-2);
  font-size: var(--fs-p2);
}


.station-car-groups__view {
  .view ul {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: var(--margin-l);
    list-style: none;
    margin: 0;
    padding: 0;

    li {
      display: flex;
      flex-direction: row;
      justify-content: flex-start;
      align-items: center;
      gap: var(--margin-m);

      border: 2px solid var(--grey-light-2);
      border-radius: var(--br-s);
      padding: var(--margin-m);

      transition: all 0.3s ease-in-out;

      .views-field-field-image {
        flex: 0 0 120px;

        img {
          width: 120px;
          height: 80px;
          object-fit: cover;
          border-radius: var(--br-s);
        }
      }

      &:hover {
        border-color: var(--blue-light-1);
        transform: scale(1.04);
        box-shadow: 0 10px 30px var(--c-black-transparent-3);
      }

      .views-field-fieldset > .field-content > div {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: flex-start;
        gap: var(--margin-xxs);

        .views-field-title {
          font-size: var(--fs-p2);
          font-weight: var(--fw-semibold);
          color: var(--blue-dark-1);
          line-height: 1;
        }

        .views-field-field-subtitle {
          font-size: var(--fs-small2);
          color: var(--blue-dark-2);
        }

      }
    }
  }
}





/* ***** PHOTO GALLERY ***** */

.station-gallery {
  margin-top: var(--margin-xl);
}


.field--name-field-photo-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--margin-s);

  &.field--type-image {
    width: 100%;
    height: 100%;
    overflow: hidden;
    aspect-ratio: auto;

  }

  .field__item {
    overflow: hidden;
    border-radius: var(--br-s);
    height: 100%;
  }


  img, picture , figure {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
  }


}
