/* =====================================================================
   MellPOS — Design System
   Pink solid · Putih
   ===================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
    --pink-50:  #fff6fa;
    --pink-100: #fbe3ee;
    --pink-200: #f3bcd4;
    --pink-300: #e58ab6;
    --pink-400: #d45a96;
    --pink-500: #c12d78;
    --pink-600: #a91f65;

    /* Alias lama, kini memakai nuansa pink agar tema tetap satu warna. */
    --purple-50:  #fff0f6;
    --purple-100: #fbe3ee;
    --purple-200: #f3bcd4;
    --purple-300: #e58ab6;
    --purple-400: #c12d78;
    --purple-500: #a91f65;

    --ink:      #36232e;
    --ink-soft: #5c4451;
    --muted:    #7d6472;
    --line:     #f5d9e6;
    --bg:       #fff0f6;
    --white:    #ffffff;

    --success:      #2f9e74;
    --success-bg:   #e8f8f0;
    --warning:      #b98110;
    --warning-bg:   #fff5e0;
    --danger:       #d95367;
    --danger-bg:    #ffe9ec;

    --radius-sm: 10px;
    --radius:    16px;
    --radius-lg: 22px;

    --shadow-sm: 0 4px 14px -8px rgba(96, 51, 80, .35);
    --shadow:    0 18px 40px -28px rgba(96, 51, 80, .45);
    --shadow-lg: 0 28px 60px -30px rgba(96, 51, 80, .45);

    --font: 'Plus Jakarta Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;
    --sidebar-w: 264px;
    --ease: cubic-bezier(.3, .8, .3, 1);
}

/* ---------- 2. Reset & base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    font-family: var(--font);
    font-size: 14px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, p { margin: 0; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }
.icon { flex-shrink: 0; display: inline-block; vertical-align: middle; }
::selection { background: var(--pink-200); color: var(--ink); }

:focus-visible {
    outline: 3px solid rgba(193, 45, 120, .45);
    outline-offset: 2px;
}

.text-pink {
    color: var(--pink-500);
}

/* ---------- 3. Layout ---------- */
.app { min-height: 100vh; }

.app-main {
    margin-left: var(--sidebar-w);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.page-content {
    flex: 1;
    padding: 26px 32px 44px;
    max-width: 1560px;
    width: 100%;
    animation: page-in .35s var(--ease);
}

@keyframes page-in {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: none; }
}

.app-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 18px 24px 26px;
    color: var(--muted);
    font-size: 12px;
}

.app-footer-dot {
    width: 3px; height: 3px;
    border-radius: 50%;
    background: var(--pink-300);
}

/* ---------- 4. Sidebar ---------- */
.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar-w);
    z-index: 60;
    display: flex;
    flex-direction: column;
    background: var(--pink-500);
    border-right: 1px solid var(--pink-600);
    padding: 22px 16px 18px;
    overflow-y: auto;
    scrollbar-width: thin;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 2px 6px 22px;
}

.brand { display: flex; align-items: center; gap: 11px; }

.brand-logo {
    line-height: 0;
    filter: drop-shadow(0 8px 14px rgba(169, 31, 101, .35));
    flex-shrink: 0;
}

.brand-text { display: flex; flex-direction: column; line-height: 1.2; }

.brand-name {
    font-size: 19px;
    font-weight: 800;
    letter-spacing: -.03em;
    color: var(--ink);
}

.brand-tag {
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .13em;
    text-transform: uppercase;
    color: var(--muted);
}

.sidebar .brand-name { color: #fff; }
.sidebar .brand-tag { color: rgba(255, 255, 255, .78); }

.sidebar .icon-btn {
    background: rgba(255, 255, 255, .14);
    border-color: rgba(255, 255, 255, .3);
    color: #fff;
}

.sidebar .icon-btn:hover {
    background: rgba(255, 255, 255, .24);
    border-color: rgba(255, 255, 255, .45);
    color: #fff;
}

.sidebar-close { display: none; }

.sidebar-nav { display: flex; flex-direction: column; gap: 3px; }

.nav-section-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .8);
    padding: 14px 14px 7px;
}

.nav-section-label:first-child { padding-top: 4px; }

.nav-link {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10.5px 13px;
    border-radius: 13px;
    color: #fff;
    font-weight: 600;
    font-size: 13.5px;
    transition: background .18s, color .18s, transform .18s;
}

.nav-icon {
    display: grid;
    place-items: center;
    width: 22px;
    color: #fff;
    transition: color .18s;
}

.nav-link:hover {
    background: rgba(255, 255, 255, .12);
    color: #fff;
}

