/* ============================================
   Jnana Vikas School - Custom Styles
   Color Scheme: Maroon (#8B0000) & Gold (#FFD700)
   ============================================ */

/* CSS Variables */
:root {
    --color-maroon: #8B0000;
    --color-maroon-dark: #6B0000;
    --color-maroon-light: #A52A2A;
    --color-gold: #FFD700;
    --color-gold-dark: #DAA520;
    --color-gold-light: #FFF8DC;
    --color-white: #FFFFFF;
    --color-black: #000000;
    --color-gray: #6c757d;
    --color-gray-light: #f8f9fa;
    --font-primary: 'Poppins', sans-serif;
    --font-secondary: 'Playfair Display', serif;
    --transition: all 0.3s ease;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.15);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 600;
}

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

/* ============================================
   Preloader
   ============================================ */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-white);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.loader-content {
    text-align: center;
}

.loader-logo {
    width: 120px;
    height: auto;
    margin-bottom: 20px;
    animation: pulse 1.5s ease-in-out infinite;
}

/*
.loader-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--color-gold-light);
    border-top-color: var(--color-maroon);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}*/

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* ============================================
   Color Classes
   ============================================ */
.bg-maroon {
    background-color: var(--color-maroon) !important;
}

.text-maroon {
    color: var(--color-maroon) !important;
}

.bg-gold {
    background-color: var(--color-gold) !important;
}

.text-gold {
    color: var(--color-gold) !important;
}

.btn-maroon {
    background-color: var(--color-maroon);
    color: var(--color-white);
    border: 2px solid var(--color-maroon);
    padding: 10px 30px;
    font-weight: 500;
    border-radius: 5px;
    transition: var(--transition);
}

