/* ============================================
   CLIENTS PAGE STYLES
   Matching AICL.css Green Theme & Structure
   ============================================ */

:root {
    --primary-green: #006633;
    --primary-green-light: #008040;
    --accent-green: #00C853;
    --bg-white: #FFFFFF;
    --bg-light: #F5F5F5;
    --bg-card: #FFFFFF;
    --text-primary: #1A1A1A;
    --text-secondary: #666666;
    --text-muted: #999999;
    --border-color: #E0E0E0;
    --shadow: 0 2px 10px rgba(0,0,0,0.08);
    --shadow-hover: 0 8px 30px rgba(0,0,0,0.12);
    --shadow-elevated: 0 4px 20px rgba(0,0,0,0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --primary-green: #00E676;
    --primary-green-light: #00C853;
    --accent-green: #00E676;
    --bg-white: #121212;
    --bg-light: #1E1E1E;
    --bg-card: #1E1E1E;
    --text-primary: #FFFFFF;
    --text-secondary: #B0B0B0;
    --text-muted: #757575;
    --border-color: #333333;
    --shadow: 0 2px 10px rgba(0,0,0,0.3);
    --shadow-hover: 0 8px 30px rgba(0,0,0,0.5);
    --shadow-elevated: 0 4px 20px rgba(0,0,0,0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

#cube-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
    position: relative;
    z-index: 1;
}

/* ============================================
   HEADER & NAVIGATION (Matching AIL.css)
   ============================================ */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg-white);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: var(--transition);
}

.header.scrolled {
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    height: 80px;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    max-width: 200px;
}

.logo img {
    height: 60px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    transition: var(--transition);
}

.logo img:hover {
    transform: scale(1.05);
}

/* Desktop Navigation */
.desktop-nav {
    display: none;
}

@media (min-width: 1024px) {
    .desktop-nav {
        display: flex;
        align-items: center;
        gap: 2rem;
        margin-right: 2rem;
    }

    .nav-item {
        position: relative;
    }

    .nav-link {
        color: var(--text-primary);
        text-decoration: none;
        font-weight: 500;
        font-size: 1.05rem;
        padding: 0.5rem 0;
        display: flex;
        align-items: center;
        gap: 0.25rem;
        transition: var(--transition);
        cursor: pointer;
        background: none;
        border: none;
    }

    .nav-link:hover,
    .nav-link.active {
        color: var(--primary-green);
    }

    .nav-link.active::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 2px;
        background: var(--primary-green);
    }

    .dropdown-menu {
        position: absolute;
        top: 100%;
        left: 0;
        background: var(--bg-card);
        border: 1px solid var(--border-color);
        border-radius: 8px;
        padding: 0.5rem 0;
        min-width: 200px;
        box-shadow: var(--shadow-hover);
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
        transition: var(--transition);
        z-index: 100;
        list-style: none;
    }

    .nav-item:hover .dropdown-menu,
    .dropdown-menu.show {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .dropdown-item {
        display: block;
        padding: 0.75rem 1.25rem;
        color: var(--text-primary);
        text-decoration: none;
        font-size: 0.9rem;
        transition: var(--transition);
    }

    .dropdown-item:hover {
        background: var(--bg-light);
        color: var(--primary-green);
        padding-left: 1.5rem;
    }

    .menu-toggle {
        display: none !important;
    }
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

@media (max-width: 767px) {
    .contact-link span {
        display: none;
    }
}

.contact-link:hover {
    color: var(--primary-green);
}

/* Theme Toggle */
.theme-toggle {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.theme-toggle:hover {
    background: var(--bg-light);
    color: var(--primary-green);
    transform: scale(1.1);
}

.theme-toggle i {
    position: absolute;
    transition: var(--transition);
}

.theme-toggle .fa-sun {
    opacity: 0;
    transform: rotate(90deg) scale(0);
}

.theme-toggle .fa-moon {
    opacity: 1;
    transform: rotate(0) scale(1);
}

[data-theme="dark"] .theme-toggle .fa-sun {
    opacity: 1;
    transform: rotate(0) scale(1);
}

[data-theme="dark"] .theme-toggle .fa-moon {
    opacity: 0;
    transform: rotate(-90deg) scale(0);
}

/* ============================================
   MOBILE MENU (Green Theme)
   ============================================ */
.menu-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--text-primary);
    padding: 0.5rem;
    margin-left: 0.5rem;
}

