:root {
    --primary-purple: #3d3b7a;
    --primary-blue: #4a7bc8;
    --light-blue: #1a94d6;
    --dark-navy: #2d3561;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --bg-light: #f8f9fa;
    --white: #ffffff;
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --card-bg: #ffffff;
    --shadow-color: rgba(0,0,0,0.1);
    --hero-gradient-start: #3d3b7a;
    --hero-gradient-end: #4a7bc8;
    --footer-bg: #2c3e50;
    --footer-text: #ffffff;
}

body.dark-mode {
    --text-dark: #e4e4e7;
    --text-light: #a1a1aa;
    --bg-light: #27272a;
    --white: #18181b;
    --bg-primary: #18181b;
    --bg-secondary: #27272a;
    --card-bg: #27272a;
    --shadow-color: rgba(0,0,0,0.3);
    --hero-gradient-start: #1e1b3a;
    --hero-gradient-end: #1a2c4a;
    --footer-bg: #0f0f10;
    --footer-text: #e4e4e7;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    background-color: var(--bg-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg-primary);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px var(--shadow-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    height: 50px;
}

.company-name {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary-blue);
}

.lang-switcher {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.lang-btn {
    padding: 0.4rem 0.8rem;
    border: 2px solid var(--primary-blue);
    background: transparent;
    color: var(--primary-blue);
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.lang-btn.active {
    background: var(--primary-blue);
    color: white;
}

.lang-btn:hover {
    background: var(--primary-blue);
    color: white;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-dark);
}

.theme-toggle {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1);
}

/* Hero Section */
.hero {
    margin-top: 80px;
    min-height: 90vh;
    background: linear-gradient(135deg, var(--hero-gradient-start) 0%, var(--hero-gradient-end) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    transition: background 0.3s ease;
}

.hero::before {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: -200px;
    right: -200px;
}

.hero::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    bottom: -150px;
    left: -150px;
}

.hero-content {
    max-width: 800px;
    z-index: 1;
    animation: fadeInUp 1s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: white;
    color: var(--primary-purple);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* Section Styles */
section {
    padding: 5rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-purple);
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow-color);
    transition: all 0.3s;
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px var(--shadow-color);
}

.service-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-purple);
}

.service-card p {
    color: var(--text-light);
    line-height: 1.8;
}

/* About Section */
#about {
    background: var(--bg-light);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.about-text h3 {
    font-size: 1.8rem;
    color: var(--primary-purple);
    margin-bottom: 1rem;
}

.about-text p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-features {
    list-style: none;
}

.about-features li {
    padding: 1rem;
    margin-bottom: 1rem;
    background: var(--card-bg);
    border-radius: 10px;
    box-shadow: 0 3px 10px var(--shadow-color);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.about-features li::before {
    content: '✓';
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    color: white;
    border-radius: 50%;
    font-weight: bold;
    flex-shrink: 0;
}

/* Contact Section */
.contact-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.contact-info {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 4rem;
    margin-top: 2rem;
}

.contact-item {
    text-align: center;
}

.contact-item h3 {
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
}

.contact-item a {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 500;
}

.contact-item a:hover {
    text-decoration: underline;
}

/* Footer */
footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    text-align: center;
    padding: 2rem;
    transition: background 0.3s ease, color 0.3s ease;
}

footer p {
    opacity: 0.9;
}

/* Language-specific content */
/* Hide English content by default (Spanish mode) */
[data-lang="en"] {
    display: none !important;
}

/* English mode: hide Spanish content */
body.lang-en [data-lang="es"] {
    display: none !important;
}

/* English mode: show English content */
body.lang-en h1[data-lang="en"],
body.lang-en h2[data-lang="en"],
body.lang-en h3[data-lang="en"],
body.lang-en p[data-lang="en"],
body.lang-en a[data-lang="en"] {
    display: block !important;
}

body.lang-en a[data-lang="en"] {
    display: inline-block !important;
}

/* English mode: list items need flex layout */
body.lang-en li[data-lang="en"] {
    display: flex !important;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: white;
        flex-direction: column;
        padding: 2rem;
        transition: left 0.3s;
        box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    }

    .nav-links.active {
        left: 0;
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1.1rem;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .contact-info {
        flex-direction: column;
        gap: 2rem;
    }

    h2 {
        font-size: 2rem;
    }
}
