/* ======================================
   Hyderabad Safety Nets - Premium Design
   Proprietor: Nagu Koda
   Modern UI/UX with Animations
   ====================================== */

/* === ROOT VARIABLES === */
:root {
    /* Brand Colors - VIBRANT UPDATE */
    --primary-blue: #0077FF;
    /* Electric Blue */
    --primary-dark: #0055CC;
    --primary-light: #33A3FF;
    --secondary-orange: #FF6B35;
    /* Energetic Orange */
    --secondary-dark: #E64525;
    --accent-green: #00D97E;
    /* Fresh Green */
    --accent-light: #4FFFB0;

    /* Neutrals */
    --dark: #0F1419;
    /* Deeper Dark */
    --gray-dark: #2D3748;
    --gray-medium: #718096;
    --gray-light: #A0AEC0;
    --bg-light: #F7FAFC;
    --bg-white: #FFFFFF;

    /* Gradients - ENHANCED */
    --gradient-primary: linear-gradient(135deg, #0077FF 0%, #00C9FF 100%);
    /* Blue Cyan */
    --gradient-secondary: linear-gradient(135deg, #FF6B35 0%, #FFAA00 100%);
    /* Orange Yellow */
    --gradient-accent: linear-gradient(135deg, #00D97E 0%, #00F5A0 100%);
    /* Green */
    --gradient-dark: linear-gradient(135deg, #1A1A2E 0%, #16213E 100%);
    --gradient-hero: linear-gradient(135deg, rgba(0, 119, 255, 0.95) 0%, rgba(26, 26, 46, 0.90) 100%);

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 119, 255, 0.15);
    /* Blue tinted shadow */
    --shadow-xl: 0 20px 40px rgba(0, 119, 255, 0.2);
    --shadow-glow: 0 0 30px rgba(0, 119, 255, 0.4);
    /* Stronger glow */

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-xxl: 4rem;

    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Transitions */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);

    /* Border Radius */
    --radius-sm: 0.5rem;
    --radius-md: 1rem;
    --radius-lg: 1.5rem;
    --radius-xl: 2rem;
    --radius-full: 9999px;
}

/* === DARK MODE THEME === */
[data-theme="dark"] {
    --bg-white: #0F1419;
    --bg-light: #151A21;
    --dark: #FFFFFF;
    --gray-dark: #E2E8F0;
    --gray-medium: #CBD5E0;
    --gray-light: #4A5568;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.7);

    /* Adjust gradients for dark mode to be slightly more vibrant */
    --gradient-hero: linear-gradient(135deg, rgba(0, 0, 0, 0.9) 0%, rgba(20, 20, 20, 0.95) 100%);
}

/* Dark Mode Transitions */
body,
.service-card,
.feature-card,
.testimonial-card-slider,
.navbar {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* === GLOBAL RESET & BASE === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

html,
body {
    overflow-x: hidden;
    /* Standard overflow fix */
    width: 100%;
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
    touch-action: manipulation;
}

body {
    font-family: var(--font-body);
    color: var(--gray-dark);
    line-height: 1.7;
    /* Increased for readability */
    background-color: var(--bg-white);
    font-size: 1.05rem;
    /* Larger base font */
}

/* === TYPOGRAPHY === */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 800;
    /* Bolder headings */
    line-height: 1.2;
    color: var(--dark);
    margin-bottom: var(--spacing-md);
}

h1 {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    /* Bolder scaling */
}

h2 {
    font-size: clamp(2rem, 5vw, 3rem);
    /* Bolder scaling */
}

h3 {
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    /* Bolder scaling */
}

h4 {
    font-size: clamp(1.4rem, 3vw, 1.75rem);
    /* Bolder scaling */
}

h5 {
    font-size: 1.125rem;
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: var(--spacing-sm);
    color: #4A5568;
    /* Darker, more visible gray */
}

a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: var(--transition-base);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

ul {
    margin-bottom: var(--spacing-sm);
}

li {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

/* === UTILITY CLASSES === */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.container-fluid {
    width: 100%;
    padding: 0 var(--spacing-md);
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 calc(var(--spacing-sm) * -1);
}

.col {
    flex: 1;
    padding: 0 var(--spacing-sm);
    min-width: 0;
    /* Prevent overflow */
}

@media (max-width: 991px) {
    .col {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .row {
        flex-direction: column;
    }

    .about .row {
        flex-direction: column;
    }

    .about .col:first-child {
        margin-bottom: var(--spacing-xl);
    }

    .about img {
        margin-top: 1rem;
        width: 100% !important;
        max-width: 600px;
        /* Large but capped for quality */
        margin-left: auto;
        margin-right: auto;
    }
}

.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.mt-1 {
    margin-top: var(--spacing-xs);
}

.mt-2 {
    margin-top: var(--spacing-sm);
}

.mt-3 {
    margin-top: var(--spacing-md);
}

.mt-4 {
    margin-top: var(--spacing-lg);
}

.mt-5 {
    margin-top: var(--spacing-xl);
}

.mb-1 {
    margin-bottom: var(--spacing-xs);
}

.mb-2 {
    margin-bottom: var(--spacing-sm);
}

.mb-3 {
    margin-bottom: var(--spacing-md);
}

.mb-4 {
    margin-bottom: var(--spacing-lg);
}

.mb-5 {
    margin-bottom: var(--spacing-xl);
}

.py-1 {
    padding-top: var(--spacing-xs);
    padding-bottom: var(--spacing-xs);
}

.py-2 {
    padding-top: var(--spacing-sm);
    padding-bottom: var(--spacing-sm);
}

.py-3 {
    padding-top: var(--spacing-md);
    padding-bottom: var(--spacing-md);
}

.py-4 {
    padding-top: var(--spacing-lg);
    padding-bottom: var(--spacing-lg);
}

.py-5 {
    padding-top: var(--spacing-xl);
    padding-bottom: var(--spacing-xl);
}

/* === SECTION STYLING === */
.section {
    padding: var(--spacing-xxl) 0;
    position: relative;
}

.section-title {
    text-align: center;
    margin-bottom: var(--spacing-xl);
    position: relative;
}

.section-title h2 {
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
}

.section-subtitle {
    color: var(--primary-blue);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.875rem;
    margin-bottom: var(--spacing-sm);
}

/* === BUTTON STYLES === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--radius-full);
    border: none;
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    z-index: 5;
    gap: 0.5rem;
    pointer-events: auto !important;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: width var(--transition-base);
    z-index: -1;
}

.btn:hover::before {
    width: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--bg-white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--gradient-secondary);
    color: var(--bg-white);
    box-shadow: var(--shadow-md);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
}

.btn-outline:hover {
    background: var(--primary-blue);
    color: var(--bg-white);
}

.btn-lg {
    padding: 1.25rem 2.5rem;
    font-size: 1.125rem;
}

.btn-sm {
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
}

/* === NAV CTA BUTTON (Call Now in header) === */
.nav-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.45rem 1.2rem;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: #fff;
    text-decoration: none;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    border: none;
    cursor: pointer;
    white-space: nowrap;
    line-height: 1.4;
    box-shadow: 0 4px 14px rgba(0, 119, 255, 0.35);
    transition: all 0.25s ease;
    letter-spacing: 0.3px;
}

.nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 119, 255, 0.5);
    color: #fff;
    background: linear-gradient(135deg, #0055CC 0%, #0099EE 100%);
}

.nav-cta i {
    font-size: 0.8rem;
}

/* === HEADER & NAVIGATION === */
.top-bar {
    background: var(--dark);
    color: var(--bg-white);
    padding: var(--spacing-xs) 0;
    font-size: 0.875rem;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.top-bar-info {
    display: flex;
    gap: var(--spacing-lg);
    flex-wrap: wrap;
}

.top-bar-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.top-bar-item i {
    color: var(--secondary-orange);
}

.top-bar-links {
    display: flex;
    gap: var(--spacing-md);
}

.top-bar-links a {
    color: var(--bg-white);
    transition: var(--transition-fast);
}

.top-bar-links a:hover {
    color: var(--secondary-orange);
}

/* Main Header */
.header {
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition-base);
    height: 130px;
    /* Increased height for larger logo */
    display: flex;
    align-items: center;
}

.header.scrolled {
    box-shadow: var(--shadow-md);
    height: 110px;
}

.header-content {
    display: flex;
    /* Flexbox for clean Logo-Left / Nav-Right layout */
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
    width: 100%;
    max-width: 1400px;
    /* Prevent it from getting too wide on ultrawide screens */
    margin: 0 auto;
}

/* Logo Branding: Center Stage & Premium */
.logo {
    display: flex;
    align-items: center;
    position: relative;
    z-index: 10;
    flex-shrink: 0;
    /* Prevent logo from squishing */
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 15px;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.logo-link:hover {
    transform: scale(1.02);
}

.logo-img {
    height: 100px;
    /* Clean standard size */
    width: auto;
    object-fit: contain;
    mix-blend-mode: multiply;
    transition: transform 0.4s ease;
    /* Remove shadow to let image be clean */
}

.logo-link:hover .logo-img {
    transform: rotate(-3deg) scale(1.05);
}

.logo-text-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1;
    justify-content: center;
}

.logo-main-text {
    font-family: var(--font-heading);
    font-size: 4rem;
    /* Larger, more dominant text */
    font-weight: 900;
    /* Multi-Color Gradient */
    background: linear-gradient(to right, #0077FF 0%, #00C6FF 30%, #9333EA 60%, #FF6B35 100%);
    background-size: 300% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: #0077FF;
    text-transform: uppercase;
    letter-spacing: -2px;
    margin: 0;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
    position: relative;
    animation: shineText 4s linear infinite;
}

/* Shine Animation for Text */
@keyframes shineText {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.logo-sub-text {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 800;
    color: #FF6B35;
    text-transform: uppercase;
    letter-spacing: 6px;
    margin-top: 2px;
    margin-left: 4px;
    text-shadow: 0 1px 2px rgba(255, 107, 53, 0.1);
}

/* Nav moves to the right */
.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

@media (max-width: 991px) {
    .header {
        height: auto;
        padding: 0.5rem 0;
        overflow: visible;
    }

    .header-content {
        padding: 0.5rem 1rem;
        /* Ensure space between logo and burger menu */
        justify-content: space-between;
    }

    .logo-link {
        gap: 12px;
        /* Slightly tighter gap on mobile */
        flex-shrink: 0;
        max-width: 80%;
        /* Prevent logo from overlapping menu */
    }

    /* Fix: Keep logo scaled up on interaction */
    .logo-link:active .logo-img,
    .logo-link:focus .logo-img,
    .logo-link:hover .logo-img {
        transform: scale(1.1);
        /* Tame the zoom on mobile */
    }

    .logo-img {
        height: 50px !important;
        /* Reset to reasonable mobile size */
        /* Better Fit */
        max-width: none !important;
        width: auto;
        transform: none;
        /* Reset desktop transform */
        margin-left: 0;
        margin-right: 0;
        mix-blend-mode: multiply;
        object-fit: contain;
    }

    .logo-text-wrapper {
        margin-left: 0;
        z-index: 5;
    }

    /* Logo Styles handled in the mobile optimization section at the bottom for better control */
}

/* Navigation */
.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
    /* Increased spacing */
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    /* Increased spacing between items */
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    color: var(--gray-dark);
    font-weight: 500;
    font-size: 15px;
    padding: 0.75rem 0;
    position: relative;
    transition: var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    white-space: nowrap;
}

/* Chevron icon styling */
.nav-link i.fa-chevron-down {
    font-size: 10px;
    transition: transform 0.3s ease;
    opacity: 0.6;
}

.nav-item.dropdown:hover .nav-link i.fa-chevron-down {
    transform: rotate(180deg);
    opacity: 1;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-blue);
    transition: width var(--transition-base);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--primary-blue);
}

/* Dropdown - FIXED to prevent disappearing */
.nav-item.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    /* Increased gap */
    left: 0;
    min-width: 250px;
    background: var(--bg-white);
    box-shadow: 0 10px 40px rgba(0, 119, 255, 0.15);
    border-radius: var(--radius-md);
    padding: 0.75rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 9999;
    list-style: none;
    pointer-events: none;
    margin-top: 0;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* IMPORTANT: Activate dropdown on hover of parent OR menu */
.nav-item.dropdown:hover .dropdown-menu,
.dropdown-menu:hover {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown-item {
    padding: 0.65rem 1rem;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    margin: 0.15rem 0;
    list-style: none;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, #0077FF 0%, #33A3FF 100%);
    transform: translateX(5px);
}

.dropdown-item:hover a {
    color: var(--bg-white) !important;
}

.dropdown-item a {
    color: var(--gray-dark);
    display: block;
    font-weight: 500;
    font-size: 14px;
    text-decoration: none;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 0.25rem;
    cursor: pointer;
    padding: var(--spacing-xs);
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--dark);
    border-radius: var(--radius-full);
    transition: var(--transition-base);
}

/* === HERO SECTION === */
.hero {
    position: relative;
    min-height: 650px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: #000;
}

.hero-slider-bg-wrapper {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 0;
    overflow: hidden;
}

.hero-slide-bg {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.5s ease-in-out, transform 8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-transform-style: preserve-3d;
    transform-style: preserve-3d;
    -webkit-transform: scale(1.0) translate3d(0, 0, 0);
    transform: scale(1.0) translate3d(0, 0, 0);
    will-change: transform, opacity;
}

.hero-slide-bg.active {
    opacity: 0.80;
    -webkit-transform: scale(1.08) translate3d(0, 0, 0);
    transform: scale(1.08) translate3d(0, 0, 0);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.1) 100%);
    z-index: 1;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 100;
    /* Higher than any overlay */
    color: var(--bg-white);
    pointer-events: auto;
}

