:root {
    --primary-color: #1a365d;
    /* Navy Blue - Trust & Authority */
    --secondary-accent: #ff6600;
    /* Vibrant Orange - Call to Action */
    --light-bg: #FFFFFF;
    --text-color: #2d3748;
    /* Deep Slate Gray */
    --card-hover-shadow: 0 12px 30px rgba(26, 54, 93, 0.12);
    /* Navy tinted shadow */
    --accent-soft: #f1f5f9;
    /* Soft blue-gray for backgrounds */
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text-color);
    background-color: var(--light-bg);
    overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Merriweather', serif;
    /* More academic feel */
    color: var(--primary-color);
}

/* Sticky Header with Glassmorphism */
.navbar {
    transition: all 0.3s ease;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.sticky-top-blur {
    position: sticky;
    top: 0;
    z-index: 1030;
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.brand-text {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary-color);
}

.nav-link {
    font-weight: 500;
    color: #555;
    transition: color 0.2s;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    font-weight: 700;
}

/* Quick Actions / Utility Menu */
.quick-actions {
    font-size: 0.85rem;
}

.quick-actions a {
    text-decoration: none;
    color: #666;
    margin-left: 15px;
    transition: color 0.2s;
}

.quick-actions a:hover {
    color: var(--primary-color);
}

/* Hero Section */
.hero-section {
    position: relative;
    padding: 0;
    /* Remove padding as height is defined by carousel */
    margin-top: -85px;
    /* Keep the negative margin for overlap if transparent header, but ensure z-index */
    overflow: hidden;
}

.hero-carousel-item {
    height: 600px;
    background-color: #000;
}

.hero-carousel-item img {
    object-fit: cover;
    height: 100%;
    width: 100%;
    opacity: 0.6;
    /* Darken image for text readability */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
    pointer-events: none;
    /* Allow clicks to pass through if needed, but buttons are inside */
}

/* Ensure buttons in overlay are clickable */
.hero-overlay .container,
.hero-overlay .btn {
    pointer-events: auto;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

/* Section Styling */
.section-padding {
    padding: 80px 0;
}

.section-title {
    position: relative;
    margin-bottom: 50px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 1.75rem;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
    margin: 15px auto 0;
}

/* Sidebar Filters */
.filter-card {
    background: white;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 100px;
    /* Stick below the header */
}

.filter-group-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--text-color);
}

/* Custom Checkbox/Radio Styling */
.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.form-check-input:focus {
    border-color: #d4b98c;
    box-shadow: 0 0 0 0.25rem rgba(176, 141, 85, 0.25);
}

.form-check-label {
    cursor: pointer;
    font-size: 0.95rem;
    color: #555;
    transition: color 0.2s;
}

.form-check-label:hover {
    color: var(--primary-color);
}

.filter-divider {
    border-top: 1px solid #eee;
    margin: 20px 0;
}


/* Card Design */
.course-card {
    border: none;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    background: white;
    overflow: hidden;
    height: 100%;
}

.course-card .card-body {
    display: flex;
    flex-direction: column;
    padding: 1.5rem !important;
}

.course-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--card-hover-shadow);
}

