/* ============================================
   RESPONSIVE.CSS — Breakpoints & Mobile
   ============================================ */

/* ── 1200px → Large tablet / small desktop ── */
@media (max-width: 1200px) {
  :root {
    --container-pad: clamp(16px, 4vw, 48px);
  }

  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr;
  }
  .footer-grid .footer-brand {
    grid-column: 1 / -1;
  }
  .footer-grid .footer-brand p {
    max-width: 100%;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .dashboard-layout {
    grid-template-columns: 220px 1fr;
  }
  .dashboard-main { padding: 36px 32px; }
}

/* ── 992px → Tablet landscape ── */
@media (max-width: 992px) {
  :root { --section-padding: 72px 0; }

  .grid-4 { grid-template-columns: repeat(2, 1fr); }

  .split-section {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .split-section.reverse { direction: ltr; }

  .contact-wrap { grid-template-columns: 1fr; gap: 40px; }

  .dash-cards { grid-template-columns: repeat(2, 1fr); }

  .hero-illustration { display: none; }
}

/* ── 768px → Tablet portrait / large mobile ── */
@media (max-width: 768px) {
  :root { --section-padding: 56px 0; }

  h1 { font-size: 2.2rem; }
  h2 { font-size: 1.75rem; }

  /* Nav */
  .nav-links  { display: none; }
  .nav-toggle { display: flex; }

  /* Grids */
  .grid-2,
  .grid-3 { grid-template-columns: 1fr; }

  .stats-grid { grid-template-columns: repeat(2, 1fr); }

  /* Hero */
  .hero-section { padding: 140px 0 72px; }
  .hero-content { text-align: center; }
  .hero-btns    { justify-content: center; }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-brand { grid-column: 1 / -1; }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  /* Auth */
  .auth-card  { padding: 36px 28px; }

  /* Dashboard */
  .dashboard-layout {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: static;
    height: auto;
  }
  .dashboard-main { padding: 28px 20px; }
  .dash-cards { grid-template-columns: 1fr; }

  /* Contact form */
  .contact-form-card { padding: 32px 28px; }

  /* CTA buttons */
  .cta-buttons { flex-direction: column; align-items: center; }
  .cta-buttons .btn { width: 100%; max-width: 300px; justify-content: center; }

  /* Section header */
  .section-header { margin-bottom: 40px; }
}

/* ── 480px → Small mobile ── */
@media (max-width: 480px) {
  :root { --section-padding: 48px 0; }

  h1 { font-size: 1.85rem; }

  .btn-xl { padding: 15px 28px; font-size: 0.95rem; }

  .card { padding: 28px 24px; }

  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-number { font-size: 1.9rem; }

  .testimonial-card { padding: 28px 24px; }
  .testimonial-card::before { font-size: 4rem; }

  .auth-card { padding: 28px 20px; border-radius: var(--radius-lg); }

  .footer-grid { grid-template-columns: 1fr; }
  .footer-brand { grid-column: auto; }

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

  .team-avatar { width: 72px; height: 72px; font-size: 1.6rem; }

  /* Sidebar becomes top bar on mobile */
  .sidebar { display: none; }
  .sidebar.mobile-open { display: block; position: fixed; inset: 0; z-index: 999; overflow-y: auto; }

  .feature-item { flex-direction: column; }
  .feature-number { font-size: 1.8rem; }
}

/* ── Print styles ── */
@media print {
  .navbar, .footer, .nav-toggle, .btn { display: none !important; }
  body { background: white; color: black; }
  .card { box-shadow: none; border: 1px solid #ddd; }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
