/* =========================================
   COURSES PAGE STYLES (Clean Layout)
========================================= */

/* --- 1. HERO SECTION (Mandala Theme) --- */
.courses-hero {
    position: relative;
    padding: 120px 0 100px 0;
    background-color: var(--astro-primary); 
    color: white;
    overflow: hidden;
    border-bottom: 5px solid var(--astro-accent);
}

.mandala-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1500px;
    height: 1500px;
    background-image: url('images/mandala.png'); 
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transform: translate(-50%, -50%);
    opacity: 0.1; 
    animation: spin-mandala 60s linear infinite;
    z-index: 1;
}

.mandala-bg:empty {
    background: radial-gradient(circle, var(--astro-accent) 2px, transparent 2.5px);
    background-size: 30px 30px;
}

@keyframes spin-mandala {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.hero-badge-gold {
    display: inline-block; background: var(--astro-accent); color: var(--astro-primary);
    padding: 6px 20px; border-radius: 4px; font-weight: 800; font-size: 0.85rem;
    text-transform: uppercase; margin-bottom: 20px; letter-spacing: 2px;
    position: relative; z-index: 2;
}

.courses-title {
    font-size: 3.5rem; font-weight: 900; color: #fff;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.4); margin-bottom: 15px;
    position: relative; z-index: 2;
}

.courses-sub {
    font-size: 1.2rem; color: #ddd; max-width: 700px; margin: 0 auto; line-height: 1.6;
    position: relative; z-index: 2;
}

/* --- 2. CURRICULUM SECTION (Background & Headings) --- */
.courses-section {
    /* --- 1. KEPT: Your Important Layout Properties --- */
    padding: 80px 0;
    position: relative;
    overflow: hidden;

    /* --- 2. NEW: Background Image moved here (Matches Consult logic) --- */
    /* Note: I kept your '../' path */
    background: url('../images/marriage-bg.jpg') center/cover fixed; 
}

.courses-section::before {
    /* --- 3. NEW: This is now the White Overlay --- */
    content: "";
    position: absolute;
    inset: 0; /* Covers the whole section */
    background: rgba(255, 255, 255, 0.78); /* The exact white tint */
    z-index: 1;
}

/* --- 4. CRITICAL: Lifts the text above the white overlay --- */
.courses-section > * {
    position: relative;
    z-index: 2;
}

.section-heading {
    color: var(--astro-primary); font-weight: 900; font-size: 2.5rem; text-transform: uppercase;
}

.gold-divider {
    width: 100px; height: 4px; background: var(--astro-accent); border-radius: 2px; margin-top: 10px;
}

/* --- 3. TUITION SPECIFIC STYLES --- */
.tuition-header { margin-bottom: 5px !important; }

.tuition-main-title {
    color: var(--astro-primary); font-weight: 900; font-size: 2.4rem;
    text-transform: uppercase; margin-bottom: 5px;
}

.tuition-subheading {
    font-size: 1.15rem; color: #000000; font-weight: 700; font-style: italic; margin-bottom: 15px;
}

.tuition-card {
    background: #ffffff; border-radius: 12px; padding: 25px; box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-left: 10px solid var(--astro-primary); transition: all 0.3s ease; text-align: left;
}

.tuition-card:hover {
    transform: translateX(10px); box-shadow: 0 12px 35px rgba(128, 0, 0, 0.15); border-left-color: var(--astro-accent);
}

.tuition-title { color: var(--astro-primary); font-weight: 900; font-size: 1.9rem; margin-bottom: 8px; }

.tuition-content-heading {
    color: var(--astro-primary); font-size: 1.1rem; font-weight: 800; margin-bottom: 10px;
    text-transform: uppercase; display: inline-block; border-bottom: 2px solid var(--astro-accent); 
}

.tuition-subjects { color: #000000; font-size: 1.2rem; line-height: 1.7; margin-bottom: 15px; font-weight: 700; }

.hindi-subtext { display: block; margin-top: 8px; color: #000000; font-weight: 600; font-size: 1.15rem; }

.interest-msg { font-size: 1.1rem; color: var(--astro-primary); font-style: italic; font-weight: 800; margin-bottom: 18px; }

.tuition-phone {
    display: inline-flex; align-items: center; background-color: var(--astro-primary); color: white !important; 
    padding: 12px 30px; border-radius: 50px; font-weight: 800; text-decoration: none; transition: 0.3s;
    box-shadow: 0 4px 15px rgba(128, 0, 0, 0.3); letter-spacing: 0.1rem;
}

.tuition-phone:hover { background-color: var(--astro-accent); color: var(--astro-primary) !important; transform: scale(1.05); }

.paper-solution-box {
    background-color: #ecf02c; color: var(--astro-primary); padding: 25px; border-radius: 12px; 
    text-align: center; border: 3px dashed var(--astro-primary); box-shadow: 0 6px 15px rgba(92, 0, 0, 0.15); margin-top: 30px;
    font-size: 1.2rem;
}

/* --- 4. CERTIFICATE SECTION --- */
.certificate-section { padding: 100px 0; background: var(--astro-primary); color: white; overflow: hidden; }

.sub-text-gold { color: var(--astro-accent); font-weight: 800; letter-spacing: 2px; }
.cert-title { font-size: 3rem; font-weight: 900; margin-bottom: 20px; }
.cert-desc { font-size: 1.1rem; line-height: 1.8; color: #e0e0e0; margin-bottom: 30px; }

.cert-features { list-style: none; padding: 0; }
.cert-features li { font-size: 1.1rem; margin-bottom: 15px; display: flex; align-items: center; }
.cert-features li::before {
    content: '\f058'; font-family: 'Font Awesome 5 Free'; font-weight: 900;
    color: var(--astro-accent); margin-right: 15px; font-size: 1.3rem;
}

.certificate-frame {
    position: relative; padding: 15px; background: #fff; border: 1px solid #ccc; 
    box-shadow: 0 0 40px rgba(0,0,0,0.5); transition: 0.5s; display: inline-block;
}
.certificate-frame:hover { transform: scale(1.02); }
.cert-img { border: 1px solid #eee; display: block; }

.shine-effect {
    position: absolute; top: 0; left: -100%; width: 50%; height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 100%);
    animation: shine 3s infinite;
}

@keyframes shine { 100% { left: 200%; } }

/* --- 5. COURSE STEP & ARROW STYLES --- */
.course-step-wrapper {
    display: flex; align-items: flex-start; gap: 20px; position: relative;
    margin-left: -90px; margin-bottom: 25px;
}

.course-arrow-badge {
    flex-shrink: 0; width: 60px; height: 60px; background: var(--astro-accent);
    border: 4px solid #fff; border-radius: 50%; display: flex; align-items: center;
    justify-content: center; font-size: 1.8rem; font-weight: 900; color: var(--astro-primary);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1); position: relative; z-index: 5; margin-top: 10px; 
}

.course-arrow-badge::after {
    content: ''; position: absolute; right: -22px; top: 50%;
    transform: translateY(-50%); border-left: 18px solid var(--astro-accent);
    border-top: 18px solid transparent; border-bottom: 18px solid transparent; z-index: -1;
}

.course-step-wrapper .tuition-card { flex-grow: 1; margin-bottom: 0 !important; }

/* --- 6. VERTICAL DIVIDER (DESKTOP) --- */
@media (min-width: 992px) {
    .curriculum-divider {
        position: relative; border-right: 4px solid var(--astro-primary);
        padding-right: 50px; box-shadow: 5px 0 15px rgba(128, 0, 0, 0.05);
    }
    .curriculum-divider::after {
        content: ''; position: absolute; right: -8px; top: 50%;
        transform: translateY(-50%); width: 12px; height: 40px;
        background: var(--astro-accent); border-radius: 10px;
    }
    .curriculum-divider + .col-lg-6 { padding-left: 50px; }
}

/* =========================================
   FIXED MOBILE TAB SYSTEM (With Fade-In)
========================================= */

/* Fade-In Animation */
@keyframes tabFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 991px) {
    .course-step-wrapper { margin-left: 0; flex-direction: column; align-items: center; text-align: center; }
    .course-arrow-badge::after { display: none; }

    /* Standardized Spacing for Tabs on Mobile */
    .mobile-content-section {
        display: none;
        margin-top: 0 !important;
        animation: tabFadeIn 0.4s ease-out forwards;
    }
    
    #tab-tuition { display: block; }

    /* Standardizing headings for every section */
    .mobile-content-section .tuition-header {
        margin-top: 5px !important; 
        margin-bottom: 20px !important;
    }
}

/* 2. Responsive Tab Container (Fits all screens > 320px) */
.mobile-tabs-container {
    display: flex;
    justify-content: space-between; 
    align-items: center;
    gap: 5px; 
    padding: 6px;
    background: rgba(128, 0, 0, 0.05);
    border-radius: 50px;
    width: 95%; 
    max-width: 420px;
    margin: 0 auto 25px auto;
}

/* 3. Individual Buttons (Equal Width / Responsive Text) */
.tab-btn {
    flex: 1;
    border: none;
    background: transparent;
    padding: 8px 5px; 
    font-weight: 800;
    font-size: 0.75rem; 
    color: var(--astro-primary);
    border-radius: 40px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.tab-btn.active {
    background: var(--astro-primary);
    color: var(--astro-accent);
    box-shadow: 0 4px 12px rgba(128, 0, 0, 0.2);
}

/* Responsive adjustments for mid-size mobile devices */
@media (min-width: 400px) {
    .tab-btn { font-size: 0.85rem; padding: 10px 15px; }
    .mobile-tabs-container { gap: 8px; }
}

@media (max-width: 768px) {
    .courses-title { font-size: 2.5rem; }
    .cert-title { font-size: 2.2rem; }
    .mandala-bg { width: 800px; height: 800px; }
}