/* ===== CSS Variables ===== */
:root {
    /* Light Mode Colors */
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-tertiary: #e9ecef;
    --text-primary: #1a1a1a;
    --text-secondary: #6c757d;
    --text-tertiary: #adb5bd;
    --accent-primary: #6366f1;
    --accent-secondary: #8b5cf6;
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --card-bg: #ffffff;
    --card-border: #e9ecef;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.16);
    --nav-bg: rgba(255, 255, 255, 0.95);
    --footer-bg: #1a1a1a;
    --footer-text: #e9ecef;
}

[data-theme="dark"] {
    /* Dark Mode Colors */
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --bg-tertiary: #2a2a2a;
    --text-primary: #ffffff;
    --text-secondary: #adb5bd;
    --text-tertiary: #6c757d;
    --accent-primary: #818cf8;
    --accent-secondary: #a78bfa;
    --accent-gradient: linear-gradient(135deg, #818cf8 0%, #a78bfa 100%);
    --card-bg: #1a1a1a;
    --card-border: #2a2a2a;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --nav-bg: rgba(26, 26, 26, 0.95);
    --footer-bg: #0a0a0a;
    --footer-text: #adb5bd;
}

/* ===== Reset & Base Styles ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== Navigation ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--nav-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--card-border);
    z-index: 1000;
    padding: 16px 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand .logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 8px 0;
}

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

.nav-controls {
    display: flex;
    gap: 16px;
    align-items: center;
}

.language-selector {
    display: flex;
    gap: 8px;
    background: var(--bg-secondary);
    padding: 4px;
    border-radius: 8px;
}

.lang-btn {
    background: transparent;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    color: var(--text-secondary);
    font-weight: 500;
    transition: all 0.3s ease;
}

.lang-btn:hover {
    background: var(--card-bg);
    color: var(--text-primary);
}

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

.theme-toggle {
    background: var(--bg-secondary);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background: var(--accent-primary);
    transform: scale(1.05);
}

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 2px solid var(--card-border);
}

.btn-secondary:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

/* ===== Hero Section ===== */
.hero {
    padding: 120px 0 80px;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-title {
    font-size: 56px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 24px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    margin-bottom: 32px;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 16px;
}

.hero-visual {
    position: relative;
    height: 400px;
}

.floating-card {
    position: absolute;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow-lg);
    animation: float 3s ease-in-out infinite;
}

.floating-card .card-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

.floating-card .card-text {
    font-weight: 600;
    color: var(--text-primary);
}

.card-1 {
    top: 0;
    left: 0;
    animation-delay: 0s;
}

.card-2 {
    top: 120px;
    right: 40px;
    animation-delay: 1s;
}

.card-3 {
    bottom: 40px;
    left: 80px;
    animation-delay: 2s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* ===== Sections ===== */
.services-overview,
.ai-highlight {
    padding: 80px 0;
}

.services-overview {
    background: var(--bg-secondary);
}

.section-title {
    font-size: 42px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 60px;
}

/* ===== Service Cards ===== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 32px;
}

.service-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-primary);
}

.service-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.service-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.service-description {
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.6;
}

.service-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.service-link:hover {
    color: var(--accent-secondary);
}

/* ===== AI Cards ===== */
.ai-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 32px;
    margin-bottom: 48px;
}

.ai-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 40px;
    transition: all 0.3s ease;
}

.ai-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.ai-icon {
    font-size: 56px;
    margin-bottom: 20px;
}

.ai-title {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.ai-description {
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 4px;
    transition: width 1s ease;
}

.cta-center {
    text-align: center;
}

/* ===== Footer ===== */
.footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    padding: 60px 0 24px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: 60px;
    margin-bottom: 40px;
}

.footer-brand h3 {
    margin-bottom: 16px;
}

.footer-brand p {
    color: var(--text-tertiary);
    line-height: 1.6;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.footer-column h4 {
    margin-bottom: 16px;
    color: var(--footer-text);
}

.footer-column a {
    display: block;
    color: var(--text-tertiary);
    text-decoration: none;
    margin-bottom: 12px;
    transition: color 0.3s ease;
}

.footer-column a:hover {
    color: var(--accent-primary);
}

.footer-bottom {
    border-top: 1px solid var(--bg-tertiary);
    padding-top: 24px;
    text-align: center;
    color: var(--text-tertiary);
}

/* ===== Demo Showcase Styles ===== */
.demo-header {
    padding: 100px 0 40px;
    text-align: center;
}

.demo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 32px;
    padding: 40px 0;
}

.demo-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.demo-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.demo-preview {
    width: 100%;
    height: 200px;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 64px;
}

.demo-info {
    padding: 24px;
}

.demo-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
}

.demo-description {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.demo-link {
    display: inline-block;
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 600;
}

/* ===== Responsive Design ===== */
@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
    }
    
    .hero-visual {
        display: none;
    }
    
    .hero-title {
        font-size: 42px;
    }
    
    .services-grid,
    .ai-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .nav-menu {
        gap: 16px;
    }
}

@media (max-width: 640px) {
    .hero-title {
        font-size: 32px;
    }
    
    .hero-subtitle {
        font-size: 16px;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .section-title {
        font-size: 32px;
    }
    
    .nav-menu {
        display: none;
    }
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* ===== Service Detail Pages ===== */
.service-detail-header {
    padding: 120px 0 60px;
    text-align: center;
    background: var(--bg-secondary);
}

.service-detail-icon {
    font-size: 80px;
    margin-bottom: 24px;
}

.service-detail-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 16px;
}

.service-detail-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
}

.service-detail-content {
    padding: 80px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
    margin-bottom: 60px;
}

.feature-item {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 24px;
}

.feature-item h3 {
    font-size: 20px;
    margin-bottom: 12px;
    color: var(--accent-primary);
}

.feature-item p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== Contact Page ===== */
.contact-section {
    padding: 120px 0 80px;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-top: 60px;
}

.contact-form {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 40px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--card-border);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.contact-item {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 24px;
}

.contact-item h3 {
    font-size: 20px;
    margin-bottom: 12px;
    color: var(--accent-primary);
}

.contact-item p {
    color: var(--text-secondary);
}
