/* ===========================================
   RESPONSIVE.CSS - Mobile First Media Queries
   All responsive adjustments in one place

   Breakpoints:
   - Mobile: 0-767px (base styles)
   - Tablet: 768px+
   - Desktop: 1024px+
   - Large: 1440px+
   =========================================== */

/* ===========================================
   TABLET BREAKPOINT (768px+)
   =========================================== */

@media (min-width: 768px) {
    /* Typography */
    h1 { font-size: var(--fs-3xl); }
    h2 { font-size: var(--fs-2xl); }
    h3 { font-size: var(--fs-xl); }

    .section-title {
        font-size: var(--fs-3xl);
    }

    /* Container */
    .container {
        padding: 0 var(--space-xl);
    }

    /* Navbar */
    .navbar {
        min-height: 70px;
    }

    .nav-container {
        padding: 0 var(--space-xl);
    }

    .nav-logo img {
        height: 50px;
    }

    /* Hide hamburger, show desktop menu */
    .nav-toggle {
        display: none;
    }

    .nav-menu {
        position: static;
        width: auto;
        height: auto;
        background: none;
        flex-direction: row;
        padding: 0;
        box-shadow: none;
        left: 0;
        opacity: 1;
        transform: none;
        gap: var(--space-lg);
    }

    .nav-menu::before,
    .nav-menu::after {
        display: none;
    }

    .nav-menu li {
        margin: 0;
        opacity: 1;
        transform: none;
        animation: none;
    }

    .nav-menu a {
        font-size: var(--fs-base);
        font-weight: 500;
        color: var(--text-dark);
        padding: var(--space-sm);
    }

    .nav-menu a:hover {
        color: var(--primary);
        transform: none;
    }

    .nav-menu a::before {
        bottom: 0;
        height: 2px;
    }

    /* Hero */
    .hero-modern {
        min-height: calc(100vh - 70px);
        margin-top: 70px;
        padding: var(--space-3xl) 0;
    }

    .hero-container {
        padding: 0 var(--space-xl);
    }

    .hero-main,
    .hero-highlight {
        font-size: clamp(2rem, 4vw, 3rem);
    }

    .hero-description {
        font-size: var(--fs-lg);
    }

    .hero-cta {
        flex-direction: row;
    }

    .hero-right {
        max-width: 600px;
        margin: 0 auto;
    }

    /* Grids */
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-xl);
    }

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

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

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

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

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

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

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

    /* Contact */
    .contact-content {
        grid-template-columns: 1fr 1fr;
    }

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

    /* Cards */
    .card-content {
        padding: var(--space-xl);
    }

    .project-card {
        padding: var(--space-xl);
    }

    /* Buttons */
    .btn {
        min-width: 140px;
    }

    /* Section spacing */
    section {
        padding: var(--space-3xl) 0;
    }
}

/* ===========================================
   DESKTOP BREAKPOINT (1024px+)
   =========================================== */

@media (min-width: 1024px) {
    /* Typography */
    h1 { font-size: var(--fs-4xl); }
    h2 { font-size: var(--fs-3xl); }

    .section-title {
        font-size: var(--fs-4xl);
    }

    /* Container */
    .container {
        max-width: 1200px;
        padding: 0 var(--space-xl);
    }

    /* Navbar */
    .navbar {
        min-height: 80px;
    }

    .nav-container {
        padding: 0 var(--space-2xl);
        max-width: 1400px;
    }

    .nav-logo img {
        height: 60px;
    }

    .nav-menu {
        gap: var(--space-xl);
    }

    .nav-menu a {
        font-size: var(--fs-base);
        padding: var(--space-sm) var(--space-md);
    }

    /* Hero */
    .hero-modern {
        min-height: calc(100vh - 80px);
        margin-top: 80px;
    }

    .hero-content-wrapper {
        flex-direction: row;
        gap: var(--space-3xl);
        align-items: center;
    }

    .hero-left {
        flex: 1;
        max-width: 600px;
        text-align: left;
    }

    .hero-badge {
        margin-left: 0;
        margin-right: auto;
    }

    .hero-trust {
        justify-content: flex-start;
    }

    .hero-cta {
        justify-content: flex-start;
    }

    .hero-right {
        flex: 1;
        max-width: 550px;
    }

    /* Show floating cards on desktop */
    .floating-card {
        display: flex;
        position: absolute;
        background: white;
        padding: var(--space-md);
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow-lg);
        align-items: center;
        gap: var(--space-sm);
        animation: float 3s ease-in-out infinite;
        z-index: 3;
    }

    .floating-card.card-1 {
        top: 10%;
        left: -10%;
    }

    .floating-card.card-2 {
        bottom: 20%;
        right: -10%;
        animation-delay: 1s;
    }

    /* Background elements */
    .bg-circle {
        display: block;
        animation: float-slow 20s ease-in-out infinite;
    }

    .circle-1 {
        width: 400px;
        height: 400px;
    }

    .circle-2 {
        width: 300px;
        height: 300px;
        animation-delay: 5s;
    }

    /* Grids */
    .projects-grid {
        grid-template-columns: repeat(3, 1fr);
    }

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

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

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

    .board-grid {
        grid-template-columns: repeat(5, 1fr);
        max-width: 1000px;
    }

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

    /* Cards hover effects */
    .card:hover {
        transform: translateY(-8px);
    }

    .project-card:hover {
        transform: translateY(-8px);
    }

    /* Section spacing */
    section {
        padding: 80px 0;
    }

    /* Buttons */
    .btn {
        padding: 14px 28px;
        font-size: var(--fs-lg);
    }

    .btn:hover {
        transform: translateY(-2px);
    }
}

