/* ========================================
   JIVABOND Loading Animation - PROFESSIONAL MINIMAL
   ======================================== */

/* Loader Container */
#jivabond-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #0b1c31;
    /* Matches Hero Section */
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.6s;
    overflow: hidden;
}

#jivabond-loader.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* Loader Content Wrapper */
.loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    animation: content-reveal 0.8s ease-out;
}

/* Professional Spinner */
.professional-spinner {
    position: relative;
    width: 100px;
    height: 100px;
    margin-bottom: 30px;
}

.spinner-ring {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 3px solid rgba(120, 166, 90, 0.1);
    border-top-color: #78A65A;
    border-radius: 50%;
    animation: spin 1.2s cubic-bezier(0.5, 0.1, 0.4, 0.9) infinite;
}

.spinner-core {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px;
    height: 70px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(120, 166, 90, 0.4);
    animation: pulse 2s ease-in-out infinite;
}

.spinner-jb-svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* Brand Styles */
.brand-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.loader-logo-svg {
    width: 280px;
    height: auto;
    margin-bottom: 5px;
    filter: drop-shadow(0 0 15px rgba(120, 166, 190, 0.2));
    animation: content-reveal 1s ease-out;
}

.loading {
    --speed-of-animation: 0.9s;
    --gap: 6px;
    --first-color: #78A65A;
    --second-color: #28357F;
    --third-color: #78A65A;
    --fourth-color: #28357F;
    --fifth-color: #78A65A;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100px;
    gap: var(--gap);
    height: 60px;
    margin-top: 10px;
}

.loading span {
    width: 4px;
    height: 40px;
    background: var(--first-color);
    animation: scale var(--speed-of-animation) ease-in-out infinite;
    border-radius: 2px;
}

.loading span:nth-child(2) {
    background: var(--second-color);
    animation-delay: -0.8s;
}

.loading span:nth-child(3) {
    background: var(--third-color);
    animation-delay: -0.7s;
}

.loading span:nth-child(4) {
    background: var(--fourth-color);
    animation-delay: -0.6s;
}

.loading span:nth-child(5) {
    background: var(--fifth-color);
    animation-delay: -0.5s;
}

@keyframes scale {

    0%,
    40%,
    100% {
        transform: scaleY(0.1);
    }

    20% {
        transform: scaleY(1);
    }
}

/* Animations */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.8;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.1);
        opacity: 1;
    }
}

@keyframes content-reveal {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes expand-line {

    0%,
    100% {
        width: 0;
        opacity: 0;
    }

    50% {
        width: 100%;
        opacity: 1;
    }
}

@keyframes fade-status {

    0%,
    100% {
        opacity: 0.4;
    }

    50% {
        opacity: 1;
    }
}

@keyframes logo-reveal {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .loader-logo-svg {
        width: 220px;
    }

    .loader-status {
        font-size: 0.75rem;
        letter-spacing: 0.3rem;
    }

    .professional-spinner {
        width: 80px;
        height: 80px;
    }

    .spinner-core {
        width: 55px;
        height: 55px;
    }
}