/* ==========================================================================
   MobiCharge B2C Customer Website — Design System & Mobile Responsive Styles
   ========================================================================== */

:root {
    --primary: #2563EB;
    --primary-hover: #1D4ED8;
    --primary-light: #EFF6FF;
    --primary-gradient: linear-gradient(135deg, #1E40AF 0%, #3B82F6 100%);
    --accent: #06B6D4;
    --success: #10B981;
    --success-light: #ECFDF5;
    --warning: #F59E0B;
    --warning-light: #FFFBEB;
    --danger: #EF4444;
    --danger-light: #FEF2F2;

    --bg-main: #F8FAFC;
    --bg-surface: #FFFFFF;
    --bg-card: #FFFFFF;
    --bg-subtle: #F1F5F9;

    --text-primary: #0F172A;
    --text-secondary: #475569;
    --text-muted: #94A3B8;
    --text-white: #FFFFFF;

    --border: #CBD5E1;
    --border-light: #E2E8F0;
    --border-focus: #3B82F6;

    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.15), 0 8px 10px -6px rgb(0 0 0 / 0.1);

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-full: 9999px;

    --font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.55;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}
a:hover {
    color: var(--primary-hover);
}

/* Header & Nav */
.header {
    background-color: var(--bg-surface);
    border-bottom: 1px solid var(--border-light);
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(8px);
}
.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.brand-logo {
    display: block;
    width: 145px;
    height: 48px;
    max-width: 100%;
    max-height: none;
    object-fit: contain;
    flex-shrink: 0;
}

.brand-wordmark {
    display: inline-block;
    color: var(--text-primary);
    font-size: 1.18rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.45px;
    white-space: nowrap;
}
.logo-icon {
    width: 36px;
    height: 36px;
    background: var(--primary-gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.15rem;
}
.logo span { color: var(--primary); }

.nav-menu {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    list-style: none;
}
.nav-link {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 0.4rem 0.2rem;
    position: relative;
}
.nav-link:hover, .nav-link.active {
    color: var(--primary);
}
.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
}


    
    .nav-actions {
        order: 2;
        display: flex;
        align-items: center;
        flex: 0 1 auto;
        min-width: 0;
        max-width: 48%;
        margin-left: auto;
        gap: 4px;
        overflow: visible;
    }

    .nav-actions .btn {
        min-width: 0;
        padding: 7px 8px;
        font-size: 11px;
        white-space: nowrap;
    }

    .nav-actions .btn-outline {
        max-width: 112px;
        overflow: hidden;
        text-overflow: ellipsis;
    }


    .nav-toggle {
        display: flex;
        order: 3;
        flex: 0 0 38px;
        align-items: center;
        justify-content: center;
        width: 38px;
        height: 38px;
        margin-left: 0;
        padding: 0;
        border: 0;
        background: transparent;
        color: var(--text-primary);
        font-size: 1.4rem;
        cursor: pointer;
    }


.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.65rem 1.15rem;
    font-size: 0.92rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
    min-height: 42px;
}
.btn-primary {
    background: var(--primary-gradient);
    color: var(--text-white);
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.25);
}
.btn-primary:hover {
    background: var(--primary-hover);
    color: var(--text-white);
}
.btn-secondary {
    background: var(--bg-subtle);
    color: var(--text-primary);
    border-color: var(--border-light);
}
.btn-secondary:hover { background: #E2E8F0; }
.btn-outline {
    background: transparent;
    border-color: var(--border);
    color: var(--text-secondary);
}
.btn-outline:hover { background: var(--bg-subtle); color: var(--text-primary); }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.85rem; min-height: 36px; }
.btn-block { width: 100%; }

/* Layout */
.main-content {
    flex: 1;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 1.75rem 1rem;
}

.view-section {
    display: none;
    animation: fadeIn 0.2s ease-in-out;
}
.view-section.active { display: block; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Hero & Card */
.hero-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 2rem;
    align-items: start;
    margin-bottom: 2.5rem;
}
.hero-title {
    font-size: 2.35rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.8px;
    color: var(--text-primary);
    margin-bottom: 0.85rem;
}
.hero-title span {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-subtitle {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    max-width: 500px;
}
.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}
.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--bg-surface);
    border: 1px solid var(--border-light);
    padding: 0.3rem 0.7rem;
    border-radius: var(--radius-full);
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
}
.badge-pill i { color: var(--success); }

