.bundle-cta {
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.08), rgba(13, 202, 240, 0.08));
    border-radius: 0.75rem;
    border: 1px solid rgba(13, 110, 253, 0.3);
    box-shadow: 0 12px 24px rgba(13, 110, 253, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.bundle-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px rgba(13, 110, 253, 0.12);
}

.bundle-cta .btn-lg {
    min-width: 240px;
}

.bundle-spotlight {
    border-radius: 0.75rem;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.bundle-spotlight .btn-sm {
    min-width: 160px;
}

.bundle-upsell {
    background: linear-gradient(120deg, rgba(13, 110, 253, 0.06), rgba(255, 193, 7, 0.06));
    border-radius: 0.9rem;
    box-shadow: 0 12px 24px rgba(13, 110, 253, 0.08);
}

.bundle-upsell ul {
    padding-left: 1.2rem;
    margin-bottom: 0;
}
/* Custom styles for PassPoint Academy */

/* General styling with performance optimizations */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    /* Optimize rendering performance */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Performance optimizations */
* {
    box-sizing: border-box;
}

/* Optimize animations and transforms */
.card {
    will-change: transform;
    transform: translateZ(0);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Hero section */
.hero-section {
    background: linear-gradient(135deg, var(--bs-primary) 0%, var(--bs-primary-dark) 100%);
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.hero-section .container {
    position: relative;
    z-index: 1;
}

/* Course cards - fixed overlap issues */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.card-img-top {
    transition: transform 0.3s ease;
    width: 100%;
    height: 200px;
    object-fit: cover;
    object-position: center;
    flex-shrink: 0;
}

.card:hover .card-img-top {
    transform: scale(1.05);
}

.card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-text {
    flex: 1;
    overflow: hidden;
}

/* Module progress */
.module-number {
    font-weight: bold;
    font-size: 1.1rem;
}

.progress {
    border-radius: 10px;
    overflow: hidden;
}

.progress-bar {
    background: linear-gradient(90deg, var(--bs-success) 0%, var(--bs-info) 100%);
    transition: width 0.6s ease;
}

/* Quiz styling */
.form-check {
    padding: 0.75rem;
    border-radius: 8px;
    transition: background-color 0.2s ease;
}

.form-check:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.08);
}

.form-check-input:checked + .form-check-label {
    font-weight: 500;
    color: var(--bs-primary);
}

/* Quiz results */
.option-review {
    transition: all 0.2s ease;
}

/* Certificate styling */
.certificate-container .card {
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    position: relative;
}

.certificate-container .card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--bs-warning), var(--bs-info), var(--bs-success), var(--bs-primary));
    border-radius: inherit;
    z-index: -1;
}

/* Navigation improvements */
.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

.nav-link {
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: var(--bs-primary) !important;
}

/* Breadcrumb styling */
.breadcrumb {
    background: transparent;
    padding: 0;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    font-weight: bold;
    color: var(--bs-primary);
}

