/* ─── Reset ─── */
[x-cloak] {
    display: none !important;
}

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

/* ─── Design LIGHT ─── */
:root {
    --bg: #f0f4f8;
    --bg2: #e8edf5;
    --card: #ffffff;
    --card2: #fcfcfc;
    --raised: #fafafa;
    --hover: rgba(0, 0, 0, 0.04);
    --border: rgba(0, 0, 0, 0.08);
    --border2: rgba(0, 0, 0, 0.05);
    --text: #0f172a;
    --text2: #475569;
    --text3: #94a3b8;
    --brand: #2563eb;
    --brand2: #1d4ed8;
    --brand3: #3b82f6;
    --bglow: rgba(37, 99, 235, 0.2);
    --bglow2: rgba(37, 99, 235, 0.08);
    --bbg: rgba(37, 99, 235, 0.08);
    --bborder: rgba(37, 99, 235, 0.2);
    --accent: #4f46e5;
    --accent-bg: rgba(79, 70, 229, 0.08);
    --warn: #f59e0b;
    --warn-bg: rgba(245, 158, 11, 0.1);
    --danger: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.09);
    --safe: #22c55e;
    --safe-bg: rgba(34, 197, 94, 0.09);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.14);
    --sidebar-w: 240px;
    --radius: 14px;
    --radius-sm: 10px;
    --radius-xs: 7px;
    --space: 1rem;
    --space-sm: 0.75rem;
    --space-xs: 0.5rem;
}

/* ─── Design DARK ─── */
.dark {
    --bg: #060c18;
    --bg2: #0c1526;
    --card: #0f1c30;
    --card2: #162035;
    --raised: #1c2a42;
    --hover: rgba(255, 255, 255, 0.04);
    --border: rgba(255, 255, 255, 0.08);
    --border2: rgba(255, 255, 255, 0.05);
    --text: #e8f0fe;
    --text2: #94a3b8;
    --text3: #4a5568;
    --brand: #3b82f6;
    --brand2: #2563eb;
    --brand3: #60a5fa;
    --bglow: rgba(59, 130, 246, 0.28);
    --bglow2: rgba(59, 130, 246, 0.12);
    --bbg: rgba(59, 130, 246, 0.1);
    --bborder: rgba(59, 130, 246, 0.25);
    --accent: #6366f1;
    --accent-bg: rgba(99, 102, 241, 0.12);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.55);
}

/* ─── Base ─── */
html,
body {
    height: 100%;
    background: var(--bg);
    color: var(--text);
    font-family: "Plus Jakarta Sans", sans-serif;
    transition:
        background 0.3s,
        color 0.25s;
    -webkit-font-smoothing: antialiased;
    touch-action: pan-x pan-y;
}

::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 99px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text3);
}

/* ─── Layout atoms ─── */
.flex-col {
    display: flex;
    flex-direction: column;
}

