/* =========================================
   VoucherPro - Mobile Android Style UI
   ========================================= */

:root {
    --primary:       #00897B;
    --primary-dark:  #00695C;
    --primary-light: #B2DFDB;
    --secondary:     #69F0AE;
    --success:       #4CAF50;
    --warning:       #FF9800;
    --danger:        #F44336;
    --info:          #2196F3;
    --dark:          #212121;
    --muted:         #757575;
    --bg:            #F5F5F5;
    --card:          #FFFFFF;
    --border:        #E0E0E0;
    --shadow:        0 2px 8px rgba(0,0,0,0.12);
    --shadow-lg:     0 4px 20px rgba(0,0,0,0.18);
    --radius:        12px;
    --radius-sm:     8px;
    --nav-height:    64px;
    --app-bar:       56px;
    --font:          'Roboto', -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--dark);
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
}

/* =========================================
   APP BAR
   ========================================= */
.app-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--app-bar);
    background: var(--primary);
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.app-bar-inner {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 8px;
    gap: 4px;
}

.app-bar-title {
    flex: 1;
    font-size: 18px;
    font-weight: 500;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 8px;
}

.app-bar-actions { display: flex; gap: 4px; }

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
}
.btn-icon:hover { background: rgba(255,255,255,0.15); }
.btn-icon .material-icons { font-size: 22px; }

/* =========================================
   MAIN CONTENT
   ========================================= */
.main-content {
    margin-top: var(--app-bar);
    padding-bottom: calc(var(--nav-height) + 16px);
    min-height: calc(100vh - var(--app-bar));
}

.page-content {
    padding: 12px;
    max-width: 600px;
    margin: 0 auto;
}

/* =========================================
   BOTTOM NAVIGATION
   ========================================= */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: space-around;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.12);
    z-index: 100;
    padding: 0 4px;
}

.bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: var(--muted);
    text-decoration: none;
    font-size: 10px;
    font-weight: 500;
    padding: 8px 0;
    transition: color 0.2s;
    min-width: 0;
}
.bottom-nav-item .material-icons { font-size: 22px; }
.bottom-nav-item.active { color: var(--primary); }
.bottom-nav-item.active .material-icons { font-size: 24px; }

.bottom-nav-fab {
    width: 52px;
    height: 52px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    box-shadow: var(--shadow-lg);
    margin-top: -16px;
    flex-shrink: 0;
    transition: background 0.2s, transform 0.2s;
}
.bottom-nav-fab:hover { background: var(--primary-dark); transform: scale(1.05); }
.bottom-nav-fab .material-icons { font-size: 26px; }

/* =========================================
   SIDE DRAWER
   ========================================= */
.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 200;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}
.drawer-overlay.open { opacity: 1; pointer-events: all; }

.drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background: #fff;
    z-index: 201;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.drawer.open { transform: translateX(0); }

.drawer-header {
    background: var(--primary);
    padding: 32px 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.drawer-user-info {}
.drawer-user-name { color: #fff; font-size: 16px; font-weight: 500; }
.drawer-user-role {
    color: var(--primary-light);
    font-size: 12px;
    margin-top: 2px;
    background: rgba(255,255,255,0.15);
    padding: 2px 8px;
    border-radius: 10px;
    display: inline-block;
}

.drawer-body { flex: 1; overflow-y: auto; padding: 8px 0; }

.drawer-menu { list-style: none; }
.drawer-group {
    padding: 8px 16px 4px;
    font-size: 11px;
    font-weight: 600;
    color: var(--muted);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-top: 8px;
}

.drawer-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 20px;
    color: var(--dark);
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: background 0.15s, color 0.15s;
    border-left: 3px solid transparent;
}
.drawer-item .material-icons { font-size: 20px; color: var(--muted); }
.drawer-item:hover { background: var(--bg); }
.drawer-item.active {
    background: rgba(0,137,123,0.1);
    color: var(--primary);
    border-left-color: var(--primary);
    font-weight: 500;
}
.drawer-item.active .material-icons { color: var(--primary); }
.drawer-item.text-danger { color: var(--danger); }
.drawer-item.text-danger .material-icons { color: var(--danger); }

/* =========================================
   CARDS
   ========================================= */
.card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 0;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    font-weight: 500;
    font-size: 15px;
    border-bottom: 1px solid var(--border);
    color: var(--dark);
}

