/* ========================================
   Responsive — refined breakpoints
   Targets: 1440, 1024, 768, 480, 320
======================================== */

html,
body {
  overflow-x: hidden;
}

img,
svg,
video,
canvas,
iframe {
  max-width: 100%;
}

.container {
  width: 100%;
  margin: 0 auto;
}

/* 1440px+ */
@media (min-width: 1440px) {
  :root {
    --max-width: 1360px;
  }

  .container {
    padding-left: var(--space-xl);
    padding-right: var(--space-xl);
  }
}

/* 1024px and below */
@media (max-width: 1024px) {
  html {
    font-size: 15px;
  }

  :root {
    --space-xl: 2.5rem;
    --space-2xl: 3.5rem;
    --space-3xl: 4.5rem;
  }

  .container {
    padding-left: var(--space-md);
    padding-right: var(--space-md);
  }

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

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

  .hero,
  .page-hero,
  .hero--cinematic {
    padding-left: var(--space-md);
    padding-right: var(--space-md);
  }

  .hero__title,
  .hero--cinematic__title {
    line-height: 1.3;
  }
}

/* 768px and below */
@media (max-width: 768px) {
  html {
    font-size: 14px;
  }

  :root {
    --nav-height: 64px;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
  }

  .container {
    padding-left: 20px;
    padding-right: 20px;
  }

  .grid--2,
  .grid--3,
  .grid--4,
  .category-cards,
  .casual-connect,
  .footer__grid,
  .message-grid,
  .two-col-layout {
    grid-template-columns: 1fr;
  }

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

  .hero,
  .hero--cinematic,
  .page-hero {
    min-height: 62vh;
  }

  .hero__title {
    font-size: clamp(1.8rem, 5.2vw, 2.4rem);
  }

  .hero__subtitle,
  .hero--cinematic__subtitle,
  .page-hero__subtitle {
    font-size: clamp(0.95rem, 2.1vw, 1rem);
    line-height: 1.8;
  }

  .hero__actions,
  .hero--cinematic__actions,
  .cta-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .hero__actions .btn,
  .hero--cinematic__actions .btn,
  .cta-buttons .btn {
    width: 100%;
  }

  .nav__links {
    display: none;
  }

  .nav__hamburger {
    display: flex;
  }

  .nav__drawer {
    display: block;
    width: min(85vw, 320px);
  }

  .nav__drawer-overlay {
    display: block;
    pointer-events: none;
  }

  .nav__drawer-overlay.open {
    pointer-events: all;
  }

  .tabs {
    overflow-x: auto;
    scrollbar-width: none;
  }

  .tabs::-webkit-scrollbar {
    display: none;
  }

  .page-connect .schedule-row {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: var(--space-sm);
    padding: var(--space-md);
  }

  .page-connect .schedule-date {
    min-width: 64px;
  }

  .page-connect .schedule-row .btn {
    width: 100%;
    justify-content: center;
  }

  .page-home .interview-card,
  .page-interviews .interview-card {
    flex: 0 0 min(84vw, 360px);
  }

  .timeline {
    padding-left: calc(var(--space-lg) + 10px);
  }

  .timeline__item::before {
    left: calc(-1 * (var(--space-lg) + 10px));
  }
}

/* 480px and below */
@media (max-width: 480px) {
  html {
    font-size: 13px;
  }

  :root {
    --nav-height: 60px;
    --space-sm: 0.75rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 1.75rem;
    --space-2xl: 2.5rem;
  }

  .container {
    padding-left: 16px;
    padding-right: 16px;
  }

  .hero,
  .hero--cinematic,
  .page-hero {
    min-height: 56vh;
    padding-top: calc(var(--nav-height) + var(--space-lg));
  }

  .hero__title,
  .hero--cinematic__title,
  .page-hero__title {
    font-size: clamp(1.6rem, 6.2vw, 2rem);
    line-height: 1.35;
  }

  .stats {
    grid-template-columns: 1fr;
    gap: var(--space-sm);
  }

  .page-home .interview-card,
  .page-interviews .interview-card {
    flex: 0 0 88vw;
  }

  .carousel-nav__btn {
    width: 38px;
    height: 38px;
  }

  .card,
  .connect-card,
  .form-card {
    padding: var(--space-md);
  }

  /* Jobs page table readability on small mobile */
  .page-jobs .job-table,
  .page-jobs .job-table tbody,
  .page-jobs .job-table tr,
  .page-jobs .job-table td {
    display: block;
    width: 100%;
  }

  .page-jobs .job-table tr {
    padding: 8px 0;
  }

  .page-jobs .job-table td {
    padding: 2px 0;
  }

  .page-jobs .job-table td:first-child {
    width: auto;
    padding-right: 0;
    margin-top: 6px;
    color: var(--text-muted);
    font-weight: 600;
  }

  .page-faq .faq-category__title {
    font-size: 1.2rem;
  }
}

/* 320px and below */
@media (max-width: 320px) {
  html {
    font-size: 12px;
  }

  .container {
    padding-left: 12px;
    padding-right: 12px;
  }

  .nav__logo {
    font-size: 0.9rem;
  }

  .btn,
  .nav__cta {
    padding: 10px 18px;
  }

  .hero__title,
  .hero--cinematic__title,
  .page-hero__title {
    font-size: 1.45rem;
  }

  .page-home .interview-card,
  .page-interviews .interview-card {
    flex: 0 0 92vw;
  }
}

