/*
 * BAS Virtual Academy — Mobile-First Stylesheet
 * Single source of truth for all responsive behavior.
 * Loaded last so it wins over all other CSS files.
 * Breakpoints:
 *   xs  : 0–575px   (small phones)
 *   sm  : 576–767px (large phones)
 *   md  : 768–991px (tablets)
 *   lg  : 992px+    (desktop)
 */

/* ============================================================
   1. BASE — applies at every screen size
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img, video, iframe, svg, canvas {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Prevent iOS zoom on input focus */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="search"],
input[type="url"],
input[type="date"],
input[type="time"],
select,
textarea,
.form-control,
.form-select {
    font-size: 16px !important;
}

/* Minimum touch target size */
.btn,
a.btn,
button,
[role="button"] {
    min-height: 44px;
    min-width: 44px;
}

.btn-sm {
    min-height: 36px;
}

/* Tables always scrollable */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* ============================================================
   2. PUBLIC NAVBAR — mobile-first
   ============================================================ */
.navbar-public {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 1px 4px rgba(0,0,0,.06);
    /* Do NOT set overflow:hidden — it would clip the dropdown */
}

.navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .75rem 1rem;
    max-width: 1400px;
    margin: 0 auto;
    gap: .5rem;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary, #2563eb);
    text-decoration: none;
    flex-shrink: 0;
    max-width: calc(100% - 56px);
}

.navbar-brand span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.navbar-brand img.brand-logo {
    height: 36px;
    width: auto;
    flex-shrink: 0;
}

/* Desktop Action Buttons (hidden on mobile via CSS) */
.navbar-actions {
    display: none;
}

/* Hamburger — mobile only, always last in flex row */
.navbar-toggler {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: .5rem;
    color: #374151;
    font-size: 1.25rem;
    cursor: pointer;
    flex-shrink: 0;
    transition: background .15s;
}

.navbar-toggler:hover {
    background: #f3f4f6;
}

/* Mobile dropdown menu — full width block element below navbar-container */
.navbar-mobile-menu {
    display: block;
    width: 100%;
    background: #fff;
    border-top: 1px solid #e5e7eb;
    max-height: 0;
    overflow: hidden;
    transition: max-height .35s ease;
    /* Ensure it's not clipped by any parent overflow */
    position: relative;
    z-index: 1029;
}

.navbar-mobile-menu.show {
    max-height: 600px;
}

.navbar-mobile-menu ul {
    list-style: none;
    margin: 0;
    padding: .5rem 0;
}

.navbar-mobile-menu a {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .875rem 1.25rem;
    color: #374151;
    font-size: .9375rem;
    font-weight: 500;
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: all .15s;
}

.navbar-mobile-menu a:hover,
.navbar-mobile-menu a.active {
    background: #f9fafb;
    color: var(--primary, #2563eb);
    border-left-color: var(--primary, #2563eb);
}

/* Auth buttons inside mobile menu */
.navbar-mobile-menu .mobile-auth {
    display: flex;
    flex-direction: column;
    gap: .5rem;
    padding: .75rem 1.25rem 1rem;
    border-top: 1px solid #e5e7eb;
}

.navbar-mobile-menu .mobile-auth .btn {
    width: 100%;
    justify-content: center;
}

/* ============================================================
   3. AUTHENTICATED LAYOUT — sidebar + topbar
   ============================================================ */

/* --- Topbar --- */
.topbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 1020 !important;
    height: 60px !important;
    background: #fff !important;
    border-bottom: 1px solid #e5e7eb !important;
    box-shadow: 0 1px 4px rgba(0,0,0,.06) !important;
    display: flex !important;
    align-items: center !important;
    padding: 0 1rem !important;
}

/* Hamburger inside topbar */
#sidebarToggleTop {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    border-radius: .5rem;
    color: #374151;
    font-size: 1.25rem;
    cursor: pointer;
    flex-shrink: 0;
    transition: background .15s;
}

#sidebarToggleTop:hover {
    background: #f3f4f6;
}

/* --- Sidebar --- */
.sidebar,
ul.navbar-nav.sidebar,
.navbar-nav.bg-gradient-primary.sidebar.sidebar-dark.accordion {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    height: 100vh !important;
    width: 280px !important;
    z-index: 1050 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    transform: translateX(-100%) !important;
    transition: transform .3s cubic-bezier(.4,0,.2,1) !important;
    /* Smooth scrolling inside sidebar */
    -webkit-overflow-scrolling: touch;
}