.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
}

.recharge-tabs {
    display: flex;
    gap: 0.4rem;
    background: var(--bg-subtle);
    padding: 0.3rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.25rem;
}
.tab-btn {
    flex: 1;
    padding: 0.6rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    transition: var(--transition);
}
.tab-btn.active {
    background: var(--bg-surface);
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.form-group { margin-bottom: 1.15rem; }
.form-label {
    display: block;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.35rem;
}
.form-control {
    width: 100%;
    padding: 0.7rem 0.9rem;
    font-size: 16px; /* Prevents auto-zoom on mobile browsers */
    font-family: inherit;
    color: var(--text-primary);
    background-color: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: var(--transition);
    min-height: 44px;
}
.form-control:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}
.input-group {
    position: relative;
    display: flex;
}
.input-addon {
    padding: 0.7rem 0.85rem;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-right: none;
    border-radius: var(--radius-md) 0 0 var(--radius-md);
    font-weight: 700;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
}
.input-group .form-control {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.detection-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.82rem;
    font-weight: 600;
    margin-top: 0.35rem;
}
.detection-badge.loading { color: var(--primary); }
.detection-badge.success { color: var(--success); }
.detection-badge.muted { color: var(--text-muted); }

.api-banner {
    background: #FFFBEB;
    border: 1px solid #FDE68A;
    color: #92400E;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.order-summary {
    background: var(--bg-subtle);
    border-radius: var(--radius-md);
    padding: 1rem;
    margin: 1rem 0;
    border: 1px dashed var(--border);
}
.summary-line {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.4rem;
    font-size: 0.88rem;
    color: var(--text-secondary);
}
.summary-line.total {
    border-top: 1px solid var(--border);
    padding-top: 0.5rem;
    margin-top: 0.5rem;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--text-primary);
}
.discount-text { color: var(--success); font-weight: 700; }

/* Modals — Completely Responsive & Viewport-Bounded */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(4px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 0.75rem;
    overflow-y: auto;
}
.modal-overlay.active { display: flex; }
.modal-content {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 480px;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    position: relative;
    padding: 1.75rem 1.5rem;
    margin: auto;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
    padding-right: 1.5rem;
}
.modal-title {
    font-size: 1.25rem;
    font-weight: 800;
}
.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.75rem;
    color: var(--text-muted);
    cursor: pointer;
    line-height: 1;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.modal-close:hover { color: var(--text-primary); }

.modal-plans { max-width: 720px; }
.plans-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}
.plan-card {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.85rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition);
    cursor: pointer;
}
.plan-card:hover { border-color: var(--primary); box-shadow: var(--shadow-md); }
.plan-price { font-size: 1.35rem; font-weight: 800; color: var(--primary); }
.plan-meta {
    display: flex;
    gap: 0.75rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin: 0.3rem 0;
}
.plan-desc {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.65rem;
    line-height: 1.35;
}

/* Tables */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    background: var(--bg-surface);
}
.data-table {
    width: 100%;
    min-width: 580px;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.88rem;
}
.data-table th {
    background: var(--bg-subtle);
    padding: 0.75rem 0.85rem;
    font-weight: 700;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-light);
}
.data-table td {
    padding: 0.75rem 0.85rem;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-primary);
}
.data-table tr:last-child td { border-bottom: none; }
.status-pill {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}
.status-pill.success { background: var(--success-light); color: var(--success); }
.status-pill.pending { background: var(--warning-light); color: var(--warning); }
.status-pill.processing { background: var(--primary-light); color: var(--primary); }
.status-pill.failed { background: var(--danger-light); color: var(--danger); }

