/* Reset and Base Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary-red: #dd3d3a;
  --primary-blue: #244193;
  --light-blue: #eef2fa;
  --dark-text: #333333;
  --light-text: #666666;
  --white: #ffffff;
  --off-white: #f9f9f9;
  --light-gray: #f5f5f5;
  --medium-gray: #e0e0e0;
  --dark-gray: #888888;
  --box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  --transition: all 0.3s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--dark-text);
  background-color: var(--white);
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Playfair Display", serif;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 1rem;
  color: var(--dark-text);
}

h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}

h4 {
  font-size: clamp(1.2rem, 2.5vw, 1.8rem);
}

p {
  margin-bottom: 1.5rem;
  color: var(--light-text);
}

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

a:hover {
  color: var(--primary-red);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* --- IMPROVEMENT: Add clear focus styles for keyboard navigation --- */
:focus-visible {
  outline: 2px solid var(--primary-blue);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px var(--light-blue);
}
/* Ensure specific elements like modals don't get outlines */
.modal:focus-visible,
.popup-banner:focus-visible {
  outline: none;
  box-shadow: none;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 80px 0;
}

@media (max-width: 768px) {
  .section {
    padding: 60px 0;
  }
}

.section-title {
  text-align: center;
  margin-bottom: 50px;
  position: relative;
}

.section-title::after {
  content: "";
  display: block;
  width: 80px;
  height: 3px;
  background: linear-gradient(
    to right,
    var(--primary-red),
    var(--primary-blue)
  );
  margin: 15px auto 0;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-red), var(--primary-blue));
  color: var(--white);
  box-shadow: 0 4px 15px rgba(221, 61, 58, 0.2);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(221, 61, 58, 0.3);
  color: var(--white);
}

.btn-secondary {
  background-color: var(--white);
  color: var(--primary-blue);
  border: 1px solid var(--primary-blue);
}

.btn-secondary:hover {
  background-color: var(--light-blue);
  color: var(--primary-blue);
  transform: translateY(-3px);
}

.btn-tertiary {
  background-color: transparent;
  color: var(--primary-blue);
  padding: 8px 0;
  position: relative;
}

.btn-tertiary::after {
  content: "→";
  margin-left: 5px;
  transition: var(--transition);
}

.btn-tertiary:hover {
  color: var(--primary-red);
}

.btn-tertiary:hover::after {
  margin-left: 10px;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 15px 0;
  transition: var(--transition);
  background-color: transparent;
}

.header.scrolled {
  background-color: var(--white);
  box-shadow: var(--box-shadow);
  padding: 10px 0;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  z-index: 1001;
}

.logo img {
  height: 45px;
  transition: var(--transition);
}

.header.scrolled .logo img {
  height: 40px;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
  padding: 5px; /* Added padding for easier clicking */
}

.nav-toggle span {
  display: block;
  width: 30px;
  height: 3px;
  margin: 6px 0;
  background-color: var(--dark-text);
  transition: var(--transition);
}

.nav-menu {
  display: flex;
  list-style: none;
}

.nav-link {
  margin: 0 15px;
  font-weight: 500;
  color: var(--dark-text);
  transition: var(--transition);
  position: relative;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(
    to right,
    var(--primary-red),
    var(--primary-blue)
  );
  transition: var(--transition);
}

.nav-link:hover::after {
  width: 100%;
}

.header-cta {
  margin-left: 20px;
}

@media (max-width: 1023px) {
  .nav-toggle {
    display: block;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 400px;
    height: 100vh;
    background-color: var(--white);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 50px 20px;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
    visibility: hidden; /* Hide when inactive */
  }

  .nav-menu.active {
    right: 0;
    visibility: visible; /* Show when active */
  }

  .nav-item {
    margin: 15px 0;
  }

  /* --- IMPROVEMENT: Ensure toggle animation centers correctly --- */
  .nav-toggle.active span:nth-child(1) {
    transform: translate(0, 9px) rotate(45deg);
  }

  .nav-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle.active span:nth-child(3) {
    transform: translate(0, -9px) rotate(-45deg);
  }

  .header-cta {
    display: none;
  }
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  color: var(--white);
  overflow: hidden;
}

.hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: -1;
}

.hero-content {
  max-width: 700px;
  padding: 0 20px;
  animation: fadeIn 1.5s ease;
}

