/* Vibrant & Creative Modern Design System */
:root {
    --primary-color: #0076ff;
    --secondary-color: #7000ff;
    --accent-color: #ff00c8;
    --bg-light: #fdfdff;
    --bg-white: #ffffff;
    --bg-card: rgba(255, 255, 255, 0.7);
    --text-main: #1d1d1f;
    --text-muted: #6e6e73;
    --glass-border: rgba(255, 255, 255, 0.4);
    --premium-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

body {
    background-color: var(--bg-light);
    color: var(--text-main);
    font-family: 'Poppins', sans-serif !important;
    font-family: 'Poppins', sans-serif !important;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6,
.h1,
.h2,
.h3,
.h4,
.h5,
.h6 {
    font-family: 'Poppins', sans-serif !important;
}

/* Glassmorphism Light */
.glass-panel {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 30px;
    box-shadow: var(--premium-shadow);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.glass-panel:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 118, 255, 0.1);
    border-color: var(--primary-color);
}

/* Vibrant Text Gradient */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Mesh Gradient Background */
.mesh-gradient {
    background-color: #fff;
    background-image:
        radial-gradient(at 0% 0%, rgba(0, 118, 255, 0.1) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(112, 0, 255, 0.1) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(255, 0, 200, 0.1) 0px, transparent 50%),
        radial-gradient(at 0% 100%, rgba(0, 242, 255, 0.1) 0px, transparent 50%);
}

/* Hero Modern Light */
.hero-vibrant {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding: 100px 0;
}

/* Creative Floating Circles */
.blob {
    position: absolute;
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    filter: blur(80px);
    border-radius: 50%;
    z-index: -1;
    opacity: 0.15;
    animation: blobify 10s infinite alternate ease-in-out;
}

@keyframes blobify {
    0% {
        transform: translate(0, 0) scale(1);
        border-radius: 50% 50% 50% 50%;
    }

    50% {
        transform: translate(50px, -50px) scale(1.2);
        border-radius: 40% 60% 70% 30%;
    }

    100% {
        transform: translate(-30px, 40px) scale(0.9);
        border-radius: 60% 40% 30% 70%;
    }
}

/* Premium Button */
.btn-vibrant {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff !important;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    box-shadow: 0 10px 20px rgba(0, 118, 255, 0.3);
    transition: all 0.3s;
}

.btn-vibrant:hover {
    transform: scale(1.05);
    box-shadow: 0 15px 30px rgba(0, 118, 255, 0.4);
}

/* Service Grid */
.service-item-vibrant {
    padding: 50px;
    text-align: left;
}

.service-item-vibrant i {
    font-size: 2.5rem;
    margin-bottom: 25px;
    display: inline-block;
    padding: 15px;
    background: rgba(0, 118, 255, 0.05);
    border-radius: 12px;
}

/* Image Transitions */
.hover-scale {
    transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.hover-scale:hover {
    transform: scale(1.03);
}

/* Floating Glass Navbar Redesign */
.navbar-modern-floating {
    position: fixed;
    top: 25px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 100px;
    z-index: 10000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    padding: 10px 30px;
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.navbar-modern-floating.scrolled {
    top: 15px;
    width: 95%;
    padding: 8px 30px;
}

.navbar-modern-floating .navbar-brand {
    transform: none;
    transition: transform 0.3s;
}

.navbar-modern-floating .navbar-brand:hover {
    transform: translateY(-2px);
}

.navbar-modern-floating .nav-link {
    color: var(--text-main) !important;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 10px 15px !important;
    position: relative;
    transition: all 0.3s;
}

.navbar-modern-floating .nav-link::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    transition: all 0.3s;
    transform: translateX(-50%);
}

.navbar-modern-floating .nav-link:hover {
    color: var(--primary-color) !important;
}

.navbar-modern-floating .nav-link:hover::after {
    width: 50%;
}

.navbar-modern-floating .nav-item.active .nav-link {
    color: var(--primary-color) !important;
}

.navbar-modern-floating .nav-item.active .nav-link::after {
    width: 50%;
}

.navbar-modern-floating .navbar-nav {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.navbar-modern-floating .nav-item {
    list-style: none;
}

/* Dropdown styling */
.navbar-modern-floating .dropdown-menu {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-top: 15px;
    padding: 15px;
}

.navbar-modern-floating .dropdown-item {
    font-weight: 700;
    padding: 10px 20px;
    border-radius: 10px;
    transition: all 0.3s;
}

.navbar-modern-floating .dropdown-item:hover,
.navbar-modern-floating .dropdown-item.active {
    background: rgba(0, 118, 255, 0.1);
    color: var(--primary-color);
    font-weight: 800;
}

/* Mobile Responsive Navbar Override */
@media (max-width: 991px) {
    .navbar-modern-floating {
        width: 100%;
        max-width: 100%;
        top: 0;
        left: 0;
        transform: none;
        border-radius: 0 !important;
        padding: 15px 20px;
        background: rgba(255, 255, 255, 0.98);
        border: none;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }

    .navbar-modern-floating.scrolled {
        width: 100%;
        top: 0;
        border-radius: 0 !important;
        padding: 10px 20px;
    }

    .navbar-modern-floating .navbar-collapse {
        background: #ffffff;
        margin: 15px -20px -15px -20px;
        padding: 30px 20px;
        border-top: 1px solid rgba(0, 0, 0, 0.05);
        max-height: 85vh;
        overflow-y: auto;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    }

    .navbar-modern-floating .navbar-nav {
        text-align: center;
        width: 100%;
    }

    .navbar-modern-floating .nav-item {
        width: 100%;
        margin-bottom: 5px;
    }

    .navbar-modern-floating .nav-link {
        padding: 15px 0 !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.03);
        font-size: 1.1rem;
        font-weight: 700;
        color: var(--text-main);
        display: block;
        width: 100%;
    }

    .navbar-modern-floating .dropdown-menu {
        background: #f8f9fa;
        box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.03);
        border: none;
        padding: 15px;
        margin-top: 10px;
        border-radius: 16px;
        text-align: center;
        min-width: unset;
        width: 100%;
    }

    .navbar-modern-floating .dropdown-item {
        padding: 12px;
        margin-bottom: 5px;
        border-radius: 10px;
        font-weight: 600;
        color: var(--text-muted);
        white-space: normal;
    }

    .navbar-modern-floating .dropdown-item:last-child {
        margin-bottom: 0;
    }

    .navbar-modern-floating .dropdown-item:hover,
    .navbar-modern-floating .dropdown-item.active {
        background: #fff;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    }
}

/* FIX MOBILE NAVBAR STYLE - REMOVE BOOTSTRAP CONSTRAINTS */
@media (max-width: 991px) {

    /* 1. Reset Navbar Wrapper */
    #hlo-header-main.navbar-modern-floating,
    .navbar-modern-floating {
        width: 100% !important;
        max-width: 100% !important;
        left: 0 !important;
        top: 0 !important;
        right: 0 !important;
        transform: none !important;
        border-radius: 0 !important;
        margin: 0 !important;
        background: rgba(255, 255, 255, 0.98) !important;
        border: none !important;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05) !important;
        padding: 10px 0 !important;
        /* Remove horizontal padding here, handle in inner */
        position: fixed !important;
    }

    /* 2. KILL BOOTSTRAP CONTAINER RESTRICTIONS */
    .navbar-modern-floating .container,
    .navbar-modern-floating .container-fluid {
        position: static !important;
        /* Key fix: Dropdown will reference navbar, not container */
        width: 100% !important;
        max-width: none !important;
        padding-left: 20px !important;
        /* Add spacing for logo/toggle back manually */
        padding-right: 20px !important;
        margin: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
    }

    .hlo-nav-mobile-wrapper {
        padding: 0 10px;
    }

    /* 3. Full Screen Width Dropdown */
    .navbar-modern-floating .navbar-collapse {
        position: absolute !important;
        top: 100% !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 20px 0 !important;
        background: #ffffff !important;
        border-top: 1px solid rgba(0, 0, 0, 0.05) !important;
        box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1) !important;
        border-radius: 0 0 25px 25px !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }

    .navbar-modern-floating .navbar-nav {
        width: 100% !important;
        margin: 0 !important;
    }

    .navbar-modern-floating .nav-item {
        width: 100% !important;
        text-align: center;
        border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    }

    .navbar-modern-floating .nav-link {
        font-size: 1.1rem !important;
        padding: 15px 0 !important;
        display: block;
        width: 100%;
    }

    /* 4. Sub-menu Formatting */
    .navbar-modern-floating .dropdown-menu {
        position: static !important;
        float: none !important;
        background: #f4f6f8 !important;
        /* Darker bg for contrast */
        box-shadow: none !important;
        border: 1px solid rgba(0, 0, 0, 0.02) !important;
        border-radius: 12px !important;
        padding: 10px !important;
        margin: 10px 15px !important;
        /* Space from sides */
        width: auto !important;
        /* Let margin handle width */
        text-align: center !important;
    }

    .navbar-modern-floating .dropdown-item {
        text-align: center !important;
        padding: 12px !important;
        color: var(--text-muted) !important;
        white-space: normal !important;
    }

    .navbar-modern-floating .dropdown-item:hover {
        color: var(--primary-color) !important;
        background: none !important;
        font-weight: 700;
    }
}

