:root {
    --theme_primary_blue: #98dfef;  /* Your existing blue */
    --theme_primary_dark: #1a365d;  /* Deep navy for contrast */
    --theme_primary_medium: #2d5a9a; /* Medium blue */
    --theme_primary_light: #e6f2ff; /* Light blue background */
    
    --theme_accent_teal: #039564;   /* Keep your green as accent */
    --theme_accent_light_teal: #05c78a; /* Brighter teal */
    --theme_accent_gold: #ffd166;   /* Warm gold instead of yellow */
    --theme_accent_coral: #ff6b6b;  /* For highlights */
    
    --theme_neutral_white: #ffffff;
    --theme_neutral_light: #f8fafc;
    --theme_neutral_medium: #e2e8f0;
    --theme_neutral_dark: #4a5568;

    --tabbar_custom_height: 50px;
    --toolbar_custom_height: 45px;
    /* --phone_notification_bar_custom_height: 45px; */
    --phone_notification_bar_custom_height: 0px;
    --custom_min_height: 100%;
    --theme_shadow_color: rgba(0, 0, 0, 0.25);
    --theme_transparent_color: rgba(0, 0, 0, 0.075);
    --theme_cus_1_color: #000000;
    --theme_cus_2_color: #505050;
    --theme_cus_3_color: var(--theme_primary_blue);
    --theme_cus_4_color: var(--theme_accent_teal);
    --theme_cus_5_color: var(--theme_primary_dark);
    --theme_cus_6_color: var(--theme_primary_light);
    --theme_cus_7_color: var(--theme_neutral_white);
    --theme_cus_8_color: var(--theme_accent_gold);
    --theme_cus_9_color: rgba(3, 149, 100, 0.15);
    
    /* New variables for login page */
    --login_gradient_start: var(--theme_primary_blue);
    --login_gradient_end: var(--theme_primary_medium);
    --login_shadow: rgba(152, 223, 239, 0.3);
    --login_border_radius: 20px;
    --login_form_bg: rgba(255, 255, 255, 0.95);
}

.mobile-app-container .page__content {
    padding-top: var(--phone_notification_bar_custom_height);
}

.toolbar {
    margin-top: var(--phone_notification_bar_custom_height);
    height: var(--toolbar_custom_height);
}

.toolbar.blue {
    background-color: var(--theme_primary_blue);
}

#menu {
    .page__background {
        background-color: #efeff4 !important;
    }
    .page__content {
    }
}

.toolbar+.page__background, .toolbar+.page__background+.page__content {
    margin-top: var(--phone_notification_bar_custom_height);
    top: var(--toolbar_custom_height) !important;
}

.sidebar-btn {
    position: absolute;
    /* top: calc(150px + var(--phone_notification_bar_custom_height)); */
    right: 0;
}

/* Enhanced Sidebar Styles */
ons-splitter-side {
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.3) !important;
    border-left: 1px solid var(--theme_neutral_medium) !important;
}

ons-splitter-side .page__background {
    background: linear-gradient(135deg, var(--theme_primary_light), var(--theme_neutral_white)) !important;
}

ons-splitter-side .page__content {
    background: transparent !important;
}

/* Sidebar Header */
.sidebar-header {
    background: linear-gradient(135deg, var(--theme_primary_medium), var(--theme_primary_dark));
    color: white;
    padding: 1.5rem 1rem !important;
    margin-bottom: 1rem;
    border-radius: 0 0 20px 20px;
    box-shadow: 0 4px 12px rgba(26, 54, 93, 0.2);
    margin-top: calc(var(--phone_notification_bar_custom_height) * -1);
    padding-top: calc(var(--phone_notification_bar_custom_height) + 2rem) !important;
}

/* Profile Image */
.profile-image-container {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    padding: 4px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.profile-image {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
}

/* User Name */
.user-name {
    color: white;
    font-weight: 600;
    font-size: 1.25rem;
    margin-bottom: 0.5rem !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Edit Profile Button */
.edit-profile-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-radius: 25px;
    padding: 8px 20px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.edit-profile-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.edit-profile-btn:active {
    transform: translateY(0);
}

/* Sidebar Menu */
.sidebar-menu {
    background: transparent !important;
    margin: 0 !important;
    padding: 0 1rem !important;
}

.sidebar-menu-item {
    background: white !important;
    border: none !important;
    border-radius: 12px !important;
    margin: 8px 0 !important;
    box-shadow: 0 2px 8px rgba(26, 54, 93, 0.1);
    transition: all 0.3s ease !important;
    min-height: 56px !important;
}

.sidebar-menu-item:hover {
    transform: translateX(-5px);
    box-shadow: 0 4px 12px rgba(26, 54, 93, 0.15);
}

.sidebar-menu-item:active {
    background: var(--theme_primary_light) !important;
}

/* Menu Icons */
.menu-icon {
    color: var(--theme_primary_medium) !important;
    font-size: 1.125rem;
    width: 24px;
    text-align: center;
}

/* List item content */
.sidebar-menu-item .center {
    color: var(--theme_primary_dark);
    font-weight: 500;
    font-size: 0.95rem;
}

.sidebar-menu-item .right {
    opacity: 0.6;
}

/* Sidebar Footer */
.sidebar-footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.9);
    border-top: 1px solid var(--theme_neutral_medium);
    padding: 1rem !important;
}

