/* ================= THEME COLORS ================= */

:root {
    /* Primary brand colors */
    --color-primary: #4a7ff2;
    --color-primary-dark: #888cdc;
    --color-secondary: #EFF6FF;

    /* Accent & UI */
    --color-accent: #2b5bdf;
    --color-border: #4b73e2;

    /* Text colors */
    --color-text-main: #1F2937;
    --color-text-muted: #374151;
    --color-text-light: #ffffff;

    /* Backgrounds */
    --color-bg-main: #f7f9fb;
    --color-bg-card: #ffffff;
}

/* ================= RESET & BASE ================= */

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
}

body {
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--color-bg-main);
    color: var(--color-text-main);
    line-height: 1.6;
}

a {
    color: inherit;
}

/* ================= HEADER ================= */

header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 88px;
    background-color: var(--color-primary);
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 0 20px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Hamburger button */
.menu-btn {
    font-size: 32px;
    background: none;
    border: none;
    color: var(--color-text-light);
    cursor: pointer;
}

/* Logo + Title */
.logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo {
    height: 56px;
    border-radius: 14px;
    background: var(--color-bg-card);
    padding: 4px;
}

.site-title {
    display: flex;
    flex-direction: column;
    color: var(--color-text-light);
    line-height: 1.1;
}

.site-title .brand {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 0.6px;
}

.site-title .descriptor {
    font-size: 15px;
    font-weight: 500;
    opacity: 0.9;
}

/* ===== Mobile Header: Proper Centered Title ===== */
@media (max-width: 768px) {

  header {
    display: grid;
    grid-template-columns: 48px 1fr 48px; /* left | center | right */
    align-items: center;
    padding: 0 12px;
    height: 96px;
  }

  /* Hamburger stays left */
  .menu-btn {
    grid-column: 1;
    justify-self: start;
    font-size: 34px;
    z-index: 2;
  }

  /* Center logo + title perfectly */
  .logo-container {
    grid-column: 2;
    justify-self: center;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: center;
  }

  /* Prevent header-left flex from interfering */
  .header-left {
    display: contents;
  }

  .site-title {
    text-align: left;
  }

  .site-title .brand {
    font-size: 20px;
    line-height: 1.1;
  }

  .site-title .descriptor {
    font-size: 13px;
    line-height: 1.1;
  }
}


/* ================= SIDE MENU ================= */

.side-menu {
    position: fixed;
    top: 0;
    left: -260px;
    width: 260px;
    height: 100%;
    background-color: var(--color-primary-dark);
    padding: 24px;
    box-shadow: 2px 0 14px rgba(0, 0, 0, 0.3);
    transition: left 0.3s ease;
    z-index: 3000;
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

.side-menu a {
    display: block;
    color: var(--color-text-light);
    text-decoration: none;
    font-size: 20px;
    margin: 20px 0;
}

.side-menu a:hover {
    font-size: 22px;
}

.close-btn {
    font-size: 34px;
    color: var(--color-text-light);
    cursor: pointer;
    text-align: right;
}

/* Overlay */
.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
    z-index: 2500;
}

/* ================= HERO ================= */

.hero {
    background: var(--color-secondary);
    min-height: calc(100vh - 72px);
    position: relative;
    z-index: 1;
    overflow: hidden;
    padding-top: 40px;
}

.hero-inner {
    max-width: 1200px;
    margin: auto;
    padding: 80px 20px;
    display: flex;
    align-items: center;
    gap: 40px;
    position: relative;
    z-index: 2;

}

.hero-image img {
    max-width: 420px;
    width: 100%;
    border-radius: 18px;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.08));
}

.hero-text {
    max-width: 560px;
}

.hero-text h1 {
    font-size: 42px;
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--color-accent);
}

.hero-text h1 span {
    color: var(--color-primary);
}

