:root {
    --primary: #E35336;
    --primary-light: #FFD3AC;
    --secondary: #9988A1;
    --accent: #8A2B0E;
    --text: #1f2937;
    --text-muted: #6b7280;
    --light-bg: #FFF8F0;
    --border: #E8D5C0;
    --radius: 18px;
    --radius-lg: 26px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text);
    background: #ffffff;
    padding-top: 78px;
}

.navbar-school {
    background: linear-gradient(135deg, rgba(227, 83, 54, 0.96), rgba(255, 211, 172, 0.96));
    box-shadow: 0 10px 30px rgba(227, 83, 54, 0.18);
    transition: all 0.25s ease;
    backdrop-filter: blur(12px);
}

.navbar-school.scrolled {
    box-shadow: 0 8px 24px rgba(227, 83, 54, 0.18);
}

.navbar-school .navbar-brand,
.navbar-school .nav-link {
    color: #fff !important;
}

.navbar-school .navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 800;
}

.navbar-school .navbar-brand img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    padding: 3px;
}

.navbar-school .brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.navbar-school .brand-text small {
    font-size: 0.72rem;
    opacity: 0.82;
    font-weight: 600;
}

.navbar-school .nav-link {
    font-weight: 600;
    opacity: 0.9;
    border-radius: 999px;
    padding: 0.5rem 0.9rem !important;
}

.navbar-school .nav-link:hover,
.navbar-school .nav-link.active {
    opacity: 1;
    background: rgba(255,255,255,0.12);
}

.navbar-school .btn-login {
    background: var(--secondary);
    color: #1f2937 !important;
    padding: 0.55rem 1rem !important;
}

.hero-section {
    position: relative;
    overflow: hidden;
    padding: 5rem 0 4rem;
    background: linear-gradient(135deg, #8A2B0E 0%, #E35336 50%, #FFD3AC 100%) !important;
    color: #fff;
}

.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top left, rgba(255,255,255,0.12), transparent 35%), radial-gradient(circle at bottom right, rgba(255,255,255,0.08), transparent 30%);
    pointer-events: none;
}

.hero-section > .container,
.section-padding > .container,
.public-footer > .container {
    position: relative;
    z-index: 1;
}

.hero-school-logo {
    width: 96px;
    height: 96px;
    border-radius: 24px;
    object-fit: contain;
    background: rgba(255,255,255,0.12);
    padding: 8px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255,255,255,0.14);
    border: 1px solid rgba(255,255,255,0.18);
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.hero-section h1 {
    font-size: clamp(2.4rem, 5vw, 4.6rem);
    font-weight: 800;
    line-height: 1.05;
    margin-bottom: 1rem;
}

.hero-tagline {
    color: rgba(255,255,255,0.88);
    font-size: 1.08rem;
    line-height: 1.8;
    max-width: 42rem;
}

.hero-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    border-radius: 999px;
    padding: 0.95rem 1.35rem;
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.hero-btn:hover {
    transform: translateY(-2px);
}

.hero-btn-primary {
    background: var(--secondary);
    color: #1e293b;
    box-shadow: 0 16px 32px rgba(255, 193, 7, 0.35);
}

.hero-btn-primary:hover {
    color: #111827;
}

.hero-btn-outline {
    border: 1px solid rgba(255,255,255,0.55);
    color: #fff;
    background: rgba(255,255,255,0.08);
}

.hero-btn-outline:hover {
    color: #fff;
    background: rgba(255,255,255,0.16);
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.stat-item {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.16);
    border-radius: 20px;
    padding: 1rem;
    text-align: center;
    backdrop-filter: blur(8px);
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 800;
}

.stat-label {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.78);
}

