:root {
    --primary-color: #003366; /* Deep Blue */
    --secondary-color: #f0f4f8; /* Light Gray */
    --accent-color: #ffc107; /* Bright Yellow */
    --text-color: #333;
    --heading-font: 'Poppins', sans-serif;
    --body-font: 'Lato', sans-serif;
    --border-radius: 8px;
    --shadow: 0 4px 12px rgba(0,0,0,0.08);
    --animation-duration: 0.5s;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
}

body {
    font-family: var(--body-font);
    color: var(--text-color);
    line-height: 1.6;
    background-color: #fcfdff;
}

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

h1, h2, h3 {
    font-family: var(--heading-font);
    font-weight: 600;
    color: var(--primary-color);
    line-height: 1.2;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; margin-bottom: 1.5rem; text-align: center; }
h3 { font-size: 1.4rem; }

a {
    color: var(--primary-color);
    text-decoration: none;
}

/* Header */
header {
    background-color: #ffffff;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow 0.3s ease, background-color 0.3s ease;
}

header.scrolled {
    box-shadow: 0 2px 10px rgba(0,0,0,0.07);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.logo {
    height: 45px;
    margin-right: 10px;
}

#main-nav ul {
    display: flex;
    list-style-type: none;
    gap: 2rem;
}

#main-nav a {
    font-weight: 600;
    padding: 0.5rem 0;
    position: relative;
}

#main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

#main-nav a:hover::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cta-button {
    font-family: var(--heading-font);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    border: none;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-button.primary-cta {
    background-color: var(--accent-color);
    color: var(--primary-color);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.15);
}

#menu-toggle {
    display: none;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: var(--primary-color);
    cursor: pointer;
}

/* Hero Section */
.hero {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 80vh;
    min-height: 550px;
    background: url(lib.jpg) no-repeat center center/cover;
    color: white;
    padding: 0 20px;
    position: relative;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 51, 102, 0.8), rgba(0, 51, 102, 0.85));
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    padding: 2rem;
    border-radius: var(--border-radius);
    background-color: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(5px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    animation: fadeIn 1s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.hero-content h1 {
    color: white;
    font-size: 3.5rem;
    font-weight: 700;
    min-height: 1em; /* Reserve space for typing text */
    margin-bottom: 1rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.3rem;
    margin: 1.5rem 0 2.5rem;
    max-width: 800px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.hero .cta-button {
    font-size: 1.1rem;
    padding: 0.9rem 2.2rem;
    border-radius: 30px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.hero .primary-btn {
    background-color: var(--accent-color);
    color: var(--primary-color);
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.4);
}

.hero .secondary-btn {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.hero .primary-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(255, 193, 7, 0.5);
}

.hero .secondary-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-5px);
}

/* Sections */
section {
    padding: 5rem 0;
}

section.quick-links {
    background-color: var(--secondary-color);
}
section.programs {
    background-color: var(--secondary-color);
}

.section-subtitle {
    text-align: center;
    max-width: 600px;
    margin: -1rem auto 3rem;
    font-size: 1.1rem;
    color: #555;
}

/* Filter Controls */
.filter-controls {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 3rem;
}

.filter-btn {
    font-family: var(--heading-font);
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    border: 2px solid var(--primary-color);
    background-color: transparent;
    color: var(--primary-color);
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

.filter-btn.active {
    background-color: var(--primary-color);
    color: white;
}

/* Card Grid */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.card {
    background: #fff;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e0e0e0;
}

.card.hidden {
    display: none; /* For filtering */
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0,51,102,0.15);
}

.card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-content h3 {
    margin-bottom: 0.75rem;
}

.card-content p {
    flex-grow: 1;
    margin-bottom: 1.5rem;
    color: #555;
}