/* Toasts */
.toast-container {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
    max-width: 400px;
    margin-left: auto;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    pointer-events: none;
}
.toast {
    background: var(--text-primary);
    color: white;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.88rem;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    pointer-events: auto;
    animation: slideUp 0.2s ease-out;
}
.toast.success { background: #065F46; border-left: 4px solid var(--success); }
.toast.error { background: #991B1B; border-left: 4px solid var(--danger); }
.toast.warning { background: #92400E; border-left: 4px solid var(--warning); }

@keyframes slideUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Footer */
.footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border-light);
    padding: 2.5rem 1rem 1.5rem;
    margin-top: auto;
}
.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 1.5rem;
}
.footer-brand-logo-link {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    max-width: 100%;
    margin-bottom: 0.5rem;
    text-decoration: none;
}
.footer-brand-logo {
    display: block;
    width: 100px;
    height: 100px;
    max-width: none;
    max-height: none;
    object-fit: contain;
    flex-shrink: 0;
}
.footer-brand-wordmark {
    display: inline-block;
    color: var(--text-primary);
    font-size: clamp(1.25rem, 3vw, 2rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.6px;
    white-space: nowrap;
}
.footer-brand p { font-size: 0.88rem; color: var(--text-secondary); margin-top: 0.5rem; max-width: 300px; }
.footer-heading { font-size: 0.9rem; font-weight: 700; color: var(--text-primary); margin-bottom: 0.85rem; text-transform: uppercase; }
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
.footer-links a { font-size: 0.88rem; color: var(--text-secondary); }
.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.82rem;
    color: var(--text-muted);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; gap: 1.75rem; }
    .footer-container { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
    .plans-grid { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
    .header-container { padding: 0.5rem 0.85rem; }
    .brand-logo {
        display: block;
        width: 135px;
        height: 38px;
        max-width: none;
        max-height: none;
        flex: 0 0 135px;
        object-fit: contain;
        object-position: left center;
    }
    .brand-wordmark { font-size: 1rem; letter-spacing: -0.3px; }
    .footer-brand-logo {
        width: 80px;
        height: 80px;
        max-width: none;
        max-height: none;
        flex-basis: 80px;
    }
    .footer-brand-wordmark { font-size: 1.35rem; letter-spacing: -0.4px; }
    
    .nav-menu {
        display: none !important;
        position: absolute !important;
        top: calc(100% + 8px) !important;
        bottom: auto !important;
        left: auto !important;
        right: 12px !important;
        width: min(300px, calc(100vw - 24px)) !important;
        box-sizing: border-box;
        padding: 14px !important;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        background: #ffffff;
        border: 1px solid #dbe5f2;
        border-radius: 16px;
        box-shadow: 0 12px 30px rgba(15, 23, 42, 0.16);
        z-index: 9999;
    }

    .nav-menu.active { display: flex; }
    .nav-toggle { display: flex; align-items: center; justify-content: center; }
    .hero-title { font-size: 1.85rem; }
    .hero-subtitle { font-size: 0.95rem; }
    .hero-badges { margin-bottom: 1rem; }
    .card {
    padding: 1.15rem;
}

    /* Compact only the card containing the recharge form */
    .card:has(#recharge-form) {
        padding: 14px;
        border-radius: 18px;
    }
    
    #recharge-form .form-group {
        margin-bottom: 13px;
    }
    
    #recharge-form .form-label {
        font-size: 14px;
        margin-bottom: 5px;
    }
    
    #recharge-form .form-control {
        min-height: 44px;
    }
    
    #recharge-form .recharge-tabs {
        margin-bottom: 16px;
    }
    
    #recharge-form .tab-btn {
        padding: 9px 5px;
        font-size: 13px;
        line-height: 1.3;
    }
        /* Keep Operator and Circle side-by-side on mobile */
        .form-row {
            grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
            gap: 10px;
            align-items: start;
        }
        
        .form-row .form-group {
            min-width: 0;
            margin-bottom: 12px;
        }
        
        .form-row .form-control {
            width: 100%;
            min-width: 0;
            height: 46px;
            padding: 8px 10px;
            font-size: 14px;
        }