.nav-link:hover .nav-icon { color: #fff; }

.nav-link.active {
    background: var(--pink-600);
    color: #fff;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
}

.nav-link.active .nav-icon { color: #fff; }

.nav-badge {
    margin-left: auto;
    min-width: 20px;
    padding: 1px 7px;
    border-radius: 99px;
    background: #fff;
    color: var(--pink-600);
    font-size: 10.5px;
    font-weight: 700;
    text-align: center;
}

.nav-link.active .nav-badge {
    background: rgba(255, 255, 255, .28);
    color: #fff;
}

.nav-divider {
    height: 1px;
    background: rgba(255, 255, 255, .2);
    margin: 8px 12px;
}

.nav-logout { color: #fff; }
.nav-logout .nav-icon { color: rgba(255, 255, 255, .7); }
.nav-logout:hover { background: rgba(0, 0, 0, .14); color: #fff; }
.nav-logout:hover .nav-icon { color: #fff; }

.sidebar-footer { margin-top: auto; padding-top: 22px; }

.sidebar-cta {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 13px;
    border-radius: 15px;
    background: var(--pink-600);
    border: 1px solid rgba(255, 255, 255, .18);
    margin-bottom: 14px;
}

.sidebar-cta-icon {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: rgba(255, 255, 255, .16);
    color: #fff;
    flex-shrink: 0;
}

.sidebar-cta strong {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
}

.sidebar-cta span { font-size: 11px; color: rgba(255, 255, 255, .8); }

.user-mini {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 8px 2px;
    border-top: 1px solid rgba(255, 255, 255, .2);
}

.user-mini-text { display: flex; flex-direction: column; line-height: 1.35; min-width: 0; }
.sidebar .user-mini-text strong { color: #fff; }
.user-mini-text strong { font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-mini-text span { font-size: 11px; color: var(--muted); }
.sidebar .user-mini-text span { color: rgba(255, 255, 255, .78); }
.sidebar .avatar-pink { background: var(--pink-600); color: #fff; }
.user-mini .icon-btn { margin-left: auto; }

.sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 55;
    background: rgba(58, 37, 51, .42);
    backdrop-filter: blur(3px);
    border: 0;
}

/* ---------- 5. Avatar ---------- */
.avatar {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: .02em;
    background: var(--pink-100);
    color: var(--pink-600);
    flex-shrink: 0;
}

.avatar-pink { background: var(--pink-100); color: var(--pink-600); }

.avatar-photo { padding: 0; overflow: hidden; }
.avatar-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }

.avatar-primary {
    background: var(--pink-500);
    color: #fff;
    box-shadow: 0 8px 16px -10px rgba(169, 31, 101, .7);
}

.avatar-xl {
    width: 84px;
    height: 84px;
    border-radius: 26px;
    font-size: 27px;
    border: 4px solid #fff;
    box-shadow: 0 14px 30px -16px rgba(190, 105, 150, .7);
}

/* ---------- 6. Topbar ---------- */
.topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 32px;
    background: rgba(255, 240, 246, .94);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(245, 217, 230, .9);
}

.menu-toggle { display: none; }

.page-heading { min-width: 0; }

.page-heading h1 {
    font-size: 21px;
    font-weight: 800;
    letter-spacing: -.035em;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.page-heading p {
    font-size: 12.5px;
    color: var(--muted);
    margin-top: 1px;
}

.topbar-right {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}

.date-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 38px;
    padding: 0 14px;
    border-radius: 11px;
    background: #fff;
    border: 1px solid var(--line);
    color: var(--ink-soft);
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.date-chip .icon { color: var(--pink-400); }

.icon-btn {
    display: inline-grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 11px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--ink-soft);
    transition: background .18s, color .18s, border-color .18s, transform .18s;
}

.icon-btn:hover { background: var(--pink-50); color: var(--pink-500); border-color: var(--pink-200); }
.icon-btn:active { transform: scale(.96); }
.icon-btn-sm { width: 30px; height: 30px; border-radius: 9px; }

.has-dot { position: relative; }

.has-dot::after {
    content: '';
    position: absolute;
    top: 8px;
    right: 9px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--pink-400);
    border: 2px solid #fff;
}

.user-chip {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 4px 12px 4px 4px;
    border-radius: 13px;
    border: 1px solid var(--line);
    background: #fff;
    transition: border-color .18s, background .18s;
}

.user-chip:hover { border-color: var(--pink-200); background: var(--pink-50); }
.user-chip-text { display: flex; flex-direction: column; line-height: 1.3; }
.user-chip-text strong { font-size: 12px; font-weight: 700; }
.user-chip-text span { font-size: 10.5px; color: var(--muted); }

/* ---------- 7. Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 40px;
    padding: 0 17px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
    transition: background .18s, color .18s, border-color .18s, transform .12s, box-shadow .18s;
}

.btn:active { transform: translateY(1px); }
.btn .icon { width: 17px; height: 17px; }

.btn-primary {
    background: var(--pink-500);
    border-color: var(--pink-500);
    color: #fff;
    box-shadow: 0 10px 22px -13px rgba(169, 31, 101, .8);
}

.btn-primary:hover {
    background: var(--pink-600);
    border-color: var(--pink-600);
    color: #fff;
    box-shadow: 0 14px 26px -13px rgba(169, 31, 101, .75);
}

.btn-soft {
    background: var(--pink-50);
    border-color: var(--pink-100);
    color: var(--pink-600);
}

.btn-soft:hover { background: var(--pink-100); }

.btn-ghost {
    background: #fff;
    border-color: var(--line);
    color: var(--ink-soft);
}

.btn-ghost:hover { background: var(--pink-50); border-color: var(--pink-200); color: var(--pink-600); }

.btn-danger { background: var(--danger-bg); color: var(--danger); border-color: #ffd7dd; }
.btn-danger:hover { background: #ffdde2; }

.btn-danger-text { color: var(--danger); }
.btn-danger-text:hover { background: var(--danger-bg); border-color: #ffd7dd; color: var(--danger); }

.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #4c3a53; }

.btn-block { width: 100%; }
.btn-lg { height: 48px; border-radius: 14px; font-size: 14px; }
.btn-sm { height: 32px; padding: 0 11px; font-size: 11.5px; border-radius: 9px; gap: 6px; }
.btn-sm .icon { width: 14px; height: 14px; }

.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- 8. Cards & sections ---------- */
.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 19px 22px 0;
}

.card-head-line { padding-bottom: 16px; border-bottom: 1px solid var(--line); }

.card-title { font-size: 14.5px; font-weight: 800; letter-spacing: -.02em; }
.card-subtitle { font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.card-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.card-body { padding: 18px 22px 22px; }
.card-body-flush { padding: 0; }

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.section-head h2 { font-size: 16px; font-weight: 800; letter-spacing: -.02em; }
.section-head p { font-size: 12px; color: var(--muted); }

.grid-2 { display: grid; grid-template-columns: 1.65fr 1fr; gap: 18px; align-items: start; }
.grid-2-even { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: start; }

.page-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 16px;
}

/* ---------- 9. Stat cards ---------- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.stat-card {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: flex-start;
    gap: 13px;
    padding: 18px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 19px;
    box-shadow: var(--shadow);
}

.stat-card::after {
    content: '';
    position: absolute;
    right: -26px;
    top: -30px;
    width: 88px;
    height: 88px;
    border-radius: 50%;
    background: var(--pink-50);
    opacity: .85;
}

.stat-icon {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 13px;
    flex-shrink: 0;
}

.stat-icon.pink,
.stat-icon.purple,
.stat-icon.mint,
.stat-icon.amber { background: var(--pink-100); color: var(--pink-600); }

.stat-body { position: relative; z-index: 1; min-width: 0; flex: 1; }
.stat-label { font-size: 11.5px; font-weight: 600; color: var(--muted); white-space: nowrap; }

.stat-value {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -.035em;
    line-height: 1.25;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stat-foot {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 7px;
    font-size: 10.5px;
    color: var(--muted);
}

.stat-trend {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 1px 7px;
    border-radius: 99px;
    font-size: 10px;
    font-weight: 700;
}

.stat-trend.up   { background: var(--success-bg); color: var(--success); }
.stat-trend.down { background: var(--danger-bg); color: var(--danger); }
.stat-trend .icon { width: 11px; height: 11px; }

/* ---------- 10. Toolbar, forms ---------- */
.toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.toolbar-search { position: relative; flex: 1; min-width: 220px; max-width: 380px; }
.toolbar-search .icon {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    pointer-events: none;
}

.toolbar-search .form-control { padding-left: 39px; height: 40px; border-radius: 12px; }
.toolbar-filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-left: auto; }

.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 15px; }
.form-group:last-child { margin-bottom: 0; }

.form-label {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--ink-soft);
    letter-spacing: .01em;
}

