/**
 * Jawhara Establishment Luxury Website - Responsive CSS
 * مؤسسة جوهرة للمقاولات والتشطيبات الفاخرة — استعلامات التجاوب لكافة الشاشات
 */

/* ==========================================================================
   Global Overflow & Mobile Protections
   ========================================================================== */
html, body {
  overflow-x: clip;
}

/* ==========================================================================
   Breakpoint: Extra Large Screens & 4K Displays (>= 1440px and 2560px)
   ========================================================================== */
@media (min-width: 1440px) {
  .container {
    max-width: var(--container-max);
  }
}

@media (min-width: 2560px) {
  .container {
    max-width: 1600px;
  }
  
  body {
    font-size: 1.125rem;
  }
}

/* ==========================================================================
   Breakpoint: Desktops & Laptops (1024px - 1439px)
   ========================================================================== */
@media (max-width: 1200px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

/* ==========================================================================
   Breakpoint: Small Desktops & Tablets Landscape (<= 1024px)
   ========================================================================== */
@media (max-width: 1024px) {
  .nav-desktop,
  .header-actions .btn-whatsapp-desktop {
    display: none;
  }

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

  .calc-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .journey-timeline::before {
    inset-inline-start: 22px;
  }

  .journey-step-marker {
    width: 46px;
    height: 46px;
    font-size: 1.15rem;
  }

  .journey-step-card {
    gap: 1.25rem;
  }
}

/* ==========================================================================
   Breakpoint: Tablets Portrait (<= 768px)
   ========================================================================== */
@media (max-width: 768px) {
  :root {
    --header-height: 70px;
  }

  body {
    padding-bottom: var(--mobile-bar-height);
  }

  .mobile-floating-bar {
    display: block;
  }

  .hero-section {
    min-height: auto;
    padding-top: calc(var(--header-height) + 2rem);
    padding-bottom: 3.5rem;
    text-align: center;
  }

  .hero-content {
    margin-inline: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-highlights {
    grid-template-columns: 1fr 1fr;
  }

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

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

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

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom-bar {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .calc-area-inputs {
    flex-direction: column;
    align-items: stretch;
  }

  .calc-number-input {
    width: 100%;
  }

  .booking-form-box {
    width: 100%;
  }

  .booking-form {
    padding: 1.25rem;
  }

  .before-after-box {
    padding: 1rem;
  }

  .before-after-tag {
    bottom: 0.75rem;
    padding: 0.25rem 0.65rem;
    font-size: var(--font-size-xs);
  }

  .tag-before {
    left: 0.75rem;
  }

  .tag-after {
    right: 0.75rem;
  }
}

/* ==========================================================================
   Breakpoint: Mobile Phones (320px - 480px)
   ========================================================================== */
@media (max-width: 480px) {
  :root {
    --container-pad: 1rem;
  }

  .brand-name {
    font-size: 1.1rem;
  }

  .brand-sub {
    font-size: 0.65rem;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-highlights {
    grid-template-columns: 1fr;
  }

  .btn {
    width: 100%;
  }

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

  .gallery-filter-tabs {
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
  }

  .gallery-tab-btn {
    flex-shrink: 0;
  }

  .calc-service-options {
    grid-template-columns: 1fr 1fr;
  }

  .modal-header {
    padding: 1rem 1.25rem;
  }
}

/* 320px ultra-small screens */
@media (max-width: 320px) {
  body {
    font-size: 0.9375rem;
  }

  .calc-service-options {
    grid-template-columns: 1fr;
  }
}
