:root {
    /* Original Friendly Palette Tokens */
    --primary-color: #2e7d32;
    --secondary-color: #00796b;
    --text-color: #333333;
    --bg-color: #f4f7f6;
    --card-bg: #ffffff;
    
    /* Underwater Mode Color Tokens */
    --ocean-dark: #0f172a;            /* Deep Blue Ocean Void */
    --ocean-card: #1e293b;            /* Submerged Card Blocks */
    --ocean-text: #f1f5f9;            /* Ice White Contrast Text */
    --ocean-highlight: #1e3a5f;       /* Clear Deep Blue Callout Box */
    --ocean-accent: #38bdf8;          /* Bright Electric Sky Cyan */
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--bg-color);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    /* High-performance hardware accelerated easing curves for smooth submersion transition */
    transition: background-color 0.8s cubic-bezier(0.4, 0, 0.2, 1), color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Full Screen Submersion Layout Shift styles */
body.underwater {
    background-color: var(--ocean-dark);
    color: var(--ocean-text);
}

/* Outer page layout content holder limits width of text cards */
.container { 
    max-width: 760px; 
    margin: 40px auto; 
    padding: 0 20px; 
    position: relative; 
}

/* --- VIBRANT TROPICAL SPECTRUM HEADER SETTINGS --- */
header {
    position: relative;
    text-align: center;
    /* Completely overhauled gradient stack using rich magentas and pure corals to block grey zones */
    background: linear-gradient(45deg, #ff6b6b, #ff9f43, #feca57, #1dd1a1, #00d2d3, #54a0ff, #5f27cd, #f368e0, #ff6b6b);
    background-size: 600% 600%;
    color: white;
    padding: 90px 20px 140px 20px;
    /* Widens layout past central card boundaries to hit the screen borders */
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
    box-sizing: border-box;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    animation: fadeIn 0.8s ease-out forwards, rainbowBackgroundShift 18s ease infinite;
    overflow: hidden;
}

header h1 {
    font-family: 'Playfair Display', Georgia, serif; 
    font-size: 3.2em; 
    font-weight: 700; 
    margin: 0 0 12px 0; 
    letter-spacing: -0.3px; 
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.35);
    animation: fadeInUp 0.6s ease-out 0.1s both; 
    pointer-events: none;
}

header p {
    margin: 0; 
    font-size: 1.35em; 
    opacity: 0.95; 
    font-weight: 400; 
    letter-spacing: 0.2px; 
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    animation: fadeIn 0.8s ease-out 0.4s both; 
    pointer-events: none;
}

/* Wave container stretches wall-to-wall with the full screen header */
.wave-wrapper { 
    position: absolute; 
    width: 100vw; 
    bottom: 0; 
    left: 0; 
    height: 120px; 
    overflow: hidden; 
    pointer-events: none; 
}

.wave-svg { 
    display: block; 
    width: 100%; 
    height: 100%; 
}

.wave-path { 
    fill: var(--bg-color); 
    transition: fill 0.8s cubic-bezier(0.4, 0, 0.2, 1); 
}

body.underwater .wave-path { 
    fill: var(--ocean-dark); 
}

/* --- Core Content Structures --- */
.main-content {
    background: var(--card-bg);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(30, 41, 59, 0.04);
    margin-bottom: 30px;
    animation: fadeInUp 0.8s cubic-bezier(0.15, 1, 0.3, 1) 0.15s both;
    transition: background-color 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                box-shadow 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                border-color 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
}

body.underwater .main-content {
    background-color: var(--ocean-card);
    color: var(--ocean-text);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
    border-color: rgba(255,255,255,0.05);
}

h2 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.7em;
    color: #2e7d32;
    border-bottom: 2px solid #edf2f7;
    padding-bottom: 10px;
    margin-top: 40px;
    transition: color 0.8s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

body.underwater h2 { 
    color: var(--ocean-accent); 
    border-bottom-color: rgba(255,255,255,0.1);
}

