/* ========================
   Mobile Optimizations
   Fixes for screens < 768px
   ======================== */

@media (max-width: 767px) {

  /* --- Reduce section spacing on mobile --- */
  .hero,
  .how-it-works,
  .featured,
  .practices,
  .trust,
  .specializations,
  .methodology,
  .cta-banner,
  .section,
  .search-page {
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-2xl);
  }

  .section__subtitle {
    margin-bottom: var(--space-2xl);
    font-size: var(--text-base);
  }

  /* --- Hero section --- */
  .hero {
    min-height: auto;
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-3xl);
  }

  .hero__title {
    font-size: var(--text-4xl);
    line-height: 1.2;
  }

  .hero__subtitle {
    font-size: var(--text-base);
    margin-bottom: var(--space-xl);
  }

  .hero__actions {
    flex-direction: column;
  }

  .hero__actions .btn {
    width: 100%;
    justify-content: center;
  }

  /* --- Featured section --- */
  .featured__header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }

  .featured__header h2 {
    font-size: var(--text-2xl);
  }

  /* --- Specializations: single column on small phones --- */
  .specializations__grid {
    grid-template-columns: 1fr;
    gap: var(--space-sm);
  }

  .specialization-card {
    padding: var(--space-md);
  }

  /* --- Methodology flow steps --- */
  .methodology__flow-step {
    min-width: 0;
    width: 100%;
    padding: var(--space-md) var(--space-lg);
  }

  .methodology__grid .method-card {
    padding: var(--space-md);
  }

  /* --- Practice cards --- */
  .practice-card {
    padding: var(--space-lg);
  }

  .practice-card__tags {
    display: none;
  }

  /* --- Stat cards compact --- */
  .stat-card {
    padding: var(--space-md);
  }

  .stat-card__number {
    font-size: var(--text-2xl);
  }

  /* --- CTA banner --- */
  .cta-banner {
    padding: var(--space-2xl) 0;
  }

  .cta-banner__title {
    font-size: var(--text-2xl);
  }

  .cta-banner__text {
    font-size: var(--text-base);
    margin-bottom: var(--space-xl);
  }

  .cta-banner__icon {
    width: 48px;
    height: 48px;
  }

  /* --- Cards --- */
  .card__body {
    padding: var(--space-md);
  }

  .card__name {
    font-size: var(--text-base);
  }

  /* --- Modal fullscreen on mobile --- */
  .modal {
    max-width: 100%;
    max-height: 100vh;
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    margin: var(--space-md);
  }

  /* --- Search page --- */
  .search-header {
    padding: var(--space-lg) 0;
  }

  .results-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-sm);
  }

  .results-sort {
    justify-content: space-between;
  }

  /* --- Buttons --- */
  .btn--lg {
    padding: var(--space-md) var(--space-xl);
    font-size: var(--text-sm);
  }

  /* --- Footer compact --- */
  .site-footer {
    padding: var(--space-2xl) 0 var(--space-lg);
  }

  .footer__grid {
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
  }

  .footer__bottom {
    gap: var(--space-sm);
  }

  /* --- Headings smaller on mobile --- */
  h2 {
    font-size: var(--text-2xl);
  }

  h3 {
    font-size: var(--text-xl);
  }

  /* --- Page-specific hero sections --- */
  .trajecten-hero,
  .starten-hero,
  .vergoeding-hero,
  .wn-hero,
  .contact-hero,
  .about-hero {
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-2xl);
    min-height: auto;
  }

  .trajecten-hero__title,
  .starten-hero__title,
  .vergoeding-hero__title,
  .wn-hero__title {
    font-size: var(--text-3xl);
    line-height: 1.2;
  }

  .trajecten-hero__subtitle,
  .starten-hero__subtitle,
  .vergoeding-hero__subtitle,
  .wn-hero__subtitle {
    font-size: var(--text-base);
  }

  /* --- Trajecten page --- */
  .pricing-grid,
  .traject-keuze__grid,
  .methodiek__grid {
    grid-template-columns: 1fr;
  }

  .compare-table {
    font-size: var(--text-xs);
  }

  .compare-table th,
  .compare-table td {
    padding: var(--space-sm);
  }

  /* --- Vergoeding page --- */
  .steps-grid,
  .verzekeraar-grid,
  .info-highlights {
    grid-template-columns: 1fr;
  }

  /* --- Waarom nazorg page --- */
  .wn-stats {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .wn-benefits,
  .wn-methodology__grid,
  .wn-focus__grid,
  .wn-audience__grid {
    grid-template-columns: 1fr;
  }

  /* --- Profile page --- */
  .profile-header {
    flex-direction: column;
    text-align: center;
    gap: var(--space-lg);
  }

  .profile-header__info-bar {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm);
  }

  .profile-layout {
    grid-template-columns: 1fr;
  }

  /* --- Contact page --- */
  .contact-layout {
    grid-template-columns: 1fr;
  }
}

/* ========================
   Small phones (< 375px)
   ======================== */
@media (max-width: 374px) {
  :root {
    --container-padding: 0.75rem;
  }

  .hero__title {
    font-size: var(--text-3xl);
  }

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

  .stat-card__number {
    font-size: var(--text-xl);
  }
}

/* ========================
   Prevent horizontal scroll
   ======================== */
html, body {
  overflow-x: hidden;
}
