/* BEFORE/AFTER PAGE STYLES */

/* --- Hero Section --- */
.ba-hero {
  background-color: var(--teal-background, #f7f9f6);
  padding: 120px 20px 60px;
  text-align: center;
  overflow: hidden;
  position: relative;
}

.ba-hero-container {
  max-width: 800px;
  margin: 0 auto;
}

.ba-eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--teal-primary, #a4b697);
  font-weight: 600;
  margin-bottom: 20px;
}

.ba-title {
  font-size: 3.5rem;
  line-height: 1.1;
  color: var(--text-dark, #2b2b2b);
  margin-bottom: 24px;
}

.ba-title span {
  color: var(--teal-dark, #6c805c);
  font-style: italic;
  font-family: serif;
}

.ba-desc {
  font-size: 1.1rem;
  color: #666;
  max-width: 600px;
  margin: 0 auto;
}

/* Animations */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Shared Container --- */
.ba-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* --- Featured Slider Section --- */
.ba-featured {
  padding: 60px 0 100px;
}

.ba-slider-container {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 30px 60px rgba(164, 182, 151, 0.2);
  aspect-ratio: 16 / 9;
  background-color: #eee;
}

.ba-img-before, .ba-img-after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.ba-img-before img, .ba-img-after img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.ba-img-after {
  clip-path: polygon(50% 0, 100% 0, 100% 100%, 50% 100%);
}

.ba-label {
  position: absolute;
  top: 20px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.8);
  backdrop-filter: blur(4px);
  color: var(--teal-dark, #6c805c);
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
  z-index: 10;
  pointer-events: none;
}

.label-before { left: 20px; }
.label-after { right: 20px; }

/* The Range Input */
.ba-slider {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  z-index: 20;
  cursor: ew-resize;
}

.ba-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 2px;
  height: 100%;
  background: transparent;
  cursor: ew-resize;
}

.ba-slider::-moz-range-thumb {
  width: 2px;
  height: 100%;
  background: transparent;
  cursor: ew-resize;
  border: none;
}

/* Custom Visual Handle */
.ba-slider-button {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background-color: #fff;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 15;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(0,0,0,0.2);
}

.ba-slider-button::after {
  content: '';
  position: absolute;
  width: 48px;
  height: 48px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  z-index: -1;
}

.ba-slider-button svg {
  width: 16px;
  height: 16px;
  margin: 0 2px;
  position: relative;
  z-index: 2;
}

.ba-featured-info {
  text-align: center;
  margin-top: 40px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.ba-featured-info h3 {
  font-size: 2rem;
  color: var(--teal-dark, #6c805c);
  margin-bottom: 16px;
}

.ba-featured-info p {
  color: #666;
  font-size: 1.05rem;
  line-height: 1.6;
}

/* --- Grid Section --- */
.ba-grid-section {
  background-color: #fff;
  padding: 80px 0;
}

.ba-section-title {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 60px;
  color: var(--text-dark, #2b2b2b);
}

.ba-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.ba-grid-item {
  border-radius: 20px;
  overflow: hidden;
  background: #f7f9f6;
  box-shadow: 0 15px 35px rgba(164, 182, 151, 0.1);
  transition: transform 0.4s ease;
}

.ba-grid-item:hover {
  transform: translateY(-10px);
}

.small-slider {
  border-radius: 0;
  box-shadow: none;
  max-width: 100%;
  aspect-ratio: 4 / 3;
}

.small-slider .ba-slider-button::after {
  width: 36px;
  height: 36px;
}
.small-slider .ba-slider-button svg {
  width: 12px;
  height: 12px;
}

.ba-grid-info {
  padding: 30px;
}

.ba-grid-info h4 {
  font-size: 1.3rem;
  color: var(--teal-dark, #6c805c);
  margin-bottom: 8px;
}

.ba-grid-info p {
  color: #666;
  font-size: 0.95rem;
  margin: 0;
}

/* --- CTA Section --- */
.ba-cta {
  background-color: var(--teal-primary, #a4b697);
  color: #fff;
  text-align: center;
  padding: 100px 20px;
  border-radius: 40px 40px 0 0;
}

.ba-cta h2 {
  font-size: 2.8rem;
  margin-bottom: 16px;
}

.ba-cta p {
  font-size: 1.1rem;
  margin-bottom: 40px;
  opacity: 0.9;
}

.ba-btn {
  display: inline-block;
  background-color: #fff;
  color: var(--teal-dark, #6c805c);
  padding: 16px 40px;
  border-radius: 30px;
  font-weight: 600;
  text-decoration: none;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.ba-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 15px 25px rgba(0,0,0,0.15);
}

/* Responsive */
@media (max-width: 768px) {
  .ba-title { font-size: 2.5rem; }
  .ba-hero { padding-top: 100px; }
  .ba-featured-info h3 { font-size: 1.6rem; }
  .ba-grid { grid-template-columns: 1fr; }
  .ba-cta h2 { font-size: 2rem; }
}

/* --- Card Styling --- */
.ba-grid-info-card {
  padding: 24px;
  background: #fff;
  text-align: left;
}

.ba-badge {
  display: inline-block;
  background-color: #d8ebd4;
  color: #1a534c;
  padding: 6px 14px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 14px;
}

.ba-card-title {
  font-size: 1.3rem;
  color: #1a2a3a;
  margin: 0 0 12px 0;
  font-weight: 700;
}

.ba-card-duration {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  color: #6a7482;
  margin-bottom: 16px;
}

.ba-card-duration svg {
  width: 18px;
  height: 18px;
  color: #6a7482;
}

.ba-card-desc {
  font-size: 1rem;
  color: #666;
  line-height: 1.5;
  margin: 0;
}

/* For Portrait Slider and Static Images */
.portrait-slider, .square-static {
  border-radius: 20px 20px 0 0;
  box-shadow: none;
  max-width: 100%;
  aspect-ratio: 1 / 1;
  position: relative;
  overflow: hidden;
  background-color: #eee;
}

.square-static img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.portrait-static {
  border-radius: 20px 20px 0 0;
  box-shadow: none;
  max-width: 100%;
  aspect-ratio: 4 / 5;
  position: relative;
  overflow: hidden;
  background-color: #eee;
}

.portrait-static img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