/* FINAL OVERRIDE FOR MOBILE */
@media (max-width: 1024px) {

    #hlo-header-main.navbar-modern-floating,
    .navbar-modern-floating {
        width: 100% !important;
        left: 0 !important;
        transform: none !important;
    }
}

/* ===================================
   SECTION SPACING OPTIMIZATION
   Purpose: Reduce spacing between sections on homepage
   =================================== */

/* Reduce padding for all sections */
#main-content section {
    padding-top: 60px !important;
    padding-bottom: 60px !important;
}

/* Hero section - reduced height for compact banner */
.hero-vibrant {
    padding-top: 160px !important;
    padding-bottom: 50px !important;
    min-height: 75vh !important;
    /* Reduced from 100vh */
}

/* Hero title size adjustment */
.hero-vibrant h1 {
    font-size: clamp(3rem, 7vw, 5.5rem) !important;
}

.hero-vibrant p {
    font-size: 1.2rem !important;
    margin: 25px auto !important;
}

/* Specific section overrides */
#about-us {
    padding: 60px 0 !important;
}

#sectors {
    padding: 60px 0 !important;
}

#game-production {
    padding: 60px 0 !important;
}

#chatbot-production {
    padding: 60px 0 !important;
}

#camera-ai-security {
    padding: 50px 0 !important;
}