/* Sign Out Button */
.signout-btn {
    background: linear-gradient(135deg, var(--theme_accent_coral), #ff5252);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 12px 24px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

.signout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 107, 0.4);
}

.signout-btn:active {
    transform: translateY(0);
}

.btn-color-e {
    background: linear-gradient(135deg, var(--theme_primary_blue), #3883b2);
}
.btn-color-e:hover {
    box-shadow: 0 6px 16px rgba(108, 168, 206, 0.4);
}

/* List item customization */
.sidebar-menu ons-list-item {
    padding: 0 !important;
}

.sidebar-menu .list-item {
    min-height: 56px !important;
    border-bottom: none !important;
}

.sidebar-menu .list-item__center {
    padding-left: 0 !important;
    --list-item-separator-color: none;
}

.sidebar-menu .list-item__right {
    --list-item-separator-color: none;
}

.sidebar-menu .list-item__left {
    padding: 12px !important;
}

/* Animation for sidebar opening */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

ons-splitter-side[side="right"] {
    animation: slideInRight 0.3s ease-out;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    ons-splitter-side {
        width: 280px !important;
    }
    
    .sidebar-header {
        padding: 1.5rem 1rem !important;
        margin-top: calc(var(--phone_notification_bar_custom_height) * -1);
        padding-top: calc(var(--phone_notification_bar_custom_height) + 2rem) !important;
    }
    
    .profile-image-container {
        width: 80px;
        height: 80px;
    }
    
    .user-name {
        font-size: 1.1rem;
    }
    
    .sidebar-menu-item {
        min-height: 52px !important;
        margin: 6px 0 !important;
    }
    
    .sidebar-menu {
        padding: 0 0.75rem !important;
    }
}

/* Active state for menu items */
.sidebar-menu-item.active {
    background: var(--theme_primary_light) !important;
    border-left: 4px solid var(--theme_primary_medium) !important;
}

/* Ensure proper spacing */
.sidebar-menu-item + .sidebar-menu-item {
    margin-top: 4px !important;
}
/* Language Options Styling */
.language-option {
    background: var(--theme_neutral_light) !important;
    border-left: 4px solid var(--theme_primary_blue) !important;
    margin: 2px 0 !important;
    min-height: 48px !important;
}

.language-option:hover {
    background: var(--theme_primary_light) !important;
    transform: translateX(-3px) !important;
}

.language-option .center {
    color: var(--theme_primary_dark);
    font-weight: 400;
    font-size: 0.9rem;
}

/* Language collapse animation */
#language-options {
    transition: all 0.3s ease;
    overflow: hidden;
}

#language-options.show {
    display: block !important;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 300px;
    }
}

/* Rotate chevron when expanded */
#language-menu-header.active .fa-chevron-down {
    transform: rotate(180deg);
    transition: transform 0.3s ease;
}

/* Current language highlight */
.language-option .fa-check {
    font-size: 0.875rem;
}

h1, h2, h3, h4, h5, h6, p {
    margin: 0px !important;
}

body, .page, .page__background {
    background-color: var(--theme_cus_3_color) !important;
}

.position-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-55%)!important;
    width: 100%;
}

.position-bottom-right {
    position: absolute;
    bottom: 1%;
    right: 3%;
}

.fs-10px{
    font-size: 10px;
}
.fs-12px{
    font-size: 12px;
}
.fs-13px{
    font-size: 13px;
}
.fs-14px{
    font-size: 14px;
}
.fs-15px{
    font-size: 15px;
}
.fs-16px{
    font-size: 16px;
}
.fs-18px{
    font-size: 18px;
}
.fs-20px{
    font-size: 20px;
}
.fs-22px{
    font-size: 22px;
}
.fs-24px{
    font-size: 24px;
}
.fs-40px{
    font-size: 40px;
}

.transparent {
    color: var(--theme_shadow_color);
}

.green {
    color: var(--theme_cus_4_color);
}

.double-border {
    position: relative;
}

.double-border::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    border-top: 1px solid var(--theme_transparent_color);
    border-bottom: 1px solid var(--theme_cus_9_color);
}

.custom-height {
    min-height: calc(var(--custom_min_height) - 150px);
    &.mh {
        min-height: var(--custom_min_height);
    }
}

.dotted-border {
    /* border: 1px 0px 0px 1px var(--theme_black_color); */
    border-top: var(--theme_black_color);
    border-bottom: var(--theme_black_color);
    border-style: dotted;
}