.card-body { padding: 16px; }
.card-body.p-0 { padding: 0; }

.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.ml-auto { margin-left: auto; }

/* =========================================
   STATS
   ========================================= */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 12px;
}

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

.stat-card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    overflow: hidden;
}

.stat-card.stat-primary { border-left: 4px solid var(--primary); }
.stat-card.stat-success  { border-left: 4px solid var(--success); }
.stat-card.stat-blue     { border-left: 4px solid var(--info); }
.stat-card.stat-warning  { border-left: 4px solid var(--warning); }
.stat-card.stat-danger   { border-left: 4px solid var(--danger); }

.stat-icon .material-icons { font-size: 28px; color: var(--primary); opacity: 0.7; }
.stat-card.stat-success .stat-icon .material-icons  { color: var(--success); }
.stat-card.stat-blue    .stat-icon .material-icons  { color: var(--info); }
.stat-card.stat-warning .stat-icon .material-icons  { color: var(--warning); }
.stat-card.stat-danger  .stat-icon .material-icons  { color: var(--danger); }

.stat-value { font-size: 16px; font-weight: 700; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-label { font-size: 11px; color: var(--muted); margin-top: 2px; }

.stat-mini {
    background: var(--card);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}
.stat-mini .material-icons { font-size: 24px; }
.stat-mini.stat-blue .material-icons  { color: var(--info); }
.stat-mini.stat-orange .material-icons { color: var(--warning); }
.stat-mini.stat-green .material-icons  { color: var(--success); }
.stat-mini.stat-red .material-icons    { color: var(--danger); }
.stat-mini-val   { font-size: 20px; font-weight: 700; }
.stat-mini-label { font-size: 10px; color: var(--muted); }

/* =========================================
   SECTION TITLE
   ========================================= */
.section-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 4px 8px;
}

/* =========================================
   PAGE HEADER
   ========================================= */
.page-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 0 16px;
}
.page-header-info { flex: 1; min-width: 0; }
.page-header-title { font-size: 18px; font-weight: 700; color: var(--text); line-height: 1.2; }
.page-header-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }

/* =========================================
   MODAL
   ========================================= */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 200;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 16px;
    animation: fadeIn 0.2s ease;
}
.modal-box {
    background: var(--card);
    border-radius: var(--radius) var(--radius) var(--radius) var(--radius);
    padding: 20px;
    width: 100%;
    max-width: 480px;
    animation: slideUp 0.25s ease;
}
.modal-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text);
}
@keyframes slideUp {
    from { transform: translateY(40px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* =========================================
   SHORTCUTS
   ========================================= */
.shortcut-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 12px;
}
.shortcut-grid-2 { grid-template-columns: repeat(2, 1fr); }

.shortcut-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--dark);
    font-size: 12px;
    font-weight: 500;
    text-align: center;
    padding: 4px;
}