.form-label .req { color: var(--pink-500); }

.form-control {
    width: 100%;
    height: 42px;
    padding: 0 13px;
    border: 1px solid #eedde8;
    border-radius: 11px;
    background: #fffdff;
    font-size: 13px;
    color: var(--ink);
    transition: border-color .18s, box-shadow .18s, background .18s;
}

.form-control::placeholder { color: #a58d99; }

.form-control:focus {
    outline: none;
    border-color: var(--pink-300);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(193, 45, 120, .14);
}

textarea.form-control { height: auto; min-height: 84px; padding: 11px 13px; resize: vertical; line-height: 1.55; }
select.form-control { appearance: none; padding-right: 34px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2397869d' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; }

.form-hint { font-size: 10.5px; color: var(--muted); line-height: 1.5; }

.form-check { display: inline-flex; align-items: center; gap: 9px; font-size: 12px; font-weight: 600; color: var(--ink-soft); cursor: pointer; }
.form-check input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--pink-500); }

input[type="file"].form-control { height: auto; padding: 7px 10px; font-size: 11.5px; }
input[type="file"].form-control::file-selector-button { margin-right: 9px; padding: 5px 10px; border: 0; border-radius: 8px; background: var(--pink-50); color: var(--pink-600); font-size: 11px; font-weight: 700; cursor: pointer; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.form-grid .span-2 { grid-column: span 2; }

.input-icon { position: relative; }
.input-icon > .icon { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.input-icon .form-control { padding-left: 39px; }

.password-toggle {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border: 0;
    background: transparent;
    color: var(--muted);
    border-radius: 8px;
}

.password-toggle:hover { background: var(--pink-50); color: var(--pink-500); }

.input-prefix { position: relative; }
.input-prefix-text {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    pointer-events: none;
}
.input-prefix .form-control { padding-left: 38px; }

.date-form { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.date-form .form-group { margin-bottom: 0; min-width: 145px; }

/* ---------- 11. Tables ---------- */
.table-wrap {
    width: 100%;
    overflow-x: auto;
    scrollbar-width: thin;
}

.table { width: 100%; border-collapse: collapse; white-space: nowrap; }

.table thead th {
    padding: 11px 20px;
    background: #fff9fc;
    border-bottom: 1px solid var(--line);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: var(--muted);
    text-align: left;
}

.table tbody td {
    padding: 13px 20px;
    border-bottom: 1px solid #f8eef4;
    font-size: 12.5px;
    color: var(--ink-soft);
    vertical-align: middle;
}

.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr { transition: background .15s; }
.table tbody tr:hover { background: #fffafd; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table .strong { font-weight: 700; color: var(--ink); }
.table .muted { color: var(--muted); font-size: 11.5px; }

.table-actions { display: flex; align-items: center; gap: 6px; justify-content: flex-end; }

.product-cell { display: flex; align-items: center; gap: 11px; min-width: 0; }
.product-cell-text { display: flex; flex-direction: column; line-height: 1.4; min-width: 0; }
.product-cell-text strong { font-size: 12.5px; font-weight: 700; color: var(--ink); }
.product-cell-text span { font-size: 10.5px; color: var(--muted); }

.product-thumb {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 11px;
    background: var(--pink-100);
    color: var(--pink-600);
    font-size: 13px;
    font-weight: 800;
    flex-shrink: 0;
    text-transform: uppercase;
}

.stock-cell { display: flex; flex-direction: column; gap: 4px; min-width: 88px; }
.stock-cell-top { display: flex; align-items: center; gap: 6px; }

.stock-bar {
    height: 4px;
    width: 100%;
    border-radius: 99px;
    background: #f5ebf1;
    overflow: hidden;
}

.stock-bar span {
    display: block;
    height: 100%;
    border-radius: 99px;
    background: var(--pink-500);
}

.stock-bar.low span { background: #f3b45f; }
.stock-bar.empty span { background: #ef93a2; }

.table-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 48px 20px;
    text-align: center;
}

.table-empty .empty-icon { margin-bottom: 2px; }
.table-empty h3 { font-size: 14px; font-weight: 800; }
.table-empty p { font-size: 12px; color: var(--muted); max-width: 300px; }

/* ---------- 12. Badges, alerts, misc ---------- */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 99px;
    font-size: 10.5px;
    font-weight: 700;
    line-height: 1.5;
    white-space: nowrap;
}

.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-danger  { background: var(--danger-bg); color: var(--danger); }
.badge-info    { background: var(--purple-100); color: var(--purple-500); }
.badge-pink    { background: var(--pink-100); color: var(--pink-600); }
.badge-neutral { background: #f5eff4; color: var(--muted); }

.badge .dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
}

.alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 12.5px;
    font-weight: 500;
    margin-bottom: 14px;
    line-height: 1.55;
}

.alert .icon { margin-top: 1px; }
.alert-success { background: var(--success-bg); color: #1f7a58; }
.alert-danger  { background: var(--danger-bg); color: #b53d50; }
.alert-info    { background: var(--pink-50); color: var(--pink-600); }
.alert-warning { background: var(--warning-bg); color: #93670e; }

.filter-tabs {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 11px;
    flex-wrap: wrap;
}

.filter-tabs a {
    padding: 5px 11px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    color: var(--muted);
    transition: background .15s, color .15s;
}

.filter-tabs a:hover { color: var(--ink); }
.filter-tabs a.active { background: var(--pink-50); color: var(--pink-600); font-weight: 700; }

.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 20px;
    border-top: 1px solid var(--line);
    font-size: 11.5px;
    color: var(--muted);
    flex-wrap: wrap;
}

.pagination-links { display: flex; gap: 5px; }

.pagination-links a,
.pagination-links span {
    min-width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    padding: 0 8px;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: #fff;
    font-size: 11px;
    font-weight: 700;
    color: var(--ink-soft);
}

.pagination-links a:hover { background: var(--pink-50); border-color: var(--pink-200); color: var(--pink-600); }
.pagination-links .current { background: var(--pink-100); border-color: var(--pink-200); color: var(--pink-600); }
.pagination-links .disabled { opacity: .45; }

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 46px 20px;
}

.empty-icon {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 17px;
    background: var(--pink-100);
    color: var(--pink-600);
    margin-bottom: 12px;
}

.empty-state h3 { font-size: 14px; font-weight: 800; margin-bottom: 3px; }
.empty-state p { font-size: 12px; color: var(--muted); max-width: 320px; margin-bottom: 14px; }

.divider { height: 1px; background: var(--line); margin: 16px 0; }

.hint-box {
    display: flex;
    gap: 9px;
    padding: 11px 13px;
    border-radius: 11px;
    background: var(--pink-50);
    color: #7a3b5d;
    font-size: 11.5px;
    line-height: 1.55;
    border: 1px solid var(--pink-100);
}

.hint-box .icon { color: var(--purple-400); margin-top: 1px; }

/* ---------- 13. Dashboard ---------- */
.chart-wrap { padding: 10px 4px 0; }

.bar-chart {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    height: 190px;
    padding-top: 14px;
}

.bar-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    height: 100%;
    min-width: 0;
}

.bar-value {
    font-size: 9.5px;
    font-weight: 700;
    color: var(--muted);
    white-space: nowrap;
}

.bar-fill {
    width: 100%;
    max-width: 34px;
    border-radius: 9px 9px 5px 5px;
    background: var(--pink-400);
    min-height: 5px;
    transition: height .4s var(--ease);
    position: relative;
}

.bar-col.today .bar-fill {
    background: var(--pink-600);
}

.bar-col.today .bar-label { color: var(--pink-500); font-weight: 700; }

.bar-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--muted);
    text-align: center;
    white-space: nowrap;
}

.chart-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 14px;
    margin-top: 4px;
    border-top: 1px dashed var(--line);
    font-size: 11px;
    color: var(--muted);
}

