@import url('https://fonts.googleapis.com/css2?family=Uncial+Antiqua&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Bodoni+Moda+SC:ital,opsz,wght@0,6..96,400..900;1,6..96,400..900&family=Bodoni+Moda:ital,opsz,wght@0,6..96,400..900;1,6..96,400..900&family=Playfair+Display+SC&display=swap');

:root {
    /* Premium Dark Greyscale Palette */
    --bg-base: #080808;
    --bg-surface: #121212;
    --bg-card: #1a1a1a;
    
    /* Text */
    --text-primary: #ffffff;
    --text-secondary: #999999;
    --text-muted: #666666;
    
    /* Severe Impact Red */
    --accent-red: #ff1e1e;
    --accent-red-hover: #cc0000;
    --accent-glow: rgba(255, 30, 30, 0.4);
    
    /* Borders & UI */
    --border-subtle: #2a2a2a;
    
    /* Typography */
    --font-heading: 'Bodoni Moda SC', serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

/* =========================================
   Global Reset & Typography
   ========================================= */
* { box-sizing: border-box; margin: 0; padding: 0; }

body { 
    font-family: var(--font-body); 
    
    /* Removed the dark gradient overlay! Now just the raw, clear image */
    background: url('../assets/images/bg.png') repeat top left fixed;
    background-size: auto; 
    
    color: var(--text-secondary); 
    line-height: 1.6; 
    overflow-x: hidden; 
}

h1, h2, h3 { font-family: var(--font-heading); color: var(--text-primary); font-weight: 700; letter-spacing: 1px; }
a { text-decoration: none; color: inherit; transition: all 0.3s ease; }

/* Utilities */
.mt-2 { margin-top: 1rem; }
.mt-4 { margin-top: 2rem; }
.text-center { text-align: center; }

/* =========================================
   Splash Screen
   ========================================= */
#splash-screen {
    position: fixed;
    inset: 0;
    background-color: var(--bg-base);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.6s cubic-bezier(0.8, 0, 0.2, 1), visibility 0.6s;
}
.splash-content {
    color: var(--text-primary);
    font-size: 4rem;
    font-weight: 800;
    font-family: var(--font-heading);
    letter-spacing: 2px;
    animation: pulseGlow 1.5s infinite;
}
.splash-hidden { opacity: 0; visibility: hidden; }

@keyframes pulseGlow {
    0%, 100% { transform: scale(1); text-shadow: 0 0 10px transparent; }
    50% { transform: scale(1.02); text-shadow: 0 0 20px var(--accent-glow); }
}

/* =========================================
   Global Navigation (Sub-pages)
   ========================================= */
.navbar { position: sticky; top: 0; background: rgba(18, 18, 18, 0.85); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border-subtle); z-index: 1000; }
.nav-container { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.2rem 0.5rem 1.2rem; max-width: 1200px; margin: auto; }
.logo-img { height: 80px; width: auto; display: block; filter: brightness(0) invert(1); }
.nav-links { display: flex; gap: 2.5rem; }
.nav-item { color: var(--text-secondary); font-weight: 500; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; position: relative; }
.nav-item:hover, .nav-item.active { color: var(--text-primary); }
.nav-item::after { content: ''; position: absolute; bottom: -5px; left: 0; width: 0%; height: 2px; background: var(--accent-red); transition: width 0.3s ease; }
.nav-item:hover::after, .nav-item.active::after { width: 100%; }
.hamburger { display: none; background: none; border: none; font-size: 1.8rem; color: var(--text-primary); cursor: pointer; }
.close-menu-btn { display: none; }

/* =========================================
   Core Layouts & Components
   ========================================= */
main { min-height: 80vh; max-width: 1200px; margin: 0 auto; padding: 4rem 2rem; animation: fadeIn 0.8s ease forwards; }

/* Pull the home page content up higher on the screen */
body[data-page="home"] main { padding-top: 1.5rem; padding-bottom: 2rem; }

@keyframes fadeIn { 
    from { opacity: 0; transform: translateY(10px); } 
    to { opacity: 1; transform: none; } /* 'none' prevents animation from trapping fixed menus */
}

