/* =============================================================================
   PREMIUM GSAP ANIMATIONS & EFFECTS STYLESHEET
   ============================================================================= */

/* --- Scroll Progress Bar --- */
.scroll-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: #F4B400; /* Gold */
    z-index: 99999; /* Higher than navbar */
    pointer-events: none;
    transform-origin: left center;
}

/* --- Custom Cursor (Desktop Only) --- */
.custom-cursor-dot {
    width: 8px;
    height: 8px;
    background: #F4B400; /* Gold dot */
    position: fixed;
    top: 0;
    left: 0;
    border-radius: 50%;
    pointer-events: none;
    z-index: 100000;
    transition: width 0.2s cubic-bezier(0.25, 1, 0.5, 1), height 0.2s cubic-bezier(0.25, 1, 0.5, 1), background-color 0.2s ease;
    mix-blend-mode: normal;
}

.custom-cursor-ring {
    width: 36px;
    height: 36px;
    border: 2px solid #1E2D7D; /* Navy Blue ring */
    position: fixed;
    top: 0;
    left: 0;
    border-radius: 50%;
    pointer-events: none;
    z-index: 99999;
    mix-blend-mode: normal;
    transition: width 0.3s cubic-bezier(0.25, 1, 0.5, 1), height 0.3s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.3s ease, background-color 0.3s ease;
}

/* Active Hover cursor states */
.custom-cursor-ring.active {
    width: 54px;
    height: 54px;
    background: rgba(30, 45, 125, 0.12); /* Navy blue translucent fill */
    border-color: #F4B400; /* Gold ring */
}

.custom-cursor-dot.active {
    width: 0px; /* Hide dot or make small inside gold ring */
    height: 0px;
}

/* Active Click cursor state */
.custom-cursor-ring.clicking {
    width: 26px !important;
    height: 26px !important;
    background: rgba(244, 180, 0, 0.3) !important;
    border-color: #F4B400 !important;
    transition: width 0.15s cubic-bezier(0.25, 1, 0.5, 1), height 0.15s cubic-bezier(0.25, 1, 0.5, 1), background-color 0.15s ease, border-color 0.15s ease !important;
}

/* Hide default cursor on desktop when custom cursor is active (disabled per user request) */
/* html.has-custom-cursor,
html.has-custom-cursor body,
html.has-custom-cursor a,
html.has-custom-cursor button,
html.has-custom-cursor input,
html.has-custom-cursor textarea,
html.has-custom-cursor select {
    cursor: none !important;
} */

/* Hide custom cursor on touch/mobile devices */
@media (max-width: 1024px) {
    .custom-cursor-dot,
    .custom-cursor-ring {
        display: none !important;
    }
    html.has-custom-cursor,
    html.has-custom-cursor body,
    html.has-custom-cursor a,
    html.has-custom-cursor button,
    html.has-custom-cursor input,
    html.has-custom-cursor textarea,
    html.has-custom-cursor select {
        cursor: auto !important;
    }
}

/* --- Preloader / Loader --- */
#neci-preloader {
    position: fixed;
    inset: 0;
    z-index: 1000000; /* Highest priority */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: transparent; /* Transparent container so panels slide out */
}

/* Background panels splitting horizontally */
.preloader-bg-panel {
    position: absolute;
    left: 0;
    right: 0;
    height: 50.5vh; /* Slightly oversized to prevent gaps */
    background: #ffffff; /* Clean white theme */
    z-index: 1;
    will-change: transform;
}

.preloader-bg-panel.panel-top {
    top: 0;
    border-bottom: 1px solid rgba(27, 31, 107, 0.04);
}

.preloader-bg-panel.panel-bottom {
    bottom: 0;
    border-top: 1px solid rgba(27, 31, 107, 0.04);
}

/* Glowing horizontal separator line during split */
.preloader-split-glow {
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    height: 2px;
    background: linear-gradient(to right, transparent, #F4B400, transparent);
    box-shadow: 0 0 10px rgba(244, 180, 0, 0.4), 0 0 25px rgba(244, 180, 0, 0.15);
    z-index: 2;
    transform: translateY(-50%);
    pointer-events: none;
    opacity: 0; /* Hidden during loading to prevent overlap with centered brand text */
    display: none !important; /* Disabled to completely prevent the yellow line from showing after 100% load */
    will-change: opacity, transform;
}

.loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 3; /* Sit above the background panels */
    position: relative;
}

