/* ==========================================================================
   Homeo Care Clinic — Homepage Stylesheet
   Covers: hero carousel, intro+clinics, stats band, doctor bio, why-us,
   online consult, health categories, products, reviews, media band,
   partners, team carousel, before/after carousel, blog teaser.
   Plus: scroll-reveal animation system + shared carousel component styles.
   Depends on tokens defined in style.css — load style.css first.
   ========================================================================== */

/* ---------- Shared section wrapper widths ---------- */
.intro-clinics__inner,
.stats-band__inner,
.doctor-bio__inner,
.why-us__inner,
.online-consult__inner,
.health-categories__inner,
.products__inner,
.reviews__inner,
.media-band__inner,
.partners__inner,
.team__inner,
.before-after__inner,
.blog-teaser__inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 3.5rem 1.25rem;
}

.eyebrow {
  color: var(--color-accent);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 0.4rem;
}

/* Section-level headings: black/near-black, NOT green — green is reserved
   for card/grid titles (h3/h4) inside content blocks, per site-wide rule. */
section h1,
section h2 {
  color: var(--color-text);
}

section h2 {
  font-size: 1.75rem;
  margin: 0 0 1rem;
}

/* ==========================================================================
   Hero carousel
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
}

.hero__track {
  display: flex;
  transition: transform 0.5s ease;
}

.hero__slide {
  flex: 0 0 100%;
}

.hero__slide img {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
  display: block;
}

.hero__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.9);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text);
  cursor: pointer;
  z-index: 10;
  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.hero__arrow svg {
  width: 20px;
  height: 20px;
}

.hero__arrow:hover {
  background: #fff;
  transform: translateY(-50%) scale(1.08);
}

.hero__arrow--prev {
  left: 1rem;
}

.hero__arrow--next {
  right: 1rem;
}

.hero__dots {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
  z-index: 10;
}

.hero__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
  border: none;
  cursor: pointer;
  padding: 0;
  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.hero__dot.is-active {
  background: #fff;
  transform: scale(1.2);
}

/* ==========================================================================
   Intro (left) + Visit Our Clinics (right)
   ========================================================================== */
.intro-clinics {
  background: #fff;
}

.intro-clinics__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.intro-clinics__content h1 {
  font-size: 2rem;
  margin: 0 0 1rem;
}

.intro-clinics__content p {
  color: var(--color-text-light);
}

.intro-clinics__clinics {
  background: var(--color-bg-alt);
  border-radius: 10px;
  padding: 1.75rem;
}

.clinics__list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.clinic-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1.25rem;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.clinic-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.clinic-card h3 {
  color: var(--color-primary);
  font-size: 1rem;
  margin: 0 0 0.5rem;
}

.clinic-card p {
  color: var(--color-text-light);
  font-size: 0.875rem;
}

/* ==========================================================================
   Stats band
   ========================================================================== */
.stats-band {
  background: var(--color-bg-alt);
}

.stats-band p {
  color: var(--color-text-light);
  max-width: 820px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
  text-align: center;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1.5rem 1.25rem;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.stat:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.stat__num {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-primary);
}

.stat__label {
  font-size: 0.85rem;
  color: var(--color-text-light);
}

/* ==========================================================================
   Doctor bio — image 45% / text 55%
   ========================================================================== */
.doctor-bio {
  background: #fff;
}

.doctor-bio__inner {
  display: grid;
  grid-template-columns: 45% 55%;
  gap: 2.5rem;
  align-items: center;
}

.doctor-bio__inner img {
  border-radius: 8px;
  width: 100%;
}

.doctor-bio__text p {
  color: var(--color-text-light);
}

/* ==========================================================================
   Why choose us — icon cards
   ========================================================================== */
.why-us {
  background: var(--color-bg-alt);
}

.why-us__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.why-card {
  background: #fff;
  border-radius: 10px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.why-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.1);
}

.why-card__icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--color-bg-info);
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.1rem;
  transition:
    background 0.25s ease,
    color 0.25s ease,
    transform 0.25s ease;
}

.why-card__icon svg {
  width: 28px;
  height: 28px;
}

.why-card:hover .why-card__icon {
  background: var(--color-primary);
  color: #fff;
  transform: scale(1.08);
}

.why-card h3 {
  color: var(--color-primary);
  font-size: 1.05rem;
  margin: 0 0 0.5rem;
}

.why-card p {
  color: var(--color-text-light);
  font-size: 0.875rem;
}

/* ==========================================================================
   Online consultation
   ========================================================================== */
.online-consult {
  background: #fff;
  text-align: center;
}

.online-consult img {
  margin: 0 auto;
  max-width: 640px;
}

/* ==========================================================================
   Health categories
   ========================================================================== */
.health-categories {
  background: var(--color-bg-alt);
}

.health-categories > .health-categories__inner > p {
  color: var(--color-text-light);
  max-width: 720px;
}

.health-categories__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.category-block {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.category-block:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.category-block h3 {
  color: var(--color-primary);
  font-size: 1rem;
  margin: 0 0 0.75rem;
}

.category-block li {
  margin-bottom: 0.4rem;
}

.category-block a {
  font-size: 0.875rem;
  color: var(--color-text-light);
}

.category-block a:hover {
  color: var(--color-primary);
}

/* ==========================================================================
   Products — icon cards
   ========================================================================== */
.products {
  background: #fff;
}

.products__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.5rem;
}

.product-group {
  background: var(--color-bg-alt);
  border-radius: 10px;
  padding: 1.75rem 1.25rem;
  text-align: center;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.product-group:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.08);
}

