:root {
    --primary-color: #2563eb;
    --primary-dark: #1e40af;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --bg-light: #f8fafc;
    --bg-white: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-primary);
    font-size: 13px;
    line-height: 1.5;
}

/* Top Navigation Bar */
.navbar-admin {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    padding: 0.5rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--primary-color) !important;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.navbar-brand i {
    font-size: 1.3rem;
}

.navbar-nav .nav-link {
    color: var(--text-primary) !important;
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.4rem 0.75rem !important;
    border-radius: 6px;
    transition: all 0.2s ease;
    margin: 0 0.15rem;
}

.navbar-nav .nav-link:hover {
    background-color: var(--bg-light);
    color: var(--primary-color) !important;
}

.navbar-nav .nav-link.active {
    background-color: var(--primary-color);
    color: white !important;
}

.dropdown-menu {
    border: none;
    box-shadow: var(--shadow-lg);
    border-radius: 6px;
    padding: 0.4rem;
    margin-top: 0.4rem;
    min-width: 180px;
    font-size: 0.875rem;
}

.dropdown-item {
    padding: 0.5rem 0.75rem;
    border-radius: 5px;
    font-weight: 400;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.dropdown-item:hover {
    background-color: var(--bg-light);
    color: var(--primary-color);
}

.dropdown-item i {
    width: 18px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.dropdown-item:hover i {
    color: var(--primary-color);
}

.dropdown-divider {
    margin: 0.4rem 0;
    border-color: var(--border-color);
}

/* Profile Dropdown */
.profile-dropdown {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.profile-dropdown:hover {
    background-color: var(--bg-light);
}

.profile-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.8125rem;
}

.profile-avatar-img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.profile-info {
    display: flex;
    flex-direction: column;
}

.profile-name {
    font-weight: 600;
    font-size: 0.8125rem;
    color: var(--text-primary);
    line-height: 1.2;
}

.profile-role {
    font-size: 0.6875rem;
    color: var(--text-secondary);
    line-height: 1.2;
}

/* Main Content */
.main-content {
    padding: 1rem 0;
}

.page-header {
    margin-bottom: 1.25rem;
}

.page-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* App Grid */
.apps-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.app-card {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
}

.app-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
    text-decoration: none;
    color: inherit;
}

.app-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 0.75rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
}