.hero-title {
  color: var(--white);
  margin-bottom: 20px;
  line-height: 1.2;
}

.hero-subtitle {
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  margin-bottom: 15px;
  color: var(--white);
  font-weight: 500;
}

.hero-description {
  font-size: 18px;
  margin-bottom: 30px;
  color: rgba(255, 255, 255, 0.9);
}

.hero-cta {
  display: flex;
  gap: 15px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Transformation Stories Section */
.transformation {
  background-color: var(--off-white);
}

.transformation-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
}

@media (max-width: 1023px) {
  .transformation-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 767px) {
  .transformation-grid {
    grid-template-columns: 1fr;
  }
}

.transformation-card {
  background-color: var(--white);
  border-radius: 8px;
  padding: 30px;
  text-align: center;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  opacity: 0;
  transform: translateY(30px);
}

.transformation-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.transformation-card:hover {
  transform: translateY(-10px);
}

.transformation-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--light-blue);
  border-radius: 50%;
  color: var(--primary-blue);
  font-size: 24px;
}

.transformation-title {
  font-size: 20px;
  margin-bottom: 15px;
}

.transformation-description {
  font-size: 15px;
  color: var(--light-text);
}

/* Core Offerings Section */
.offerings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

@media (max-width: 1023px) {
  .offerings-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 767px) {
  .offerings-grid {
    grid-template-columns: 1fr;
  }
}

.offering-card {
  background-color: var(--white);
  border-radius: 8px;
  padding: 30px;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.offering-card:hover {
  transform: translateY(-10px);
}

.offering-card.premium {
  border: 2px solid var(--primary-red);
  position: relative;
}

.premium-label {
  position: absolute;
  top: -12px;
  right: 20px;
  background: linear-gradient(135deg, var(--primary-red), var(--primary-blue));
  color: var(--white);
  padding: 5px 15px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
}

.offering-icon {
  color: var(--primary-blue);
  font-size: 32px;
  margin-bottom: 20px;
}

.offering-title {
  font-size: 22px;
  margin-bottom: 15px;
}

.offering-description {
  font-size: 15px;
  color: var(--light-text);
  margin-bottom: 20px;
  flex-grow: 1;
}

.offering-price {
  margin-top: auto;
  margin-bottom: 15px;
  font-weight: 600;
  font-size: 18px;
}

.offering-price .original-price {
  text-decoration: line-through;
  color: var(--dark-gray);
  font-size: 16px;
  margin-left: 5px;
}

.offering-link {
  display: inline-flex;
  align-items: center;
  color: var(--primary-blue);
  font-weight: 500;
}

.offering-link i {
  transition: var(--transition);
  margin-left: 5px;
}

.offering-link:hover i {
  transform: translateX(5px);
}

/* About Section */
.about {
  background-color: var(--light-blue);
  position: relative;
  overflow: hidden;
}

.about-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}

@media (max-width: 767px) {
  .about-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

.about-mission h3,
.about-vision h3 {
  margin-bottom: 20px;
}

.about-vision {
  position: relative;
}

.mountain-outline {
  position: absolute;
  bottom: -50px;
  right: -50px;
  width: 300px;
  height: 150px;
  opacity: 0.1;
  z-index: -1;
}

/* Testimonials Section */
/* --- IMPROVEMENT: Add role=tablist for accessibility --- */
.testimonials-tabs {
  display: flex;
  justify-content: center;
  margin-bottom: 40px;
  border-radius: 4px; /* Add radius to container */
  overflow: hidden; /* Clip corners */
}

.testimonials-tab {
  padding: 10px 25px;
  background-color: var(--light-gray);
  color: var(--light-text);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
  flex-grow: 1; /* Make tabs fill space */
  text-align: center;
}

/* Removed individual border-radius */
/* .testimonials-tab:first-child {
        border-radius: 4px 0 0 4px;
      }

      .testimonials-tab:last-child {
        border-radius: 0 4px 4px 0;
      } */

.testimonials-tab.active {
  background-color: var(--primary-blue);
  color: var(--white);
}

.testimonials-content {
  position: relative;
  overflow: hidden;
}

.testimonials-panel {
  display: none;
}

.testimonials-panel.active {
  display: block;
}

.testimonials-carousel {
  display: flex;
  transition: var(--transition);
}

.testimonial-card {
  flex: 0 0 100%;
  max-width: 100%;
  padding: 0 15px;
  transition: var(--transition);
}

@media (min-width: 768px) {
  .testimonial-card {
    flex: 0 0 50%;
    max-width: 50%;
  }
}

@media (min-width: 1024px) {
  .testimonial-card {
    flex: 0 0 33.333%;
    max-width: 33.333%;
  }
}

.testimonial-inner {
  background-color: var(--white);
  border-radius: 8px;
  padding: 30px;
  box-shadow: var(--box-shadow);
  height: 100%;
}

.testimonial-header {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.testimonial-image {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 15px;
}

.testimonial-info h4 {
  margin-bottom: 5px;
  font-size: 18px;
}

.testimonial-info p {
  margin-bottom: 0;
  font-size: 14px;
  color: var(--dark-gray);
}

.testimonial-rating {
  color: #ffd700;
  margin-bottom: 15px;
}

.testimonial-content {
  font-style: italic;
  color: var(--light-text);
}

.testimonial-video {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  padding-top: 56.25%;
  cursor: pointer;
}

.testimonial-video img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.testimonial-video::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.testimonial-video::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-40%, -50%);
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 15px solid var(--primary-red);
  z-index: 1;
  transition: var(--transition);
}