.section-padding {
    padding: 5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.section-header h2 {
    font-size: clamp(2rem, 4vw, 3.2rem);
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.section-header .lead {
    color: var(--text-muted);
    max-width: 760px;
    margin: 0 auto;
}

.about-section,
.gallery-section,
.contact-section {
    background: #fff;
}

.facilities-section,
.leadership-section,
.admission-section {
    background: var(--light-bg);
}

.about-image-wrapper,
.hero-image-wrapper {
    position: relative;
}

.about-values {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.value-item {
    background: #FFF8F0;
    color: var(--primary);
    border-radius: 999px;
    padding: 0.45rem 0.85rem;
    font-weight: 600;
    border: 1px solid #E8D5C0;
}

.facility-card,
.contact-card,
.admission-form-card,
.admission-info-card,
.leader-card,
.gallery-event-block {
    background: #fff;
    border: 1px solid rgba(227, 83, 54, 0.08);
    border-radius: var(--radius);
    box-shadow: 0 12px 30px rgba(227, 83, 54, 0.06);
}

/* ==================== BRANCH CARDS ==================== */
.branch-card {
    background: #fff;
    border: 2px solid rgba(227, 83, 54, 0.1);
    border-radius: var(--radius-lg);
    padding: 2rem;
    height: 100%;
    position: relative;
    transition: all 0.3s ease;
    box-shadow: 0 12px 30px rgba(227, 83, 54, 0.08);
}

.branch-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(227, 83, 54, 0.12);
    border-color: rgba(227, 83, 54, 0.2);
}

.branch-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.branch-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.branch-icon.secondary {
    background: linear-gradient(135deg, var(--secondary), #ffb300);
    color: #1f2937;
}

.branch-badge {
    background: #FFF8F0;
    color: var(--primary);
    padding: 0.4rem 1rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid #E8D5C0;
}

.branch-badge.main {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    border: none;
}

.branch-card h4 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-weight: 700;
}

.branch-address {
    color: var(--text-muted);
    margin-bottom: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.branch-address i {
    color: var(--primary);
    margin-top: 0.25rem;
}

.branch-details {
    margin-bottom: 1.25rem;
}

.branch-detail-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--light-bg);
    color: var(--text-muted);
    font-size: 0.95rem;
}

.branch-detail-item:last-child {
    border-bottom: none;
}

.branch-detail-item i {
    color: var(--primary);
    width: 20px;
}

.branch-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.feature-tag {
    background: #FFF8F0;
    color: var(--primary);
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.coming-soon-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(4px);
}

.coming-soon-overlay span {
    background: linear-gradient(135deg, var(--secondary), #ffb300);
    color: #1f2937;
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.facility-card,
.contact-card,
.admission-info-card {
    padding: 1.5rem;
    height: 100%;
}

.facility-icon,
.contact-icon,
.leader-image {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #E35336, #FFD3AC);
    color: #fff;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.facility-card h5,
.contact-card h5,
.admission-info-card h5 {
    color: var(--primary);
    font-weight: 700;
}

.facility-card p,
.contact-card p,
.admission-info-card li,
.leader-message,
.event-desc {
    color: var(--text-muted);
}

.admission-form-card {
    padding: 1.75rem;
}

.btn-submit {
    border: none;
    border-radius: 999px;
    padding: 0.95rem 1.25rem;
    background: linear-gradient(135deg, #E35336, #FFD3AC);
    color: #fff;
    font-weight: 700;
    box-shadow: 0 14px 28px rgba(227, 83, 54, 0.2);
}

.btn-submit:hover {
    filter: brightness(1.05);
}

.form-control,
.form-select {
    border-radius: 14px;
    padding: 0.8rem 1rem;
    border-color: #dbe4f0;
}

.form-control:focus,
.form-select:focus {
    box-shadow: 0 0 0 0.2rem rgba(227, 83, 54, 0.15);
    border-color: var(--primary-light);
}

.leader-card {
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.leader-info h4 {
    margin-bottom: 0.25rem;
    color: var(--primary);
}

.leader-role,
.leader-qual {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.gallery-slider-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.gallery-slider {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(220px, 1fr);
    gap: 1rem;
    overflow-x: auto;
    padding: 0.25rem;
    scrollbar-width: thin;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    min-height: 180px;
    background: #edf2f7;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    min-height: 180px;
    object-fit: cover;
    display: block;
}

.gallery-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 0.75rem;
    color: #fff;
    background: linear-gradient(180deg, transparent, rgba(0,0,0,0.7));
}

.slider-nav {
    border: 0;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #fff;
    color: var(--primary);
    box-shadow: 0 8px 20px rgba(227, 83, 54, 0.15);
}

.marquee-bar {
    background: #8A2B0E;
    color: #fff;
    overflow: hidden;
    white-space: nowrap;
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.marquee-content {
    display: inline-flex;
    gap: 3rem;
    padding: 0.8rem 0;
    animation: marquee 30s linear infinite;
}

.marquee-content span {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.public-footer,
.footer-section {
    background: #0f172a;
    color: rgba(255,255,255,0.88);
    padding: 3rem 0 1.5rem;
}

.public-footer h5,
.public-footer h6,
.footer-section h5,
.footer-section h6 {
    color: #fff;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255,255,255,0.78);
    text-decoration: none;
}

.footer-links a:hover {
    color: #fff;
}

.footer-contact-item {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    margin-bottom: 0.95rem;
    color: rgba(255,255,255,0.78);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.12);
    margin-top: 2rem;
    padding-top: 1rem;
    text-align: center;
}

.footer-divider {
    border-color: rgba(255,255,255,0.12);
    margin: 2rem 0 1rem;
}

.back-to-top {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 0;
    background: var(--secondary);
    color: #111827;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.22);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.25s ease;
    z-index: 1030;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(138, 43, 14, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    z-index: 1100;
}

.lightbox-overlay.active {
    display: flex;
}

.lightbox-overlay img {
    max-width: min(100%, 960px);
    max-height: 90vh;
    border-radius: 18px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

.lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    color: #fff;
    font-size: 2.4rem;
    cursor: pointer;
}

@media (max-width: 991.98px) {
    body {
        padding-top: 72px;
    }

    .hero-stats {
        grid-template-columns: 1fr;
    }

    .leader-card {
        flex-direction: column;
    }
}

@media (max-width: 575.98px) {
    .section-padding {
        padding: 4rem 0;
    }

    .hero-section {
        padding: 4rem 0 3rem;
    }

    .hero-btn {
        width: 100%;
        justify-content: center;
    }

    .gallery-slider-wrapper {
        flex-direction: column;
    }

    .slider-nav {
        display: none;
    }
}