#erp-ai-system {
    padding: 50px 0 !important;
}

#film-studio {
    padding: 50px 0 !important;
}

/* Reduce bottom margin for section titles */
.onky-studio-context .text-center.mb-5 {
    margin-bottom: 2rem !important;
}

/* Reduce spacing in rows */
.onky-studio-context .row.mb-5 {
    margin-bottom: 2rem !important;
}

/* Reduce spacing between cards */
.onky-studio-context .mb-4 {
    margin-bottom: 1.5rem !important;
}

/* Reduce spacing in game cards */
.game-card-premium {
    margin-bottom: 2rem !important;
}

/* Reduce spacing in vertical galleries */
.vertical-gallery-grid {
    margin-top: 1.5rem !important;
}

/* Scroll To Top Button Premium */
.scrollToTop {
    display: none;
    /* Managed by JS */
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    z-index: 9999;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.2);

    /* Perfect Centering with Flexbox */
    display: flex;
    /* Override JS inline display if needed, but JS toggles this. JS usually sets display: block. We need !important or specific handling if JS uses fadeArgs */
    align-items: center;
    justify-content: center;
}

/* Fix for JS fadeIn/fadeOut which sets display: block */
.scrollToTop[style*="display: block"] {
    display: flex !important;
}

.scrollToTop i {
    font-size: 22px;
    background: linear-gradient(to bottom, var(--primary-color, #0076ff), var(--secondary-color, #7000ff));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
    /* Reset line-height */
    margin-top: -2px;
    /* Optical correction */
}

.scrollToTop:hover {
    transform: translateY(-5px) scale(1.1);
    background: rgba(255, 255, 255, 0.25);
    border-color: var(--primary-color);
    box-shadow: 0 15px 35px rgba(0, 118, 255, 0.3);
}

.scrollToTop::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 50%;
    border: 2px solid transparent;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) border-box;
    -webkit-background-clip: padding-box, border-box;
    background-clip: padding-box, border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: destination-out;
    mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    opacity: 0.5;
    animation: spin-slow 4s linear infinite;
}