/* Alert improvements */
.alert {
    border-radius: 10px;
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Button improvements */
.btn {
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Video container */
.ratio iframe {
    border-radius: 8px;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .hero-section .display-4 {
        font-size: 2.5rem;
    }
    
    .certificate-container {
        padding: 10px;
    }
    
    .certificate-container .card-body {
        padding: 2rem 1rem !important;
    }
    
    .certificate-container .display-4 {
        font-size: 2rem;
    }
}

/* Loading states */
.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: currentColor;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Dark theme adjustments */
[data-bs-theme="dark"] .form-check:hover {
    background-color: rgba(255,255,255,0.05);
}

/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

/* Skeleton loaders */
.lazy-img {
    opacity: 0;
    transition: opacity 0.3s ease;
    background: linear-gradient(90deg, rgba(255,255,255,0.08), rgba(255,255,255,0.18), rgba(255,255,255,0.08));
    background-size: 200% 100%;
    animation: shimmer 1.2s infinite;
}

.lazy-img.img-loaded {
    opacity: 1;
    background: none;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Full-card skeleton overlay */
.skeleton-overlay {
    position: absolute;
    inset: 0;
    padding: 12px;
    display: none;
    pointer-events: none;
}

.card.loading-card .skeleton-overlay {
    display: block;
    background: linear-gradient(90deg, rgba(255,255,255,0.05), rgba(255,255,255,0.12), rgba(255,255,255,0.05));
    background-size: 200% 100%;
    animation: shimmer 1.2s infinite;
    z-index: 2;
}

.skeleton-overlay .skeleton-rect-image {
    width: 100%;
    height: 200px;
    border-radius: 8px;
    background: rgba(255,255,255,0.15);
    margin-bottom: 12px;
}

.skeleton-overlay .skeleton-content { padding: 4px 2px; }
.skeleton-overlay .skeleton-line { height: 12px; border-radius: 6px; background: rgba(255,255,255,0.12); margin: 10px 0; }
.skeleton-overlay .skeleton-line-title { height: 18px; width: 70%; }
.skeleton-overlay .skeleton-line-text { width: 90%; }
.skeleton-overlay .skeleton-line-text.short { width: 60%; }
.skeleton-overlay .skeleton-line-cta { width: 40%; height: 36px; border-radius: 8px; }

/* Exam mobile timer bar */
.exam-mobile-timer-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1060;
    padding: 10px 16px;
    background: linear-gradient(90deg, var(--bs-warning), var(--bs-danger));
    color: #000;
    font-weight: 600;
    display: none;
}

@media (max-width: 768px) {
    .exam-mode { padding-top: 52px; }
    .exam-mode .exam-mobile-timer-bar {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
}

/* Exam mode layout */
.exam-mode .navbar,
.exam-mode footer {
    display: none !important;
}

.exam-mode .exam-topbar {
    position: sticky;
    top: 0;
    z-index: 1055;
}

[data-bs-theme="dark"] .certificate-container .card {
    background: linear-gradient(145deg, var(--bs-dark) 0%, var(--bs-gray-900) 100%);
    color: var(--bs-light);
}

/* Accessibility improvements */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus states */
.btn:focus,
.form-control:focus,
.form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.25);
    outline: none;
}

/* Print styles */
@media print {
    .btn, .navbar, footer, .breadcrumb {
        display: none !important;
    }
    
    .certificate-container {
        background: none !important;
        padding: 0 !important;
    }
}

/* Guided Selection Form Styles */
.guided-selection-form .form-select {
    border-width: 2px;
    font-size: 1rem;
    padding: 0.75rem 1rem;
    background-color: rgba(255, 255, 255, 0.95);
    color: #212529;
    transition: all 0.2s ease;
}

.guided-selection-form .form-select:hover {
    border-color: var(--bs-primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.guided-selection-form .form-select:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
    background-color: #fff;
}

.guided-selection-form .form-label {
    color: #fff;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.guided-selection-form .btn-light {
    font-weight: 600;
    padding: 0.75rem 2rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.guided-selection-form .btn-light:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}

/* Hover lift effect for cards */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Package card featured badge */
.card.border-primary {
    border-width: 3px !important;
}

.card-header.bg-primary {
    font-weight: 600;
    padding: 0.75rem 1rem;
}

/* Course modal enhancements */
.modal-lg {
    max-width: 800px;
}

.modal-content {
    border-radius: 12px;
    border: none;
    overflow: hidden;
}

.modal-header {
    border-bottom: 2px solid rgba(var(--bs-primary-rgb), 0.1);
    padding: 1.5rem;
}

.modal-body {
    padding: 2rem;
}

/* Badge enhancements */
.badge {
    padding: 0.5rem 0.75rem;
    font-weight: 500;
    letter-spacing: 0.025em;
}

.badge.fs-6 {
    font-size: 0.95rem !important;
}

/* License requirements card */
.card.border-info {
    border-width: 2px !important;
}

.card.border-info .card-header {
    font-weight: 600;
}

.card.border-info .list-group-item {
    border-left: none;
    border-right: none;
    padding: 0.75rem 0;
}

.card.border-info .list-group-item:first-child {
    border-top: none;
}

.card.border-info .list-group-item:last-child {
    border-bottom: none;
}

/* Quick links cards */
.card a {
    text-decoration: none;
    color: inherit;
}

.card a:hover h5 {
    color: var(--bs-primary);
}

/* Responsive grid adjustments */
@media (max-width: 576px) {
    .guided-selection-form .row > div {
        margin-bottom: 1rem;
    }
    
    .guided-selection-form .row > div:last-child {
        margin-bottom: 0;
    }
    
    .guided-selection-form .btn-light {
        padding: 0.65rem 1.5rem;
        font-size: 0.95rem;
    }
    
    .hero-section .display-4 {
        font-size: 2rem;
    }
    
    .hero-section .lead {
        font-size: 1.1rem;
    }
}

/* Course overview page enhancements */
.course-overview-hero {
    background: linear-gradient(135deg, var(--bs-primary) 0%, rgba(var(--bs-primary-rgb), 0.8) 100%);
}

/* Package pricing display */
.text-decoration-line-through {
    opacity: 0.6;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* Course card image optimization */
.card-img-top {
    content-visibility: auto;
    will-change: transform;
}

/* Form select styling for dark theme */
[data-bs-theme="dark"] .guided-selection-form .form-select {
    background-color: rgba(255, 255, 255, 0.95);
    color: #212529;
}

[data-bs-theme="dark"] .guided-selection-form .form-select option {
    background-color: #fff;
    color: #212529;
}

/* Loading spinner in modal */
.spinner-border {
    width: 3rem;
    height: 3rem;
}

/* Upsell card styling */
.card.bg-light.border-success {
    border-width: 2px !important;
}

.list-group-item.bg-transparent {
    background-color: transparent !important;
}

/* Improve button spacing in modals */
.modal-body .d-grid {
    margin-top: 1rem;
}

/* Performance: GPU acceleration for animations */
.card,
.btn,
.hover-lift,
.lazy-img {
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Accessibility: High contrast mode support */
@media (prefers-contrast: high) {
    .btn,
    .card,
    .form-select {
        border-width: 2px !important;
    }
    
    .hero-section {
        background: var(--bs-primary) !important;
    }
}

/* Empty state styling */
.text-muted {
    opacity: 0.7;
}

.fa-4x {
    font-size: 4rem;
}

/* Breadcrumb responsive */
@media (max-width: 576px) {
    .breadcrumb {
        font-size: 0.85rem;
    }
    
    .breadcrumb-item + .breadcrumb-item {
        padding-left: 0.3rem;
    }
}

/* Course detail badges */
.card-body .badge {
    margin-right: 0.25rem;
    margin-bottom: 0.5rem;
}

/* Optimize font loading */
@font-face {
    font-display: swap;
}

/* Image lazy loading skeleton */
img[loading="lazy"] {
    background: linear-gradient(90deg, rgba(255,255,255,0.08), rgba(255,255,255,0.18), rgba(255,255,255,0.08));
    background-size: 200% 100%;
    animation: shimmer 1.2s infinite;
}

img[loading="lazy"].img-loaded {
    background: none;
    animation: none;
}

/* Trust element styling */
.alert-primary {
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.1), rgba(13, 202, 240, 0.1));
    border-left: 4px solid var(--bs-primary);
}

.alert-info {
    border-left: 4px solid var(--bs-info);
}

.alert-success {
    border-left: 4px solid var(--bs-success);
}

/* Package comparison grid */
.package-feature-list {
    list-style: none;
    padding-left: 0;
}

.package-feature-list li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.package-feature-list li:last-child {
    border-bottom: none;
}

/* ========================================
   DASHBOARD UX IMPROVEMENTS
   ======================================== */

/* Continue Hero Card */
.continue-hero-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.continue-hero-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(13, 110, 253, 0.3) !important;
}

.continue-hero-card .progress {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Hover lift effect for course cards */
.hover-lift {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3) !important;
}

/* Status badges */
.badge {
    font-size: 0.75rem;
    padding: 0.35rem 0.65rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Progress bars */
.progress {
    border-radius: 10px;
    overflow: hidden;
}

.progress-bar {
    transition: width 0.6s ease;
}

/* Search input styling */
#courseSearch {
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

#courseSearch:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Section headers */
h3 {
    position: relative;
    padding-bottom: 0.5rem;
}

/* Collapsible sections */
.collapse {
    transition: height 0.35s ease;
}

/* Recommendation card styling */
.card.border-info {
    border-width: 2px;
}

/* Deadline warning */
.alert-warning {
    border-left: 4px solid #ffc107;
    background-color: rgba(255, 193, 7, 0.1);
}

/* Mobile optimizations */
@media (max-width: 768px) {
    /* Larger touch targets */
    .btn {
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }
    
    /* Stack course cards */
    .col-md-6, .col-lg-4 {
        margin-bottom: 1.5rem;
    }
    
    /* Adjust hero card spacing */
    .continue-hero-card .card-body {
        padding: 1.5rem;
    }
    
    .continue-hero-card h3 {
        font-size: 1.5rem;
    }
    
    /* Full-width buttons on mobile */
    .continue-hero-card .d-flex {
        flex-direction: column;
    }
    
    .continue-hero-card .d-flex .btn {
        width: 100% !important;
        margin-bottom: 0.5rem;
    }
    
    /* Adjust search bar */
    .input-group {
        margin-bottom: 1rem;
    }
}

/* Smooth scrolling for page navigation */
html {
    scroll-behavior: smooth;
}

/* Status-specific styling */
.border-warning {
    border-width: 2px !important;
}

.border-success {
    border-width: 2px !important;
}

/* Loading states */
.course-card {
    transition: opacity 0.3s ease;
}

.course-card.hidden {
    opacity: 0.3;
}

/* Better focus states for accessibility */
button:focus,
a:focus,
input:focus {
    outline: 2px solid #0d6efd;
    outline-offset: 2px;
}

/* Achievement badges (Phase 3 prep) */
.achievement-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: bold;
    margin: 0.25rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Deadline urgency colors */
.days-left-urgent {
    color: #dc3545;
    font-weight: bold;
}

.days-left-warning {
    color: #ffc107;
    font-weight: bold;
}

.days-left-ok {
    color: #198754;
}

/* Better spacing for stats */
small.text-muted {
    line-height: 1.8;
}

/* Card image consistent heights */
.card-img-top {
    object-fit: cover;
    height: 180px;
}

/* Prevent layout shift */
.card {
    min-height: 400px;
}

/* Enhanced button states */
.btn-warning:hover {
    background-color: #ffca2c;
    border-color: #ffc720;
    transform: scale(1.02);
}

.btn-success:hover {
    background-color: #198754;
    border-color: #146c43;
    transform: scale(1.02);
}

/* Sticky header on scroll (optional future enhancement) */
@media (min-width: 992px) {
    .sticky-search {
        position: sticky;
        top: 0;
        z-index: 1020;
        background: #212529;
        padding: 1rem 0;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }
}


/* Button text wrapping for long titles */
.btn.text-wrap {
    white-space: normal;
    word-break: break-word;
    line-height: 1.3;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* Ensure buttons don't break layout */
.d-flex.flex-wrap {
    align-items: flex-start;
}

/* Better button hover with tooltip */
.btn[title]:hover::after {
    /* Tooltip will be handled by browser's native title attribute */
}

/* ===========================================
   TRACK DIRECTORY - MOBILE OPTIMIZATIONS
   =========================================== */

/* Elective course cards - make list-like on mobile */
@media (max-width: 767px) {
    /* Remove padding from column containers */
    .elective-courses-grid .col-md-6 {
        padding-left: 0;
        padding-right: 0;
    }
    
    /* Transform cards into list items */
    .elective-course-card {
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top: none;
        margin-bottom: 0 !important;
        box-shadow: none;
        min-height: auto;
    }
    
    /* Subtle hover effect */
    .elective-course-card:hover {
        transform: none;
        box-shadow: none;
        background-color: rgba(255, 255, 255, 0.05);
    }
    
    /* Flexbox layout for title and button */
    .elective-course-card .card-body {
        padding: 0.75rem 1rem;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    
    /* Course title styling */
    .elective-course-card .card-body span {
        flex: 1;
        font-size: 0.95rem;
        line-height: 1.4;
    }
    
    /* Compact button styling */
    .elective-course-card .card-body .btn,
    .elective-course-card .card-body .badge {
        margin-left: 0.5rem;
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
        min-width: auto;
        flex-shrink: 0;
    }
    
    /* Add top border to first elective card */
    .elective-courses-grid .col-md-6:first-child .elective-course-card {
        border-top: 1px solid var(--bs-border-color);
    }
}

/* Course carousel cards on mobile - also compact */
@media (max-width: 767px) {
    .course-carousel-container .course-card .card {
        min-height: auto;
    }
    
    .course-carousel-container .course-card .card-img-top {
        height: 150px;
    }
    
    .course-carousel-container .course-card .card-body {
        padding: 1rem;
    }
    
    .course-carousel-container .course-card .card-title {
        font-size: 1rem;
        -webkit-line-clamp: 2;
    }
    
    .course-carousel-container .course-card .card-text {
        font-size: 0.875rem;
    }
}

/* Better spacing for accordion items on mobile */
@media (max-width: 767px) {
    .accordion-body {
        padding: 1rem;
    }
    
    .list-group-item {
        font-size: 0.9rem;
        padding: 0.75rem 0.5rem;
    }
    
    .list-group-item .btn-sm {
        padding: 0.25rem 0.5rem;
        font-size: 0.8rem;
    }
}