.btn-maroon:hover {
    background-color: var(--color-maroon-dark);
    border-color: var(--color-maroon-dark);
    color: var(--color-white);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-gold {
    background-color: var(--color-gold);
    color: var(--color-maroon);
    border: 2px solid var(--color-gold);
    padding: 10px 30px;
    font-weight: 600;
    border-radius: 5px;
    transition: var(--transition);
}

.btn-gold:hover {
    background-color: var(--color-gold-dark);
    border-color: var(--color-gold-dark);
    color: var(--color-maroon);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-outline-light:hover {
    background-color: var(--color-white);
    color: var(--color-maroon);
}

/* ============================================
   Top Bar
   ============================================ */
.top-bar {
    font-size: 0.875rem;
}

.top-bar i {
    color: var(--color-gold);
}

/* ============================================
   Navigation
   ============================================ */
.navbar {
    padding: 15px 0;
    transition: var(--transition);
}

.nav-logo {
    width: 60px;
    height: auto;
    border-radius: 50%;
}

.navbar-brand h5 {
    font-size: 1.25rem;
}

.navbar-brand small {
    font-size: 0.75rem;
    font-style: italic;
}

.nav-link {
    color: #333 !important;
    font-weight: 500;
    padding: 10px 15px !important;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 15px;
    width: 0;
    height: 2px;
    background-color: var(--color-maroon);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: calc(100% - 30px);
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-maroon) !important;
}

.navbar.scrolled {
    box-shadow: var(--shadow);
    padding: 10px 0;
}

/* ============================================
   Hero Section
   ============================================ */
.hero-section {
    position: relative;
    min-height: 100vh;
    background: url('../images/hero-school.jpg') center/cover no-repeat fixed;
    display: flex;
    align-items: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(139, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.7) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
}

.hero-badge .badge {
    font-weight: 600;
    letter-spacing: 1px;
}

.hero-content h1 {
    font-size: 3.5rem;
    line-height: 1.2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-content .lead {
    font-size: 1.5rem;
    font-weight: 300;
}

.hero-buttons {
    margin-top: 30px;
}

.hero-scroll {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.scroll-down {
    display: inline-block;
    width: 50px;
    height: 50px;
    background: var(--color-gold);
    border-radius: 50%;
    text-align: center;
    line-height: 50px;
    color: var(--color-maroon);
    animation: bounce 2s infinite;
}

.scroll-down:hover {
    background: var(--color-white);
    color: var(--color-maroon);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

/* ============================================
   Stats Section
   ============================================ */
.stats-section {
    padding: 60px 0;
}

.stat-item {
    padding: 20px;
}

.stat-item h3 {
    font-size: 3rem;
    margin-bottom: 10px;
}

.counter {
    font-size: 3rem;
    font-weight: 700;
}

/* ============================================
   Section Styles
   ============================================ */
section {
    padding: 80px 0;
}

.section-header {
    margin-bottom: 50px;
}

.subtitle {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 10px;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.section-desc {
    max-width: 600px;
    color: var(--color-gray);
}

/* ============================================
   About Section
   ============================================ */
.about-image-wrapper {
    position: relative;
}

.main-image {
    border-radius: 20px;
}

.experience-badge {
    position: absolute;
    bottom: -20px;
    right: -20px;
    background: var(--color-gold);
    color: var(--color-maroon);
    padding: 25px 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: var(--shadow-lg);
}

.experience-badge .years {
    display: block;
    font-size: 3rem;
    font-weight: 700;
    line-height: 1;
}

.experience-badge .text {
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.3;
}

.feature-item {
    font-weight: 500;
}

.feature-item i {
    font-size: 1.25rem;
}

/* ============================================
   Principal Section
   ============================================ */
.principal-image img {
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
}

.principal-message {
    padding: 20px;
}

.quote-icon {
    opacity: 0.5;
}

/* ============================================
   Academic Cards
   ============================================ */
.academic-card {
    background: var(--color-white);
    padding: 35px 25px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: center;
    border-bottom: 4px solid transparent;
}

.academic-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-bottom-color: var(--color-maroon);
}

.card-icon {
    width: 80px;
    height: 80px;
    background: var(--color-gold-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.academic-card h4 {
    margin-bottom: 15px;
}

.academic-card ul {
    text-align: left;
    margin-top: 20px;
}

.academic-card ul li {
    margin-bottom: 8px;
    font-size: 0.9rem;
}

/* ============================================
   Facility Cards
   ============================================ */
.facility-card {
    background: var(--color-white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.facility-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.facility-image {
    position: relative;
    overflow: hidden;
}

.facility-image img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: var(--transition);
}

.facility-card:hover .facility-image img {
    transform: scale(1.1);
}

.facility-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(139, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.facility-card:hover .facility-overlay {
    opacity: 1;
}

.facility-content {
    padding: 25px;
}

.facility-content h4 {
    margin-bottom: 10px;
}

/* ============================================
   Gallery Section
   ============================================ */
.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: var(--transition);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(139, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

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

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

/* ============================================
   Testimonials
   ============================================ */
.testimonial-item {
    padding: 40px;
}

.testimonial-content {
    max-width: 800px;
    margin: 0 auto;
}

.carousel-control-prev,
.carousel-control-next {
    width: 50px;
    height: 50px;
    background: var(--color-gold);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 1;
}

.carousel-control-prev {
    left: 20px;
}

.carousel-control-next {
    right: 20px;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    filter: invert(1);
}

/* ============================================
   Admission CTA
   ============================================ */
.admission-cta {
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-dark) 100%);
}

.admission-features .badge {
    font-size: 0.875rem;
    padding: 8px 15px;
}

/* ============================================
   Contact Section
   ============================================ */
.contact-info {
    background: var(--color-white);
    padding: 40px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    height: 100%;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: var(--color-gold-light);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contact-form-wrapper {
    border-radius: 15px;
}

.form-control,
.form-select {
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--color-maroon);
    box-shadow: 0 0 0 0.2rem rgba(139, 0, 0, 0.25);
}

.form-label {
    font-weight: 500;
    color: var(--color-maroon);
    margin-bottom: 8px;
}

/* ============================================
   Map Section
   ============================================ */
.map-section iframe {
    display: block;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    background: #1a1a1a !important;
}

.footer-logo {
    width: 60px;
    height: auto;
    border-radius: 50%;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #aaa;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--color-gold);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 10px;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    transition: var(--transition);
}

.social-link:hover {
    background: var(--color-gold);
    color: var(--color-maroon);
    transform: translateY(-3px);
}

.newsletter-form .form-control {
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-white);
}

.newsletter-form .form-control::placeholder {
    color: #aaa;
}

.newsletter-form .btn-gold {
    padding: 10px 20px;
}

/* ============================================
   Back to Top Button
   ============================================ */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--color-maroon);
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
    box-shadow: var(--shadow);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--color-gold);
    color: var(--color-maroon);
    transform: translateY(-5px);
}

/* ============================================
   Page Headers (Multi-page)
   ============================================ */
.page-header {
    position: relative;
    min-height: 400px;
    background: url('../images/hero-school.jpg') center/cover no-repeat;
    display: flex;
    align-items: center;
}

.page-header-about {
    background: url('../images/about-classroom.jpg') center/cover no-repeat;
}

.page-header-academics {
    background: url('../images/facilities-computer.jpg') center/cover no-repeat;
}

.page-header-facilities {
    background: url('../images/facilities-library.jpg') center/cover no-repeat;
}

.page-header-gallery {
    background: url('../images/events-annual.jpg') center/cover no-repeat;
}

.page-header-testimonials {
    background: url('../images/gallery-students.jpg') center/cover no-repeat;
}

.page-header-contact {
    background: url('../images/facilities-sports.jpg') center/cover no-repeat;
}

.page-header-admission {
    background: url('../images/hero-school.jpg') center/cover no-repeat;
}

.page-header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(139, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.7) 100%);
}

.page-header .container {
    position: relative;
    z-index: 2;
}

.page-header .breadcrumb {
    background: transparent;
    padding: 0;
}

.page-header .breadcrumb-item + .breadcrumb-item::before {
    color: var(--color-white);
}

.page-header .breadcrumb-item a:hover {
    color: var(--color-gold) !important;
}

/* ============================================
   Mission & Vision Cards
   ============================================ */
.mission-card,
.vision-card {
    transition: var(--transition);
}

.mission-card:hover,
.vision-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.icon-box {
    width: 80px;
    height: 80px;
    background: var(--color-gold-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   Value Cards
   ============================================ */
.value-card {
    transition: var(--transition);
}

.value-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.1) !important;
}

/* ============================================
   Program Content
   ============================================ */
.program-content {
    padding: 20px;
}

.program-icon {
    width: 80px;
    height: 80px;
    background: var(--color-gold-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   Activity Cards
   ============================================ */
.activity-card {
    transition: var(--transition);
}

.activity-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* ============================================
   Additional Facilities
   ============================================ */
.additional-facility {
    transition: var(--transition);
}

.additional-facility:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* ============================================
   Gallery Filter Buttons
   ============================================ */
.gallery-filter .btn {
    margin: 5px;
    border-radius: 25px;
    padding: 8px 25px;
}

.btn-outline-maroon {
    color: var(--color-maroon);
    border: 2px solid var(--color-maroon);
    background: transparent;
}

.btn-outline-maroon:hover,
.btn-outline-maroon.active {
    background: var(--color-maroon);
    color: var(--color-white);
}

/* ============================================
   Testimonial Cards (Full)
   ============================================ */
.testimonial-card-full {
    transition: var(--transition);
}

.testimonial-card-full:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.testimonial-avatar {
    flex-shrink: 0;
}

.rating {
    font-size: 0.875rem;
}

/* ============================================
   Contact Page Styles
   ============================================ */
.contact-info-wrapper {
    background: var(--color-white);
    padding: 40px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    height: 100%;
}

.contact-icon-large {
    flex-shrink: 0;
}

/* ============================================
   Admission Page Styles
   ============================================ */
.process-card {
    transition: var(--transition);
}

.process-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.process-number {
    box-shadow: 0 4px 15px rgba(139, 0, 0, 0.3);
}

.documents-section,
.eligibility-section {
    transition: var(--transition);
}

.documents-section:hover,
.eligibility-section:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.admission-form-wrapper {
    transition: var(--transition);
}

.admission-form-wrapper:hover {
    box-shadow: var(--shadow-lg);
}

/* ============================================
   Testimonial Card (Homepage)
   ============================================ */
.testimonial-card {
    transition: var(--transition);
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* ============================================
   Responsive Styles
   ============================================ */
@media (max-width: 991px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .experience-badge {
        right: 10px;
        bottom: -10px;
        padding: 15px 20px;
    }
    
    .experience-badge .years {
        font-size: 2rem;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        display: none;
    }
}

@media (max-width: 767px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero-content .lead {
        font-size: 1.1rem;
    }
    
    .stat-item h3,
    .counter {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .testimonial-item {
        padding: 20px;
    }
    
    .admission-cta {
        padding: 30px 20px !important;
    }
}

@media (max-width: 575px) {
    .top-bar {
        text-align: center;
    }
    
    .top-bar .col-md-6:last-child {
        margin-top: 5px;
    }
    
    .hero-buttons .btn {
        display: block;
        width: 100%;
        margin-bottom: 10px;
    }
    
    .hero-buttons .btn:first-child {
        margin-right: 0 !important;
    }
}

/* ============================================
   Animation Classes
   ============================================ */
[data-aos] {
    transition-timing-function: ease-out;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: var(--color-maroon-dark);
}

/* Selection Color */
::selection {
    background: var(--color-gold);
    color: var(--color-maroon);
}
