/* ==========================================================================
   SHREE JEE ASSOCIATE — Responsive Stylesheet
   Breakpoints: 1200 / 1080 / 992 / 768 / 576 / 400
   ========================================================================== */

/* ---------- Large desktop ---------- */
@media (max-width: 1280px) {
  :root {
    --sec-y: 76px;
  }

  .main-nav a {
    padding: 10px 9px;
    font-size: 0.88rem;
  }

  .main-nav a::after {
    left: 9px;
    right: 9px;
  }

  .brand-logo {
    height: 66px;
  }

  .site-header.is-stuck .brand-logo {
    height: 58px;
  }

  /* Drop the CTA text and keep just the icons so the 8-item nav still fits */
  .header-cta .btn span.cta-label {
    display: none;
  }

  .header-cta .btn {
    padding: 13px 15px;
  }
}

/* ---------- Small desktop / large tablet ---------- */
@media (max-width: 1080px) {
  .main-nav a {
    padding: 10px 7px;
    font-size: 0.85rem;
  }

  .main-nav a::after {
    left: 7px;
    right: 7px;
  }

  .brand-logo {
    height: 60px;
  }

  .hero-grid {
    gap: 40px;
  }
}

/* ==========================================================================
   TABLET & MOBILE NAVIGATION  (<= 992px)
   ========================================================================== */
@media (max-width: 992px) {
  :root {
    --sec-y: 64px;
    --header-h: 72px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  /* The sticky header creates its own stacking context, and the off-canvas
     panel lives inside it. Lift the header above the backdrop while the menu
     is open, otherwise the backdrop (1050) would paint over the panel. */
  body.nav-open .site-header {
    z-index: 1100;
  }

  /* Off-canvas panel */
  .main-nav {
    position: fixed;
    top: 0;
    right: 0;
    width: min(340px, 86vw);
    height: 100dvh;
    background: var(--white);
    box-shadow: -12px 0 40px rgba(5, 23, 44, 0.22);
    padding: 84px 24px 40px;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.34s var(--ease);
    z-index: 1100;
    visibility: hidden;
  }

  .main-nav.open {
    transform: translateX(0);
    visibility: visible;
  }

  .main-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }

  .main-nav a {
    padding: 15px 14px;
    font-size: 1rem;
    border-bottom: 1px solid var(--grey-100);
    border-radius: 0;
  }

  .main-nav a::after {
    display: none;
  }

  .main-nav a.active {
    color: var(--royal-600);
    background: var(--grey-50);
    border-left: 3px solid var(--gold-500);
  }

  /* CTA buttons repeated inside the panel */
  .nav-panel-cta {
    display: grid;
    gap: 12px;
    margin-top: 26px;
  }

  .nav-panel-cta .btn {
    width: 100%;
  }

  .nav-panel-contact {
    display: block;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--grey-200);
    font-size: 0.9rem;
    color: var(--ink-soft);
    line-height: 1.7;
  }

  .nav-panel-contact a {
    color: var(--navy-800);
    font-weight: 600;
    display: block;
  }

  /* Close button inside panel */
  .nav-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--grey-200);
    background: var(--white);
    color: var(--navy-800);
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-close svg {
    width: 18px;
    height: 18px;
  }

  .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(5, 23, 44, 0.55);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--t), visibility var(--t);
    z-index: 1050;
  }

  .nav-backdrop.show {
    opacity: 1;
    visibility: visible;
  }

  /* Layout shifts */
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .split,
  .split-wide-left,
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero {
    padding: 64px 0 72px;
  }

  /* Luxury hero: credential panel drops below the copy */
  .hero-lux {
    padding: 70px 0 76px;
  }

  .hero-lux .hero-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .hero-lux .lead,
  .hero-desc {
    max-width: none;
  }

  .footer-top {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 36px;
  }

  .cta-band {
    padding: 42px 32px;
    text-align: center;
    justify-content: center;
  }

  /* Timeline: 5 across is too tight below 992px — go to 3 + 2 */
  .timeline {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 32px 20px;
  }

  .timeline::before {
    display: none;
  }

  .cta-band .btn-group {
    justify-content: center;
  }

  .cta-band p {
    margin-inline: auto;
  }
}