.hero-slider {
    position: relative;
}

.hero-slide {
    display: none;
    animation: fadeIn var(--transition-slow);
    position: relative;
    padding-right: 0;
    /* Removed large padding that was causing mobile overflow */
}

.hero-slide.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}



.hero-slide p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: var(--spacing-lg);
}

.hero-cta {
    display: flex;
    gap: var(--spacing-md);
    flex-wrap: wrap;
}

/* Hero Stats */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-xl);
}

.stat-item {
    text-align: center;
    padding: var(--spacing-lg);
    background: rgba(255, 255, 255, 0.03);
    /* Ultra transparent */
    backdrop-filter: blur(20px);
    /* Heavy Blur */
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    /* Top highlight */
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 2;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    color: var(--secondary-orange);
    display: block;
    line-height: 1.2;
}

.stat-label {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* === FEATURES SECTION === */
.features {
    background: var(--bg-light);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
}

.feature-card {
    background: var(--bg-white);
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-align: center;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.feature-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
    transform-origin: center;
}

@media (hover: hover) {
    .feature-card:hover::after {
        transform: scaleX(1);
    }

    .feature-card:hover {
        transform: translateY(-10px);
        box-shadow: var(--shadow-lg);
    }
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--spacing-md);
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--bg-white);
}

.feature-card h3 {
    color: var(--dark);
    margin-bottom: var(--spacing-sm);
}