/* Sidebar visible state */
.sidebar.toggled,
ul.navbar-nav.sidebar.toggled,
.navbar-nav.bg-gradient-primary.sidebar.sidebar-dark.accordion.toggled {
    transform: translateX(0) !important;
}

/* Content wrapper — always full width on mobile */
#content-wrapper,
div#content-wrapper {
    margin-left: 0 !important;
    width: 100% !important;
}

/* Prevent body scroll when sidebar is open */
body.sidebar-overlay-active {
    overflow: hidden !important;
}

/* Backdrop */
.sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 1040;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    animation: bas-fade-in .2s ease;
}

/* Sidebar nav items — always show text on mobile */
.sidebar .nav-link {
    display: flex !important;
    align-items: center !important;
    gap: .75rem !important;
    padding: .875rem 1rem !important;
    white-space: nowrap !important;
}

.sidebar .nav-link span,
.sidebar .sidebar-brand-text,
.sidebar .sidebar-heading,
.sidebar .collapse-item {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

.sidebar .nav-link i {
    width: 20px !important;
    flex-shrink: 0 !important;
    text-align: center;
}

.sidebar-brand {
    flex-direction: row !important;
    gap: .5rem !important;
    padding: 1rem !important;
    height: auto !important;
    min-height: 64px;
}

/* --- Content padding on mobile --- */
#content,
div#content {
    padding: .875rem !important;
}

.container-fluid {
    padding-left: .875rem !important;
    padding-right: .875rem !important;
}

/* ============================================================
   4. CARDS
   ============================================================ */
