/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #0c1a21, #1a2d35);
    min-height: 100vh;
    color: white;
    overflow-x: hidden;
}

.container {
    width: 98%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header-container {
    width: 98%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 0 10px 0;
}

header {
    background: rgba(9, 51, 63, 0.95);
    position: relative;
    z-index: 10;
    border-radius: 40px;
    padding: 15px 25px;
    display: flex;
    align-items: center;
    gap: 15px;
    align-items: center;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(41, 219, 160, 0.1);
    position: relative;
    overflow: visible;
    transition: all 0.4s ease;
}
.brand-logo {
    height: 50px;        /* 🔑 controls size */
    width: auto;         /* keeps aspect ratio */
    object-fit: contain;
    display: block;
}
.logo img,
.logo img:focus,
.logo img:active {
    border: none;
    outline: none;
    box-shadow: none;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        rgba(41, 219, 160, 0.15) 0%, 
        rgba(255, 222, 89, 0.1) 100%);
    z-index: -1;
    opacity: 0;
    transition: opacity 0.5s ease;
}

header:hover::before {
    opacity: 1;
}
header,
.header-container,
.nav-links,
.nav-links li {
    overflow: visible !important;
}

.logo span {
    color: #ffde59;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.8rem;
    transition: all 0.3s ease;
    padding: 8px 15px;
    border-radius: 30px;
    flex-shrink: 0;          /* prevents logo compression */
    margin-right: auto;      /* pushes everything else right */
}

.logo:hover {
    transform: translateY(-2px);
    text-shadow: 0 0 15px rgba(41, 219, 160, 0.7);
}




.nav-links {
    display: flex;
    list-style: none;
    gap: 5px;
    background: rgba(255, 255, 255, 0.05);
    padding: 8px;
    border-radius: 30px;
    backdrop-filter: blur(5px);
}

.nav-links li {
    position: relative;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 25px;
    transition: all 0.3s ease;
    display: block;
    position: relative;
    overflow: hidden;
}

.nav-links a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.nav-links a:hover::before {
    left: 100%;
}

.dropdown > a:hover {
    transform: none !important;
}