.product-group__icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #fff;
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  transition:
    background 0.25s ease,
    color 0.25s ease;
}

.product-group__icon svg {
  width: 24px;
  height: 24px;
}

.product-group:hover .product-group__icon {
  background: var(--color-primary);
  color: #fff;
}

.product-group h3 {
  color: var(--color-primary);
  font-size: 1rem;
  margin: 0 0 0.75rem;
}

.product-group ul {
  text-align: left;
}

.product-group li {
  margin-bottom: 0.4rem;
}

.product-group a {
  font-size: 0.85rem;
  color: var(--color-text-light);
}

.product-group a:hover {
  color: var(--color-primary);
}

/* ==========================================================================
   Reviews
   ========================================================================== */
.reviews {
  background: var(--color-bg-alt);
}

.reviews__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.review-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1.5rem;
  margin: 0;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.review-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.review-card p {
  font-size: 0.9rem;
  color: var(--color-text-light);
  font-style: italic;
}

.review-card cite {
  display: block;
  margin-top: 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-primary);
  font-style: normal;
}

/* ==========================================================================
   Featured media band
   ========================================================================== */
.media-band {
  background: #fff;
  text-align: center;
}

.media-band__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin-top: 1.5rem;
}

.media-band__grid img {
  height: 32px;
  width: auto;
  opacity: 0.7;
  filter: grayscale(100%);
  transition:
    opacity 0.25s ease,
    filter 0.25s ease;
}

.media-band__grid img:hover {
  opacity: 1;
  filter: grayscale(0%);
}

/* ==========================================================================
   Partners
   ========================================================================== */
.partners {
  background: var(--color-bg-alt);
  text-align: center;
}

.partners__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 3rem;
  margin-top: 1.5rem;
}

.partners__grid img {
  height: 40px;
  width: auto;
  transition: transform 0.25s ease;
}

.partners__grid img:hover {
  transform: translateY(-3px);
}

/* ==========================================================================
   Shared horizontal carousel component (Team + Before/After)
   ========================================================================== */
.carousel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.carousel-arrow {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--color-border);
  color: var(--color-text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.carousel-arrow svg {
  width: 18px;
  height: 18px;
}

.carousel-arrow:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #fff;
  transform: scale(1.06);
}

/* ---------- Team carousel ---------- */
.team {
  background: #fff;
  text-align: center;
}

.team__subtitle {
  color: var(--color-text-light);
  margin-bottom: 2rem;
}

.team__track {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 0.5rem;
  flex: 1;
  scrollbar-width: none;
}

.team__track::-webkit-scrollbar {
  display: none;
}

.team-card {
  scroll-snap-align: start;
  flex: 0 0 190px;
  text-align: left;
  transition: transform 0.25s ease;
}

.team-card:hover {
  transform: translateY(-5px);
}

.team-card img {
  border-radius: 8px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  width: 100%;
  background: var(--color-bg-alt);
}

.team-card h3 {
  color: var(--color-primary);
  font-size: 0.9rem;
  margin: 0.75rem 0 0.15rem;
}

.team-card h3 a {
  color: inherit;
}

.team-card p {
  font-size: 0.75rem;
  color: var(--color-text-light);
  margin: 0;
}

/* ---------- Before / After carousel ---------- */
.before-after {
  background: var(--color-bg-alt);
  text-align: center;
}

.before-after__subtitle {
  color: var(--color-text-light);
  margin-bottom: 2rem;
}

.before-after__track {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 0.5rem;
  flex: 1;
  scrollbar-width: none;
}

.before-after__track::-webkit-scrollbar {
  display: none;
}

.before-after__track img {
  scroll-snap-align: start;
  flex: 0 0 300px;
  border-radius: 8px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.25s ease;
}

.before-after__track img:hover {
  transform: scale(1.03);
}

/* ==========================================================================
   Blog teaser
   ========================================================================== */
.blog-teaser {
  background: #fff;
}

.blog-teaser__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.blog-card {
  border: 1px solid var(--color-border);
  border-radius: 8px;
  overflow: hidden;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 14px 24px rgba(0, 0, 0, 0.08);
}

.blog-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.blog-card h3 {
  color: var(--color-primary);
  font-size: 1rem;
  margin: 1rem 1rem 0.75rem;
  line-height: 1.4;
}

.blog-card h3 a {
  color: inherit;
}

.blog-card h3 a:hover {
  text-decoration: underline;
}

.blog-card .btn {
  margin: 0 1rem 1rem;
}

/* ==========================================================================
   Scroll-reveal animation system (progressive enhancement)
   The .has-js class is added by an inline script in header.php before CSS
   paints, so no-JS visitors always see full content with no animation.
   ========================================================================== */
html:not(.has-js) .reveal {
  opacity: 1 !important;
  transform: none !important;
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 960px) {
  .intro-clinics__inner {
    grid-template-columns: 1fr;
  }

  .doctor-bio__inner {
    grid-template-columns: 1fr;
  }

  .doctor-bio__inner img {
    max-width: 360px;
    margin: 0 auto;
  }

  .why-us__grid,
  .health-categories__grid,
  .reviews__grid,
  .blog-teaser__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats-grid,
  .products__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .why-us__grid,
  .health-categories__grid,
  .stats-grid,
  .products__grid,
  .reviews__grid,
  .blog-teaser__grid {
    grid-template-columns: 1fr;
  }

  .hero__slide img {
    max-height: 260px;
  }

  .hero__arrow {
    width: 36px;
    height: 36px;
  }

  .team-card {
    flex: 0 0 150px;
  }

  .before-after__track img {
    flex: 0 0 240px;
  }
}
