/**
 * ISP Billing Engine - High-Tech Internet Loading & Confirmation System
 * Aesthetics: Cyberpunk / Modern Fiber-Optic Glassmorphism
 */

/* ==========================================================================
   1. Fullscreen Glassmorphism Loading Overlay
   ========================================================================== */
.isp-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at center, rgba(15, 23, 42, 0.88) 0%, rgba(3, 7, 18, 0.95) 100%);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 9999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.35s ease;
}

.isp-loading-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* ==========================================================================
   2. Main Futuristic Card Container
   ========================================================================== */
.isp-loading-card {
    position: relative;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(56, 189, 248, 0.3);
    border-radius: 24px;
    padding: 2.25rem 2rem;
    max-width: 440px;
    width: 90%;
    text-align: center;
    box-shadow: 0 0 50px rgba(14, 165, 233, 0.25), 0 25px 60px -15px rgba(0, 0, 0, 0.8);
    transform: scale(0.92);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.isp-loading-overlay.active .isp-loading-card {
    transform: scale(1);
}

/* Background Ambient Glow Behind Card */
.isp-loading-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 30%, rgba(14, 165, 233, 0.15) 0%, rgba(99, 102, 241, 0.08) 40%, transparent 70%);
    pointer-events: none;
    animation: isp-card-glow 6s ease-in-out infinite alternate;
}

@keyframes isp-card-glow {
    0% { transform: rotate(0deg) scale(1); }
    100% { transform: rotate(360deg) scale(1.1); }
}

/* ==========================================================================
   3. Internet Animation: Radar WiFi & Dual Neon Fiber Rings
   ========================================================================== */
.isp-anim-container {
    position: relative;
    width: 130px;
    height: 130px;
    margin: 0 auto 1.5rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Pulsing Radar WiFi Waves */
.isp-radar-wave {
    position: absolute;
    border-radius: 50%;
    border: 1.5px solid rgba(56, 189, 248, 0.5);
    box-shadow: 0 0 15px rgba(56, 189, 248, 0.4);
    opacity: 0;
    pointer-events: none;
}

.isp-radar-wave:nth-child(1) {
    width: 70px;
    height: 70px;
    animation: isp-radar-pulse 2.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) infinite;
}

.isp-radar-wave:nth-child(2) {
    width: 70px;
    height: 70px;
    animation: isp-radar-pulse 2.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) infinite;
    animation-delay: 0.8s;
}

.isp-radar-wave:nth-child(3) {
    width: 70px;
    height: 70px;
    animation: isp-radar-pulse 2.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) infinite;
    animation-delay: 1.6s;
}

@keyframes isp-radar-pulse {
    0% {
        transform: scale(0.6);
        opacity: 0.9;
        border-color: rgba(56, 189, 248, 0.8);
    }
    60% {
        opacity: 0.4;
    }
    100% {
        transform: scale(2.2);
        opacity: 0;
        border-color: rgba(147, 51, 234, 0.2);
    }
}

/* Outer High-Speed Orbital Fiber Ring */
.isp-orbit-outer {
    position: absolute;
    width: 116px;
    height: 116px;
    border-radius: 50%;
    border: 2px dashed rgba(56, 189, 248, 0.6);
    border-top-color: #38bdf8;
    border-right-color: #818cf8;
    box-shadow: 0 0 18px rgba(56, 189, 248, 0.5);
    animation: isp-orbit-clockwise 3s linear infinite;
}

