/* User Panel CSS Variables - Override base variables */
:root {
    --primary-color: #007bff;
    --secondary-color: #0056b3;

    /* Sidebar colors for both modes */
    --sidebar-bg: #000000;
    --sidebar-text: #ffffff;
    --sidebar-hover-bg: #f3f4f6;
    --sidebar-active-bg: #a3daff;
    --sidebar-active-text: #0369a1;
    --sidebar-border: #e5e7eb;
}

/* Dark mode sidebar variables */
[data-theme="dark"] {
    --sidebar-bg: #1f2937;
    --sidebar-text: #f9fafb;
    --sidebar-hover-bg: #374151;
    --sidebar-active-bg: #374151;
    --sidebar-active-text: #e0f2fe;
    --sidebar-border: #374151;
}

/* Custom sidebar styling for light mode only */
[data-theme="light"] #sidebar {
    background-color: var(--sidebar-bg);
    border-right-color: var(--sidebar-border);
}

[data-theme="light"] #sidebar .border-b {
    border-color: var(--sidebar-border);
}

[data-theme="light"] #sidebar .text-xl {
    color: var(--sidebar-text);
}

[data-theme="light"] #sidebar ul.space-y-3 li a {
    color: var(--sidebar-text);
}

[data-theme="light"] #sidebar ul.space-y-3 li a:hover {
    background-color: var(--sidebar-hover-bg);
    color: var(--sidebar-active-text);
}

/* Keep active item styling consistent */
[data-theme="light"] #sidebar ul.space-y-3 li a.bg-primary-100 {
    background-color: var(--sidebar-active-bg);
    color: var(--sidebar-active-text);
}

/* Bottom toggle button styling */
[data-theme="light"] #sidebar .border-t {
    border-color: var(--sidebar-border);
}

[data-theme="light"] #sidebar #toggleSidebarButton {
    color: var(--sidebar-text);
}

/* Dark mode sidebar styling */
[data-theme="dark"] #sidebar {
    background-color: var(--sidebar-bg);
    border-right-color: var(--sidebar-border);
}

[data-theme="dark"] #sidebar .border-b,
[data-theme="dark"] #sidebar .border-t {
    border-color: var(--sidebar-border);
}

[data-theme="dark"] #sidebar .text-xl {
    color: var(--sidebar-text);
}

[data-theme="dark"] #sidebar ul.space-y-3 li a {
    color: var(--sidebar-text);
}

[data-theme="dark"] #sidebar ul.space-y-3 li a:hover {
    background-color: var(--sidebar-hover-bg);
}

[data-theme="dark"] #sidebar ul.space-y-3 li a.bg-primary-900 {
    background-color: var(--sidebar-active-bg);
    color: var(--sidebar-active-text);
}

[data-theme="dark"] #sidebar #toggleSidebarButton {
    color: var(--sidebar-text);
}

/* Logo styling */
.full-logo {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 700;
    letter-spacing: 0.5px;
    position: relative;
    padding: 0 2px;
    text-shadow: 0px 0px 1px rgba(0, 0, 0, 0.1);
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
    cursor: default;
}

/* Add a subtle animation on hover */
.full-logo:hover {
    transform: translateY(-1px);
    filter: drop-shadow(0 2px 4px rgba(0, 123, 255, 0.3));
}

/* Add a small icon before the logo */
.full-logo::before {
    content: "\f233"; /* Server icon from Font Awesome */
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 6px;
    font-size: 0.9em;
    opacity: 0.9;
    color: var(--primary-color);
    text-shadow: none;
    transition: transform 0.3s ease;
}

/* Icon animation on hover */
.full-logo:hover::before {
    transform: rotate(-10deg);
    color: var(--secondary-color);
}

/* Add a subtle underline effect on hover */
.full-logo::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width 0.3s ease;
    opacity: 0.7;
    border-radius: 2px;
}

.full-logo:hover::after {
    width: 100%;
}

/* Short logo styling for collapsed sidebar */
.short-logo {
    font-weight: 800;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 1.5rem;
    position: relative;
    display: inline-flex;
    align-items: center;
}

/* Add icon to short logo */
.short-logo::before {
    content: "\f233";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 4px;
    font-size: 0.9em;
    color: var(--primary-color);
}

/* Dark mode specific adjustments */
[data-theme="dark"] .full-logo,
[data-theme="dark"] .short-logo {
    filter: drop-shadow(0 1px 2px rgba(255, 255, 255, 0.1));
}

/* Additional modern template specific styles can be added here */

/* Enhance light mode table headers and tabs */
[data-theme="light"] .table-header,
[data-theme="light"] thead tr,
[data-theme="light"] th {
    background-color: var(--sidebar-active-bg) !important; /* Sử dụng màu nền mục active */
    color: var(--sidebar-text) !important; /* Sử dụng màu chữ sidebar */
    border-bottom: 2px solid var(--primary-color) !important;
}

/* Styling for plan type buttons */
.plan-type-btn.active-tab {
    background-color: var(--sidebar-active-bg) !important;
    color: var(--sidebar-active-text) !important;
    border: 1px solid var(--primary-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.plan-type-btn.active-tab:hover {
    background-color: var(--sidebar-active-bg) !important;
    filter: brightness(0.95);
}

.plan-type-btn.inactive-tab {
    background-color: #f3f4f6;
    color: #4b5563;
    border: 1px solid #e5e7eb;
}

[data-theme="light"] .plan-type-btn.inactive-tab:hover {
    background-color: var(--sidebar-hover-bg);
}

/* Enhance service tabs in light mode */
[data-theme="light"] .service-tabs {
    border-bottom: 1px solid #e5e7eb;
}

[data-theme="light"] .service-tabs a {
    position: relative;
    padding: 0.75rem 1rem;
    font-weight: 500;
}

[data-theme="light"] .service-tabs a.active {
    color: var(--primary-color);
    font-weight: 600;
    background-color: transparent;
    border-bottom: 2px solid var(--primary-color);
    margin-bottom: -1px;
}

[data-theme="light"] .service-tabs a:not(.active):hover {
    background-color: #f3f4f6;
    border-top-left-radius: 0.375rem;
    border-top-right-radius: 0.375rem;
}

/* Enhance table row hover in light mode */
[data-theme="light"] tbody tr:hover {
    background-color: var(--sidebar-hover-bg) !important;
}

/* Add subtle box shadow to cards in light mode */
[data-theme="light"] .card {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}