:root {
    --primary: #2a7d46;
    --primary-dark: #1e5a32;
    --accent: #f4a261;
    --light: #f8f9fa;
    --dark: #1a1a1a;
    --text: #333;
    --white: #fff;
    --shadow: 0 10px 30px rgba(0,0,0,0.1);
    --radius: 12px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; color: var(--text); background: #f4f6f8; line-height: 1.6; }

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* Top school bar */
.school-topbar { background: linear-gradient(90deg, #2c2c2c, #3d3d3d, #2c2c2c); color: #00d4ff; padding: 12px 0; text-align: center; border-bottom: 3px solid #00d4ff; }
.school-info h1 { font-size: 2rem; font-weight: 700; color: #00d4ff; margin-bottom: 2px; text-transform: uppercase; letter-spacing: 1px; }
.school-info p { font-size: 1.05rem; font-weight: 600; color: #00d4ff; margin: 0; line-height: 1.3; }

/* Header */
.header { background: var(--white); box-shadow: var(--shadow); position: sticky; top: 0; z-index: 1000; animation: slideDown 0.6s ease; }

.header .container { display: flex; align-items: center; justify-content: space-between; padding: 10px 20px; gap: 15px; }
.logo { display: flex; align-items: center; }
.logo img { height: 80px; width: auto; object-fit: contain; }
.logo-icon { width: 80px; height: 80px; background: var(--primary); color: var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 2.2rem; }

/* Navigation */
.nav { flex: 1; display: flex; justify-content: flex-end; min-width: 0; }
.nav > ul { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; width: 100%; }
.nav li { position: relative; flex: 0 0 auto; }
.nav > ul > li > a { display: block; padding: 8px 12px; font-size: 0.75rem; font-weight: 600; color: var(--dark); border-radius: 4px; white-space: nowrap; text-transform: uppercase; }
.nav > ul > li:hover > a { background: var(--primary); color: var(--white); }
.nav li .dropdown { position: absolute; top: 100%; left: 0; background: var(--white); min-width: 220px; box-shadow: var(--shadow); border-radius: var(--radius); opacity: 0; visibility: hidden; transform: translateY(10px); transition: all 0.3s; overflow: hidden; z-index: 1001; display: none; }
.nav li:hover .dropdown { display: block; opacity: 1; visibility: visible; transform: translateY(0); }
#desktop-dropdown { position: absolute; display: none; background: var(--white); min-width: 220px; box-shadow: var(--shadow); border-radius: var(--radius); overflow: hidden; z-index: 99999; }
#desktop-dropdown li { display: block; }
#desktop-dropdown li a { display: block; padding: 10px 15px; color: var(--text); border-bottom: 1px solid #f0f0f0; }
#desktop-dropdown li a:hover { background: var(--primary); color: var(--white); }
.dropdown li a { display: block; padding: 10px 15px; font-size: 0.85rem; border-bottom: 1px solid #f0f0f0; color: var(--text); }
.dropdown li a:hover { background: var(--primary); color: var(--white); padding-left: 22px; }

.mobile-toggle { display: none; font-size: 1.5rem; background: var(--primary); color: var(--white); border: none; padding: 8px 12px; border-radius: 6px; cursor: pointer; }

/* Notice bar */
.notice-bar { background: linear-gradient(90deg, var(--accent), #e76f51); color: var(--white); padding: 12px 15px; text-align: center; font-weight: 600; white-space: normal; animation: pulseBar 2.5s infinite; }
.notice-bar a { color: var(--white); text-decoration: underline; }

/* Hero */
.hero { position: relative; height: 70vh; min-height: 500px; background: linear-gradient(135deg, rgba(20,60,35,0.82), rgba(10,40,20,0.9)), url('../images/hero.jpg') center/cover no-repeat; display: flex; align-items: center; justify-content: center; text-align: center; color: var(--white); overflow: hidden; }
.hero-content { max-width: 800px; padding: 20px; animation: fadeInUp 1s ease; }
.hero h2 { font-size: 2.8rem; margin-bottom: 15px; text-shadow: 2px 2px 4px rgba(0,0,0,0.4); }
.hero p { font-size: 1.2rem; margin-bottom: 25px; }
.hero-slider { position: relative; height: 70vh; min-height: 500px; overflow: hidden; background: var(--dark); }
.hero-slider .slide { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity 0.8s ease; z-index: 1; }
.hero-slider .slide.active { opacity: 1; z-index: 2; }
.slide-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.4); }
.slide-content { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); text-align: center; color: var(--white); z-index: 2; width: 90%; max-width: 900px; }
.slide-content h2 { font-size: 2.8rem; margin-bottom: 15px; text-shadow: 2px 2px 4px rgba(0,0,0,0.4); }
.slide-content p { font-size: 1.2rem; margin-bottom: 25px; }
.slider-prev, .slider-next { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.2); color: var(--white); border: none; width: 45px; height: 45px; border-radius: 50%; font-size: 1.2rem; cursor: pointer; z-index: 10; backdrop-filter: blur(4px); transition: 0.3s; }
.slider-prev:hover, .slider-next:hover { background: var(--primary); }
.slider-prev { left: 20px; }
.slider-next { right: 20px; }
.slider-dots { position: absolute; bottom: 25px; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; z-index: 10; }
.slider-dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--white); background: transparent; cursor: pointer; }
.slider-dot.active { background: var(--white); }
.btn { display: inline-block; padding: 12px 28px; background: var(--accent); color: var(--white); border-radius: 50px; font-weight: 700; box-shadow: 0 5px 15px rgba(244,162,97,0.4); transition: 0.3s; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(244,162,97,0.5); background: #e89550; }
.btn-outline { background: transparent; border: 2px solid var(--white); }
.btn-outline:hover { background: var(--white); color: var(--primary); }

/* Sections */
.section { padding: 70px 0; }
.section-title { text-align: center; margin-bottom: 45px; }
.section-title h2 { font-size: 2rem; color: var(--primary); margin-bottom: 10px; position: relative; display: inline-block; }
.section-title h2::after { content: ''; position: absolute; width: 60px; height: 4px; background: var(--accent); bottom: -8px; left: 50%; transform: translateX(-50%); border-radius: 2px; }
.section-title p { color: #666; margin-top: 15px; }
.section-title.light h2, .section-title.light p { color: #fff; }

.container { width: 92%; max-width: 1200px; margin: 0 auto; }

/* Cards */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 25px; }
.card { background: var(--white); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); transition: 0.4s; text-align: center; }
.card:hover { transform: translateY(-8px); box-shadow: 0 15px 35px rgba(0,0,0,0.12); }
.card-icon { width: 70px; height: 70px; background: var(--primary); color: var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.8rem; margin: 0 auto 18px; transition: 0.3s; }
.card:hover .card-icon { transform: rotate(360deg); background: var(--accent); }
.card h3 { color: var(--primary); margin-bottom: 10px; }
.card p { color: #666; font-size: 0.95rem; }

/* Quick links */
.quick-links { background: #fff; padding: 30px 0; border-bottom: 1px solid #eee; }
.quick-links .container { display: grid; grid-template-columns: repeat(4, 1fr); text-align: center; }
.quick-item { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 20px; color: var(--text); border-right: 1px solid #eee; font-weight: 600; text-transform: uppercase; transition: 0.3s; }
.quick-item:last-child { border-right: none; }
.quick-item i { font-size: 1.8rem; color: var(--primary); }
.quick-item:hover { color: var(--primary); }

/* YouTube videos */
.video-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.video-card { position: relative; padding-bottom: 56.25%; background: #000; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.video-card iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }

/* Activity / Success cards */
.activity-card, .story-card { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: 0.3s; text-align: center; }
.activity-card:hover, .story-card:hover { transform: translateY(-5px); box-shadow: 0 15px 35px rgba(0,0,0,0.12); }
.activity-card img, .story-card img { width: 100%; height: 220px; object-fit: cover; display: block; }
.activity-card h3, .story-card h3 { padding: 18px 15px 5px; color: var(--primary); }
.activity-card .btn-sm, .story-card p { margin-bottom: 20px; }
.story-card p { padding: 0 15px 20px; color: #666; }
.btn-sm { padding: 8px 20px; font-size: 0.85rem; }

/* Page banner */
.page-banner { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--white); padding: 80px 0 60px; text-align: center; position: relative; overflow: hidden; }
.page-banner h1 { font-size: 2.2rem; animation: fadeInUp 0.8s ease; }
.page-banner .breadcrumbs { margin-top: 10px; opacity: 0.9; }
.page-banner::before { content: ''; position: absolute; top: -50%; right: -10%; width: 300px; height: 300px; background: rgba(255,255,255,0.1); border-radius: 50%; animation: float 6s ease-in-out infinite; }

.page-content { background: var(--white); padding: 50px 0; min-height: 400px; }
.page-content .container { background: var(--white); padding: 30px; border-radius: var(--radius); box-shadow: var(--shadow); }
.page-content h2, .page-content h3 { color: var(--primary); margin: 20px 0 10px; }
.page-content p { margin-bottom: 15px; }
.page-content ul { list-style: disc; margin-left: 20px; margin-bottom: 15px; }
.page-content img { max-width: 100%; border-radius: 8px; margin: 15px 0; }
.page-section { margin-top: 40px; padding-top: 30px; border-top: 1px solid #eee; }
.section-content { font-size: 1rem; line-height: 1.8; }
.section-img { width: 100%; border-radius: 8px; box-shadow: var(--shadow); }
.section-image-only { text-align: center; }
.section-pdf { margin: 20px 0; }
.section-video { margin: 20px 0; }
.section-table { overflow-x: auto; }
.section-table table { width: 100%; border-collapse: collapse; margin: 15px 0; }
.section-table th, .section-table td { border: 1px solid #ddd; padding: 10px; text-align: left; }
.section-table th { background: var(--primary); color: #fff; }

/* Custom Editor */
.custom-editor { 
    border: 2px solid #e0e0e0; 
    border-radius: 12px; 
    overflow: hidden; 
    background: #fff; 
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: box-shadow 0.3s ease;
}
.custom-editor:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.12); }

.editor-toolbar { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 6px; 
    padding: 12px 15px; 
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%); 
    border-bottom: 2px solid #e0e0e0;
}

.editor-toolbar button { 
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%); 
    border: 1px solid #d0d0d0; 
    border-radius: 6px; 
    padding: 8px 12px; 
    cursor: pointer; 
    font-size: 0.85rem; 
    font-weight: 600; 
    min-width: 38px; 
    min-height: 38px;
    color: #495057;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.editor-toolbar button:hover { 
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%); 
    color: #fff; 
    border-color: var(--primary); 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(42,125,70,0.3);
}

.editor-toolbar button:active { 
    transform: translateY(0); 
    box-shadow: 0 2px 4px rgba(42,125,70,0.2);
}

.editor-area { 
    min-height: 300px; 
    padding: 20px; 
    outline: none; 
    line-height: 1.8; 
    font-size: 1rem;
    color: #333;
    background: #fff;
}

.editor-area:focus { 
    background: #fafbfc;
}

.editor-source { 
    width: 100%; 
    min-height: 300px; 
    padding: 20px; 
    font-family: 'Courier New', monospace; 
    font-size: 0.9rem;
    border: none; 
    resize: vertical; 
    background: #2d2d2d;
    color: #f8f8f2;
    line-height: 1.6;
}

/* Contact form */
.contact-form { max-width: 600px; margin: 0 auto; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 600; color: var(--primary); }
.form-group input, .form-group textarea, .form-group select { width: 100%; padding: 12px; border: 1px solid #ddd; border-radius: 8px; font-size: 1rem; transition: 0.3s; }
.form-group input:focus, .form-group textarea:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px rgba(42,125,70,0.1); }
.form-group textarea { min-height: 120px; resize: vertical; }

.alert { padding: 12px 18px; border-radius: 8px; margin-bottom: 20px; }
.alert-success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.alert-error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

/* Footer */
.footer { background: var(--dark); color: #ccc; padding: 50px 0 0; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 30px; margin-bottom: 30px; }
.footer h4 { color: var(--white); margin-bottom: 18px; font-size: 1.1rem; }
.footer a { color: #bbb; display: block; margin-bottom: 8px; }
.footer a:hover { color: var(--accent); padding-left: 5px; }
.footer-bottom { border-top: 1px solid #444; padding: 18px 0; text-align: center; color: #999; font-size: 0.9rem; }

/* Animations */
@keyframes slideDown { from { transform: translateY(-100%); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulseLogo { 0%,100% { transform: scale(1); } 50% { transform: scale(1.05); } }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-20px); } }
@keyframes marquee { 0% { transform: translateX(100%); } 100% { transform: translateX(-100%); } }
@keyframes pulseBar { 0%,100% { opacity: 1; } 50% { opacity: 0.85; } }

.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s ease; }
.reveal.active { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 1100px) {
    .mobile-toggle { display: block; }
    .nav { position: absolute; top: 100%; left: 0; width: 100%; background: var(--white); box-shadow: var(--shadow); display: none; overflow: visible; }
    .nav.active { display: block; animation: fadeInUp 0.4s ease; }
    .nav > ul { flex-direction: column; width: auto; overflow: visible; padding: 10px; }
    .nav li .dropdown { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; display: none; padding-left: 15px; }
    .nav li.active .dropdown { display: block; }
    #desktop-dropdown { display: none !important; }
    .header { position: relative; }
    .hero h2 { font-size: 2rem; }
}