.nav-links a.active {
    background: rgba(41, 219, 160, 0.2);
    color: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.header-buttons {
    display: flex;
    gap: 15px;
}

.btn {
    padding: 12px 25px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-login {
    background: transparent;
    color: #29dba0;
    border: 2px solid #29dba0;
}

.btn-login:hover {
    background: rgba(41, 219, 160, 0.1);
    box-shadow: 0 5px 15px rgba(41, 219, 160, 0.3);
    transform: translateY(-3px);
}

.btn-contact {
    background: linear-gradient(90deg, #29dba0, #1db886);
    color: #09333f;
    border: 2px solid transparent;
    font-weight: 700;
}

.btn-contact:hover {
    background: linear-gradient(90deg, #1db886, #29dba0);
    box-shadow: 0 5px 15px rgba(41, 219, 160, 0.4);
    transform: translateY(-3px);
}

.phone-icon {
    font-size: 0.9rem;
}

/* Responsive Header */

@media (max-width: 576px) {
    .logo {
        font-size: 1.5rem;
    }
    
    .nav-links a {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
    
    .btn {
        padding: 10px 18px;
        font-size: 0.9rem;
    }
}
/* Dropdown Menu Styles */
.dropdown.open .dropdown-menu {
    display: block;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dropdown-icon {
    font-size: 0.8em;
    transition: transform 0.3s ease;
}

.dropdown:hover .dropdown-icon {
    transform: rotate(180deg);
}

.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 12px;
    min-width: 260px;
    background: #09333f;
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    z-index: 99999;
    display: none;
}

.dropdown.open .dropdown-menu {
    display: block;
}
header,
.header-container,
.nav-links,
.nav-links li {
    overflow: visible !important;
}



.dropdown-item:hover {
    background: rgba(41, 219, 160, 0.15);
}

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #29dba0, #ffde59);
}

.dropdown-item {
    padding: 14px 22px;
    color: #ffffff;
    display: flex;
    gap: 12px;
    align-items: center;
}

.dropdown-item:hover {
    background: rgba(41, 219, 160, 0.15);
}
.dropdown-item:hover i {
    color: #29dba0;
    transform: scale(1.1);
}

.dropdown-item i {
    color: #ffde59;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

/* Subtle animation for dropdown items */
.dropdown-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: linear-gradient(to bottom, #29dba0, #ffde59);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.dropdown-item:hover::before {
    transform: scaleY(1);
}

/* Dropdown item hover glow effect */
.dropdown-item:hover {
    box-shadow: inset 0 0 20px rgba(41, 219, 160, 0.1);
}

/* Responsive dropdown for mobile */
@media (max-width: 992px) {
    .dropdown-menu {
        position: static;
        transform: none;
        opacity: 1;
        visibility: visible;
        display: none;
        background: rgba(255, 255, 255, 0.05);
        margin-top: 10px;
        border-radius: 15px;
    }
    
    .dropdown.active .dropdown-menu {
        display: block;
    }
    
    .dropdown-toggle {
        cursor: pointer;
    }
    
    .dropdown-item {
        padding: 12px 20px;
        font-size: 0.9rem;
    }
}
/* Alternative: Move dropdown inside a higher-level container */
.header-container {
    position: relative;
    overflow: visible;
}

/* Create a new wrapper for dropdown that's outside the header */

/* Add slight delay for smoother animation */
.dropdown-menu a:nth-child(1) { transition-delay: 0.05s; }
.dropdown-menu a:nth-child(2) { transition-delay: 0.1s; }
.dropdown-menu a:nth-child(3) { transition-delay: 0.15s; }
.dropdown-menu a:nth-child(4) { transition-delay: 0.2s; }
.dropdown-menu a:nth-child(5) { transition-delay: 0.25s; }
.dropdown-menu a:nth-child(6) { transition-delay: 0.3s; }
/* ====== DROPDOWN FIXES ====== */

/* Remove this if it exists - it's causing issues */
.dropdown.open .dropdown-menu {
    display: block;
}

/* Fix dropdown visibility */
.dropdown {
    position: relative;
    overflow: visible !important; /* Important */
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 10px); /* Add space below the toggle */
    left: 0;
    margin-top: 0; /* Remove margin-top */
    min-width: 260px;
    background: #09333f;
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    z-index: 99999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border: 1px solid rgba(41, 219, 160, 0.2);
}

/* Show dropdown on hover (Desktop) */
.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    display: block;
}

/* Show dropdown when active (Mobile) */
.dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    display: block;
}

/* Make sure header doesn't clip dropdown */
header {
    overflow: visible !important;
}

.header-container {
    overflow: visible !important;
}

/* Fix dropdown items to prevent interference */
.dropdown-item {
    position: relative;
    z-index: 2;
    padding: 14px 22px;
    color: #ffffff;
    display: flex;
    gap: 12px;
    align-items: center;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* Prevent text selection interference */
.dropdown-item * {
    pointer-events: none;
}

.dropdown-item:hover {
    background: rgba(41, 219, 160, 0.15);
    color: #29dba0;
    padding-left: 30px;
}

.dropdown-item:hover i {
    color: #29dba0;
    transform: scale(1.1);
}

.dropdown-item i {
    color: #ffde59;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

/* Smooth animation for dropdown */
@keyframes dropdownAppear {
    from {
        opacity: 0;
        transform: translateY(-10px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.dropdown:hover .dropdown-menu {
    animation: dropdownAppear 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Ensure dropdown stays open when hovering over it */
.dropdown-menu:hover {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Prevent click interference on dropdown toggle */
.dropdown-toggle {
    cursor: pointer;
    user-select: none;
}

/* Mobile specific fixes */
@media (max-width: 992px) {
    .dropdown-menu {
        position: static;
        top: auto;
        left: auto;
        transform: none !important;
        opacity: 1 !important;
        visibility: visible !important;
        display: none;
        background: rgba(255, 255, 255, 0.05);
        margin: 10px 0 0 15px;
        border-radius: 15px;
        box-shadow: inset 0 0 20px rgba(0,0,0,0.2);
        border: 1px solid rgba(255,255,255,0.1);
        animation: none !important;
    }
    
    .dropdown.active .dropdown-menu {
        display: block;
        animation: slideDown 0.3s ease;
    }
    
    @keyframes slideDown {
        from {
            opacity: 0;
            max-height: 0;
        }
        to {
            opacity: 1;
            max-height: 500px;
        }
    }
    
    .dropdown-item {
        padding: 12px 20px;
        font-size: 0.95rem;
    }
    
    .dropdown-item:hover {
        padding-left: 25px;
    }
}

/* Desktop: Keep dropdown open when clicking inside */
@media (min-width: 993px) {
    .dropdown-menu {
        pointer-events: auto;
    }
    
    /* Prevent dropdown from closing when clicking inside */
    .dropdown-menu:active,
    .dropdown-menu:focus-within {
        opacity: 1 !important;
        visibility: visible !important;
    }
}

/* Arrow for dropdown */
.dropdown-menu::after {
    content: '';
    position: absolute;
    top: -10px;
    left: 30px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid #09333f;
    z-index: 1000;
}
/* Prevent page jumping when clicking dropdown */
.dropdown-toggle[href="#"] {
    cursor: pointer;
}
/* ====== RESPONSIVE HEADER FIXES ====== */

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 10px;
    color: #29dba0;
    background: rgba(41, 219, 160, 0.1);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    justify-content: center;
    align-items: center;
    border: 2px solid rgba(41, 219, 160, 0.3);
    transition: all 0.3s ease;

    margin-left: 15px;
    flex-shrink: 0;
}


/* Tablet Styles */
@media (max-width: 992px) {
    .header-container {
        padding: 0 15px;
    }
    
    header {
        padding: 12px 20px;
        flex-wrap: wrap;
    }
    
    .nav-links {
        display: none;
        width: 100%;
        order: 3;
        margin-top: 15px;
        flex-direction: column;
        background: rgba(9, 51, 63, 0.95);
        padding: 15px;
        border-radius: 15px;
        gap: 10px;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-links li {
        width: 100%;
    }
    
    .nav-links a {
        padding: 12px 20px;
        border-radius: 10px;
        text-align: center;
    }
    
    .dropdown-menu {
        position: static !important;
        display: none !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        background: rgba(255, 255, 255, 0.05);
        margin: 10px 0;
        border-radius: 10px;
        box-shadow: none;
        border-left: 3px solid #29dba0;
        animation: none !important;
    }
    
    .dropdown.active .dropdown-menu {
        display: block !important;
    }
    
    .dropdown-item {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .header-buttons {
        margin-left: auto;
    }
    
    .mobile-menu-toggle {
        display: block;
        margin-left: 15px;
    }
    
    /* Remove dropdown arrow on mobile */
    .dropdown-menu::after {
        display: none;
    }
}

/* Mobile Styles */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: stretch;
        padding: 15px;
        border-radius: 20px;
    }
    
    .logo {
        justify-content: center;
        margin-bottom: 15px;
    }
    
    .mobile-menu-toggle {
        position: absolute;
        top: 20px;
        right: 20px;
    }
    
    .nav-links {
        margin-top: 20px;
    }
    
    .header-buttons {
        display: none;
        width: 100%;
        margin-top: 15px;
        justify-content: center;
        gap: 10px;
    }
    
    .header-buttons.active {
        display: flex;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
        flex: 1;
        justify-content: center;
    }
}

/* Small Mobile Styles */
@media (max-width: 576px) {
    .logo {
        font-size: 1.4rem;
    }
    
    .logo-icon {
        width: 35px;
        height: 35px;
        font-size: 1.2rem;
    }
    
    .nav-links a {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .dropdown-item {
        padding: 8px 15px;
        font-size: 0.85rem;
    }
    
    .btn {
        padding: 8px 15px;
        font-size: 0.85rem;
    }
}

/* Fix for Results button text color */
.btn-contact a {
    color: #09333f !important;
    font-weight: 600;
}

.btn-contact:hover a {
    color: #09333f !important;
}

/* Smooth animations */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav-links.active {
    animation: slideDown 0.3s ease forwards;
}

/* Desktop dropdown fix */
@media (min-width: 993px) {
    .dropdown:hover .dropdown-menu {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
}
@media (max-width: 768px) {
    .header-container {
        padding-top: 15px;
    }
}
@media (max-width: 480px) {
    .logo-text {
        font-size: 1.4rem;
    }
}
@media (max-width: 768px) {
    body {
        padding-left: 12px;
        padding-right: 12px;
    }
}
/* Form Error Messages */
.error-message {
    color: #ff6b6b;
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

/* Form Messages/Alerts */
#formMessages {
    margin-bottom: 20px;
}

.alert {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    animation: slideDown 0.3s ease;
}

.alert-success {
    background: linear-gradient(135deg, #29dba0, #1db886);
    color: white;
}

.alert-error {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
}

.alert i {
    margin-right: 10px;
    font-size: 18px;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 5px;
}

.close-btn:hover {
    opacity: 0.8;
}

@keyframes slideDown {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Form Validation Styling */
.form-control.error {
    border-color: #ff6b6b;
    box-shadow: 0 0 0 2px rgba(255, 107, 107, 0.2);
}

/* Loading spinner */
.fa-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}