.modal-content {
        padding: 1.25rem 1rem;
        max-height: calc(100vh - 1rem);
        border-radius: var(--radius-md);
    }
    .footer-container { grid-template-columns: 1fr; gap: 1.25rem; }
    .footer-bottom { flex-direction: column; gap: 0.5rem; text-align: center; }
    .toast-container { left: 0.5rem; right: 0.5rem; bottom: 0.75rem; }
    /* Mobile account menu */
    .nav-actions {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 42px;
        height: 42px;
        margin-left: auto;
        border: 1px solid #dbe4f0;
        border-radius: 12px;
        background: #ffffff;
        color: #173b83;
        font-size: 23px;
        cursor: pointer;
        transition: background 0.2s ease, box-shadow 0.2s ease;
    }
    
    .nav-toggle:hover {
        background: #f0f5ff;
        box-shadow: 0 3px 10px rgba(30, 64, 175, 0.12);
    }
    
    /* Dropdown panel — apply to the existing menu container */
    .nav-menu {
        position: absolute;
        top: calc(100% + 8px);
        left: 10px;
        right: 10px;
        z-index: 1000;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        padding: 14px;
        border: 1px solid #e2e8f0;
        border-radius: 16px;
        background: #ffffff;
        box-shadow: 0 12px 28px rgba(15, 23, 42, 0.14);
    }
    
    /* Account details inside the menu */
    .nav-menu .user-info {
        padding: 10px;
        margin-bottom: 8px;
        border-radius: 10px;
        background: #f1f5ff;
        color: #173b83;
        font-weight: 600;
    }
    
    /* Sign Out button inside the menu */
    .nav-menu .btn-signout {
        width: 100%;
        min-height: 42px;
        border: 1px solid #dbe4f0;
        border-radius: 10px;
        background: #ffffff;
        color: #173b83;
        font-weight: 600;
        cursor: pointer;
    }
    
    .nav-menu .btn-signout:hover {
        background: #eef4ff;
    }
    
}
/* Plan Category Filters Bar */
.plan-category-bar {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    white-space: nowrap;
    padding-bottom: 0.65rem;
    margin-bottom: 0.85rem;
    border-bottom: 1px solid var(--border-light);
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
}
.plan-category-bar::-webkit-scrollbar {
    height: 4px;
}
.plan-category-bar::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}
.plan-category-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    user-select: none;
}
.plan-category-pill:hover {
    border-color: var(--primary);
    color: var(--primary);
}
.plan-category-pill.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 2px 6px rgba(43, 89, 255, 0.25);
}
.plan-category-count {
    display: inline-block;
    font-size: 0.7rem;
    opacity: 0.85;
    background: rgba(0, 0, 0, 0.08);
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
    margin-left: 0.2rem;
}
.plan-category-pill.active .plan-category-count {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff;
}

/* Authentication Upgrade: Password Toggle, OTP & Alerts */
.password-toggle-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}
.password-toggle-wrapper .form-control {
    padding-right: 2.75rem;
}
.password-toggle-btn {
    position: absolute;
    right: 0.5rem;
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.35rem 0.6rem;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease;
    z-index: 2;
}
.password-toggle-btn:hover {
    color: var(--primary);
}
.otp-input-field {
    text-align: center;
    letter-spacing: 0.45rem;
    font-family: 'SFMono-Regular', Consolas, Menlo, Monaco, monospace;
    font-size: 1.5rem;
    font-weight: 700;
    padding: 0.75rem;
}
.auth-notice-card {
    background: rgba(43, 89, 255, 0.06);
    border-left: 3px solid var(--primary);
    padding: 0.85rem 1rem;
    border-radius: 6px;
    font-size: 0.88rem;
    color: #1e293b;
    margin-bottom: 1.25rem;
    line-height: 1.5;
}
.resend-timer-box {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 1rem;
}


