/* Mobile/tablet-only refinements. Desktop (>=1024px) deliberately retains its existing styles. */
@media (max-width: 1023px) {
  /* Keep the resort affiliation/address readable as an open, edge-to-edge strip. */
  .home-company-strip {
    box-sizing: border-box !important;
    width: 100vw !important;
    max-width: none !important;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding-inline: max(1rem, env(safe-area-inset-left)) !important;
  }

  [aria-label="Resort brands and address"] .inline-flex.flex-wrap {
    box-sizing: border-box !important;
    display: flex !important;
    width: 100vw !important;
    max-width: none !important;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
    justify-content: center !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    padding: 0.65rem 1rem !important;
    white-space: normal !important;
  }

  /* Slightly reduce the center Iksha mark beside the tourism/JTDC marks. */
  [aria-label="Resort brands and address"] img[alt="Iksha Resorts"] {
    height: clamp(3.1rem, 9vw, 4.5rem) !important;
    max-height: 4.5rem !important;
  }

  /* Match the reference: full-width Call Now above WhatsApp with a visible gap. */
  #home div:has(> [data-testid="button-call-now-hero"]):has(> [data-testid="button-whatsapp-hero"]) {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: center !important;
    gap: 0.55rem !important;
    width: min(100%, 30rem) !important;
    margin-inline: auto !important;
  }

  #home [data-testid="button-call-now-hero"],
  #home [data-testid="button-whatsapp-hero"] {
    box-sizing: border-box !important;
    display: flex !important;
    flex: 0 0 auto !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: 2.75rem;
    justify-content: center !important;
    padding: 0.65rem 1rem !important;
  }

  /* Keep “Free” visible on desktop, but remove it from the mobile/tablet label. */
  #home .mobile-hide-free {
    display: none !important;
  }

  /* The floating CTA stays hidden at the top until the affiliation strip scrolls away. */
  body:not(.mobile-scroll-call-visible) [data-testid="button-floating-call"] {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translateY(0.75rem) !important;
    transition: opacity 180ms ease, transform 180ms ease, visibility 0s linear 180ms !important;
  }

  body.mobile-scroll-call-visible [data-testid="button-floating-call"] {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translateY(0) !important;
    transition: opacity 180ms ease, transform 180ms ease, visibility 0s !important;
  }
}


/* Separate the ownership/location copy from the resort-logo grid and compact it on smaller screens. */
@media (max-width: 1023px) {
  [aria-label="Resort brands and address"] .container > div:has(a.view-cta-blink) {
    padding-bottom: 0.35rem !important;
  }

  .home-ownership-section {
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    box-sizing: border-box;
    width: 100vw;
    margin: 0 !important;
    padding: 0.35rem 0 0.1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.12);
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .home-ownership-section .home-company-strip {
    box-sizing: border-box !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0.12rem 0.75rem !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    color: #1a1a1a !important;
    font-size: 0.7rem !important;
    line-height: 1.25 !important;
    gap: 0.2em !important;
  }

  .home-ownership-section > .border-t {
    border-top: 0 !important;
    padding: 0.05rem 0.75rem 0.35rem !important;
  }

  .home-ownership-section .inline-flex.flex-wrap {
    box-sizing: border-box !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
    display: flex !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0.05rem 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    column-gap: 0.35rem !important;
    row-gap: 0 !important;
    line-height: 1.25 !important;
  }
}


/* Final mobile/tablet logo scale and hero CTA breathing room. */
@media (max-width: 1023px) {
  [aria-label="Resort brands and address"] img[alt="Jharkhand Tourism"],
  [aria-label="Resort brands and address"] img[alt="JTDC"] {
    height: clamp(2.55rem, 8.85vw, 4.25rem) !important;
  }

  [aria-label="Resort brands and address"] img[alt="Iksha Resorts"] {
    height: clamp(2.7rem, 8vw, 3.75rem) !important;
  }

  [aria-label="Resort brands and address"] .container > div:has(a.view-cta-blink) a.group img {
    height: clamp(2.2rem, 6.35vw, 3.05rem) !important;
  }

  /* Add space only after the location badge; leave the rating/image spacing untouched. */
  #home div:has(> [data-testid="button-call-now-hero"]):has(> [data-testid="button-whatsapp-hero"]) {
    margin-top: 3.375rem !important;
  }
}


/* Final touch: modestly reduce the three resort marks and their view labels; match ownership/address type size. */
@media (max-width: 1023px) {
  [aria-label="Resort brands and address"] .container > div:has(a.view-cta-blink) a.group img {
    height: clamp(2rem, 5.72vw, 2.75rem) !important;
  }

  [aria-label="Resort brands and address"] a.view-cta-blink {
    font-size: clamp(7.2px, 1.17vw, 9px) !important;
    padding: 0.11rem 0.45rem !important;
  }

  .home-ownership-section .home-company-strip {
    font-size: 10px !important;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .home-ownership-section .home-company-strip {
    font-size: 14px !important;
  }
}


/* Make the lower three property marks and their captions unmistakably smaller on mobile/tablet. */
@media (max-width: 1023px) {
  [aria-label="Resort brands and address"] .container > div:has(a.view-cta-blink) a.group img {
    height: clamp(1.75rem, 5vw, 2.4rem) !important;
  }

  [aria-label="Resort brands and address"] a.view-cta-blink {
    font-size: clamp(6.5px, 1.04vw, 8px) !important;
    padding: 0.1rem 0.4rem !important;
  }
}

/* Apply the distinct affiliation/address section on desktop too, while leaving other PC layout intact. */
@media (min-width: 1024px) {
  .home-ownership-section {
    box-sizing: border-box;
    width: 100%;
    margin: 0.35rem 0 0 !important;
    padding: 0.45rem 0 0.35rem;
    border-top: 1px solid rgba(0, 0, 0, 0.12);
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .home-ownership-section .home-company-strip {
    box-sizing: border-box !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0.15rem 0.75rem !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    color: #1a1a1a !important;
    font-size: 14px !important;
    line-height: 1.25 !important;
    gap: 0.25em !important;
  }

  .home-ownership-section > .border-t {
    border-top: 0 !important;
    padding: 0.08rem 0.75rem 0.25rem !important;
  }

  .home-ownership-section .inline-flex.flex-wrap {
    box-sizing: border-box !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
    display: flex !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0.05rem 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    font-size: 14px !important;
    column-gap: 0.35rem !important;
    row-gap: 0 !important;
    line-height: 1.25 !important;
  }
}


/* Keep the mobile/header wordmark, hide only its secondary tagline, and improve hero-title contrast. */
header [data-testid="link-logo"] > div > span:nth-child(2) {
  display: none !important;
}

[data-testid="section-hero"] h1 {
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.88), 0 6px 14px rgba(0, 0, 0, 0.58) !important;
}
