/* Custom CSS for DonePay PPOB Mobile UI */

:root {
    --primary: #2563eb;
    --primary-light: #eff6ff;
    --primary-dark: #1d4ed8;
    --secondary: #4f46e5;
    --accent: #f59e0b;
    --success: #10b981;
    --success-light: #ecfdf5;
    --danger: #ef4444;
    --danger-light: #fef2f2;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-600: #475569;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    --card-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.08), 0 8px 10px -6px rgba(37, 99, 235, 0.05);
    --nav-shadow: 0 -4px 20px -2px rgba(15, 23, 42, 0.06);
    --btn-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--gray-900);
    color: var(--gray-800);
    display: flex;
    justify-content: center;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Wrapper for simulated mobile device on desktop */
.app-container {
    width: 100%;
    max-width: 480px;
    background-color: var(--gray-50);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    padding-bottom: 80px; /* Space for bottom nav */
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.25);
}

/* Hide scrollbars but keep functionality */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* ==========================================================================
   Header Component
   ========================================================================== */
.app-header {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    padding: 20px 20px 35px 20px;
    border-bottom-left-radius: 24px;
    border-bottom-right-radius: 24px;
    color: white;
}

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

.brand-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: white;
}

.brand-logo i {
    font-size: 24px;
    color: var(--accent);
}

.brand-logo span {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.header-actions {
    display: flex;
    gap: 12px;
}

.action-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.action-btn:active {
    transform: scale(0.92);
    background-color: rgba(255, 255, 255, 0.25);
}

.badge-dot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 8px;
    height: 8px;
    background-color: var(--danger);
    border-radius: 50%;
    border: 1.5px solid var(--primary);
}

/* ==========================================================================
   Wallet & Balance Card
   ========================================================================== */
.wallet-card-wrapper {
    padding: 0 20px;
    margin-top: -20px;
    margin-bottom: 20px;
}

.wallet-card {
    background-color: white;
    border-radius: 20px;
    padding: 18px 20px;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.wallet-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 1.5px dashed var(--gray-200);
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.wallet-balance {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.balance-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--gray-400);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.balance-amount-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.balance-currency {
    font-size: 14px;
    font-weight: 700;
    color: var(--gray-400);
    margin-top: 4px;
}

.balance-amount {
    font-size: 24px;
    font-weight: 800;
    color: var(--gray-900);
    letter-spacing: -0.5px;
}

.toggle-balance {
    cursor: pointer;
    color: var(--gray-400);
    font-size: 18px;
    padding: 4px;
    transition: color 0.2s;
}

.toggle-balance:hover {
    color: var(--primary);
}

.member-tier {
    display: flex;
    align-items: center;
    gap: 6px;
    background-color: var(--primary-light);
    color: var(--primary);
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 700;
}

.member-tier i {
    font-size: 12px;
    color: var(--accent);
}

/* Wallet Actions */
.wallet-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.wallet-action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--gray-800);
    cursor: pointer;
}

.wallet-action-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background-color: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.2s ease;
}

.wallet-action-item:active .wallet-action-icon {
    transform: translateY(-2px);
    background-color: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.wallet-action-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--gray-600);
}

/* ==========================================================================
   Product Grid (PPOB Services)
   ========================================================================== */
.services-section {
    padding: 0 20px;
    margin-bottom: 25px;
}

.section-title-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding: 0 4px;
}

.section-title {
    font-size: 15px;
    font-weight: 800;
    color: var(--gray-900);
}

.section-link {
    font-size: 12px;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
}

.services-grid {
    background-color: white;
    border-radius: 20px;
    padding: 20px 10px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    row-gap: 20px;
    column-gap: 8px;
    box-shadow: var(--card-shadow);
}

.service-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    cursor: pointer;
}

.service-icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: white;
    position: relative;
    transition: all 0.2s ease;
}

.service-item:active .service-icon-wrapper {
    transform: scale(0.9);
}

