:root {
    --bs-primary: #09F69B;
    --bs-primary-rgb: 9, 246, 155;
    --bs-link-color: #09F69B;
    --bs-link-hover-color: #07c47a;
}

.btn-primary {
    --bs-btn-bg: #09F69B;
    --bs-btn-border-color: #09F69B;
    --bs-btn-hover-bg: #07c47a;
    --bs-btn-hover-border-color: #07c47a;
    --bs-btn-active-bg: #06b06a;
    --bs-btn-active-border-color: #06b06a;
    --bs-btn-disabled-bg: #09F69B;
    --bs-btn-disabled-border-color: #09F69B;
    color: #000 !important; /* Better contrast for bright green */
}

.btn-outline-primary {
    --bs-btn-color: #09F69B;
    --bs-btn-border-color: #09F69B;
    --bs-btn-hover-bg: #09F69B;
    --bs-btn-hover-border-color: #09F69B;
    --bs-btn-active-bg: #09F69B;
    --bs-btn-active-border-color: #09F69B;
}

.btn-outline-primary:hover, .btn-outline-primary:active {
    color: #000 !important;
}

body { 
    padding-top: 80px !important; 
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-family: 'Roboto', sans-serif; /* Default */
}

/* Language Specific Fonts */
[lang="en"] body { font-family: 'Roboto', sans-serif; }
[lang="km"] body { font-family: 'Battambang', cursive; }
[lang="zh"] body { font-family: 'Microsoft JhengHei', 'Noto Sans SC', sans-serif; }

/* Table Header Theme Adjustments */
[data-bs-theme="dark"] .table thead, 
[data-bs-theme="dark"] .table .table-light {
    --bs-table-bg: #1a1d20;
    --bs-table-color: #fff;
    border-color: #373b3e;
}

[data-bs-theme="dark"] .table thead th {
    color: #fff !important;
}

/* Responsive Tab Scroller */
.tab-scroller {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none;  /* IE 10+ */
    margin-bottom: -1px; /* Overlap border */
}

.tab-scroller::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.tab-scroller .nav-tabs {
    border-bottom: none;
}

.nav-tabs .nav-link.active {
    border-bottom: 3px solid var(--bs-primary) !important;
    color: var(--bs-primary) !important;
}

.footer {
    width: 100%;
}

.navbar-logo, .theme-logo {
    transition: filter 0.3s ease;
}

[data-bs-theme="dark"] .navbar-logo, 
[data-bs-theme="dark"] .theme-logo {
    filter: brightness(0) invert(1);
}

/* Ensure the navbar matches the theme */
.navbar.theme-aware {
    background-color: var(--bs-body-bg) !important;
    border-bottom: 1px solid var(--bs-border-color);
}

/* Adjust logo size if needed */
.navbar-brand {
    max-height: 45px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.navbar-brand img {
    object-fit: cover;
    height: 85px;
    width: auto;
}