/* Logo Wrapper */
.loader-logo-wrapper {
    position: relative;
    margin-bottom: 25px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.loader-logo-wrapper img {
    width: 150px; /* Properly visible and sized */
    height: auto;
    max-height: 80px;
    object-fit: contain;
    z-index: 2;
    filter: drop-shadow(0 4px 8px rgba(27, 31, 107, 0.06));
}

#loader-brand {
    font-family: "Outfit", "Inter", sans-serif;
    color: #1F2A7A; /* Corporate Navy */
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-top: 5px;
    margin-bottom: 25px;
}

#loader-brand span {
    color: #F4B400; /* Gold */
    font-weight: 800;
}

/* Progress bar container and components */
.loader-progress-container {
    width: 280px;
    margin-top: 5px;
    display: flex;
    flex-direction: column;
}

.loader-meta {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 8px;
}

#loader-status {
    font-family: "Inter", sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    color: #64748b; /* Slate Grey */
    text-transform: uppercase;
    letter-spacing: 0.12em;
    text-align: left;
    min-height: 16px;
    animation: loaderStatusPulse 1.8s ease-in-out infinite alternate;
}

#loader-progress {
    font-family: "Outfit", "Inter", sans-serif;
    font-size: 1.05rem;
    font-weight: 800;
    color: #1F2A7A; /* Corporate Navy */
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.01em;
}

.loader-bar-wrap {
    position: relative;
    width: 100%;
    height: 4px;
    background: rgba(27, 31, 107, 0.06);
    border-radius: 4px;
    margin-top: 24px; /* Increased spacing to guarantee progress bar does not touch the status text above */
}

#loader-bar {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0%;
    background: #F4B400; /* Gold */
    border-radius: 4px;
    transition: width 0.1s linear;
}

#loader-bar-glow {
    position: absolute;
    top: 50%;
    left: 0%;
    width: 10px;
    height: 10px;
    background: #F4B400;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 8px #F4B400, 0 0 16px #F4B400;
    pointer-events: none;
    transition: left 0.1s linear;
}

@keyframes loaderStatusPulse {
    0% {
        opacity: 0.6;
    }
    100% {
        opacity: 1;
    }
}

/* --- Dynamic GSAP Reveal Classes --- */
.gsap-reveal {
    opacity: 0;
    visibility: hidden;
    will-change: transform, opacity;
}

/* --- Product Cards Premium Hover Effect --- */
.catalog-product-card {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.catalog-product-card:hover {
    transform: translateY(-10px) !important;
    box-shadow: 0 24px 48px rgba(30, 45, 125, 0.14) !important;
}

.catalog-product-card .catalog-product-media img {
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.catalog-product-card:hover .catalog-product-media img {
    transform: scale(1.08) !important;
}

/* --- Gallery Premium Zoom & Glow --- */
.gallery-item {
    position: relative;
    border: 2px solid transparent !important;
    border-radius: 12px !important;
    overflow: hidden;
    transition: border-color 0.4s ease, box-shadow 0.4s ease !important;
}

.gallery-item:hover {
    border-color: #F4B400 !important;
    box-shadow: 0 0 20px rgba(244, 180, 0, 0.35) !important;
}

.gallery-item img {
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.gallery-item:hover img {
    transform: scale(1.06) !important;
}

/* --- Form Fields Label Transition --- */
.form-group-floating {
    position: relative;
    margin-bottom: 24px;
}

.form-group-floating label {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    color: var(--neci-muted, #718096);
    padding: 0 4px;
    pointer-events: none;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    font-size: 0.95rem;
    font-weight: 500;
}

.form-group-floating textarea ~ label {
    top: 24px;
    transform: none;
}

.form-group-floating input:focus ~ label,
.form-group-floating input:not(:placeholder-shown) ~ label,
.form-group-floating textarea:focus ~ label,
.form-group-floating textarea:not(:placeholder-shown) ~ label {
    top: 0;
    transform: translateY(-50%) scale(0.85);
    background: #ffffff;
    color: #1E2D7D;
    font-weight: 600;
    left: 12px;
}

/* Ripple Click Effect */
.ripple-btn {
    position: relative;
    overflow: hidden;
}

.btn-ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.45);
    transform: scale(0);
    pointer-events: none;
}

@keyframes btn-ripple-anim {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Client logos premium effects */
.client-logo-box {
    filter: none !important; /* Always colored by default */
    opacity: 0.8;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.client-logo-box:hover {
    opacity: 1;
    transform: scale(1.1);
    filter: drop-shadow(0 0 8px rgba(244, 180, 0, 0.4)) !important;
}

/* Float Animation for Mission/Vision Cards */
@keyframes neciFloat {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
    100% { transform: translateY(0px); }
}

.float-hover:hover {
    animation: neciFloat 4s ease-in-out infinite;
}
