/* ==========================================================================
   RUMREN STORE & MASTER ADMIN - CORE DARK STYLESHEET (BACKEND DEDICATED)
   Terpisah 100% dari CSS frontend (style.css). Tidak akan saling tabrak.
   ========================================================================== */

:root {
    --bg-main: #0B0F17;
    --bg-surface: #111726;
    --bg-card: #151D2F;
    --bg-card-hover: #1C263D;
    --bg-glass: rgba(17, 23, 38, 0.94);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.16);
    --border-accent: rgba(16, 185, 129, 0.45);

    /* Accents */
    --primary: #10B981;
    --primary-hover: #059669;
    --primary-dim: rgba(16, 185, 129, 0.15);
    --primary-glow: rgba(16, 185, 129, 0.25);
    --primary-text: #FFFFFF;
    --primary-subtext: rgba(255, 255, 255, 0.95);

    --amber: #F59E0B;
    --amber-dim: rgba(245, 158, 11, 0.15);
    --danger: #EF4444;
    --danger-dim: rgba(239, 68, 68, 0.15);
    --blue: #3B82F6;
    --blue-dim: rgba(59, 130, 246, 0.15);

    /* Typography Colors */
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --text-sub: #64748B;
    --text-white: #FFFFFF;

    /* Border Radii */
    --r-xs: 4px;
    --r-sm: 6px;
    --r-md: 8px;
    --r-lg: 10px;

    --header-height: 60px;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.25);
    --shadow-card: 0 4px 12px rgba(0, 0, 0, 0.35);
    --shadow-pop: 0 8px 24px rgba(0, 0, 0, 0.5);
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    width: 100%;
    min-height: 100%;
    overflow-x: clip;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-main) !important;
    color: var(--text-main) !important;
    min-height: 100vh;
    min-height: 100dvh;
    font-size: 14px;
    line-height: 1.45;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}

/* Touch Action Fix */
button,
input,
select,
textarea,
a,
.btn {
    touch-action: manipulation;
}

/* Global Optical Alignment for Lucide Icons */
svg.lucide,
i[data-lucide] {
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
}

/* Base Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--primary);
    color: var(--primary-text, #FFFFFF);
    padding: 8px 16px;
    border-radius: var(--r-sm);
    font-weight: 700;
    font-size: 0.85rem;
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 2px 8px var(--primary-shadow, rgba(16, 185, 129, 0.25));
}

.btn-primary:hover {
    background: var(--primary-hover, #059669);
    color: var(--primary-text, #FFFFFF);
    box-shadow: 0 4px 12px var(--primary-shadow, rgba(16, 185, 129, 0.35));
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main, #F8FAFC);
    padding: 8px 16px;
    border-radius: var(--r-sm);
    font-weight: 700;
    font-size: 0.85rem;
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.12));
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    white-space: nowrap;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF;
    border-color: rgba(255, 255, 255, 0.22);
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: transparent;
    color: var(--text-main, #F8FAFC);
    padding: 6px 12px;
    border-radius: var(--r-xs, 4px);
    font-weight: 700;
    font-size: 0.8rem;
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.15));
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #FFFFFF;
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: rgba(239, 68, 68, 0.15);
    color: #F87171;
    padding: 8px 16px;
    border-radius: var(--r-sm);
    font-weight: 600;
    font-size: 0.85rem;
    border: 1px solid rgba(239, 68, 68, 0.3);
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.3);
    color: #FFFFFF;
}

/* Base Tables */
table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.84rem;
}

th {
    background: rgba(255, 255, 255, 0.03);
    padding: 10px 14px;
    color: var(--text-muted, #94A3B8);
    font-weight: 700;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    white-space: nowrap;
}

td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.06));
    color: var(--text-main, #F8FAFC);
    vertical-align: middle;
    white-space: nowrap;
    background: transparent;
}

tr:hover td {
    background: rgba(255, 255, 255, 0.025);
}

/* Base Form Inputs & Controls */
.form-control,
.form-input,
.form-select,
.form-textarea,
input[type='text'],
input[type='search'],
input[type='number'],
input[type='password'],
input[type='email'],
input[type='tel'],
input[type='url'],
select,
textarea {
    width: 100%;
    box-sizing: border-box;
    background: #161F30;
    color: #F8FAFC;
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.12));
    border-radius: var(--r-sm, 6px);
    padding: 9px 12px;
    font-family: inherit;
    font-size: 0.85rem;
    line-height: 1.4;
    min-height: 38px;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    color-scheme: dark;
}

select.form-control,
select {
    padding-right: 32px;
    cursor: pointer;
    min-height: 38px;
}

textarea.form-control,
textarea {
    min-height: 80px;
    line-height: 1.5;
    padding: 10px 12px;
}

.form-control:focus,
.form-input:focus,
.form-select:focus,
.form-textarea:focus,
input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-glow, rgba(16, 185, 129, 0.25));
}

@media (max-width: 768px) {

    .form-input,
    .form-select,
    .form-textarea,
    .form-control,
    input,
    select,
    textarea {
        font-size: 16px !important;
    }
}

/* Base Modals & Drawers Overlay */
.modal,
.modal-overlay,
.master-modal-overlay {
    position: fixed !important;
    inset: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    height: 100dvh !important;
    background: rgba(0, 0, 0, 0.8) !important;
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
    z-index: 999999 !important;
    display: none !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 14px;
    box-sizing: border-box;
}

.modal.active,
.modal-overlay.active,
.master-modal-overlay.active {
    display: flex !important;
}

