/* ============================================
   SOLIDMOTION - MOBILE OPTIMALISATIE v2
   Complete responsive fixes voor alle pagina's
   ============================================ */

/* ─── HAMBURGER MENU FIX ───
   Bug: hamburger spans hadden transforms buiten .nav--open,
   waardoor ze altijd in X-state stonden.
   Fix: reset de default state en gebruik .nav--open voor X-animatie
*/

/* Reset hamburger to default 3-line state */
.hamburger span:nth-child(1) {
  transform: none !important;
  width: 22px !important;
}
.hamburger span:nth-child(2) {
  opacity: 1 !important;
  width: 18px !important;
}
.hamburger span:nth-child(3) {
  transform: none !important;
  width: 22px !important;
}

/* X-state only when menu is open */
.nav--open .hamburger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg) !important;
  width: 22px !important;
}
.nav--open .hamburger span:nth-child(2) {
  opacity: 0 !important;
}
.nav--open .hamburger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg) !important;
  width: 22px !important;
}

/* ─── MOBILE NAV — VOLLEDIG HERSCHREVEN ─── */
@media (max-width: 768px) {

  /* === NAV BAR — NIEUWE AANPAK ===
     Het probleem: .nav heeft position:fixed + transition(transform)
     + backdrop-filter. Elk van deze creëert een "containing block"
     waardoor position:fixed op .nav__mobile NIET werkt t.o.v. het
     viewport, maar t.o.v. de 64px hoge nav. Daarom een andere
     aanpak: wanneer het menu OPEN is, wordt de <nav> zelf
     schermvullend, en het menu gebruikt position:absolute daarbinnen.
  */

  /* --- Nav default (menu dicht) --- */
  .nav {
    background: rgb(10, 10, 15) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    pointer-events: auto !important;
    height: var(--nav-height, 64px) !important;
    overflow: visible !important;
  }

  .nav--scrolled {
    background: rgb(10, 10, 15) !important;
  }

  /* --- Nav OPEN = fullscreen --- */
  .nav--open {
    height: 100vh !important;
    height: 100dvh !important;
    overflow-x: hidden !important;
    overflow-y: hidden !important;
    /* Sta scrollen toe BINNEN .nav__mobile via zijn eigen overflow-y:auto */
    transform: none !important;
  }

  .nav--open.nav--hidden {
    transform: none !important;
  }

  /* === NAV INNER (top bar met logo + hamburger) === */
  .nav__inner {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    height: var(--nav-height, 64px);
  }

  /* === NAV LINKS-WRAP: RESET PILL SHAPE === */
  .nav__links-wrap {
    display: flex !important;
    align-items: center;
    background: none !important;
    background-color: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin-left: auto;
    box-shadow: none !important;
    overflow: visible !important;
    transform: none !important;
    filter: none !important;
  }

  .nav--scrolled .nav__links-wrap {
    background: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    box-shadow: none !important;
  }

  /* === DESKTOP NAV LINKS VERBERGEN === */
  .nav__links {
    display: none !important;
  }

  .nav__actions .btn-sm,
  .nav__actions .btn-primary.btn-sm,
  .nav__actions .btn.btn-primary.btn-sm,
  .nav__actions .btn--sm,
  .nav__actions .btn--primary.btn--sm,
  .nav__actions .btn.btn--primary.btn--sm,
  .nav__actions > a.btn {
    display: none !important;
  }

  /* === NAV ACTIONS (bevat hamburger) === */
  .nav__actions {
    display: flex !important;
    align-items: center;
    gap: 0 !important;
  }

  /* === HAMBURGER BUTTON === */
  .hamburger {
    display: flex !important;
    flex-direction: column !important;
    width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 5px;
    position: relative;
    z-index: 10 !important;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    background: transparent !important;
    border: none !important;
    padding: 8px !important;
  }

  /* === MOBIEL MENU — PREMIUM DARK THEME ===
     Gebruikt position:absolute i.p.v. fixed.
     Omdat .nav--open height:100dvh is, vult dit het hele scherm.
     Dark theme passend bij de SolidMotion nav bar.
  */
  .nav__mobile {
    display: block !important;
    visibility: visible !important;
    position: absolute !important;
    top: var(--nav-height, 64px) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    /* Expliciete hoogte zodat overflow-y: auto werkt */
    height: calc(100vh - var(--nav-height, 64px)) !important;
    height: calc(100dvh - var(--nav-height, 64px)) !important;
    background: #ffffff !important;
    padding: 2rem 1.5rem !important;
    padding-bottom: 7rem !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    z-index: 5 !important;
    border-top: 1px solid rgba(0, 0, 0, 0.06) !important;
    transform: translateX(100%) !important;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
    pointer-events: none !important;
    box-sizing: border-box !important;
  }

  /* === MENU OPEN STATE === */
  .nav--open .nav__mobile {
    transform: translateX(0) !important;
    pointer-events: auto !important;
  }

  /* === BACKDROP: niet nodig, nav is al fullscreen === */
  .nav__mobile::before {
    display: none !important;
  }

  /* === STAGGERED FADE-IN ANIMATIE ===
     Elk menu-item schuift iets later in voor een premium gevoel.
  */
  .nav__mobile-link,
  .nav__mobile-sub,
  .nav__mobile-sublabel,
  .nav__mobile .btn {
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.3s ease, transform 0.3s ease !important;
  }

  .nav--open .nav__mobile-link,
  .nav--open .nav__mobile-sub,
  .nav--open .nav__mobile-sublabel,
  .nav--open .nav__mobile .btn {
    opacity: 1 !important;
    transform: translateX(0) !important;
  }

  /* Staggered delays */
  .nav--open .nav__mobile > :nth-child(1) { transition-delay: 0.05s !important; }
  .nav--open .nav__mobile > :nth-child(2) { transition-delay: 0.08s !important; }
  .nav--open .nav__mobile > :nth-child(3) { transition-delay: 0.11s !important; }
  .nav--open .nav__mobile > :nth-child(4) { transition-delay: 0.14s !important; }
  .nav--open .nav__mobile > :nth-child(5) { transition-delay: 0.17s !important; }
  .nav--open .nav__mobile > :nth-child(6) { transition-delay: 0.20s !important; }
  .nav--open .nav__mobile > :nth-child(7) { transition-delay: 0.23s !important; }
  .nav--open .nav__mobile > :nth-child(8) { transition-delay: 0.26s !important; }
  .nav--open .nav__mobile > :nth-child(9) { transition-delay: 0.29s !important; }
  .nav--open .nav__mobile > :nth-child(10) { transition-delay: 0.32s !important; }
  .nav--open .nav__mobile > :nth-child(11) { transition-delay: 0.35s !important; }
  .nav--open .nav__mobile > :nth-child(12) { transition-delay: 0.38s !important; }
  .nav--open .nav__mobile > :nth-child(13) { transition-delay: 0.41s !important; }

  /* === HOOFDLINKS (Home, Makelaars, Portfolio, etc.) === */
  .nav__mobile-link {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    min-height: 56px !important;
    padding: 1rem 0.25rem !important;
    font-size: 1.25rem !important;
    font-weight: 600 !important;
    letter-spacing: -0.01em !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06) !important;
    color: #0A0A0A !important;
    text-decoration: none !important;
    width: 100% !important;
    transition: color 0.15s ease, padding-left 0.15s ease, opacity 0.3s ease, transform 0.3s ease !important;
  }

  .nav__mobile-link:active {
    color: #049DFF !important;
    padding-left: 0.5rem !important;
  }

  /* Pijl-icoon hint rechts */
  .nav__mobile-link::after {
    content: '→' !important;
    font-size: 0.875rem !important;
    color: rgba(0, 0, 0, 0.15) !important;
    transition: color 0.15s ease, transform 0.15s ease !important;
  }

  .nav__mobile-link:active::after {
    color: #049DFF !important;
    transform: translateX(4px) !important;
  }

  /* === SUBLABELS (Creatief, Digitaal) === */
  .nav__mobile-sublabel {
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
    font-size: 0.6875rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.12em !important;
    text-transform: uppercase !important;
    color: #049DFF !important;
    padding: 1.75rem 0.25rem 0.625rem !important;
  }

  /* Lijn naast sublabel */
  .nav__mobile-sublabel::after {
    content: '' !important;
    flex: 1 !important;
    height: 1px !important;
    background: linear-gradient(90deg, rgba(4, 157, 255, 0.2), transparent) !important;
  }

  /* === SUBLINKS (Videografie, Fotografie, etc.) === */
  .nav__mobile-sub {
    display: flex !important;
    align-items: center !important;
    min-height: 48px !important;
    padding: 0.75rem 0.25rem 0.75rem 0.75rem !important;
    font-size: 1rem !important;
    font-weight: 400 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04) !important;
    color: rgba(10, 10, 10, 0.6) !important;
    text-decoration: none !important;
    width: 100% !important;
    transition: color 0.15s ease, padding-left 0.15s ease, opacity 0.3s ease, transform 0.3s ease !important;
  }

  .nav__mobile-sub:active {
    color: #0A0A0A !important;
    padding-left: 1rem !important;
  }

  /* Subtiel bullet voor sublinks */
  .nav__mobile-sub::before {
    content: '' !important;
    width: 4px !important;
    height: 4px !important;
    border-radius: 50% !important;
    background: rgba(0, 0, 0, 0.12) !important;
    margin-right: 0.75rem !important;
    flex-shrink: 0 !important;
    transition: background 0.15s ease !important;
  }

  .nav__mobile-sub:active::before {
    background: #049DFF !important;
  }

  /* === CTA KNOP — GRADIENT ACCENT === */
  .nav__mobile .btn {
    display: flex !important;
    width: 100% !important;
    justify-content: center !important;
    align-items: center !important;
    min-height: 52px !important;
    font-size: 1rem !important;
    font-weight: 600 !important;
    margin-top: 2rem !important;
    border-radius: 9999px !important;
    white-space: normal !important;
    background: linear-gradient(135deg, #049DFF, #6366f1) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 4px 20px rgba(4, 157, 255, 0.25) !important;
    letter-spacing: 0.01em !important;
    transition: box-shadow 0.2s ease, transform 0.15s ease, opacity 0.3s ease !important;
  }

  .nav__mobile .btn:active {
    transform: scale(0.98) translateX(0) !important;
    box-shadow: 0 2px 12px rgba(4, 157, 255, 0.35) !important;
  }

  /* === <br> in het menu verbergen === */
  .nav__mobile br {
    display: none !important;
  }

  /* === CHATBOT VERBERGEN wanneer menu open === */
  .nav--open ~ * .chatbot-launcher,
  .nav--open ~ .chatbot-launcher,
  body:has(.nav--open) .chatbot-launcher,
  body:has(.nav--open) .chatbot-widget,
  body:has(.nav--open) [class*="chatbot"] {
    display: none !important;
    pointer-events: none !important;
  }
}