.feature-card p {
    color: var(--gray-medium);
}

/* === SERVICES SECTION === */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--spacing-lg);
}

.service-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
    position: relative;
}

.service-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

@media (hover: hover) {
    .service-card:hover {
        transform: translateY(-5px);
        box-shadow: var(--shadow-xl);
    }

    .service-card:hover .service-image img {
        transform: scale(1.1);
    }
}

.service-badge {
    position: absolute;
    top: var(--spacing-sm);
    right: var(--spacing-sm);
    background: var(--secondary-orange);
    color: var(--bg-white);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
}

.service-content {
    padding: var(--spacing-lg);
}

.service-content h3 {
    margin-bottom: var(--spacing-sm);
}

.service-content p {
    margin-bottom: var(--spacing-md);
    color: var(--gray-medium);
}

.service-features {
    list-style: none;
    margin-bottom: var(--spacing-md);
}

.service-features li {
    padding: 0.5rem 0;
    color: var(--gray-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.service-features li::before {
    content: '\2713';
    /* Unicode Checkmark */
    color: var(--accent-green);
    font-weight: 700;
}

.service-actions {
    display: flex;
    gap: var(--spacing-sm);
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--bg-light);
}

.service-actions .btn {
    flex: 1;
}

/* === FLOATING CONTACT BUTTONS === */
.floating-contacts {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.floating-btn {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    transition: all var(--transition-base);
    font-size: 1.5rem;
    color: var(--bg-white);
    text-decoration: none;
}

.floating-btn:hover {
    transform: scale(1.1);
}

.floating-phone {
    background: var(--gradient-primary);
}

.floating-whatsapp {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
}

/* === TESTIMONIALS SECTION - PREMIUM DESIGN === */
.testimonials {
    background: linear-gradient(135deg, #F7FAFC 0%, #E2E8F0 100%);
    position: relative;
    overflow: hidden;
}

/* Grid Layout for Reviews */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--spacing-lg);
    max-width: 1200px;
    margin: 0 auto;
}

/* Testimonial Card - Beautiful Design */
.testimonial-card {
    background: var(--bg-white);
    padding: var(--spacing-lg);
    border-radius: var(--radius-xl);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 10px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 5rem;
    color: rgba(0, 119, 255, 0.08);
    font-family: Georgia, serif;
    line-height: 1;
    z-index: 0;
}

@media (hover: hover) {
    .testimonial-card:hover {
        transform: translateY(-8px) scale(1.02);
        box-shadow: 0 12px 24px rgba(0, 119, 255, 0.15), 0 8px 16px rgba(0, 0, 0, 0.1);
        border-color: rgba(0, 119, 255, 0.3);
    }
}

/* Header with Avatar */
.testimonial-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
    position: relative;
    z-index: 1;
}