.display-center {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.btn-otp {
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--theme_cus_4_color);
    color: white;
    border: none;
    border-radius: 4px;
    padding: 4px 12px;
    font-size: 12px;
    z-index: 10;
}

.password {
    position: relative;
    i {
        position: absolute;
        right: 14px;
        top: 50%;
        transform: translateY(-50%);
    }
}

.user-box {
    position: relative;
    width: 100%;
    margin-top: 10px;
}

.user-box input {
    background-color: var(--theme_cus_7_color) !important;
    color: var(--theme_cus_1_color);
    width: 100%;
    padding: 16px 24px;
    border-radius: 30px;
    font-size: 16px;
    border: none;
    outline: none;
    box-shadow: 3px 3px var(--theme_shadow_color);
}
.user-box label {
    position: absolute;
    top: 50%;
    left: 24px;
    transform: translate(0, -50%)!important;
    padding: 10px 0;
    font-size: 16px;
    color: var(--theme_cus_1_color);
    pointer-events: none;
    transition: .5s;
}
.user-box select, .user-box .selectpickr .btn {
    width: 100%;
    padding: 16px 24px;
    border-radius: 30px;
    background-color: white;
    border: none;
    outline: none;
    box-shadow: 3px 3px var(--theme_shadow_color);
}
.user-box .select-label {
    position: absolute;
    top: 14px;
    left: 24px;
    font-size: 12px;
    color: var(--theme_cus_2_color);
}

.user-box input:focus ~ label,
.user-box input:valid ~ label {
    top: -6px;
    transform: translate(0, 0)!important;
    color: var(--theme_cus_2_color);
    font-size: 12px;
}

.user-box .eye {
    position: absolute;
    top: 50%;
    right: 24px;
    transform: translate(0, -50%)!important;
    font-size: 20px;
}

.user-box .submit {
    background-color: var(--theme_cus_8_color) !important;
    color: var(--theme_cus_1_color);
    width: 100%;
    padding: 16px 24px;
    border-radius: 30px;
    border: none;
    outline: none;
    text-align: center;
    font-weight: bolder;
    box-shadow: 3px 3px var(--theme_shadow_color);
}

.tabbar__content{
    bottom: var(--tabbar_custom_height);
}
ons-toolbar:not([inline]){
    position: unset;
}
.tabbar{
    height: var(--tabbar_custom_height);    
    box-shadow: var(--theme_black_color) 0 10px 7px 7px;
    
    span{
        font-size: 10px;
    }
    .tabbar__item.active .tabbar__button{
        color: rgb(var(--theme_text_color));
    }
    .tabbar__button{
        height: var(--tabbar_custom_height);
    }
}

.sales_tab.btn-group {
    border-radius: 20px;
    box-shadow: 3px 3px var(--theme_shadow_color);
}

.sales_tab.btn-group .btn {
    background-color: var(--theme_cus_7_color);
    font-weight: 600;
    padding: 0.375rem 1rem;
}

.sales_tab.btn-group .btn.active {
    border: 2px solid var(--theme_cus_4_color);
    background-color: var(--theme_cus_4_color);
    color: white;
}

.sales_tab.btn-group .btn:first-child {
    border-top-left-radius: 20px;
    border-bottom-left-radius: 20px;
}

.sales_tab.btn-group .btn:last-child {
    border-top-right-radius: 20px;
    border-bottom-right-radius: 20px;
}

.sales_tab.btn-group .btn:not(.active):hover {
    background-color: #e9ecef;
}

/* Enhanced Badge Styles for Sales Tabs */
.sales_tab .btn {
    position: relative;
    transition: all 0.3s ease;
}

.sales_tab .btn .badge {
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.25em 0.5em;
    min-width: 1.6em;
    height: 1.6em;
    border-radius: 0.8em;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    top: -1px;
}

/* Pending/Ongoing Badge */
.sales_tab .btn .pending-count {
    background: linear-gradient(135deg, var(--theme_accent_gold), #ffb347) !important;
    color: var(--theme_primary_dark) !important;
}

/* Completed Badge */
.sales_tab .btn .completed-count {
    background: linear-gradient(135deg, var(--theme_accent_teal), var(--theme_accent_light_teal)) !important;
    color: white !important;
}

/* Active state badges */
.sales_tab .btn.active .badge {
    transform: scale(1.1);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}

/* Hover effects */
.sales_tab .btn:not(.active):hover .badge {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.25);
}

/* Pulse animation for new data */
@keyframes pulse-gentle {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.badge-updated {
    animation: pulse-gentle 0.6s ease-in-out;
}

/* Empty badge state */
.sales_tab .badge:empty {
    display: none;
}

/* Responsive badge sizes */
@media (max-width: 576px) {
    .sales_tab .btn .badge {
        font-size: 0.6rem;
        padding: 0.2em 0.4em;
        min-width: 1.4em;
        height: 1.4em;
    }
    
    .sales_tab .btn {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
}

/* Ensure proper spacing with badges */
.sales_tab .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
}

#summ_comp_tab {
  border-radius: 20px;
  box-shadow: 3px 3px var(--theme_shadow_color);
  background-color: var(--theme_cus_7_color);
}

