/* ============================================================
   V.S.R SALON — Mobile Centering & UI Consistency Fixes
   Append this to styles.css (or include after it in HTML)
   ============================================================ */

/* -------------------------------------------------------
   GLOBAL: Prevent horizontal overflow that causes left-shift
   ------------------------------------------------------- */
html, body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
}

/* Ensure container is always centred */
.container {
  width: 100%;
  box-sizing: border-box;
}

/* -------------------------------------------------------
   HERO: Centre all text and elements on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #hero {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100svh;
    padding: 7rem 0 5rem;
  }

  .hero-content {
    text-align: center;
    width: 100%;
    padding: 0 1.5rem;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-tagline {
    text-align: center;
    width: 100%;
  }

  .hero-title {
    text-align: center;
    width: 100%;
  }

  .hero-subtitle {
    text-align: center;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 1rem;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
    max-width: 300px;
    justify-content: center;
    box-sizing: border-box;
  }

  /* Scroll indicator centred */
  .scroll-indicator {
    left: 50%;
    transform: translateX(-50%);
  }
}

/* -------------------------------------------------------
   ABOUT: Centre content on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #about {
    text-align: center;
  }

  .about-content {
    text-align: center;
  }

  .about-content .section-title::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .about-content p {
    text-align: center;
  }

  .about-description {
    text-align: center;
  }

  .about-features {
    align-items: flex-start;
    text-align: left;
    width: 100%;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
  }

  .about-feature-item {
    text-align: left;
    align-items: flex-start;
  }

  .about-feature-item > div:last-child {
    text-align: left;
  }
}

/* -------------------------------------------------------
   SERVICES: Centre tabs and menu on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #services {
    text-align: center;
  }

  .services-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding: 0.5rem 1rem 0.75rem;
    gap: 0.5rem;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    box-sizing: border-box;
  }

  .services-tabs::-webkit-scrollbar {
    display: none;
  }

  .tab-btn {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 10px 18px;
    font-size: 0.82rem;
  }

  .pricing-menu {
    width: 100%;
    box-sizing: border-box;
    margin: 0 auto;
    padding: 2rem 1.25rem;
    border-radius: 16px;
  }

  .pricing-item {
    flex-wrap: wrap;
    gap: 0.2rem;
  }

  .pricing-name {
    font-size: 1rem;
    flex: 1 1 auto;
    min-width: 0;
  }

  .pricing-price {
    font-size: 1rem;
    flex-shrink: 0;
    margin-left: auto;
  }

  .pricing-dots {
    display: none;
  }
}

/* -------------------------------------------------------
   PACKAGES: Centre on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #packages {
    text-align: center;
  }

  .packages-grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    box-sizing: border-box;
    padding: 0;
  }

  .package-card {
    width: 100%;
    box-sizing: border-box;
  }

  .package-card.featured {
    transform: none;
  }

  .package-card.featured:hover {
    transform: translateY(-8px);
  }

  .package-header {
    padding: 1.5rem;
  }

  .package-features {
    padding: 1.5rem;
  }

  .package-cta {
    width: calc(100% - 3rem);
    margin: 0 1.5rem 1.5rem;
  }
}

/* -------------------------------------------------------
   WHY CHOOSE / STATS: Centre on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #why-choose {
    text-align: center;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    width: 100%;
    box-sizing: border-box;
  }

  .stat-card {
    padding: 1.5rem 1rem;
    width: 100%;
    box-sizing: border-box;
  }
}

/* -------------------------------------------------------
   GALLERY: Centre on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #gallery {
    text-align: center;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 180px;
    gap: 0.4rem;
    width: 100%;
    box-sizing: border-box;
    margin-top: 2rem;
  }

  .gallery-item:nth-child(1) {
    grid-column: span 2;
    grid-row: span 1;
  }
}

/* -------------------------------------------------------
   BOOKING: Centre form and info on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #booking {
    text-align: center;
  }

  .booking-wrapper {
    grid-template-columns: 1fr;
    gap: 2rem;
    width: 100%;
    box-sizing: border-box;
  }

  .booking-info {
    text-align: center;
  }

  .booking-info .section-subtitle,
  .booking-info .section-title,
  .booking-description {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }

  .booking-info .section-title::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .booking-highlights {
    align-items: center;
    width: 100%;
  }

  .booking-highlight-item {
    flex-direction: row;
    text-align: left;
    justify-content: flex-start;
    max-width: 360px;
    margin: 0 auto;
    gap: 0.8rem;
  }

  .booking-highlight-item > div:last-child {
    text-align: left;
  }

  .booking-form-wrapper {
    width: 100%;
    box-sizing: border-box;
  }

  .booking-form {
    padding: 1.75rem 1.25rem;
    width: 100%;
    box-sizing: border-box;
    border-radius: 16px;
  }

  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .booking-submit {
    font-size: 1rem;
    padding: 16px;
  }
}

/* -------------------------------------------------------
   CONTACT: Centre on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  #contact {
    text-align: center;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    width: 100%;
    box-sizing: border-box;
  }

  .contact-info {
    width: 100%;
  }

  .contact-item {
    text-align: left;
    justify-content: flex-start;
    max-width: 460px;
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
  }

  .contact-map {
    height: 280px;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
  }
}

/* -------------------------------------------------------
   FOOTER: Centre on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    width: 100%;
    box-sizing: border-box;
  }

  .footer-about {
    grid-column: span 2;
    text-align: center;
  }

  .footer-about p {
    margin-left: auto;
    margin-right: auto;
  }

  .footer-social {
    justify-content: center;
  }

  .footer-links {
    text-align: left;
  }

  .footer-bottom {
    text-align: center;
    font-size: 0.8rem;
    padding: 1.5rem 0 0.5rem;
    word-break: break-word;
  }
}

/* -------------------------------------------------------
   SMALL MOBILE (≤480px): Full single-column centred layout
   ------------------------------------------------------- */