.testimonial-video:hover::after {
  background-color: rgba(255, 255, 255, 0.9);
  transform: translate(-50%, -50%) scale(1.1);
}

.testimonials-controls {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

/* --- IMPROVEMENT: Add role=tablist for accessibility --- */
.testimonials-dots {
  display: flex;
  gap: 8px;
}

.testimonials-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--medium-gray);
  cursor: pointer;
  transition: var(--transition);
  border: none; /* Ensure it's treated as a button */
  padding: 0; /* Remove default padding */
}

.testimonials-dot.active {
  background-color: var(--primary-blue);
}

/* Courses Section */
.courses {
  background-color: var(--off-white);
}

.courses-carousel {
  position: relative;
  padding: 0 50px; /* Space for arrows */
  overflow: hidden; /* Recommend library for better UX */
}

.course-card {
  background-color: var(--white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--box-shadow);
  height: 100%;
  margin: 15px;
  flex-shrink: 0; /* Needed for basic carousel */
  width: calc(33.333% - 30px); /* Example width, adjust as needed */
  display: none; /* Hide by default, JS will show */
}

/* Example for a very basic carousel display */
.course-card.visible {
  display: block;
}

@media (max-width: 1023px) {
  .course-card {
    width: calc(50% - 30px);
  }
}
@media (max-width: 767px) {
  .course-card {
    width: calc(100% - 30px);
  }
}

/* --- IMPROVEMENT: Wrapper for actual sliding content (needed for library) --- */
.courses-carousel-wrapper {
  display: flex; /* Use flex for basic alignment if not using library */
  transition: transform 0.5s ease; /* Basic transition */
}

.course-image {
  height: 200px;
  background-size: cover;
  background-position: center;
}

.course-content {
  padding: 25px;
}

.course-title {
  font-size: 22px;
  margin-bottom: 10px;
}

.course-details {
  font-size: 14px;
  color: var(--dark-gray);
  margin-bottom: 15px;
}

.course-status {
  display: inline-block;
  padding: 5px 10px;
  background-color: var(--primary-red);
  color: var(--white);
  font-size: 12px;
  font-weight: 500;
  border-radius: 4px;
  margin-bottom: 15px;
}

.course-price {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--primary-blue);
}

.course-price .original-price {
  text-decoration: line-through;
  color: var(--dark-gray);
  font-size: 16px;
  margin-left: 5px;
}

.course-cta {
  width: 100%;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background-color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--box-shadow);
  cursor: pointer;
  z-index: 1;
  transition: var(--transition);
  border: none; /* Make it a button */
  padding: 0;
}

.carousel-arrow:hover {
  background-color: var(--primary-blue);
  color: var(--white);
}

.carousel-prev {
  left: 0;
}

.carousel-next {
  right: 0;
}

