/*──────────────────────────────────────────────────────────────────────────────
  EXISTING RULES for .section2, .container-section-left, etc.
──────────────────────────────────────────────────────────────────────────────*/
.section2 {
  background-color: #ffffff;
  height: max-content;
  width: 100vw;
  padding: 4vh 5vw;
  /* Reduced padding for smaller height */
  font-family: 'Sofia Pro', sans-serif;

  display: flex;
  /* Changed to flex for better centering/control */
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 5vw;

  overflow: hidden;
  box-sizing: border-box;
}

.container-section-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  /* Align text left */
  max-width: 600px;
}

.Mobile-sect2 {
  display: none;
  /* Hidden on desktop */
}

/* Typography Enhancements */
.desk-sect2-H1 {
  font-size: 5vh;
  /* Slightly smaller header */
  line-height: 1.1;
  color: #1b1b1b;
  text-align: left;
  padding: 0;
  margin: 0 0 1vh 0;
  font-weight: 800;
  /* Extra bold */
  letter-spacing: -0.02em;
  /* Tighten up display text */
}

.desk-sect2 p {
  font-size: 2vh;
  color: #666;
  margin-top: 1.5vh;
  font-weight: 500;
}

.image-container-section2 {
  width: 100%;
  margin-bottom: 2vh;
}

.image-section2-logo {
  margin-top: 0.5vh;
  width: 50%;
  /* Slightly smaller for balance */
  max-width: 250px;
  height: auto;
}

/* Social Buttons */
.socialmedia-buttons-container-sect3 {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  margin-top: 2vh;
  /* Reduced margin */
  list-style: none;
  gap: 3vh;
  padding: 0;
}

.socialmedia-buttons-container-sect3 li {
  display: flex;
  align-items: center;
  justify-content: center;
}

.socialmedia-buttons-container-sect3 a {
  display: block;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  /* Bouncy pop */
}

.header-icon-media-sect3 {
  width: 4vh;
  /* Slightly smaller icons */
  height: auto;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
  /* Subtle depth */
  transition: filter 0.3s ease;
}

.socialmedia-buttons-container-sect3 li:hover a {
  transform: translateY(-5px) scale(1.1);
}

.socialmedia-buttons-container-sect3 li:hover .header-icon-media-sect3 {
  filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.2));
  /* Deep shadow on hover */
}


/*──────────────────────────────────────────────────────────────────────────────
  Carousel Layout (Desktop)
──────────────────────────────────────────────────────────────────────────────*/
.instagram-media {
  flex: 1;
  /* Take remaining space */
  width: 100%;
  max-width: 550px;
  /* Increased back for bigger animation */
  aspect-ratio: 1 / 1;
  display: flex;
  justify-content: center;
  align-items: center;
  /* Add a subtle float animation to the whole carousel container for life */
  animation: float 6s ease-in-out infinite;
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

#carousel-container {
  width: 100%;
  height: 100%;
  position: relative;
  perspective: 1000px;
  /* Fixed robust perspective */
  perspective-origin: 50% 50%;
  cursor: grab;
  touch-action: none;
}

#carousel-container:active {
  cursor: grabbing;
}

#carousel {
  width: 100%;
  height: 100%;
  position: absolute;
  transform-style: preserve-3d;
  transform-origin: 50% 50%;
  /* Will be controlled by JS */
}

.carousel__cell {
  position: absolute;
  width: 45%;
  /* Bigger cells (was 30%) */
  height: 45%;
  left: 50%;
  top: 50%;
  overflow: hidden;
  border-radius: 12px;
  /* Modern rounding */
  transform-origin: 50% 50%;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  /* Nice shadow for 3D depth */
  background: #000;
  /* Fallback */
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: box-shadow 0.3s ease;
}

.carousel__cell:hover {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
  border-color: rgba(255, 255, 255, 0.3);
}

.carousel__cell img,
.carousel__cell video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  display: block;
}


/*──────────────────────────────────────────────────────────────────────────────
  Responsive
──────────────────────────────────────────────────────────────────────────────*/

/* Tablet (1024px and below) */
@media screen and (max-width: 1024px) {
  .section2 {
    flex-direction: column;
    text-align: center;
    padding: 5vh 5vw;
    gap: 5vh;
    height: auto;
  }

  .container-section-left {
    align-items: center;
    max-width: 100%;
  }

  .desk-sect2-H1 {
    text-align: center;
    font-size: 5vh;
  }

  .socialmedia-buttons-container-sect3 {
    justify-content: center;
  }

  .instagram-media {
    max-width: 50vh;
    /* Relative to viewport height on mobile/tablet */
  }

  /* Reveal mobile-specific text classes if used, or just style the desk ones to work everywhere */
  .desk-sect2 {
    display: block;
  }
}

/* Mobile (small) */
@media screen and (max-width: 600px) {
  .desk-sect2-H1 {
    font-size: 4vh;
  }

  .instagram-media {
    width: 90vw;
    max-width: 90vw;
    aspect-ratio: 1/1;
  }

  .carousel__cell {
    width: 35%;
    /* Larger cells on mobile relative to container */
    height: 35%;
  }

  .header-icon-media-sect3 {
    width: 4vh;
  }
}