/* Hero Section (Sub-pages) */
.hero { 
    text-align: center; 
    padding: 4rem 2rem 8rem 2rem; 
    background: rgba(18, 18, 18, 0.4); 
    backdrop-filter: blur(8px); /* Frosted glass effect over bg.png */
    border: 1px solid var(--border-subtle); 
    border-radius: 12px; 
    margin-bottom: 4rem; 
    position: relative; 
    overflow: hidden; 
}
.hero::before { content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 60%; height: 1px; background: radial-gradient(circle, var(--accent-red) 0%, transparent 100%); opacity: 0.5; }
.hero h1 { font-size: 3rem; color: var(--text-primary); }
.hero p { font-size: 1.25rem; color: var(--text-muted); margin-bottom: 2.5rem; max-width: 600px; margin-inline: auto; font-family: var(--font-body); }

/* Buttons */
.btn { display: inline-block; padding: 0.875rem 2.5rem; background: var(--accent-red); color: var(--text-primary); border-radius: 4px; border: 1px solid var(--accent-red); font-weight: 600; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 1px; transition: all 0.3s ease; box-shadow: 0 0 15px transparent; font-family: var(--font-body); }
.btn:hover { background: var(--accent-red-hover); border-color: var(--accent-red-hover); box-shadow: 0 0 20px var(--accent-glow); transform: translateY(-2px); }
.btn-outline { background: transparent; border: 1px solid var(--text-secondary); color: var(--text-primary); margin-left: 1rem; box-shadow: none; }
.btn-outline:hover { background: var(--text-primary); color: var(--bg-base); border-color: var(--text-primary); transform: translateY(-2px); box-shadow: none; }

/* Cards & Grid */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.card { 
    /* Changed to a semi-transparent dark grey (matches #1a1a1a but at 45% opacity) */
    background: rgba(26, 26, 26, 0.45); 
    
    /* Applies a strong blur to the background image underneath */
    backdrop-filter: blur(16px); 
    -webkit-backdrop-filter: blur(16px); /* For Safari support */
    
    padding: 1.25rem 2rem 2rem 2rem; 
    border: 1px solid rgba(255, 255, 255, 0.08); /* Softened the border slightly for the glass look */
    border-radius: 8px; 
    transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease; 
    position: relative; 
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%; 
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3); /* Adds a subtle drop shadow to lift it off the background */
}
.card::after { content: ''; position: absolute; bottom: 0; left: 0; width: 100%; height: 2px; background: var(--accent-red); transform: scaleX(0); transition: transform 0.4s ease; transform-origin: left; }
.card:hover { transform: translateY(-5px); border-color: #333; }
.card:hover::after { transform: scaleX(1); }
.card h3 { font-size: 1.4rem; margin-bottom: 1rem; color: var(--text-primary); }

/* Committee Card Specifics */
.committee-img { width: 100%; height: 220px; object-fit: cover; border-radius: 4px; border: 1px solid var(--border-subtle); margin-bottom: 1.5rem; }
.description-text { display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: 0.95rem; color: var(--text-secondary); }
.description-text.expanded { -webkit-line-clamp: unset; line-clamp: unset;}
.read-more-btn { background: none; border: none; color: var(--accent-red); cursor: pointer; padding: 0; font-size: 0.85rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; transition: color 0.3s ease; font-family: var(--font-body); }
.read-more-btn:hover { color: var(--text-primary); }

/* Data Tables (Travel) */
.table-wrapper { width: 100%; overflow-x: auto; border-radius: 8px; border: 1px solid var(--border-subtle); background: var(--bg-card); }
.styled-table { width: 100%; border-collapse: collapse; min-width: 700px; }
.styled-table thead tr { background-color: var(--bg-surface); color: var(--text-secondary); text-align: left; border-bottom: 2px solid var(--border-subtle); }
.styled-table th { padding: 1.2rem 1.5rem; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; font-weight: 600; font-family: var(--font-body); }
.styled-table td { padding: 1rem 1.5rem; border-bottom: 1px solid var(--border-subtle); color: var(--text-primary); font-size: 0.95rem; font-family: var(--font-body); }
.styled-table tbody tr { transition: background-color 0.2s ease; }
.styled-table tbody tr:hover { background-color: rgba(255, 255, 255, 0.02); }
.styled-table tbody tr:last-of-type { border-bottom: none; }

/* Forms */
.form-group { margin-bottom: 1.5rem; text-align: left; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 500; color: var(--text-secondary); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; font-family: var(--font-body); }
.form-group input, .form-group textarea { width: 100%; padding: 1rem; background: var(--bg-base); border: 1px solid var(--border-subtle); border-radius: 4px; color: var(--text-primary); font-family: inherit; transition: all 0.3s ease; }
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--accent-red); box-shadow: 0 0 0 1px var(--accent-red); }