/* Inner Counter-Rotating Orbital Ring */
.isp-orbit-inner {
    position: absolute;
    width: 86px;
    height: 86px;
    border-radius: 50%;
    border: 2px solid transparent;
    border-left-color: #06b6d4;
    border-bottom-color: #c084fc;
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.6);
    animation: isp-orbit-counter 2s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes isp-orbit-clockwise {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes isp-orbit-counter {
    0% { transform: rotate(360deg); }
    100% { transform: rotate(0deg); }
}

/* Central Glowing Orb & WiFi Signal */
.isp-core-node {
    position: relative;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0284c7 0%, #4f46e5 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 25px rgba(14, 165, 233, 0.8), inset 0 0 10px rgba(255, 255, 255, 0.4);
    z-index: 2;
    animation: isp-node-breathe 2s ease-in-out infinite alternate;
}

.isp-core-node i {
    font-size: 1.65rem;
    color: #ffffff;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.9));
    animation: isp-wifi-bounce 1.5s ease-in-out infinite;
}

@keyframes isp-node-breathe {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 20px rgba(14, 165, 233, 0.6), inset 0 0 8px rgba(255, 255, 255, 0.3);
    }
    100% {
        transform: scale(1.06);
        box-shadow: 0 0 35px rgba(56, 189, 248, 0.95), inset 0 0 14px rgba(255, 255, 255, 0.6);
    }
}

@keyframes isp-wifi-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-2px); }
}

/* ==========================================================================
   4. Typography & Shimmer Title
   ========================================================================= */
.isp-loading-title {
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    background: linear-gradient(135deg, #38bdf8 0%, #818cf8 50%, #c084fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
    display: block;
}

.isp-loading-desc {
    font-size: 0.85rem;
    color: #94a3b8;
    line-height: 1.45;
    margin-bottom: 1.25rem;
}

/* Live Network Status Indicator */
.isp-network-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(56, 189, 248, 0.2);
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 600;
    color: #38bdf8;
    letter-spacing: 0.5px;
    margin-bottom: 1.25rem;
}

.isp-ping-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #10b981;
    box-shadow: 0 0 10px #10b981;
    animation: isp-ping-blink 1.2s infinite;
}

@keyframes isp-ping-blink {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.3; transform: scale(0.7); }
}

/* ==========================================================================
   5. Cyber Fiber Progress Bar
   ========================================================================== */
.isp-progress-bar-wrap {
    width: 100%;
    height: 6px;
    background: rgba(30, 41, 59, 0.8);
    border-radius: 999px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 1rem;
}

.isp-progress-bar-glow {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, #38bdf8 30%, #818cf8 70%, transparent 100%);
    box-shadow: 0 0 15px #38bdf8;
    border-radius: 999px;
    animation: isp-progress-sweep 1.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes isp-progress-sweep {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Footer Company Badge */
.isp-engine-badge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 700;
    color: #64748b;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* ==========================================================================
   6. Custom Modern SweetAlert2 Skin for ISP Theme
   ========================================================================== */
.isp-swal-popup {
    border-radius: 20px !important;
    padding: 1.75rem 1.5rem !important;
    background: #ffffff !important;
    box-shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.25), 0 0 20px rgba(14, 165, 233, 0.15) !important;
    border: 1px solid rgba(226, 232, 240, 0.9) !important;
}

.isp-swal-title {
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    margin-top: 0.5rem !important;
    letter-spacing: -0.01em !important;
}

.isp-swal-html {
    font-size: 0.92rem !important;
    color: #475569 !important;
    line-height: 1.55 !important;
    margin: 0.75rem 0 1.25rem 0 !important;
}

.isp-swal-confirm-btn {
    border-radius: 10px !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    padding: 0.65rem 1.4rem !important;
    box-shadow: 0 4px 14px rgba(13, 110, 253, 0.3) !important;
    letter-spacing: 0.2px !important;
}

.isp-swal-confirm-danger-btn {
    border-radius: 10px !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    padding: 0.65rem 1.4rem !important;
    box-shadow: 0 4px 14px rgba(220, 53, 69, 0.3) !important;
    letter-spacing: 0.2px !important;
}

.isp-swal-cancel-btn {
    border-radius: 10px !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    padding: 0.65rem 1.4rem !important;
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    border: 1px solid #cbd5e1 !important;
}

.isp-swal-cancel-btn:hover {
    background-color: #e2e8f0 !important;
    color: #1e293b !important;
}