.hero-desc {
    font-size: 17px;
    line-height: 1.7;
    color: var(--color-text-muted);
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("../images/logos/jeevana_raksha_logo_512.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 860px;
    opacity: 0.05;
    pointer-events: none;
    z-index: 0;
}

@media (max-width: 768px) {
    .hero::before {
        background-size: 240px;
        opacity: 0.04;
    }

      .hero {
    min-height: auto;        /* allow growth */
    height: auto;
    overflow: visible;       /* allow content to show */
    padding-bottom: 56px;    /* space for arrow */
  }

      .hero-inner {
    padding: 20px 16px 40px;
    gap: 20px;
  }

    .hero-image img {
    max-width: 240px;
    height: auto;
    object-fit: contain;
    margin-top: 8px;
  }

    .hero-text h1 {
        font-size: 28px;
        line-height: 1.25;
    }

    .hero-desc {
        font-size: 15px;
    }

    /* watermark lighter on mobile */
    .hero::after {
        opacity: 0.05;
        background-size: 220px;
    }

    /* scroll arrow visible */
    .scroll-indicator {
        bottom: 16px;
    }
}

/* ================= BUTTONS ================= */

.btn {
    display: inline-block;
    padding: 12px 22px;
    background-color: var(--color-primary);
    color: var(--color-text-light);
    text-decoration: none;
    border-radius: 6px;
    font-size: 15px;
    transition: background-color 0.2s ease;
}

.btn:hover {
    background-color: var(--color-primary-dark);
}

/* ================= SECTIONS ================= */

.section {
    padding: 50px 20px;
    max-width: 1100px;
    margin: auto;
    position: relative;
    z-index: 2;
    background: var(--color-bg-card);
}

.section h3 {
    text-align: center;
    font-size: 26px;
    margin-bottom: 30px;
    color: var(--color-primary);
}

.section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    width: 60px;
    height: 4px;
    background: var(--color-primary);
    transform: translateX(-50%);
    border-radius: 4px;
}

/* ================= SERVICES ================= */

.services {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 22px;
}

#services {
    margin-top: -80px;
    padding-top: 100px;
    z-index: 3;
}

.card {
    background: var(--color-bg-card);
    padding: 22px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card h4 {
    margin-top: 0;
    color: var(--color-primary);
}

@media (max-width: 768px) {
  #services {
    margin-top: 0;
    padding-top: 40px;
  }
}

/* ================= GALLERY ================= */

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
}

.gallery-grid img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 14px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.gallery-grid img:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
}

/* ================= CONTACT ================= */

.contact {
    border-left: 5px solid var(--color-primary);
    background: var(--color-bg-card);
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    text-align: center;
}

/* ================= FOOTER ================= */

footer {
    background-color: var(--color-primary);
    color: var(--color-text-light);
    text-align: center;
    padding: 16px;
    font-size: 14px;
}

/* ================= SCROLL INDICATOR ================= */

.scroll-indicator {
    position: absolute;
    bottom: 110px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--color-primary);
    font-size: 13px;
    opacity: 0.9;
    z-index: 10;
}

.scroll-indicator .arrow {
    width: 18px;
    height: 18px;
    border-right: 3px solid var(--color-primary);
    border-bottom: 3px solid var(--color-primary);
    transform: rotate(45deg);
    margin: auto;
    animation: bounceArrow 1.6s infinite;
}

@keyframes bounceArrow {
    0% {
        transform: rotate(45deg) translate(0, 0);
        opacity: 0.4;
    }

    50% {
        transform: rotate(45deg) translate(6px, 6px);
        opacity: 1;
    }

    100% {
        transform: rotate(45deg) translate(0, 0);
        opacity: 0.4;
    }
}

@media (max-width: 768px) {
     .scroll-indicator {
    position: relative;
    margin-top: 16px;
    bottom: auto;
  }
}

/* ================= HERO DEPTH ================= */

.hero.behind {
    filter: brightness(0.94);
}

/* ================= RESPONSIVE ================= */

@media (max-width: 900px) {
    .hero-inner {
        flex-direction: column;
        text-align: center;
    }

    .hero-image img {
        max-width: 300px;
    }

    .hero-text h1 {
        font-size: 32px;
    }
}

