/* ===== RESPONSIVE.CSS ===== */

/* Desktop sidebar collapse & mobile drawer now handled entirely in sidebar.css */
/* Do not redefine #sidebar width/transform/margin here to avoid conflicts */

/* Ultrawide */
@media (min-width: 1920px) {
  :root {
    --container-max: 1280px;
  }
}

/* Laptop */
@media (max-width: 1024px) {
  .connect-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Tablet & Mobile */
@media (max-width: 820px) {
  :root {
    --fs-display: 40px;
    --fs-h1: 32px;
    --fs-h2: 24px;
    --fs-h3: 18px;
  }
  /* Mobile Header */
  .mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: var(--z-nav);
  }
  .mobile-logo {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 18px;
  }
  .hamburger-btn {
    background: none;
    border: none;
    color: var(--text);
    cursor: pointer;
    padding: 8px;
  }

  /* Mobile sidebar handled in sidebar.css */
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .stats-inner {
    grid-template-columns: repeat(2, 1fr);
  }
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 32px 16px;
  }
}

/* Mobile */
@media (max-width: 640px) {
  .hero-visual {
    position: static;
    flex-direction: row;
    justify-content: flex-start;
    margin-bottom: 18px;
    animation: none;
  }
  .hero h1 {
    padding-right: 0;
    font-size: 34px;
  }
  .grid-3,
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .connect-grid {
    grid-template-columns: 1fr;
  }
  .book-card {
    flex-direction: column;
  }
  .book-cover {
    width: 100%;
    min-height: 120px;
  }
  section {
    padding: 48px 0 56px;
  }
  .section-alt {
    padding: 48px 0 56px;
  }
  .filter-bar {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
  }
  .filter-bar::-webkit-scrollbar {
    display: none;
  }
  .tab-pill {
    white-space: nowrap;
  }
  .modal {
    width: calc(100vw - 32px);
  }
  .modal--wide {
    width: calc(100vw - 32px);
  }
  .modal--detail {
    width: calc(100vw - 32px);
  }

  .contact-form-wide {
    grid-template-columns: 1fr;
  }
  .cf-right textarea {
    min-height: 120px;
  }
}

/* Small Mobile */
@media (max-width: 480px) {
  .hero h1 {
    font-size: 28px;
  }
  .btn-row {
    flex-direction: column;
  }
  .btn-row .btn {
    width: 100%;
    justify-content: center;
  }
  .highlights {
    gap: 8px;
  }
  .hl-chip {
    padding: 10px 12px;
  }
  .stats-inner {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .stat-num {
    font-size: 22px;
  }
  .connect-card {
    padding: 16px;
  }
}
