/* ============================================
   Admin Panel - Shop B2B
   ============================================ */

:root {
    /* Colors - Dark Theme */
    --bg-primary: #0f1117;
    --bg-secondary: #1a1d26;
    --bg-card: #22262f;
    --bg-hover: #2d323d;

    --text-primary: #ffffff;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;

    --accent-primary: #FFC244;
    --accent-secondary: #00A082;
    --accent-blue: #3b82f6;
    --accent-purple: #8b5cf6;
    --accent-pink: #ec4899;

    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #3b82f6;

    --border-color: #374151;
    --border-light: #2d323d;

    /* Spacing */
    --sidebar-width: 260px;
    --header-height: 70px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.5);

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 20px;
}

/* ============================================
   Reset & Base Styles
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    outline: none;
}

input,
select,
textarea {
    font-family: inherit;
    font-size: 14px;
}

.hidden {
    display: none !important;
}

/* ============================================
   Login Screen
   ============================================ */

.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-primary) 0%, #1e2332 50%, var(--bg-primary) 100%);
    padding: 20px;
}

.login-box {
    background: var(--bg-card);
    padding: 40px;
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 420px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header .logo {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 28px;
    color: var(--bg-primary);
}

.login-header h1 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 5px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 14px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.input-wrapper {
    position: relative;
}

.input-wrapper i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 44px 14px 44px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    transition: var(--transition-fast);
}

.input-wrapper input:focus {
    border-color: var(--accent-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 194, 68, 0.1);
}

.btn-primary {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--accent-primary), #e5ac00);
    color: var(--bg-primary);
    font-weight: 600;
    font-size: 15px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: var(--transition-fast);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 194, 68, 0.3);
}

.btn-secondary {
    padding: 12px 24px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-weight: 500;
    font-size: 14px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    transition: var(--transition-fast);
}

.btn-secondary:hover {
    background: var(--bg-hover);
}

.btn-danger {
    padding: 12px 24px;
    background: var(--danger);
    color: white;
    font-weight: 500;
    font-size: 14px;
    border-radius: var(--radius-md);
    transition: var(--transition-fast);
}

.btn-danger:hover {
    background: #dc2626;
}

.error-message {
    color: var(--danger);
    font-size: 13px;
    margin-top: 15px;
    text-align: center;
}

/* ============================================
   Dashboard Layout
   ============================================ */

.dashboard-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
    transition: var(--transition-normal);
}

.sidebar-header {
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header .logo {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--bg-primary);
}

.sidebar-header h2 {
    font-size: 18px;
    font-weight: 700;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 12px;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    transition: var(--transition-fast);
    margin-bottom: 4px;
}

.nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(255, 194, 68, 0.15), rgba(0, 160, 130, 0.15));
    color: var(--accent-primary);
}

.nav-item i {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.nav-item span {
    font-size: 14px;
    font-weight: 500;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid var(--border-color);
}

.btn-logout {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px;
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    border-radius: var(--radius-md);
    font-weight: 500;
    transition: var(--transition-fast);
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.2);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.main-header {
    height: var(--header-height);
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.menu-toggle {
    display: none;
    background: none;
    color: var(--text-primary);
    font-size: 20px;
    padding: 8px;
}

.main-header h1 {
    font-size: 20px;
    font-weight: 600;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
}

.user-info i {
    font-size: 28px;
    color: var(--accent-primary);
}

/* Content Area */
.content-area {
    flex: 1;
    padding: 30px;
    background: var(--bg-primary);
}

/* Pages */
.page {
    display: none;
}

.page.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Dashboard Overview
   ============================================ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    border: 1px solid var(--border-color);
    transition: var(--transition-fast);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.stat-icon.products {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-blue);
}

.stat-icon.categories {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple);
}