.chart-legend { display: flex; align-items: center; gap: 12px; }
.legend-item { display: flex; align-items: center; gap: 5px; }
.legend-dot { width: 8px; height: 8px; border-radius: 3px; background: var(--pink-500); }
.legend-dot.alt { background: #f1e7ef; }

.recent-list { display: flex; flex-direction: column; }

.recent-item {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 11px 22px;
    border-bottom: 1px solid #f8eef4;
    transition: background .15s;
}

.recent-item:last-child { border-bottom: 0; }
.recent-item:hover { background: #fffafd; }

.recent-icon {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 11px;
    background: var(--pink-50);
    color: var(--pink-400);
    flex-shrink: 0;
}

.recent-text { display: flex; flex-direction: column; line-height: 1.4; min-width: 0; }
.recent-text strong { font-size: 12px; font-weight: 700; }
.recent-text span { font-size: 10.5px; color: var(--muted); }
.recent-amount { margin-left: auto; font-size: 12px; font-weight: 800; white-space: nowrap; }

.low-stock-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px dashed var(--line);
}

.low-stock-item:last-child { border-bottom: 0; }
.low-stock-item .product-thumb { width: 32px; height: 32px; border-radius: 9px; font-size: 11px; }
.low-stock-item strong { font-size: 11.5px; font-weight: 700; display: block; line-height: 1.4; }
.low-stock-item span { font-size: 10px; color: var(--muted); }

.low-stock-count { margin-left: auto; text-align: right; }
.low-stock-count strong { font-size: 12px; font-weight: 800; }
.low-stock-count span { font-size: 9.5px; }

.greeting {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 22px;
    margin-bottom: 18px;
    border-radius: var(--radius-lg);
    background: var(--pink-100);
    border: 1px solid var(--pink-200);
    overflow: hidden;
    position: relative;
}

.greeting-icon {
    display: grid;
    place-items: center;
    width: 50px;
    height: 50px;
    border-radius: 16px;
    background: #fff;
    color: var(--pink-500);
    box-shadow: 0 12px 24px -16px rgba(216, 104, 158, .9);
    flex-shrink: 0;
}

.greeting-text { min-width: 0; }
.greeting-text h2 { font-size: 15.5px; font-weight: 800; letter-spacing: -.02em; }
.greeting-text p { font-size: 12px; color: var(--muted); margin-top: 2px; }

.greeting-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- 14. POS ---------- */
.pos-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 372px;
    gap: 18px;
    align-items: start;
}

.pos-catalog { min-width: 0; }

.pos-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.pos-toolbar .toolbar-search { max-width: none; flex: 1; }

.category-chips {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.chip {
    padding: 7px 13px;
    border-radius: 99px;
    border: 1px solid var(--line);
    background: #fff;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--ink-soft);
    transition: all .16s;
}

.chip:hover { border-color: var(--pink-200); color: var(--pink-600); }
.chip.active {
    background: var(--pink-500);
    border-color: var(--pink-500);
    color: #fff;
    box-shadow: 0 8px 18px -12px rgba(169, 31, 101, .75);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(158px, 1fr));
    gap: 12px;
}

.pos-card {
    display: flex;
    flex-direction: column;
    gap: 9px;
    padding: 12px;
    text-align: left;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 17px;
    box-shadow: 0 10px 24px -24px rgba(96, 51, 80, .5);
    transition: transform .18s var(--ease), box-shadow .18s, border-color .18s;
    position: relative;
}

.pos-card:hover {
    transform: translateY(-3px);
    border-color: var(--pink-200);
    box-shadow: 0 18px 28px -22px rgba(96, 51, 80, .55);
}

.pos-card:active { transform: translateY(-1px) scale(.99); }
.pos-card.is-disabled { opacity: .5; cursor: not-allowed; pointer-events: none; }

.pos-thumb {
    position: relative;
    display: grid;
    place-items: center;
    height: 78px;
    border-radius: 12px;
    background: var(--pink-100);
    color: var(--pink-600);
    font-size: 25px;
    font-weight: 800;
    overflow: hidden;
}

.pos-thumb::after {
    content: '';
    position: absolute;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .45);
    top: -22px;
    right: -16px;
}

.pos-cat { font-size: 9px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--pink-500); }
.pos-name { font-size: 12px; font-weight: 700; line-height: 1.35; color: var(--ink); }
.pos-meta { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: auto; }
.pos-price { font-size: 12.5px; font-weight: 800; color: var(--pink-600); }
.pos-stock { font-size: 9.5px; color: var(--muted); }
.pos-stock.low { color: var(--warning); }

.pos-cart {
    position: sticky;
    top: 100px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: calc(100vh - 124px);
}

.cart-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 17px 18px 14px;
    border-bottom: 1px solid var(--line);
}

.cart-head-icon {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: var(--pink-100);
    color: var(--pink-600);
}

.cart-head h2 { font-size: 13.5px; font-weight: 800; }
.cart-head p { font-size: 10.5px; color: var(--muted); }