.highlight-box {
    background-color: #e8f5e9;
    border-left: 4px solid var(--primary-color);
    padding: 20px;
    margin: 35px 0;
    border-radius: 0 10px 10px 0;
    font-weight: 500;
    animation: fadeInUp 0.6s ease-out 0.6s both;
    transition: background-color 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                border-left-color 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

body.underwater .highlight-box {
    background-color: var(--ocean-highlight);
    border-left-color: var(--ocean-accent);
    color: #e0f2fe;
}

.fundraising-section { 
    display: grid; 
    grid-template-columns: 1fr 1fr; 
    gap: 24px; 
    margin-top: 30px; 
}

@media (max-width: 600px) { 
    .fundraising-section { grid-template-columns: 1fr; } 
}

.fundraising-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 25px;
    border-radius: 12px;
    color: #475569;
    position: relative;
    z-index: 1;
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1),
                background-color 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.25, 0.8, 0.25, 1),
                color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInUp 0.6s cubic-bezier(0.15, 1, 0.3, 1) both;
}

body.underwater .fundraising-card {
    background-color: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.08);
    color: #cbd5e1;
}

.fundraising-card h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.35em;
    margin-top: 0;
    margin-bottom: 12px;
    color: var(--secondary-color);
    transition: color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

body.underwater .fundraising-card h3 { 
    color: var(--ocean-accent); 
}

.fundraising-card:hover {
    transform: translateY(-5px);
    border-color: var(--secondary-color);
    box-shadow: 0 12px 24px rgba(11, 102, 106, 0.06);
    background: #ffffff;
}

body.underwater .fundraising-card:hover {
    background-color: rgba(255, 255, 255, 0.06);
    border-color: var(--ocean-accent);
    box-shadow: 0 12px 25px rgba(56, 189, 248, 0.15);
}

.gallery-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 30px 0;
}

@media (max-width: 600px) { 
    .gallery-grid { grid-template-columns: 1fr; } 
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 4px solid white;
    background: transparent;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

body.underwater .gallery-item {
    border-color: var(--ocean-card);
    box-shadow: 0 10px 25px rgba(56, 189, 248, 0.15);
}

.gallery-item img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.links-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 25px;
}

.action-link {
    flex: 1;
    min-width: 160px;
    text-align: center;
    text-decoration: none;
    padding: 14px 20px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1.05em;
    background-color: var(--secondary-color);
    color: white;
    box-shadow: 0 4px 12px rgba(11, 102, 106, 0.15);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.action-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(11, 102, 106, 0.25);
    background-color: var(--primary-color);
}

body.underwater .action-link {
    background-color: transparent;
    color: var(--ocean-accent);
    border: 2px solid var(--ocean-accent);
    box-shadow: 0 4px 15px rgba(56, 189, 248, 0.1);
}

body.underwater .action-link:hover {
    background-color: var(--ocean-accent);
    color: var(--ocean-dark);
    box-shadow: 0 8px 25px rgba(56, 189, 248, 0.35);
}

/* --- Particles & Custom Graphic Drop Vectors --- */
.splash-particle { 
    position: absolute; 
    width: 6px; 
    height: 6px; 
    background: rgba(255, 255, 255, 0.95); 
    border-radius: 50%; 
    pointer-events: none; 
    z-index: 10; 
    will-change: transform, opacity; 
}
body.underwater .splash-particle { background: #38bdf8; }

.bubble-container { 
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 100; display: none; 
}
body.underwater .bubble-container { display: block; }

.bubble { 
    position: absolute; background: rgba(255, 255, 255, 0.09); border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 50%; will-change: transform, opacity; 
}

footer { 
    text-align: center; padding: 40px 20px; font-size: 1.15em; font-weight: 600; color: #2e7d32; letter-spacing: 0.1px; animation: fadeIn 1s ease-out 1s both; transition: color 0.8s cubic-bezier(0.4, 0, 0.2, 1); 
}
body.underwater footer { color: var(--ocean-accent); }

@keyframes fadeInUp { from { opacity: 0; transform: translateY(25px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes scaleIn { from { opacity: 0; transform: scale(0.97); } to { opacity: 1; transform: scale(1); } }
@keyframes rainbowBackgroundShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
@keyframes bubbleRise { 
    0% { transform: translateY(105vh) translateX(0) scale(0.6); opacity: 0; } 
    10% { opacity: 0.6; } 
    85% { opacity: 0.6; } 
    100% { transform: translateY(-15vh) translateX(var(--bx)) scale(1.3); opacity: 0; } 
}
