/* =========================================
   1. DESKTOP MARGINS & BASE STYLES
   ========================================= */

/* ── Grass separator between S2 and S5 ── */
.s-grass-separator {
  width: 100%;
  display: block;
  line-height: 0;
  background: #00340000;
  z-index: 11;
  position: relative;
  margin-top:13%;
}
.s-grass-separator img {
  width: 100%;
  display: block;
  object-fit: cover;
  object-position: top;
  height:200px;
  /* display: none; */
}

/* ── S5: now uses normal document flow ── */
.s5 {
  background: #003400;
  width: 100%;
  /* padding-bottom: 20px; */
}

.s5-flow {
  display: flex;
  justify-content: center;
  /* padding-top: 40px; */
  padding-bottom: 10px;
  background-color: #06410a;
  margin-top:0;
}

.s5aboutus {
  position: relative;
  width: 14%;
  /* min-width: 220px; */
  z-index: 10;
  margin-top:-60%;
    min-width: 150px;
    height: 50px;
}

.s5-footer-container {
  position: relative;
  left: auto;
  transform: none;
  z-index: 60;
  width: 100%;
  color: white;
  font-family: sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 0;
  padding-top: 0;
  background-color: #06410a;
}

/* --- Card & Carousel Internal Styles --- */
.card-stack {
  position: relative;
  width: 100%; 
  max-width: var(--stack-width);
  height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card {
  position: absolute;
  width: var(--card-width);
  height: var(--card-height);
  background: var(--card-white);
  border-radius: 24px;
  transition: all 0.4s ease-in-out;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  opacity: 0;
  z-index: 0;
  transform: scale(0.8);
}

.card.active {
  opacity: 1;
  z-index: 10;
  transform: translateX(0) scale(1.2);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

.card.prev {
  opacity: 1;
  z-index: 5;
  transform: translateX(calc(var(--translate-offset) * -1)) scale(0.9);
}

.card.next {
  opacity: 1;
  z-index: 5;
  transform: translateX(var(--translate-offset)) scale(0.9);
}

.nav-btn {
  background: var(--btn-color);
  border: none;
  border-radius: 50%;
  width: var(--btn-size);
  height: var(--btn-size);
  cursor: pointer;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 10px; 
  transition: transform 0.2s;
  flex-shrink: 0; 
}

.nav-btn:hover {
  transform: scale(1.1);
}

.nav-btn svg {
  width: 50%;
  height: 50%;
  stroke: #003300;
}

/* --- Footer Grid & Layout --- */
.s5-footer-grid {
  display: grid;
  gap: 6px;
  width: 100%;
  max-width: 480px;
  margin: 40px auto 10px;
}

.s5-grid-box {
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  position: relative;
  cursor: pointer;
}

.s5-grid-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 20px;
  margin-left: 2%;
  margin-top:-15%;
}

.s5-full {
  aspect-ratio: 16/9;
}

.s5-thumbs-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-top: -4%;
}

.s5-des-text{
  position: absolute;
  width: 57%;
  z-index: 9;
  left: 50%;
  margin-top: 28.5%;              
  transform: translate(-50%, -50%);

  font-family: "Bebas Neue", sans-serif;
  font-weight: 500;
  font-style: normal;

  font-size: clamp(0.9rem, 3.5vw, 1.4rem);
  line-height: 1.1;
  text-align: center;
  color: white;
}

.s5-footer-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding-top: 6%;
}

.s5-socials {
  display: flex;
  gap: 20px;
  margin-bottom: 5px;
  /* margin-top:100px; */
}

.s5-socials svg {
  width: 24px;
  height: 24px;
  stroke: white;
}

.s5-legal-links, .s5-legal-links a {
  font-size: 11px;
  text-decoration: none;
  color: white;
  font-weight: bold;
  letter-spacing: 1px;
}

.s5-disclaimer, .s5-copyright {
  font-size: 10px;
  margin: 0;
  letter-spacing: 0.5px;
}