.stat-icon.orders {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.stat-icon.requests {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.stat-info h3 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 4px;
}

.stat-info p {
    color: var(--text-secondary);
    font-size: 13px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

/* ============================================
   Cards
   ============================================ */

.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-header h3 {
    font-size: 16px;
    font-weight: 600;
}

.view-all {
    color: var(--accent-primary);
    font-size: 13px;
    font-weight: 500;
}

.view-all:hover {
    text-decoration: underline;
}

.card-body {
    padding: 20px 24px;
    overflow-x: auto;
}

/* ============================================
   Tables
   ============================================ */

.table-controls {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 200px;
}

.search-box i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.search-box input {
    width: 100%;
    padding: 12px 12px 12px 42px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
}

.search-box input:focus {
    border-color: var(--accent-primary);
    outline: none;
}

select {
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    cursor: pointer;
    min-width: 180px;
}

select:focus {
    border-color: var(--accent-primary);
    outline: none;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

.data-table th {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: var(--bg-secondary);
}

.data-table td {
    font-size: 14px;
}

.data-table tbody tr:hover {
    background: var(--bg-hover);
}

.clickable-row {
    cursor: pointer;
    transition: background-color var(--transition-fast);
}

.clickable-row:hover {
    background-color: var(--bg-hover);
}

.data-table .loading,
.data-table .no-data {
    text-align: center;
    color: var(--text-muted);
    padding: 40px;
}

.data-table img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: var(--radius-sm);
}

.text-right {
    text-align: right;
}

/* Status Badges */
.status-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.phone-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    margin-top: 4px;
    display: inline-block;
    transition: var(--transition-fast);
}

.phone-link:hover {
    color: var(--accent-secondary);
    text-decoration: underline;
}

.status-badge.pending {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.status-badge.confirmed {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-blue);
}

.status-badge.processing {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple);
}

.status-badge.shipped {
    background: rgba(236, 72, 153, 0.15);
    color: var(--accent-pink);
}