.shortcut-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow);
}
.shortcut-icon .material-icons { font-size: 26px; color: #fff; }

.bg-primary { background: var(--primary); }
.bg-blue    { background: var(--info); }
.bg-orange  { background: var(--warning); }
.bg-teal    { background: #00BCD4; }
.bg-purple  { background: #9C27B0; }
.bg-green   { background: var(--success); }
.bg-red     { background: var(--danger); }
.bg-muted   { background: var(--muted); }

/* =========================================
   PROVIDER CARD (Dashboard)
   ========================================= */
.provider-card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}
.provider-name  { font-weight: 500; font-size: 14px; }
.provider-code  { font-size: 12px; color: var(--muted); }
.saldo-amount   { font-weight: 700; font-size: 15px; }

/* =========================================
   LIST ITEMS
   ========================================= */
.list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}
.list-item:last-child { border-bottom: none; }

.list-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.list-icon .material-icons { font-size: 18px; color: #fff; }
.list-icon.bg-success  { background: var(--success); }
.list-icon.bg-danger   { background: var(--danger); }
.list-icon.bg-warning  { background: var(--warning); }
.list-icon.bg-primary  { background: var(--primary); }
.list-icon.bg-info     { background: var(--info); }
.list-icon.bg-muted    { background: var(--muted); }

.list-info  { flex: 1; min-width: 0; }
.list-title { font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-subtitle { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.list-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex-shrink: 0; }

.list-rank {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    flex-shrink: 0;
}
.list-rank.rank-1 { background: #FFD700; color: #fff; }
.list-rank.rank-2 { background: #C0C0C0; color: #fff; }
.list-rank.rank-3 { background: #CD7F32; color: #fff; }

/* =========================================
   VOUCHER CARDS
   ========================================= */
.voucher-list { display: flex; flex-direction: column; gap: 10px; }

.voucher-card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    border-left: 4px solid var(--border);
}
.voucher-card.border-danger { border-left-color: var(--danger); }
.voucher-card-kosong { border-left-color: var(--muted); }

.voucher-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px 8px;
}

.voucher-code {
    font-family: monospace;
    font-size: 15px;
    font-weight: 700;
    color: var(--dark);
    letter-spacing: 0.5px;
}
.voucher-provider-badge {
    font-size: 11px;
    color: var(--muted);
    margin-top: 2px;
}

.voucher-card-body { padding: 0 16px 8px; }

.voucher-paket {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--dark);
    margin-bottom: 6px;
}
.voucher-paket .material-icons { font-size: 16px; color: var(--primary); }

.voucher-info-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 4px;
}
.voucher-info-row .material-icons { font-size: 14px; }

.voucher-price-row {
    display: flex;
    gap: 16px;
    margin-top: 8px;
}
.voucher-price-row > div small { font-size: 10px; color: var(--muted); display: block; }
.price { font-weight: 600; font-size: 13px; }

.voucher-card-actions {
    display: flex;
    gap: 8px;
    padding: 8px 16px 12px;
    align-items: center;
}

/* =========================================
   BUTTONS
   ========================================= */
.btn-primary, .btn-outline, .btn-success, .btn-danger,
.btn-primary-full, .btn-outline-full, .btn-success-full, .btn-danger-full,
.btn-back, .btn-login {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
    padding: 10px 16px;
    line-height: 1;
}

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

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
}
.btn-outline:hover { background: rgba(0,137,123,0.06); }

.btn-danger-outline {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    color: var(--danger);
    border: 1.5px solid var(--danger);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    padding: 10px 16px;
    cursor: pointer;
    text-decoration: none;
}

.btn-primary-full, .btn-outline-full, .btn-success-full, .btn-danger-full {
    width: 100%;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
    font-size: 15px;
}
.btn-primary-full { background: var(--primary); color: #fff; }
.btn-primary-full:hover { background: var(--primary-dark); }
.btn-outline-full { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-success-full { background: var(--success); color: #fff; }
.btn-success-full:hover { background: #388E3C; }
.btn-danger-full  { background: var(--danger); color: #fff; }
.btn-danger-full:hover { background: #C62828; }

.btn-block { width: 100%; }
.btn-lg { padding: 14px 16px; font-size: 16px; border-radius: var(--radius-sm); }

.btn-action {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 7px 12px;
    border-radius: 20px;
    border: 1.5px solid var(--border);
    background: transparent;
    color: var(--muted);
    font-size: 13px;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}
.btn-action:hover { border-color: var(--primary); color: var(--primary); }
.btn-action .material-icons { font-size: 16px; }

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

.btn-mini {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1.5px solid var(--border);
    background: transparent;
    color: var(--muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}
.btn-mini:hover { border-color: var(--primary); color: var(--primary); }
.btn-mini .material-icons { font-size: 15px; }
.btn-mini-danger:hover { border-color: var(--danger); color: var(--danger); }

.btn-back {
    background: transparent;
    color: var(--muted);
    border: none;
    padding: 8px 0;
    font-size: 14px;
}

.btn-icon-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
}
.btn-icon-text .material-icons { font-size: 18px; }

.flex-1 { flex: 1; }

/* =========================================
   FAB
   ========================================= */
.fab {
    position: fixed;
    bottom: calc(var(--nav-height) + 16px);
    right: 20px;
    width: 56px;
    height: 56px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    box-shadow: var(--shadow-lg);
    z-index: 99;
    transition: all 0.2s;
}
.fab:hover { background: var(--primary-dark); transform: scale(1.05); }
.fab .material-icons { font-size: 28px; }

/* =========================================
   FORMS
   ========================================= */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 500; color: var(--muted); margin-bottom: 6px; }

.form-control {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 14px;
    color: var(--dark);
    background: #fff;
    transition: border-color 0.2s;
    outline: none;
}
.form-control:focus { border-color: var(--primary); }
textarea.form-control { resize: vertical; min-height: 80px; }
select.form-control { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24'%3E%3Cpath fill='%23757575' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }

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

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 8px;
    justify-content: flex-end;
}

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

.filter-date-form .form-group { margin-bottom: 12px; }

.input-currency {
    display: flex;
    align-items: center;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    transition: border-color 0.2s;
}
.input-currency:focus-within { border-color: var(--primary); }
.input-currency span {
    padding: 12px 12px;
    background: var(--bg);
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
    border-right: 1.5px solid var(--border);
    white-space: nowrap;
}
.input-currency .form-control { border: none; border-radius: 0; flex: 1; }
.input-currency .form-control:focus { border: none; }

/* =========================================
   FILTER BAR
   ========================================= */
.filter-bar {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 12px;
    margin-bottom: 10px;
}
.filter-form { display: flex; flex-direction: column; gap: 8px; }

.search-box {
    display: flex;
    align-items: center;
    border: 1.5px solid var(--border);
    border-radius: 24px;
    padding: 8px 14px;
    gap: 8px;
    transition: border-color 0.2s;
}
.search-box:focus-within { border-color: var(--primary); }
.search-box .material-icons { color: var(--muted); font-size: 18px; }
.search-box input { flex: 1; border: none; outline: none; font-size: 14px; background: transparent; }

.filter-form select {
    padding: 8px 14px;
    border: 1.5px solid var(--border);
    border-radius: 20px;
    font-size: 13px;
    color: var(--dark);
    background: #fff;
    outline: none;
    cursor: pointer;
}

.result-count {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 4px 8px;
    font-size: 13px;
    color: var(--muted);
}

/* =========================================
   RADIO CARDS
   ========================================= */
.radio-card {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.15s;
    gap: 12px;
}
.radio-card:last-child { border-bottom: none; }
.radio-card:hover { background: var(--bg); }
.radio-card input[type=radio] { display: none; }
.radio-card-content { flex: 1; }
.radio-card-title { font-size: 14px; font-weight: 500; }
.radio-card-sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.radio-check { color: transparent; transition: color 0.2s; font-size: 20px; }
.radio-card:has(input:checked) { background: rgba(0,137,123,0.06); }
.radio-card:has(input:checked) .radio-check { color: var(--primary); }
.radio-card:has(input:checked) .radio-card-title { color: var(--primary); font-weight: 600; }

/* =========================================
   PAYMENT GRID
   ========================================= */
.payment-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.payment-option { cursor: pointer; }
.payment-option input { display: none; }
.payment-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 12px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
    transition: all 0.2s;
}
.payment-content .material-icons { font-size: 24px; }
.payment-option:has(input:checked) .payment-content {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(0,137,123,0.06);
}

/* =========================================
   PROFIT PREVIEW
   ========================================= */
.profit-preview { border: 2px solid var(--primary-light); }

.profit-indicator {
    padding: 10px 14px;
    background: rgba(0,137,123,0.06);
    border-radius: var(--radius-sm);
    font-size: 14px;
    margin-bottom: 16px;
}

/* =========================================
   DETAIL ROWS
   ========================================= */
.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--bg);
    font-size: 14px;
    gap: 12px;
}
.detail-row:last-child { border-bottom: none; }
.detail-row span { color: var(--muted); flex-shrink: 0; }
.detail-row strong { text-align: right; }
.detail-row-total { font-weight: 700; padding-top: 12px; margin-top: 4px; border-top: 1.5px solid var(--border); border-bottom: none; }

.info-row { display: flex; justify-content: space-between; align-items: center; padding: 6px 0; font-size: 14px; }
.info-row span { color: var(--muted); }

/* =========================================
   ALERTS & BADGES
   ========================================= */
.alert {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    margin-bottom: 12px;
}
.alert .material-icons { font-size: 20px; flex-shrink: 0; }
.alert-error   { background: #FFEBEE; color: var(--danger); }
.alert-warning { background: #FFF8E1; color: #E65100; }
.alert-success { background: #E8F5E9; color: var(--success); }

.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}
.badge-primary   { background: rgba(0,137,123,0.15); color: var(--primary); }
.badge-success   { background: rgba(76,175,80,0.15);  color: var(--success); }
.badge-warning   { background: rgba(255,152,0,0.15);  color: #E65100; }
.badge-danger    { background: rgba(244,67,54,0.15);  color: var(--danger); }
.badge-info      { background: rgba(33,150,243,0.15); color: var(--info); }
.badge-secondary { background: var(--bg); color: var(--muted); border: 1px solid var(--border); }
.badge-dark      { background: #424242; color: #fff; }

/* =========================================
   SNACKBAR
   ========================================= */
.snackbar {
    position: fixed;
    bottom: calc(var(--nav-height) + 12px);
    left: 12px;
    right: 12px;
    max-width: 500px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    z-index: 999;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
    box-shadow: var(--shadow-lg);
}
.snackbar.show { transform: translateY(0); opacity: 1; }
.snackbar .material-icons { font-size: 20px; flex-shrink: 0; }
.snackbar-success { background: #1B5E20; color: #fff; }
.snackbar-error   { background: #B71C1C; color: #fff; }

/* =========================================
   SCAN
   ========================================= */
.scan-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--primary);
    color: #fff;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-bottom: 12px;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
}
.scan-banner .material-icons:last-child { margin-left: auto; }

.scan-hint { text-align: center; color: var(--muted); font-size: 13px; margin-top: 12px; }
.scan-result { text-align: center; padding: 20px; }
.scan-success { color: var(--success); }
.scan-success .material-icons { font-size: 48px; }
.scan-error { text-align: center; color: var(--muted); padding: 20px; }
.scan-error .material-icons { font-size: 48px; display: block; margin: 0 auto 8px; }
.hidden { display: none !important; }

/* =========================================
   LOADING
   ========================================= */
.loading-state {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 20px 16px;
    color: var(--muted);
    font-size: 14px;
    justify-content: center;
}
.spin { animation: spin 1s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* =========================================
   EMPTY STATE
   ========================================= */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    text-align: center;
    gap: 12px;
    color: var(--muted);
}
.empty-state .material-icons { font-size: 64px; opacity: 0.3; }
.empty-state p { font-size: 15px; color: var(--muted); }

/* =========================================
   STRUK / RECEIPT
   ========================================= */
.struk-container {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    max-width: 380px;
    margin: 0 auto;
    font-family: 'Courier New', monospace;
    overflow: hidden;
}

.struk-header {
    background: var(--primary);
    color: #fff;
    text-align: center;
    padding: 20px 16px;
}
.struk-logo .material-icons { font-size: 36px; }
.struk-toko   { font-size: 16px; font-weight: 700; margin-top: 8px; }
.struk-alamat { font-size: 12px; opacity: 0.85; }
.struk-telp   { font-size: 12px; opacity: 0.85; }

.struk-body { padding: 16px; }
.struk-row { display: flex; justify-content: space-between; font-size: 13px; padding: 3px 0; gap: 8px; }
.struk-row span:first-child { color: var(--muted); }
.struk-total { font-weight: 700; font-size: 15px; padding: 8px 0; }
.struk-divider { text-align: center; color: var(--muted); font-size: 12px; letter-spacing: 1px; padding: 4px 0; }

.struk-footer { text-align: center; padding: 12px 16px 20px; border-top: 1px dashed var(--border); }
.struk-qr { display: flex; justify-content: center; margin-bottom: 12px; }
.struk-thanks { font-size: 12px; color: var(--muted); }
.struk-powered { font-size: 10px; color: var(--border); margin-top: 6px; }

/* =========================================
   INFO CARD
   ========================================= */
.info-card {
    background: rgba(0,137,123,0.06);
    border: 1.5px solid var(--primary-light);
    border-radius: var(--radius-sm);
    padding: 14px;
    font-size: 13px;
    color: var(--muted);
    line-height: 1.6;
}
.info-card p { margin-bottom: 6px; }
.info-card-title { font-weight: 600; color: var(--primary); display: flex; align-items: center; gap: 6px; margin-bottom: 10px; }
.info-card-title .material-icons { font-size: 18px; }

/* =========================================
   BACK BAR
   ========================================= */
.back-bar { padding: 12px 0 4px; }

.action-group { display: flex; flex-direction: column; gap: 0; }

/* =========================================
   SALDO PROVIDER
   ========================================= */
.saldo-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}
.saldo-row:last-child { border-bottom: none; }
.saldo-provider {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}
.saldo-provider .material-icons { color: var(--primary); }

.provider-saldo-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.provider-name-lg { font-size: 16px; font-weight: 600; }
.saldo-amount-lg { font-size: 20px; font-weight: 700; }
.provider-actions { display: flex; gap: 8px; }
.text-right { text-align: right; }

/* =========================================
   PROFIL
   ========================================= */
.profil-header {
    text-align: center;
    padding: 24px 16px 20px;
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 12px;
}
.profil-avatar .material-icons { font-size: 72px; color: var(--primary); }
.profil-nama { font-size: 20px; font-weight: 700; margin-top: 8px; }
.profil-role {
    display: inline-block;
    background: var(--primary);
    color: #fff;
    padding: 3px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin: 6px 0;
}
.profil-username { font-size: 13px; color: var(--muted); }

/* =========================================
   QR CODE
   ========================================= */
.qr-container { display: flex; flex-direction: column; align-items: center; padding: 20px; }
#qrcode { padding: 16px; background: #fff; border-radius: var(--radius-sm); border: 2px solid var(--border); }
.qr-code-text { font-family: monospace; font-size: 16px; font-weight: 700; margin-top: 12px; }
.qr-paket { font-size: 13px; color: var(--muted); margin-top: 4px; }
.qr-info { text-align: center; }

/* =========================================
   MISC
   ========================================= */
.text-primary { color: var(--primary) !important; }
.text-success { color: var(--success) !important; }
.text-danger  { color: var(--danger) !important; }
.text-warning { color: var(--warning) !important; }
.text-muted   { color: var(--muted) !important; }
.text-center  { text-align: center; }
.text-lg      { font-size: 18px; font-weight: 700; }

.price-row-inline {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    margin-top: 4px;
}

.profit-small { font-size: 12px; font-weight: 600; }

/* =========================================
   LOGIN PAGE
   ========================================= */
.login-body {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, #26A69A 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.login-container {
    width: 100%;
    max-width: 380px;
}

.login-header { text-align: center; margin-bottom: 32px; color: #fff; }
.login-logo {
    width: 80px;
    height: 80px;
    background: rgba(255,255,255,0.2);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    backdrop-filter: blur(10px);
}
.login-logo .material-icons { font-size: 44px; color: #fff; }
.login-title { font-size: 28px; font-weight: 700; }
.login-subtitle { font-size: 14px; opacity: 0.85; margin-top: 6px; }

.login-card {
    background: rgba(255,255,255,0.95);
    border-radius: 20px;
    padding: 28px 24px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    backdrop-filter: blur(10px);
}

.login-form .input-field {
    position: relative;
    margin-bottom: 16px;
}
.login-form .input-field .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 20px;
    pointer-events: none;
}
.login-form .input-field input {
    width: 100%;
    padding: 14px 14px 14px 46px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s;
}
.login-form .input-field input:focus { border-color: var(--primary); }
.btn-toggle-pass {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--muted);
    cursor: pointer;
    padding: 4px;
}

.btn-login {
    width: 100%;
    padding: 14px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 8px;
    transition: background 0.2s;
}
.btn-login:hover { background: var(--primary-dark); }

.login-footer { text-align: center; color: rgba(255,255,255,0.7); font-size: 13px; margin-top: 24px; }
.login-version { font-size: 11px; margin-top: 8px; opacity: 0.6; }

/* =========================================
   KARYAWAN & SHIFT
   ========================================= */
.karyawan-chip {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 5px 10px 5px 5px;
    border-radius: 20px;
    border: 1.5px solid var(--border);
}
.chip-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
}

/* =========================================
   PRINT STYLES
   ========================================= */
@media print {
    .app-bar, .bottom-nav, .fab, .no-print, .action-group, .back-bar { display: none !important; }
    .main-content { margin-top: 0 !important; padding-bottom: 0 !important; }
    body { background: #fff; }
    .struk-container { box-shadow: none; max-width: 100%; }
}

/* =========================================
   RESPONSIVE
   ========================================= */
@media (min-width: 600px) {
    .page-content { padding: 16px; }
    .stats-grid { gap: 14px; }
    .drawer { width: 300px; }
}