.menu-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.menu-overlay {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 380px;
    height: 100vh;
    height: -webkit-fill-available;
    background: var(--bg-card);
    z-index: 10001;
    transition: right 0.3s ease;
    box-shadow: -5px 0 30px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.menu-overlay.active {
    right: 0;
}

.menu-header {
    display: flex;
    justify-content: flex-end;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.close-menu {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.close-menu:hover {
    background: var(--bg-light);
    color: var(--primary-green);
    transform: rotate(90deg);
}

.menu-list {
    list-style: none;
    padding: 1rem 0;
    flex-grow: 1;
}

.menu-item {
    border-bottom: 1px solid var(--border-color);
}

.menu-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    transition: var(--transition);
    background: none;
    border: none;
    width: 100%;
    cursor: pointer;
}

.menu-link:hover,
.menu-link.active {
    background: var(--bg-light);
    color: var(--primary-green);
    padding-left: 2rem;
}

.submenu {
    list-style: none;
    background: var(--bg-light);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.submenu.active {
    max-height: 300px;
}

.submenu li {
    border-bottom: 1px solid var(--border-color);
}

.submenu a {
    display: block;
    padding: 1rem 2rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.submenu a:hover {
    color: var(--primary-green);
    padding-left: 2.5rem;
}

.menu-footer {
    padding: 1.5rem;
    background: var(--bg-light);
    border-top: 1px solid var(--border-color);
}

.menu-contact-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 1rem;
    background: var(--primary-green);
    color: white;
    border: none;
    border-radius: 50px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.menu-contact-btn:hover {
    background: var(--primary-green-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 102, 51, 0.3);
}

.backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.backdrop.active {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   CLIENTS HERO SECTION
   ============================================ */
.clients-hero {
    margin-top: 80px;
    background: linear-gradient(135deg, var(--primary-green) 0%, #004d26 100%);
    color: white;
    padding: 5rem 5%;
    position: relative;
    overflow: hidden;
    text-align: center;
}

[data-theme="dark"] .clients-hero {
    background: linear-gradient(135deg, #1a1a1a 0%, #0d0d0d 100%);
    border-bottom: 2px solid var(--primary-green);
}

.clients-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><rect width="100" height="100" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    background: rgba(255,255,255,0.2);
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.3);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.clients-hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero-subtitle {
    font-size: 1.25rem;
    opacity: 0.9;
    font-weight: 300;
    max-width: 600px;
    margin: 0 auto;
}

/* ============================================
   CLIENTS SECTION (Carousel)
   ============================================ */
.clients {
    padding: 5rem 0;
    background: var(--bg-light);
    overflow: hidden;
}

[data-theme="dark"] .clients {
    background: #1a1a1a;
}

.clients-carousel-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
}

/* This is the scrolling container - must keep class name for JS */
.clients .container {
    display: flex;
    white-space: nowrap;
    animation: scroll linear infinite;
    padding: 2rem 0;
    max-width: 100%;
    margin: 0 auto;
    overflow-x: visible;
    position: relative;
}

.container:hover {
    animation-play-state: paused;
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Client Cards */
.client {
    position: relative;
    min-width: 280px;
    height: 180px;
    overflow: hidden;
    border-radius: 16px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
    margin-right: 2.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    flex-shrink: 0;
}

.client::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-green), var(--accent-green));
    background-size: 200% 100%;
    animation: gradientShift 3s ease infinite;
    z-index: 2;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.client:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-hover);
    border-color: var(--accent-green);
}

.client img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 25px;
    transition: var(--transition);
    background: var(--bg-card);
}

.client:hover img {
    filter: brightness(0.95);
    transform: scale(1.05);
}

.client-name {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 102, 51, 0.95);
    color: #fff;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    opacity: 0;
    transform: translateY(100%);
    transition: var(--transition);
    white-space: normal;
    line-height: 1.4;
    backdrop-filter: blur(4px);
}