.flex-row {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.gap-1 {
    gap: 0.25rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 0.75rem;
}

.gap-4 {
    gap: 1rem;
}

.gap-5 {
    gap: 1.25rem;
}

.w-full {
    width: 100%;
}

.amount {
    font-family: "JetBrains Mono", monospace;
    font-weight: 600;
}

.emoji {
    font-family: "Noto Color Emoji", sans-serif !important;
}

/* ─── Cards ─── */
.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.card2 {
    background: var(--card2);
    border: 1px solid var(--border2);
    border-radius: var(--radius-sm);
}

.raised {
    background: var(--raised);
    border: 1px solid var(--border2);
    border-radius: var(--radius-sm);
    transition:
        border-color 0.15s,
        box-shadow 0.15s;
}

.raised:hover {
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.glass {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(12px);
    border-radius: var(--radius);
}

.light .glass {
    background: rgba(255, 255, 255, 0.7);
    border-color: rgba(0, 0, 0, 0.08);
}

/* ─── Buttons ─── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    font-family: inherit;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: all 0.18s;
    white-space: nowrap;
}

.btn-brand {
    background: linear-gradient(135deg, var(--brand), var(--brand2));
    color: #fff;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 20px var(--bglow);
}

.btn-brand:hover:not(:disabled) {
    box-shadow: 0 6px 28px var(--bglow);
    transform: translateY(-1px);
    filter: brightness(1.05);
}

.btn-brand:active:not(:disabled) {
    transform: translateY(0);
    filter: brightness(0.98);
}

.btn-brand:disabled {
    opacity: 0.4;
    box-shadow: none;
    cursor: not-allowed;
    transform: none;
}

.btn-ghost {
    background: var(--raised);
    border: 1px solid var(--border);
    color: var(--text2);
    border-radius: var(--radius-sm);
}

.btn-ghost:hover:not(:disabled) {
    background: var(--hover);
    color: var(--text);
    border-color: var(--border);
}

.btn-ghost:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-danger {
    background: var(--danger-bg);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: var(--danger);
    border-radius: var(--radius-xs);
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.35);
}

.btn-success {
    background: var(--safe-bg);
    border: 1px solid rgba(34, 197, 94, 0.2);
    color: var(--safe);
    border-radius: var(--radius-xs);
}

.btn-success:hover {
    background: rgba(34, 197, 94, 0.15);
    border-color: rgba(34, 197, 94, 0.35);
}

.btn-warning {
    background: var(--warn-bg);
    border: 1px solid rgba(245, 158, 11, 0.2);
    color: var(--warn);
    border-radius: var(--radius-xs);
}

.btn-warning:hover {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.35);
}

.btn-icon {
    background: var(--raised);
    border: 1px solid var(--border);
    border-radius: var(--radius-xs);
    color: var(--text2);
    cursor: pointer;
    transition: all 0.15s;
    padding: 0.35rem;
}

.btn-icon:hover {
    background: var(--hover);
    color: var(--text);
}

/* Size modifiers */
.btn-lg {
    padding: 0.8rem 1.5rem;
    font-size: 0.9rem;
    border-radius: var(--radius-sm);
}

.btn-md {
    padding: 0.65rem 1.1rem;
    font-size: 0.845rem;
    border-radius: var(--radius-sm);
}

.btn-sm {
    padding: 0.42rem 0.8rem;
    font-size: 0.78rem;
    border-radius: var(--radius-xs);
}

.btn-xs {
    padding: 0.28rem 0.55rem;
    font-size: 0.7rem;
    border-radius: var(--radius-xs);
}

.btn-full {
    width: 100%;
}

/* ─── Form fields ─── */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.form-label {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text2);
    letter-spacing: 0.01em;
}

.form-label span {
    color: var(--danger);
    margin-left: 2px;
}

.ys-input {
    background: var(--raised);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    width: 100%;
    padding: 0.7rem 1rem;
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 500;
    transition:
        border-color 0.18s,
        box-shadow 0.18s,
        background 0.18s;
    appearance: none;
}

.ys-input:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--bglow2);
    background: var(--card2);
}

.ys-input::placeholder {
    color: var(--text3);
}

.ys-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

select.ys-input {
    cursor: pointer;
    background-image: none;
}

textarea.ys-input {
    resize: vertical;
    min-height: 80px;
}

.input-prefix {
    display: flex;
    align-items: center;
    background: var(--raised);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    transition:
        border-color 0.18s,
        box-shadow 0.18s;
}

.input-prefix:focus-within {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--bglow2);
}

.input-prefix span {
    padding: 0.7rem 0.85rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text3);
    border-right: 1.5px solid var(--border);
    background: var(--card2);
    white-space: nowrap;
}

.input-prefix input {
    border: none;
    background: transparent;
    flex: 1;
    padding: 0.7rem 0.9rem;
    color: var(--text);
    font-family: inherit;
    font-size: 0.875rem;
}

.input-prefix input:focus {
    outline: none;
}

.input-prefix input::placeholder {
    color: var(--text3);
}

/* Checkbox */
.checkbox-row {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    cursor: pointer;
    padding: 0.65rem 0.9rem;
    background: var(--raised);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    transition: border-color 0.15s;
}

.checkbox-row:hover {
    border-color: var(--brand);
}

.checkbox-row input[type="checkbox"] {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    accent-color: var(--brand);
    cursor: pointer;
}

.checkbox-row span {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text2);
}