.modal-box,
.modal-drawer {
    background: var(--bg-card, #151D2F);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.12));
    border-radius: var(--r-md, 8px);
    color: var(--text-main, #F8FAFC);
    box-shadow: var(--shadow-pop, 0 10px 30px rgba(0, 0, 0, 0.7));
    position: relative;
    max-width: 95vw;
    box-sizing: border-box;
}

/* ============================================
   ADMIN SPECIFIC STYLES (RESPONSIVE DESKTOP & MOBILE)
   ============================================ */
body.admin-page {
    font-size: 14px;
    height: 100vh;
    overflow: hidden;
    margin: 0;
    padding: 0;
    -webkit-text-size-adjust: 100%;
}

@media (max-width: 860px) {
    body.admin-page {
        height: auto;
        min-height: 100vh;
        overflow-x: clip;
        overflow-y: visible;
    }
}

.admin-layout {
    display: flex;
    height: 100vh;
    width: 100%;
    overflow: hidden;
}

/* Mobile Header & Drawer Navigation */
.admin-mobile-header {
    display: none;
}

.sidebar-overlay {
    display: none;
}

.btn-sidebar-close {
    display: none;
}

.admin-bottom-nav {
    display: none;
}

.sidebar {
    width: 240px;
    background: var(--bg-surface);
    border-right: 1px solid var(--border-color);
    padding: 0;
    display: flex;
    flex-direction: column;
    height: 100vh;
    max-height: 100vh;
    flex-shrink: 0;
    box-sizing: border-box;
    overflow: hidden;
    position: sticky;
    top: 0;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 860px) {
    .admin-layout {
        height: auto;
        min-height: 100vh;
        overflow: visible;
        flex-direction: column;
    }

    .admin-mobile-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        background: rgba(11, 17, 30, 0.94);
        backdrop-filter: blur(16px) saturate(180%);
        -webkit-backdrop-filter: blur(16px) saturate(180%);
        border-bottom: 1px solid var(--border-color);
        padding: 10px 14px;
        position: -webkit-sticky;
        position: sticky;
        top: 0;
        z-index: 990;
    }

    .btn-icon-mobile {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid var(--border-color);
        border-radius: 8px;
        color: var(--text-main);
        cursor: pointer;
        transition: background 0.15s;
    }

    .btn-icon-mobile:active {
        background: rgba(255, 255, 255, 0.15);
    }

    .sidebar-overlay {
        display: block;
        position: fixed;
        inset: 0;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.7);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 9998;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.25s ease, visibility 0.25s ease;
    }

    .sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .sidebar {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        bottom: 0 !important;
        width: 280px !important;
        max-width: 85vw !important;
        height: 100vh !important;
        max-height: 100vh !important;
        background: #0F172A !important;
        z-index: 9999 !important;
        transform: translateX(-100%) !important;
        box-shadow: 10px 0 35px rgba(0, 0, 0, 0.8) !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
        padding: 0 !important;
    }

    .sidebar .sidebar-brand {
        background: #0F172A !important;
    }

    .sidebar .sidebar-footer {
        background: #0F172A !important;
    }

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

    .btn-sidebar-close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        border-radius: 6px;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid var(--border-color);
        color: var(--text-muted);
        cursor: pointer;
    }

    .main-content {
        padding: 14px 12px 92px 12px !important;
    }

    .admin-bottom-nav {
        display: flex;
        position: fixed;
        bottom: max(12px, env(safe-area-inset-bottom, 12px));
        left: 14px;
        right: 14px;
        max-width: 460px;
        margin: 0 auto;
        height: 60px;
        background: rgba(15, 23, 42, 0.82);
        backdrop-filter: blur(20px) saturate(190%);
        -webkit-backdrop-filter: blur(20px) saturate(190%);
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 20px;
        box-shadow: 0 10px 32px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.05);
        z-index: 995;
        justify-content: space-around;
        align-items: center;
        padding: 4px 6px;
        box-sizing: border-box;
        transition: height 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            max-width 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            bottom 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            border-radius 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            padding 0.25s cubic-bezier(0.16, 1, 0.3, 1);
        will-change: height, max-width, bottom;
    }

    .admin-bottom-nav.compact {
        height: 46px;
        bottom: 10px;
        max-width: 310px;
        border-radius: 28px;
        padding: 3px 8px;
        box-shadow: 0 8px 26px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.08);
    }

    .bottom-nav-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        color: #94A3B8;
        text-decoration: none;
        gap: 3px;
        flex: 1;
        height: 100%;
        border: none;
        background: transparent;
        border-radius: 14px;
        margin: 0 2px;
        cursor: pointer;
        transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
        -webkit-tap-highlight-color: transparent;
    }

    .bottom-nav-item span {
        font-size: 0.68rem;
        font-weight: 600;
        white-space: nowrap;
        transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1),
            max-height 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            margin-top 0.2s cubic-bezier(0.16, 1, 0.3, 1);
        max-height: 18px;
        overflow: hidden;
        opacity: 1;
        display: block;
    }

    .admin-bottom-nav.compact .bottom-nav-item span {
        opacity: 0;
        max-height: 0;
        margin-top: 0;
        pointer-events: none;
    }

    .admin-bottom-nav.compact .bottom-nav-item {
        padding: 4px;
        border-radius: 14px;
        gap: 0;
    }

    .bottom-nav-item:active,
    .bottom-nav-item.active {
        color: var(--primary);
        background: rgba(249, 115, 22, 0.12);
    }

    .bottom-nav-item svg,
    .bottom-nav-item i {
        width: 19px;
        height: 19px;
        transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1),
            width 0.25s cubic-bezier(0.16, 1, 0.3, 1),
            height 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .admin-bottom-nav.compact .bottom-nav-item svg,
    .admin-bottom-nav.compact .bottom-nav-item i {
        width: 20px;
        height: 20px;
    }

    .bottom-nav-item.active svg,
    .bottom-nav-item.active i {
        transform: scale(1.08);
    }

    .bottom-nav-icon-wrap {
        position: relative;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .bottom-nav-icon-wrap .nav-badge {
        position: absolute;
        top: -4px;
        right: -8px;
        background: var(--danger);
        color: #FFFFFF;
        font-size: 0.6rem;
        font-weight: 800;
        padding: 1px 5px;
        border-radius: 9999px;
        line-height: 1.1;
        box-shadow: 0 2px 6px rgba(225, 29, 72, 0.5);
    }

    .dashboard-main-grid {
        grid-template-columns: 1fr !important;
    }

    .dashboard-masonry-container {
        column-count: 1 !important;
    }
}

.dashboard-main-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 12px;
}

.dashboard-masonry-container {
    column-count: 2;
    column-gap: 12px;
    width: 100%;
}

.dashboard-masonry-card {
    break-inside: avoid-column;
    page-break-inside: avoid;
    -webkit-column-break-inside: avoid;
    display: inline-block;
    width: 100%;
    margin-bottom: 12px;
    background: var(--card-bg, #111827);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    padding: 14px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    vertical-align: top;
}

/* Custom Date Range Form - Mobile & iOS Optimized */
.dash-date-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) auto;
    gap: 10px;
    align-items: flex-end;
    width: 100%;
}

@media (max-width: 640px) {
    .dash-date-form-grid {
        grid-template-columns: 1fr;
    }
}