.app-card:nth-child(2) .app-icon {
    background: linear-gradient(135deg, #10b981, #059669);
}

.app-card:nth-child(3) .app-icon {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.app-card:nth-child(4) .app-icon {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

.app-card:nth-child(5) .app-icon {
    background: linear-gradient(135deg, #ec4899, #db2777);
}

.app-card:nth-child(6) .app-icon {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
}

.app-card:nth-child(7) .app-icon {
    background: linear-gradient(135deg, #f97316, #ea580c);
}

.app-card:nth-child(8) .app-icon {
    background: linear-gradient(135deg, #14b8a6, #0d9488);
}

.app-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-primary);
    margin-bottom: 0.2rem;
}

.app-description {
    font-size: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.3;
}

/* Responsive */
@media (max-width: 768px) {
    .apps-container {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 0.75rem;
    }

    .profile-info {
        display: none;
    }

    .navbar-nav .nav-link {
        padding: 0.4rem 0.6rem !important;
        font-size: 0.8125rem;
    }

    .main-content {
        padding: 0.75rem 0;
    }

    .page-header {
        margin-bottom: 1rem;
    }

    /* .page-title {
        font-size: 1.25rem;
    } */
}

/* Badge */
.badge-notification {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--danger-color);
    color: white;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    font-size: 0.625rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/* Standard Button Styles - Common sizing for modal and page action buttons */
.btn-standard {
    height: 32px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 14px;
}


/* recent activities styles  start */
/* Activity styles */
.activity-list { max-height: 390px; overflow-y: auto; }
.activity-item { display: flex; gap: 0.5rem; border-bottom: 1px solid #f3f4f6; padding-top:2px; }
.activity-item:last-child { border-bottom: none; }
.activity-icon { 
  width: 26px; height: 26px; border-radius: 50%; 
  display: flex; align-items: center; justify-content: center; 
  font-size: 0.65rem; flex-shrink: 0;
}
.activity-icon.create { background: #dcfce7; color: #16a34a; }
.activity-icon.update { background: #dbeafe; color: #2563eb; }
.activity-icon.delete { background: #fee2e2; color: #dc2626; }
.activity-icon.payment { background: #fef3c7; color: #d97706; }
.activity-icon.default { background: #f3f4f6; color: #6b7280; }
.activity-content { flex: 1; min-width: 0; }
.activity-text { font-size: 0.7rem; color: #374151; line-height: 1.3; }
.activity-meta { font-size: 0.6rem; color: #9ca3af; margin-top: 0.1rem; }
.activity-user { font-weight: 500; margin-right: 0.4rem; }

/* recent activities styles  end */

.ql-editor{
    padding: 0px;
}
.ql-editor p{
    font-size: 14px;
    line-height: 1.8;
    min-height: 10px;
}

/* Status Dropdown Styles */
.status-dropdown {
    font-size: 0.75rem;
    padding: 0.2rem 0.4rem;
    width: auto;
    min-width: 100px;
    display: inline-block;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.status-dropdown:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Status Dropdown Color Classes */
.status-dropdown.status-primary {
    background-color: #dbeafe !important;
    color: #1e40af !important;
    border-color: #2563eb !important;
}

.status-dropdown.status-warning {
    background-color: #fef3c7 !important;
    color: #92400e !important;
    border-color: #f59e0b !important;
}

.status-dropdown.status-info {
    background-color: #dbeafe !important;
    color: #1e40af !important;
    border-color: #3b82f6 !important;
}

.status-dropdown.status-success {
    background-color: #d1fae5 !important;
    color: #065f46 !important;
    border-color: #10b981 !important;
}

.status-dropdown.status-danger {
    background-color: #fee2e2 !important;
    color: #991b1b !important;
    border-color: #ef4444 !important;
}

.status-dropdown.status-secondary {
    background-color: #f3f4f6 !important;
    color: #6b7280 !important;
    border-color: #9ca3af !important;
}

/* Status Dropdown Options */
.status-dropdown option {
    padding: 0.4rem;
}

.status-dropdown option[style*="background-color: #dbeafe"] {
    background-color: #dbeafe !important;
    color: #1e40af !important;
}

.status-dropdown option[style*="background-color: #fef3c7"] {
    background-color: #fef3c7 !important;
    color: #92400e !important;
}

.status-dropdown option[style*="background-color: #d1fae5"] {
    background-color: #d1fae5 !important;
    color: #065f46 !important;
}

.status-dropdown option[style*="background-color: #fee2e2"] {
    background-color: #fee2e2 !important;
    color: #991b1b !important;
}

.status-dropdown option[style*="background-color: #f3f4f6"] {
    background-color: #f3f4f6 !important;
    color: #6b7280 !important;
}

/* Language Dropdown Styles */
.language-dropdown-wrapper {
    display: inline-block;
}

/* Standalone button style (for login/register pages) */
.language-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    text-decoration: none;
    color: var(--text-primary, #1f2937);
    border-radius: 6px;
    transition: background-color 0.2s ease;
    background: white;
    border: 1px solid var(--border-color, #e5e7eb);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    cursor: pointer;
}

.language-dropdown-btn:hover {
    background-color: #f8f9fa;
    color: var(--text-primary, #1f2937);
}

.language-dropdown-btn[aria-expanded="true"] {
    background-color: #f8f9fa;
}

/* Navbar style (for main layout) */
.navbar-nav .language-dropdown-wrapper .language-dropdown-btn {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0.5rem 0.75rem;
}

.navbar-nav .language-dropdown-wrapper .language-dropdown-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.language-dropdown {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
}

.language-flag {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.language-info {
    display: flex;
    flex-direction: column;
}

.language-name {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary, #1f2937);
    line-height: 1.2;
}

.language-country {
    font-size: 0.75rem;
    color: var(--text-secondary, #6b7280);
    line-height: 1.2;
}

.language-flag-small {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.7rem;
    flex-shrink: 0;
}

.language-option.active {
    background-color: #e7f3ff !important;
    color: #0066cc !important;
}

.language-option.active .fw-semibold {
    color: #0066cc !important;
    font-weight: 600 !important;
}

.language-option.active .text-muted {
    color: #4d94ff !important;
}

.language-option.active .language-flag-small {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%) !important;
}

.language-option:hover {
    background-color: #f8f9fa;
}

.language-option.active:hover {
    background-color: #d6e9ff !important;
}

/* Language Dropdown Container (for login/register pages) */
.language-dropdown-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1050;
}

.language-dropdown-container .nav-item {
    margin: 0;
}

.language-dropdown-container .nav-link {
    padding: 0.5rem 0.75rem;
}

.language-dropdown-container .dropdown {
    position: relative;
}

.language-dropdown-container .dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    left: auto;
    z-index: 1000;
    display: none;
    min-width: 200px;
    padding: 0.5rem 0;
    margin: 0.125rem 0 0;
    font-size: 0.875rem;
    color: #212529;
    text-align: left;
    list-style: none;
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 0.375rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.language-dropdown-container .dropdown-menu.show {
    display: block;
}

.language-dropdown-container .dropdown-menu-end {
    right: 0;
    left: auto;
}

.language-dropdown-container .dropdown-item {
    display: block;
    width: 100%;
    padding: 0.5rem 1rem;
    clear: both;
    font-weight: 400;
    color: #212529;
    text-align: inherit;
    text-decoration: none;
    white-space: nowrap;
    background-color: transparent;
    border: 0;
    transition: background-color 0.15s ease-in-out;
}

.language-dropdown-container .dropdown-item:hover,
.language-dropdown-container .dropdown-item:focus {
    color: #1e2125;
    background-color: #e9ecef;
}

.language-dropdown-container .dropdown-item.active,
.language-dropdown-container .dropdown-item:active {
    color: #fff;
    background-color: #0d6efd;
}

@media (max-width: 576px) {
    .language-dropdown-container {
        top: 0.75rem;
        right: 0.75rem;
    }
    
    .language-dropdown-container .dropdown-menu {
        min-width: 180px;
    }
}