/* ===== CSS Variables ===== */
:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #8b5cf6;
    --accent-color: #06b6d4;
    --background: #0f172a;
    --surface: #1e293b;
    --surface-light: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-muted: #94a3b8;
    --success: #10b981;
    --border-color: #334155;
    --shadow: rgba(0, 0, 0, 0.3);
    --gradient: linear-gradient(135deg, var(--primary-color), var(--secondary-color), var(--accent-color));
}

/* ===== Reset & Base ===== */
* {
    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(--background);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* ===== Header & Navigation ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-primary);
}

.logo-icon {
    font-size: 2rem;
}

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

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

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* ===== Hero Section ===== */
.hero {
    margin-top: 80px;
    padding: 8rem 0 6rem;
    background: linear-gradient(180deg, var(--background) 0%, var(--surface) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.1), transparent 50%);
    pointer-events: none;
}

.hero-content {
    text-align: center;
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

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

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.stat {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: var(--surface);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.stat:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.stat-icon {
    font-size: 2rem;
}

.stat-label {
    font-weight: 600;
    color: var(--text-secondary);
}

/* ===== Sections ===== */
.section {
    padding: 5rem 0;
}

.section-dark {
    background-color: var(--surface);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--gradient);
    margin: 1rem auto 0;
    border-radius: 2px;
}

/* ===== About Section ===== */
.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.about-card {
    background: var(--surface);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.card-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.about-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.about-card p {
    color: var(--text-secondary);
    font-size: 1rem;
}

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

.service-card {
    background: var(--background);
    padding: 2.5rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary-color);
}

.service-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    display: block;
}

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

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

/* ===== Tech Stack Section ===== */
.tech-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

.tech-badge {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 30px;
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.tech-badge:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: scale(1.1);
}

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

.contact-text {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.contact-link {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.125rem;
    transition: all 0.3s ease;
}

.contact-link:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(99, 102, 241, 0.4);
}

.contact-icon {
    font-size: 1.5rem;
}

/* ===== Footer ===== */
.footer {
    background-color: var(--background);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer-content {
    text-align: center;
    color: var(--text-muted);
}

.footer-content p {
    margin: 0.5rem 0;
}

.footer-ip {
    font-family: 'Courier New', monospace;
    color: var(--accent-color);
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

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

    .nav-links {
        gap: 1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .hero {
        padding: 5rem 0 3rem;
    }

    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }

    .stat {
        width: 100%;
        justify-content: center;
    }

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

@media (max-width: 480px) {
    .nav-links {
        display: none;
    }

    .hero-title {
        font-size: 2rem;
    }

    .container {
        padding: 0 1rem;
    }
}