.dash-date-input-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.dash-date-label {
    font-size: 0.72rem;
    color: var(--text-muted, #94a3b8);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}

.dash-date-field {
    width: 100%;
    min-height: 40px;
    padding: 8px 12px;
    font-size: 0.84rem;
    font-weight: 600;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    box-sizing: border-box;
    color-scheme: dark;
    -webkit-appearance: none;
    appearance: none;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.dash-date-field:focus {
    outline: none;
    border-color: var(--primary, #10b981);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

.dash-date-submit-btn {
    min-height: 40px;
    background: var(--primary, #10b981);
    color: #022c22;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
    transition: opacity 0.15s, transform 0.1s;
    white-space: nowrap;
}

.dash-date-submit-btn:hover {
    opacity: 0.92;
}

.dash-date-submit-btn:active {
    transform: scale(0.98);
}

.sidebar-brand {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 16px 14px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-surface);
    flex-shrink: 0;
    margin: 0;
}

.brand-badge {
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: var(--primary-text, #FFFFFF);
    border-radius: var(--r-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1 1 auto;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 12px 10px;
    min-height: 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.nav-menu::-webkit-scrollbar {
    width: 5px;
}

.nav-menu::-webkit-scrollbar-track {
    background: transparent;
}

.nav-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.nav-menu::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.sidebar-footer {
    position: sticky;
    bottom: 0;
    z-index: 20;
    padding: 12px 12px 14px 12px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-surface);
    margin-top: auto;
    flex-shrink: 0;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: var(--r-sm);
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.84rem;
    font-weight: 600;
    transition: background 0.15s, color 0.15s;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-main);
}

.nav-link.active {
    background: var(--primary);
    color: var(--primary-text, #FFFFFF);
    font-weight: 700;
}

.main-content {
    flex-grow: 1;
    height: 100vh;
    overflow-y: auto;
    padding: 20px;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

@media (max-width: 860px) {
    .main-content {
        height: auto !important;
        overflow: visible !important;
        padding: 14px 12px 85px 12px !important;
    }
}

.top-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    gap: 12px;
}

.page-title {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.page-title-icon {
    width: 34px;
    height: 34px;
    border-radius: var(--r-sm);
    background: var(--primary-dim);
    border: 1px solid var(--border-accent);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.page-title-icon i,
.page-title-icon svg {
    width: 17px;
    height: 17px;
    color: var(--primary);
    stroke: var(--primary);
}

.page-title-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.page-title-text h2,
.page-title h2 {
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.25;
    margin: 0;
    color: var(--text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.page-title-text p,
.page-title p {
    color: var(--text-muted);
    font-size: 0.73rem;
    margin: 2px 0 0 0;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

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

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--r-md);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.stat-val {
    font-size: 1.3rem;
    font-weight: 800;
    margin-top: 2px;
    line-height: 1.2;
}

.stat-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--r-sm);
    background: var(--primary-dim);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Product & Business Vertical Tabs (1 ROW HORIZONTAL SCROLL) */
.product-vertical-tabs,
.addons-vertical-tabs,
.settings-master-tabs {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    gap: 10px !important;
    margin-bottom: 16px !important;
    padding-bottom: 4px !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.product-vertical-tabs::-webkit-scrollbar,
.addons-vertical-tabs::-webkit-scrollbar,
.settings-master-tabs::-webkit-scrollbar {
    display: none !important;
}

.product-tab-card {
    flex: 0 0 auto !important;
    min-width: max-content !important;
    display: flex;
    align-items: center;
    text-align: left !important;
    gap: 12px;
    padding: 10px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--r-md);
    text-decoration: none;
    transition: all 0.2s ease;
    box-sizing: border-box;
    cursor: pointer;
    white-space: nowrap !important;
}

.product-tab-card:hover {
    border-color: var(--primary) !important;
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.04) !important;
}

.product-tab-card.active {
    background: var(--primary-dim) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 4px 14px var(--primary-glow) !important;
}

.product-tab-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--r-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.product-tab-icon i,
.product-tab-icon svg {
    width: 18px !important;
    height: 18px !important;
}

.product-tab-info {
    flex: 0 0 auto !important;
    min-width: max-content !important;
    text-align: left !important;
}

.product-tab-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    text-align: left !important;
}

.product-tab-name {
    font-size: 0.86rem;
    color: var(--text-main);
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: clip !important;
    text-align: left !important;
    font-weight: 700;
}

.product-tab-badge {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: var(--r-xs);
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-muted);
    flex-shrink: 0;
}

.product-tab-badge.active,
.product-tab-card.active .product-tab-badge {
    background: var(--primary);
    color: var(--primary-text);
}

.product-tab-desc {
    font-size: 0.72rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 2px;
    text-align: left !important;
}

/* Table Filter Bar (Desktop) */
.table-filter-bar {
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border-color);
    padding: 8px 14px;
}

.filter-form-grid {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.filter-field-search {
    position: relative;
    flex: 1 1 180px;
    max-width: 260px;
    min-width: 140px;
}

.filter-field-search i,
.filter-field-search svg {
    position: absolute;
    left: 9px;
    top: 50%;
    transform: translateY(-50%);
    width: 13px !important;
    height: 13px !important;
    color: var(--text-muted);
    pointer-events: none;
}

.filter-field-search input {
    padding: 5px 8px 5px 28px !important;
    font-size: 0.78rem !important;
    height: 32px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    border-radius: 6px !important;
}

.filter-field {
    flex: 0 1 auto;
}

.filter-field select {
    font-size: 0.78rem !important;
    height: 32px !important;
    padding: 4px 8px !important;
    border-radius: 6px !important;
    width: auto;
    min-width: 130px;
}

.filter-actions-group {
    display: flex;
    gap: 5px;
    align-items: center;
}

.filter-actions-group button,
.filter-actions-group a {
    padding: 0 12px !important;
    height: 32px !important;
    font-size: 0.76rem !important;
    border-radius: 6px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    white-space: nowrap !important;
}

/* Tables in Admin */
.card-table {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--r-md);
    overflow: hidden;
    margin-bottom: 24px;
}

.table-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: nowrap;
    box-sizing: border-box;
    width: 100%;
}

.table-header-left {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    flex: 0 1 auto;
    min-width: 0;
    overflow: hidden;
}

.table-header-left h3,
.table-header-left h4 {
    font-size: 1rem;
    font-weight: 800;
    margin: 0;
    color: var(--text-main);
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.table-header-left p {
    font-size: 0.73rem;
    color: var(--text-muted);
    margin: 2px 0 0 0;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.table-header-right {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex: 0 0 auto;
    flex-shrink: 0;
    margin-left: auto;
    flex-wrap: nowrap;
}

.table-header-actions,
.table-header-btns {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: nowrap;
    flex: 0 0 auto;
    flex-shrink: 0;
}

.table-header-actions .btn-primary,
.table-header-actions .btn-secondary,
.table-header-actions button,
.table-header-actions a,
.table-header-btns .btn-primary,
.table-header-btns .btn-secondary,
.table-header-btns button,
.table-header-btns a,
.table-header-right .btn-primary,
.table-header-right .btn-secondary,
.table-header-right button,
.table-header-right a {
    width: auto !important;
    max-width: fit-content;
    height: 34px;
    padding: 0 14px;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
    flex: 0 0 auto;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-sizing: border-box;
}

.table-scroll-hint {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.68rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 0 7px;
    height: 32px;
    border-radius: var(--r-xs);
    white-space: nowrap;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .table-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 12px 14px;
    }

    .table-header-left {
        width: 100%;
        display: flex;
        flex-direction: row;
        align-items: flex-start;
        gap: 10px;
    }

    .table-header-left h3,
    .table-header-left h4 {
        font-size: 0.95rem;
        white-space: normal;
    }

    .table-header-left p {
        font-size: 0.72rem;
        line-height: 1.35;
        white-space: normal;
    }

    .table-header-right {
        width: 100%;
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
        margin-left: 0;
    }

    .table-header-actions,
    .table-header-btns {
        width: 100%;
        display: flex;
        align-items: center;
        gap: 6px;
        flex-wrap: wrap;
    }

    .table-header-actions .btn-primary,
    .table-header-actions .btn-secondary,
    .table-header-actions button,
    .table-header-actions a,
    .table-header-btns .btn-primary,
    .table-header-btns .btn-secondary,
    .table-header-btns button,
    .table-header-btns a,
    .table-header-right .btn-primary,
    .table-header-right .btn-secondary,
    .table-header-right button,
    .table-header-right a {
        flex: 0 0 auto;
        min-width: auto;
        min-height: 28px;
        height: 28px;
        padding: 4px 9px;
        font-size: 0.72rem;
        font-weight: 700;
        border-radius: var(--r-xs);
        justify-content: center;
        text-align: center;
    }

    .table-scroll-hint {
        display: none !important;
    }

    .product-vertical-tabs,
    .addons-vertical-tabs,
    .settings-master-tabs {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        gap: 8px !important;
        margin-bottom: 12px !important;
        padding-bottom: 4px !important;
        scrollbar-width: none !important;
        -ms-overflow-style: none !important;
    }

    .product-vertical-tabs::-webkit-scrollbar,
    .addons-vertical-tabs::-webkit-scrollbar,
    .settings-master-tabs::-webkit-scrollbar {
        display: none !important;
    }

    .product-tab-card {
        flex: 0 0 auto !important;
        width: auto !important;
        min-width: auto !important;
        padding: 7px 12px !important;
        gap: 8px !important;
        border-radius: 8px !important;
    }

    .product-tab-icon {
        width: 28px !important;
        height: 28px !important;
        border-radius: 6px !important;
    }

    .product-tab-icon i,
    .product-tab-icon svg {
        width: 14px !important;
        height: 14px !important;
    }

    .product-tab-info {
        flex: 0 0 auto !important;
    }

    .product-tab-title-row {
        gap: 6px !important;
    }

    .product-tab-name {
        font-size: 0.8rem !important;
        font-weight: 700 !important;
    }

    .product-tab-badge {
        font-size: 0.68rem !important;
        padding: 1px 6px !important;
        border-radius: 4px !important;
    }

    .product-tab-desc {
        display: none !important;
    }

    /* Compact Table Filter Form on Mobile */
    .table-filter-bar {
        padding: 8px 10px !important;
    }

    .filter-form-grid {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 6px !important;
        width: 100% !important;
    }

    .filter-field-search {
        grid-column: 1 / -1 !important;
        max-width: 100% !important;
        width: 100% !important;
    }

    .filter-field {
        width: 100% !important;
        min-width: 0 !important;
    }

    .filter-field select {
        width: 100% !important;
        min-width: 0 !important;
        height: 34px !important;
        font-size: 0.78rem !important;
    }

    .filter-actions-group {
        display: flex !important;
        gap: 6px !important;
        width: 100% !important;
    }

    .filter-actions-group button,
    .filter-actions-group a {
        flex: 1 !important;
        height: 34px !important;
        justify-content: center !important;
    }

    /* Settings Mobile Form & Sub-nav Rules */
    .settings-compact-nav {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        gap: 6px !important;
        padding: 4px !important;
        margin-bottom: 12px !important;
        scrollbar-width: none !important;
    }

    .settings-compact-nav::-webkit-scrollbar {
        display: none !important;
    }

    .settings-compact-nav .settings-tab-card {
        flex: 0 0 auto !important;
        width: auto !important;
        white-space: nowrap !important;
        padding: 6px 12px !important;
        font-size: 0.76rem !important;
    }

    .dashboard-main-grid {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    .dashboard-quick-actions {
        padding: 8px 10px !important;
        gap: 6px !important;
    }

    .dashboard-quick-actions .action-pill {
        font-size: 0.75rem !important;
        padding: 5px 10px !important;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    cursor: grab;
    position: relative;
    scrollbar-width: thin;
    scrollbar-color: rgba(16, 185, 129, 0.4) rgba(255, 255, 255, 0.05);
}

.table-responsive.is-dragging {
    cursor: grabbing !important;
    user-select: none;
}

.table-responsive::-webkit-scrollbar {
    height: 9px;
}

.table-responsive::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.04);
    border-radius: 6px;
}

.table-responsive::-webkit-scrollbar-thumb {
    background: rgba(16, 185, 129, 0.4);
    border-radius: 6px;
    border: 2px solid transparent;
    background-clip: content-box;
}

.table-responsive::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

.table-scroll-hint {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--primary);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
    padding: 2px 6px;
    border-radius: 6px;
    white-space: nowrap;
    user-select: none;
    flex-shrink: 0;
}

.table-scroll-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    padding: 0;
    margin: 0;
    background: rgba(16, 185, 129, 0.2);
    color: var(--primary);
    border: 1px solid rgba(16, 185, 129, 0.35);
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
    font-weight: bold;
    line-height: 1;
    transition: all 0.15s ease;
}

.table-scroll-btn:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.84rem;
}

th {
    background: var(--table-th-bg, rgba(255, 255, 255, 0.03));
    padding: 10px 14px;
    color: var(--text-muted, #94A3B8);
    font-weight: 700;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    white-space: nowrap;
}

td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.06));
    color: var(--text-main, #F8FAFC);
    vertical-align: middle;
    white-space: nowrap;
}

tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

body.admin-page th {
    background: rgba(255, 255, 255, 0.03) !important;
    color: var(--text-muted, #94A3B8) !important;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.08)) !important;
}

body.admin-page td {
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.06)) !important;
    color: var(--text-main, #F8FAFC) !important;
    background: transparent !important;
}

body.admin-page tr:hover td {
    background: rgba(255, 255, 255, 0.025) !important;
}

/* ============================================
   ADMIN TOP BAR & ACTION CONTROLS
   ============================================ */
.top-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap;
}

@media (max-width: 640px) {
    .top-actions {
        width: 100%;
        justify-content: space-between;
        flex-wrap: wrap;
    }
}

.store-selector-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    padding: 7px 14px;
    border-radius: var(--r-sm);
    border: 1px solid var(--border-color);
    white-space: nowrap;
}