.card .read-more {
    font-weight: 700;
    color: var(--primary-color);
    align-self: flex-start;
    padding: 0.6rem 1.2rem;
    border-radius: var(--border-radius);
    background-color: var(--accent-color);
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.card .read-more:hover {
    background-color: #004a8c;
    color: white;
    transform: scale(1.05);
}

/* Quick Links Section */
.quick-links .links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.quick-links .quick-link-card {
    background: #fff;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e0e0e0;
    text-align: center;
}

.quick-links .quick-link-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0,51,102,0.15);
}

.quick-link-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.quick-links .quick-link-card h3 {
    margin-bottom: 0.5rem;
}

.quick-links .quick-link-card p {
    color: #555;
    margin-bottom: 1.5rem;
}

.quick-links .quick-link-card span {
    font-weight: 600;
    color: var(--primary-color);
}

/* Stats Bar */
.stats-bar {
    background-color: var(--primary-color);
    color: white;
    padding: 3rem 0;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.5s ease-out forwards;
}
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}
.stat-item h3 {
    color: var(--accent-color);
    font-size: 3rem;
    font-weight: 700;
}
.stat-label {
    font-size: 1rem;
    color: var(--secondary-color);
}

/* Team Section */
.team {
    background-color: #fff;
    padding: 6rem 0;
}

.committee-intro {
    max-width: 800px;
    margin: 0 auto 3rem;
    text-align: center;
    position: relative;
    padding: 2rem;
    background-color: rgba(240, 244, 248, 0.7);
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
}

.committee-intro p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #444;
}

.committee-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--primary-color), #004a8c);
    color: white;
    padding: 0.5rem 1.5rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 3px 10px rgba(0, 51, 102, 0.2);
    letter-spacing: 0.05em;
}
/* Organization Tree Structure */
.org-tree {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 3rem;
    position: relative;
    padding: 2rem 0;
    background: linear-gradient(to bottom, rgba(240, 244, 248, 0.5), rgba(255, 255, 255, 0.8));
    border-radius: 12px;
}

.org-level {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2.5rem;
    width: 100%;
    margin-bottom: 2rem;
    position: relative;
    z-index: 2;
}

.chairperson-level {
    margin-bottom: 2.5rem;
}

.org-connector {
    width: 3px;
    height: 50px;
    background: linear-gradient(to bottom, var(--primary-color), var(--accent-color));
    margin: 0 auto 1.5rem;
    position: relative;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.org-connector:before {
    content: '';
    position: absolute;
    width: 80%;
    height: 3px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.team-member {
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    width: 240px;
    position: relative;
}

.team-member:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    opacity: 0.8;
}

.chairperson {
    border: none;
    transform: scale(1.08);
    box-shadow: 0 8px 30px rgba(0, 51, 102, 0.15);
}

.chairperson:before {
    height: 8px;
    background: var(--accent-color);
}

.team-member:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 15px 30px rgba(0, 51, 102, 0.2);
}

.chairperson:hover {
    transform: translateY(-8px) scale(1.1);
}

.member-photo-wrapper {
    height: 220px;
    overflow: hidden;
    position: relative;
}

.member-photo-wrapper:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    opacity: 0.7;
}

.member-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
    filter: saturate(1.1);
}

.team-member:hover .member-photo {
    transform: scale(1.08);
}

.member-info {
    padding: 1.8rem 1.5rem;
    text-align: center;
    position: relative;
    background: white;
    z-index: 1;
}

.member-info h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
    position: relative;
    display: inline-block;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.member-info h3:after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.team-member:hover .member-info h3:after {
    width: 60px;
}

.member-role {
    color: #555;
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    background-color: rgba(0, 51, 102, 0.08);
    margin-top: 5px;
}

.chairperson .member-role {
    background-color: rgba(255, 193, 7, 0.2);
    color: #333;
    font-weight: 700;
}

/* Testimonials Section */
.testimonials {
    background-color: var(--secondary-color);
    padding: 5rem 0;
}

.testimonial-slider {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
}

.testimonial-slide {
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.testimonial-slide.active {
    display: block;
    opacity: 1;
}

.testimonial-card {
    background-color: white;
    padding: 3rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 2rem;
    text-align: left;
    height: 100%;
}

.testimonial-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--accent-color);
}