.author-avatar {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-white);
    font-size: 1.5rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.author-info {
    text-align: left;
}

.author-info h4 {
    margin: 0;
    color: var(--dark);
    font-size: 1.125rem;
    font-weight: 600;
}

.author-info p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--gray-medium);
}

/* Animated Star Rating */
.testimonial-rating {
    margin: var(--spacing-md) 0;
    display: flex;
    gap: 0.25rem;
    justify-content: flex-start;
    position: relative;
    z-index: 1;
}

.testimonial-rating i {
    color: #FFB800;
    font-size: 1.125rem;
    animation: starPulse 3s ease-in-out infinite;
    transition: all 0.3s ease;
}

/* Staggered animation for each star */
.testimonial-rating i:nth-child(1) {
    animation-delay: 0s;
}

.testimonial-rating i:nth-child(2) {
    animation-delay: 0.1s;
}

.testimonial-rating i:nth-child(3) {
    animation-delay: 0.2s;
}

.testimonial-rating i:nth-child(4) {
    animation-delay: 0.3s;
}

.testimonial-rating i:nth-child(5) {
    animation-delay: 0.4s;
}

/* Star Pulse Animation */
@keyframes starPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.15);
        opacity: 0.85;
        filter: drop-shadow(0 0 8px rgba(255, 184, 0, 0.6));
    }
}

/* Hover effect on stars */
.testimonial-card:hover .testimonial-rating i {
    transform: scale(1.2) rotate(15deg);
    filter: drop-shadow(0 0 10px rgba(255, 184, 0, 0.8));
}

.testimonial-card:hover .testimonial-rating i:nth-child(odd) {
    transform: scale(1.2) rotate(-15deg);
}

