/* Mobile-first responsive overrides */

@media (max-width: 768px) {
  /* Navigation */
  .nav {
    width: 92%;
    padding: 0.6rem 1.25rem;
    top: 1rem;
  }
  
  .nav__links {
    display: none;
  }
  
  .nav__toggle {
    display: flex;
  }

  /* Hero */
  .hero__content {
    grid-template-columns: 1fr !important;
    text-align: center;
    gap: 2rem;
  }

  .hero__text {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero__portrait {
    max-height: 45vh;
    margin-top: 1.5rem;
    width: 100%;
  }

  .hero__portrait img {
    max-height: 45vh;
    object-fit: cover;
    border-radius: var(--radius-lg);
  }

  .hero__age {
    font-size: 3.5rem;
    bottom: -1rem;
    right: 50%;
    transform: translateX(50%);
  }

  .chapter-progress {
    display: none;
  }

  /* Chapter Grids */
  .chapter-grid {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }

  .chapter__content {
    text-align: left;
  }

  .chapter__images {
    width: 100%;
  }

  .chapter__image img {
    width: 100%;
    max-height: 350px;
    object-fit: cover;
    border-radius: var(--radius-md);
  }

  /* Grids */
  .personality-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem;
  }

  .books__grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 1rem;
  }

  .gifts__grid {
    grid-template-columns: 1fr !important;
    gap: 1.25rem;
  }

  .message-wall {
    columns: 1;
  }

  .gallery__strip {
    gap: 1rem;
    padding: 1rem 0;
  }

  .gallery__item {
    min-width: 220px;
    height: 300px;
  }

  /* Audio Control */
  .audio-control {
    bottom: 1rem;
    right: 1rem;
    padding: 0.5rem 1rem;
    font-size: 0.7rem;
  }

  /* Modals */
  .modal__content {
    width: 92%;
    max-height: 85vh;
    padding: 1.5rem;
    overflow-y: auto;
  }

  .scroll-progress {
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    right: auto;
  }

  .scroll-progress__fill {
    transition: width 0.1s;
    height: 100%;
  }

  .finale__number {
    font-size: clamp(5rem, 22vw, 9rem);
  }

  .section {
    padding: clamp(3.5rem, 8vh, 5.5rem) 0;
  }
  
  .chapter {
    padding: clamp(3.5rem, 8vh, 5.5rem) 0;
  }

  .cursor {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .hero__content {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  .message-wall {
    columns: 2;
  }

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

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

@media (min-width: 1440px) {
  :root {
    --space-xs: clamp(0.75rem, 1.2vw, 1rem);
    --space-sm: clamp(1rem, 1.8vw, 1.5rem);
    --space-md: clamp(1.5rem, 2.5vw, 2rem);
    --space-lg: clamp(2.25rem, 3.5vw, 3rem);
    --space-xl: clamp(3.5rem, 5vw, 4.5rem);
    --space-2xl: clamp(5rem, 7vw, 6.5rem);
    --space-3xl: clamp(7.5rem, 10vw, 9.5rem);
    --space-4xl: clamp(10rem, 14vw, 12rem);
  }
}