/* Footer */
.site-footer { background: var(--bg-surface); border-top: 1px solid var(--border-subtle); padding: 5rem 2rem 2rem; margin-top: 4rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 3rem; max-width: 1200px; margin: auto; padding-bottom: 3rem; border-bottom: 1px solid var(--border-subtle); }
.footer-col h4 { color: var(--text-primary); font-size: 1rem; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 1.5rem; font-family: var(--font-body); }
.footer-col a { display: block; margin-bottom: 0.75rem; color: var(--text-muted); transition: color 0.3s ease; }
.footer-col a:hover { color: var(--accent-red); }
.footer-bottom { text-align: center; padding-top: 2rem; color: var(--text-muted); font-size: 0.85rem; font-family: var(--font-body); }
.disclaimer { margin-top: 0.5rem; font-style: italic; color: #555; }

/* =========================================
   Interactive Home Hero & Layout
   ========================================= */
.interactive-hero {
    position: relative;
    min-height: 60vh; /* Reduced from 80vh to save vertical space */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    border-radius: 12px;
    border: 1px solid var(--border-subtle);
    background: rgba(18, 18, 18, 0.4);
    backdrop-filter: blur(8px);
    overflow: hidden;
    margin-bottom: 2rem; /* Reduced from 4rem */
    --cursor-x: 50%;
    --cursor-y: 50%;
}
.interactive-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle 500px at var(--cursor-x) var(--cursor-y), rgba(255, 30, 30, 0.12), transparent 70%);
    z-index: 1;
    pointer-events: none;
    transition: background 0.1s ease-out;
}
.hero-content { position: relative; z-index: 2; padding: 1.5rem 2rem; width: 100%; }

/* Override the inline logo size to shrink it on desktop */
.hero-content img { 
    height: 250px !important; 
    margin: 0 auto 0 auto !important;
    display: block; 
}

/* Scaled down heading and text */
.interactive-hero h1 { font-size: 3.5rem; margin-bottom: 0.25rem; letter-spacing: -1px; text-shadow: 0 4px 20px rgba(0,0,0,0.5); }
.interactive-hero p { font-size: 1.25rem; color: var(--text-muted); letter-spacing: 1px; font-family: var(--font-body); }

/* Compress the spacing around the buttons */
.interactive-hero .btn { padding: 0.75rem 2rem; }
.hero-content > div[style] { margin-top: 1.5rem !important; margin-bottom: 2rem !important; }


/* Home Desktop Nav */
.portal-nav { margin-top: 1rem; text-align: center; }
.home-hamburger { display: none; background: none; border: none; color: var(--text-primary); font-size: 2.5rem; cursor: pointer; margin: 0 auto; transition: color 0.3s ease; font-family: var(--font-body); }
.home-hamburger:hover { color: var(--accent-red); }
.home-nav-links { display: flex; gap: 3rem; justify-content: center; }
.home-nav-links a { color: var(--text-secondary); font-weight: 600; text-transform: uppercase; letter-spacing: 2px; font-size: 0.9rem; position: relative; padding-bottom: 0.5rem; font-family: var(--font-body); }
.home-nav-links a:hover { color: var(--text-primary); }
.home-nav-links a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0%; height: 2px; background: var(--accent-red); transition: width 0.3s ease; }
.home-nav-links a:hover::after { width: 100%; }

/* Home Desktop Spacing */
.about-section, .highlights-section { margin-top: 5rem; }
.home-section-title { font-size: 2.5rem; text-align: center; margin-bottom: 2rem; }
.about-content { max-width: 800px; margin: auto; font-size: 1.15rem; color: var(--text-secondary); }
.about-content p { margin-bottom: 1.5rem; font-family: var(--font-body); }

/* Floating Mobile Navigation Button (Hidden on Desktop) */
.floating-nav-btn { display: none; }


/* =========================================
   Mobile Responsiveness (Max-width: 768px)
   ========================================= */