/* ─── HERO SECTION MOBIEL ─── */
@media (max-width: 768px) {
  .hero {
    min-height: auto !important;
    padding-block: var(--space-16) var(--space-12) !important;
    overflow: visible !important;
  }

  .hero__content {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .hero__title {
    font-size: clamp(2.2rem, 10vw, 3.5rem) !important;
    word-break: break-word;
  }

  .hero__sub {
    max-width: 100% !important;
    font-size: var(--text-base) !important;
  }

  /* CTAs stapelen op mobiel */
  .hero__ctas {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: var(--space-3) !important;
    width: 100%;
  }

  .hero__ctas .btn {
    width: 100% !important;
    justify-content: center !important;
    text-align: center;
    white-space: normal !important;
  }

  .hero__scroll {
    display: none !important;
  }
}

@media (max-width: 480px) {
  .hero__title {
    font-size: clamp(1.8rem, 8vw, 2.5rem) !important;
  }
}

/* ─── KNOPPEN - GEEN AFKAPPEN ─── */
@media (max-width: 768px) {
  .btn,
  .btn-primary,
  .btn-ghost,
  .btn-white,
  .btn-outline-white,
  [class*="btn--"] {
    white-space: normal !important;
    word-break: break-word;
    min-height: 44px;
    padding: 0.75rem 1.25rem !important;
    font-size: var(--text-sm) !important;
    text-align: center;
    justify-content: center;
  }

  .btn-lg {
    padding: 0.875rem 1.5rem !important;
    font-size: var(--text-base) !important;
  }
}

/* ─── STATS GRID (4-kolom → 2-kolom) ─── */
@media (max-width: 768px) {
  .stats-grid,
  [style*="grid-template-columns:repeat(4,1fr)"] {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: var(--space-4) !important;
  }

  [data-counter] {
    font-size: var(--text-3xl) !important;
  }
}

@media (max-width: 480px) {
  .stats-grid,
  [style*="grid-template-columns:repeat(4,1fr)"] {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: var(--space-3) !important;
  }

  [data-counter] {
    font-size: var(--text-2xl) !important;
  }
}

/* ─── DIENSTEN GRID (3-kolom → 1-kolom) ─── */
@media (max-width: 768px) {
  .grid-3 {
    grid-template-columns: 1fr !important;
    gap: var(--space-6) !important;
  }

  .grid-2 {
    grid-template-columns: 1fr !important;
    gap: var(--space-6) !important;
  }

  .grid-4 {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: var(--space-4) !important;
  }
}

@media (max-width: 480px) {
  .grid-4 {
    grid-template-columns: 1fr !important;
    gap: var(--space-4) !important;
  }
}

/* ─── VIDEOGRAFIE SECTIE (2-kolom → 1-kolom) ─── */
@media (max-width: 768px) {
  [style*="grid-template-columns:1fr 1fr"],
  [style*="grid-template-columns: 1fr 1fr"],
  [style*="grid-template-columns:1fr 1.2fr"],
  [style*="grid-template-columns:1fr 1.6fr"] {
    grid-template-columns: 1fr !important;
    gap: var(--space-6) !important;
  }

  /* Footer 4-kolom → 1-kolom */
  [style*="grid-template-columns:2fr 1fr 1fr 1fr"],
  [style*="grid-template-columns: 2fr 1fr 1fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: var(--space-8) !important;
  }

  /* Videografie gap verkleinen */
  [style*="gap:var(--space-12)"] {
    gap: var(--space-6) !important;
  }
}

/* ─── VISUAL SPLIT SECTIE ─── */
@media (max-width: 768px) {
  .visual-split {
    grid-template-columns: 1fr !important;
    gap: var(--space-6) !important;
  }

  .visual-split__img {
    aspect-ratio: 16 / 10;
    border-radius: var(--radius-lg);
    overflow: hidden;
  }

  .visual-split__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

/* ─── FOTO STRIP (4-kolom → 2-kolom) ─── */
@media (max-width: 768px) {
  .photo-strip-grid,
  .photo-strip-grid[style] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* ─── PORTFOLIO GRID ─── */
@media (max-width: 768px) {
  .portfolio-grid {
    grid-template-columns: 1fr !important;
    gap: var(--space-6) !important;
  }

  .portfolio-card__image {
    aspect-ratio: 16 / 10;
  }

  .portfolio-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

/* ─── TESTIMONIALS SLIDER ─── */
@media (max-width: 768px) {
  .testimonials-slider {
    overflow: hidden;
  }

  .testimonial-slide > div {
    padding: var(--space-5) var(--space-4) !important;
    margin: 0 var(--space-2);
  }

  .testimonial-slide p[style*="font-size:var(--text-lg)"] {
    font-size: var(--text-base) !important;
  }

  .slider-controls {
    margin-top: var(--space-6) !important;
  }
}

/* ─── PROCESS / WERKWIJZE GRID ─── */
@media (max-width: 768px) {
  .process-grid {
    grid-template-columns: 1fr !important;
    gap: var(--space-6) !important;
  }

  .process-grid::before {
    display: none !important;
  }
}

/* ─── CTA BANNER ─── */
@media (max-width: 768px) {
  .cta-banner {
    padding: var(--space-8) var(--space-5) !important;
    text-align: center;
  }

  .cta-banner__title {
    font-size: var(--text-3xl) !important;
  }

  .cta-banner__actions {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: var(--space-3) !important;
  }

  .cta-banner__actions .btn-white,
  .cta-banner__actions .btn-outline-white,
  .cta-banner__actions a {
    width: 100% !important;
    justify-content: center !important;
    text-align: center;
  }
}

/* ─── SECTION HEADERS ─── */
@media (max-width: 768px) {
  .h2,
  h2 {
    font-size: var(--text-3xl) !important;
  }

  .h3,
  h3 {
    font-size: var(--text-2xl) !important;
  }

  .section-header--center {
    margin-bottom: var(--space-8) !important;
  }

  .section-header {
    margin-bottom: var(--space-8) !important;
  }

  .section-header[style*="display:flex"][style*="justify-content:space-between"] {
    flex-direction: column !important;
    align-items: flex-start !important;
  }

  .section {
    padding-block: var(--space-12) !important;
  }

  .section--sm {
    padding-block: var(--space-8) !important;
  }
}

/* ─── SHOWREEL SECTION ─── */
@media (max-width: 768px) {
  .showreel-section {
    height: auto !important;
  }

  .showreel-sticky {
    position: relative !important;
    height: auto !important;
    padding: 0 !important;
  }

  .showreel-frame {
    width: 100% !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }
}

/* ─── FOOTER COMPACT ─── */
@media (max-width: 768px) {
  .footer-new .container > div:first-child {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: var(--space-4) var(--space-3) !important;
    padding-bottom: var(--space-6) !important;
  }

  /* Description spans full width */
  .footer-new .container > div:first-child > div:first-child {
    grid-column: 1 / -1;
    padding-bottom: var(--space-4);
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    margin-bottom: var(--space-2);
  }

  .footer-new .container > div:first-child > div:first-child p:nth-of-type(2) {
    margin-bottom: var(--space-4) !important;
    font-size: var(--text-xs) !important;
  }

  /* Smaller headings & links in footer columns */
  .footer-new .container > div:first-child ul {
    gap: var(--space-2) !important;
  }
}

/* ─── CONTACT FORMULIER ─── */
@media (max-width: 768px) {
  .form-group-row,
  div[style*="grid-template-columns:1fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: var(--space-4) !important;
  }

  .contact-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ─── WEBSITES PAGINA - BEFORE/AFTER SLIDER ─── */
@media (max-width: 768px) {
  .ba-slider {
    min-width: 100% !important;
    width: 100% !important;
    overflow: hidden !important;
  }

  .ba-slider__before img {
    min-width: 100vw !important;
  }

  .perf-dashboard {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .growth-layout {
    grid-template-columns: 1fr !important;
  }

  [style*="min-width:960px"] {
    min-width: 100% !important;
    width: 100% !important;
  }
}

/* ─── FOOTER MOBIEL — COMPACT ─── */
@media (max-width: 768px) {
  .footer-new .container > div:first-of-type {
    /* Beschrijving bovenaan (1 kolom), daarna 3 linklijsten naast elkaar */
    grid-template-columns: 1fr !important;
    gap: var(--space-5) !important;
    padding-bottom: var(--space-5) !important;
  }

  /* Beschrijving compacter */
  .footer-new .container > div:first-of-type > div:first-child p:last-of-type {
    margin-bottom: var(--space-3) !important;
  }

  /* De 3 linklijsten (Links, Aanbod, Legal) naast elkaar in een row */
  .footer-new .container > div:first-of-type > div:nth-child(2),
  .footer-new .container > div:first-of-type > div:nth-child(3),
  .footer-new .container > div:first-of-type > div:nth-child(4) {
    display: inline-block !important;
    vertical-align: top !important;
    width: calc(33.333% - 0.75rem) !important;
    float: left !important;
  }

  /* Ruimte tussen de 3 kolommen */
  .footer-new .container > div:first-of-type > div:nth-child(2) {
    margin-right: 1rem !important;
  }
  .footer-new .container > div:first-of-type > div:nth-child(3) {
    margin-right: 1rem !important;
  }

  /* Kleinere gap in linklijsten */
  .footer-new .container > div:first-of-type ul {
    gap: var(--space-2) !important;
  }

  /* Kleinere titels */
  .footer-new .container > div:first-of-type p[style*="text-transform:uppercase"] {
    margin-bottom: var(--space-3) !important;
    font-size: 0.7rem !important;
  }

  /* Clearfix na de floats */
  .footer-new .container > div:first-of-type::after {
    content: '' !important;
    display: table !important;
    clear: both !important;
  }

  .footer-new {
    padding-top: var(--space-6);
  }

  /* Logo marquee kleiner */
  .footer-logo-marquee {
    overflow: hidden;
  }

  .footer-logo-img {
    height: 32px !important;
  }

  /* Copyright bar */
  .footer-new [style*="display:flex"][style*="justify-content:space-between"] {
    padding-top: var(--space-4) !important;
  }
}

/* ─── FAQ SECTIE ─── */
@media (max-width: 768px) {
  .faq-item {
    padding: var(--space-4) !important;
  }

  .faq-question {
    font-size: var(--text-base) !important;
    min-height: 44px;
    display: flex;
    align-items: center;
  }
}

/* ─── INLINE FLEX GAP CONTAINERS ─── */
@media (max-width: 768px) {
  [style*="display:flex"][style*="flex-wrap:wrap"] {
    gap: var(--space-2) !important;
  }

  [style*="display:flex"][style*="gap:var(--space-4)"] {
    flex-direction: column !important;
    align-items: stretch !important;
  }

  [style*="display:flex"][style*="gap:var(--space-4)"] > .btn,
  [style*="display:flex"][style*="gap:var(--space-4)"] > a[class*="btn"] {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}

/* ─── MARQUEE / TRUST BAR ─── */
@media (max-width: 768px) {
  .marquee-section {
    overflow: hidden !important;
  }

  .marquee-item {
    font-size: var(--text-sm) !important;
    padding: 0 var(--space-4) !important;
  }
}

/* ─── IMAGE GRIDS IN SHOWCASE SECTIES ─── */
@media (max-width: 768px) {
  [style*="display:grid"][style*="grid-template-columns:1fr 1fr"][style*="gap:var(--space-4)"] {
    grid-template-columns: 1fr 1fr !important;
    gap: var(--space-3) !important;
  }

  [style*="margin-top:var(--space-8)"] {
    margin-top: 0 !important;
  }
}

/* ─── ABONNEMENTEN PAGINA ─── */
@media (max-width: 768px) {
  .abo-diensten-layout {
    grid-template-columns: 1fr !important;
  }

  .abo-steps {
    grid-template-columns: 1fr !important;
  }
}

/* ─── MAKELAARS PAGINA ─── */
@media (max-width: 768px) {
  .mk-pain-layout {
    grid-template-columns: 1fr !important;
  }

  .pain-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ─── BENTO GALLERY LAYOUTS ─── */
@media (max-width: 768px) {
  .foto-bento,
  .oo-bento,
  .mk-bento,
  [style*="grid-template-columns:repeat(12,1fr)"] {
    grid-template-columns: 1fr 1fr !important;
    grid-template-rows: auto !important;
  }

  .foto-bento > *,
  .oo-bento > *,
  .mk-bento > * {
    grid-column: auto !important;
    grid-row: auto !important;
  }
}

/* ─── CASE PAGINA'S ─── */
@media (max-width: 768px) {
  .case-stats {
    grid-template-columns: 1fr !important;
  }

  .case-img-grid {
    grid-template-columns: 1fr !important;
  }

  .case-services-dark {
    grid-template-columns: 1fr !important;
  }

  /* Case video grid met fixed 300px kolom */
  [style*="grid-template-columns:1fr 300px"] {
    grid-template-columns: 1fr !important;
  }
}

/* ─── SCROLL WAVE & CURSOR ─── */
@media (max-width: 768px) {
  .scroll-wave {
    display: none !important;
  }

  .cursor-glow {
    display: none !important;
  }
}

/* ─── PADDING & SPACING REDUCTIE ─── */
@media (max-width: 768px) {
  :root {
    --space-24: 3.5rem;
    --space-32: 4rem;
    --space-20: 3rem;
    --space-16: 2.5rem;
  }
}

/* ─── OVERFLOW PREVENTIE ─── */
@media (max-width: 768px) {
  body {
    overflow-x: hidden !important;
  }

  /* NIET overflow:hidden op body.nav--open, dat doet de JS al */

  .container {
    max-width: 100vw !important;
  }

  img, video {
    max-width: 100% !important;
  }

  /* overflow-x:hidden op sections verwijderd — veroorzaakt scroll-jank
     op mobiele browsers. De body overflow-x:hidden vangt alles op. */
}

/* ─── VERBETERDE TOUCH TARGETS ─── */
@media (hover: none) and (pointer: coarse) {
  .btn,
  a.btn,
  button {
    min-height: 44px;
  }

  .nav__mobile-link,
  .nav__mobile-sub {
    min-height: 48px;
  }

  .slider-prev,
  .slider-next,
  .slider-dot {
    min-width: 44px;
    min-height: 44px;
  }

  .filter-btn {
    min-height: 44px;
    padding: var(--space-2) var(--space-4) !important;
  }
}

/* ─── EXTRA SMALL SCREENS (375px en kleiner) ─── */
@media (max-width: 375px) {
  .hero__title {
    font-size: clamp(1.6rem, 8vw, 2rem) !important;
    line-height: 1.1 !important;
  }

  .h2,
  h2 {
    font-size: var(--text-2xl) !important;
  }

  .container {
    padding-inline: var(--space-4) !important;
  }

  .btn,
  .btn-primary,
  .btn-ghost {
    font-size: var(--text-sm) !important;
    padding: 0.625rem 1rem !important;
  }

  [data-counter] {
    font-size: var(--text-xl) !important;
  }

  .nav__mobile {
    padding: 1.25rem 1rem !important;
    padding-bottom: 5rem !important;
  }

  .nav__mobile-link {
    font-size: 1.1rem !important;
    min-height: 50px !important;
  }

  .nav__mobile-sub {
    font-size: 0.9375rem !important;
    min-height: 44px !important;
  }
}