/* ==========================================================================
   MOBILE  (<= 768px)
   ========================================================================== */
@media (max-width: 768px) {
  :root {
    --sec-y: 54px;
    --gap: 18px;
  }

  body {
    font-size: 16px;
    line-height: 1.68;
  }

  .container {
    padding-inline: 18px;
  }

  .topbar {
    font-size: 0.78rem;
  }

  .topbar .container {
    justify-content: center;
  }

  .topbar-left {
    gap: 16px;
    justify-content: center;
  }

  .topbar-email,
  .topbar-address {
    display: none;
  }

  /* Hide desktop header CTAs — mobile sticky bar takes over */
  .header-cta {
    display: none;
  }

  /* Two-up card layout survives down to large phones / small tablets.
     Wide pairs (.grid-2) go single so their text does not get cramped. */
  .grid-2 {
    grid-template-columns: 1fr;
  }

  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .check-list.two-col {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .section-head {
    margin-bottom: 36px;
  }

  .card {
    padding: 28px 24px;
  }

  .form-card {
    padding: 28px 22px;
  }

  .page-banner {
    padding: 52px 0 46px;
  }

  .cta-band {
    padding: 36px 24px;
    border-radius: var(--r-lg);
  }

  .btn-group .btn {
    flex: 1 1 100%;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 34px;
    text-align: left;
  }

  .site-footer {
    padding-top: 56px;
    /* room for the mobile sticky bar */
    padding-bottom: 0;
  }

  .footer-bottom {
    justify-content: center;
    text-align: center;
    padding-bottom: 26px;
  }

  .visual-panel {
    min-height: 260px;
    padding: 30px 26px;
  }

  .hero-lux {
    padding: 54px 0 60px;
  }

  .hero-cred {
    padding: 26px 22px;
  }

  .hero-rule {
    margin: 24px 0 22px;
  }

  .eyebrow-rule {
    font-size: 0.66rem;
    letter-spacing: 0.2em;
  }

  /* The trailing hairline wastes width on phones */
  .eyebrow-rule::after {
    display: none;
  }

  /* Timeline becomes a vertical list with a left rail */
  .timeline {
    grid-template-columns: 1fr;
    gap: 0;
    padding-left: 8px;
  }

  .tl-step {
    display: grid;
    grid-template-columns: 62px 1fr;
    gap: 18px;
    text-align: left;
    padding: 0 0 26px;
    position: relative;
  }

  .tl-step:last-child {
    padding-bottom: 0;
  }

  /* Vertical connector between markers */
  .tl-step:not(:last-child)::before {
    content: "";
    position: absolute;
    left: 30px;
    top: 62px;
    bottom: 6px;
    width: 2px;
    background: var(--grey-200);
    border-radius: 2px;
  }

  .timeline-light .tl-step:not(:last-child)::before {
    background: rgba(255, 255, 255, 0.16);
  }

  .tl-num {
    margin: 0;
  }

  .tl-step > div {
    padding-top: 10px;
  }

  .partner-note {
    padding: 18px 18px;
    font-size: 0.92rem;
  }

  /* ---- Floating buttons: move up above the sticky bar ---- */
  .float-actions {
    right: 14px;
    bottom: 84px;
    gap: 10px;
  }

  .float-btn {
    width: 50px;
    height: 50px;
  }

  .float-btn svg {
    width: 24px;
    height: 24px;
  }

  /* Hide the duplicate floating call button on mobile —
     the sticky bar already carries Call */
  .float-call {
    display: none;
  }

  .back-to-top {
    right: 14px;
    bottom: 146px;
    width: 42px;
    height: 42px;
  }

  /* ---- Mobile sticky action bar ---- */
  .mobile-bar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 950;
    background: var(--white);
    border-top: 1px solid var(--grey-200);
    box-shadow: 0 -6px 24px rgba(8, 36, 69, 0.12);
    padding-bottom: env(safe-area-inset-bottom, 0);
  }

  .mobile-bar a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 11px 6px 12px;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--navy-800);
    border-right: 1px solid var(--grey-100);
    transition: background var(--t-fast), color var(--t-fast);
    min-height: 60px;
  }

  .mobile-bar a:last-child {
    border-right: 0;
  }

  .mobile-bar a:active {
    background: var(--grey-50);
  }

  .mobile-bar svg {
    width: 21px;
    height: 21px;
  }

  .mobile-bar .mb-call {
    color: var(--royal-600);
  }

  .mobile-bar .mb-whatsapp {
    color: #1fa855;
  }

  .mobile-bar .mb-enquiry {
    color: var(--gold-600);
  }

  /* Push page content clear of the fixed bar */
  body {
    padding-bottom: 62px;
  }
}

