/* ==========================================================================
   Gaza Foundation - Main Stylesheet
   ========================================================================== */

/* CSS Variables (Design System) */
:root {
    --brand-red: #E53935;
    --ink-900: #2B2F36;
    --ink-700: #4B5563;
    --bg-0: #FFFFFF;
    --bg-50: #F7F8FA;
    --accent-600: #2563EB;
    --radius: 10px;
    
    /* Typography */
    --font-heading: 'Montserrat', system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    
    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* ==========================================================================
   Base Styles & Resets
   ========================================================================== */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink-700);
    background-color: var(--bg-0);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--ink-900);
    margin: 0 0 var(--space-md) 0;
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: var(--space-lg);
}

h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    margin-bottom: var(--space-md);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    margin-bottom: var(--space-sm);
}

h4 {
    font-size: 1.25rem;
    margin-bottom: var(--space-sm);
}

p {
    margin: 0 0 var(--space-md) 0;
}

a {
    color: var(--accent-600);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--brand-red);
}

a:focus-visible {
    outline: 2px solid var(--accent-600);
    outline-offset: 2px;
    border-radius: 4px;
}

/* ==========================================================================
   Layout Utilities
   ========================================================================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.grid {
    display: grid;
    gap: var(--space-md);
}

.card {
    background: var(--bg-0);
    border-radius: var(--radius);
    padding: var(--space-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-sm) var(--space-lg);
    border: none;
    border-radius: var(--radius);
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 44px; /* Accessibility: minimum touch target */
    min-width: 44px;
}

.btn:focus-visible {
    outline: 2px solid var(--accent-600);
    outline-offset: 2px;
}

.btn-primary {
    background-color: var(--brand-red);
    color: white;
}

.btn-primary:hover {
    background-color: #d32f2f;
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: transparent;
    color: var(--ink-700);
    border: 2px solid var(--ink-700);
}

.btn-secondary:hover {
    background-color: var(--ink-700);
    color: white;
}

.btn-large {
    padding: var(--space-md) var(--space-xl);
    font-size: 1.125rem;
}

/* ==========================================================================
   Header
   ========================================================================== */

.header {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-md) 0;
}

.logo img {
    height: auto;
    max-height: 50px;
    width: auto;
}

.nav {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--brand-red);
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1001;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 6px;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
    background: linear-gradient(135deg, var(--bg-50) 0%, var(--bg-0) 100%);
    padding: var(--space-2xl) 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 60%;
    height: 200%;
    background: radial-gradient(circle, rgba(229, 57, 53, 0.1) 0%, transparent 70%);
    transform: rotate(15deg);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
    align-items: center;
}

.hero-text {
    text-align: left;
}

.hero-text h1 {
    margin-bottom: var(--space-lg);
}

.hero-subhead {
    font-size: 1.25rem;
    color: var(--ink-700);
    margin-bottom: var(--space-xl);
    max-width: 500px;
}

.hero-cta {
    display: flex;
    gap: var(--space-md);
    justify-content: flex-start;
    flex-wrap: wrap;
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    width: 500px;
    height: 375px;
    object-fit: cover;
}

/* ==========================================================================
   Impact Section
   ========================================================================== */

.impact {
    padding: var(--space-2xl) 0;
    background: var(--bg-0);
}

.impact h2 {
    text-align: center;
    margin-bottom: var(--space-xl);
}

.impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-xl);
}

.impact-card {
    text-align: center;
    padding: var(--space-xl);
    background: var(--bg-50);
    border-radius: var(--radius);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.impact-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.impact-number {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--brand-red);
    margin-bottom: var(--space-sm);
}

.impact-label {
    font-size: 1.125rem;
    color: var(--ink-700);
    font-weight: 500;
}

/* ==========================================================================
   Press Section
   ========================================================================== */

.press {
    padding: var(--space-2xl) 0;
    background: var(--bg-50);
}

.press h2 {
    text-align: center;
    margin-bottom: var(--space-md);
}

.section-intro {
    text-align: center;
    font-size: 1.125rem;
    color: var(--ink-700);
    margin-bottom: var(--space-xl);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.press-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-xl);
}

.press-item {
    background: var(--bg-0);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    text-decoration: none;
    color: inherit;
    display: block;
}

.press-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.press-logo {
    padding: var(--space-md);
    background: var(--bg-50);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    text-align: center;
}

.press-logo img {
    max-width: 120px;
    height: auto;
    max-height: 40px;
    object-fit: contain;
}

.press-image {
    position: relative;
    overflow: hidden;
}

.press-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.press-item:hover .press-image img {
    transform: scale(1.05);
}

.press-content {
    padding: var(--space-md);
}

.press-content h3 {
    font-size: 1.125rem;
    margin-bottom: var(--space-sm);
    color: var(--ink-900);
    line-height: 1.3;
}

.press-content p {
    font-size: 0.875rem;
    color: var(--ink-700);
    margin: 0;
    line-height: 1.4;
}

.press-fallback {
    text-align: center;
    padding: var(--space-xl);
    background: var(--bg-0);
    border-radius: var(--radius);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

/* ==========================================================================
   Testimonials Section
   ========================================================================== */

.testimonials {
    padding: var(--space-2xl) 0;
    background: var(--bg-0);
}

.testimonials h2 {
    text-align: center;
    margin-bottom: var(--space-md);
}

.testimonials-carousel {
    position: relative;
    margin-top: var(--space-xl);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg);
}

.testimonial-item {
    background: var(--bg-0);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    border: 2px solid var(--bg-50);
    position: relative;
}

.testimonial-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius);
    pointer-events: none;
    z-index: 1;
}