.store-selector-badge select {
    background: transparent;
    border: none;
    color: var(--text-main);
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    outline: none;
    font-family: inherit;
    max-width: 210px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

.store-selector-badge select option {
    background: #FFFFFF;
    color: #0F172A;
    max-width: 100%;
}

/* Primary, Secondary, Danger General Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--primary);
    color: var(--primary-text, #FFFFFF);
    padding: 8px 16px;
    border-radius: var(--r-sm);
    font-weight: 700;
    font-size: 0.85rem;
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 2px 8px var(--primary-shadow, rgba(16, 185, 129, 0.25));
}

.btn-primary:hover {
    background: var(--primary-hover, #059669);
    color: var(--primary-text, #FFFFFF);
    box-shadow: 0 4px 12px var(--primary-shadow, rgba(16, 185, 129, 0.35));
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: #F1F5F9;
    color: #334155;
    padding: 8px 16px;
    border-radius: var(--r-sm);
    font-weight: 700;
    font-size: 0.85rem;
    border: 1px solid #CBD5E1;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    white-space: nowrap;
}

.btn-secondary:hover {
    background: #E2E8F0;
    color: #0F172A;
    border-color: #94A3B8;
}

body.admin-page .btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main, #F8FAFC);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.12));
}

body.admin-page .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF;
    border-color: rgba(255, 255, 255, 0.22);
}

body.admin-page .btn-outline {
    background: transparent;
    color: var(--text-main, #F8FAFC);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.15));
}

body.admin-page .btn-outline:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #FFFFFF;
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: rgba(239, 68, 68, 0.15);
    color: #F87171;
    padding: 8px 16px;
    border-radius: var(--r-sm);
    font-weight: 600;
    font-size: 0.85rem;
    border: 1px solid rgba(239, 68, 68, 0.3);
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.3);
    color: #FFFFFF;
}

/* ============================================
   TABLE INLINE ACTION BUTTONS (AKSI)
   ============================================ */
.td-actions {
    white-space: nowrap;
    text-align: right;
    vertical-align: middle;
}

.action-btn-group {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    justify-content: flex-end;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    min-width: 32px;
    padding: 0;
    border-radius: var(--r-xs);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    font-family: inherit;
    text-decoration: none;
    line-height: 1;
}

.btn-action-text {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 32px;
    padding: 0 12px;
    border-radius: var(--r-xs);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    font-family: inherit;
    text-decoration: none;
    white-space: nowrap;
}

.btn-action:hover,
.btn-action-text:hover {
    transform: translateY(-1px);
}

.btn-action-primary,
.btn-action-view {
    background: var(--primary-dim, rgba(16, 185, 129, 0.12));
    color: var(--primary, #34D399);
    border-color: var(--primary-border, rgba(16, 185, 129, 0.3));
}

.btn-action-primary:hover,
.btn-action-view:hover {
    background: var(--primary-glow, rgba(16, 185, 129, 0.25));
    color: #A7F3D0;
    border-color: var(--primary-border, rgba(16, 185, 129, 0.6));
}

.btn-action-edit,
.btn-action-warning {
    background: rgba(245, 158, 11, 0.12);
    color: #FBBF24;
    border-color: rgba(245, 158, 11, 0.3);
}

.btn-action-edit:hover,
.btn-action-warning:hover {
    background: rgba(245, 158, 11, 0.25);
    color: #FDE68A;
    border-color: rgba(245, 158, 11, 0.6);
}

.btn-action-delete,
.btn-action-danger {
    background: rgba(239, 68, 68, 0.12);
    color: #F87171;
    border-color: rgba(239, 68, 68, 0.3);
}

.btn-action-delete:hover,
.btn-action-danger:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #FCA5A5;
    border-color: rgba(239, 68, 68, 0.6);
}

.btn-action-add {
    background: rgba(59, 130, 246, 0.12);
    color: #60A5FA;
    border-color: rgba(59, 130, 246, 0.3);
}

.btn-action-add:hover {
    background: rgba(59, 130, 246, 0.25);
    color: #93C5FD;
    border-color: rgba(59, 130, 246, 0.6);
}

.btn-action-delete:hover,
.btn-action-danger:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #FCA5A5;
    border-color: rgba(239, 68, 68, 0.5);
}