.course-card .card-img-top {
    height: 200px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.course-card:hover .card-img-top {
    transform: scale(1.05);
}

.course-tag {
    background: #e7effc;
    /* Subtle Navy tint background */
    color: var(--primary-color);
    /* Navy text */
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.75rem;
    display: inline-block;
    margin-bottom: 12px;
    font-weight: 700;
}

/* Redesigned Course Details */
.course-info-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 15px;
    margin: 15px 0;
    padding: 15px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.info-item {
    font-size: 0.8rem;
    color: #4a5568;
    /* Slate gray */
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-item.full-width {
    grid-column: span 2;
}

.info-item i {
    width: 14px;
    color: var(--primary-color);
    /* Navy icons */
    text-align: center;
}

.info-label {
    font-weight: 600;
    color: #444;
    margin-right: 4px;
}

.course-pricing {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: auto;
    /* Push to bottom */
    padding-top: 15px;
}

.price-group {
    display: flex;
    flex-direction: column;
}

.original-price {
    font-size: 0.85rem;
    color: #999;
    text-decoration: line-through;
}

.discount-price {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--secondary-accent);
}

.reg-period {
    font-size: 0.75rem;
    background-color: #f1f5f9;
    /* Soft Navy tint background */
    color: var(--primary-color);
    padding: 4px 10px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 10px;
    width: 100%;
    text-align: center;
    font-weight: 600;
    border: 1px solid #e2e8f0;
}

.btn-primary-custom {
    background-color: var(--secondary-accent);
    border-color: var(--secondary-accent);
    color: white;
    padding: 6px 16px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-primary-custom:hover {
    background-color: #967643;
    border-color: #967643;
    color: white;
}

/* Services */
#services {
    background-color: #f8fafc;
    /* Very light workspace gray */
}

.service-box {
    text-align: center;
    padding: 35px 25px;
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
    z-index: 1;
    border-top: 3px solid transparent;
    /* Placeholder for color accent */
}

/* Tonal Color Classes */
.service-box.sb-blue {
    border-top-color: #1a365d;
}

.service-box.sb-teal {
    border-top-color: #2c7a7b;
}

.service-box.sb-slate {
    border-top-color: #4a5568;
}

.service-box.sb-gold {
    border-top-color: #b7791f;
}

.service-box.sb-orange {
    border-top-color: #c05621;
}

.service-box.sb-green {
    border-top-color: #2f855a;
}

.service-box.sb-purple {
    border-top-color: #6b46c1;
}

.service-box.sb-blue .service-icon {
    color: #1a365d;
    background: rgba(26, 54, 93, 0.05);
}

.service-box.sb-teal .service-icon {
    color: #2c7a7b;
    background: rgba(44, 122, 123, 0.05);
}

.service-box.sb-slate .service-icon {
    color: #4a5568;
    background: rgba(74, 85, 104, 0.05);
}

.service-box.sb-gold .service-icon {
    color: #b7791f;
    background: rgba(183, 121, 31, 0.05);
}

.service-box.sb-orange .service-icon {
    color: #c05621;
    background: rgba(192, 86, 33, 0.05);
}

.service-box.sb-green .service-icon {
    color: #2f855a;
    background: rgba(47, 133, 90, 0.05);
}

.service-box.sb-purple .service-icon {
    color: #6b46c1;
    background: rgba(107, 70, 193, 0.05);
}

.service-box::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: var(--secondary-accent);
    transform: scaleX(0);
    transition: transform 0.4s ease;
    transform-origin: center;
}

.service-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 25px -5px rgba(26, 54, 93, 0.1), 0 10px 10px -5px rgba(26, 54, 93, 0.04);
}

.service-box:hover::after {
    transform: scaleX(1);
}

.service-icon {
    font-size: 2.2rem;
    width: 80px;
    height: 80px;
    line-height: 80px;
    border-radius: 50%;
    margin-bottom: 22px;
    transition: all 0.4s ease;
    display: inline-block;
    position: relative;
}

.service-box:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    background: var(--secondary-accent) !important;
    color: white !important;
}

.service-box h5 {
    font-size: 1.15rem;
    margin-bottom: 12px;
    transition: color 0.3s ease;
}

.service-box:hover h5 {
    color: var(--primary-color);
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: white;
    padding: 60px 0 20px;
}

footer h5 {
    color: white;
    font-weight: 700;
    margin-bottom: 20px;
}

footer a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.2s;
}

footer a:hover {
    color: var(--secondary-accent);
    /* Keep orange for contrast on dark footer */
    text-decoration: underline;
}

/* Mobile Adjustments */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: white;
        padding: 20px;
        border-radius: 10px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        margin-top: 10px;
    }

    .quick-actions {
        margin-top: 15px;
        border-top: 1px solid #eee;
        padding-top: 15px;
        text-align: center;
    }

    .quick-actions a {
        display: block;
        margin: 10px 0;
        /* Adequate Touch Target */
        padding: 5px;
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .filter-card {
        position: static;
        margin-bottom: 30px;
    }
}