@media (max-width: 768px) {
    .hero-image img {
        max-width: 240px;
    }
}

/* ================= LIGHTBOX ================= */
/* ================= LIGHTBOX ================= */

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    z-index: 4000;

    display: flex;
    align-items: center;
    justify-content: center;

    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.lightbox.show {
    opacity: 1;
    pointer-events: auto;
}

.lightbox img {
    max-width: 88%;
    max-height: 88%;
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    animation: zoomIn 0.25s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.96);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Close button */
.lightbox .close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    font-size: 44px;
    color: #ffffff;
    cursor: pointer;
    z-index: 10;
}

/* Navigation arrows */
.lightbox .nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.55);
    border: none;
    color: white;
    font-size: 44px;
    padding: 18px 22px;
    cursor: pointer;
    border-radius: 50%;
    user-select: none;
}

.lightbox .nav:hover {
    background: rgba(0, 0, 0, 0.65);
}

.lightbox .prev {
    left: 24px;
}

.lightbox .next {
    right: 24px;
}

/* Mobile tweak */
@media (max-width: 768px) {
  .lightbox .nav {
    font-size: 40px;
    padding: 20px;
  }

  .lightbox .close {
    font-size: 42px;
    width: 52px;
    height: 52px;
  }
}
/* ================= TESTIMONIALS ================= */

.testimonials-section {
  background: var(--color-bg-main);
}

.testimonials-wrapper {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scrollbar-width: none;
  scroll-snap-type: x mandatory;
}

.testimonials-wrapper::-webkit-scrollbar {
  display: none;
}

.testimonials-track {
  display: flex;
  flex-wrap: nowrap;
  gap: 20px;
  padding: 14px 6px;
}

.testimonial-card {
  flex: 0 0 280px;
  background: var(--color-bg-card);
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  scroll-snap-align: start;
}

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

/* Header */
.testimonial-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

/* Avatar */
.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  background: #e5e7eb;
}

/* Stars */
.rating span {
  color: #f5b301;
  font-size: 18px;
  letter-spacing: 1px;
}

/* Review */
.review {
  font-size: 15px;
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: 12px;
}

/* Author */
.author {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-primary);
}

/* ================= GALLERY CAROUSEL (4 ITEMS + ARROWS) ================= */

.gallery-carousel-container {
  position: relative;
  display: flex;
  align-items: center;
}

.gallery-carousel {
  overflow: hidden;
  width: 100%;
}

.gallery-track {
  display: flex;
  gap: 24px;
  transition: transform 0.5s ease;
  padding: 20px 0;
}

/* Default item */
.gallery-item {
  flex: 0 0 22%;                 /* 4 items visible */
  height: 180px;
  border-radius: 18px;
  overflow: hidden;
  opacity: 0.55;
  transform: scale(0.92);
  transition: all 0.4s ease;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Active (center focus) */
.gallery-item.active {
  flex: 0 0 28%;
  height: 230px;
  opacity: 1;
  transform: scale(1);
  box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}

/* Arrows */
.gallery-arrow {
  background: none;
  border: none;
  font-size: 48px;
  color: var(--color-primary);
  cursor: pointer;
  padding: 12px;
  z-index: 2;
}

.gallery-arrow:hover {
  opacity: 0.75;
}

.gallery-arrow.left {
  margin-right: 10px;
}

.gallery-arrow.right {
  margin-left: 10px;
}

.gallery-carousel-container {
  position: relative;
  display: flex;
  align-items: center;
  height: 260px;            /* FIXED HEIGHT */
  overflow: hidden;
}


/* Mobile adjustments */
@media (max-width: 768px) {
  .gallery-item {
    flex: 0 0 70%;
    height: 200px;
  }

  .gallery-item.active {
    flex: 0 0 80%;
    height: 240px;
  }

  .gallery-arrow {
    font-size: 36px;
  }

    .gallery-carousel-container {
    height: 280px;
  }
}