/* Tab group */
.tab-group {
    display: flex;
    gap: 0.5rem;
    padding: 0.35rem;
    background: var(--raised);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.tab-btn {
    flex: 1;
    padding: 0.5rem 0.75rem;
    font-size: 0.78rem;
    font-weight: 700;
    border: none;
    border-radius: var(--radius-xs);
    cursor: pointer;
    transition: all 0.15s;
    color: var(--text3);
    background: transparent;
    font-family: inherit;
}

.tab-btn.active {
    background: var(--card);
    color: var(--text);
    box-shadow: var(--shadow-sm);
}

.tab-btn:hover:not(.active) {
    background: var(--hover);
    color: var(--text2);
}

/* ─── Photo upload ─── */
.photo-drop {
    position: relative;
    border: 2px dashed var(--border);
    border-radius: var(--radius-sm);
    transition:
        border-color 0.18s,
        background 0.18s;
    cursor: pointer;
    overflow: hidden;
}

.photo-drop:hover,
.photo-drop.dragover {
    border-color: var(--brand);
    background: var(--bbg);
}

.photo-drop input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.photo-preview-img {
    width: auto;
    height: 100%;
    object-fit: cover;
    border-radius: calc(var(--radius-sm) - 2px);
    margin: 0 auto;
}

/* ─── Badges ─── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.62rem;
    font-weight: 800;
    padding: 0.18rem 0.55rem;
    border-radius: 99px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    white-space: nowrap;
}

.badge-green {
    background: rgba(16, 185, 129, 0.12);
    color: var(--brand3);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.badge-red {
    background: rgba(239, 68, 68, 0.1);
    color: #fc8181;
    border: 1px solid rgba(239, 68, 68, 0.18);
}

.badge-indigo {
    background: rgba(99, 102, 241, 0.1);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.18);
}

.badge-amber {
    background: rgba(245, 158, 11, 0.1);
    color: #fcd34d;
    border: 1px solid rgba(245, 158, 11, 0.18);
}

.badge-admin {
    background: rgba(139, 92, 246, 0.1);
    color: #c4b5fd;
    border: 1px solid rgba(139, 92, 246, 0.18);
}

/* ─── Status dot ─── */
.dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.dot-on {
    background: var(--brand);
    box-shadow: 0 0 6px var(--brand);
}

.dot-off {
    background: var(--warn);
    box-shadow: 0 0 6px var(--warn);
}

/* ─── Sidebar ─── */
.sidebar {
    width: var(--sidebar-w);
    flex-shrink: 0;
    background: var(--card);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition:
        background 0.3s,
        border-color 0.25s;
}

.snav-section {
    font-size: 0.6rem;
    font-weight: 800;
    color: var(--text3);
    padding: 0.9rem 0.9rem 0.3rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.snav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.7rem 0.9rem;
    border-radius: var(--radius-sm);
    font-size: 0.855rem;
    font-weight: 600;
    border: 1px solid transparent;
    cursor: pointer;
    background: none;
    color: var(--text2);
    transition: all 0.15s;
    text-align: left;
    margin-bottom: 1px;
    font-family: inherit;
}

.snav-item:hover:not(.active) {
    background: var(--hover);
    color: var(--text);
}

.snav-item.active {
    background: var(--bbg);
    color: var(--brand);
    border-color: var(--bborder);
    box-shadow: inset 3px 0 0 var(--brand);
}

.snav-icon {
    font-family: "Noto Color Emoji", sans-serif;
    font-size: 1.3rem;
    line-height: 1;
    flex-shrink: 0;
    width: 25px;
    text-align: center;
}

.snav-badge {
    margin-left: auto;
    background: var(--brand);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 800;
    padding: 0.1rem 0.45rem;
    border-radius: 99px;
    min-width: 18px;
    text-align: center;
}

/* ─── Bottom nav (mobile) ─── */
.bnav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 0.45rem 0.6rem;
    border-radius: var(--radius-sm);
    font-size: 0.58rem;
    font-weight: 700;
    border: none;
    background: none;
    cursor: pointer;
    color: var(--text3);
    transition: all 0.15s;
    font-family: inherit;
    position: relative;
    min-width: 52px;
}

.bnav-item.active {
    color: var(--brand);
}

.bnav-item.active::after {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2.5px;
    background: var(--brand);
    border-radius: 99px;
}

.bnav-icon {
    font-family: "Noto Color Emoji", sans-serif;
    font-size: 1.2rem;
    line-height: 1;
}

/* ─── Product card ─── */
.pcard {
    background: var(--card2);
    border: 1.5px solid var(--border2);
    border-radius: var(--radius);
    padding: 0.5rem;
    cursor: pointer;
    transition: all 0.18s;
    position: relative;
    overflow: hidden;
}

.pcard::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 60%, var(--bglow2));
    opacity: 0;
    transition: opacity 0.25s;
    pointer-events: none;
}

.pcard:hover {
    border-color: var(--bborder);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.pcard:hover::before {
    opacity: 1;
}

.pcard:active {
    transform: translateY(-1px);
}

.pcard-has-items {
    border-color: var(--bborder);
    box-shadow:
        0 0 0 1px var(--bborder),
        0 4px 16px var(--bglow2);
}

/* ─── Category pill ─── */
.cpill {
    border-radius: 70px;
    border: 1.5px solid var(--border);
    padding: 0.2rem 0.5rem;
    font-size: 0.78rem;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
    cursor: pointer;
    background: none;
    color: var(--text3);
    transition: all 0.15s;
    font-family: inherit;
}

.cpill:hover:not(.active) {
    background: var(--hover);
    color: var(--text2);
    border-color: var(--border);
}

.cpill.active {
    background: var(--bbg);
    border-color: var(--bborder);
    color: var(--brand);
    font-weight: 700;
}

/* ─── Theme toggle ─── */
.ttog {
    width: 42px;
    height: 24px;
    border-radius: 99px;
    flex-shrink: 0;
    background: var(--raised);
    border: 1.5px solid var(--border);
    position: relative;
    cursor: pointer;
    transition: background 0.2s;
}

.ttog::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--text3);
    transition:
        transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1),
        background 0.2s;
}