/* Founder Section */
.founder {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.founder-pattern {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("https://via.placeholder.com/1920x1080");
  background-size: cover;
  opacity: 0.05;
  z-index: -1;
}

.founder-container {
  display: grid;
  grid-template-columns: 60% 40%;
  gap: 50px;
  align-items: center;
}

@media (max-width: 1023px) {
  .founder-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

.founder-content h2 {
  margin-bottom: 30px;
}

.founder-signature {
  display: flex;
  align-items: center;
  margin-top: 30px;
}

.founder-signature img {
  height: 60px;
  margin-right: 20px;
}

.founder-name {
  font-weight: 600;
}

.founder-title {
  font-size: 14px;
  color: var(--dark-gray);
}

.founder-media {
  display: grid;
  grid-template-rows: auto auto;
  gap: 20px;
}

.founder-photo {
  border-radius: 8px;
  overflow: hidden;
}

.founder-video {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  padding-top: 56.25%;
  cursor: pointer;
}

.founder-video img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.founder-video::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.founder-video::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-40%, -50%);
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 15px solid var(--primary-red);
  z-index: 1;
  transition: var(--transition);
}

.founder-video:hover::after {
  background-color: rgba(255, 255, 255, 0.9);
  transform: translate(-50%, -50%) scale(1.1);
}

/* Book Section */
.book {
  background-color: var(--light-blue);
}

.book-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}