.service-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--gray-800);
    text-align: center;
    white-space: nowrap;
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Service Icon Gradients */
.bg-pulsa { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.bg-data { background: linear-gradient(135deg, #10b981, #047857); }
.bg-token { background: linear-gradient(135deg, #f59e0b, #d97706); }
.bg-pdam { background: linear-gradient(135deg, #06b6d4, #0891b2); }
.bg-bpjs { background: linear-gradient(135deg, #14b8a6, #0f766e); }
.bg-wifi { background: linear-gradient(135deg, #6366f1, #4338ca); }
.bg-game { background: linear-gradient(135deg, #ec4899, #be185d); }
.bg-emoney { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }
.bg-pascabayar { background: linear-gradient(135deg, #64748b, #334155); }
.bg-finance { background: linear-gradient(135deg, #f43f5e, #be123c); }
.bg-pbb { background: linear-gradient(135deg, #059669, #064e3b); }
.bg-other { background: linear-gradient(135deg, #e2e8f0, #cbd5e1); color: var(--gray-600) !important; }

/* Badge for popular/promo services */
.service-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: var(--danger);
    color: white;
    font-size: 8px;
    font-weight: 800;
    padding: 2px 5px;
    border-radius: 8px;
    text-transform: uppercase;
    border: 1px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* ==========================================================================
   Promo Carousel Component (Index)
   ========================================================================== */
.promo-section {
    padding: 0 20px;
    margin-bottom: 25px;
}

.promo-slider-container {
    width: 100%;
    overflow: hidden;
    border-radius: 16px;
    position: relative;
    box-shadow: var(--card-shadow);
}

.promo-slider {
    display: flex;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    width: 100%;
}

.promo-slide {
    min-width: 100%;
    position: relative;
}

.promo-slide img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    display: block;
}

.promo-banner-custom {
    width: 100%;
    height: 140px;
    background: linear-gradient(135deg, #4f46e5, #06b6d4);
    color: white;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.promo-banner-custom.blue-pink {
    background: linear-gradient(135deg, #ec4899, #8b5cf6);
}

.promo-banner-custom.orange-gold {
    background: linear-gradient(135deg, #f59e0b, #e11d48);
}

.promo-badge {
    align-self: flex-start;
    background-color: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.promo-title {
    font-size: 16px;
    font-weight: 800;
    margin-top: 10px;
    line-height: 1.2;
}

.promo-desc {
    font-size: 11px;
    opacity: 0.85;
}

.promo-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.promo-btn {
    background-color: white;
    color: var(--gray-900);
    border: none;
    padding: 5px 12px;
    border-radius: 30px;
    font-size: 10px;
    font-weight: 800;
    cursor: pointer;
}

.promo-indicators {
    position: absolute;
    bottom: 10px;
    right: 15px;
    display: flex;
    gap: 6px;
}

.indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    transition: all 0.3s;
}

.indicator.active {
    background-color: white;
    width: 14px;
    border-radius: 10px;
}

/* ==========================================================================
   Live Transaction Feed
   ========================================================================== */
.live-feed-section {
    padding: 0 20px;
    margin-bottom: 25px;
}

.live-feed-card {
    background-color: white;
    border-radius: 16px;
    padding: 12px 16px;
    box-shadow: var(--card-shadow);
    display: flex;
    align-items: center;
    gap: 12px;
    border-left: 4px solid var(--success);
    overflow: hidden;
}

.feed-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--success-light);
    color: var(--success);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.feed-content {
    flex-grow: 1;
    font-size: 12px;
    color: var(--gray-600);
    overflow: hidden;
}

.feed-user {
    font-weight: 700;
    color: var(--gray-900);
}

.feed-product {
    font-weight: 700;
    color: var(--primary);
}

.feed-status {
    background-color: var(--success-light);
    color: var(--success);
    font-size: 9px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 6px;
    text-transform: uppercase;
    flex-shrink: 0;
}

/* ==========================================================================
   Trust / Benefits Section
   ========================================================================== */
.benefits-section {
    padding: 0 20px;
    margin-bottom: 25px;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.benefit-card {
    background-color: white;
    border-radius: 16px;
    padding: 15px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    box-shadow: var(--card-shadow);
}

.benefit-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.benefit-card:nth-child(1) .benefit-icon {
    background-color: var(--primary-light);
    color: var(--primary);
}
.benefit-card:nth-child(2) .benefit-icon {
    background-color: var(--success-light);
    color: var(--success);
}
.benefit-card:nth-child(3) .benefit-icon {
    background-color: var(--danger-light);
    color: var(--danger);
}

.benefit-title {
    font-size: 11px;
    font-weight: 800;
    color: var(--gray-900);
}

.benefit-desc {
    font-size: 9px;
    color: var(--gray-400);
    line-height: 1.3;
}

/* ==========================================================================
   Quick CS Section
   ========================================================================== */
.support-section {
    padding: 0 20px;
    margin-bottom: 30px;
}

.support-card {
    background: linear-gradient(135deg, var(--gray-800), var(--gray-900));
    border-radius: 16px;
    padding: 18px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.support-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.support-title {
    font-size: 14px;
    font-weight: 800;
}

.support-desc {
    font-size: 11px;
    color: var(--gray-300);
}

.support-button {
    background-color: #25d366;
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.3);
    transition: transform 0.2s;
}

.support-button:active {
    transform: scale(0.95);
}

/* ==========================================================================
   Page Headers (Sub-pages like Riwayat, Promo, Profil)
   ========================================================================== */
.subpage-header {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    padding: 20px 20px 25px 20px;
    color: white;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}

.subpage-top {
    display: flex;
    align-items: center;
    gap: 16px;
}

.back-btn {
    color: white;
    font-size: 24px;
    text-decoration: none;
    cursor: pointer;
}

.subpage-title {
    font-size: 18px;
    font-weight: 800;
}

/* ==========================================================================
   Search and Filters (Riwayat Page)
   ========================================================================== */
.search-filter-wrapper {
    padding: 16px 20px 10px 20px;
}

.search-input-wrapper {
    position: relative;
    width: 100%;
    margin-bottom: 12px;
}

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

.search-input {
    width: 100%;
    height: 46px;
    background-color: white;
    border: 1.5px solid var(--gray-200);
    border-radius: 12px;
    padding: 0 16px 0 44px;
    font-size: 13px;
    font-weight: 600;
    outline: none;
    transition: all 0.2s;
}

.search-input::placeholder {
    color: var(--gray-400);
}

.search-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Filter Horizontal Slider */
.filter-tabs-wrapper {
    display: flex;
    overflow-x: auto;
    gap: 8px;
    padding-bottom: 5px;
}

.filter-tab {
    background-color: white;
    color: var(--gray-600);
    border: 1.5px solid var(--gray-200);
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-tab.active {
    background-color: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* ==========================================================================
   History List Items
   ========================================================================== */
.history-section {
    padding: 0 20px;
    flex-grow: 1;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.history-card {
    background-color: white;
    border-radius: 16px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: transform 0.15s;
}

.history-card:active {
    transform: scale(0.98);
}

.history-left {
    display: flex;
    align-items: center;
    gap: 14px;
    overflow: hidden;
}

.history-icon-wrapper {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: white;
    flex-shrink: 0;
}

.history-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow: hidden;
}

.history-title {
    font-size: 13px;
    font-weight: 800;
    color: var(--gray-900);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.history-target {
    font-size: 11px;
    font-weight: 600;
    color: var(--gray-400);
}

.history-date {
    font-size: 10px;
    color: var(--gray-400);
}

.history-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    flex-shrink: 0;
}

.history-amount {
    font-size: 14px;
    font-weight: 800;
}

.history-amount.expense {
    color: var(--gray-900);
}

.history-amount.income {
    color: var(--success);
}

.status-badge {
    font-size: 9px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 6px;
    text-transform: uppercase;
}

.status-badge.sukses {
    background-color: var(--success-light);
    color: var(--success);
}

.status-badge.proses {
    background-color: #fffbeb;
    color: #d97706;
}

.status-badge.gagal {
    background-color: var(--danger-light);
    color: var(--danger);
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 50px 20px;
    text-align: center;
    color: var(--gray-400);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 12px;
}

.empty-state p {
    font-size: 13px;
    font-weight: 600;
}

/* ==========================================================================
   Detail Bottom Sheet Modal (Drawer)
   ========================================================================== */
.sheet-backdrop {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    height: 100vh;
    background-color: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.sheet-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.detail-bottom-sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: white;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.15);
    padding: 24px 20px;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 2001;
}

.sheet-backdrop.show .detail-bottom-sheet {
    transform: translateY(0);
}

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

.sheet-title {
    font-size: 16px;
    font-weight: 800;
    color: var(--gray-900);
}

.close-sheet-btn {
    border: none;
    background: none;
    font-size: 22px;
    color: var(--gray-400);
    cursor: pointer;
}

/* Receipt Design inside Bottom Sheet */
.receipt-container {
    background-color: var(--gray-50);
    border: 1px dashed var(--gray-300);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    font-size: 12px;
}

.receipt-header {
    text-align: center;
    border-bottom: 1.5px dashed var(--gray-300);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.receipt-brand {
    font-size: 15px;
    font-weight: 800;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.receipt-status-text {
    font-size: 11px;
    font-weight: 700;
    margin-top: 4px;
    text-transform: uppercase;
}

.receipt-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.receipt-label {
    color: var(--gray-400);
    font-weight: 600;
}

.receipt-value {
    color: var(--gray-900);
    font-weight: 700;
    text-align: right;
}

.receipt-divider {
    border-top: 1.5px dashed var(--gray-300);
    margin: 12px 0;
}

.receipt-sn-box {
    background-color: var(--primary-light);
    border: 1px solid rgba(37, 99, 235, 0.15);
    color: var(--primary);
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 700;
    text-align: center;
    font-family: monospace;
    font-size: 13px;
    margin: 8px 0;
}

.sheet-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.sheet-btn {
    height: 46px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.sheet-btn-secondary {
    background-color: var(--gray-100);
    color: var(--gray-600);
}

.sheet-btn-primary {
    background-color: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.sheet-btn:active {
    transform: scale(0.97);
}

/* ==========================================================================
   Scan QR Layout (scan.php)
   ========================================================================== */
.scan-page-body {
    background-color: #000 !important;
}

.scan-container {
    background-color: #0b0f19;
    color: white;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    position: relative;
    overflow: hidden;
}

.scanner-viewfinder {
    width: 260px;
    height: 260px;
    position: relative;
    border: 2px solid rgba(255, 255, 255, 0.25);
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 30px;
}

/* Viewfinder Corners */
.corner {
    position: absolute;
    width: 24px;
    height: 24px;
    border-color: var(--primary);
    border-style: solid;
    border-width: 0;
}

.top-left { top: 0; left: 0; border-top-width: 4px; border-left-width: 4px; border-top-left-radius: 16px; }
.top-right { top: 0; right: 0; border-top-width: 4px; border-right-width: 4px; border-top-right-radius: 16px; }
.bottom-left { bottom: 0; left: 0; border-bottom-width: 4px; border-left-width: 4px; border-bottom-left-radius: 16px; }
.bottom-right { bottom: 0; right: 0; border-bottom-width: 4px; border-right-width: 4px; border-bottom-right-radius: 16px; }

/* Moving Scan Laser Line */
.scan-laser {
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, transparent, var(--primary), transparent);
    box-shadow: 0 0 10px var(--primary);
    animation: scanning 2.5s infinite linear;
}

@keyframes scanning {
    0% { top: 0; }
    50% { top: 100%; }
    100% { top: 0; }
}

.scan-instruction {
    font-size: 13px;
    font-weight: 700;
    color: var(--gray-300);
    text-align: center;
    margin-bottom: 40px;
}

.scan-controls {
    display: flex;
    gap: 24px;
}

.scan-control-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.scan-control-btn:active {
    background-color: var(--primary);
    transform: scale(0.9);
}

.scan-control-label {
    font-size: 10px;
    text-align: center;
    color: var(--gray-400);
    margin-top: 8px;
    font-weight: 700;
}

/* ==========================================================================
   Promo Page Layout (promo.php)
   ========================================================================== */
.promo-list-page {
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.promo-item-card {
    background-color: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    border: 1px solid var(--gray-200);
}

.promo-img-placeholder {
    height: 120px;
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    color: white;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.promo-card-body {
    padding: 16px;
}

.promo-card-title {
    font-size: 14px;
    font-weight: 800;
    color: var(--gray-900);
    margin-bottom: 6px;
}

.promo-card-desc {
    font-size: 11px;
    color: var(--gray-600);
    line-height: 1.4;
    margin-bottom: 12px;
}

.promo-card-action {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.promo-code-box {
    background-color: var(--gray-100);
    border: 1px dashed var(--gray-300);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 800;
    color: var(--gray-800);
    font-family: monospace;
}

.promo-claim-btn {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s;
}

.promo-claim-btn:active {
    transform: scale(0.95);
    background-color: var(--primary-dark);
}

/* ==========================================================================
   Profil Page Layout (profil.php)
   ========================================================================== */
.profile-content {
    padding: 20px;
}

.profile-card {
    background-color: white;
    border-radius: 20px;
    padding: 20px;
    box-shadow: var(--card-shadow);
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.profile-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    font-weight: 700;
    border: 3px solid var(--primary-light);
}

.profile-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.profile-name {
    font-size: 16px;
    font-weight: 800;
    color: var(--gray-900);
}

.profile-phone {
    font-size: 12px;
    color: var(--gray-400);
    font-weight: 600;
}

.profile-menu-container {
    background-color: white;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    margin-bottom: 20px;
}

.profile-menu-header {
    font-size: 11px;
    font-weight: 800;
    color: var(--gray-400);
    padding: 16px 20px 8px 20px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    border-bottom: 1px solid var(--gray-100);
}

.profile-menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    text-decoration: none;
    color: var(--gray-800);
    border-bottom: 1px solid var(--gray-100);
    transition: background-color 0.2s;
    cursor: pointer;
}

.profile-menu-item:last-child {
    border-bottom: none;
}

.profile-menu-item:active {
    background-color: var(--gray-50);
}

.profile-menu-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.profile-menu-icon {
    font-size: 18px;
    color: var(--gray-600);
}

.profile-menu-label {
    font-size: 12px;
    font-weight: 700;
}

.profile-menu-right {
    color: var(--gray-400);
    font-size: 16px;
}

.profile-logout-container {
    padding: 0 10px;
}

.logout-btn {
    width: 100%;
    height: 48px;
    border-radius: 14px;
    background-color: var(--danger-light);
    color: var(--danger);
    border: none;
    font-size: 13px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.logout-btn:active {
    transform: scale(0.97);
    background-color: var(--danger);
    color: white;
}

/* ==========================================================================
   Bottom Navigation Component
   ========================================================================== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    height: 68px;
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border-top: 1px solid rgba(226, 232, 240, 0.8);
    display: flex;
    justify-content: space-around;
    align-items: center;
    box-shadow: var(--nav-shadow);
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    text-decoration: none;
    color: var(--gray-400);
    width: 60px;
    height: 100%;
    cursor: pointer;
    position: relative;
    transition: all 0.2s;
}

.nav-item i {
    font-size: 20px;
    transition: transform 0.2s;
}

.nav-item span {
    font-size: 10px;
    font-weight: 700;
}

.nav-item.active {
    color: var(--primary);
}

.nav-item.active i {
    transform: translateY(-2px);
    font-weight: bold;
}

.nav-item-center {
    position: relative;
    top: -15px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white !important;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.4);
    border: 4px solid var(--gray-50);
}

.nav-item-center i {
    font-size: 24px !important;
}

.nav-item-center:active {
    transform: scale(0.9) translateY(-15px);
}

@media (max-width: 480px) {
    body {
        background-color: var(--gray-50);
    }
    .app-container {
        box-shadow: none;
    }
}

/* Global Submit Button Styling */
.submit-deposit-btn {
    width: 100%;
    height: 50px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: var(--btn-shadow);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
    text-decoration: none;
}

.submit-deposit-btn:active {
    transform: scale(0.98);
    opacity: 0.95;
}

