/* ══════════════════════════════════════════════════════════════
   responsive.css — Master Responsive System (Phone & Tablet Tuning)
   Engineered for Pixel-Perfect Fluid Scaling & Native Touch Feel
   ══════════════════════════════════════════════════════════════ */

/* ── Global Viewport Protection (Eliminates Horizontal Jitter) ── */
html,
body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden !important;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

/* ── Section Scroll Anchors Margin (Guarantees clearance below fixed navbar) ── */
#hero-section,
#brands-section,
#projects-section,
#designs-section,
#services,
#testimonials-section,
#contact-section {
  scroll-margin-top: 75px !important;
}

/* ══════════════════════════════════════════════════════════════
   1. TABLET FLOATING NAVBAR (min-width: 601px) and (max-width: 1080px)
   Strictly scoped to tablets — Never executes on mobile phones
   ══════════════════════════════════════════════════════════════ */
@media (min-width: 601px) and (max-width: 1080px) {

  /* ── Floating Pill Navbar for Tablet (80% Width, Logo Left, Links Middle, Buttons Right in ALL Languages) ── */
  #navbar,
  body.lang-ar #navbar,
  html[dir="rtl"] #navbar,
  html.lang-ar #navbar {
    position: fixed !important;
    top: 14px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 80% !important;
    max-width: 80% !important;
    height: 48px !important;
    padding: 0 16px !important;
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    direction: ltr !important;
    border-radius: 999px !important;
    box-shadow: 0 4px 16px rgba(7, 25, 27, 0.08) !important;
    z-index: 1000 !important;
    box-sizing: border-box !important;
    pointer-events: auto !important;
  }

  body.dark #navbar {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4) !important;
  }

  /* Logo strictly on the LEFT */
  .nav-logo,
  body.lang-ar .nav-logo,
  html[dir="rtl"] .nav-logo,
  html.lang-ar .nav-logo {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    flex-shrink: 0 !important;
    order: 1 !important;
    margin: 0 !important;
    padding: 0 !important;
    pointer-events: auto !important;
  }

  #site-logo {
    width: 24px !important;
    height: 24px !important;
    display: block !important;
    object-fit: contain !important;
    pointer-events: auto !important;
  }

  /* Show navigation sections centered in the MIDDLE between Logo and Actions */
  .nav-links,
  body.lang-ar .nav-links,
  html[dir="rtl"] .nav-links,
  html.lang-ar .nav-links {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 1 1 auto !important;
    gap: clamp(8px, 1.6vw, 18px) !important;
    list-style: none !important;
    margin: 0 auto !important;
    padding: 0 10px !important;
    order: 2 !important;
    pointer-events: auto !important;
  }

  .nav-links li {
    display: inline-flex !important;
    align-items: center !important;
    pointer-events: auto !important;
  }

  .nav-links li.nav-item-dropdown {
    position: relative !important;
  }

  .nav-links a {
    display: inline-flex !important;
    align-items: center !important;
    font-size: clamp(11.5px, 1.35vw, 13px) !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
    padding: 8px 6px !important;
    cursor: pointer !important;
    pointer-events: auto !important;
    touch-action: manipulation !important;
    text-decoration: none !important;
    -webkit-tap-highlight-color: transparent !important;
  }

  .nav-dropdown-menu {
    z-index: 1005 !important;
  }

  .nav-item-dropdown.open .nav-dropdown-arrow {
    transform: rotate(180deg) !important;
  }

  .nav-item-dropdown.open .nav-dropdown-menu {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: all !important;
    transform: translateX(-50%) translateY(0) !important;
  }

  .nav-dropdown-menu a {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 9px 14px !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    border-radius: 10px !important;
    white-space: nowrap !important;
    touch-action: manipulation !important;
  }

  /* Buttons (Theme Mode + Language Switcher) strictly on the RIGHT */
  .nav-actions,
  body.lang-ar .nav-actions,
  html[dir="rtl"] .nav-actions,
  html.lang-ar .nav-actions {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
    order: 3 !important;
    flex-shrink: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    direction: ltr !important;
    pointer-events: auto !important;
  }

  .theme-btn,
  .lang-btn {
    width: 36px !important;
    height: 36px !important;
    border-radius: 50% !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    pointer-events: auto !important;
    cursor: pointer !important;
  }

  .lang-dropdown {
    right: 0 !important;
    left: auto !important;
    pointer-events: auto !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   1B. GENERAL LAPTOPS & TABLETS (max-width: 1080px)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 1080px) {

  /* Designs Mosaic: Handled with precision in designs.css for tablet (3 columns) and mobile (2 columns iOS style) */
  .designs-mosaic-wrapper {
    overflow: visible !important;
    margin-top: 0 !important;
  }

  .design-pill-img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  /* Services Grid (Tablet & Phone): 2 columns with Speed & Diversity spanning 2 columns (بعرض بطاقتين) without gaps */
  .expertise-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 18px !important;
  }

  .exp-card-affordability { order: 1 !important; grid-column: span 1 !important; }
  .exp-card-consistency   { order: 2 !important; grid-column: span 1 !important; }
  .exp-card-speed         { order: 3 !important; grid-column: span 2 !important; }
  .exp-card-scalability   { order: 4 !important; grid-column: span 1 !important; }
  .exp-card-flexibility   { order: 5 !important; grid-column: span 1 !important; }
  .exp-card-diversity     { order: 6 !important; grid-column: span 2 !important; }
  .exp-card-support       { order: 7 !important; grid-column: span 1 !important; }
  .exp-card-convenience   { order: 8 !important; grid-column: span 1 !important; }

  /* Slightly raise hero role and heading on tablets */
  .hero-role,
  body.lang-ar .hero-role,
  html[dir="rtl"] .hero-role {
    transform: translateY(-16px) !important;
    margin-bottom: 26px !important;
  }

  h1,
  body.lang-ar h1,
  html[dir="rtl"] h1 {
    transform: translateY(-14px) !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   2. TABLETS & PHABLETS (max-width: 900px)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {

  /* ── Hero Section Architecture (Phone & Tablet: Unified Vertical Narrative) ── */
  #hero-section {
    position: relative !important;
    height: auto !important;
    min-height: 100vh !important;
    padding: 96px 18px 48px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  /* Hide background ghost icons on mobile to prevent visual noise */
  .logo-float-container {
    display: none !important;
  }

  #hero-content {
    display: contents !important;
  }

  .hero-left,
  .hero-right {
    display: contents !important;
  }

  /* 1. Hero Role (Balanced height with safe margin above hero name and header) */
  .hero-role {
    order: 1 !important;
    position: relative !important;
    z-index: 10 !important;
    width: 100% !important;
    max-width: 460px !important;
    text-align: center !important;
    margin: 8px 0 28px 0 !important;
    transform: translateY(-24px) !important;
    padding: 0 !important;
    font-size: clamp(12.5px, 3.4vw, 14.5px) !important;
    font-weight: 600 !important;
    letter-spacing: 0.04em !important;
    color: var(--muted) !important;
  }

  body.lang-ar .hero-role,
  html[dir="rtl"] .hero-role {
    margin: 8px 0 28px 0 !important;
    transform: translateY(-24px) !important;
    text-align: center !important;
    font-size: clamp(14px, 3.8vw, 16px) !important;
  }

  /* 2. Hero Name in ONE SINGLE LINE (Enlarged and Prominent — Lifted up prominently for phone and tablet) */
  h1 {
    order: 2 !important;
    position: relative !important;
    z-index: 10 !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: -18px 0 0 0 !important;
    transform: translateY(-28px) !important;
    padding: 0 4px !important;
    text-align: center !important;
    white-space: nowrap !important;
    font-size: clamp(20px, 5.8vw, 34px) !important;
    line-height: 1.25 !important;
    letter-spacing: -0.025em !important;
    box-sizing: border-box !important;
  }

  body.lang-en h1,
  body.lang-fr h1,
  html:not(.lang-ar) h1 {
    font-size: clamp(20px, 5.8vw, 34px) !important;
    letter-spacing: -0.025em !important;
  }

  body.lang-en h1 .hero-last,
  body.lang-fr h1 .hero-last {
    letter-spacing: 0 !important;
  }

  h1 br {
    display: none !important;
  }

  h1 em,
  h1 .hero-last {
    display: inline !important;
    font-size: 1em !important;
    margin: 0 !important;
  }

  body.lang-ar h1,
  html[dir="rtl"] h1 {
    margin: -18px 0 0 0 !important;
    transform: translateY(-28px) !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
    text-align: center !important;
    direction: rtl !important;
    white-space: nowrap !important;
    font-size: clamp(28px, 7.8vw, 42px) !important;
    letter-spacing: 0 !important;
  }

  /* 3. The 3D Canvas / Portrait Image (Enlarged & Overlapping under the two top phrases) */
  #scene {
    order: 3 !important;
    position: relative !important;
    inset: auto !important;
    width: 100% !important;
    max-width: 500px !important;
    height: clamp(380px, 50vh, 500px) !important;
    margin: -75px auto 10px auto !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    pointer-events: all !important;
    opacity: 1 !important;
    transform: none !important;
    z-index: 2 !important;
  }

  #scene canvas {
    width: 100% !important;
    height: 100% !important;
    display: block !important;
    touch-action: pan-y !important;
  }

  /* 4. Description / Bio */
  .hero-bio {
    order: 4 !important;
    width: 100% !important;
    max-width: 440px !important;
    margin: 0 auto 16px auto !important;
    padding: 0 8px !important;
    font-size: 13.5px !important;
    line-height: 1.68 !important;
    text-align: center !important;
    color: var(--muted) !important;
    box-sizing: border-box !important;
  }

  body.lang-ar .hero-bio,
  html[dir="rtl"] .hero-bio {
    text-align: center !important;
    direction: rtl !important;
    font-size: 14px !important;
    line-height: 1.74 !important;
  }

  /* 5. Badges / Tags (Kept in ONE SINGLE LINE on mobile and tablet) */
  .hero-tags {
    order: 5 !important;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 6px !important;
    width: 100% !important;
    max-width: 440px !important;
    margin: 0 auto 16px auto !important;
    padding: 0 4px !important;
    box-sizing: border-box !important;
  }

  .hero-tags .tag-chip {
    font-size: clamp(9.5px, 2.75vw, 11.5px) !important;
    padding: 5px clamp(6px, 1.8vw, 12px) !important;
    border-radius: 99px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }

  /* 6. Stats (Clean & Transparent without Card/Container Background) */
  .hero-stats {
    order: 6 !important;
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-around !important;
    align-items: center !important;
    width: 100% !important;
    max-width: 440px !important;
    margin: 0 auto 20px auto !important;
    padding: 6px 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border-radius: 0 !important;
    box-sizing: border-box !important;
  }

  body:not(.dark) .hero-stats,
  body.dark .hero-stats {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }

  .stat-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    flex: 1 1 0 !important;
  }

  .stat-num {
    font-size: clamp(26px, 6.8vw, 32px) !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
  }

  .stat-label {
    font-size: 11.5px !important;
    margin-top: 4px !important;
    text-align: center !important;
  }

  /* 7. Action Buttons (Two Buttons) */
  .hero-actions {
    order: 7 !important;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 400px !important;
    margin: 0 auto 22px auto !important;
    padding: 0 4px !important;
    box-sizing: border-box !important;
  }

  .hero-actions .btn-primary,
  .hero-actions .btn-ghost {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    padding: 10px 14px !important;
    font-size: 13px !important;
    border-radius: 99px !important;
    text-align: center !important;
    justify-content: center !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
  }

  /* 8. Social Media Buttons */
  .hero-socials {
    order: 8 !important;
    display: flex !important;
    flex-direction: row !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 440px !important;
    margin: 0 auto !important;
    padding: 0 !important;
  }

  .social-link {
    width: 40px !important;
    height: 40px !important;
  }

  /* ── Featured Projects Section (Tablet) ── */
  #projects-section {
    padding: 40px 20px 48px !important;
  }

  .projects-bento-grid {
    grid-template-columns: 1fr !important;
    gap: 22px !important;
  }

  .pcard,
  .pcard-hero-wide,
  .pcard-medium {
    grid-column: span 1 !important;
    width: 100% !important;
  }

  .pcard-visual {
    height: clamp(220px, 45vw, 320px) !important;
  }

  /* ── Testimonials Section (Tablet: 2*2 Bento Cards & Centered Info) ── */
  #testimonials-section {
    padding: 40px 20px 48px !important;
  }

  .testimonials-layout {
    grid-template-columns: 1fr !important;
    gap: 36px !important;
  }

  .testi-info-col,
  .testi-top-group {
    align-items: center !important;
    text-align: center !important;
    width: 100% !important;
  }

  .testi-badge-pill {
    margin-left: auto !important;
    margin-right: auto !important;
  }

  .testi-title {
    text-align: center !important;
    width: 100% !important;
  }

  .testi-desc {
    text-align: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
    max-width: 520px !important;
    width: 100% !important;
  }

  .testi-cta-btn {
    margin-left: auto !important;
    margin-right: auto !important;
  }

  /* Tablet: 2*2 Testimonials Grid (641px to 1080px) */
  .testi-cards-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px !important;
  }

  /* ── Contact Section (Tablet: Identical to Desktop Layout) ── */
  #contact-section {
    position: relative !important;
    max-width: 1240px !important;
    margin: 0 auto !important;
    padding: 48px 24px 44px !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 560px !important;
  }

  .contact-inner {
    position: relative !important;
    z-index: 2 !important;
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    flex: 1 1 auto !important;
    text-align: start !important;
  }

  .contact-cols {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 24px !important;
    max-width: 760px !important;
    margin-bottom: 24px !important;
  }

  .contact-col {
    align-items: flex-start !important;
    text-align: start !important;
  }

  .contact-col-head {
    justify-content: flex-start !important;
  }

  .contact-form-area {
    max-width: 580px !important;
    align-items: flex-start !important;
    margin-top: auto !important;
    margin-bottom: 0 !important;
    padding-top: 24px !important;
  }

  .contact-map-layer {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 50% !important;
    z-index: 1 !important;
    display: block !important;
    opacity: 0.65 !important;
    pointer-events: none !important;
  }

  .contact-step:not(.contact-step--hidden) {
    display: flex !important;
    flex-direction: row !important;
    align-items: flex-end !important;
    gap: 16px !important;
    width: 100% !important;
  }

  .contact-step--hidden,
  .contact-step.contact-step--hidden {
    display: none !important;
  }

  .contact-ghost-wrap {
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }

  .contact-circle-btn {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px !important;
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    flex-shrink: 0 !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    align-self: flex-end !important;
  }

  .contact-circle-icon {
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    min-height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
    border-radius: 50% !important;
    aspect-ratio: 1 / 1 !important;
    flex-shrink: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
  }

  /* ── Footer (Tablet) ── */
  .site-footer {
    padding: 32px 16px 28px !important;
  }

  .footer-card {
    padding: 32px 24px 28px !important;
    border-radius: 0 !important;
  }

  .footer-columns-wrap {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 24px 32px !important;
    width: 100% !important;
  }

  .footer-col-item:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }

  .footer-col-item:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 / span 2 !important;
  }

  .footer-col-item:nth-child(3) {
    grid-column: 1 !important;
    grid-row: 2 !important;
    margin-top: 6px !important;
  }

  .footer-card-middle {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }

  .footer-location-tag,
  .footer-phone-tag,
  .footer-giant-email {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }

  /* ── Floating Scroll-to-Top Button strictly on the right in Tablet ── */
  .scroll-to-top-btn,
  body.lang-ar .scroll-to-top-btn,
  html[dir="rtl"] .scroll-to-top-btn {
    right: 24px !important;
    left: auto !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   3. MOBILE PHONES ONLY (max-width: 600px)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  #navbar {
    position: fixed !important;
    top: 12px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 80% !important;
    max-width: 80% !important;
    height: 48px !important;
    padding: 0 14px !important;
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    direction: ltr !important;
    box-sizing: border-box !important;
    border-radius: 999px !important;
    box-shadow: 0 4px 14px rgba(7, 25, 27, 0.08) !important;
    z-index: 1000 !important;
  }

  body.dark #navbar {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4) !important;
  }

  /* Hide navigation sections on Phone only across ALL languages and states */
  .nav-links,
  body.lang-ar .nav-links,
  html[dir="rtl"] .nav-links,
  html.lang-ar .nav-links,
  #navbar .nav-links,
  body #navbar .nav-links,
  html body #navbar .nav-links {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
  }

  .nav-logo {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    order: 1 !important;
    flex-shrink: 0 !important;
  }

  #site-logo {
    width: 24px !important;
    height: 24px !important;
    display: block !important;
  }

  .nav-actions {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
    order: 2 !important;
    flex-shrink: 0 !important;
  }

  .theme-btn,
  .lang-btn {
    width: 36px !important;
    height: 36px !important;
    border-radius: 50% !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .lang-dropdown {
    top: 54px !important;
    min-width: 130px !important;
    border-radius: 14px !important;
    right: 0 !important;
    left: auto !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   4. GENERAL TABLET & MOBILE TUNING (max-width: 768px)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* ── Hero Buttons on Mobile (Compact & Strictly Single Row) ── */
  .hero-actions {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
    max-width: 360px !important;
    margin: 0 auto 20px auto !important;
    padding: 0 8px !important;
    box-sizing: border-box !important;
  }

  .hero-actions .btn-primary,
  .hero-actions .btn-ghost {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 9px 12px !important;
    font-size: 12px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
    border-radius: 99px !important;
    text-align: center !important;
    box-sizing: border-box !important;
  }

  .hero-actions .btn-ghost svg {
    width: 12px !important;
    height: 12px !important;
    flex-shrink: 0 !important;
  }

  /* ── Brands Section Mobile Tuning ── */
  #brands-section {
    padding: 32px 14px 40px !important;
  }

  .brands-title {
    font-size: clamp(24px, 6vw, 32px) !important;
    margin-bottom: 20px !important;
  }

  .brands-vertical-stage {
    padding: 14px 6px !important;
    border-radius: 20px !important;
  }

  .brands-grid-row {
    gap: 10px !important;
  }

  .brand-card {
    height: 70px !important;
    padding: 8px 10px !important;
    border-radius: 14px !important;
  }

  .brand-card img {
    max-height: 34px !important;
  }

  /* Disable cursor hover tooltip on touch screens */
  #brand-popup {
    display: none !important;
  }

  /* ── Designs Section Mobile (2 Columns iOS Style Staggered Feed) ── */
  #designs-section {
    padding: 36px 12px 46px !important;
  }

  /* ── Fullscreen Project Details Drawer (Mobile Modal) ── */
  .pmodal-backdrop {
    padding: 0 !important;
    align-items: flex-end !important;
  }

  .pmodal-box {
    width: 100vw !important;
    height: 100vh !important;
    max-height: 100vh !important;
    max-width: 100vw !important;
    border-radius: 0 !important;
    border: none !important;
  }

  .pmodal-close-btn {
    top: 14px !important;
    right: 14px !important;
    width: 44px !important;
    height: 44px !important;
    border-radius: 50% !important;
    z-index: 100 !important;
  }

  .pmodal-body {
    padding: 20px 16px 80px !important;
    -webkit-overflow-scrolling: touch !important;
  }

  .pmodal-banner-wrap {
    height: 190px !important;
    border-radius: 16px !important;
    margin-bottom: 22px !important;
  }

  .pmodal-title {
    font-size: 24px !important;
    line-height: 1.2 !important;
  }

  .pmodal-tagline {
    font-size: 14px !important;
    margin-bottom: 20px !important;
  }

  .pmodal-specs-grid {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  .pmodal-spec-card {
    padding: 16px 14px !important;
    border-radius: 14px !important;
  }

  /* Mockup carousels adjusted for mobile thumbs */
  .pmodal-mockups-carousel {
    padding: 10px 4px !important;
    margin-bottom: 24px !important;
  }

  .pmodal-mockups-track {
    height: 380px !important;
    gap: 14px !important;
  }

  .phone-mockup-frame {
    width: 175px !important;
    scroll-snap-align: center;
  }

  .desktop-mockup-frame {
    width: 280px !important;
    scroll-snap-align: center;
  }

  /* ── Testimonials Grid: 1 Column ONLY on Mobile (Phone Mode: <= 640px) ── */
  @media (max-width: 640px) {
    .testi-cards-grid {
      grid-template-columns: 1fr !important;
      gap: 14px !important;
    }

    .testi-info-col,
    .testi-top-group {
      align-items: center !important;
      text-align: center !important;
    }

    .testi-title {
      text-align: center !important;
    }

    .testi-desc {
      text-align: center !important;
      margin-left: auto !important;
      margin-right: auto !important;
    }

    /* ── Contact Section Mobile Phone (<= 640px): Map Cover Background, Centered Title, Right-Aligned Data, Open Area for Pin, Stepped Form Below ── */
    #contact-section {
      position: relative !important;
      width: 100% !important;
      padding: 38px 18px 36px !important;
      box-sizing: border-box !important;
      overflow: hidden !important;
      display: flex !important;
      flex-direction: column !important;
      min-height: 590px !important;
    }

    /* 1. Map Cover Layer in the Background */
    .contact-map-layer {
      position: absolute !important;
      inset: 0 !important;
      top: 0 !important;
      left: 0 !important;
      right: 0 !important;
      bottom: 0 !important;
      width: 100% !important;
      height: 100% !important;
      z-index: 1 !important;
      display: block !important;
      pointer-events: none !important;
      -webkit-mask-image: none !important;
      mask-image: none !important;
      border-radius: 0 !important;
      border: none !important;
      box-shadow: none !important;
      margin: 0 !important;
      opacity: 0.58 !important;
    }

    body.dark .contact-map-layer {
      opacity: 0.72 !important;
      border: none !important;
      box-shadow: none !important;
    }

    /* 2. Inner Content on Top of Map */
    .contact-inner {
      position: relative !important;
      z-index: 2 !important;
      width: 100% !important;
      display: flex !important;
      flex-direction: column !important;
      align-items: stretch !important;
      flex: 1 1 auto !important;
      margin: 0 auto !important;
    }

    /* 3. Badge & Title Centered */
    .contact-top-row {
      display: flex !important;
      justify-content: center !important;
      align-items: center !important;
      width: 100% !important;
      margin-bottom: 8px !important;
    }

    .contact-badge-pill {
      margin: 0 auto 14px auto !important;
      text-align: center !important;
    }

    .contact-big-title {
      text-align: center !important;
      width: 100% !important;
      margin: 0 auto 24px auto !important;
      font-size: clamp(2.1rem, 7.5vw, 2.7rem) !important;
    }

    /* 4. Data on the Left, Leaving Right Empty for Location Coordinates/Pin */
    .contact-cols {
      display: flex !important;
      flex-direction: column !important;
      align-items: flex-start !important;
      text-align: left !important;
      width: 52% !important;
      max-width: 200px !important;
      margin-left: 0 !important;
      margin-right: auto !important;
      gap: 16px !important;
      margin-bottom: 30px !important;
      min-height: 175px !important;
      box-sizing: border-box !important;
      padding: 10px 0 10px 4px !important;
    }

    body.lang-ar .contact-cols,
    html[dir="rtl"] .contact-cols {
      align-items: flex-start !important;
      text-align: left !important;
      margin-left: 0 !important;
      margin-right: auto !important;
      padding: 10px 0 10px 4px !important;
    }

    .contact-col {
      display: flex !important;
      flex-direction: column !important;
      align-items: flex-start !important;
      text-align: left !important;
      width: 100% !important;
      gap: 4px !important;
    }

    body.lang-ar .contact-col,
    html[dir="rtl"] .contact-col {
      align-items: flex-start !important;
      text-align: left !important;
    }

    .contact-col-head {
      display: flex !important;
      justify-content: flex-start !important;
      align-items: center !important;
      gap: 6px !important;
      text-align: left !important;
      width: 100% !important;
      font-size: 11px !important;
      color: #334155 !important;
    }

    body.lang-ar .contact-col-head,
    html[dir="rtl"] .contact-col-head {
      text-align: left !important;
      justify-content: flex-start !important;
    }

    body.dark .contact-col-head {
      color: #cbd5e1 !important;
    }

    .contact-col-val {
      text-align: left !important;
      width: 100% !important;
      font-size: 13.5px !important;
      line-height: 1.45 !important;
      color: #07191b !important;
      font-weight: 600 !important;
      text-shadow: 0 1px 6px rgba(255, 255, 255, 0.8) !important;
    }

    body.lang-ar .contact-col-val,
    html[dir="rtl"] .contact-col-val {
      text-align: left !important;
    }

    body.lang-ar .contact-col-val[href^="tel"],
    html[dir="rtl"] .contact-col-val[href^="tel"] {
      direction: ltr !important;
      text-align: left !important;
      display: inline-block !important;
    }

    body.dark .contact-col-val {
      color: #ffffff !important;
      text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9) !important;
    }

    /* 5. Stepped Form Continues Below */
    .contact-form-area {
      width: 100% !important;
      max-width: 100% !important;
      margin-top: auto !important;
      margin-bottom: 0 !important;
      padding-top: 24px !important;
      display: flex !important;
      flex-direction: column !important;
      align-items: stretch !important;
    }

    .contact-step-progress {
      display: flex !important;
      justify-content: center !important;
      align-items: center !important;
      width: 100% !important;
      margin-top: 18px !important;
      gap: 10px !important;
    }
  }

  .testi-bubble {
    padding: 18px 16px !important;
    border-radius: 18px !important;
  }

  .testi-quote-text {
    font-size: 13.5px !important;
    line-height: 1.65 !important;
  }

  .testi-author-avatar {
    width: 42px !important;
    height: 42px !important;
  }

  /* ── Multi-Step Contact Form (Mobile Phone & Tablet Next Button Alignment) ── */
  .contact-step-pill {
    padding: 6px 10px !important;
    font-size: 12px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }

  /* CRITICAL: 16px font-size prevents iOS & Chrome Mobile from auto-zooming inputs */
  .contact-ghost-input {
    font-size: 16px !important;
    min-height: 44px !important;
    text-align: start !important;
  }

  .contact-ghost-label {
    text-align: start !important;
  }

  /* Next Button & Input strictly on the same row, never pushed to its own line */
  .contact-step:not(.contact-step--hidden) {
    display: flex !important;
    flex-direction: row !important;
    align-items: flex-end !important;
    justify-content: space-between !important;
    gap: 12px !important;
    width: 100% !important;
  }

  .contact-step--hidden,
  .contact-step.contact-step--hidden {
    display: none !important;
  }

  .contact-ghost-wrap {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    text-align: start !important;
  }

  /* Perfect circular Next button: auto width/height wrapper, circular icon */
  .contact-circle-btn {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 8px !important;
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    flex-shrink: 0 !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 0 4px 0 !important;
    align-self: flex-end !important;
    cursor: pointer !important;
  }

  .contact-circle-icon {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    max-width: 44px !important;
    max-height: 44px !important;
    border-radius: 50% !important;
    aspect-ratio: 1 / 1 !important;
    flex-shrink: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
  }

  .contact-circle-text {
    font-size: 13px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }

  /* ── Footer 2-Column Luxury Grid (Tablet & Mobile) ── */
  .footer-card {
    border-radius: 0 !important;
  }

  .footer-columns-wrap {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 22px 16px !important;
    width: 100% !important;
  }

  .footer-col-item:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }

  .footer-col-item:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 / span 2 !important;
  }

  .footer-col-item:nth-child(3) {
    grid-column: 1 !important;
    grid-row: 2 !important;
    margin-top: 4px !important;
  }

  .footer-card-middle {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    padding: 0 !important;
  }

  .footer-location-tag,
  .footer-phone-tag {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }

  .footer-col-header {
    font-size: 12px !important;
    margin-bottom: 12px !important;
  }

  .footer-nav-list li a,
  .footer-nav-static {
    font-size: 13.5px !important;
    padding: 6px 0 !important;
  }

  .footer-card-bottom {
    flex-direction: column !important;
    gap: 18px !important;
    text-align: center !important;
    align-items: center !important;
  }

  .footer-giant-email {
    font-size: clamp(16px, 4.8vw, 20px) !important;
    word-break: break-all !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }

  .footer-legal-copy {
    font-size: 12px !important;
  }

  .footer-social-cluster {
    justify-content: center !important;
    gap: 10px !important;
  }

  .footer-icon-pill {
    width: 40px !important;
    height: 40px !important;
  }

  /* ── Floating Scroll-to-Top Button strictly on the right in Mobile ── */
  .scroll-to-top-btn,
  body.lang-ar .scroll-to-top-btn,
  html[dir="rtl"] .scroll-to-top-btn {
    width: 46px !important;
    height: 46px !important;
    bottom: 20px !important;
    right: 20px !important;
    left: auto !important;
    z-index: 99999 !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
  }

  .scroll-to-top-btn.visible {
    pointer-events: auto !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   4. ULTRA-COMPACT SMARTPHONES (max-width: 400px)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 400px) {
  #hero-content {
    padding: 0 12px !important;
  }

  h1,
  body.lang-en h1,
  body.lang-fr h1,
  html:not(.lang-ar) h1 {
    font-size: clamp(18px, 5.4vw, 21.5px) !important;
    letter-spacing: -0.025em !important;
  }

  body.lang-ar h1,
  html[dir="rtl"] h1 {
    font-size: clamp(22px, 6.8vw, 26px) !important;
  }

  .hero-actions {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    gap: 6px !important;
    width: 100% !important;
    max-width: 330px !important;
    padding: 0 4px !important;
  }

  .hero-actions .btn-primary,
  .hero-actions .btn-ghost {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    width: auto !important;
    padding: 8px 8px !important;
    font-size: 11px !important;
    white-space: nowrap !important;
  }

  .hero-actions .btn-ghost {
    gap: 5px !important;
  }

  .hero-actions .btn-ghost svg {
    width: 11px !important;
    height: 11px !important;
    flex-shrink: 0 !important;
  }

  .hero-stats {
    gap: 8px !important;
    padding: 12px 14px !important;
  }

  .stat-num {
    font-size: 22px !important;
  }

  .stat-label {
    font-size: 10.5px !important;
  }


  .pcard-visual {
    height: 200px !important;
  }

  .hero-tags {
    flex-wrap: nowrap !important;
    gap: 4px !important;
  }

  .hero-tags .tag-chip {
    font-size: 9.5px !important;
    padding: 4px 7px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   5. ARABIC (RTL) RESPONSIVE HARMONY ACROSS ALL BREAKPOINTS
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {

  body.lang-ar .testi-info-col,
  html[dir="rtl"] .testi-info-col,
  body.lang-ar .testi-top-group,
  html[dir="rtl"] .testi-top-group,
  body.lang-ar .testi-title,
  html[dir="rtl"] .testi-title,
  body.lang-ar .testi-desc,
  html[dir="rtl"] .testi-desc {
    text-align: center !important;
    align-items: center !important;
  }

  body.lang-ar .scroll-to-top-btn,
  html[dir="rtl"] .scroll-to-top-btn {
    right: 20px !important;
    left: auto !important;
  }

  body.lang-ar .pmodal-close-btn,
  html[dir="rtl"] .pmodal-close-btn {
    right: auto !important;
    left: 14px !important;
  }

  body.lang-ar .lang-dropdown,
  html[dir="rtl"] .lang-dropdown {
    right: 0 !important;
    left: auto !important;
  }
}