.cart-count {
    margin-left: auto;
    min-width: 24px;
    height: 24px;
    padding: 0 7px;
    display: grid;
    place-items: center;
    border-radius: 99px;
    background: var(--pink-100);
    color: var(--pink-600);
    font-size: 10.5px;
    font-weight: 800;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 8px 18px;
    min-height: 90px;
    scrollbar-width: thin;
}

.cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 30px 10px;
    text-align: center;
    color: var(--muted);
}

.cart-empty-icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: var(--pink-50);
    color: var(--pink-300);
    margin-bottom: 2px;
}

.cart-empty strong { font-size: 12px; color: var(--ink-soft); }
.cart-empty span { font-size: 10.5px; }

.cart-item {
    display: flex;
    gap: 10px;
    padding: 11px 0;
    border-bottom: 1px dashed var(--line);
}

.cart-item:last-child { border-bottom: 0; }

.cart-item-thumb {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    background: var(--pink-100);
    color: var(--pink-600);
    font-size: 13px;
    font-weight: 800;
    flex-shrink: 0;
}

.cart-item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cart-item-name { font-size: 11.5px; font-weight: 700; line-height: 1.35; }
.cart-item-price { font-size: 10px; color: var(--muted); }
.cart-item-sub { font-size: 11.5px; font-weight: 800; color: var(--ink); margin-top: 2px; }

.cart-item-side { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }

.qty-control {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    padding: 2px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
}

.qty-btn {
    width: 21px;
    height: 21px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--ink-soft);
    font-size: 13px;
    line-height: 1;
}

.qty-btn:hover { background: var(--pink-50); color: var(--pink-500); }
.qty-value { min-width: 20px; text-align: center; font-size: 11px; font-weight: 700; }

.cart-remove {
    border: 0;
    background: transparent;
    color: #c3adb9;
    display: grid;
    place-items: center;
    padding: 2px;
    border-radius: 6px;
}

.cart-remove:hover { color: var(--danger); background: var(--danger-bg); }
.cart-remove .icon { width: 14px; height: 14px; }

.cart-summary {
    padding: 14px 18px 16px;
    border-top: 1px solid var(--line);
    background: #fff;
}

.summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11.5px;
    color: var(--muted);
    padding: 2px 0;
}

.summary-row strong { color: var(--ink-soft); font-weight: 700; font-size: 12px; }

.summary-total {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 9px 0 12px;
    border-top: 1px dashed var(--line);
    margin-top: 6px;
}

.summary-total span { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.summary-total strong { font-size: 20px; font-weight: 800; letter-spacing: -.04em; color: var(--pink-600); }

.payment-box { display: flex; flex-direction: column; gap: 9px; }

.payment-box .form-control { height: 42px; font-weight: 700; }
.payment-box select.form-control { font-weight: 600; height: 38px; font-size: 12px; }

.quick-cash { display: flex; gap: 6px; flex-wrap: wrap; }
.quick-cash button {
    flex: 1;
    min-width: 60px;
    height: 28px;
    border: 1px solid var(--pink-100);
    background: var(--pink-50);
    border-radius: 8px;
    font-size: 10px;
    font-weight: 700;
    color: var(--pink-600);
    transition: background .15s;
}

.quick-cash button:hover { background: var(--pink-100); }

.change-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 7px 11px;
    border-radius: 9px;
    background: var(--success-bg);
    font-size: 11px;
    color: #237c59;
}

.change-row strong { font-size: 12.5px; font-weight: 800; }
.change-row.negative { background: var(--danger-bg); color: #b53d50; }

.cart-actions { display: grid; grid-template-columns: auto 1fr; gap: 8px; padding-top: 4px; }
.cart-actions .btn { height: 44px; }

/* ---------- 15. Modal ---------- */
.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: none;
    padding: 20px;
    overflow-y: auto;
}

body.modal-open { overflow: hidden; }

.modal.open { display: flex; align-items: center; justify-content: center; }

.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(58, 37, 51, .52);
    backdrop-filter: blur(4px);
    animation: modal-fade-in .2s var(--ease);
}

.modal-dialog {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 500px;
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    margin: 0 auto;
    background: #fff;
    border-radius: 22px;
    box-shadow: 0 40px 80px -30px rgba(58, 37, 51, .5);
    animation: modal-pop .24s var(--ease);
    overflow: hidden;
}

.modal-dialog.modal-sm { max-width: 420px; }

@keyframes modal-pop {
    from { opacity: 0; transform: translateY(14px) scale(.98); }
    to   { opacity: 1; transform: none; }
}

@keyframes modal-out {
    to { opacity: 0; transform: translateY(10px) scale(.985); }
}

@keyframes modal-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes modal-fade-out {
    to { opacity: 0; }
}

.modal.closing .modal-dialog { animation: modal-out .18s var(--ease) forwards; }
.modal.closing .modal-backdrop { animation: modal-fade-out .18s var(--ease) forwards; }

.modal-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 20px 22px 14px;
    border-bottom: 1px solid var(--line);
    flex-shrink: 0;
}

.modal-heading { min-width: 0; flex: 1; }

.modal-head-icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: var(--pink-100);
    color: var(--pink-600);
    flex-shrink: 0;
}

.modal-head-icon.is-success { background: var(--success-bg); color: var(--success); }
.modal-head-icon.is-error { background: var(--danger-bg); color: var(--danger); }
.modal-head-icon.is-warning { background: var(--warning-bg); color: var(--warning); }
.modal-head-icon.is-info { background: var(--pink-100); color: var(--pink-600); }
.modal-head-icon.is-primary { background: var(--pink-100); color: var(--pink-600); }
.modal-head-icon.is-danger { background: var(--danger-bg); color: var(--danger); }

.modal-title { font-size: 15px; font-weight: 800; letter-spacing: -.02em; }
.modal-subtitle { font-size: 11px; color: var(--muted); margin-top: 1px; }

.modal-close {
    margin-left: auto;
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 9px;
    background: #fbf4f8;
    color: var(--muted);
}

.modal-close:hover { background: var(--pink-100); color: var(--pink-600); }

.modal-body {
    padding: 18px 22px;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.modal-message {
    color: var(--ink-soft);
    font-size: 13px;
    line-height: 1.65;
    white-space: pre-line;
}

.modal-details { margin-top: 14px; }
.modal-details:empty { display: none; }

.modal-detail-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 8px 0;
    border-bottom: 1px dashed var(--line);
    font-size: 12px;
}

.modal-detail-row:last-child { border-bottom: 0; }
.modal-detail-row span { color: var(--muted); }
.modal-detail-row strong { font-weight: 700; text-align: right; word-break: break-word; }