.light .ttog::after {
    transform: translateX(18px);
    background: var(--brand);
}

/* ─── Modal / overlay ─── */
.modal-bg {
    background: rgba(2, 8, 20, 0.75);
    backdrop-filter: blur(8px);
}

.modal-sheet {
    background: var(--card);
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -8px 48px rgba(0, 0, 0, 0.5);
}

.modal-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
}

.handle {
    width: 36px;
    height: 4px;
    border-radius: 99px;
    background: var(--border);
    margin: 0 auto;
}

/* ─── Topbar ─── */
.topbar {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    padding: 0.55rem 1rem;
    gap: 0.75rem;
    background: var(--card);
    border-bottom: 1px solid var(--border);
    z-index: 20;
}

/* ─── Saldo chip ─── */
.saldo-chip {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--bbg);
    border: 1.5px solid var(--bborder);
    border-radius: 99px;
    padding: 0.28rem 0.85rem;
    cursor: pointer;
    transition: all 0.15s;
}

.saldo-chip:hover {
    background: rgba(16, 185, 129, 0.16);
    border-color: var(--brand);
}

/* ─── Cart item ─── */
.cart-item {
    background: var(--raised);
    border: 1px solid var(--border2);
    border-radius: var(--radius-sm);
    transition: border-color 0.12s;
}

.cart-item:hover {
    border-color: var(--border);
}

/* ─── Qty btn ─── */
.qty-btn {
    width: 26px;
    height: 26px;
    border-radius: var(--radius-xs);
    background: var(--card2);
    border: 1px solid var(--border);
    font-size: 0.82rem;
    cursor: pointer;
    color: var(--text);
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.12s;
    font-family: inherit;
}

.qty-btn:hover {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
}

.qty-btn-del {
    width: 26px;
    height: 26px;
    border-radius: var(--radius-xs);
    background: var(--danger-bg);
    border: 1px solid rgba(239, 68, 68, 0.15);
    font-size: 0.82rem;
    cursor: pointer;
    color: var(--danger);
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.12s;
    font-family: inherit;
}

.qty-btn-del:hover {
    background: rgba(239, 68, 68, 0.18);
    border-color: rgba(239, 68, 68, 0.3);
}

/* ─── Summary stat card ─── */
.stat-card {
    background: var(--card2);
    border: 1px solid var(--border2);
    border-radius: var(--radius-sm);
    padding: 0.85rem 1rem;
    text-align: center;
}

/* ─── A2HS banner ─── */
.a2hs-wrap {
    background: linear-gradient(135deg, var(--card), var(--card2));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.3s ease-out;
}

/* ─── Animations ─── */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

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

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateX(8px);
    }

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

@keyframes pulse {
    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }
}

.toast-in {
    animation: slideUp 0.25s ease-out;
}

.page-in {
    animation: fadeSlide 0.22s ease-out;
}

/* ─── Responsive helpers ─── */
.sidebar {
    display: none;
}

.bnav {
    display: flex;
}

@media (min-width: 768px) {
    .sidebar {
        display: flex;
    }

    .bnav {
        display: none;
    }
}

.cart-panel {
    display: none;
}

@media (min-width: 1024px) {
    .cart-panel {
        display: flex;
        flex-direction: column;
    }
}

.cart-fab {
    display: flex;
    flex-direction: column;
}

@media (min-width: 1024px) {
    .cart-fab {
        display: none;
    }
}

.hide-desktop {
    display: block;
}

@media (min-width: 768px) {
    .hide-desktop {
        display: none !important;
    }
}

.pb-safe {
    padding-bottom: env(safe-area-inset-bottom, 0);
}

@media (max-width: 640px) {
    .card.x-auth {
        border: none;
        border-radius: 0;
    }

    .card.x-slider {
        border: none;
        border-radius: 0;
        background: #0556ce;
    }
}