/* MobiCharge mobile navigation — final override */
@media (max-width: 680px) {

    .header {
        position: sticky;
        top: 0;
        z-index: 1000;
    }

    .header-container {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
    }

    /* Keep the hamburger button visible */
    .nav-toggle {
        display: flex !important;
        flex: 0 0 42px;
        width: 42px;
        height: 42px;
        align-items: center;
        justify-content: center;
        margin-left: auto;
        border: 1px solid #dbe5f2;
        border-radius: 12px;
        background: #ffffff;
        color: #173b83;
        box-shadow: 0 3px 10px rgba(30, 64, 175, 0.10);
        cursor: pointer;
        position: relative;
        z-index: 1002;
    }

    /* Closed state */
    .nav-menu {
        display: none !important;
        position: absolute !important;
        top: calc(100% + 8px) !important;
        left: 10px !important;
        right: 10px !important;
        bottom: auto !important;
        width: auto !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 10px !important;
        padding: 14px !important;
        margin: 0 !important;
        list-style: none !important;
        background: #ffffff !important;
        border: 1px solid #dbe5f2 !important;
        border-radius: 16px !important;
        box-shadow: 0 12px 30px rgba(15, 23, 42, 0.16) !important;
        z-index: 1001 !important;
    }

    /* Open state — this must override display:none */
    .nav-menu.active {
        display: grid !important;
    }

    /* Four attractive navigation boxes */
    .nav-menu > li {
        display: flex;
        min-width: 0;
        margin: 0;
        padding: 0;
    }

    .nav-menu > li > a,
    .nav-menu > li > button {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        width: 100%;
        min-height: 48px;
        padding: 10px 6px;
        border: 1px solid #e2e8f0;
        border-radius: 11px;
        background: #f8fafc;
        color: #173b83;
        font-size: 12px;
        font-weight: 700;
        text-align: center;
        text-decoration: none;
        cursor: pointer;
        box-sizing: border-box;
    }

    .nav-menu > li > a:hover,
    .nav-menu > li > button:hover {
        background: #eff6ff;
        border-color: #93b4f8;
        color: #2563eb;
    }

    /* Account name and sign-out, if already inside the menu */
    .nav-menu .user-info {
        grid-column: 1 / -1;
        width: 100%;
        padding: 11px 12px;
        margin: 0;
        border: 1px solid #dbeafe;
        border-radius: 11px;
        background: #eff6ff;
        color: #173b83;
        font-size: 13px;
        font-weight: 700;
        text-align: center;
        box-sizing: border-box;
    }

    .nav-menu .btn-signout {
        width: 100%;
        min-height: 44px;
        padding: 10px;
        border: 1px solid #fecaca;
        border-radius: 11px;
        background: #fff7f7;
        color: #b91c1c;
        font-size: 13px;
        font-weight: 700;
        cursor: pointer;
    }

    .nav-menu .btn-signout:hover {
        background: #fee2e2;
    }
}
/* Mobile header: account name box beside hamburger */
.header-account-controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-left: auto;
    min-width: 0;
}

.header-account-controls .nav-actions {
    display: flex;
    align-items: center;
    min-width: 0;
    max-width: 170px;
    margin-left: 0;
    gap: 6px;
}

.header-account-controls .nav-toggle {
    display: flex;
    flex: 0 0 42px;a
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    margin: 0;
    padding: 0;
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    background: #fff;
    color: #173b83;
    font-size: 22px;
    cursor: pointer;
}

@media (max-width: 680px) {
    .header-container {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .header-account-controls {
        gap: 6px;
    }

    .header-account-controls .nav-actions {
        max-width: 145px;
    }

    .header-account-controls .nav-toggle {
        flex: 0 0 38px;
        width: 38px;
        height: 38px;
    }
}


/* MobiCharge desktop-only header layout */
@media (min-width: 681px) {
    .header-container {
        display: flex;
        align-items: center;
        gap: 22px;
    }

    .header-container > .logo {
        order: 1;
        flex-shrink: 0;
        margin-right: auto;
    }

    .header-container > .nav-menu {
        order: 2;
        display: flex !important;
        align-items: center;
        justify-content: center;
        gap: 18px;
        flex-shrink: 0;
        position: static;
        width: auto;
        margin: 0;
    }

    .header-container > .header-account-controls {
        order: 3;
        display: flex;
        align-items: center;
        flex-shrink: 0;
        margin-left: 0;
    }

    /* Hide hamburger on laptops/desktops only */
    .header-container .nav-toggle {
        display: none !important;
    }

    .header-account-controls .nav-actions {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
        max-width: none;
        margin: 0;
    }
}


/* Desktop-only four-card feature layout */
@media (min-width: 1101px) {
    .home-feature-grid {
        display: grid !important;
        grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
        gap: 20px;
        width: 100%;
        margin-top: 2rem;
        align-items: stretch;
    }

    .home-feature-grid > .card {
        min-width: 0;
        width: 100%;
        box-sizing: border-box;
    }
}

/* Medium laptop screens */
@media (min-width: 681px) and (max-width: 1100px) {
    .home-feature-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 18px;
        width: 100%;
    }
}


/* ==========================================
   MOBICHARGE LIVE RECHARGE PROGRESS MODAL
========================================== */

#modal-order-status .modal-content {
    max-width: 710px;
    width: 100%;
    padding: 0;
    border-radius: 24px;
    overflow-x: hidden;
}

.mc-processing-modal {
    padding: 26px 34px 22px;
    text-align: center;
    background: #ffffff;
    color: #102b59;
}

.mc-processing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
}

.mc-brand {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 21px;
    font-weight: 800;
    color: #102b59;
}