/* ===========================================
   LARGE DESKTOP BREAKPOINT (1440px+)
   =========================================== */

@media (min-width: 1440px) {
    /* Container */
    .container {
        max-width: 1400px;
        padding: 0 var(--space-2xl);
    }

    /* Navbar */
    .nav-container {
        max-width: 1600px;
        padding: 0 var(--space-3xl);
    }

    /* Hero */
    .hero-container {
        max-width: 1600px;
    }

    .hero-main,
    .hero-highlight {
        font-size: 3.5rem;
    }

    /* Grids */
    .values-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    /* Section spacing */
    section {
        padding: 100px 0;
    }
}

/* ===========================================
   EXTRA SMALL DEVICES (480px and below)
   =========================================== */

@media (max-width: 480px) {
    /* Typography */
    .hero-main,
    .hero-highlight {
        font-size: 1.5rem;
    }

    .hero-kicker {
        font-size: var(--fs-sm);
    }

    .hero-description {
        font-size: var(--fs-sm);
    }

    .section-title {
        font-size: var(--fs-xl);
    }

    /* Buttons */
    .hero-cta {
        flex-direction: column;
        width: 100%;
    }

    .btn-hero-primary,
    .btn-hero-secondary {
        width: 100%;
        justify-content: center;
        padding: var(--space-md) var(--space-lg);
        font-size: var(--fs-base);
    }

    /* Trust indicators */
    .hero-trust {
        gap: var(--space-lg);
    }

    .trust-number {
        font-size: var(--fs-xl);
    }

    /* Cards */
    .card-content {
        padding: var(--space-md);
    }

    .project-card {
        padding: var(--space-lg);
    }

    /* Footer */
    .footer-content {
        text-align: center;
    }
}

/* ===========================================
   LANDSCAPE ORIENTATION ON MOBILE
   =========================================== */

@media (max-height: 500px) and (orientation: landscape) {
    .hero-modern {
        min-height: auto;
        padding: var(--space-xl) 0;
    }

    .hero-trust {
        display: none;
    }

    .nav-menu {
        padding-top: var(--space-xl);
        justify-content: flex-start;
    }

    .nav-menu li {
        margin: var(--space-sm) 0;
    }

    .nav-menu a {
        font-size: var(--fs-lg);
        padding: var(--space-sm);
    }
}

/* ===========================================
   PRINT STYLES
   =========================================== */

@media print {
    .navbar,
    .fab,
    .instagram-section,
    .hero-bg-elements,
    .floating-card {
        display: none !important;
    }

    .hero-modern {
        min-height: auto;
        margin-top: 0;
        padding: var(--space-xl) 0;
    }

    body {
        font-size: 12pt;
        line-height: 1.5;
        color: black;
        background: white;
    }

    a {
        color: black;
        text-decoration: underline;
    }

    .card,
    .project-card {
        box-shadow: none;
        border: 1px solid #ccc;
        page-break-inside: avoid;
    }
}

/* ===========================================
   HIGH CONTRAST MODE
   =========================================== */

@media (prefers-contrast: high) {
    :root {
        --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
        --shadow-md: 0 4px 6px rgba(0,0,0,0.3);
        --shadow-lg: 0 10px 15px rgba(0,0,0,0.3);
    }

    .btn {
        border: 2px solid currentColor;
    }

    .card {
        border: 2px solid var(--border-dark);
    }

    .nav-menu a {
        text-decoration: underline;
    }
}

/* ===========================================
   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;
    }

    .floating-card {
        animation: none;
    }

    .bg-circle {
        animation: none;
    }

    .hero-image {
        transition: none;
    }
}

/* ===========================================
   TOUCH DEVICE OPTIMIZATIONS
   =========================================== */

@media (hover: none) and (pointer: coarse) {
    /* Remove hover effects on touch devices */
    .card:hover,
    .project-card:hover,
    .support-card:hover,
    .btn:hover {
        transform: none;
    }

    /* Increase touch targets */
    .nav-menu a {
        padding: var(--space-md) var(--space-lg);
    }

    .social-links a {
        width: 48px;
        height: 48px;
    }

    .btn-read-more {
        min-height: 48px;
        padding: var(--space-sm) var(--space-md);
    }
}

/* ===========================================
   ANIMATIONS - Float Effect
   =========================================== */

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes float-slow {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(30px, -30px) scale(1.05);
    }
    66% {
        transform: translate(-20px, 20px) scale(0.95);
    }
}