#summ_comp_tab .form-select {
  background-color: transparent;
  border: none;
  outline: none;
  box-shadow: none;
  font-weight: 600;
  padding: 0.75rem 1rem;
  cursor: pointer;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px 12px;
  text-align: center; /* Center the text */
  text-align-last: center; /* Center the selected option text */
}

/* Center the dropdown options as well */
#summ_comp_tab .form-select option {
  text-align: center;
}

/* Responsive adjustments */
@media (max-width: 576px) {
  #summ_comp_tab .form-select {
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
  }
}

.round-green-box {
    color: var(--theme_cus_5_color);
    background-color: var(--theme_cus_9_color) !important;
    border-radius: 5px;
}

.round-yellow-box {
    color: var(--theme_cus_1_color);
    background-color: var(--theme_cus_8_color) !important;
    border-radius: 15px;
    box-shadow: 3px 3px var(--theme_shadow_color);
}

.round-white-box {
    color: var(--theme_cus_1_color);
    background-color: var(--theme_cus_7_color) !important;
    border-radius: 15px;
    box-shadow: 3px 3px var(--theme_shadow_color);
}

.white-box {
    color: var(--theme_cus_1_color);
    background-color: var(--theme_cus_7_color) !important;
}

.calendar-wrapper {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-left: 50%;
    scroll-padding-right: 50%;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch; 
    overflow-y: hidden;
    margin: 0;
    padding: 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.calendar-wrapper::-webkit-scrollbar {
    display: none;
}

.week {
    margin: 0;
    padding: 0;
    scroll-snap-align: center;
}

.mini-date {
    width: 14.28%;
    display: flex;
    flex-direction: column;
    text-align: center;
    padding-top: 10px;
    padding-bottom: 10px;
    margin: 0;
    p {
        padding-top: 2px;
        padding-bottom: 2px;
        pointer-events: none;
    }

    &.picked {
        background-color: var(--theme_transparent_color);
        color: var(--theme_cus_4_color);
        border-radius: 15px;
        font-weight: bold;
    }
}

.disabled {
    pointer-events: none;
    color: var(--theme_shadow_color);
    &.clickable {
        pointer-events: all;
    }
}

/* Summary Card Styles */
.summary-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid var(--theme_neutral_medium);
}

.summary-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(26, 54, 93, 0.15) !important;
}