.testimonial-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.testimonial-item:hover img {
    transform: scale(1.05);
}

.testimonial-item img {
    width: 100%;
    height: 300px;
    object-fit: contain;
    background: white;
    padding: var(--space-md);
    border-bottom: 1px solid var(--bg-50);
    position: relative;
    z-index: 2;
    transition: transform 0.3s ease;
}

.testimonial-caption {
    padding: var(--space-lg);
    font-style: italic;
    color: var(--ink-700);
    text-align: center;
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-50);
    position: relative;
    z-index: 2;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.carousel-controls {
    display: flex;
    justify-content: center;
    gap: var(--space-sm);
    margin-top: var(--space-lg);
}

.carousel-btn {
    background: var(--bg-0);
    border: 2px solid var(--ink-700);
    color: var(--ink-700);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.carousel-btn:hover {
    background: var(--ink-700);
    color: white;
}

.carousel-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.testimonials-fallback {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-xl);
}

/* ==========================================================================
   Donate Section
   ========================================================================== */

.donate {
    padding: var(--space-2xl) 0;
    background: var(--bg-50);
    text-align: center;
}

.donate h2 {
    margin-bottom: var(--space-lg);
}

.donate p {
    font-size: 1.125rem;
    max-width: 700px;
    margin: 0 auto var(--space-xl) auto;
    color: var(--ink-700);
}

.donate-cta {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* ==========================================================================
   Contact Section
   ========================================================================== */

.contact {
    padding: var(--space-2xl) 0;
    background: var(--bg-0);
}

.contact h2 {
    text-align: center;
    margin-bottom: var(--space-xl);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
    margin-top: var(--space-xl);
}

.contact-info h3 {
    margin-bottom: var(--space-md);
}

.contact-details {
    margin-top: var(--space-lg);
}

.contact-details p {
    margin-bottom: var(--space-sm);
}

.contact-form {
    background: var(--bg-50);
    padding: var(--space-xl);
    border-radius: var(--radius);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: var(--space-md);
}

.form-group label {
    display: block;
    margin-bottom: var(--space-xs);
    font-weight: 600;
    color: var(--ink-900);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: var(--space-sm);
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-600);
}

.form-group input.error,
.form-group textarea.error {
    border-color: var(--brand-red);
}

.error-message {
    color: var(--brand-red);
    font-size: 0.875rem;
    margin-top: var(--space-xs);
    min-height: 1.25rem;
}

.form-success {
    background: #d4edda;
    color: #155724;
    padding: var(--space-md);
    border-radius: var(--radius);
    border: 1px solid #c3e6cb;
    margin-top: var(--space-md);
}

.honeypot {
    position: absolute;
    left: -9999px;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
    background: var(--ink-900);
    color: white;
    padding: var(--space-2xl) 0 var(--space-lg) 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.footer-section h4 {
    color: white;
    margin-bottom: var(--space-md);
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-section ul li {
    margin-bottom: var(--space-xs);
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.2s ease;
}

.footer-section a:hover {
    color: white;
}

.footer-logo {
    margin-bottom: var(--space-md);
}

.social-links {
    display: flex;
    gap: var(--space-sm);
}

.social-link {
    padding: var(--space-xs) var(--space-sm);
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    transition: background-color 0.2s ease;
}

.social-link:hover {
    background: rgba(255, 255, 255, 0.2);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--space-lg);
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
}

/* ==========================================================================
   Legal Pages
   ========================================================================== */

.legal-content {
    padding: var(--space-2xl) 0;
    background: var(--bg-0);
}

.legal-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.legal-wrapper h1 {
    margin-bottom: var(--space-sm);
}

.last-updated {
    color: var(--ink-700);
    font-style: italic;
    margin-bottom: var(--space-xl);
}

.legal-wrapper section {
    margin-bottom: var(--space-xl);
}

.legal-wrapper h2 {
    color: var(--ink-900);
    margin-bottom: var(--space-md);
}

.legal-wrapper h3 {
    color: var(--ink-900);
    margin-top: var(--space-lg);
    margin-bottom: var(--space-sm);
}

.legal-wrapper ul {
    margin-bottom: var(--space-md);
}

.legal-wrapper li {
    margin-bottom: var(--space-xs);
}

.legal-navigation {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    margin-top: var(--space-2xl);
    flex-wrap: wrap;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    .container {
        padding: 0 var(--space-sm);
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
        text-align: center;
    }
    
    .hero-text {
        text-align: center;
    }
    
    .hero-cta {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-image {
        order: -1;
    }
    
    .donate-cta {
        flex-direction: column;
        align-items: center;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }
    
    .impact-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    
    .press-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    
    .testimonials-grid {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
    
    .testimonial-item {
        min-height: 350px;
    }
    
    .testimonial-item img {
        height: 250px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .legal-navigation {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: var(--space-xl) 0;
    }
    
    .impact,
    .press,
    .testimonials,
    .donate,
    .contact {
        padding: var(--space-xl) 0;
    }
    
    .impact-card {
        padding: var(--space-lg);
    }
    
    .contact-form {
        padding: var(--space-lg);
    }
    
    .btn-large {
        padding: var(--space-sm) var(--space-lg);
        font-size: 1rem;
    }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    .header,
    .footer,
    .btn,
    .carousel-controls {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
        color: black;
        background: white;
    }
    
    .container {
        max-width: none;
        padding: 0;
    }
    
    .hero,
    .impact,
    .press,
    .testimonials,
    .donate,
    .contact {
        padding: 1rem 0;
        page-break-inside: avoid;
    }
    
    .impact-grid,
    .press-grid,
    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    a {
        color: black;
        text-decoration: underline;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
} 