/* ============================================
   JamaicaUnited.org - Style Sheet
   Jamaican Flag Colors: Green #009B3A, Yellow #FED100, Black #000000
   Design: Clean, modern, trust-building (Apple + Red Cross inspired)
   ============================================ */

/* ============================================
   CSS Reset & Base Styles
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Jamaican Flag Colors */
    --jamaica-green: #009B3A;
    --jamaica-yellow: #FED100;
    --jamaica-black: #000000;

    /* Supporting Colors */
    --white: #FFFFFF;
    --off-white: #F9F9F9;
    --light-gray: #F5F5F7;
    --gray: #86868B;
    --dark-gray: #1D1D1F;

    /* Accent Colors */
    --green-light: #00C853;
    --green-dark: #007A2A;
    --yellow-light: #FFE54C;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.16);

    /* Typography */
    --font-primary: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-secondary: 'Georgia', serif;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    color: var(--dark-gray);
    line-height: 1.6;
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--jamaica-black);
}

h1 {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

h3 {
    font-size: 1.75rem;
    font-weight: 600;
}

h4 {
    font-size: 1.5rem;
    font-weight: 600;
}

p {
    margin-bottom: 1rem;
    font-size: 1.125rem;
    line-height: 1.7;
    color: var(--dark-gray);
}

a {
    color: var(--jamaica-green);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--green-dark);
}

/* ============================================
   Header & Navigation
   ============================================ */
.site-header {
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 3px solid var(--jamaica-yellow);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--jamaica-black);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-flag {
    display: inline-block;
    width: 32px;
    height: 24px;
    position: relative;
    background: var(--jamaica-green);
    border-radius: 2px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.logo-flag::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(45deg, transparent 35%, var(--jamaica-yellow) 35%, var(--jamaica-yellow) 65%, transparent 65%),
        linear-gradient(-45deg, transparent 35%, var(--jamaica-yellow) 35%, var(--jamaica-yellow) 65%, transparent 65%);
}

.logo-flag::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(45deg, transparent 40%, var(--jamaica-black) 40%, var(--jamaica-black) 60%, transparent 60%),
        linear-gradient(-45deg, transparent 40%, var(--jamaica-black) 40%, var(--jamaica-black) 60%, transparent 60%);
}

/* Original gradient backup - Simple stripe version if needed
.logo-flag-simple {
    display: inline-block;
    width: 32px;
    height: 24px;
    background: linear-gradient(to bottom,
        var(--jamaica-green) 0%,
        var(--jamaica-green) 33.33%,
        var(--jamaica-yellow) 33.33%,
        var(--jamaica-yellow) 66.66%,
        var(--jamaica-black) 66.66%,
        var(--jamaica-black) 100%);
    border-radius: 2px;
}
*/

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.main-nav a {
    color: var(--dark-gray);
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--jamaica-green);
}

