/* ========================================
   엘림G브릿지 - Custom Styles
   ======================================== */

/* CSS Variables */
:root {
    --primary: #1E3A5F;
    --secondary: #3B82F6;
    --accent: #F59E0B;
    --warmth: #E11D48;
    --nature: #10B981;
    --light: #F8FAFC;
    --dark: #0F172A;
    --gradient-primary: linear-gradient(135deg, var(--primary), var(--secondary));
    --gradient-accent: linear-gradient(135deg, var(--accent), #F97316);
    --gradient-nature: linear-gradient(135deg, var(--nature), #34D399);
    --gradient-warmth: linear-gradient(135deg, var(--warmth), #FB7185);
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

/* Navigation Styles */
#mainNav {
    background: transparent;
    transition: all 0.3s ease;
}

#mainNav.scrolled {
    background: rgba(30, 58, 95, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.nav-link {
    position: relative;
    font-weight: 500;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Hero Section */
#hero {
    position: relative;
}

.bridge-animation {
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(245, 158, 11, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(59, 130, 246, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(16, 185, 129, 0.05) 0%, transparent 70%);
    animation: bridgeFlow 20s ease-in-out infinite;
}

@keyframes bridgeFlow {
    0%, 100% {
        opacity: 0.5;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}

/* Counter Animation */
.counter {
    display: inline-block;
}

/* Card Hover Effects */
.pillar-card {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Gradient Text */
.gradient-text {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Button Styles */
.btn-primary {
    background: var(--gradient-accent);
    color: white;
    padding: 1rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(245, 158, 11, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(245, 158, 11, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: white;
    padding: 1rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Section Styles */
section {
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: #6B7280;
}

/* Pillar Bridge Line */
.pillar-bridge-line {
    background: linear-gradient(90deg, 
        var(--accent), 
        var(--secondary), 
        var(--nature), 
        var(--warmth)
    );
    height: 4px;
    border-radius: 2px;
}

/* Card Styles */
.feature-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.feature-card:hover {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    transform: translateY(-4px);
}

/* Icon Styles */
.icon-box {
    width: 80px;
    height: 80px;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    margin-bottom: 1.5rem;
}

.icon-box.accent { background: var(--gradient-accent); }
.icon-box.secondary { background: var(--gradient-primary); }
.icon-box.nature { background: var(--gradient-nature); }
.icon-box.warmth { background: var(--gradient-warmth); }

/* Timeline Styles (for Vision page) */
.timeline {
    position: relative;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary), var(--secondary), var(--accent));
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    padding-bottom: 2rem;
    padding-left: 2rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -0.5rem;
    top: 0.25rem;
    width: 1rem;
    height: 1rem;
    background: var(--accent);
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 0 0 4px var(--accent);
}

/* Form Styles */
.form-input {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid #E5E7EB;
    border-radius: 0.75rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.form-label {
    display: block;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

/* Footer Styles */
footer {
    background: var(--dark);
}

footer a:hover {
    color: var(--accent);
}

/* Language Selector */
#langSelector {
    transition: all 0.3s ease;
}

#langSelector:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* Mobile Menu */
#mobileMenu {
    transition: all 0.3s ease;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .section-title {
        font-size: 1.75rem;
    }
    
    #hero h1 {
        font-size: 2rem;
    }
    
    #langSelector {
        top: auto;
        bottom: 20px;
        right: 20px;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Utility Classes */
.fade-in-up {
    animation: fadeInUp 0.6s ease forwards;
}

.slide-in-left {
    animation: slideInLeft 0.6s ease forwards;
}

.slide-in-right {
    animation: slideInRight 0.6s ease forwards;
}

/* Scrollbar Styles */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

/* Page Header for Subpages */
.page-header {
    background: var(--gradient-primary);
    padding: 8rem 0 4rem;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(245, 158, 11, 0.2), transparent 70%);
}

.page-header h1 {
    color: white;
    font-size: 3rem;
    font-weight: 700;
}

.page-header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.25rem;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.breadcrumb a {
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--accent);
}

/* Tab Styles */
.tab-btn {
    padding: 1rem 2rem;
    background: transparent;
    border: none;
    font-weight: 600;
    color: #6B7280;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: var(--primary);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent);
    border-radius: 3px 3px 0 0;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeInUp 0.4s ease;
}

/* Map Styles */
.map-container {
    position: relative;
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.map-marker {
    position: absolute;
    width: 24px;
    height: 24px;
    background: var(--accent);
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.map-marker:hover {
    transform: scale(1.2);
}

.map-marker::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    background: rgba(245, 158, 11, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 2s infinite;
}

/* Accordion Styles */
.accordion-item {
    border: 1px solid #E5E7EB;
    border-radius: 1rem;
    margin-bottom: 1rem;
    overflow: hidden;
}

.accordion-header {
    padding: 1.25rem 1.5rem;
    background: white;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    color: var(--primary);
    transition: all 0.3s ease;
}

.accordion-header:hover {
    background: #F9FAFB;
}

.accordion-header.active {
    background: var(--primary);
    color: white;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.accordion-content.active {
    max-height: 500px;
}

.accordion-body {
    padding: 1.5rem;
    background: #F9FAFB;
}

/* Stats Card */
.stats-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.stats-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

.stats-number {
    font-size: 3rem;
    font-weight: 700;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Partner Logo Grid */
.partner-logo {
    width: 120px;
    height: 60px;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s ease;
}

.partner-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* Donation Box */
.donation-box {
    background: linear-gradient(135deg, #FEF3C7, #FDE68A);
    border-radius: 1.5rem;
    padding: 2rem;
    border: 2px solid var(--accent);
}

/* Volunteer Card */
.volunteer-card {
    background: white;
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.volunteer-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

.volunteer-card-header {
    padding: 1.5rem;
    color: white;
}

.volunteer-card-body {
    padding: 1.5rem;
}

/* Progress Bar */
.progress-bar {
    height: 8px;
    background: #E5E7EB;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 1s ease;
}

/* Quote Box */
.quote-box {
    position: relative;
    padding: 2rem;
    background: #F9FAFB;
    border-radius: 1.5rem;
    border-left: 4px solid var(--accent);
}

.quote-box::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 5rem;
    color: var(--accent);
    opacity: 0.2;
    font-family: Georgia, serif;
}

/* Image Gallery */
.gallery-item {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

/* Print Styles */
@media print {
    #mainNav, #langSelector, footer {
        display: none;
    }
    
    body {
        font-size: 12pt;
    }
    
    .page-header {
        background: none;
        color: black;
        padding: 2rem 0;
    }
    
    .page-header h1, .page-header p {
        color: black;
    }
}