.status-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: var(--r-xs);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    white-space: nowrap;
}

.status-pending {
    background: var(--amber-dim);
    color: #FBBF24;
}

.status-confirmed {
    background: var(--blue-dim);
    color: #60A5FA;
}

.status-processing {
    background: rgba(139, 92, 246, 0.15);
    color: #C4B5FD;
}

.status-ready {
    background: var(--primary-dim);
    color: var(--primary, #34D399);
}

.status-completed {
    background: var(--primary-glow, rgba(16, 185, 129, 0.25));
    color: var(--primary, #10B981);
}

.status-cancelled {
    background: var(--danger-dim);
    color: #F87171;
}

/* ============================================
   TABLE PAGINATION COMPONENT
   ============================================ */
.table-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    border-top: 1px solid var(--border-color);
    background: rgba(0, 0, 0, 0.15);
    flex-wrap: wrap;
    gap: 10px;
    font-size: 0.8rem;
}

.pagination-info {
    color: var(--text-muted);
    font-size: 0.78rem;
}

.pagination-info strong {
    color: var(--text-main);
}

.pagination-controls {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-page {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 12px;
    border-radius: var(--r-sm);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 700;
    border: 1px solid var(--border-color);
    transition: all 0.15s ease;
    cursor: pointer;
}

.btn-page:hover:not(.disabled) {
    background: var(--primary);
    color: var(--primary-text, #FFFFFF);
    border-color: var(--primary);
}

.btn-page.disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.05);
}

.page-number-current {
    padding: 5px 10px;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--primary);
    background: var(--primary-dim);
    border: 1px solid var(--border-accent);
    border-radius: var(--r-sm);
}

/* ============================================
   SETTINGS TAB NAVIGATION
   ============================================ */
.settings-tabs-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.settings-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 0;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    flex: 1;
    width: 100%;
    padding: 2px 0;
}

.settings-tabs::-webkit-scrollbar {
    display: none;
}

.btn-settings-tab-scroll {
    position: sticky;
    z-index: 2;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--primary);
    width: 32px;
    height: 32px;
    border-radius: var(--r-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.15s ease;
}

.btn-settings-tab-scroll:hover {
    background: var(--primary-dim);
    border-color: var(--border-accent);
}

.btn-settings-tab-scroll.left-arrow {
    margin-right: 6px;
}

.btn-settings-tab-scroll.right-arrow {
    margin-left: 6px;
}

.settings-tab-btn {
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    padding: 10px 16px;
    font-size: 0.88rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    transition: all 0.15s ease;
    border-radius: var(--r-sm) var(--r-sm) 0 0;
}

.settings-tab-btn:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.03);
}

.settings-tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: rgba(16, 185, 129, 0.08);
}

/* Compact Modern Settings Grid Tabs */
.settings-grid-tabs {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 8px;
    margin-bottom: 18px;
}

.settings-tab-card {
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--r-xs);
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    text-align: left;
    transition: all 0.15s ease;
    outline: none;
    font-family: inherit;
    width: 100%;
}

.settings-tab-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.2);
}

.settings-tab-card.active {
    background: rgba(16, 185, 129, 0.12);
    border-color: var(--primary);
    box-shadow: 0 0 0 1px var(--primary);
}

.settings-tab-card.active .tab-card-title {
    color: var(--primary);
    font-weight: 800;
}

.settings-tab-card.active .tab-card-indicator {
    opacity: 1;
    transform: scale(1);
}

.tab-card-title {
    flex: 1;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}

.tab-card-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 6px var(--primary);
    flex-shrink: 0;
    opacity: 0;
    transform: scale(0.4);
    transition: all 0.15s ease;
    margin-left: auto;
}

.settings-tab-card.tab-danger {
    border-color: rgba(239, 68, 68, 0.25);
}

.settings-tab-card.tab-danger:hover {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.4);
}

.settings-tab-card.tab-danger.active {
    background: rgba(239, 68, 68, 0.14);
    border-color: #ef4444;
    box-shadow: 0 0 0 1px #ef4444;
}

.settings-tab-card.tab-danger.active .tab-card-indicator {
    background: #ef4444;
    box-shadow: 0 0 6px #ef4444;
}

@media (max-width: 768px) {
    .settings-grid-tabs {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }

    .settings-tab-card {
        padding: 7px 10px;
    }

    .tab-card-title {
        font-size: 0.74rem;
    }
}

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

.settings-tab-pane {
    display: none;
    animation: fadeInTab 0.2s ease-in-out;
}

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

@keyframes fadeInTab {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

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

/* ============================================
   RESPONSIVE ADMIN GRID & MOBILE HELPERS
   ============================================ */
.admin-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.admin-grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

.admin-grid-recipes {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
    width: 100%;
    max-width: 100%;
    min-width: 0;
}

.admin-grid-recipes>* {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.admin-grid-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
}

.admin-grid-metrics>* {
    min-width: 0;
    overflow: hidden;
    box-sizing: border-box;
}

@media (max-width: 1200px) {
    .admin-grid-recipes {
        grid-template-columns: 250px minmax(0, 1fr);
        gap: 12px;
    }

    .admin-grid-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }
}