.s5-footer-logo {
  margin-bottom: 0;
  margin-top: 15px;
  font-weight: 900;
  font-style: italic;
  font-size: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.s5-footer-logo img{
    max-width: 240px;
    width: 100%;
    height: auto;
}

.s5-pill { 
  font-style: normal; 
}

.play-icon {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 48px;
  color: white;
  background: rgba(0,0,0,0.35);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.s5-grid-box:hover .play-icon {
  opacity: 1;
}

.video-modal {
  /* position: fixed; */
  inset: 0;
  background: rgba(0,0,0,0.85);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.video-modal.active {
  display: flex;
}

.video-modal-content {
  width: 90%;
  max-width: 900px;
  aspect-ratio: 16 / 9;
  position: relative;
}

.video-modal iframe {
  width: 100%;
  height: 100%;
}

.video-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  font-size: 32px;
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
}


/* =========================================
   2. SMARTPHONE MARGINS & OVERRIDES
   ========================================= */

@media (max-width: 768px) {
  .s-grass-separator {
    margin-top: 44%;
  }

  .s5 {
    margin-top: -40%;
    padding-bottom: 0;
  }
  .s-grass-separator img{
    height:400px;
    /* display: none; */
  }
  
  /* --- S5 mobile: flow layout, no huge margins needed --- */
  .s5-flow {
    padding-top: 34%;
    background-color: transparent;
    margin-top:-10px;
  }
  .s5aboutus {
    width: 35%;
    min-width: 100px;
    height:30px;
    margin-top: -125%
  }
  .s5-footer-container {
    margin-top: -66%;
    padding-top: 0;
    background-color: #0b440a;
  }

  /* --- Other Mobile Adjustments --- */
  .card.active {
    transform: translateX(0) scale(1.15);
  }

  .s5-footer-grid {
    gap: 6px;
    justify-items: center;
    max-width: 100%;
  }

  .s5-thumbs-row {
    grid-template-columns: 1fr; 
    justify-items: center;
  }
}

/* Extra breakpoint for very small phones */
@media (max-width: 600px) {
  .s5-footer-grid {
    grid-template-columns: 1fr; 
  }
  
  .s5-grid-box.s5-full {
    grid-column: span 1;
    height: 200px;
  }

  .s5-grid-box {
    height: 150px;
  }
}

@media only screen and (max-width: 768px){
  .s5-footer-content{
    padding-top: 24%;
  }
}

.s5-mobile-view {
  display: none;
}

@media (max-width: 768px) {
  .s5-desktop-view {
    display: none !important;
  }

  .s5-mobile-view {
    display: block !important;
    width: 100%;
    margin: 0 auto 16px;
  }

  .s5-footer-grid {
    display: block !important;
    width: 100% !important;
    max-width: 100%;
  }

  .s5-mobile-slider-wrap {
    position: relative;
    width: 100%;
  }

  .s5-mobile-slider {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 5px;
    width: 100%;
    box-sizing: border-box;
    /* padding: 0 5%; */
    padding-left:8%;
    margin-top:-30%;
  padding-right:5%;
  }

  .s5-mobile-slider::-webkit-scrollbar {
    display: none;
  }

  .s5-mobile-slider {
    scrollbar-width: none;
  }

  .s5-mobile-slider .s5-grid-box {
    flex: 0 0 90% !important;
    min-width: 90% !important;
    max-width: 90% !important;
    scroll-snap-align: center;
    display: block !important;
    margin: 0 auto;
  }

  .s5-mobile-slider .s5-grid-box img {
    width: 90% !important;
    height: auto !important;
    display: block;
    border-radius: 12px;
    margin-top:0;
  }

  .s5-slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 18px;
    line-height: 34px;
    text-align: center;
    cursor: pointer;
    padding: 0;
  }

  .s5-slider-prev {
    left: 8px;
  }

  .s5-slider-next {
    right: 8px;
  }

  .s5-thumbs-row {
    display: none !important;
  }

  .s5-des-text {
    margin-top: 72%;
    text-align: center;
    width: 70%;
  }

}
html.video-popup-open,
body.video-popup-open {
  overflow: hidden;
  height: 100%;
}