/* Quick Links Custom Dropdown */
.btn-quick-links {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
    border-radius: 4px;
    padding: 8px 20px;
    transition: all 0.2s;
}

.btn-quick-links:hover,
.btn-quick-links:focus {
    background-color: #2a4365;
    /* Lighter Navy */
    color: white;
    box-shadow: 0 4px 10px rgba(26, 54, 93, 0.2);
}

.search-container {
    display: flex;
    align-items: center;
    background-color: #f0f0f0;
    border-radius: 4px;
    padding: 2px 5px 2px 10px;
    margin-right: 10px;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.search-container:focus-within {
    background-color: white;
    border-color: var(--primary-color);
    box-shadow: 0 0 5px rgba(26, 54, 93, 0.2);
}

.search-input {
    border: none;
    background: transparent;
    outline: none;
    padding: 6px 0;
    font-size: 0.9rem;
    width: 150px;
}

.search-btn {
    border: none;
    background: transparent;
    color: #888;
    padding: 5px;
    cursor: pointer;
    transition: color 0.2s;
}

.search-btn:hover {
    color: var(--primary-color);
}

.custom-dropdown-menu {
    width: 320px;
    border: none;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    border-top: 4px solid var(--primary-color);
    border-radius: 0 0 8px 8px;
    padding: 0;
    overflow: hidden;
}

.quick-link-item {
    padding: 12px 20px;
    color: var(--text-color);
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    transition: background-color 0.2s;
    border-bottom: 1px solid #f0f0f0;
}

.quick-link-item:hover {
    background-color: #f1f5f9;
    /* Soft Navy tint */
    color: var(--primary-color);
}

.quick-link-item i {
    width: 25px;
    color: var(--primary-color);
}

.quick-links-header {
    background-color: var(--primary-color);
    color: white;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
}

.dept-select-container {
    padding: 15px 20px;
    background-color: #fafafa;
}

/* Quick Menu Styles */
.quick-menu-section {
    position: relative;
    z-index: 20;
    margin-top: -50px;
    /* Pull it up onto the hero image */
    margin-bottom: 50px;
}

.quick-menu-wrapper {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
}

.quick-menu-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 25px 15px;
    text-decoration: none;
    color: var(--primary-color);
    transition: all 0.3s ease;
    border-right: 1px solid #f0f0f0;
    height: 100%;
}

.quick-menu-item i {
    font-size: 1.8rem;
    margin-bottom: 10px;
    transition: transform 0.3s ease;
}

.quick-menu-item span {
    font-weight: 700;
    font-size: 0.95rem;
}

.quick-menu-item:hover {
    background-color: var(--primary-color);
    color: #fff;
}

.quick-menu-item:hover i {
    transform: scale(1.2);
}

.row.g-0 .col-4:last-child .quick-menu-item,
.row.g-0 .col-md-2:last-child .quick-menu-item {
    border-right: none;
}

@media (max-width: 767.98px) {
    .quick-menu-section {
        margin-top: -30px;
    }

    .quick-menu-item {
        padding: 15px 10px;
        border-bottom: 1px solid #f0f0f0;
    }

    .quick-menu-item i {
        font-size: 1.4rem;
    }

    .quick-menu-item span {
        font-size: 0.85rem;
    }

    /* Simple grid border management for mobile (3x2) */
    .col-4:nth-child(3n) .quick-menu-item {
        border-right: none;
    }
}

/* Course Category Section (Old - kept for reference if needed elsewhere) */
.category-card {
    background: white;
    border-radius: 12px;
    text-align: center;
    padding: 15px 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.02);
    display: block;
    text-decoration: none;
    height: 100%;
}

/* Base hover lift for ALL category cards */
.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(26, 54, 93, 0.12);
    /* Navy tinted shadow */
    border-color: rgba(26, 54, 93, 0.2);
}

.category-card:active {
    transform: translateY(-5px) scale(0.98);
    transition: all 0.1s ease;
}

.category-icon {
    font-size: 1.8rem;
    color: #888;
    margin-bottom: 10px;
    transition: color 0.3s ease;
}

.category-card:hover .category-icon {
    color: var(--primary-color);
    /* Navy on hover */
}