.card {
    border-radius: .75rem !important;
    margin-bottom: 1rem;
    border: 1px solid #e5e7eb;
    box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.card-body {
    padding: 1.25rem !important;
}

.card-header {
    padding: .875rem 1.25rem !important;
    font-size: .9375rem;
}

.card-footer {
    padding: .875rem 1.25rem !important;
}

/* ============================================================
   5. FORMS — clean, aligned, professional
   ============================================================ */

/* Form wrapper — consistent max-width on auth pages */
.container > .row.justify-content-center > [class*="col-"] > .card {
    border-radius: 1rem !important;
    box-shadow: 0 4px 24px rgba(0,0,0,.08) !important;
    border: none !important;
}

/* All form groups consistent spacing */
.mb-3,
.form-group {
    margin-bottom: 1.125rem !important;
}

/* Labels — always block, consistent weight */
.form-label {
    display: block;
    font-size: .875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: .375rem !important;
    line-height: 1.4;
}

/* All inputs — consistent height, padding, border */
.form-control,
.form-select {
    display: block;
    width: 100%;
    height: 46px;
    padding: .625rem .875rem !important;
    font-size: 16px !important; /* prevents iOS zoom */
    font-weight: 400;
    line-height: 1.5;
    color: #111827;
    background-color: #fff;
    border: 1.5px solid #d1d5db !important;
    border-radius: .5rem !important;
    transition: border-color .15s, box-shadow .15s;
    -webkit-appearance: none;
    appearance: none;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary, #2563eb) !important;
    box-shadow: 0 0 0 3px rgba(37,99,235,.12) !important;
    outline: none;
}

.form-control::placeholder {
    color: #9ca3af;
    font-size: .9375rem;
}

/* Textarea — auto height, no fixed height */
textarea.form-control {
    height: auto !important;
    min-height: 100px;
    resize: vertical;
    padding: .75rem .875rem !important;
}

/* Disabled inputs */
.form-control:disabled,
.form-control[readonly] {
    background-color: #f9fafb !important;
    color: #6b7280 !important;
    cursor: not-allowed;
}

/* Form text / helper text */
.form-text {
    display: block;
    margin-top: .3rem;
    font-size: .8125rem;
    color: #6b7280;
    line-height: 1.4;
}

/* Input group — icon + input side by side, perfectly aligned */
.input-group {
    display: flex;
    align-items: stretch;
    width: 100%;
    border-radius: .5rem;
    overflow: hidden;
}

.input-group .form-control {
    border-radius: 0 !important;
    border-right: none !important;
    flex: 1;
    min-width: 0;
}

.input-group .form-control:focus {
    z-index: 3;
    border-color: var(--primary, #2563eb) !important;
    box-shadow: none !important;
}

.input-group-text {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 .875rem;
    min-width: 44px;
    background-color: #f3f4f6;
    border: 1.5px solid #d1d5db;
    border-right: none;
    color: #6b7280;
    font-size: .9375rem;
    white-space: nowrap;
    border-radius: 0 !important;
}

/* First child rounded left */
.input-group > :first-child,
.input-group > .input-group-text:first-child {
    border-radius: .5rem 0 0 .5rem !important;
}

/* Last child rounded right */
.input-group > :last-child,
.input-group > .form-control:last-child,
.input-group > .btn:last-child {
    border-radius: 0 .5rem .5rem 0 !important;
    border-right: 1.5px solid #d1d5db !important;
}

/* Input group button (e.g. show/hide password) */
.input-group .btn {
    min-height: 46px;
    padding: 0 .875rem;
    border: 1.5px solid #d1d5db;
    border-left: none !important;
    background: #f3f4f6;
    color: #6b7280;
    border-radius: 0 .5rem .5rem 0 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s, color .15s;
}

.input-group .btn:hover {
    background: #e5e7eb;
    color: #374151;
}

/* When input-group has focus, show border on all children */
.input-group:focus-within .input-group-text,
.input-group:focus-within .btn {
    border-color: var(--primary, #2563eb);
}

/* Form check (checkbox/radio) */
.form-check {
    display: flex;
    align-items: flex-start;
    gap: .5rem;
    padding-left: 0;
    margin-bottom: .5rem;
}

.form-check-input {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px;
    margin-top: .125rem;
    border: 1.5px solid #d1d5db;
    border-radius: .25rem;
    cursor: pointer;
    flex-shrink: 0;
}

.form-check-input:checked {
    background-color: var(--primary, #2563eb);
    border-color: var(--primary, #2563eb);
}

.form-check-label {
    font-size: .9rem;
    color: #374151;
    cursor: pointer;
    line-height: 1.5;
}

/* d-flex justify-content-between for remember me + forgot password */
.d-flex.justify-content-between.align-items-center {
    flex-wrap: wrap;
    gap: .5rem;
}

/* ---- Remember me row (login page) ---- */
.remember-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
}

.remember-check {
    display: flex;
    align-items: center;
    gap: .5rem;
    cursor: pointer;
    margin: 0;
    font-size: .9rem;
    color: #374151;
    font-weight: 500;
    user-select: none;
}

.remember-check input[type="checkbox"] {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px;
    border: 1.5px solid #d1d5db;
    border-radius: .25rem;
    cursor: pointer;
    accent-color: var(--primary, #2563eb);
    flex-shrink: 0;
    margin: 0 !important;
}

.remember-check span {
    line-height: 1;
    white-space: nowrap;
}

.forgot-link {
    font-size: .875rem;
    font-weight: 500;
    color: var(--primary, #2563eb);
    text-decoration: none;
    white-space: nowrap;
    transition: color .15s;
}

.forgot-link:hover {
    color: var(--primary-hover, #1d4ed8);
    text-decoration: underline;
}

/* d-grid submit button — full width */
.d-grid .btn {
    width: 100%;
    justify-content: center;
}

/* Row columns — proper gutters on mobile */
.row {
    --bs-gutter-x: 1rem;
    --bs-gutter-y: 0;
    margin-left: calc(var(--bs-gutter-x) * -.5);
    margin-right: calc(var(--bs-gutter-x) * -.5);
}

.row > * {
    padding-left: calc(var(--bs-gutter-x) * .5);
    padding-right: calc(var(--bs-gutter-x) * .5);
}

/* On mobile, col-md-6 stacks to full width */
@media (max-width: 767.98px) {
    .col-md-6,
    .col-md-4,
    .col-md-8,
    .col-md-3 {
        width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100% !important;
    }
}

/* Auth card centering — proper vertical spacing */
.container > .row.justify-content-center {
    padding: 1.5rem 0;
}

/* Card title on auth pages */
.card-body .text-center.mb-4 h1,
.card-body .text-center.mb-4 .h3 {
    font-size: 1.5rem !important;
    font-weight: 700;
    color: #111827;
    margin-bottom: .375rem !important;
}

.card-body .text-center.mb-4 p {
    font-size: .9375rem;
    color: #6b7280;
    margin-bottom: 0;
}

/* Sign in / sign up link at bottom */
.card-body .text-center.mt-4 p {
    font-size: .9375rem;
    color: #6b7280;
    margin-bottom: 0;
}

/* Password strength meter */
.progress {
    height: 6px;
    border-radius: 3px;
    background: #e5e7eb;
    overflow: hidden;
}

/* Password requirements list */
.form-text span {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    font-size: .8rem;
}

/* Select dropdown arrow */
.form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right .75rem center;
    background-size: 16px 12px;
    padding-right: 2.5rem !important;
}

/* Alert styling */
.alert {
    display: flex;
    align-items: flex-start;
    gap: .625rem;
    padding: .875rem 1rem;
    border-radius: .625rem;
    font-size: .9rem;
    border: none;
    margin-bottom: 1rem;
}

.alert i {
    flex-shrink: 0;
    margin-top: .125rem;
}

.alert .btn-close {
    margin-left: auto;
    flex-shrink: 0;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
}

.alert-warning {
    background: #fef3c7;
    color: #92400e;
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
}

/* Profile page detail list */
.profile-details-list li {
    flex-wrap: nowrap !important;
    gap: .5rem;
}

.detail-value {
    font-size: .8125rem !important;
    word-break: break-word;
    text-align: right;
    max-width: 55%;
}

/* Contact page icon circles */
.icon-circle {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
}

.icon-circle-primary { background: #dbeafe; color: #2563eb; }
.icon-circle-success { background: #d1fae5; color: #059669; }
.icon-circle-warning { background: #fef3c7; color: #d97706; }
.icon-circle-info    { background: #cffafe; color: #0891b2; }
.icon-circle-danger  { background: #fee2e2; color: #dc2626; }

/* text-end on mobile becomes text-start */
@media (max-width: 575.98px) {
    .text-end {
        text-align: left !important;
    }

    .text-end .btn {
        width: 100%;
        justify-content: center;
    }
}

/* ============================================================
   6. BUTTONS
   ============================================================ */
.btn {
    border-radius: .5rem;
    font-weight: 500;
    padding: .625rem 1.125rem;
    font-size: .9375rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    transition: all .15s;
}

.btn-sm {
    padding: .4rem .75rem;
    font-size: .8125rem;
    min-height: 34px;
}

.btn-lg {
    padding: .75rem 1.5rem;
    font-size: 1rem;
    min-height: 50px;
}

/* ============================================================
   7. TABLES
   ============================================================ */
.table th,
.table td {
    padding: .75rem .875rem;
    font-size: .875rem;
    vertical-align: middle;
}

.table thead th {
    font-size: .8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .4px;
    white-space: nowrap;
}

/* ============================================================
   8. MODALS
   ============================================================ */
.modal-dialog {
    margin: .5rem !important;
    max-width: calc(100% - 1rem) !important;
}

.modal-body {
    padding: 1rem !important;
}

.modal-footer {
    padding: .75rem 1rem !important;
    flex-wrap: wrap;
    gap: .5rem;
}

.modal-footer .btn {
    flex: 1;
    min-width: 120px;
}

/* ============================================================
   9. TYPOGRAPHY
   ============================================================ */
h1, .h1 { font-size: 1.75rem !important; }
h2, .h2 { font-size: 1.5rem !important; }
h3, .h3 { font-size: 1.25rem !important; }
h4, .h4 { font-size: 1.125rem !important; }

.display-4 { font-size: 2rem !important; }
.display-5 { font-size: 1.75rem !important; }
.lead { font-size: 1rem !important; }

/* ============================================================
   10. HERO SECTION (public pages)
   ============================================================ */
.hero-section {
    padding: 3rem 1rem !important;
    min-height: auto !important;
    text-align: center;
}

.hero-title,
.hero-section h1 {
    font-size: 1.75rem !important;
    line-height: 1.25 !important;
    margin-bottom: 1rem !important;
}

.hero-subtitle,
.hero-section p {
    font-size: 1rem !important;
    margin-bottom: 1.5rem !important;
}

.hero-cta {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: .75rem !important;
}

.hero-cta .btn {
    width: 100% !important;
    justify-content: center !important;
}

/* ============================================================
   11. FEATURES / GRID SECTIONS (public pages)
   ============================================================ */
.features-section,
.testimonials-section,
.stats-section,
.cta-section,
.pricing-section,
.contact-section,
.about-section,
.team-section {
    padding: 2.5rem 1rem !important;
}

.features-grid,
.testimonials-grid,
.pricing-grid,
.team-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
}

.stats-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 1rem !important;
}

.section-title,
.section-header h2 {
    font-size: 1.5rem !important;
}

.section-subtitle,
.section-header p {
    font-size: .9375rem !important;
}

.feature-card,
.testimonial-card {
    padding: 1.5rem !important;
}

.contact-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
}

/* ============================================================
   12. DASHBOARD STATS CARDS
   ============================================================ */
.dashboard-grid,
.stats-grid.dashboard {
    grid-template-columns: 1fr 1fr !important;
    gap: .75rem !important;
}

.stat-card,
.dashboard-card {
    padding: 1rem !important;
}

.stat-number,
.card-stats-value {
    font-size: 1.75rem !important;
}

.stat-icon,
.card-icon-circle {
    width: 48px !important;
    height: 48px !important;
    font-size: 1.25rem !important;
}

/* ============================================================
   13. PROFILE PAGE
   ============================================================ */
.profile-image-container {
    width: 110px !important;
    height: 110px !important;
}

.profile-stats {
    flex-direction: row !important;
    flex-wrap: wrap !important;
    gap: .5rem !important;
}

.profile-stat {
    flex: 1;
    min-width: 80px;
}

.profile-header {
    padding: 1.5rem 1rem !important;
}

/* ============================================================
   14. FOOTER
   ============================================================ */
.site-footer {
    padding: 2rem 1rem !important;
    text-align: center;
}

.site-footer .col-md-4,
.site-footer .col-md-3,
.site-footer .col-md-2 {
    margin-bottom: 1.5rem;
}

.site-footer a:hover {
    padding-left: 0 !important;
}

/* ============================================================
   15. UTILITIES
   ============================================================ */
.scroll-to-top {
    right: .875rem !important;
    bottom: .875rem !important;
    width: 42px !important;
    height: 42px !important;
}

.pagination {
    flex-wrap: wrap;
    gap: .25rem;
}

.page-link {
    padding: .5rem .75rem;
    font-size: .875rem;
}

.alert {
    padding: .875rem 1rem;
    font-size: .9rem;
    border-radius: .625rem;
}

/* ============================================================
   16. TABLET (576px – 991px) — 2-column grids, wider padding
   ============================================================ */
@media (min-width: 576px) {
    .navbar-container {
        padding: .875rem 1.25rem;
    }

    .hero-title,
    .hero-section h1 {
        font-size: 2.25rem !important;
    }

    .hero-cta {
        flex-direction: row !important;
        justify-content: center !important;
    }

    .hero-cta .btn {
        width: auto !important;
    }

    .features-grid,
    .team-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .testimonials-grid {
        grid-template-columns: 1fr !important;
    }

    .dashboard-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .modal-dialog {
        margin: 1.5rem auto !important;
        max-width: 500px !important;
    }

    .modal-footer .btn {
        flex: 0 0 auto;
        width: auto;
    }
}

@media (min-width: 768px) {
    #content,
    div#content {
        padding: 1.25rem !important;
    }

    .container-fluid {
        padding-left: 1.25rem !important;
        padding-right: 1.25rem !important;
    }

    .hero-section {
        padding: 4rem 1.5rem !important;
        text-align: left;
    }

    .hero-cta {
        justify-content: flex-start !important;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .stats-grid {
        grid-template-columns: repeat(4, 1fr) !important;
    }

    .contact-grid {
        grid-template-columns: 1fr 1fr !important;
    }

    h1, .h1 { font-size: 2rem !important; }
    h2, .h2 { font-size: 1.75rem !important; }
    h3, .h3 { font-size: 1.5rem !important; }
}

/* ============================================================
   17. DESKTOP (992px+) — sidebar always visible, full layout
   ============================================================ */
@media (min-width: 992px) {

    /* Show desktop nav, hide mobile elements */
    .navbar-toggler {
        display: none !important;
    }

    .navbar-menu {
        display: flex !important;
        gap: 2rem;
        list-style: none;
        margin: 0;
        padding: 0;
        align-items: center;
        flex: 1;
        justify-content: center;
    }

    .navbar-menu a {
        color: #4b5563;
        font-size: .9375rem;
        font-weight: 500;
        text-decoration: none;
        padding: .375rem .5rem;
        position: relative;
        transition: color .15s;
    }

    .navbar-menu a:hover,
    .navbar-menu a.active {
        color: var(--primary, #2563eb);
    }

    .navbar-menu a::after {
        content: '';
        position: absolute;
        bottom: -2px;
        left: 50%;
        transform: translateX(-50%);
        width: 0;
        height: 2px;
        background: var(--primary, #2563eb);
        transition: width .15s;
    }

    .navbar-menu a:hover::after,
    .navbar-menu a.active::after {
        width: 80%;
    }

    .navbar-actions {
        display: flex !important;
        gap: .75rem;
        align-items: center;
        flex-shrink: 0;
    }

    .navbar-mobile-menu {
        display: none !important;
    }

    /* Sidebar — always visible on desktop */
    .sidebar,
    ul.navbar-nav.sidebar,
    .navbar-nav.bg-gradient-primary.sidebar.sidebar-dark.accordion {
        transform: translateX(0) !important;
        position: fixed !important;
        width: 260px !important;
    }

    /* Collapsed sidebar */
    body.sidebar-toggled .sidebar,
    body.sidebar-toggled ul.navbar-nav.sidebar {
        width: 80px !important;
        transform: translateX(0) !important;
    }

    body.sidebar-toggled .sidebar .sidebar-brand-text,
    body.sidebar-toggled .sidebar .nav-link span,
    body.sidebar-toggled .sidebar .sidebar-heading,
    body.sidebar-toggled .sidebar .collapse-inner {
        display: none !important;
    }

    body.sidebar-toggled .sidebar .nav-link {
        justify-content: center !important;
        padding: .875rem !important;
    }

    body.sidebar-toggled .sidebar .nav-link i {
        margin: 0 !important;
        width: auto !important;
    }

    /* Content wrapper offset */
    #content-wrapper,
    div#content-wrapper {
        margin-left: 260px !important;
        width: calc(100% - 260px) !important;
    }

    body.sidebar-toggled #content-wrapper,
    body.sidebar-toggled div#content-wrapper {
        margin-left: 80px !important;
        width: calc(100% - 80px) !important;
    }

    /* Hide mobile hamburger */
    #sidebarToggleTop {
        display: none !important;
    }

    /* Show desktop collapse button */
    #sidebarToggle {
        display: flex !important;
    }

    /* Content padding */
    #content,
    div#content {
        padding: 1.5rem !important;
    }

    .container-fluid {
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }

    /* Hero */
    .hero-section {
        padding: 5rem 0 !important;
        min-height: 520px !important;
    }

    .hero-title,
    .hero-section h1 {
        font-size: 2.75rem !important;
    }

    /* Features */
    .features-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .pricing-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .team-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    /* Dashboard */
    .dashboard-grid {
        grid-template-columns: repeat(4, 1fr) !important;
    }

    /* Typography */
    h1, .h1 { font-size: 2.25rem !important; }
    h2, .h2 { font-size: 2rem !important; }
    h3, .h3 { font-size: 1.75rem !important; }

    /* Modals */
    .modal-dialog {
        margin: 1.75rem auto !important;
        max-width: 500px !important;
    }

    .modal-footer .btn {
        flex: 0 0 auto;
        width: auto;
    }
}

@media (min-width: 1200px) {
    .hero-title,
    .hero-section h1 {
        font-size: 3.25rem !important;
    }

    .features-grid {
        grid-template-columns: repeat(4, 1fr) !important;
    }

    .testimonials-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

/* ============================================================
   18. PRINT
   ============================================================ */
@media print {
    .sidebar,
    .topbar,
    .navbar-public,
    .site-footer,
    .scroll-to-top,
    .sidebar-backdrop,
    .btn:not(.btn-print),
    #sidebarToggleTop,
    #sidebarToggle {
        display: none !important;
    }

    #content-wrapper,
    div#content-wrapper {
        margin-left: 0 !important;
        width: 100% !important;
    }

    body {
        background: #fff !important;
        color: #000 !important;
    }

    .card {
        box-shadow: none !important;
        border: 1px solid #ccc !important;
        break-inside: avoid;
    }
}