@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
  }

  #hero {
    padding: 6rem 0 4rem;
  }

  .hero-content {
    padding: 0 1rem;
  }

  .hero-title {
    font-size: clamp(1.65rem, 8vw, 2.2rem);
    line-height: 1.15;
  }

  .hero-tagline {
    font-size: 0.68rem;
    letter-spacing: 2px;
  }

  .hero-subtitle {
    font-size: 0.92rem;
  }

  .btn-primary,
  .btn-secondary {
    max-width: 100%;
    font-size: 0.9rem;
  }

  /* Stats: 2-col even on small screens */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  .stat-number {
    font-size: 2.2rem;
  }

  /* Gallery: single column */
  .gallery-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 200px;
  }

  .gallery-item:nth-child(1) {
    grid-column: span 1;
  }

  /* Footer: single column */
  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-about {
    grid-column: span 1;
  }

  .footer-links {
    text-align: center;
  }

  .footer-links a:hover {
    transform: none;
  }

  /* Packages price */
  .price-current {
    font-size: 2.2rem;
  }

  /* Nav */
  #navbar {
    padding: 0.9rem 0;
  }

  .nav-container {
    padding: 0 1rem;
  }

  .nav-logo {
    height: 48px;
  }

  .nav-cta {
    font-size: 0.78rem !important;
    padding: 8px 14px !important;
  }

  /* Mobile menu links */
  .mobile-menu a {
    font-size: 1.3rem;
  }

  /* Contact */
  .contact-map {
    height: 240px;
  }

  .contact-item {
    gap: 0.8rem;
  }

  /* Floating buttons */
  .floating-buttons {
    bottom: 1rem;
    right: 1rem;
    gap: 0;
  }

  .float-btn {
    width: 50px;
    height: 50px;
  }

  .float-whatsapp {
    margin-bottom: 0.75rem;
  }

  /* Back to top */
  .back-to-top {
    left: 1rem;
    bottom: 1rem;
    width: 42px;
    height: 42px;
  }

  /* Booking form */
  .booking-form {
    padding: 1.25rem 1rem;
  }

  .form-group input,
  .form-group select {
    padding: 13px 14px;
    font-size: 0.95rem;
  }

  /* Preloader */
  #preloader .preloader-logo {
    font-size: 1.7rem;
  }

  /* Package tag positioning fix */
  .package-card.featured::before {
    right: -28px;
    font-size: 0.7rem;
    padding: 5px 36px;
  }
}