.modal-item-list {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-top: 2px;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--pink-50);
    border: 1px solid var(--line);
}

.modal-item-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    font-size: 11.5px;
    color: var(--ink-soft);
}

.modal-item-row strong { font-weight: 700; white-space: nowrap; }
.modal-item-row span { min-width: 0; }

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 9px;
    padding: 14px 22px 18px;
    border-top: 1px solid var(--line);
    background: #fffafd;
    flex-shrink: 0;
}

.modal-icon-templates { display: none !important; }

.btn-danger-solid {
    background: var(--danger);
    border-color: var(--danger);
    color: #fff;
}

.btn-danger-solid:hover { background: #c7465a; border-color: #c7465a; color: #fff; }

/* ---------- 16. Toast ---------- */
.toast-stack {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 300;
    display: flex;
    flex-direction: column;
    gap: 9px;
    max-width: min(360px, calc(100vw - 32px));
}

.toast {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 12px 13px;
    border-radius: 13px;
    background: #fff;
    border: 1px solid var(--line);
    border-left: 4px solid var(--pink-400);
    box-shadow: 0 18px 40px -22px rgba(58, 37, 51, .5);
    font-size: 12px;
    animation: toast-in .3s var(--ease);
}

.toast.leaving { animation: toast-out .25s var(--ease) forwards; }
.toast-success { border-left-color: #4bc295; }
.toast-error,
.toast-danger  { border-left-color: #ef8092; }
.toast-warning { border-left-color: #e5b34a; }
.toast-info    { border-left-color: var(--pink-400); }

.toast-icon { display: grid; place-items: center; color: var(--pink-400); margin-top: 1px; }
.toast-success .toast-icon { color: var(--success); }
.toast-error .toast-icon,
.toast-danger .toast-icon { color: var(--danger); }
.toast-warning .toast-icon { color: var(--warning); }
.toast-info .toast-icon { color: var(--pink-500); }
.toast-text { flex: 1; color: var(--ink-soft); line-height: 1.5; }

.toast-close {
    border: 0;
    background: transparent;
    color: #bdaabf;
    font-size: 17px;
    line-height: 1;
    padding: 0 2px;
}

.toast-close:hover { color: var(--ink); }

@keyframes toast-in {
    from { opacity: 0; transform: translateX(20px); }
    to   { opacity: 1; transform: none; }
}

@keyframes toast-out {
    to { opacity: 0; transform: translateX(20px); }
}

/* ---------- 17. Profile ---------- */
.profile-hero {
    position: relative;
    padding: 0 0 22px;
    overflow: hidden;
    margin-bottom: 18px;
}

.profile-cover {
    height: 118px;
    background: var(--pink-500);
}

.profile-hero-body {
    display: flex;
    align-items: flex-end;
    gap: 16px;
    padding: 0 24px;
    margin-top: -42px;
    flex-wrap: wrap;
}

.profile-ident { display: flex; flex-direction: column; gap: 2px; padding-bottom: 2px; }
.profile-ident h2 { font-size: 18px; font-weight: 800; letter-spacing: -.03em; }
.profile-ident p { font-size: 12px; color: var(--muted); }

.profile-badges { display: flex; gap: 6px; margin-top: 5px; flex-wrap: wrap; }

.profile-hero-actions { margin-left: auto; display: flex; gap: 8px; padding-bottom: 4px; }

.info-list { display: flex; flex-direction: column; }

.info-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px dashed var(--line);
}

.info-row:last-child { border-bottom: 0; }

.info-icon {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: var(--pink-50);
    color: var(--pink-400);
    flex-shrink: 0;
}

.info-text { display: flex; flex-direction: column; line-height: 1.45; min-width: 0; }
.info-text span { font-size: 10px; color: var(--muted); }
.info-text strong { font-size: 12px; font-weight: 700; word-break: break-word; }

.profile-avatar-wrap { position: relative; }
.profile-avatar-ring {
    position: relative;
    z-index: 1;
}

/* ---------- 18. Laporan ---------- */
.summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.mini-stat {
    padding: 15px 17px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
}

.mini-stat span { font-size: 10.5px; font-weight: 600; color: var(--muted); display: block; }
.mini-stat strong { font-size: 17px; font-weight: 800; letter-spacing: -.03em; display: block; margin-top: 1px; }
.mini-stat small { font-size: 10px; color: var(--muted); }

.report-list { display: flex; flex-direction: column; gap: 11px; }
.report-list-item { display: flex; align-items: center; gap: 10px; }
.report-list-item .rank {
    width: 22px;
    height: 22px;
    display: grid;
    place-items: center;
    border-radius: 7px;
    background: var(--pink-50);
    color: var(--pink-500);
    font-size: 10px;
    font-weight: 800;
    flex-shrink: 0;
}
.report-list-item .report-name { font-size: 11.5px; font-weight: 700; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.report-list-item .report-val { font-size: 11.5px; font-weight: 800; }
.report-list-item small { color: var(--muted); font-size: 9.5px; display: block; font-weight: 500; }

.method-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px dashed var(--line);
}

.method-row:last-child { border-bottom: 0; }

.method-icon {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: var(--purple-50);
    color: var(--purple-400);
}

.method-row strong { font-size: 11.5px; font-weight: 700; display: block; }
.method-row span { font-size: 10px; color: var(--muted); }
.method-val { margin-left: auto; text-align: right; font-size: 11.5px; font-weight: 800; }

/* ---------- 19. Receipt / detail ---------- */
.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 18px;
    align-items: start;
}

.receipt-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 24px;
    box-shadow: var(--shadow);
}

.receipt-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px dashed var(--line);
}

.receipt-brand { display: flex; align-items: center; gap: 10px; }
.receipt-brand strong { font-size: 14px; font-weight: 800; display: block; line-height: 1.2; }
.receipt-brand span { font-size: 10px; color: var(--muted); }

.receipt-meta { text-align: right; font-size: 10.5px; color: var(--muted); line-height: 1.6; }
.receipt-meta strong { display: block; font-size: 11.5px; color: var(--ink); font-weight: 700; }