/* ==========================================================================
   SMALL MOBILE  (<= 576px)
   ========================================================================== */
@media (max-width: 576px) {
  :root {
    --sec-y: 48px;
  }

  /* Phones: every card grid collapses to a single column */
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  /* Long CTA labels ("Explore Vrindavan Properties", "Get Insurance
     Assistance") are allowed to wrap rather than overflow their button. */
  .btn {
    white-space: normal;
    line-height: 1.35;
  }

  h1,
  .h1 {
    font-size: 2rem;
  }

  h2,
  .h2 {
    font-size: 1.6rem;
  }

  .lead {
    font-size: 1.02rem;
  }

  .brand-logo {
    height: 46px;
    max-width: 180px;
  }

  .site-header.is-stuck .brand-logo {
    height: 42px;
  }

  .btn {
    padding: 14px 24px;
    font-size: 0.93rem;
  }

  .btn-lg {
    padding: 16px 28px;
    font-size: 0.97rem;
  }

  .acc-trigger {
    padding: 17px 18px;
    font-size: 0.96rem;
  }

  .acc-panel-inner {
    padding: 0 18px 20px;
    font-size: 0.94rem;
  }

  .footer-logo-plate img {
    height: 84px;
  }

  .chips li {
    font-size: 0.84rem;
    padding: 8px 14px;
  }
}

/* ---------- Very small devices (320px – 400px) ---------- */
@media (max-width: 400px) {
  .container {
    padding-inline: 15px;
  }

  .mobile-bar a {
    font-size: 0.7rem;
    padding-inline: 4px;
  }

  .topbar-left {
    gap: 12px;
  }

  h1,
  .h1 {
    font-size: 1.72rem;
  }

  h2,
  .h2 {
    font-size: 1.45rem;
  }

  .lead {
    font-size: 0.98rem;
  }

  /* Product / e-book card buttons stack instead of squeezing side by side */
  .product-actions {
    flex-direction: column;
  }

  .product-actions .btn {
    width: 100%;
  }

  /* Tighter card and form padding to protect the reading width */
  .card {
    padding: 24px 18px;
  }

  .product-card {
    padding: 0;
  }

  .product-body {
    padding: 22px 18px 24px;
  }

  .form-card {
    padding: 24px 16px;
  }

  .card[style*="padding:10px 30px"] {
    padding-inline: 18px !important;
  }

  .cta-band {
    padding: 30px 18px;
  }

  .acc-trigger {
    padding: 15px 14px;
    gap: 12px;
  }

  .acc-panel-inner {
    padding: 0 14px 18px;
  }

  .partner-note {
    padding: 16px 14px;
    gap: 10px;
  }

  .visual-panel {
    padding: 26px 20px;
    min-height: 220px;
  }

  /* Contact / info rows: keep the icon and the long email on one line each */
  .info-row {
    gap: 12px;
  }

  .info-icon {
    width: 42px;
    height: 42px;
  }

  .btn-lg {
    padding: 15px 20px;
    font-size: 0.94rem;
  }

  .chips li {
    font-size: 0.8rem;
    padding: 7px 12px;
  }
}

/* ---------- Landscape phones: shorter vertical rhythm ---------- */
@media (max-width: 900px) and (orientation: landscape) and (max-height: 520px) {
  .hero {
    padding: 46px 0 54px;
  }

  .main-nav {
    padding-top: 70px;
  }
}
