/**
 * YognikShala — 3D Booklet Programs Carousel Styles
 * Location: /yoga1/css/booklet_programs.css
 * Time Zone: Indian Standard Time (Asia/Kolkata +05:30)
 */

.booklet-programs-section {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 0 25px 0;
  user-select: none;
  overflow: hidden;
}

.booklet-container {
  position: relative;
  width: 100%;
  min-height: 490px;
  perspective: 1200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 16px 0 10px 0;
}

.booklet-track {
  position: relative;
  width: 100%;
  height: 470px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform-style: preserve-3d;
}

/* Individual Booklet Card */
.booklet-card {
  position: absolute;
  width: 350px;
  max-width: 82vw;
  background: #ffffff;
  border-radius: 26px;
  padding: 24px 20px;
  border: 1.5px solid rgba(201, 147, 47, 0.3);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.07);
  transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1), 
              opacity 0.6s ease, 
              box-shadow 0.6s ease, 
              border-color 0.6s ease,
              background-color 0.6s ease;
  cursor: pointer;
  will-change: transform, opacity;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-sizing: border-box;
  overflow: hidden;
}

/* 3D CENTER FOCUS CARD */
.booklet-card.booklet-center {
  z-index: 30;
  transform: translate3d(0, 0, 50px) scale(1.05);
  opacity: 1;
  border: 2.5px solid #e8721e;
  box-shadow: 0 22px 48px -8px rgba(232, 114, 30, 0.38), 
              0 0 22px rgba(232, 114, 30, 0.16);
  background: linear-gradient(180deg, #fffdfa 0%, #fffbf2 100%);
  cursor: default;
}

.booklet-card.booklet-center h3,
.booklet-card.booklet-center h4 {
  font-weight: 900 !important;
  color: #2b1b12 !important;
}

/* LEFT VISIBLE BOOKLET CARD - FULLY VIEWABLE TABBED FORMAT */
.booklet-card.booklet-left {
  z-index: 25;
  transform: translate3d(-365px, 0, 0px) scale(0.93) rotateY(6deg);
  opacity: 0.95;
  filter: none;
  border-color: rgba(201, 147, 47, 0.45);
  box-shadow: -10px 14px 30px rgba(0, 0, 0, 0.09);
  background: #ffffff;
}

.booklet-card.booklet-left:hover {
  opacity: 1;
  transform: translate3d(-370px, 0, 10px) scale(0.96) rotateY(2deg);
  border-color: #e8721e;
}

/* RIGHT VISIBLE BOOKLET CARD - FULLY VIEWABLE TABBED FORMAT */
.booklet-card.booklet-right {
  z-index: 25;
  transform: translate3d(365px, 0, 0px) scale(0.93) rotateY(-6deg);
  opacity: 0.95;
  filter: none;
  border-color: rgba(201, 147, 47, 0.45);
  box-shadow: 10px 14px 30px rgba(0, 0, 0, 0.09);
  background: #ffffff;
}

.booklet-card.booklet-right:hover {
  opacity: 1;
  transform: translate3d(370px, 0, 10px) scale(0.96) rotateY(-2deg);
  border-color: #e8721e;
}

/* HIDDEN CARDS OUTSIDE 3-CARD VIEW */
.booklet-card.booklet-hidden-left {
  z-index: 10;
  transform: translate3d(-750px, 0, -100px) scale(0.7) rotateY(20deg);
  opacity: 0;
  pointer-events: none;
}

.booklet-card.booklet-hidden-right {
  z-index: 10;
  transform: translate3d(750px, 0, -100px) scale(0.7) rotateY(-20deg);
  opacity: 0;
  pointer-events: none;
}

/* ARROW BUTTONS */
.booklet-arrow-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 40;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #ffffff;
  color: #2b1b12;
  border: 1.5px solid rgba(201, 147, 47, 0.4);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  outline: none;
}

.booklet-arrow-btn:hover {
  background: #e8721e;
  color: #ffffff;
  border-color: #e8721e;
  transform: translateY(-50%) scale(1.12);
  box-shadow: 0 10px 25px rgba(232, 114, 30, 0.45);
}

.booklet-arrow-btn:active {
  transform: translateY(-50%) scale(0.95);
}

.booklet-arrow-prev {
  left: 10px;
}

.booklet-arrow-next {
  right: 10px;
}

/* DOTS / INDICATORS */
.booklet-nav-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
}

.booklet-dot-item {
  width: 12px;
  height: 12px;
  border-radius: 20px;
  background: #cbd5e1;
  cursor: pointer;
  transition: all 0.4s ease;
  border: none;
  padding: 0;
}

.booklet-dot-item.active {
  width: 32px;
  background: #e8721e;
  box-shadow: 0 3px 8px rgba(232, 114, 30, 0.4);
}

/* AUTO TRANSITION TIMER PROGRESS BAR */
.booklet-timer-bar {
  width: 160px;
  height: 4px;
  background: rgba(203, 213, 225, 0.4);
  border-radius: 4px;
  margin: 12px auto 0 auto;
  overflow: hidden;
  position: relative;
}

.booklet-timer-progress {
  height: 100%;
  background: #e8721e;
  width: 0%;
  transition: width 0.1s linear;
}

/* Responsive adjustments */
@media (max-width: 1150px) {
  .booklet-card {
    width: 310px;
  }
  .booklet-card.booklet-left {
    transform: translate3d(-320px, 0, 0px) scale(0.92) rotateY(5deg);
  }
  .booklet-card.booklet-right {
    transform: translate3d(320px, 0, 0px) scale(0.92) rotateY(-5deg);
  }
}

@media (max-width: 900px) {
  .booklet-card {
    width: 270px;
    padding: 20px 16px;
  }
  .booklet-card.booklet-left {
    transform: translate3d(-275px, 0, 0px) scale(0.9) rotateY(4deg);
  }
  .booklet-card.booklet-right {
    transform: translate3d(275px, 0, 0px) scale(0.9) rotateY(-4deg);
  }
}

@media (max-width: 640px) {
  .booklet-card {
    width: 250px;
    padding: 18px 14px;
  }
  .booklet-card.booklet-left {
    transform: translate3d(-230px, 0, 0px) scale(0.86) rotateY(3deg);
    opacity: 0.75;
  }
  .booklet-card.booklet-right {
    transform: translate3d(230px, 0, 0px) scale(0.86) rotateY(-3deg);
    opacity: 0.75;
  }
  .booklet-arrow-prev {
    left: 2px;
  }
  .booklet-arrow-next {
    right: 2px;
  }
}