.receipt-items { width: 100%; border-collapse: collapse; margin: 12px 0; }
.receipt-items th {
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--muted);
    text-align: left;
    padding: 5px 0;
}
.receipt-items th.num, .receipt-items td.num { text-align: right; }
.receipt-items td { padding: 7px 0; font-size: 11.5px; border-bottom: 1px dashed #f7ecf3; vertical-align: top; }
.receipt-items td small { display: block; font-size: 9.5px; color: var(--muted); }

.receipt-totals { margin-left: auto; width: 100%; max-width: 250px; padding-top: 4px; }
.receipt-totals .summary-row { font-size: 11px; }
.receipt-grand { display: flex; align-items: center; justify-content: space-between; padding-top: 7px; margin-top: 5px; border-top: 1px dashed var(--line); }
.receipt-grand span { font-size: 11px; font-weight: 700; }
.receipt-grand strong { font-size: 15px; font-weight: 800; color: var(--pink-600); }

.receipt-foot { text-align: center; font-size: 10.5px; color: var(--muted); padding-top: 16px; margin-top: 14px; border-top: 1px dashed var(--line); line-height: 1.7; }

.detail-side { display: flex; flex-direction: column; gap: 14px; }

.detail-note { font-size: 11.5px; color: var(--muted); line-height: 1.6; }

/* ---------- 20. Auth ---------- */
.auth-body { background: var(--bg); }

.auth-shell {
    display: grid;
    grid-template-columns: 1.02fr .98fr;
    min-height: 100vh;
}

.auth-hero {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 44px 52px;
    overflow: hidden;
    background: var(--pink-500);
}

.auth-hero-top { position: relative; z-index: 2; }

.auth-hero .brand-name { font-size: 22px; color: #fff; }
.auth-hero .brand-tag { color: rgba(255, 255, 255, .78); }

.auth-hero-desc {
    margin-top: 20px;
    max-width: 330px;
    font-size: 13px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .88);
}

.auth-illustration {
    position: relative;
    flex: 1;
    min-height: 300px;
    margin: 22px 0 10px;
}

.auth-orb { position: absolute; border-radius: 50%; filter: blur(1px); }
.orb-1 {
    width: 180px; height: 180px;
    left: 18%; top: 16%;
    background: rgba(255, 255, 255, .18);
    opacity: 1;
    box-shadow: 0 30px 60px -30px rgba(80, 8, 48, .35);
}
.orb-2 {
    width: 108px; height: 108px;
    right: 16%; top: 40%;
    background: rgba(255, 255, 255, .12);
    opacity: 1;
    box-shadow: 0 26px 50px -26px rgba(80, 8, 48, .3);
}
.orb-3 {
    width: 54px; height: 54px;
    left: 30%; bottom: 16%;
    background: rgba(255, 255, 255, .24);
    opacity: 1;
}

.auth-glass {
    position: absolute;
    left: 8%;
    bottom: 12%;
    width: 210px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, .62);
    border: 1px solid rgba(255, 255, 255, .85);
    backdrop-filter: blur(14px);
    box-shadow: 0 24px 48px -26px rgba(120, 60, 105, .45);
}

.auth-glass-row { display: flex; gap: 5px; margin-bottom: 11px; }
.dot { width: 7px; height: 7px; border-radius: 50%; }
.dot-pink { background: var(--pink-500); }
.dot-purple { background: var(--pink-600); }
.dot-yellow { background: var(--pink-300); }

.auth-bar { height: 6px; border-radius: 99px; background: #f2e3ec; margin-bottom: 7px; overflow: hidden; }
.auth-bar span { display: block; height: 100%; border-radius: 99px; background: var(--pink-500); }

.float-card {
    position: absolute;
    z-index: 3;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 13px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .92);
    box-shadow: 0 20px 36px -22px rgba(120, 60, 105, .5);
    border: 1px solid #fff;
    animation: floaty 5s ease-in-out infinite;
}

.float-card strong { display: block; font-size: 12px; font-weight: 800; line-height: 1.25; }
.float-card small { font-size: 9.5px; color: var(--muted); }

.float-icon {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: var(--success-bg);
    color: var(--success);
}

.float-icon.purple { background: var(--purple-100); color: var(--purple-500); }

.float-card-1 { right: 4%; top: 10%; animation-delay: .3s; }
.float-card-2 { left: 4%; top: 48%; animation-delay: 1.1s; }

@keyframes floaty {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-7px); }
}

.auth-hero-foot { position: relative; z-index: 2; font-size: 10.5px; color: rgba(255, 255, 255, .78); }

.auth-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 28px;
    background: #fff;
}

.auth-form-wrap { width: 100%; max-width: 376px; }

.auth-brand-mobile { display: none; align-items: center; gap: 10px; margin-bottom: 24px; }

.auth-form-wrap h1 {
    font-size: 30px;
    font-weight: 800;
    letter-spacing: -.045em;
    line-height: 1.15;
}

.auth-subtitle { font-size: 12.5px; color: var(--muted); margin: 6px 0 24px; line-height: 1.6; }
.auth-form .form-group { margin-bottom: 16px; }
.auth-form .form-control { height: 46px; border-radius: 12px; }
.auth-form .btn-lg { margin-top: 6px; }

.demo-credentials {
    margin-top: 20px;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--pink-50);
    border: 1px dashed var(--pink-200);
    text-align: center;
}

.demo-credentials span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--pink-500);
}