.mc-brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 9px;
    color: #ffffff;
    background: linear-gradient(135deg, #1685f9, #1747c9);
    font-weight: 900;
    font-size: 23px;
    font-style: italic;
}

.mc-processing-close {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    background: #edf3fc;
    color: #526b91;
    font-size: 27px;
    cursor: pointer;
    line-height: 1;
}

.mc-progress-track {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 28px;
    width: 100%;
}

.mc-progress-step {
    width: 112px;
    min-width: 85px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    color: #8b9bb5;
    font-size: 13px;
    font-weight: 700;
}

.mc-step-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #edf2f9;
    color: #8b9bb5;
    font-size: 17px;
    border: 4px solid #e4ebf5;
}

.mc-progress-step.completed .mc-step-circle {
    background: #2168ef;
    color: #ffffff;
    border-color: #dceaff;
}

.mc-progress-step.active .mc-step-circle {
    width: 54px;
    height: 54px;
    margin-top: -6px;
    margin-bottom: -1px;
    background: #2168ef;
    color: #ffffff;
    border: 5px solid #e1edff;
    box-shadow: 0 5px 16px rgba(33, 104, 239, 0.2);
    animation: mc-step-pulse 2s infinite;
}

.mc-progress-step.active {
    color: #1762e9;
    font-size: 14px;
}

.mc-progress-step.failed .mc-step-circle {
    background: #dc2626;
    border-color: #fee2e2;
    color: #ffffff;
}

.mc-progress-step small {
    font-size: 11px;
    font-weight: 500;
    color: #8494ad;
}

.mc-progress-step.active small {
    color: #2168ef;
}

.mc-progress-connector {
    flex: 1;
    height: 4px;
    background: #dce5f2;
    border-radius: 10px;
    overflow: hidden;
    margin: 0 3px;
    position: relative;
    top: -13px;
}

.mc-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #2474ff, #16a5f5);
    border-radius: 10px;
    transition: width 1s ease-in-out;
    position: relative;
}

.mc-progress-fill[style*="100%"]::after {
    content: "";
    position: absolute;
    right: 0;
    top: -3px;
    width: 10px;
    height: 10px;
    background: #ffffff;
    border: 2px solid #2474ff;
    border-radius: 50%;
}

.mc-recharge-visual {
    width: 190px;
    height: 190px;
    margin: 0 auto 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.mc-visual-ring {
    position: absolute;
    border-radius: 50%;
    border: 7px solid rgba(42, 133, 244, 0.15);
}

.mc-ring-one {
    width: 184px;
    height: 184px;
}

.mc-ring-two {
    width: 150px;
    height: 150px;
    border-color: rgba(42, 133, 244, 0.38);
    border-right-color: transparent;
    animation: mc-ring-rotate 5s linear infinite;
}

.mc-phone-icon {
    width: 72px;
    height: 116px;
    border: 5px solid #1762d9;
    border-radius: 13px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(180deg, #e5f2ff, #ffffff);
    color: #0877e8;
    font-size: 42px;
    position: relative;
    z-index: 2;
    box-shadow: 0 5px 18px rgba(20, 96, 210, 0.15);
}

.mc-phone-icon::before {
    content: "";
    position: absolute;
    width: 22px;
    height: 4px;
    top: 4px;
    background: #1762d9;
    border-radius: 5px;
}

.mc-phone-signal {
    position: absolute;
    top: 28px;
    font-size: 23px;
    color: #1685f9;
}

.mc-visual-status {
    position: absolute;
    z-index: 3;
    right: 36px;
    bottom: 37px;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: #10b981;
    color: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 17px;
    border: 3px solid #ffffff;
}

.mc-progress-active .mc-visual-status {
    background: #2168ef;
    animation: mc-step-pulse 1.8s infinite;
}

.mc-progress-failed .mc-visual-status {
    background: #dc2626;
}

.mc-progress-pending .mc-visual-status {
    background: #f59e0b;
}

.mc-processing-title {
    font-size: 27px;
    font-weight: 800;
    color: #102b59;
    margin: 8px 0;
}

.mc-processing-message {
    color: #1762e9;
    font-size: 17px;
    font-weight: 700;
    margin: 0 auto 18px;
    max-width: 520px;
}

.mc-live-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: #e9f2ff;
    border-radius: 13px;
    padding: 15px 12px;
    margin-bottom: 18px;
    color: #153b77;
    font-size: 14px;
    font-weight: 600;
}

.mc-live-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #1685f9;
    flex-shrink: 0;
    animation: mc-live-blink 1.3s infinite;
}