/* -------------------------------------------------------
   SECTION HEADINGS: Always centred in section context
   ------------------------------------------------------- */
@media (max-width: 768px) {
  .text-center .section-title::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .section-description {
    padding: 0 0.5rem;
    font-size: 0.93rem;
  }

  /* Section padding reduction for tighter mobile feel */
  #services,
  #packages,
  #why-choose,
  #gallery,
  #contact {
    padding: 60px 0;
  }

  #about {
    padding: 60px 0;
  }
}

/* -------------------------------------------------------
   NAV LOGO: Prevent overflow on very small screens
   ------------------------------------------------------- */
@media (max-width: 360px) {
  .nav-logo {
    height: 40px;
  }

  .nav-cta {
    font-size: 0.72rem !important;
    padding: 7px 10px !important;
  }

  .container {
    padding: 0 0.75rem;
  }

  .hero-title {
    font-size: 1.6rem;
  }
}

/* -------------------------------------------------------
   PRELOADER: Centred
   ------------------------------------------------------- */
#preloader {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  width: 100%;
}

.preloader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

/* -------------------------------------------------------
   SCROLL INDICATOR: Always centred
   ------------------------------------------------------- */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  z-index: 3;
}

.scroll-mouse {
  width: 26px;
  height: 40px;
  border: 2px solid rgba(212, 175, 55, 0.6);
  border-radius: 13px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 6px;
}

.scroll-wheel {
  width: 4px;
  height: 8px;
  background: var(--gold, #D4AF37);
  border-radius: 2px;
  animation: scrollWheel 1.8s ease infinite;
}

@keyframes scrollWheel {
  0%   { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(10px); }
}

/* -------------------------------------------------------
   PACKAGE BADGE: Fix ribbon overflow on small screens
   ------------------------------------------------------- */
.package-card {
  overflow: hidden;
  position: relative;
}

.package-badge {
  display: none;
}

.package-card.featured::before {
  content: 'POPULAR';
  position: absolute;
  top: 18px;
  right: -32px;
  background: var(--gold, #D4AF37);
  color: #1A1A1A;
  padding: 5px 40px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 2px;
  transform: rotate(45deg);
  z-index: 3;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  white-space: nowrap;
}

/* -------------------------------------------------------
   PRICING: Hide dots on very narrow screens, show flex price
   ------------------------------------------------------- */
@media (max-width: 420px) {
  .pricing-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 1.2rem;
    border-bottom: 1px solid rgba(212,175,55,0.08);
    padding-bottom: 1.2rem;
  }

  .pricing-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
  }

  .pricing-dots {
    display: none;
  }

  .pricing-name {
    font-size: 0.95rem;
    color: var(--text-light, #F8F5F0);
    flex: 1;
    min-width: 0;
    font-family: var(--font-heading, 'Playfair Display', serif);
  }

  .pricing-price {
    font-size: 0.95rem;
    color: var(--gold, #D4AF37);
    font-weight: 600;
    margin-left: 0;
    white-space: nowrap;
    font-family: var(--font-heading, 'Playfair Display', serif);
  }
}

/* -------------------------------------------------------
   ABOUT IMAGE BADGE: Prevent overflow on small screens
   ------------------------------------------------------- */
@media (max-width: 480px) {
  .about-image-badge {
    bottom: -12px;
    right: -8px;
    padding: 1rem;
  }

  .badge-number {
    font-size: 2rem;
  }

  .badge-text {
    font-size: 0.72rem;
  }
}

/* -------------------------------------------------------
   TESTIMONIALS: Fix card width on mobile
   ------------------------------------------------------- */
@media (max-width: 768px) {
  .testimonials-carousel {
    overflow: hidden;
    width: 100%;
  }

  .testimonials-track {
    width: 100%;
  }

  .testimonial-card {
    min-width: 100%;
    padding: 0.4rem;
    box-sizing: border-box;
  }
}

/* -------------------------------------------------------
   FORM ACCESSIBILITY: Ensure selects are styled consistently
   ------------------------------------------------------- */
.form-group select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* Fix date input on iOS */
input[type="date"] {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  min-height: 50px;
}