/* Country-specific color themes for summary cards */
.summary-card.CHINA {
    --country-primary: #ffebee;  /* Light red background */
    --country-accent: #f44336;   /* Red accent */
    --country-header: linear-gradient(135deg, #ffcdd2, #f44336); /* Light red to red */
}

.summary-card.CHINA.QD {
    --country-primary: #ffcdd2;  /* Light red */
    --country-accent: #d32f2f;   /* Dark red */
    --country-header: linear-gradient(135deg, #f44336, #b71c1c); /* Red to dark red */
}

.summary-card.TAIWAN {
    --country-primary: #e8f5e8;  /* Light green */
    --country-accent: #56c55a;   /* Green */
    --country-header: linear-gradient(135deg, #56c55a, #38823a); /* Light green to green */
}

/* Default blue theme (when no specific class is declared) */
.summary-card {
    --country-primary: var(--theme_primary_light);
    --country-accent: var(--theme_primary_medium);
    --country-header: linear-gradient(135deg, var(--theme_primary_medium), var(--theme_primary_dark));
}

/* Apply the color themes to summary card elements */
.summary-card .country-header {
    background: var(--country-header) !important;
}

.summary-card .stat-card {
    background: linear-gradient(135deg, var(--theme_neutral_white), var(--country-primary));
    border: 1px solid var(--country-accent);
}

.summary-card .stat-card:hover {
    background: linear-gradient(135deg, var(--country-primary), var(--theme_neutral_white));
    border-color: var(--country-accent);
}

.summary-card .stat-value {
    color: var(--theme_primary_dark);
}

.summary-card .stat-label {
    color: var(--country-accent);
}

.summary-card .agent-item-header {
    background: var(--country-primary);
    color: var(--theme_primary_dark) !important;
}

.summary-card .agent-item:hover {
    background: var(--country-primary);
}

.summary-card .total-row {
    background: linear-gradient(135deg, var(--country-primary), var(--theme_neutral_white));
    border: 2px solid var(--country-accent);
}

/* Specific adjustments for each country */
.summary-card.CHINA .agent-sales,
.summary-card.CHINA\ QD .agent-sales {
    color: #d32f2f !important; /* Red accent for sales numbers */
}

.summary-card.TAIWAN .agent-sales {
    color: #388e3c !important; /* Green accent for sales numbers */
}

/* Country Header - Blue Gradient */
.country-header {
    background: linear-gradient(135deg, var(--theme_primary_medium), var(--theme_primary_dark)) !important;
    box-shadow: 0 2px 8px rgba(26, 54, 93, 0.3);
    /* border: 1px solid var(--theme_primary_medium); */
}

/* Stat Cards - Blue Theme */
.stat-card {
    background: linear-gradient(135deg, var(--theme_neutral_white), var(--theme_primary_light));
    border: 1px solid var(--theme_primary_blue);
    transition: all 0.3s ease;
}

.stat-card:hover {
    background: linear-gradient(135deg, var(--theme_primary_light), var(--theme_neutral_white));
    border-color: var(--theme_primary_medium);
    transform: scale(1.05);
}

.stat-value {
    color: var(--theme_primary_dark);
    line-height: 1.2;
}

.stat-label {
    color: var(--theme_primary_medium);
    line-height: 1.2;
    margin-top: 2px;
    font-weight: 600;
}

/* Agents List */
.agents-list {
    border: 1px solid var(--theme_neutral_medium);
    border-radius: 8px;
    padding: 0 10px;
}

.agents-list::-webkit-scrollbar {
    width: 6px;
}

.agents-list::-webkit-scrollbar-track {
    background: var(--theme_neutral_light);
    border-radius: 3px;
}

.agents-list::-webkit-scrollbar-thumb {
    background: var(--theme_primary_blue);
    border-radius: 3px;
}

.agents-list::-webkit-scrollbar-thumb:hover {
    background: var(--theme_primary_medium);
}

.agent-item-header {
    background: var(--theme_primary_light);
    color: var(--theme_primary_dark) !important;
    border-radius: 6px;
    margin: 0 -10px;
    padding-left: 10px !important;
    padding-right: 10px !important;
}

.agent-item {
    transition: all 0.2s ease;
    border-bottom: 1px solid var(--theme_neutral_medium);
}

.agent-item:hover {
    background: var(--theme_primary_light);
    border-radius: 4px;
    margin: 2px -5px;
    padding-left: 5px !important;
    padding-right: 5px !important;
}

.agent-item:nth-child(even) {
    background-color: var(--theme_neutral_light);
}

.agent-item:nth-child(even):hover {
    background: var(--theme_primary_light);
}

.agent-name {
    color: var(--theme_primary_dark);
    font-weight: 600;
}

.agent-group, .agent-pax, .agent-perpax {
    color: var(--theme_primary_medium);
}

.agent-sales {
    color: var(--theme_accent_teal) !important;
}

/* Total Row - Blue Theme */
.total-row {
    background: linear-gradient(135deg, var(--theme_primary_light), var(--theme_neutral_white));
    border: 2px solid var(--theme_primary_blue);
    box-shadow: 0 2px 8px rgba(26, 54, 93, 0.15);
}

.total-agent-label {
    color: var(--theme_primary_dark) !important;
    font-weight: 700;
}

.total-group, .total-pax, .total-sales, .total-perpax {
    color: var(--theme_primary_medium) !important;
    font-weight: 700;
}

/* Update existing components to match new palette */
.round-white-box {
    background: var(--theme_neutral_white) !important;
    border: 1px solid var(--theme_neutral_medium);
}

.sales_tab.btn-group .btn.active {
    border: 2px solid var(--theme_primary_medium);
    background: linear-gradient(135deg, var(--theme_primary_medium), var(--theme_primary_dark));
    color: white;
}

#summ_comp_tab {
    background: linear-gradient(135deg, var(--theme_neutral_white), var(--theme_primary_light));
    border: 1px solid var(--theme_primary_blue);
}


/* Mini-date improvements */
.mini-date.picked {
    background: linear-gradient(135deg, var(--theme_primary_light), var(--theme_neutral_white));
    color: var(--theme_primary_dark);
    border: 1px solid var(--theme_primary_blue);
}

/* Animation improvements */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.agent-item {
    animation: fadeInUp 0.4s ease;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .stat-card {
        padding: 0.4rem 0.2rem;
    }
    
    .stat-value {
        font-size: 12px !important;
    }
    
    .stat-label {
        font-size: 9px !important;
    }
}

@media (min-width: 801px) {
    ons-navigator {
        margin: auto;
        /* max-width: 800px; */
    }

    body {
        /* max-width:800px; */
        border:0px;
        border-left:0px solid #999;
        border-right:0px solid #999;
        position:absolute;
        width:100%;
        min-height:100%;
        left:50%;
        top:50%;
        transform: translate(-50%, -50%);
    }
	
	/* width */
	::-webkit-scrollbar {
	  width: 5px;
	  height:5px;
	}
	
	/* Track */
	::-webkit-scrollbar-track {
	  background: #f1f1f1; 
	}
	 
	/* Handle */
	::-webkit-scrollbar-thumb {
	  background: #888; 
	}
	
	/* Handle on hover */
	::-webkit-scrollbar-thumb:hover {
	  background: #555; 
	}
	
}
/* Mobile Landscape Optimizations */
@media (max-width: 896px) and (orientation: landscape) and (max-height: 500px) {
    /* Adjust toolbar and tabbar heights for landscape */
    :root {
        --toolbar_custom_height: 40px;
        --tabbar_custom_height: 45px;
    }
    
    /* Reduce padding in sidebar for landscape */
    .sidebar-header {
        padding: 1rem 0.75rem !important;
        margin-bottom: 0.5rem;
    }
    
    .profile-image-container {
        width: 60px;
        height: 60px;
    }
    
    .user-name {
        font-size: 1rem;
    }
    
    .sidebar-menu-item {
        min-height: 44px !important;
        margin: 4px 0 !important;
    }
    
    .sidebar-menu {
        padding: 0 0.5rem !important;
    }
    
    /* Adjust main content positioning */
    .toolbar+.page__background, .toolbar+.page__background+.page__content {
        top: var(--toolbar_custom_height) !important;
    }
    
    /* Reduce font sizes for compact layout */
    .fs-16px { font-size: 14px; }
    .fs-18px { font-size: 16px; }
    .fs-20px { font-size: 18px; }
    .fs-22px { font-size: 20px; }
    .fs-24px { font-size: 22px; }
    
    /* Compact form elements */
    .user-box input {
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .user-box label {
        font-size: 14px;
        left: 20px;
    }
    
    .user-box .submit {
        padding: 12px 20px;
    }
    
    /* Adjust calendar for landscape */
    .calendar-wrapper {
        padding-bottom: 5px;
    }
    
    .mini-date {
        padding-top: 6px;
        padding-bottom: 6px;
    }
    
    /* Compact summary cards */
    .summary-card {
        margin-bottom: 0.5rem;
    }
    
    .stat-card {
        padding: 0.3rem 0.2rem;
    }
    
    .stat-value {
        font-size: 11px !important;
    }
    
    .stat-label {
        font-size: 8px !important;
    }
    
    /* Compact agents list */
    .agents-list {
        max-height: 120px;
    }
    
    /* Adjust sales tabs */
    .sales_tab.btn-group .btn {
        padding: 0.25rem 0.75rem;
        font-size: 0.8rem;
    }
    
    .sales_tab .btn .badge {
        font-size: 0.55rem;
        padding: 0.15em 0.3em;
        min-width: 1.2em;
        height: 1.2em;
    }
    
    /* Position adjustments */
    .position-center {
        transform: translate(-50%, -50%) !important;
    }
    
    /* Reduce spacing in various components */
    .round-white-box,
    .round-yellow-box {
        padding: 0.5rem !important;
    }
    
    /* Tabbar adjustments */
    .tabbar {
        height: var(--tabbar_custom_height);
    }
    
    .tabbar .tabbar__button {
        height: var(--tabbar_custom_height);
        padding: 4px 0;
    }
    
    .tabbar span {
        font-size: 9px;
    }
}

/* Additional landscape optimization for very small heights */
@media (max-width: 896px) and (orientation: landscape) and (max-height: 400px) {
    :root {
        --toolbar_custom_height: 35px;
        --tabbar_custom_height: 40px;
    }
    
    .sidebar-header {
        padding: 0.5rem 0.5rem !important;
    }
    
    .profile-image-container {
        width: 50px;
        height: 50px;
    }
    
    .sidebar-menu-item {
        min-height: 40px !important;
    }
    
    .menu-icon {
        font-size: 1rem;
    }
    
    .sidebar-menu-item .center {
        font-size: 0.85rem;
    }
}

/* Landscape optimization for tablets */
@media (min-width: 768px) and (max-width: 1024px) and (orientation: landscape) and (max-height: 768px) {
    ons-splitter-side {
        width: 320px !important;
    }
    
    /* Adjust layout for tablet landscape */
    .custom-height {
        min-height: calc(var(--custom_min_height) - 120px);
    }
}

/* Fix for iOS Safari landscape viewport height */
@supports (-webkit-touch-callout: none) {
    @media (max-width: 896px) and (orientation: landscape) {
        .page__content {
            min-height: -webkit-fill-available;
        }
    }
}

.custom-dropdown {
    position: relative;
}

.custom-dropdown .dropdown-toggle {
    display: flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    background-color: #fff;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    cursor: pointer;
}

.custom-dropdown .dropdown-toggle:after {
    margin-left: auto;
}

.dropdown-selected-content {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.selected-company-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.custom-dropdown .dropdown-menu {
    max-height: 300px;
    overflow-y: auto;
}

.custom-dropdown .dropdown-item {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
}

.option-icon-placeholder {
    background-color: #f8f9fa;
    border: 1px dashed #dee2e6;
    border-radius: 4px;
}

/* Loading Container Styles */
.loading-container {
    position: relative;
    min-height: 150px;
}

.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    border-radius: 15px;
}

.loading-spinner {
    text-align: center;
    padding: 2rem;
}

.loading-text {
    color: var(--theme_primary_dark);
    font-weight: 600;
    font-size: 1rem;
}

/* Enhanced spinner with theme colors */
.spinner-border.text-primary {
    color: var(--theme_primary_medium) !important;
    border-color: var(--theme_primary_medium);
    width: 3rem;
    height: 3rem;
    border-width: 0.3em;
}

/* Pulse animation for loading */
@keyframes pulse-loading {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
    100% {
        opacity: 1;
    }
}

.loading-container .loading-text {
    animation: pulse-loading 1.5s ease-in-out infinite;
}

/* Loading states for other elements */
.loading .mini-date {
    opacity: 0.6;
    pointer-events: none;
}

.loading .sales_tab .btn {
    pointer-events: none;
    opacity: 0.7;
}

/* Responsive loading */
@media (max-width: 576px) {
    .loading-spinner {
        padding: 1rem;
    }
    
    .spinner-border.text-primary {
        width: 2.5rem;
        height: 2.5rem;
    }
    
    .loading-text {
        font-size: 0.9rem;
    }
}

/* Full page gradient background */
.login-background {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, var(--login_gradient_start) 40%, var(--login_gradient_end) 100%);
    z-index: -1;
}

.mobile-app-container {
    max-width: 100%;
    width: 100%;
    min-height: 100%;
    position: relative;
    overflow: hidden;
    background: transparent;
}

/* Header styling */
.login-header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    padding: 40px 20px 30px;
    min-height: 200px;
}

.header-content {
    position: relative;
    z-index: 2;
}

.header-image {
    width: 200px;
    height: 200px;
    object-fit: cover;
    margin-bottom: 0px;
}

.app-title {
    font-size: 2.2em;
    margin-bottom: 8px;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.app-subtitle {
    font-size: 1em;
    opacity: 0.9;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.login-container {
    padding: 20px 25px 40px;
    max-width: 400px;
    margin: 0 auto;
}

.login-form {
    background: var(--login_form_bg);
    border-radius: var(--login_border_radius);
    padding: 30px 25px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--theme_neutral_medium);
    position: relative;
    z-index: 1;
    backdrop-filter: blur(10px);
}

.form-group {
    margin-bottom: 22px;
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--theme_primary_dark);
    font-size: 0.95em;
    padding-left: 5px;
}

.form-input {
    width: 100%;
    padding: 16px 20px;
    border: 1.5px solid var(--theme_neutral_medium);
    border-radius: 12px;
    font-size: 1em;
    transition: all 0.3s ease;
    background: var(--theme_neutral_light);
    color: var(--theme_primary_dark);
}

.form-input:focus {
    outline: none;
    border-color: var(--theme_primary_blue);
    box-shadow: 0 0 0 3px rgba(152, 223, 239, 0.15);
    background: var(--theme_neutral_white);
}

.password-container {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--theme_neutral_dark);
    cursor: pointer;
    font-size: 1.1em;
    padding: 5px;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.toggle-password:hover {
    background: var(--theme_neutral_light);
}

.login-button {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--theme_primary_blue), var(--theme_primary_medium));
    color: var(--theme_neutral_white);
    border: none;
    border-radius: 12px;
    font-size: 1.05em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px var(--login_shadow);
}