.category-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
    transition: color 0.3s ease;
}

.category-card:hover .category-title {
    color: var(--primary-color);
    /* Navy on hover */
}

/* Special Categories */
.category-card.special-free .category-icon {
    color: #20c997;
    /* Teal for Free */
}

.category-card.special-free:hover {
    border-color: #20c997;
    box-shadow: 0 15px 30px rgba(32, 201, 151, 0.15);
}

.category-card.special-free:hover .category-title {
    color: #20c997;
}

.category-card.special-discount .category-icon {
    color: #dc3545;
    /* Red for Discount */
}

.category-card.special-discount:hover {
    border-color: #dc3545;
    box-shadow: 0 15px 30px rgba(220, 53, 69, 0.15);
}

.category-card.special-discount:hover .category-title {
    color: #dc3545;
}

/* Testimonials Section */
.testimonials-section {
    background-color: #fdfdfb;
    padding: 80px 0;
}

.testimonials-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
}

.testimonials-subtitle {
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 5px;
    display: block;
}

.testimonials-title {
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
    position: relative;
    padding-bottom: 10px;
}

.testimonials-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 4px;
    background-color: var(--primary-color);
    /* Navy underline */
}

.see-more-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.see-more-link:hover {
    color: var(--secondary-accent);
    /* Orange on hover for interaction */
}

.testimonial-card {
    background: white;
    border-radius: 4px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    height: 100%;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.testimonial-profile {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.testimonial-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 15px;
    background-color: #eee;
}

.testimonial-name {
    font-weight: 700;
    margin: 0;
    font-size: 1.1rem;
}

.testimonial-quote {
    font-style: italic;
    color: #666;
    line-height: 1.6;
    margin: 0;
}

.testimonial-carousel-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

.carousel-control-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}

.carousel-control-btn:hover {
    background-color: var(--secondary-accent);
    color: white;
    border-color: var(--secondary-accent);
}

/* Member Center Styles */


/* Floating Action Menu */
.floating-action-group {
    position: fixed;
    right: 25px;
    bottom: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 2000;
}

.floating-btn {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    color: white !important;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: none;
    position: relative;
}

.floating-btn:hover {
    transform: translateY(-5px) scale(1.08);
}

.btn-line {
    background: #06C755;
    background: linear-gradient(135deg, #06C755 0%, #05B34B 100%);
}

.btn-history {
    background-color: var(--primary-color);
}

.btn-top {
    background-color: #6c757d;
    width: 40px;
    height: 40px;
    font-size: 1rem;
    margin: 0 auto;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.btn-top.show {
    opacity: 1;
    visibility: visible;
}

.floating-btn .tooltip-text {
    position: absolute;
    right: 65px;
    background: rgba(0, 0, 0, 0.75);
    color: white;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s;
    pointer-events: none;
}

.floating-btn:hover .tooltip-text {
    opacity: 1;
    visibility: visible;
    right: 60px;
}

/* Recently Viewed Panel */
.history-panel {
    position: fixed;
    right: 90px;
    bottom: 80px;
    width: 300px;
    max-height: 450px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    z-index: 2001;
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #f0f0f0;
}

.history-panel.show {
    display: flex;
    animation: fadeInSlide 0.3s ease-out;
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.history-header {
    background: var(--primary-color);
    color: white;
    padding: 12px 15px;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.history-header h6 {
    margin: 0;
    color: white;
    font-size: 0.95rem;
}

.history-list {
    overflow-y: auto;
    padding: 10px;
}

.history-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    border-bottom: 1px solid #f5f5f5;
    text-decoration: none;
    color: var(--text-color);
    transition: background 0.2s;
    align-items: center;
}

.history-item:hover {
    background: #f9f9f9;
}

.history-item img {
    width: 60px;
    height: 40px;
    border-radius: 4px;
    object-fit: cover;
}

.history-item-info span {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary-color);
}

.history-item-info small {
    color: var(--secondary-accent);
    font-size: 0.75rem;
    font-weight: 600;
}

@media (max-width: 575.98px) {
    .history-panel {
        right: 15px;
        left: 15px;
        width: auto;
        bottom: 95px;
    }
}