.mc-progress-success .mc-live-dot {
    background: #10b981;
}

.mc-progress-failed .mc-live-dot {
    background: #dc2626;
}

.mc-order-info {
    border: 1px solid #e1e9f5;
    border-radius: 15px;
    padding: 14px 17px;
    text-align: left;
    margin-bottom: 16px;
}

.mc-info-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 7px 0;
    color: #637b9f;
    font-size: 14px;
}

.mc-info-row span {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mc-info-row span i {
    width: 17px;
    color: #58749c;
}

.mc-info-row strong {
    color: #102f61;
    text-align: right;
    overflow-wrap: anywhere;
}

.mc-info-row.mc-amount-row strong {
    color: #10b981;
    font-size: 19px;
}

.mc-check-status-btn {
    width: 100%;
    margin: 3px 0 12px;
}

.mc-secure-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    color: #6680a5;
    font-size: 13px;
    padding-top: 8px;
}

.mc-secure-footer i {
    color: #4386c9;
    font-size: 18px;
}

.mc-result-warning,
.mc-gateway-notice {
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 14px;
    font-size: 13px;
    text-align: left;
}

.mc-result-warning {
    background: #fff1f2;
    color: #b91c1c;
}

.mc-gateway-notice {
    background: #fff7e6;
    color: #92400e;
}

@keyframes mc-ring-rotate {
    to { transform: rotate(360deg); }
}

@keyframes mc-step-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(33, 104, 239, 0.2); }
    50% { box-shadow: 0 0 0 9px rgba(33, 104, 239, 0); }
}

@keyframes mc-live-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.25; }
}

@media (max-width: 520px) {
    #modal-order-status .modal-content {
        max-width: 100%;
        border-radius: 18px;
    }

    .mc-processing-modal {
        padding: 19px 15px 17px;
    }

    .mc-brand {
        font-size: 18px;
    }

    .mc-progress-step {
        min-width: 65px;
        width: 78px;
        font-size: 11px;
    }

    .mc-step-circle {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .mc-progress-step.active .mc-step-circle {
        width: 45px;
        height: 45px;
    }

    .mc-progress-connector {
        top: -12px;
        margin: 0 1px;
    }

    .mc-recharge-visual {
        width: 155px;
        height: 155px;
    }

    .mc-ring-one {
        width: 150px;
        height: 150px;
    }

    .mc-ring-two {
        width: 125px;
        height: 125px;
    }

    .mc-processing-title {
        font-size: 22px;
    }

    .mc-processing-message {
        font-size: 14px;
    }

    .mc-live-status {
        font-size: 12px;
        padding: 12px 9px;
    }

    .mc-info-row {
        font-size: 12px;
    }

    .mc-info-row.mc-amount-row strong {
        font-size: 17px;
    }
}


/* MobiCharge Recharge Progress - Mobile Fix */
@media screen and (max-width: 680px) {

    #modal-order-status {
        padding: 12px !important;
        align-items: center !important;
        justify-content: center !important;
        overflow-y: auto !important;
    }

    #modal-order-status .modal-content {
        width: 100% !important;
        max-width: 100% !important;
        max-height: calc(100dvh - 24px) !important;
        height: auto !important;
        margin: auto !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        border-radius: 20px !important;
        box-sizing: border-box !important;
    }

    #modal-order-status .mc-processing-modal {
        width: 100% !important;
        box-sizing: border-box !important;
        padding: 18px 14px !important;
    }

    #modal-order-status .mc-progress-track {
        width: 100% !important;
        gap: 0 !important;
    }

    #modal-order-status .mc-progress-step {
        flex: 0 1 78px !important;
        min-width: 0 !important;
    }

    #modal-order-status .mc-progress-connector {
        flex: 1 1 20px !important;
        min-width: 8px !important;
    }

    #modal-order-status .mc-order-info {
        width: 100% !important;
        box-sizing: border-box !important;
    }

    #modal-order-status .mc-info-row {
        flex-wrap: wrap;
        font-size: 12px !important;
    }

    #modal-order-status .mc-processing-title {
        font-size: 21px !important;
    }

    #modal-order-status .mc-processing-message {
        font-size: 14px !important;
    }
}