@keyframes spin-slow {
    to {
        transform: rotate(360deg);
    }
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .scrollToTop {
        bottom: 25px;
        right: 25px;
        width: 45px;
        height: 45px;
    }

    .scrollToTop i {
        font-size: 20px;
    }
}

/* Mobile optimization - even tighter spacing */
@media (max-width: 768px) {
    #main-content section {
        padding-top: 40px !important;
        padding-bottom: 40px !important;
    }

    .hero-vibrant {
        padding-top: 160px !important;
        /* Increased for mobile to avoid navbar overlap */
        padding-bottom: 60px !important;
        min-height: 70vh !important;
    }

    /* Adjust hero text size for mobile */
    .hero-vibrant h1 {
        font-size: clamp(2rem, 8vw, 3.5rem) !important;
    }

    .hero-vibrant p {
        font-size: 1rem !important;
    }

    /* Push hero content down on mobile */
    .hero-vibrant .container {
        margin-top: 50px !important;
    }

    #camera-ai-security,
    #erp-ai-system,
    #film-studio {
        padding: 40px 0 !important;
    }

    /* Scroll To Top adjustment for mobile */
    .scrollToTop {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        line-height: 45px;
        font-size: 20px;
    }

    .scrollToTop i {
        line-height: 41px;
    }
}

/* Form Validation Styling - Premium Red */

.onky-studio-context label.error,

.onky-studio-context .field-validation-error,

.onky-studio-context .text-danger {

    color: #ff3b30 !important;

    /* Modern system red */

    font-size: 0.85rem !important;

    font-weight: 600 !important;

    margin-top: 8px !important;

    margin-bottom: 0 !important;

    display: block !important;

    transition: all 0.3s ease;

}



.onky-studio-context input.error,

.onky-studio-context textarea.error {

    border-color: #ff3b30 !important;

    background-color: rgba(255, 59, 48, 0.02) !important;

}

/* --- Game Video & Phone Mockup Enhancements --- */
.onky-studio-context .phone-mockup {
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: #000;
}

.onky-studio-context .phone-mockup video {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    display: block;
}

.video-overlay-fx {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 65px;
    height: 65px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease, visibility 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.video-overlay-fx::after {
    content: '\f04b';
    font-family: 'FontAwesome';
    color: #fff;
    font-size: 22px;
    margin-left: 5px;
    text-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.phone-mockup:hover .video-overlay-fx {
    transform: translate(-50%, -50%) scale(1.1);
    background: rgba(255, 255, 255, 0.25);
}

/* On mobile, ensure the controls and play button are centered */
@media (max-width: 768px) {
    .video-overlay-fx {
        width: 55px;
        height: 55px;
    }

    .video-overlay-fx::after {
        font-size: 18px;
    }
}