@media (max-width: 768px) {
    /* 1. GLOBAL Full-Screen Overlay (Sub-pages) */
    .nav-container { padding: 1rem 1.5rem; }
    .logo-img { height: 40px; }
    .hamburger { display: block; z-index: 2001; position: relative; }
    
    .nav-links {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100dvh;
        background: var(--bg-base);
        justify-content: center;
        align-items: center;
        gap: 3rem;
        z-index: 2000;
        opacity: 0;
        visibility: hidden;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        text-align: center;
        border: none;
    }
    .nav-links.show { opacity: 1; visibility: visible; }
    .nav-links a { font-size: 1.8rem; }

    /* 2. HOME PAGE Full-Screen Overlay */
    .home-hamburger {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        background: transparent;
        border: 1px solid var(--border-subtle);
        color: var(--text-primary);
        padding: 0.75rem 2rem;
        font-size: 1rem;
        text-transform: uppercase;
        letter-spacing: 2px;
        border-radius: 4px;
        margin: 0 auto;
        transition: border-color 0.3s ease;
    }
    .home-hamburger:hover { border-color: var(--accent-red); }
    
    .home-nav-links {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100dvh;
        background: var(--bg-base);
        justify-content: center;
        align-items: center;
        gap: 3rem;
        z-index: 2000;
        opacity: 0;
        visibility: hidden;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        margin: 0;
    }
    .home-nav-links.show { opacity: 1; visibility: visible; }
    .home-nav-links a { font-size: 2rem; }
    
    .close-menu-btn {
        display: block;
        position: absolute;
        top: 2rem;
        right: 2rem;
        background: none;
        border: none;
        color: var(--text-primary);
        font-size: 2.5rem;
        cursor: pointer;
        transition: color 0.3s ease;
    }
    .close-menu-btn:hover { color: var(--accent-red); }

    /* 3. General Mobile Spacing & Layout */
    main { padding: 2rem 1rem; }
    .hero { padding: 4rem 1.5rem; margin-bottom: 2.5rem; border-radius: 8px; }
    
    /* Increased the Heading size for mobile */
    .hero h1, .interactive-hero h1 { font-size: 2.8rem; line-height: 1.1; }
    
    /* Decreased the Paragraph size for mobile */
    .hero p, .interactive-hero p { font-size: 0.85rem; margin-bottom: 1.5rem; }
    
    /* Scale the logo down slightly just for phones */
    .hero-content img { height: 200px !important; align-self: center;}
    
    .btn { display: block; width: 100%; margin-bottom: 1rem; padding: 1rem; text-align: center; }
    .btn-outline { margin-left: 0; margin-top: 0.5rem; }
    
    .grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .card { padding: 1.5rem; }
    .card h3 { font-size: 1.25rem; }
    
    .splash-content { font-size: 2.5rem; }
    .site-footer { padding: 3rem 1.5rem 1.5rem; margin-top: 2rem; }
    .footer-grid { gap: 2rem; padding-bottom: 2rem; }

    /* 4. Home Page Snap Scrolling */
    body[data-page="home"] {
        height: 100dvh;
        height: 100vh;
        overflow-y: scroll;
        scroll-snap-type: y mandatory;
        scroll-behavior: smooth;
    }
    body[data-page="home"] main { padding: 0; margin: 0; max-width: 100%; }
    
    .home-snap-section {
        height: 100dvh;
        width: 100vw;
        scroll-snap-align: start;
        scroll-snap-stop: always;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 1rem 1.5rem;
        margin: 0 !important;
        box-sizing: border-box;
    }
    body[data-page="home"] .interactive-hero { border: none; border-radius: 0; }
    body[data-page="home"] .home-section-title { font-size: 2rem; margin-bottom: 1.5rem; }
    body[data-page="home"] .about-content p { font-size: 1rem; margin-bottom: 1rem; }
    
    body[data-page="home"] .highlights-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
        width: 100%;
        max-width: 500px;
    }
    body[data-page="home"] .highlights-grid .card { padding: 1rem; }
    body[data-page="home"] .highlights-grid h3 { font-size: 1.1rem; }
    body[data-page="home"] .highlights-grid p { font-size: 0.85rem; }
    
    body[data-page="home"] .site-footer { scroll-snap-align: end; }

    /* 5. Floating Committee Nav Button (Visible only on Mobile) */
    .floating-nav-btn {
        display: block;
        position: fixed;
        bottom: 2rem;
        left: 1.5rem;
        background: rgba(255, 30, 30, 0.9);
        backdrop-filter: blur(10px);
        color: var(--text-primary);
        border: 1px solid var(--accent-red);
        padding: 0.8rem 1.2rem;
        border-radius: 30px;
        font-weight: 700;
        font-size: 0.8rem;
        text-transform: uppercase;
        letter-spacing: 1px;
        box-shadow: 0 4px 15px rgba(0,0,0,0.6), 0 0 15px var(--accent-glow);
        z-index: 1000;
        cursor: pointer;
        transition: all 0.3s ease;
        font-family: var(--font-body);
    }
}

/* Extra fix for very small phones (like iPhone SE) */
@media (max-width: 380px) {
    .hero h1, .interactive-hero h1 { font-size: 1.8rem; }
    .btn { font-size: 0.85rem; }
}