@media (max-width: 960px) {

    .admin-grid-2,
    .admin-grid-3,
    .admin-grid-recipes {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .admin-grid-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }

    .stat-card {
        padding: 10px 12px !important;
    }

    .stat-val {
        font-size: 1.1rem !important;
    }

    .top-bar {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 12px !important;
    }

    .top-actions {
        width: 100% !important;
        flex-direction: column !important;
        gap: 8px !important;
    }

    .store-selector-badge {
        width: 100% !important;
        box-sizing: border-box !important;
        justify-content: space-between !important;
    }

    .store-selector-badge select {
        width: 100% !important;
        max-width: 100% !important;
        flex: 1 !important;
        text-overflow: ellipsis !important;
        overflow: hidden !important;
        white-space: nowrap !important;
    }

    .top-actions .btn-primary,
    .top-actions .btn-secondary {
        width: 100% !important;
        justify-content: center !important;
        padding: 10px 16px !important;
    }

    .action-btn-group .btn-action {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        min-height: 36px !important;
    }

    .modal,
    .modal-overlay {
        align-items: flex-end !important;
        padding: 0 !important;
    }

    .modal-box,
    .modal-drawer {
        border-radius: 16px 16px 0 0 !important;
        height: 90vh !important;
        height: 90dvh !important;
        min-height: 90vh !important;
        min-height: 90dvh !important;
        max-height: 90vh !important;
        max-height: 90dvh !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .modal-content,
    .modal-body {
        padding: 14px 16px !important;
        flex: 1 1 auto !important;
        height: 100% !important;
        min-height: 0 !important;
        overflow-y: auto !important;
    }

    .modal-content input,
    .modal-content select,
    .modal-content textarea,
    .form-control {
        font-size: 16px !important;
    }
}

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

    .stat-card {
        padding: 8px 10px !important;
    }

    .stat-icon {
        width: 30px !important;
        height: 30px !important;
    }

    .stat-val {
        font-size: 0.95rem !important;
    }
}


/* ============================================
   ADMIN COMPACT LOGIN SCREEN (CENTERED MODAL STYLE)
   ============================================ */
.login-wrap {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: radial-gradient(circle at 50% 30%, rgba(16, 185, 129, 0.08) 0%, #060A12 70%, #03070E 100%);
    padding: 16px;
    box-sizing: border-box;
    position: relative;
    z-index: 1;
}

.login-modal-box {
    max-width: 360px !important;
    width: 100% !important;
    background: #111726 !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 12px !important;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(16, 185, 129, 0.15) !important;
    overflow: hidden !important;
    margin: auto !important;
    transform: none !important;
    position: relative !important;
    z-index: 10 !important;
    display: flex !important;
    flex-direction: column !important;
}

/* ============================================
   CUSTOM TOAST ALERT NOTIFICATIONS (3S AUTO-CLOSE)
   ============================================ */
.custom-toast-container {
    position: fixed !important;
    top: 16px !important;
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    z-index: 9999999 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 8px !important;
    width: calc(100% - 24px) !important;
    max-width: 440px !important;
    pointer-events: none !important;
    box-sizing: border-box !important;
}

@media (max-width: 640px) {
    .custom-toast-container {
        top: 12px !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        width: calc(100% - 20px) !important;
        max-width: calc(100% - 20px) !important;
    }
}

.custom-toast {
    pointer-events: auto;
    width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 auto !important;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--primary);
    border-radius: var(--r-sm);
    padding: 12px 14px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-main);
    font-size: 0.86rem;
    font-weight: 500;
    line-height: 1.35;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    animation: toastSlideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transition: opacity 0.2s, transform 0.2s;
}

.custom-toast.toast-danger {
    border-left-color: var(--danger);
}

.custom-toast.toast-warning {
    border-left-color: var(--amber);
}

.custom-toast.toast-success {
    border-left-color: var(--primary);
}

.custom-toast-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: var(--r-xs);
    background: rgba(255, 255, 255, 0.05);
}

.custom-toast.toast-danger .custom-toast-icon {
    background: var(--danger-dim);
    color: var(--danger);
}

.custom-toast.toast-success .custom-toast-icon {
    background: var(--primary-dim);
    color: var(--primary);
}

.custom-toast.toast-warning .custom-toast-icon {
    background: var(--amber-dim);
    color: var(--amber);
}

.custom-toast-msg {
    flex: 1;
    min-width: 0;
    word-break: break-word;
}

.custom-toast-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    line-height: 1;
    padding: 2px 6px;
    cursor: pointer;
    border-radius: var(--r-xs);
    transition: color 0.15s, background 0.15s;
}

.custom-toast-close:hover {
    color: var(--text-white);
    background: rgba(255, 255, 255, 0.1);
}

.custom-toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    background: var(--primary);
    animation: toastProgress 3s linear forwards;
}

.custom-toast.toast-danger .custom-toast-progress {
    background: var(--danger);
}

.custom-toast.toast-warning .custom-toast-progress {
    background: var(--amber);
}

.custom-toast.toast-hiding {
    opacity: 0;
    transform: translateY(-12px) scale(0.96);
}

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

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

@keyframes toastProgress {
    from {
        width: 100%;
    }

    to {
        width: 0%;
    }
}

/* Custom In-App Confirm Dialogs */
.custom-confirm-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: rgba(5, 8, 16, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: fadeIn 0.2s ease forwards;
}

.custom-confirm-modal-overlay.active {
    display: flex !important;
}

.custom-confirm-box {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: var(--r-md, 16px);
    max-width: 440px;
    width: 100%;
    padding: 24px;
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.04);
    text-align: center;
    animation: zoomIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.92);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ============================================
   ADMIN GLOBAL SPOTLIGHT SEARCH (MONIFI STYLE)
   ============================================ */
.global-search-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 15, 29, 0.75);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: 80px 20px 40px;
    animation: fadeInModal 0.15s ease-out;
}

.global-search-backdrop.active {
    display: flex;
}

.global-search-dialog {
    width: 100%;
    max-width: 640px;
    background: #111827;
    border: 1px solid #374151;
    border-radius: var(--r-md);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.6);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 75vh;
}

.global-search-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid #1F2937;
    background: #1F2937;
}

.global-search-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #F9FAFB;
    font-size: 1.05rem;
    font-family: inherit;
}

.global-search-input::placeholder {
    color: #9CA3AF;
}

.global-search-body {
    padding: 12px;
    overflow-y: auto;
    flex: 1;
}

.global-search-group-title {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #9CA3AF;
    letter-spacing: 0.5px;
    padding: 8px 12px 4px;
}

.global-search-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: var(--r-sm);
    color: #E5E7EB;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid transparent;
}

.global-search-item:hover,
.global-search-item.selected {
    background: var(--primary-dim, rgba(16, 185, 129, 0.1));
    color: var(--primary, #10B981);
    border-color: var(--primary-border, rgba(16, 185, 129, 0.3));
}

.global-search-item-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: var(--primary);
}

.global-search-item-info {
    flex: 1;
    min-width: 0;
}

.global-search-item-title {
    font-size: 0.88rem;
    font-weight: 600;
    color: #F9FAFB;
    display: flex;
    align-items: center;
    gap: 8px;
}

.global-search-item-sub {
    font-size: 0.75rem;
    color: #9CA3AF;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.global-search-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 18px;
    background: #0B0F19;
    border-top: 1px solid #1F2937;
    font-size: 0.72rem;
    color: #6B7280;
}

/* ========================================
   UNIFIED HORIZONTAL SETTINGS ROW SYSTEM
   ======================================== */
.setting-section {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: var(--r-md);
    margin-bottom: 20px;
    overflow: hidden;
}

.setting-section-header {
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 8px;
}

.setting-section-header h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.setting-row {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 24px;
    padding: 14px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    align-items: center;
}

.setting-row:last-child {
    border-bottom: none;
}