.demo-credentials p { font-size: 11.5px; color: #8a6d81; margin-top: 2px; }
.auth-copy { text-align: center; font-size: 10.5px; color: #c2b2c6; margin-top: 26px; }

/* ---------- 21. Gambar produk ---------- */
.product-thumb.has-image { padding: 0; overflow: hidden; background: #f7eef4; }
.product-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.product-thumb-lg { width: 92px; height: 92px; border-radius: 20px; font-size: 26px; }

.upload-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.upload-row .upload-field { flex: 1; min-width: 200px; }
.upload-row .form-group { margin-bottom: 0; }

/* ---------- 22. Responsive ---------- */
@media (max-width: 1280px) {
    .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 1180px) {
    .date-chip { display: none; }
    .pos-layout { grid-template-columns: minmax(0, 1fr) 340px; }
    .grid-2 { grid-template-columns: 1fr; }
    .detail-layout { grid-template-columns: 1fr; }
}

@media (max-width: 1024px) {
    :root { --sidebar-w: 248px; }
    .page-content { padding: 22px 22px 40px; }
    .topbar { padding: 14px 22px; }
    .grid-3 { grid-template-columns: 1fr 1fr; }
    .pos-layout { grid-template-columns: 1fr; }
    .pos-cart { position: static; max-height: none; }
    .pos-catalog .product-grid { grid-template-columns: repeat(auto-fill, minmax(145px, 1fr)); }
}

@media (max-width: 900px) {
    .app-main { margin-left: 0; }
    .sidebar {
        transform: translateX(-102%);
        transition: transform .28s var(--ease);
        width: 280px;
        box-shadow: 0 0 60px rgba(58, 37, 51, .2);
    }
    .sidebar.open { transform: none; }
    .sidebar-close { display: inline-grid; }
    .menu-toggle { display: inline-grid; }
    .sidebar-backdrop[hidden] { display: none; }

    .auth-shell { grid-template-columns: 1fr; }
    .auth-hero { display: none; }
    .auth-panel { min-height: 100vh; }
    .auth-brand-mobile { display: flex; }
}

@media (max-width: 760px) {
    .topbar { padding: 12px 16px; gap: 10px; }
    .page-heading h1 { font-size: 18px; }
    .page-heading p { display: none; }
    .user-chip-text { display: none; }
    .user-chip { padding: 3px; border-radius: 12px; }
    .page-content { padding: 18px 16px 34px; }
    .topbar-right { gap: 6px; }
    .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .stat-card { padding: 14px; gap: 10px; border-radius: 16px; }
    .stat-icon { width: 36px; height: 36px; border-radius: 11px; }
    .stat-value { font-size: 16px; }
    .stat-label { font-size: 10.5px; }
    .summary-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .grid-2-even, .grid-3 { grid-template-columns: 1fr; }
    .toolbar-filters { margin-left: 0; width: 100%; }
    .toolbar-filters .form-control { flex: 1; }
    .card-head { padding: 16px 16px 0; }
    .card-body { padding: 14px 16px 18px; }
    .table thead th, .table tbody td { padding-left: 14px; padding-right: 14px; }
    .greeting { padding: 16px; gap: 12px; flex-wrap: wrap; }
    .greeting-actions { margin-left: 0; width: 100%; }
    .greeting-actions .btn { flex: 1; }
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
    .profile-hero-body { padding: 0 18px; }
    .modal { padding: 14px; }
    .modal-dialog { max-height: calc(100vh - 28px); max-height: calc(100dvh - 28px); margin: 0 auto; }
    .modal-header, .modal-body, .modal-footer { padding-left: 16px; padding-right: 16px; }
    .modal-footer .btn { flex: 1; justify-content: center; }
    .modal-detail-row { gap: 12px; }
    .form-grid { grid-template-columns: 1fr; }
    .form-grid .span-2 { grid-column: span 1; }
    .toast-stack { right: 14px; bottom: 14px; left: 14px; max-width: none; }
    .section-head { flex-direction: column; align-items: flex-start; gap: 8px; }
    .app-footer { flex-wrap: wrap; padding-bottom: 18px; font-size: 10.5px; }
    .chart-wrap { overflow-x: auto; }
    .bar-chart { min-width: 420px; }
    .date-form { width: 100%; }
    .date-form .form-group { flex: 1; min-width: 130px; }
    .date-form .btn { flex: 1; }
}

@media (max-width: 420px) {
    .stats-grid { grid-template-columns: 1fr; }
    .summary-grid { grid-template-columns: 1fr; }
    .product-grid { grid-template-columns: 1fr 1fr; }
    .stat-card { align-items: center; }
    .cart-actions { grid-template-columns: 1fr; }
    .receipt-card { padding: 18px; }
}

/* ---------- 23. Transaksi (kasir) ---------- */
.pos-card { font-family: inherit; color: inherit; cursor: pointer; }
.pos-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pos-thumb.has-image::after { display: none; }

.cart-item-thumb.has-image { overflow: hidden; padding: 0; }
.cart-item-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cart-remove { font-size: 16px; line-height: 1; }

.receipt-actions { display: flex; flex-direction: column; gap: 9px; }
.receipt-actions .btn { width: 100%; }

/* ---------- 24. Print ---------- */
@media print {
    body { background: #fff; }
    body::before { display: none; }
    .sidebar, .topbar, .app-footer, .toast-stack, .modal, .modal-icon-templates,
    .no-print, .sidebar-backdrop { display: none !important; }
    .app-main { margin: 0 !important; }
    .page-content { padding: 0 !important; max-width: none; animation: none; }
    .receipt-card {
        border: 0;
        box-shadow: none;
        padding: 0;
        max-width: 100%;
    }
    .detail-layout { display: block; }
    .print-only { display: block !important; }
}

/* ---------- 25. Laporan penjualan ---------- */
.print-only { display: none; }

.report-print-head { margin-bottom: 16px; }
.report-print-head h2 { font-size: 18px; font-weight: 800; letter-spacing: -.03em; }
.report-print-head p { font-size: 11.5px; color: var(--muted); }

.report-table tfoot td {
    padding: 12px 20px;
    background: #fff9fc;
    border-top: 1px solid var(--line);
    font-size: 12px;
    font-weight: 800;
    color: var(--ink);
}

.report-table tfoot .num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- 26. Print laporan ---------- */
@media print {
    .page-actions,
    .report-toolbar { display: none !important; }
    .print-only { display: block !important; }
    .grid-2,
    .grid-2-even { grid-template-columns: 1fr !important; }
    .card { border: 0; box-shadow: none; }
    .card-head { padding: 0 0 10px; }
    .card-body { padding: 0; }
    .table thead th {
        background: #f6f6f6 !important;
        color: #333;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    .table thead th,
    .table tbody td,
    .report-table tfoot td {
        padding-left: 6px;
        padding-right: 6px;
        border-bottom: 1px solid #e5e5e5;
        color: #222;
    }
    .report-table tfoot td { background: #fafafa !important; }
    .summary-grid { gap: 8px; }
    .mini-stat { border: 1px solid #ddd; box-shadow: none; }
}

/* ---------- 27. Riwayat transaksi ---------- */
.history-filter-card { margin-bottom: 18px; }

.history-filter {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

.history-filter .toolbar-search { max-width: 380px; }
.history-filter .form-control { height: 40px; }

.history-dates {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    flex-wrap: wrap;
    margin-left: auto;
}

.history-dates .form-group { margin-bottom: 0; min-width: 145px; }

.history-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 620px;
}

.history-id { display: flex; flex-direction: column; line-height: 1.4; }
.history-id strong { font-size: 12.5px; font-weight: 800; color: var(--ink); }
.history-id span { font-size: 10.5px; color: var(--muted); }

.history-date { font-size: 11.5px; color: var(--ink-soft); }

.history-products {
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--ink-soft);
}

.history-table { min-width: 940px; }

@media (max-width: 760px) {
    .history-filter .toolbar-search { max-width: none; width: 100%; }
    .history-dates { margin-left: 0; width: 100%; }
    .history-dates .form-group { flex: 1; min-width: 130px; }
    .history-dates .btn { flex: 1; }
    .history-summary { grid-template-columns: 1fr; max-width: none; }
}