.nav-donate-btn {
    background-color: var(--jamaica-green);
    color: var(--white) !important;
    padding: 0.625rem 1.5rem;
    border-radius: 24px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.nav-donate-btn:hover {
    background-color: var(--green-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 0.5rem;
}

.menu-toggle span {
    width: 28px;
    height: 3px;
    background-color: var(--jamaica-black);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    background: linear-gradient(135deg, var(--jamaica-green) 0%, var(--green-dark) 100%);
    color: var(--white);
    padding: 6rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        linear-gradient(45deg, var(--jamaica-yellow) 1px, transparent 1px),
        linear-gradient(-45deg, var(--jamaica-yellow) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.05;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero h1 {
    color: var(--white);
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero p {
    font-size: 1.375rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

.cta-button {
    display: inline-block;
    background-color: var(--jamaica-yellow);
    color: var(--jamaica-black);
    padding: 1rem 3rem;
    font-size: 1.25rem;
    font-weight: 700;
    border-radius: 32px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-lg);
    border: none;
    cursor: pointer;
}

.cta-button:hover {
    background-color: var(--yellow-light);
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

/* ============================================
   Fundraising Progress Section
   ============================================ */
.progress-section {
    background-color: var(--light-gray);
    padding: 3rem 2rem;
}

.progress-container {
    max-width: 800px;
    margin: 0 auto;
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
}

.progress-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--jamaica-green);
    display: block;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.progress-bar-container {
    background-color: #E5E5E5;
    height: 24px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    margin-bottom: 1rem;
}

.progress-bar {
    background: linear-gradient(90deg, var(--jamaica-green) 0%, var(--green-light) 100%);
    height: 100%;
    border-radius: 12px;
    transition: width 1s ease;
    position: relative;
    overflow: hidden;
}

.progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.progress-text {
    text-align: center;
    color: var(--gray);
    font-size: 0.95rem;
}

/* ============================================
   Content Sections
   ============================================ */
.section {
    padding: 5rem 2rem;
}

.section-light {
    background-color: var(--white);
}

.section-gray {
    background-color: var(--light-gray);
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--gray);
    max-width: 700px;
    margin: 0 auto;
}

/* ============================================
   Where Donations Go Section
   ============================================ */
.donation-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
}

.category-card {
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

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

.category-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--jamaica-green), var(--green-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.category-card h3 {
    margin-bottom: 1rem;
    color: var(--jamaica-black);
}

.category-card p {
    color: var(--gray);
    font-size: 1rem;
    line-height: 1.6;
}

/* ============================================
   Stories Section
   ============================================ */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.story-card {
    background-color: var(--white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

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

.story-image {
    width: 100%;
    height: 240px;
    background-color: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray);
    font-size: 3rem;
}

.story-content {
    padding: 2rem;
}

.story-content h3 {
    margin-bottom: 1rem;
}

.story-content p {
    color: var(--gray);
    font-size: 1rem;
    margin-bottom: 1.5rem;
}

.read-more {
    color: var(--jamaica-green);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.read-more:hover {
    gap: 0.75rem;
}

/* ============================================
   Partners Section
   ============================================ */
.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    align-items: center;
    justify-items: center;
}

.partner-logo {
    width: 180px;
    height: 100px;
    background-color: var(--white);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
    padding: 1.5rem;
    transition: all 0.3s ease;
    color: var(--gray);
    font-weight: 600;
    text-align: center;
}

.partner-logo:hover {
    box-shadow: var(--shadow-md);
    transform: scale(1.05);
}

/* ============================================
   Footer
   ============================================ */
.site-footer {
    background-color: var(--jamaica-black);
    color: var(--white);
    padding: 3rem 2rem 1.5rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

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

.footer-section h4 {
    color: var(--jamaica-yellow);
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.footer-section p,
.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    line-height: 1.8;
}

.footer-section a:hover {
    color: var(--jamaica-yellow);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: var(--white);
    font-size: 1.125rem;
}

.social-link:hover {
    background-color: var(--jamaica-green);
    transform: translateY(-3px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    text-align: center;
}

.profectify-statement {
    color: var(--jamaica-yellow);
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.copyright {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
}

/* ============================================
   Utility Classes
   ============================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

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

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }

.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

/* ============================================
   Responsive Design - Mobile First
   ============================================ */
@media (max-width: 768px) {
    /* Typography */
    h1 {
        font-size: 2.25rem;
    }

    h2 {
        font-size: 1.875rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    p {
        font-size: 1rem;
    }

    /* Header */
    .header-container {
        padding: 1rem;
    }

    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--white);
        box-shadow: var(--shadow-md);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .main-nav.active {
        max-height: 400px;
    }

    .main-nav ul {
        flex-direction: column;
        padding: 1rem 0;
        gap: 0;
    }

    .main-nav li {
        width: 100%;
        text-align: center;
        padding: 0.75rem 0;
        border-bottom: 1px solid var(--light-gray);
    }

    .menu-toggle {
        display: flex;
    }

    /* Hero */
    .hero {
        padding: 4rem 1.5rem;
    }

    .hero h1 {
        font-size: 2.25rem;
    }

    .hero p {
        font-size: 1.125rem;
    }

    .cta-button {
        padding: 0.875rem 2rem;
        font-size: 1.125rem;
    }

    /* Progress Section */
    .progress-container {
        padding: 1.5rem;
    }

    .progress-stats {
        flex-direction: column;
        gap: 1.5rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    /* Sections */
    .section {
        padding: 3rem 1.5rem;
    }

    .section-header {
        margin-bottom: 2.5rem;
    }

    /* Cards */
    .donation-categories {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .stories-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .category-card,
    .story-content {
        padding: 1.5rem;
    }

    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .site-footer {
        padding: 2rem 1.5rem 1rem;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .hero h1 {
        font-size: 1.875rem;
    }

    .container {
        padding: 0 1rem;
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    .site-header,
    .hero,
    .cta-button,
    .menu-toggle {
        display: none;
    }

    body {
        font-size: 12pt;
        color: #000;
    }
}

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

/* Focus styles for keyboard navigation */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 3px solid var(--jamaica-yellow);
    outline-offset: 2px;
}

/* Reduced motion for accessibility */
@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;
    }
}