/* Testimonial Text */
.testimonial-text {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--gray-dark);
    margin: var(--spacing-md) 0;
    font-style: italic;
    position: relative;
    z-index: 1;
}

/* Service Badge */
.testimonial-service {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, rgba(0, 119, 255, 0.1) 0%, rgba(0, 201, 255, 0.1) 100%);
    border: 1px solid rgba(0, 119, 255, 0.2);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary-blue);
    margin-top: var(--spacing-md);
    transition: all 0.3s ease;
}

.testimonial-card:hover .testimonial-service {
    background: linear-gradient(135deg, rgba(0, 119, 255, 0.15) 0%, rgba(0, 201, 255, 0.15) 100%);
    border-color: rgba(0, 119, 255, 0.4);
    transform: scale(1.05);
}


/* === FOOTER === */
.footer {
    background: var(--gradient-dark);
    color: rgba(255, 255, 255, 0.8);
    padding: var(--spacing-xxl) 0 var(--spacing-lg);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-xl);
    margin-bottom: var(--spacing-xl);
}

.footer-section h3 {
    color: var(--bg-white);
    margin-bottom: var(--spacing-md);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: var(--spacing-sm);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--secondary-orange);
    padding-left: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--spacing-md);
    text-align: center;
    font-size: 0.875rem;
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .nav-menu {
        gap: var(--spacing-md);
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
        z-index: 1001;
    }

    .logo-text h1 {
        font-size: 1.1rem;
    }

    .logo-img {
        width: 45px;
        height: 45px;
        font-size: 1.25rem;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100vh;
        background: var(--bg-white);
        flex-direction: column;
        justify-content: flex-start;
        padding: 80px 30px 30px;
        box-shadow: none;
        transform: translateX(100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.5s cubic-bezier(0.77, 0, 0.175, 1);
        z-index: 1000;
        overflow-y: auto;
        gap: 0;
    }

    .nav-menu.active {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-item {
        width: 100%;
        margin: 0;
        border-bottom: 1px solid var(--bg-light);
    }

    .nav-link {
        display: block;
        padding: 15px 10px;
        font-size: 1.1rem;
        width: 100%;
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        padding: 0 0 0 20px;
        min-width: auto;
        width: 100%;
        background: var(--bg-light);
        margin-top: 0;
    }

    .dropdown-item {
        padding: 12px 15px;
        margin: 0;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }

    .dropdown-item a {
        font-size: 1rem;
    }

    .hero-cta {
        flex-direction: column;
    }

    .floating-contacts {
        right: 10px;
        bottom: 180px;
        /* Move above footer */
        gap: 8px;
    }

    .floating-btn {
        width: 48px;
        height: 48px;
        font-size: 1.15rem;
    }

    /* Ensure footer is visible */
    footer {
        position: relative;
        z-index: 1;
        padding-bottom: 20px;
    }
}


@media (max-width: 480px) {
    :root {
        font-size: 14px;
    }

    .hero-stats {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
    }

    .stat-item {
        padding: var(--spacing-md);
    }

    .features-grid,
    .services-grid,
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
}

/* === ANIMATIONS === */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.animate-slide-up {
    animation: slideInUp 0.6s ease-out;
}

.animate-slide-right {
    animation: slideInRight 0.6s ease-out;
}

.animate-pulse {
    animation: pulse 2s infinite;
}

/* Loading Animation */
.loader {
    width: 50px;
    height: 50px;
    border: 5px solid var(--bg-light);
    border-top-color: var(--primary-blue);
    border-radius: var(--radius-full);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* === ENHANCED VISIBLE ANIMATIONS === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }

    70% {
        transform: scale(0.9);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes slideInFromLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInFromRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes glow {

    0%,
    100% {
        box-shadow: 0 0 5px rgba(0, 102, 204, 0.5);
    }

    50% {
        box-shadow: 0 0 20px rgba(0, 102, 204, 0.8);
    }
}

/* Animation Classes */
.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.animate-fade-in-down {
    animation: fadeInDown 0.8s ease-out forwards;
}

.animate-fade-in-left {
    animation: fadeInLeft 0.8s ease-out forwards;
}

.animate-fade-in-right {
    animation: fadeInRight 0.8s ease-out forwards;
}

.animate-zoom-in {
    animation: zoomIn 0.6s ease-out forwards;
}

.animate-bounce-in {
    animation: bounceIn 0.8s ease-out forwards;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-glow {
    animation: glow 2s ease-in-out infinite;
}

/* Delay Classes */
.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

.delay-400 {
    animation-delay: 0.4s;
}

.delay-500 {
    animation-delay: 0.5s;
}

.delay-600 {
    animation-delay: 0.6s;
}

.delay-700 {
    animation-delay: 0.7s;
}

.delay-800 {
    animation-delay: 0.8s;
}

/* Initial Hidden State for Animated Elements */
.animate-fade-in-up,
.animate-fade-in-down,
.animate-fade-in-left,
.animate-fade-in-right,
.animate-zoom-in,
.animate-bounce-in {
    opacity: 0;
}

/* Service Card Enhanced Animation */
.service-card {
    animation: fadeInUp 0.6s ease-out forwards;
}

.service-card:nth-child(1) {
    animation-delay: 0.1s;
}

.service-card:nth-child(2) {
    animation-delay: 0.2s;
}

.service-card:nth-child(3) {
    animation-delay: 0.3s;
}

.service-card:nth-child(4) {
    animation-delay: 0.4s;
}

.service-card:nth-child(5) {
    animation-delay: 0.5s;
}

.service-card:nth-child(6) {
    animation-delay: 0.6s;
}

/* Feature Card Animation */
.feature-card {
    animation: bounceIn 0.8s ease-out forwards;
}

.feature-card:nth-child(1) {
    animation-delay: 0.2s;
}

.feature-card:nth-child(2) {
    animation-delay: 0.4s;
}

.feature-card:nth-child(3) {
    animation-delay: 0.6s;
}

.feature-card:nth-child(4) {
    animation-delay: 0.8s;
}

/* Hero Content Animation */
.hero-content {
    animation: fadeInUp 1s ease-out;
}

/* Floating Buttons Entrance */
.floating-btn {
    animation: slideInFromRight 0.6s ease-out forwards;
}

.floating-btn:nth-child(1) {
    animation-delay: 0.5s;
}

.floating-btn:nth-child(2) {
    animation-delay: 0.7s;
}

/* =========================================
   🚀 NEW ANIMATIONS FOR HERO & STATS
   ========================================= */

/* 1. Multicolored Bold Hero Text - One continuous gradient */
.hero-slide h1 {
    font-size: clamp(2.5rem, 5.5vw, 4.5rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;

    background: linear-gradient(90deg, #9333ea, #ef4444, #f97316, #fbbf24);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent !important;
    background-clip: text;

    color: transparent !important;
    /* Force transparency */
    text-shadow: none !important;
    /* Clear - No shadows */
    animation: fadeInUpTitle 0.8s ease-out;
}

/* Ensure all internal words follow the same gradient */
.hero-slide h1 span,
.hero-slide h1 .text-blue,
.hero-slide h1 .text-white {
    color: inherit !important;
    background: transparent !important;
    -webkit-text-fill-color: inherit !important;
    text-shadow: none !important;
}

.hero-slide p {
    font-size: 1.35rem;
    margin-bottom: 2.5rem;
    color: #ffffff !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: none !important;
    /* Remove shadows for clarity */
    animation: fadeInUpTitle 0.8s ease-out 0.2s backwards;
    max-width: 800px;
}

@keyframes gradientFlow {
    0% {
        background-position: 0% center;
    }

    100% {
        background-position: 200% center;
    }
}

@keyframes fadeInUpTitle {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}



.hero-slide {
    min-height: 300px;
    /* Keep height stable during typing */
}

/* 2. Floating Stats Cards */
.stat-item {
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
    animation: floatCard 6s ease-in-out infinite;
    border-top: 3px solid transparent;
}

.stat-item:hover {
    transform: translateY(-10px);
    border-top-color: var(--secondary-orange);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

.stat-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: translateX(-100%);
    transition: 0.5s;
}

.stat-item:hover::after {
    transform: translateX(100%);
}

.stat-item:nth-child(1) {
    animation-delay: 0s;
}

.stat-item:nth-child(2) {
    animation-delay: 1.5s;
}

.stat-item:nth-child(3) {
    animation-delay: 3s;
}

.stat-item:nth-child(4) {
    animation-delay: 4.5s;
}

@keyframes floatCard {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

/* 3. Pulsing Numbers & Glowing Text */
.stat-number {
    display: inline-block;
    background: linear-gradient(to bottom, #FF8C42, #FF3E00);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
    animation: pulseNumber 2s infinite ease-in-out;
    filter: drop-shadow(0 2px 4px rgba(255, 62, 0, 0.3));
}

@keyframes pulseNumber {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.03);
    }
}

/* Make + and % symbols smaller in stats */
.stat-item .stat-number:nth-child(2) {
    font-size: 1.2rem;
    margin-left: 2px;
    vertical-align: middle;
}

/* 4. Hero Button Glow */
.hero-cta .btn-primary {
    animation: glowBtn 2s infinite;
}

@keyframes glowBtn {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 119, 255, 0.7);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(0, 119, 255, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(0, 119, 255, 0);
    }
}

/* =========================================
   📱 FLOATING BUTTONS & MOBILE OPTIMIZATION
   ========================================= */

/* Floating Email */
.floating-email {
    background: #EA4335;
    color: white;
}

.floating-email:hover {
    background: #d33c2f;
    transform: translateY(-5px);
}

/* Base Floating Container */
.floating-contacts {
    position: fixed;
    top: 50%;
    right: 20px;
    margin-top: -100px;
    /* Half of approx height (3 * 60px + gaps) */
    transform: none;
    /* Remove transform to avoid paint layer issues */
    bottom: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 2147483647;
    /* Maximum Z-Index */
}

.floating-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
}

.floating-phone {
    background: #00AA44;
}

.floating-whatsapp {
    background: #25D366;
}

/* MOBILE RESPONSIVE TWEAKS */
@media (max-width: 991px) {

    /* Hide Top Bar */
    .top-bar {
        display: none !important;
    }

    /* Improve Header Layout */
    .header {
        height: auto !important;
    }

    .header-content {
        padding: 0.25rem 1rem;
        height: 110px;
        /* Maximum prominence */
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .logo-link {
        gap: 10px !important;
        max-width: 90% !important;
        /* Allow more room for the logo */
    }

    /* Adjust Logo for Mobile */
    .logo-img {
        width: 75px !important;
        /* Slightly smaller for better balance */
        height: 75px !important;
    }

    .logo-text-wrapper {
        gap: 4px !important;
        line-height: 1.1 !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
    }

    .logo-main-text {
        font-size: 2.6rem !important;
        /* Optimized size */
        letter-spacing: -1px !important;
        line-height: 1 !important;
        margin: 0 !important;
        white-space: nowrap !important;
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15)) !important;
    }

    .logo-sub-text {
        font-size: 0.75rem !important;
        letter-spacing: 3.5px !important;
        margin-top: 0 !important;
        font-weight: 800 !important;
        color: var(--secondary-orange) !important;
        white-space: nowrap !important;
        text-transform: uppercase !important;
        display: block !important;
        opacity: 0.95 !important;
    }

    /* Mobile Menu - ROBUST DRAWER FIX */
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        /* Hidden off-screen right */
        width: 85vw;
        /* Safer than % */
        max-width: 300px;
        height: 100vh;
        background: var(--bg-white);
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        padding-top: 80px;
        /* Space for close button/header */
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: right 0.3s cubic-bezier(0.77, 0, 0.175, 1);
        z-index: 10000;
        display: flex;
        overflow-y: auto !important;
        /* Force scrolling */
        -webkit-overflow-scrolling: touch;
        /* Smooth iOS scrolling */
    }

    .nav-menu.active {
        right: 0;
        /* Slide in */
        box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.5);
        /* Robust Backdrop */
    }

    /* Remove problematic pseudo-element backdrop */
    .nav-menu.active::before {
        display: none;
    }

    .menu-toggle {
        display: flex;
        z-index: 10001;
        position: relative;
        /* Ensure clickability */
    }

    /* Hamburger to X Animation */
    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(6px, 6px);
    }

    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    /* Fixed Close Button when Menu is Open */
    .menu-toggle.active {
        position: fixed;
        top: 20px;
        right: 20px;
        z-index: 10002;
    }

    .nav-item {
        margin: 0;
        width: 100%;
        text-align: left;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        /* Clean separator */
    }

    .nav-link {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1.25rem 1.5rem;
        /* Larger touch target */
        color: var(--dark);
        font-size: 1.1rem;
        font-weight: 600;
    }

    .nav-link:hover {
        background: rgba(0, 0, 0, 0.02);
    }

    .nav-link.active {
        color: var(--primary-blue);
        background: rgba(0, 119, 255, 0.05);
    }

    /* Accordion Dropdown for Mobile */
    .nav-item.dropdown .dropdown-menu {
        position: static;
        /* Flow naturally */
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        width: 100%;
        padding: 0;
        background: #f8f9fa;
        /* Slight contrast */
        border-top: 1px solid rgba(0, 0, 0, 0.03);
        display: none;
        /* Hidden by default */
        transition: none;
        /* JS handles toggle */
        margin-top: 0;
    }

    .nav-item.dropdown.active .dropdown-menu {
        display: block;
        /* Show when active */
    }

    .dropdown-item {
        padding: 0;
        margin: 0;
        border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    }

    .dropdown-item a {
        padding: 1rem 2rem;
        /* Indented */
        font-size: 1rem;
        color: var(--gray-dark);
        font-weight: 500;
    }

    /* Rotate Chevron */
    .nav-item.dropdown>.nav-link i {
        transition: transform 0.3s ease;
    }

    .nav-item.dropdown.active>.nav-link i {
        transform: rotate(180deg);
        color: var(--primary-blue);
    }

    /* Theme Toggle Position - MOVED LEFT to avoid X button overlap */
    .nav-item.theme-item {
        position: absolute;
        top: 1.25rem;
        left: 1.5rem;
        /* Move to left side */
        right: auto;
        width: auto;
        border: none;
        z-index: 10002;
    }

    /* Call Button in Menu */
    .nav-item:last-child {
        margin-top: auto;
        /* Push to bottom */
        border-bottom: none;
        padding: 1rem 1.5rem 2rem 1.5rem;
        text-align: center;
        width: 100%;
        flex-shrink: 0;
        /* Prevent shrinking */
    }

    .nav-item:last-child .btn {
        width: 100%;
        padding: 1rem;
        border-radius: var(--radius-md);
        margin-bottom: 1rem;
        font-size: 1.1rem;
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 10px;
    }

    /* Mobile Menu Contact Icons Row */
    .mobile-menu-icons {
        display: none;
        /* Hide on desktop */
        justify-content: center;
        gap: 20px;
        margin-top: 10px;
    }

    .mobile-icon-link {
        width: 45px;
        height: 45px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        font-size: 1.2rem;
        text-decoration: none;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    }

    /* Button Sizing for Mobile */
    .btn-lg {
        padding: 1rem 1.5rem;
        font-size: 1rem;
    }

    .hero-cta {
        flex-wrap: wrap;
        gap: 1rem;
        justify-content: center;
    }

    .hero-cta .btn {
        width: 100%;
        /* Full width buttons on mobile */
        max-width: 300px;
    }

    .hero {
        min-height: auto;
        padding-top: 100px;
        padding-bottom: 60px;
    }

    .hero h1 {
        font-size: 2.5rem;
        /* Bigger on mobile */
        line-height: 1.1;
    }

    .hero-slide p {
        font-size: 1.15rem;
        /* Bigger on mobile */
        margin-bottom: 1.5rem;
    }

    /* Stats Grid 2x2 - Ultra-Compact Version */
    .hero-stats {
        grid-template-columns: 1fr 1fr;
        gap: 6px;
        margin-top: 20px;
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
    }

    .stat-item {
        margin-bottom: 0;
        padding: 0.4rem 0.2rem;
        min-height: 65px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        backdrop-filter: blur(6px);
        -webkit-backdrop-filter: blur(6px);
        border-width: 1px;
    }

    .stat-number {
        font-size: 1.35rem;
        line-height: 1;
        margin-bottom: 2px;
        font-weight: 900;
        letter-spacing: -0.5px;
    }

    .stat-label {
        font-size: 0.6rem;
        line-height: 1;
        text-transform: uppercase;
        letter-spacing: 0.2px;
        opacity: 0.9;
    }

    /* Feature Cards Stack */
    .features-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {

    /* Small Screens - Stats adjustment */
    .hero-stats {
        grid-template-columns: 1fr;
    }
}