.status-badge.delivered {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.status-badge.cancelled {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.status-badge.active {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.status-badge.inactive {
    background: rgba(107, 114, 128, 0.15);
    color: var(--text-muted);
}

.status-badge.approved {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.status-badge.rejected {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.status-badge.fulfilled {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-blue);
}

.status-badge.on_request {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 8px;
}

.btn-icon {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: var(--transition-fast);
}

.btn-icon.edit {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-blue);
}

.btn-icon.edit:hover {
    background: rgba(59, 130, 246, 0.25);
}

.btn-icon.delete {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.btn-icon.delete:hover {
    background: rgba(239, 68, 68, 0.25);
}

.btn-icon.view {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple);
}

.btn-icon.view:hover {
    background: rgba(139, 92, 246, 0.25);
}

/* Alerts List */
.alerts-list {
    list-style: none;
}

.alerts-list li {
    padding: 14px 0;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    gap: 12px;
}

.alerts-list li:last-child {
    border-bottom: none;
}

.alerts-list .alert-icon {
    width: 36px;
    height: 36px;
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.alerts-list .alert-info {
    flex: 1;
}

.alerts-list .alert-info strong {
    display: block;
    font-size: 14px;
    margin-bottom: 2px;
}

.alerts-list .alert-info span {
    font-size: 12px;
    color: var(--text-muted);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.pagination button {
    padding: 8px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    transition: var(--transition-fast);
}

.pagination button:hover {
    background: var(--bg-hover);
}

.pagination button.active {
    background: var(--accent-primary);
    color: var(--bg-primary);
    border-color: var(--accent-primary);
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
}

.page-actions {
    display: flex;
    gap: 10px;
}

.page-actions .btn-primary {
    width: auto;
    padding: 12px 20px;
}

/* ============================================
   Modals
   ============================================ */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
    animation: modalFadeIn 0.2s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-content {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    animation: modalSlideIn 0.2s ease;
}

.modal-content.large {
    max-width: 700px;
}

.modal-content.small {
    max-width: 400px;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    font-size: 18px;
    font-weight: 600;
}

.modal-close {
    background: none;
    color: var(--text-muted);
    font-size: 24px;
    line-height: 1;
    padding: 4px;
    transition: var(--transition-fast);
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
}

.modal-body .form-group {
    margin-bottom: 20px;
}

.modal-body .form-group:last-child {
    margin-bottom: 0;
}

.modal-body input,
.modal-body select,
.modal-body textarea {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
}

.modal-body input:focus,
.modal-body select:focus,
.modal-body textarea:focus {
    border-color: var(--accent-primary);
    outline: none;
}

.modal-body textarea {
    resize: vertical;
    min-height: 80px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.checkbox-label input {
    width: 18px;
    height: 18px;
    accent-color: var(--accent-primary);
}

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.modal-footer .btn-primary {
    width: auto;
    padding: 12px 24px;
}

/* Image Upload */
.image-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-fast);
}

.image-upload-area:hover {
    border-color: var(--accent-primary);
}

.image-upload-area.dragover {
    border-color: var(--accent-primary);
    background: rgba(255, 194, 68, 0.05);
}

.upload-placeholder i {
    font-size: 32px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.upload-placeholder p {
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.upload-placeholder span {
    font-size: 12px;
    color: var(--text-muted);
}

.image-preview {
    position: relative;
    display: block;
    text-align: center;
}

.image-preview img {
    display: block;
    max-width: 100%;
    max-height: 200px;
    border-radius: var(--radius-md);
    margin: 0 auto;
    object-fit: contain;
}

.remove-image {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 28px;
    height: 28px;
    background: var(--danger);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

/* Order Details */
.order-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 25px;
}

.info-item label {
    font-size: 12px;
    color: var(--text-muted);
    display: block;
    margin-bottom: 4px;
}

.info-item span {
    font-weight: 500;
}

.order-items h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 15px;
}

/* ============================================
   Toast Notifications
   ============================================ */

#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    min-width: 300px;
    max-width: 400px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow-lg);
    animation: toastSlideIn 0.3s ease;
}

@keyframes toastSlideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast.success {
    border-left: 4px solid var(--success);
}

.toast.error {
    border-left: 4px solid var(--danger);
}

.toast.warning {
    border-left: 4px solid var(--warning);
}

.toast.info {
    border-left: 4px solid var(--info);
}

.toast i {
    font-size: 18px;
}

.toast.success i {
    color: var(--success);
}

.toast.error i {
    color: var(--danger);
}

.toast.warning i {
    color: var(--warning);
}

.toast.info i {
    color: var(--info);
}

.toast-message {
    flex: 1;
    font-size: 14px;
}

.toast-close {
    background: none;
    color: var(--text-muted);
    font-size: 16px;
    padding: 4px;
}

/* ============================================
   Product Options
   ============================================ */

.form-section {
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid var(--border-color);
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.section-header h4 {
    font-size: 15px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-header h4 i {
    color: var(--accent-primary);
}

.btn-sm {
    padding: 8px 14px;
    font-size: 13px;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-sm.btn-primary {
    background: var(--accent-primary);
    color: var(--bg-primary);
    width: auto;
}

.btn-sm.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.options-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 15px;
}

.option-item {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 15px;
    border: 1px solid var(--border-color);
}

.option-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.option-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--accent-primary);
}

.option-actions {
    display: flex;
    gap: 8px;
}

.option-values {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.option-value-tag {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.option-value-tag .price-mod {
    color: var(--success);
    font-weight: 500;
}

.option-value-tag .price-mod.negative {
    color: var(--danger);
}

.option-value-tag button {
    background: none;
    color: var(--text-muted);
    font-size: 10px;
    padding: 2px;
}

.option-value-tag button:hover {
    color: var(--danger);
}

/* Option Values Form */
.option-values-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.option-value-row {
    display: grid;
    grid-template-columns: 1fr 100px auto;
    gap: 10px;
    align-items: center;
}

.option-value-row input {
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
}

.option-value-row .btn-remove-value {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Help Text */
.help-text {
    color: var(--text-muted);
    font-size: 13px;
    margin-bottom: 20px;
    line-height: 1.6;
}

.form-hint {
    display: block;
    color: var(--text-muted);
    font-size: 12px;
    margin-top: 6px;
}

/* Form Static Text */
.form-static {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 15px;
}

/* Reward Tier Colors */
.tier-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.tier-badge.bronze {
    background: rgba(205, 127, 50, 0.15);
    color: #cd7f32;
}

.tier-badge.silver {
    background: rgba(192, 192, 192, 0.15);
    color: #c0c0c0;
}

.tier-badge.gold {
    background: rgba(255, 215, 0, 0.15);
    color: #ffd700;
}

.tier-badge.none {
    background: rgba(107, 114, 128, 0.15);
    color: var(--text-muted);
}

.tier-badge i {
    font-size: 11px;
}

/* Trophy Icon */
.btn-icon.trophy {
    background: rgba(255, 194, 68, 0.15);
    color: var(--accent-primary);
}

.btn-icon.trophy:hover {
    background: rgba(255, 194, 68, 0.25);
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .menu-toggle {
        display: block;
    }

    .content-area {
        padding: 20px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .order-info-grid {
        grid-template-columns: 1fr;
    }

    .data-table {
        display: block;
        overflow-x: auto;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .login-box {
        padding: 30px 20px;
    }

    .table-controls {
        flex-direction: column;
    }

    .search-box {
        width: 100%;
    }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */
@media print {

    /* Hide everything by default */
    body * {
        visibility: hidden;
    }

    /* Hide specific layout elements explicitly to be safe */
    .dashboard-container,
    .sidebar,
    .main-header,
    .login-container {
        display: none !important;
    }

    /* Only show the order modal content */
    #order-modal,
    #order-modal * {
        visibility: visible;
    }

    /* Reset modal positioning for print */
    #order-modal {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        background: white;
        display: block !important;
        opacity: 1 !important;
        z-index: 9999;
        margin: 0;
        padding: 0;
        overflow: visible;
    }

    #order-modal .modal-content {
        margin: 0;
        padding: 20px;
        border: none;
        box-shadow: none;
        width: 100% !important;
        max-width: 100% !important;
        background: white;
        color: black;
    }

    /* Hide interactive elements in the modal */
    #order-modal .modal-footer,
    #order-modal .modal-close,
    #order-modal select {
        display: none !important;
    }

    /* Improve table readability */
    .data-table th,
    .data-table td {
        border: 1px solid #ddd !important;
        color: black !important;
    }

    /* Typography adjustments */
    h2,
    h4,
    label,
    span,
    p {
        color: black !important;
    }
}

/* Settings Page Improvements */
.settings-container {
    max-width: 600px;
    margin: 0 auto;
}

.settings-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 0.5rem;
}

.tab-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.tab-btn:hover {
    color: var(--text-primary);
    background-color: var(--bg-hover);
}

.tab-btn.active {
    color: var(--bg-primary);
    background-color: var(--accent-primary);
    font-weight: 600;
}

.tab-pane {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-pane.active {
    display: block;
}

.form-section-actions {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-light);
}

.btn-block {
    width: 100%;
    justify-content: center;
    padding: 1rem;
    font-size: 1rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mt-4 {
    margin-top: 2rem;
}

/* Settings Grid Layout */
.settings-container {
    max-width: 900px;
    /* Increased width for side-by-side */
    margin: 0 auto;
}

.settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.settings-panel {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 1.5rem;
}

.panel-title {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.panel-title i {
    color: var(--accent-primary);
}

.btn-lg {
    font-size: 1.1rem;
    font-weight: 600;
    padding: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   Settings Tabs
   ============================================ */

.settings-tabs {
    display: flex;
    gap: 10px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.settings-tab {
    padding: 12px 24px;
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid transparent;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-fast);
}

.settings-tab:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.settings-tab.active {
    color: var(--accent-primary);
    background: var(--bg-card);
    border-color: var(--border-color);
    border-bottom-color: var(--bg-card);
}

.settings-tab-content {
    animation: fadeIn 0.3s ease;
}

/* ============================================
   Permissions Grid & Checkboxes
   ============================================ */

.permissions-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.permission-group {
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 1px solid var(--border-light);
}

.permission-group-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.permission-checkboxes {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 8px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition-fast);
    font-size: 13px;
}

.checkbox-label:hover {
    background: var(--bg-hover);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent-primary);
    cursor: pointer;
}

.checkbox-label input[type="checkbox"]:checked+span {
    color: var(--accent-primary);
}

/* ============================================
   Status Success/Error badges
   ============================================ */

.status-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.status-error {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

/* ============================================
   Button icon disabled state
   ============================================ */

.btn-icon:disabled,
.btn-icon[disabled] {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

/* ============================================
   Badge styles
   ============================================ */

.badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

.badge-info {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-blue);
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

/* ============================================
   Btn danger for icon buttons
   ============================================ */

.btn-icon.btn-danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.btn-icon.btn-danger:hover {
    background: rgba(239, 68, 68, 0.25);
}

/* ============================================
   Form control improvements
   ============================================ */

.form-control {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    transition: var(--transition-fast);
}

.form-control:focus {
    border-color: var(--accent-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 194, 68, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 80px;
}