.login-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(152, 223, 239, 0.4);
}

.login-button:active {
    transform: translateY(-1px);
}

.login-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.forgot-password,
.register-link {
    color: var(--theme_primary_medium);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9em;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 5px;
    transition: all 0.2s ease;
}

.forgot-password:hover,
.register-link:hover {
    background: var(--theme_primary_light);
    text-decoration: underline;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9em;
    display: none;
    border-left: 4px solid #dc3545;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9em;
    display: none;
    border-left: 4px solid #28a745;
}

/* Auto-login message styles */
#auto-login-message {
    background: var(--login_form_bg);
    border-radius: var(--login_border_radius);
    padding: 40px 20px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--theme_neutral_medium);
}

.spinner-container {
    margin-bottom: 20px;
}

.spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid var(--theme_neutral_light);
    border-top: 4px solid var(--theme_primary_blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.auto-login-text {
    color: var(--theme_primary_blue);
    font-weight: 600;
    margin-bottom: 10px;
}

.cancel-auto-login-btn {
    background: none;
    border: 1px solid var(--theme_primary_blue);
    color: var(--theme_primary_blue);
    padding: 8px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9em;
    transition: all 0.2s ease;
}

.cancel-auto-login-btn:hover {
    background: var(--theme_primary_light);
}

/* Responsive Design */
@media (min-width: 768px) {
    .mobile-app-container {
        max-width: 414px;
        min-height: 85vh;
        border-radius: 25px;
        overflow: hidden;
        margin: 30px auto;
        box-shadow: 0 0 30px rgba(0, 0, 0, 0.15);
    }
    
    .login-background {
        border-radius: 25px;
    }
}

@media (max-width: 480px) {
    .login-header {
        min-height: 180px;
        padding: 30px 20px 20px;
    }
    
    .header-image {
        width: 200px;
        height: 200px;
        margin-bottom: 0px;
    }
    
    .app-title {
        font-size: 1.8em;
    }
    
    .app-subtitle {
        font-size: 0.9em;
    }
    
    .login-container {
        padding: 20px 15px;
    }
    
    .login-form {
        padding: 20px 15px;
    }
}

/* Landscape orientation */
@media (max-width: 896px) and (orientation: landscape) and (max-height: 500px) {
    .login-header {
        min-height: 120px;
        padding: 20px 20px 15px;
    }
    
    .header-image {
        width: 200px;
        height: 200px;
        margin-bottom: 0px;
    }
    
    .app-title {
        font-size: 1.5em;
        margin-bottom: 5px;
    }
    
    .app-subtitle {
        font-size: 0.8em;
    }
    
    .login-container {
        padding: 15px 20px 25px;
    }
    
    .login-form {
        padding: 20px;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
    
    .form-input {
        padding: 12px 16px;
        font-size: 0.9em;
    }
    
    .login-button {
        padding: 12px;
        font-size: 0.95em;
        margin-bottom: 15px;
    }
}

.back-button {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.back-button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(-2px);
}

.back-button i {
    font-size: 1.2em;
}

.instruction-text {
    color: var(--theme_neutral_dark);
    font-size: 0.95em;
    text-align: center;
    line-height: 1.5;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .back-button {
        width: 35px;
        height: 35px;
        margin: 10px;
    }
    
    .instruction-text {
        font-size: 0.9em;
        padding: 0 5px;
    }
}

/* Landscape orientation */
@media (max-width: 896px) and (orientation: landscape) and (max-height: 500px) {
    .login-header {
        min-height: 120px;
        padding: 20px 20px 15px;
    }
    
    .header-image {
        width: 200px;
        height: 200px;
        margin-bottom: 0px;
    }
    
    .app-title {
        font-size: 1.5em;
        margin-bottom: 5px;
    }
    
    .app-subtitle {
        font-size: 0.8em;
    }
    
    .instruction-text {
        font-size: 0.85em;
        margin-bottom: 15px;
    }
    
    .back-button {
        width: 35px;
        height: 35px;
    }
}

/* OTP button styling */
.otp-button {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--theme_accent_teal);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 0.85em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2;
}

.otp-button:hover {
    background: var(--theme_accent_light_teal);
    transform: translateY(-50%) scale(1.05);
}

.otp-button:disabled {
    background: var(--theme_neutral_medium);
    cursor: not-allowed;
    transform: translateY(-50%);
}

/* Style for date input */
input[type="date"] {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    color: var(--theme_primary_dark);
}

input[type="date"]::-webkit-calendar-picker-indicator {
    opacity: 0.6;
    cursor: pointer;
}

/* Adjust form-input for selects */
.form-input.selectpicker {
    padding: 15px 20px !important;
}

/* Adjust form group spacing for longer form */
.login-form .form-group {
    margin-bottom: 18px;
}

/* Make the form scrollable on smaller screens */
.login-form {
    overflow-y: auto;
}

.login-form::-webkit-scrollbar {
    width: 5px;
}

.login-form::-webkit-scrollbar-track {
    background: var(--theme_neutral_light);
    border-radius: 3px;
}

.login-form::-webkit-scrollbar-thumb {
    background: var(--theme_primary_blue);
    border-radius: 3px;
}

/* Adjust for landscape orientation */
@media (max-width: 896px) and (orientation: landscape) and (max-height: 500px) {
    .login-form .form-group {
        margin-bottom: 15px;
    }
    
    .form-input {
        padding: 12px 16px !important;
        font-size: 0.9em;
    }
    
    .otp-button {
        padding: 6px 12px;
        font-size: 0.8em;
    }
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .otp-button {
        padding: 6px 12px;
        font-size: 0.8em;
    }
}

/* Error icon styling */
.error-icon {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Password validation styling */
.is-invalid {
    border-color: #dc3545 !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.is-valid {
    border-color: var(--theme_accent_teal) !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23039564' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

/* Button styling for expired link page */
.login-form a.login-button {
    display: block;
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--theme_primary_blue), var(--theme_primary_medium));
    color: var(--theme_neutral_white);
    border: none;
    border-radius: 12px;
    font-size: 1.05em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px var(--login_shadow);
}

.login-form a.login-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(152, 223, 239, 0.4);
    text-decoration: none;
}

/* Adjust for landscape orientation */
@media (max-width: 896px) and (orientation: landscape) and (max-height: 500px) {
    .login-header {
        min-height: 120px;
        padding: 20px 20px 15px;
    }
    
    .header-image {
        width: 200px;
        height: 200px;
        margin-bottom: 0px;
    }
    
    .app-title {
        font-size: 1.5em;
        margin-bottom: 5px;
    }
    
    .app-subtitle {
        font-size: 0.8em;
    }
    
    .instruction-text {
        font-size: 0.85em;
        margin-bottom: 15px;
    }
}