/* === FLOATING CONTACTS - MOBILE ONLY === */
/* Hide on desktop by default */
.floating-contacts,
#floating-portal {
    display: none;
}

/* Show only on mobile/tablet (991px and below) */
@media (max-width: 991px) {

    .floating-contacts,
    #floating-portal {
        position: fixed;
        top: 300px;
        right: 15px;
        z-index: 999999999;
        width: 60px;
        height: auto;
        display: block;
        visibility: visible;
        opacity: 1;
        pointer-events: auto;
    }

    .floating-btn {
        width: 60px;
        height: 60px;
        margin: 0 0 15px 0;
        padding: 0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #ffffff;
        font-size: 24px;
        text-decoration: none;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
        border: none;
        outline: none;
        transition: all 0.2s ease;
    }

    .floating-btn:hover {
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
        transform: scale(1.1);
    }

    .floating-phone {
        background: #00AA44;
    }

    .floating-whatsapp {
        background: #25D366;
    }

    .floating-email {
        background: #EA4335;
    }
}

/* HERO CONTACT ICONS - HIDDEN (Using global floating contacts instead) */
.hero-contact-row {
    display: none !important;
}

/* Mobile menu icons - hide on desktop, show on mobile */
.mobile-menu-icons {
    display: none;
    /* Hidden on desktop */
}

