/* GLOBAL STYLES
-------------------------------------------------- */
body {
  padding-top: 3rem;
  padding-bottom: 3rem;
  color: #5a5a5a;
}

/* LANDING PAGE LAYOUT
-------------------------------------------------- */
.landing-main {
  padding-top: 4.75rem;
}
@media (min-width: 992px) {
  .landing-main {
    padding-top: 5.5rem;
  }
}

/* NAVBAR
-------------------------------------------------- */
.navbar .brand-text span {
  display: block;
  line-height: 1.1;
}
.navbar .brand-text small {
  font-size: 0.75rem;
}
.brand-logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

@media (max-width: 575.98px) {
  .navbar .brand-text small {
    display: none;
  }
}

/* HERO CAROUSEL - FIXED AND OPTIMIZED
-------------------------------------------------- */
.hero-carousel {
  color: #fff;
  margin-bottom: 4rem;
}

.hero-carousel .carousel-item {
  position: relative;
  min-height: 400px;
}

@media (min-width: 768px) {
  .hero-carousel .carousel-item {
    min-height: 500px;
  }
}

@media (min-width: 992px) {
  .hero-carousel .carousel-item {
    min-height: 600px;
  }
}

/* Ensure carousel items display properly */
.hero-carousel .carousel-item.active,
.hero-carousel .carousel-item-next,
.hero-carousel .carousel-item-prev {
  display: flex !important;
  align-items: center;
  justify-content: center;
}

/* Background media */
.hero-carousel .hero-media,
.hero-carousel .hero-media-fallback {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-carousel .hero-media {
  object-fit: cover;
}

.hero-carousel .hero-media-fallback {
  background: #343a40;
}

/* Overlay gradient */
.hero-carousel .carousel-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(128, 0, 0, 0.6), rgba(27, 27, 27, 0.7));
  z-index: 1;
}

/* Caption positioning - FIXED */
.hero-carousel .carousel-caption {
  position: relative;
  z-index: 2;
  max-width: 700px;
  width: 100%;
  padding: 2rem 1.5rem;
  margin: 0 auto;
  left: 0;
  right: 0;
  bottom: auto;
}

/* Badge - RESPONSIVE FIX */
.hero-carousel .carousel-caption .badge {
  letter-spacing: 0.08em;
  font-weight: 600;
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  white-space: normal;
  text-align: center;
  line-height: 1.3;
  max-width: 100%;
  word-wrap: break-word;
}

/* Headings and text */
.hero-carousel .carousel-caption h1 {
  text-shadow: 0 0.75rem 1.5rem rgba(0, 0, 0, 0.45);
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero-carousel .carousel-caption p {
  text-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.4);
  margin-bottom: 1.5rem;
}

/* Button container */
.hero-carousel .carousel-caption .d-flex {
  margin-top: 1.5rem;
}

/* TABLET RESPONSIVENESS */
@media (max-width: 767.98px) {
  .hero-carousel .carousel-item {
    min-height: 450px;
  }
  
  .hero-carousel .carousel-caption {
    max-width: 100%;
    padding: 2rem 1rem;
  }
  
  .hero-carousel .carousel-caption .badge {
    font-size: 0.65rem;
    padding: 0.4rem 0.75rem;
    letter-spacing: 0.05em;
  }
  
  .hero-carousel .carousel-caption h1 {
    font-size: 1.75rem;
  }
  
  .hero-carousel .carousel-caption p {
    font-size: 0.95rem;
  }
}

/* MOBILE RESPONSIVENESS */
@media (max-width: 575.98px) {
  .hero-carousel .carousel-item {
    min-height: 420px;
  }
  
  .hero-carousel .carousel-caption {
    padding: 1.5rem 1rem;
  }
  
  .hero-carousel .carousel-caption .badge {
    font-size: 0.6rem;
    padding: 0.35rem 0.6rem;
    letter-spacing: 0.03em;
    max-width: 95%;
  }
  
  .hero-carousel .carousel-caption h1 {
    font-size: 1.5rem;
  }
  
  .hero-carousel .carousel-caption p {
    font-size: 0.9rem;
  }
  
  .hero-carousel .carousel-caption .btn {
    width: 100%;
    max-width: 15rem;
  }
  
  /* Stack buttons vertically */
  .hero-carousel .carousel-caption .d-flex {
    flex-direction: column !important;
    align-items: center !important;
    gap: 0.75rem !important;
  }
}

/* FEATURE CARDS
-------------------------------------------------- */
.feature-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 1.5rem 2.5rem rgba(0, 0, 0, 0.1);
}
.feature-icon {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  margin-bottom: 1.25rem;
  background: rgba(128, 0, 0, 0.08);
  color: #800000;
}

/* MARKETING CONTENT
-------------------------------------------------- */
.marketing .col-lg-4 {
  margin-bottom: 1.5rem;
  text-align: center;
}
.marketing h2 {
  font-weight: 400;
}
.marketing .col-lg-4 p {
  margin-right: .75rem;
  margin-left: .75rem;
}

/* STATS SECTION
-------------------------------------------------- */
.stats-section .stat-value {
  font-size: 2rem;
  font-weight: 700;
}
.stats-section .stat-label {
  color: rgba(0, 0, 0, 0.65);
  font-size: 0.95rem;
}

/* FEATURETTES
-------------------------------------------------- */
.featurette-divider {
  margin: 5rem 0;
}
.featurette-heading {
  font-weight: 300;
  line-height: 1;
  letter-spacing: -.05rem;
}
.featurette + .featurette {
  margin-top: 3rem;
}

@media (min-width: 40em) {
  .featurette-heading {
    font-size: 50px;
  }
}

@media (min-width: 62em) {
  .featurette-heading {
    margin-top: 7rem;
  }
}

/* CTA SECTION
-------------------------------------------------- */
.cta-wrapper {
  margin-top: 4rem;
}
.cta-section {
  background: linear-gradient(135deg, #800000, #431c53);
  color: #fff;
  border-radius: 1rem;
  padding: 3rem;
  position: relative;
  overflow: hidden;
}
.cta-section::after {
  content: '';
  position: absolute;
  top: -20%;
  right: -10%;
  width: 320px;
  height: 320px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  pointer-events: none;
}
.cta-section .btn {
  min-width: 180px;
}

/* FOOTER
-------------------------------------------------- */
footer {
  color: rgba(255, 255, 255, 0.6);
}
footer .link-light {
  color: rgba(255, 255, 255, 0.75) !important;
}

/* DARK MODE
-------------------------------------------------- */
@media (prefers-color-scheme: dark) {
  .feature-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  .feature-icon {
    background: rgba(255, 255, 255, 0.08);
    color: #ffccd5;
  }
  .stats-section .stat-label {
    color: rgba(255, 255, 255, 0.65);
  }
  .cta-section::after {
    background: rgba(255, 255, 255, 0.08);
  }
}