/* ===============================================
   RESPONSIVE STYLES
   Mobile First Approach
   =============================================== */

/* Tablets and below (max-width: 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 0 var(--spacing-sm);
  }

  /* Header */
  .top-bar-content {
    flex-direction: column;
    gap: var(--spacing-sm);
    text-align: center;
  }

  .contact-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .contact-info a {
    margin-right: 0;
  }

  /* Hero */
  .hero-title {
    font-size: 2.5rem;
  }

  .hero-subtitle {
    font-size: 1.5rem;
  }

  .hero-description {
    font-size: 1.1rem;
  }

  /* About Section */
  .about-content {
    grid-template-columns: 1fr;
  }

  /* Impact Section */
  .impact-content {
    grid-template-columns: 1fr;
  }

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

  .services-list {
    grid-template-columns: 1fr;
  }

  /* CEO Section */
  .ceo-content {
    grid-template-columns: 1fr;
  }

  .ceo-image {
    order: -1;
  }

  /* Events Grid */
  .events-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }

  /* Navigators Grid */
  .navigators-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }
}

/* Mobile devices (max-width: 768px) */
@media (max-width: 768px) {
  /* Typography */
  h1 {
    font-size: 2rem;
  }
  h2 {
    font-size: 1.75rem;
  }
  h3 {
    font-size: 1.5rem;
  }

  .section-title {
    font-size: 2rem;
  }

  /* Spacing */
  .section {
    padding: var(--spacing-xl) 0;
  }

  /* Header */
  .top-bar {
    display: none; /* Hide top bar on mobile */
  }

  .navbar-content {
    padding: var(--spacing-xs) 0;
  }

  .logo img {
    height: 50px;
  }

  .nav-menu {
    position: fixed;
    top: 76px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 76px);
    background: white;
    flex-direction: column;
    padding: var(--spacing-lg);
    box-shadow: var(--box-shadow);
    transition: left 0.3s ease;
    overflow-y: auto;
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-menu li {
    width: 100%;
  }

  .nav-menu a {
    display: block;
    padding: 10px 0;
    font-size: 1.1rem;
    border-bottom: 1px solid var(--border-color);
  }

  .nav-social-item {
    display: block !important;
    border-bottom: none;
    padding-top: var(--spacing-sm);
  }

  .nav-social-links {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
    padding: var(--spacing-sm) 0;
  }

  .nav-social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    font-size: 1.1rem;
    border-bottom: none;
    padding: 0;
    transition: var(--transition);
  }

  .nav-social-links a:hover {
    background: var(--accent-color);
    transform: scale(1.1);
  }

  .btn-donate {
    display: none; /* Hide donate button in nav on mobile */
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
  }

  /* Hero */
  .hero {
    min-height: 500px;
    padding: var(--spacing-lg) 0;
    background-size: cover !important;
    background-position: center center !important;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.25rem;
  }

  .hero-description {
    font-size: 1rem;
    margin-bottom: var(--spacing-md);
  }

  .hero-buttons {
    flex-direction: row;
    justify-content: center;
    gap: var(--spacing-sm);
  }

  .hero-buttons .btn {
    flex: 1;
    max-width: 180px;
    padding: 12px 16px;
    font-size: 0.9rem;
  }

  /* Events Grid */
  .events-grid {
    grid-template-columns: 1fr;
  }

  /* Whys Grid */
  .whys-grid {
    grid-template-columns: 1fr;
  }

  /* Impact Section */
  .impact-stats {
    grid-template-columns: 1fr;
    gap: var(--spacing-sm);
  }

  /* Stories Grid */
  .stories-grid {
    grid-template-columns: 1fr;
  }

  /* CTA Boxes */
  .cta-boxes {
    grid-template-columns: 1fr;
  }

  /* Navigators Grid */
  .navigators-grid {
    grid-template-columns: 1fr;
  }

  /* Sponsors Grid */
  .sponsors-grid.platinum,
  .sponsors-grid.bronze,
  .sponsors-grid.supporting {
    grid-template-columns: 1fr;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-logo {
    margin-left: auto;
    margin-right: auto;
  }

  .footer-social {
    text-align: center;
  }

  .footer-contact li {
    justify-content: center;
  }
}

/* Small mobile devices (max-width: 480px) */
@media (max-width: 480px) {
  .container {
    padding: 0 var(--spacing-sm);
  }

  /* Typography */
  h1 {
    font-size: 1.75rem;
  }
  h2 {
    font-size: 1.5rem;
  }
  h3 {
    font-size: 1.25rem;
  }

  .section-title {
    font-size: 1.75rem;
  }

  /* Hero */
  .hero {
    min-height: 400px;
    background-size: cover !important;
    background-position: center center !important;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .hero-description {
    font-size: 0.95rem;
  }

  /* Buttons */
  .btn {
    padding: 12px 24px;
    font-size: 0.95rem;
  }

  /* Event Card */
  .event-date {
    top: 10px;
    right: 10px;
    padding: 8px 12px;
  }

  .event-date .day {
    font-size: 1.25rem;
  }

  .event-date .month {
    font-size: 0.8rem;
  }

  /* Why Card */
  .why-icon {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }

  /* Impact Stats */
  .stat-number {
    font-size: 2.5rem;
  }

  .stat-label {
    font-size: 1rem;
  }

  /* CTA Icon */
  .cta-icon {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }

  /* Scroll to Top */
  .scroll-to-top {
    width: 45px;
    height: 45px;
    bottom: 20px;
    right: 20px;
  }
}

/* Print Styles */
@media print {
  .top-bar,
  .navbar,
  .hero,
  .footer,
  .scroll-to-top,
  .mobile-menu-toggle {
    display: none !important;
  }

  body {
    color: black;
    background: white;
  }

  .section {
    page-break-inside: avoid;
  }

  a {
    text-decoration: underline;
  }
}

/* High Resolution Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  /* Optimize for retina displays if needed */
}

/* Landscape Orientation for Mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .hero {
    min-height: 400px;
  }

  .nav-menu {
    height: calc(100vh - 76px);
    padding: var(--spacing-md);
  }
}

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Dark Mode Support (Optional) */
@media (prefers-color-scheme: dark) {
  /* 
    Uncomment and customize if you want to support dark mode
    
    :root {
        --bg-color: #1A1A1A;
        --text-color: #E0E0E0;
        --dark-color: #FFFFFF;
    }
    */
}