.setting-label-col {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.setting-label-col .setting-title {
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 6px;
}

.setting-label-col .setting-desc {
    font-size: 0.72rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.setting-input-col {
    width: 100%;
}

.setting-input-col .form-control {
    width: 100%;
    box-sizing: border-box;
}

.setting-checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.84rem;
    color: var(--text-main);
}

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

@media (max-width: 820px) {
    .setting-row {
        grid-template-columns: 1fr;
        gap: 8px;
        align-items: flex-start;
        padding: 12px 14px;
    }
}


/* ========================================
   DASHBOARD RESPONSIVE ADAPTATIONS
   ======================================== */
.btn-branch-picker-mobile {
    display: none;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: var(--primary, #10b981);
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.btn-branch-picker-mobile:active {
    background: rgba(16, 185, 129, 0.25);
    transform: scale(0.95);
}

.branch-active-dot {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary, #10b981);
    box-shadow: 0 0 6px var(--primary, #10b981);
}

.branch-picker-item {
    transition: all 0.15s ease;
}

.branch-picker-item:hover,
.branch-picker-item:active {
    background: rgba(16, 185, 129, 0.15) !important;
    border-color: rgba(16, 185, 129, 0.4) !important;
}

/* KPI Card Flex Alignment (No Collision) */
.stat-card-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    gap: 6px !important;
    width: 100% !important;
}

.stat-card-body {
    min-width: 0 !important;
    flex: 1 1 auto !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

.stat-card-title {
    display: block !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.stat-card .stat-icon {
    flex-shrink: 0 !important;
    margin-left: auto !important;
    align-self: flex-start !important;
}

/* MODERN ORDER ITEM CARDS */
.orders-cards-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)) !important;
    gap: 10px !important;
}

.order-item-card {
    background: var(--card-bg, #111827) !important;
    border: 1px solid rgba(255, 255, 255, 0.06) !important;
    border-radius: 10px !important;
    padding: 12px 14px !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 9px !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25) !important;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease !important;
}

.order-item-card:hover {
    border-color: rgba(255, 255, 255, 0.14) !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4) !important;
    transform: translateY(-1px) !important;
}

/* ORDER CARD ACTION BUTTONS */
.order-card-actions {
    display: flex !important;
    align-items: center !important;
    gap: 5px !important;
    flex-shrink: 0 !important;
    margin-left: auto !important;
}

.order-card-btn-detail {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    height: 26px !important;
    padding: 0 8px !important;
    border-radius: 6px !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    color: #60a5fa !important;
    background: rgba(59, 130, 246, 0.12) !important;
    border: 1px solid rgba(59, 130, 246, 0.3) !important;
    cursor: pointer !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    transition: all 0.15s ease !important;
}

.order-card-btn-detail:hover {
    background: rgba(59, 130, 246, 0.25) !important;
    border-color: rgba(59, 130, 246, 0.6) !important;
    color: #93c5fd !important;
    transform: translateY(-1px) !important;
}

.order-card-btn-detail svg,
.order-card-btn-detail i {
    width: 12px !important;
    height: 12px !important;
    stroke: #60a5fa !important;
}

.order-card-btn-checkin {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    height: 26px !important;
    padding: 0 8px !important;
    border-radius: 6px !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    color: var(--primary, #10b981) !important;
    background: rgba(16, 185, 129, 0.15) !important;
    border: 1px solid rgba(16, 185, 129, 0.35) !important;
    cursor: pointer !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    transition: all 0.15s ease !important;
}

.order-card-btn-checkin:hover {
    background: rgba(16, 185, 129, 0.28) !important;
    border-color: rgba(16, 185, 129, 0.6) !important;
    color: #a7f3d0 !important;
    transform: translateY(-1px) !important;
}

.order-card-btn-checkin svg,
.order-card-btn-checkin i {
    width: 12px !important;
    height: 12px !important;
    stroke: var(--primary, #10b981) !important;
}

.order-card-btn-print {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 26px !important;
    height: 26px !important;
    min-width: 26px !important;
    border-radius: 6px !important;
    font-size: 0.72rem !important;
    color: var(--text-main, #fff) !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    cursor: pointer !important;
    transition: all 0.15s ease !important;
}

.order-card-btn-print:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
    transform: translateY(-1px) !important;
}

.order-card-btn-print svg,
.order-card-btn-print i {
    width: 13px !important;
    height: 13px !important;
    stroke: var(--text-main, #fff) !important;
}

@media (max-width: 640px) {
    .orders-cards-grid {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }
}

@media (min-width: 769px) {
    .desktop-only-branch {
        display: flex !important;
    }

    .mobile-only-branch {
        display: none !important;
    }
}

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

@media (max-width: 768px) {
    .top-bar {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px !important;
        margin-bottom: 12px !important;
    }

    .page-title {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        min-width: 0 !important;
        flex: 1 !important;
    }

    .page-title-text {
        min-width: 0 !important;
        flex: 1 !important;
    }

    .page-title-text h2 {
        font-size: 0.95rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .page-title-text p {
        font-size: 0.68rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .top-actions {
        width: auto !important;
        display: flex !important;
        align-items: center !important;
        flex-shrink: 0 !important;
    }

    .desktop-only-branch {
        display: none !important;
    }

    .mobile-only-branch {
        display: inline-flex !important;
    }

    /* Uniform Dashboard Outer Flow & Grid Gaps */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
        margin-bottom: 10px !important;
    }

    .stat-card {
        padding: 12px 14px !important;
        border-radius: 8px !important;
        min-width: 0 !important;
        margin: 0 !important;
        margin-bottom: 0 !important;
    }

    .stat-card .stat-card-title {
        font-size: 0.65rem !important;
        letter-spacing: 0.3px !important;
    }

    .stat-val {
        font-size: 1.05rem !important;
        margin: 3px 0 2px 0 !important;
    }

    .stat-card .stat-icon {
        width: 28px !important;
        height: 28px !important;
        border-radius: 6px !important;
        flex-shrink: 0 !important;
        margin-left: auto !important;
        align-self: flex-start !important;
    }

    .stat-card .stat-card-sub {
        font-size: 0.64rem !important;
        line-height: 1.25 !important;
    }

    .dashboard-quick-actions {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        padding: 8px 10px !important;
        gap: 8px !important;
        margin-bottom: 10px !important;
        border-radius: 8px !important;
        scrollbar-width: none !important;
        -ms-overflow-style: none !important;
    }

    .dashboard-quick-actions::-webkit-scrollbar {
        display: none !important;
    }

    .dashboard-quick-actions>span {
        width: auto !important;
        flex-shrink: 0 !important;
        margin-right: 2px !important;
        margin-bottom: 0 !important;
        display: inline-flex !important;
        align-items: center !important;
        font-size: 0.72rem !important;
    }

    .dashboard-quick-actions .action-pill {
        flex: 0 0 auto !important;
        width: auto !important;
        min-width: auto !important;
        font-size: 0.76rem !important;
        padding: 6px 11px !important;
        border-radius: 6px !important;
        white-space: nowrap !important;
        text-align: center !important;
    }

    .dashboard-quick-actions .action-pill:last-child {
        margin-left: 0 !important;
    }

    /* Main Grid & Columns with Zero Redundant Margin */
    .dashboard-main-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        margin-bottom: 0 !important;
    }

    .dashboard-column {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        min-width: 0 !important;
    }

    /* Dashboard Cards & Charts with Uniform Gaps & Padding */
    .dash-chart-card {
        padding: 12px 14px !important;
        border-radius: 8px !important;
        margin: 0 !important;
        margin-bottom: 0 !important;
    }

    .dash-chart-header {
        gap: 6px !important;
        margin-bottom: 10px !important;
        padding-bottom: 8px !important;
    }

    .dash-chart-header h4 {
        font-size: 0.88rem !important;
    }

    .dash-chart-header p {
        font-size: 0.68rem !important;
    }

    .dash-bars-wrapper {
        height: 125px !important;
        gap: 4px !important;
        padding-top: 6px !important;
    }

    .dash-bar-val {
        font-size: 0.58rem !important;
        margin-bottom: 2px !important;
    }

    .dash-bar-fill {
        max-width: 24px !important;
    }

    .dash-bar-label {
        font-size: 0.62rem !important;
        margin-top: 4px !important;
        line-height: 1.15 !important;
    }

    .dash-bar-label small {
        font-size: 0.55rem !important;
    }

    /* Recent Orders & Tables with Uniform Gaps & Padding */
    .card-table {
        border-radius: 8px !important;
        margin: 0 !important;
        margin-bottom: 0 !important;
        overflow: hidden !important;
    }

    .table-header {
        padding: 12px 14px !important;
    }

    .table-header h4 {
        font-size: 0.88rem !important;
    }

    .table-header p {
        font-size: 0.68rem !important;
    }

    .table-header-right .btn-secondary {
        font-size: 0.7rem !important;
        padding: 4px 8px !important;
    }

    .table th,
    .table td {
        padding: 8px 10px !important;
        font-size: 0.76rem !important;
    }

    /* Top Products & Stock */
    .dash-top-prod-item {
        padding: 6px 8px !important;
    }

    .dash-top-prod-item span {
        font-size: 0.75rem !important;
    }
}

@media (max-width: 360px) {
    .stats-grid {
        grid-template-columns: 1fr !important;
        gap: 6px !important;
    }

    .stat-val {
        font-size: 0.95rem !important;
    }
}

/* ============================================
   PREMIUM CHECKOUT LOYALTY POINTS REDEMPTION CARD (ULTRA COMPACT)
   ============================================ */
.checkout-points-card {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.09) 0%, rgba(17, 24, 39, 0.85) 100%);
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: var(--r-sm);
    padding: 10px 12px;
    margin-bottom: 12px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(245, 158, 11, 0.15);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.checkout-points-card::before {
    content: '';
    position: absolute;
    top: -40px;
    right: -30px;
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.points-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.points-header-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    flex: 1;
    cursor: pointer;
    user-select: none;
    margin: 0;
}

.points-header-icon-box {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.25) 0%, rgba(217, 119, 6, 0.15) 100%);
    border: 1px solid rgba(245, 158, 11, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FBBF24;
    flex-shrink: 0;
    box-shadow: 0 1px 4px rgba(245, 158, 11, 0.15);
}

.points-header-icon-box i,
.points-header-icon-box svg {
    width: 13px;
    height: 13px;
}

.points-header-titles {
    display: flex;
    flex-direction: column;
    min-width: 0;
    gap: 1px;
}

.points-title-row {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.points-title-row strong {
    font-size: 0.78rem;
    font-weight: 800;
    color: #FEF3C7;
    line-height: 1.2;
    letter-spacing: -0.2px;
}

.points-sub-hint {
    font-size: 0.64rem;
    color: rgba(254, 243, 199, 0.65);
    line-height: 1.15;
}

.points-badge-pill {
    display: inline-flex;
    align-items: center;
    padding: 1px 6px;
    background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
    color: #0F172A;
    font-size: 0.65rem;
    font-weight: 800;
    border-radius: 999px;
    letter-spacing: 0.2px;
    box-shadow: 0 1px 4px rgba(245, 158, 11, 0.3);
    flex-shrink: 0;
}

/* Custom iOS Style Switch (Ultra-compact & Fully Clickable) */
.custom-switch {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 19px;
    flex-shrink: 0;
    cursor: pointer;
    user-select: none;
    margin: 0;
}

.custom-switch input {
    opacity: 0;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    margin: 0;
    cursor: pointer;
    z-index: 5;
}

.switch-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 20px;
    pointer-events: none;
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 13px;
    width: 13px;
    left: 2px;
    bottom: 2px;
    background-color: #CBD5E1;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.custom-switch input:checked+.switch-slider {
    background: linear-gradient(135deg, var(--primary, #10B981) 0%, var(--primary-hover, #059669) 100%);
    border-color: var(--primary-border, rgba(16, 185, 129, 0.5));
    box-shadow: 0 0 8px var(--primary-shadow, rgba(16, 185, 129, 0.35));
}

.custom-switch input:checked+.switch-slider:before {
    transform: translateX(15px);
    background-color: #FFFFFF;
}

/* Points Input Section (Ultra-compact & Perfectly Uniform Rhythm) */
.points-input-section {
    margin-top: 7px;
    padding-top: 7px;
    border-top: 1px dashed rgba(245, 158, 11, 0.2);
    display: flex;
    flex-direction: column;
    gap: 7px;
    animation: fadeInModal 0.2s ease-out;
}

.points-input-inline-grid {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.points-input-control-wrap {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
}

.points-input-field {
    width: 100%;
    background: rgba(0, 0, 0, 0.45) !important;
    border: 1px solid rgba(245, 158, 11, 0.3) !important;
    border-radius: var(--r-xs) !important;
    padding: 4px 38px 4px 9px !important;
    font-size: 0.82rem !important;
    font-weight: 800 !important;
    color: #FEF3C7 !important;
    height: 30px !important;
    box-sizing: border-box;
    outline: none;
    transition: all 0.15s ease;
}

.points-input-field:focus {
    border-color: #F59E0B !important;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2) !important;
    background: rgba(0, 0, 0, 0.6) !important;
}

.points-input-suffix {
    position: absolute;
    right: 10px;
    font-size: 0.68rem;
    font-weight: 800;
    color: #F59E0B;
    pointer-events: none;
}

.btn-use-max-pts {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.35);
    color: #FBBF24;
    padding: 0 10px;
    height: 30px;
    box-sizing: border-box;
    border-radius: var(--r-xs);
    font-size: 0.68rem;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.15s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn-use-max-pts i,
.btn-use-max-pts svg {
    width: 12px;
    height: 12px;
}

.btn-use-max-pts:hover {
    background: rgba(245, 158, 11, 0.28);
    color: #FEF3C7;
    border-color: #F59E0B;
}

.points-discount-banner {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    margin: 0;
    background: #ECFDF5;
    border: 1.5px solid #86EFAC;
    border-radius: 4px;
    color: #065F46;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.25;
}

.points-discount-banner strong {
    color: #047857;
    font-weight: 900;
}


/* ============================================
   CUSTOM CONFIRMATION & PROMPT DIALOG MODAL
   ============================================ */
.custom-confirm-modal {
    position: fixed !important;
    inset: 0 !important;
    background: rgba(0, 0, 0, 0.85) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    z-index: 9999999 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 18px !important;
    animation: confirmFadeIn 0.2s ease !important;
}

.custom-confirm-box {
    background: #FFFFFF !important;
    border: 1px solid #CBD5E1 !important;
    color: #0F172A !important;
    border-radius: 14px !important;
    max-width: 460px !important;
    width: 100% !important;
    padding: 24px !important;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.15) !important;
    animation: confirmPop 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
    box-sizing: border-box !important;
}

body.admin-page .custom-confirm-box {
    background: #111827 !important;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    color: #F8FAFC !important;
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.85) !important;
}

@keyframes confirmFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes confirmPop {
    from {
        opacity: 0;
        transform: scale(0.92);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}