.mobile-icon-link {
    display: none;
    /* Hidden on desktop */
}

@media (max-width: 991px) {
    .mobile-menu-icons {
        display: flex;
        gap: 0.5rem;
        margin-top: 0.5rem;
    }

    .mobile-icon-link {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        color: white;
        text-decoration: none;
        transition: transform 0.2s ease;
    }

    .mobile-icon-link:hover {
        transform: scale(1.1);
    }
}

/* Very Small Screen Safeguard */
@media (max-width: 360px) {
    .logo-main-text {
        font-size: 2.2rem !important;
    }

    .logo-sub-text {
        font-size: 0.7rem !important;
        letter-spacing: 2px !important;
    }

    .logo-img {
        width: 60px;
        height: 60px;
    }

    .header-content {
        height: 90px;
    }
}

/* === MOBILE PHONE SPECIFIC OVERRIDES (<576px) === */
@media screen and (max-width: 576px) {

    /* Make menu ABSOLUTELY full width on actual phones */
    .nav-menu {
        width: 100vw !important;
        max-width: 100vw !important;
        min-width: 100vw !important;
        height: 100vh !important;
        right: -100vw !important;
        /* Move fully off screen */
        border-right: none !important;
        border-radius: 0 !important;
        left: auto !important;
    }

    .nav-menu.active {
        right: 0 !important;
        transform: none !important;
    }
}