@media (max-width: 767px) {
  .book-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

.book-image {
  text-align: center;
}

.book-image img {
  max-width: 300px;
  margin: 0 auto;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.book-content h2 {
  margin-bottom: 15px;
}

.book-author {
  font-size: 18px;
  margin-bottom: 20px;
  color: var(--primary-blue);
}

.book-credentials {
  margin-bottom: 20px;
  font-style: italic;
  color: var(--light-text);
}

.featured-logos {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
}

.featured-logos img {
  height: 30px;
  opacity: 0.7;
  transition: var(--transition);
}

.featured-logos img:hover {
  opacity: 1;
}

/* Events Section with Images */
.events-container {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 30px;
}

@media (max-width: 767px) {
  .events-container {
    grid-template-columns: 1fr;
  }
}

.events-list {
  list-style: none;
}

.event-item {
  background-color: var(--white);
  border-radius: 8px;
  margin-bottom: 20px;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

@media (min-width: 768px) {
  .event-item {
    flex-direction: row;
  }
}

.event-item:hover {
  transform: translateY(-5px);
}

.event-image {
  flex: 0 0 40%;
  position: relative;
  overflow: hidden;
}

@media (max-width: 767px) {
  .event-image {
    height: 200px;
  }
}

.event-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.event-item:hover .event-image img {
  transform: scale(1.05);
}

.event-content {
  padding: 25px;
  flex: 1;
}

.event-date {
  display: inline-block;
  padding: 5px 10px;
  background-color: var(--light-blue);
  color: var(--primary-blue);
  border-radius: 4px;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 10px;
}

.event-title {
  font-size: 20px;
  margin-bottom: 10px;
}

.event-description {
  margin-bottom: 15px;
  font-size: 15px;
}

.featured-retreat {
  background-color: var(--white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--box-shadow);
  height: 100%;
}

.retreat-image {
  height: 200px;
  overflow: hidden;
}

.retreat-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.featured-retreat:hover .retreat-image img {
  transform: scale(1.05);
}

.retreat-content {
  padding: 25px;
}

/* FAQ Section */
.faq-container {
  max-width: 800px;
  margin: 0 auto;
}

.accordion {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--box-shadow);
  border: 1px solid var(--medium-gray); /* Add border for structure */
}

/* --- IMPROVEMENT: Make header a button for accessibility --- */
.accordion-header {
  padding: 20px;
  background-color: var(--white);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: var(--transition);
  width: 100%; /* Ensure it takes full width */
  border: none; /* Remove default button border */
  text-align: left; /* Align text left */
  font-family: inherit; /* Inherit font */
  font-size: 15px; /* Match original title style */
  font-weight: 400; /* Match original title style */
}

.accordion-header:hover {
  background-color: var(--light-blue);
}

.accordion-title {
  margin: 0; /* Remove margin from h3 inside button */
  /* flex-grow: 1; Allow title to take space */
  padding-right: 15px; /* Space before icon */
  color: var(--dark-text); /* Ensure color is correct */
}

.accordion-icon {
  font-size: 16px;
  transition: var(--transition);
  flex-shrink: 0; /* Prevent icon from shrinking */
}

.accordion.active .accordion-icon {
  transform: rotate(45deg);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  background-color: var(--white);
  transition: max-height 0.4s ease-out; /* Refined transition */
  visibility: hidden; /* Hide content when collapsed */
}

.accordion.active .accordion-content {
  max-height: 500px; /* Adjust if needed */
  visibility: visible;
  transition: max-height 0.5s ease-in;
}

.accordion-body {
  padding: 0 20px 20px;
  border-top: 1px solid var(--light-gray); /* Separator */
}

.faq-more {
  text-align: center;
  margin-top: 30px;
}

/* Newsletter Section */
.newsletter {
  background-color: var(--light-blue);
  padding: 60px 0;
}

.newsletter-container {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.newsletter-title {
  margin-bottom: 15px;
}

.newsletter-description {
  margin-bottom: 30px;
}

.newsletter-form {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}

@media (max-width: 767px) {
  .newsletter-form {
    flex-direction: column;
  }
}

.newsletter-input {
  flex: 1;
  padding: 12px 15px;
  border: 1px solid var(--medium-gray);
  border-radius: 4px;
  font-family: "Poppins", sans-serif;
  font-size: 16px;
}

.newsletter-input:focus {
  outline: none;
  border-color: var(--primary-blue);
}

/* --- IMPROVEMENT: Style for input errors --- */
.newsletter-input.error {
  border-color: var(--primary-red);
  background-color: #ffeeee;
}

.newsletter-privacy {
  font-size: 14px;
  color: var(--dark-gray);
}

.newsletter-privacy a {
  text-decoration: underline;
}

/* Footer */
.footer {
  background-color: var(--dark-text);
  color: var(--white);
  padding: 80px 0 30px;
}

.footer-container {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 30px;
}

@media (max-width: 1023px) {
  .footer-container {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 767px) {
  .footer-container {
    grid-template-columns: 1fr;
  }
}

.footer-logo {
  margin-bottom: 20px;
}

.footer-logo img {
  height: 100px;
}

.footer-about {
  margin-bottom: 20px;
  color: rgba(255, 255, 255, 0.7);
}

.footer-social {
  display: flex;
  gap: 15px;
}

.footer-social a {
  width: 36px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  transition: var(--transition);
}

.footer-social a:hover {
  background-color: var(--primary-red);
  transform: translateY(-3px);
}

.footer-title {
  font-size: 18px;
  margin-bottom: 20px;
  color: var(--white);
}

.footer-links {
  list-style: none;
}

.footer-link {
  margin-bottom: 10px;
}

.footer-link a {
  color: rgba(255, 255, 255, 0.7);
  transition: var(--transition);
}

.footer-link a:hover {
  color: var(--white);
  padding-left: 5px;
}

.footer-contact-item {
  display: flex;
  margin-bottom: 15px;
  color: rgba(255, 255, 255, 0.7);
}

.footer-contact-icon {
  margin-right: 10px;
  color: var(--primary-red);
  flex-shrink: 0; /* Prevent shrinking */
  width: 20px; /* Ensure alignment */
  text-align: center;
}

.footer-bottom {
  margin-top: 50px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

@media (max-width: 767px) {
  .footer-bottom {
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }
}

.footer-copyright {
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
}

.footer-legal {
  display: flex;
  gap: 20px;
}

.footer-legal a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
  transition: var(--transition);
}

.footer-legal a:hover {
  color: var(--white);
}

.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 40px;
  height: 40px;
  background-color: var(--primary-blue);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 99;
  border: none; /* Treat as button */
  padding: 0;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background-color: var(--primary-red);
  transform: translateY(-5px);
}

/* Modals */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  background: var(--white); /* Add background for content */
  border-radius: 8px; /* Optional: round corners */
  overflow: auto; /* Add scroll if content overflows */
}

.modal-close {
  position: absolute;
  top: 10px; /* Adjusted position */
  right: 10px;
  color: var(--dark-text); /* Better contrast on white */
  background: rgba(255, 255, 255, 0.8); /* Ensure visibility */
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
  z-index: 10; /* Above iframe */
  border: none;
  padding: 0;
}
.modal-close:hover {
  background: var(--light-gray);
}

.video-modal .modal-content {
  width: 800px;
  max-width: 100%;
  background: none; /* Remove background for video */
  border-radius: 0;
  overflow: visible; /* Allow close button outside */
}

.video-container {
  position: relative;
  padding-top: 56.25%;
  width: 100%;
  border-radius: 8px; /* Add radius to video container */
  overflow: hidden; /* Clip corners */
  background: #000; /* Black background while loading */
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* Cookie Consent */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: var(--white);
  padding: 15px 0;
  box-shadow: 0 -5px 10px rgba(0, 0, 0, 0.1);
  z-index: 9998;
  transform: translateY(100%);
  transition: var(--transition);
}

.cookie-consent.active {
  transform: translateY(0);
}

.cookie-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

@media (max-width: 767px) {
  .cookie-container {
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }
}

.cookie-text {
  margin-bottom: 0;
  font-size: 14px;
}

.cookie-buttons {
  display: flex;
  gap: 10px;
}

/* WhatsApp Chat */
.chat-widget {
  position: fixed;
  bottom: 30px;
  left: 30px;
  z-index: 99;
}

.chat-button {
  width: 60px;
  height: 60px;
  background-color: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 28px;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: var(--transition);
  border: none; /* Treat as button */
  padding: 0;
}

.chat-button:hover {
  transform: scale(1.1);
}

.chat-popup {
  position: absolute;
  bottom: 80px;
  left: 0;
  width: 300px;
  background-color: var(--white);
  border-radius: 8px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: var(--transition);
}

.chat-popup.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.chat-header {
  background-color: #25d366;
  color: var(--white);
  padding: 15px;
  display: flex;
  align-items: center;
}

.chat-header-icon {
  margin-right: 10px;
  font-size: 24px;
}

.chat-header-title {
  font-weight: 500;
}

.chat-body {
  padding: 15px;
}

.chat-message {
  margin-bottom: 15px;
  font-size: 14px;
}

/* --- IMPROVEMENT: Change chat form to a link --- */
.chat-link-container {
  margin-top: 15px;
}

.chat-link {
  display: inline-block;
  background-color: #25d366;
  color: var(--white);
  border: none;
  border-radius: 4px;
  padding: 10px 15px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  font-weight: 500;
  width: 100%;
  text-align: center;
}

.chat-link:hover {
  background-color: #1da851;
  color: var(--white);
}
.chat-link i {
  margin-left: 8px;
}

/* Popup Banner */
.popup-banner {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.popup-banner.active {
  opacity: 1;
  visibility: visible;
}

.popup-content {
  position: relative;
  max-width: 500px;
  width: 90%;
  background-color: var(--white);
  border-radius: 8px;
  overflow: hidden;
  animation: popupFadeIn 0.5s ease;
}

@keyframes popupFadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.popup-header {
  padding: 20px;
  background: linear-gradient(135deg, var(--primary-red), var(--primary-blue));
  color: var(--white);
  text-align: center;
}

.popup-title {
  font-size: 24px;
  margin-bottom: 0;
  color: var(--white); /* Explicit color */
}

.popup-body {
  padding: 30px;
  text-align: center;
}

.popup-form {
  margin-top: 20px;
}

.popup-input {
  width: 100%;
  padding: 12px 15px;
  margin-bottom: 15px;
  border: 1px solid var(--medium-gray);
  border-radius: 4px;
  font-family: "Poppins", sans-serif;
  font-size: 16px;
}

.popup-input:focus {
  outline: none;
  border-color: var(--primary-blue);
}

/* --- IMPROVEMENT: Style for input errors --- */
.popup-input.error {
  border-color: var(--primary-red);
  background-color: #ffeeee;
}

.popup-button {
  width: 100%;
  margin-top: 10px;
}

.popup-footer {
  padding: 0 30px 20px;
  text-align: center;
  font-size: 14px;
  color: var(--dark-gray);
}

.popup-close {
  position: absolute;
  top: 10px;
  right: 10px;
  color: var(--white); /* White on gradient */
  font-size: 20px;
  cursor: pointer;
  z-index: 1;
  border: none;
  background: none;
  padding: 5px;
  line-height: 1;
}
.popup-close:hover {
  opacity: 0.8;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fadeInUp {
  animation: fadeInUp 0.8s ease forwards;
}

/* Utilities */
.text-center {
  text-align: center;
}

.mb-0 {
  margin-bottom: 0;
}

.calendly-inline-widget {
  min-width: 320px;
  height: 700px;
}