.client:hover .client-name {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   FOOTER (Matching AIL.css)
   ============================================ */
.footer {
    background: var(--primary-green);
    color: white;
    padding: 4rem 5% 2rem;
    margin-top: 4rem;
}

[data-theme="dark"] .footer {
    background: #0a0a0a;
    border-top: 2px solid var(--primary-green);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    padding-top: 0;
    border-top: none;
}

.footer-section h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 0.75rem;
}

.footer-section a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: var(--transition);
    display: inline-block;
}

.footer-section a:hover {
    color: white;
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
}

.social-links a:hover {
    background: white;
    color: var(--primary-green);
    transform: translateY(-3px);
    padding-left: 0;
}

.location-info p {
    margin-bottom: 1rem;
    line-height: 1.6;
    font-size: 0.95rem;
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
}

.location-info i {
    margin-top: 0.25rem;
    color: rgba(255,255,255,0.7);
    flex-shrink: 0;
}

.footer-bottom {
    max-width: 1200px;
    margin: 3rem auto 0;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.2);
    text-align: center;
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
}

/* ============================================
   FLOATING ELEMENTS
   ============================================ */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--accent-green);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 997;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
    .header-top {
        height: 70px;
        padding: 1rem;
    }

    .logo img {
        height: 50px;
    }

    .clients-hero {
        padding: 4rem 1.5rem;
        margin-top: 70px;
    }

    .clients-hero h1 {
        font-size: 2rem;
        letter-spacing: 2px;
    }

    .clients {
        padding: 3rem 0;
    }

    .client {
        min-width: 240px;
        height: 150px;
        margin-right: 1.5rem;
        border-radius: 12px;
    }

    .client img {
        padding: 20px;
    }

    .client-name {
        font-size: 0.9rem;
        padding: 0.75rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

@media (max-width: 480px) {
    .client {
        min-width: 200px;
        height: 130px;
        margin-right: 1rem;
    }

    .client img {
        padding: 15px;
    }

    .client-name {
        font-size: 0.85rem;
        padding: 0.5rem;
    }
}

/* Pause animation when user prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
    .clients .container {
        animation: none;
        flex-wrap: wrap;
        justify-content: center;
        gap: 2rem;
    }
    
    .client {
        margin-right: 0;
    }
}

/* ============================================
   CLIENTS HERO SECTION (Updated to match Gallery)
   ============================================ */
.clients-hero {
    margin-top: 80px;
    background: #121212; /* Dark background matching screenshot */
    color: white;
    padding: 6rem 5% 5rem;
    position: relative;
    overflow: hidden;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* Subtle grid pattern overlay matching screenshot */
.clients-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

/* Updated badge style to match screenshot (dark pill) */
.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-transform: uppercase;
    letter-spacing: 2px;
    backdrop-filter: blur(10px);
}

/* Large heading matching Gallery style */
.clients-hero h1 {
    font-size: clamp(3rem, 6vw, 5rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 1.5rem;
    line-height: 1;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.hero-subtitle {
    font-size: 1.2rem;
    opacity: 0.8;
    font-weight: 400;
    max-width: 600px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
}

/* Adjust clients section spacing since hero is now separate */
.clients {
    padding: 4rem 0;
    background: var(--bg-light);
    overflow: hidden;
}

/* Dark mode adjustments - keep consistent with screenshot style */
[data-theme="dark"] .clients-hero {
    background: #0a0a0a;
    border-bottom: 2px solid var(--primary-green);
}

[data-theme="dark"] .clients {
    background: #1a1a1a;
}

/* ============================================
   RESPONSIVE UPDATES
   ============================================ */
@media (max-width: 768px) {
    .clients-hero {
        margin-top: 70px;
        padding: 4rem 1.5rem 3rem;
    }

    .clients-hero h1 {
        font-size: 2.5rem;
        letter-spacing: 2px;
    }

    .hero-badge {
        font-size: 0.75rem;
        padding: 0.5rem 1.2rem;
        margin-bottom: 1.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }
}