.testimonial-content blockquote {
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 1.5rem;
    border-left: 4px solid var(--primary-color);
    padding-left: 1.5rem;
    color: #444;
}

.testimonial-name {
    display: block;
    font-weight: 700;
    font-family: var(--heading-font);
    color: var(--primary-color);
}

.testimonial-title {
    color: #666;
    font-size: 0.9rem;
}

.slider-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 2rem;
    gap: 1rem;
}

.slider-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.slider-btn:hover {
    background-color: var(--accent-color);
    color: var(--primary-color);
}

.slider-dots {
    display: flex;
    gap: 0.5rem;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #ccc;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.slider-dot.active {
    background-color: var(--primary-color);
}

/* Principal Message Section */
.principal-message {
    padding: 4rem 0;
    background-color: #fff;
}
.principal-card {
    background-color: var(--secondary-color);
    padding: 3rem;
    border-radius: var(--border-radius);
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 2.5rem;
    border-left: 10px solid var(--primary-color);
}
.principal-avatar {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid white;
    box-shadow: var(--shadow);
    flex-shrink: 0;
}
.principal-content h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
}
.principal-content blockquote {
    font-size: 1.1rem;
    font-style: italic;
    margin-bottom: 1.5rem;
    color: #444;
}
.principal-name {
    display: block;
    font-weight: 700;
    font-family: var(--heading-font);
    color: var(--primary-color);
}
.principal-title {
    color: #666;
    font-size: 0.9rem;
}

/* Grids - DEPRECATED since combined */
.links-grid {
    display: none;
}
.quick-link-card {
    display: none;
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: #fff;
    padding-top: 3rem;
}

footer a {
    color: #fff;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 2rem;
    padding-bottom: 2rem;
}

.footer-col h4 {
    font-family: var(--heading-font);
    font-weight: 600;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-col ul {
    list-style-type: none;
}

.footer-col li {
    margin-bottom: 0.5rem;
}

.footer-col .logo-link {
    color: #fff;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}
.footer-col .logo-link .logo {
    filter: brightness(0) invert(1);
}
.footer-col p {
    color: var(--secondary-color);
    max-width: 300px;
}
.footer-col .social-links {
    display: flex;
    gap: 1rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.2);
    text-align: center;
    padding: 1.5rem 0;
    font-size: 0.9rem;
    color: var(--secondary-color);
}

/* Animations */
@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 992px) {
    #main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: white;
        box-shadow: 0 10px 10px rgba(0,0,0,0.05);
    }
    #main-nav.active {
        display: block;
    }
    #main-nav ul {
        flex-direction: column;
        padding: 1rem;
        gap: 0;
    }
    #main-nav li {
       text-align: center;
    }
    #main-nav a {
        display: block;
        padding: 1rem;
    }
    #main-nav a:hover {
        background-color: var(--secondary-color);
    }
    #main-nav a::after {
        display: none;
    }

    #menu-toggle {
        display: block;
    }
    
    .header-actions .primary-cta {
        display: none;
    }
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .footer-col .logo-link, .footer-col .social-links {
        justify-content: center;
    }
    .footer-col p {
        margin-left: auto;
        margin-right: auto;
    }

    .testimonial-card {
        flex-direction: column;
        text-align: center;
        padding: 2rem;
    }
    .testimonial-content blockquote {
        border-left: none;
        padding-left: 0;
    }
    
    .org-tree {
        padding: 0 1rem;
    }
    
    .org-level {
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
    }
    
    .org-connector {
        height: 30px;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
    }
    
    .slider-controls {
        flex-wrap: wrap;
    }
    
    .principal-card {
        flex-direction: column;
        text-align: center;
        padding: 2rem;
        border-left: none;
        border-top: 10px solid var(--primary-color);
    }
}

@media (max-width: 768px) {
    h1, .hero-content h1 {
        font-size: 2.5rem;
    }
    h2 {
        font-size: 2rem;
    }
}