/* ─── Spinner ─── */
.spin {
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ─── Pin input ─── */
.pin-input {
    letter-spacing: 0.6rem;
    text-align: center;
    font-family: "JetBrains Mono", monospace;
    font-size: 1.5rem;
    font-weight: 700;
}

/* ─── Section divider ─── */
.section-divider {
    border-top: 1px solid var(--border2);
    margin: 0.75rem 0;
}

/* ─── Payment method button ─── */
.pay-method {
    flex: 1;
    padding: 0.65rem 0.5rem;
    font-size: 0.78rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.15s;
    text-transform: uppercase;
    font-family: "Noto Color Emoji", sans-serif;
    border: 1.5px solid var(--border);
    background: transparent;
    color: var(--text2);
}

.pay-method.active {
    background: var(--bbg);
    border-color: var(--bborder);
    color: var(--brand);
    box-shadow: 0 0 12px var(--bglow2);
}

.pay-method:hover:not(.active) {
    background: var(--hover);
    color: var(--text);
}

/* ─── Role badge ─── */
.role-badge {
    font-size: 0.58rem;
    font-weight: 800;
    padding: 0.15rem 0.55rem;
    border-radius: 99px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.role-admin {
    background: rgba(139, 92, 246, 0.12);
    color: #c4b5fd;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

.role-cashier {
    background: var(--bbg);
    color: var(--brand);
    border: 1px solid var(--bborder);
}

/* ─── Gradient accent header ─── */
.grad-header {
    background: linear-gradient(135deg, var(--bg2) 0%, var(--card) 100%);
    border-bottom: 1px solid var(--border);
}

/* ─── Number input ─── */
input[type="number"] {
    -moz-appearance: textfield;
}

input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ─── Preset pill ─── */
.preset {
    padding: 0.32rem 0.75rem;
    border-radius: 99px;
    border: 1.5px solid var(--border);
    background: transparent;
    font-size: 0.73rem;
    font-weight: 700;
    cursor: pointer;
    color: var(--text2);
    transition: all 0.15s;
}

.preset:hover,
.preset.active {
    border: 1.5px solid var(--brand);
    background: var(--bbg);
    color: var(--brand);
}

/* ─── No data found ─── */
.no-data {
    text-align: center;
    color: var(--text3);
    padding: 4rem 1rem;
}

.no-data .emoji {
    font-size: 3.5rem;
    margin-bottom: 0.75rem;
}

.no-data p {
    font-size: 0.88rem;
    font-weight: 500;
}

/* ─── Prose styles ─── */
.prose {
    --prose-text-color: #334155;
    --prose-font-size: 1rem;
    --prose-line-height: 1.75;
    --prose-heading-color: #0f172a;
    --prose-heading-weight: 700;
    color: var(--prose-text-color);
    font-size: var(--prose-font-size);
    line-height: var(--prose-line-height);
    max-width: 65ch;
    margin: 0 auto;
}

.prose h1,
.prose h2,
.prose h3,
.prose h4,
.prose h5,
.prose h6 {
    color: var(--prose-heading-color);
    font-weight: var(--prose-heading-weight);
    margin-top: 0.5rem;
    margin-bottom: 1rem;
}

.prose h1 {
    font-size: 1.8rem;
    line-height: 1.1;
}

.prose h2 {
    font-size: 1.5rem;
    line-height: 1.2;
}

.prose h3 {
    font-size: 1.3rem;
    line-height: 1.3;
}

.prose h4 {
    font-size: 1.2rem;
    line-height: 1.5;
}

.prose h5 {
    font-size: 1.1rem;
    line-height: 1.6;
}

.prose h6 {
    font-size: 1rem;
    line-height: 1.6;
}

.prose p {
    margin-bottom: 1.25rem;
}

.prose hr {
    margin: 0;
}

/* ─── Print styles ─── */
.print {
    font-family: "Courier New", monospace;
    font-size: 12px;
    width: 285px;
    padding: 10px;
    color: #000000;
    background: #ffffff;
}

.print h1 {
    font-size: 15px;
    text-align: center;
    margin-bottom: 2px;
}

.print small {
    display: block;
    font-size: 10px;
}

.print .center {
    text-align: center;
}

.print .divider {
    border-top: 1px dashed #000;
    margin: 5px 0;
}

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

.print td {
    vertical-align: top;
    padding: 2px 0;
}

.print .qty {
    width: 30px;
    text-align: center;
}

.print .price {
    width: 70px;
    text-align: right;
}

.print .total-row td {
    font-weight: bold;
}

.print .split {
    text-align: center;
    font-size: 11px;
    margin: 4px 0;
}

.print .footer {
    text-align: center;
    font-size: 11px;
    margin-top: 6px;
}

@media print {
    body {
        width: 100%;
    }

    button {
        display: none;
    }
}
