/* ============================================
   CSS VARIABLES & RESET
============================================ */
:root {
    --bg-primary: #0a0a0b;
    --bg-secondary: #111113;
    --bg-tertiary: #1a1a1d;
    --bg-card: #16161a;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a6;
    --text-muted: #6b6b70;
    --accent-primary: #00d4ff;
    --accent-secondary: #7c3aed;
    --accent-gradient: linear-gradient(135deg, #00d4ff 0%, #7c3aed 100%);
    --border-color: #2a2a2e;
    --success: #10b981;
    --warning: #f59e0b;
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --section-padding: 120px;
    --container-max: 1200px;
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
    --transition-slow: 0.5s ease;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-main); background-color: var(--bg-primary); color: var(--text-primary); line-height: 1.6; overflow-x: hidden; }

/* ANIMATED BACKGROUND */
.bg-grid {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none; z-index: 0; opacity: 0.4;
    background-image: linear-gradient(rgba(0, 212, 255, 0.03) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(0, 212, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: gridMove 20s linear infinite;
}
@keyframes gridMove { 0% { transform: translate(0, 0); } 100% { transform: translate(60px, 60px); } }

.bg-glow { position: fixed; width: 600px; height: 600px; border-radius: 50%; filter: blur(150px); opacity: 0.15; pointer-events: none; z-index: 0; }
.bg-glow-1 { top: -200px; right: -200px; background: var(--accent-primary); }
.bg-glow-2 { bottom: -200px; left: -200px; background: var(--accent-secondary); }

/* LAYOUT */
.container { max-width: var(--container-max); margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }
section { padding: var(--section-padding) 0; position: relative; }

/* TYPOGRAPHY */
h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; }
.section-label { font-family: var(--font-mono); font-size: 0.875rem; color: var(--accent-primary); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 16px; display: inline-block; }
.section-title { font-size: clamp(2rem, 5vw, 3rem); margin-bottom: 24px; }
.gradient-text { background: var(--accent-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* BUTTONS */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 16px 32px; font-family: var(--font-main); font-size: 1rem; font-weight: 600; text-decoration: none; border-radius: 12px; cursor: pointer; transition: all var(--transition-medium); border: none; }
.btn-primary { background: var(--accent-gradient); color: var(--bg-primary); position: relative; overflow: hidden; }
.btn-primary::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent); transition: left 0.5s ease; }
.btn-primary:hover::before { left: 100%; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 20px 40px rgba(0, 212, 255, 0.3); }
.btn-secondary { background: transparent; color: var(--text-primary); border: 1px solid var(--border-color); }
.btn-secondary:hover { background: var(--bg-tertiary); border-color: var(--accent-primary); }
.btn-call:hover { border-color: var(--success); color: var(--success); background: rgba(16, 185, 129, 0.1); }
.btn-call:hover svg { stroke: var(--success); }

/* NAVIGATION */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; padding: 20px 0; transition: all var(--transition-medium); }
.nav.scrolled { background: rgba(10, 10, 11, 0.9); backdrop-filter: blur(20px); border-bottom: 1px solid var(--border-color); padding: 12px 0; }
.nav-container { display: flex; justify-content: space-between; align-items: center; }
.nav-logo { font-size: 1.5rem; font-weight: 800; text-decoration: none; color: var(--text-primary); display: flex; align-items: center; gap: 8px; }
.nav-logo span { color: var(--accent-primary); }
.nav-logo-icon { width: 36px; height: 36px; background: var(--accent-gradient); border-radius: 8px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1rem; }
.nav-links { display: flex; gap: 40px; list-style: none; }
.nav-links a { color: var(--text-secondary); text-decoration: none; font-weight: 500; font-size: 0.9375rem; transition: color var(--transition-fast); position: relative; }
.nav-links a::after { content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px; background: var(--accent-gradient); transition: width var(--transition-medium); }
.nav-links a:hover { color: var(--text-primary); }
.nav-links a:hover::after { width: 100%; }
.nav-cta { display: none; }
.mobile-menu-btn { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 8px; }
.mobile-menu-btn span { width: 24px; height: 2px; background: var(--text-primary); transition: all var(--transition-fast); }

/* HERO */
.hero { min-height: 100vh; display: flex; align-items: flex-start; justify-content: flex-start; padding-top: 100px; position: relative; overflow: hidden; }
.hero .container { margin-left: 0; padding-left: 40px; }
.hero-content { max-width: 1000px; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 100px; font-size: 0.875rem; color: var(--text-secondary); margin-bottom: 32px; animation: fadeInUp 0.6s ease forwards; }
.hero-badge-dot { width: 8px; height: 8px; background: var(--success); border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
.hero-title { font-size: clamp(2.2rem, 6vw, 4.3rem); font-weight: 800; line-height: 1.1; margin-bottom: 24px; animation: fadeInUp 0.6s ease 0.1s forwards; opacity: 0; }
.hero-subtitle { font-size: clamp(1.125rem, 2vw, 1.375rem); color: var(--text-secondary); margin-bottom: 48px; max-width: 600px; animation: fadeInUp 0.6s ease 0.2s forwards; opacity: 0; }
.hero-buttons { display: flex; gap: 16px; flex-wrap: wrap; animation: fadeInUp 0.6s ease 0.3s forwards; opacity: 0; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

/* Code Container */
.code-container { position: absolute; right: -470px; top: 60%; transform: translateY(-50%); width: 420px; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 16px; overflow: hidden; animation: fadeIn 0.8s ease 0.5s forwards; opacity: 0; }
@keyframes fadeIn { to { opacity: 1; } }
.code-header { display: flex; gap: 8px; padding: 16px; background: var(--bg-tertiary); border-bottom: 1px solid var(--border-color); }
.code-dot { width: 12px; height: 12px; border-radius: 50%; }
.code-dot.red { background: #ff5f57; }
.code-dot.yellow { background: #febc2e; }
.code-dot.green { background: #28c840; }
.code-body { padding: 20px; font-family: var(--font-mono); font-size: 0.8rem; line-height: 1.8; color: var(--text-secondary); min-height: 200px; }
.code-line { opacity: 0; animation: typeLine 0.3s ease forwards; }
.code-keyword { color: #c678dd; }
.code-function { color: #61afef; }
.code-string { color: #98c379; }
.code-comment { color: var(--text-muted); }
.code-variable { color: #e5c07b; }
.code-operator { color: var(--accent-primary); }
@keyframes typeLine { to { opacity: 1; } }

/* ABOUT */
.about { background: var(--bg-secondary); }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.about-text p { color: var(--text-secondary); font-size: 1.125rem; margin-bottom: 24px; }
.about-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 48px; }
.stat-item { text-align: center; padding: 24px; background: var(--bg-tertiary); border-radius: 16px; border: 1px solid var(--border-color); transition: all var(--transition-medium); }
.stat-item:hover { border-color: var(--accent-primary); transform: translateY(-4px); }
.stat-number { font-size: 2.5rem; font-weight: 800; background: var(--accent-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.stat-label { font-size: 0.875rem; color: var(--text-muted); margin-top: 4px; }
.skills-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.skill-card { padding: 24px; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 16px; transition: all var(--transition-medium); }
.skill-card:hover { border-color: var(--accent-primary); transform: translateY(-4px); box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3); }
.skill-icon { width: 48px; height: 48px; background: var(--accent-gradient); border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; margin-bottom: 16px; }
.skill-title { font-size: 1.125rem; font-weight: 600; margin-bottom: 8px; }
.skill-desc { font-size: 0.875rem; color: var(--text-muted); }

/* PORTFOLIO */
.portfolio-header { text-align: center; margin-bottom: 64px; }
.portfolio-header p { color: var(--text-secondary); max-width: 600px; margin: 0 auto; }
.projects-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
.project-card { background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 20px; overflow: hidden; transition: all var(--transition-medium); position: relative; }
.project-card:hover { border-color: var(--accent-primary); transform: translateY(-8px); box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4); }
.project-card.featured { grid-column: span 2; }
.project-image { height: 240px; background: var(--bg-tertiary); position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.project-card.featured .project-image { height: 300px; }
.project-image-placeholder { font-size: 4rem; opacity: 0.3; }
.project-image img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--transition-medium); }
.project-card:hover .project-image img { transform: scale(1.05); }
.project-image::before { content: ''; position: absolute; inset: 0; background: var(--accent-gradient); opacity: 0; transition: opacity var(--transition-medium); }
.project-card:hover .project-image::before { opacity: 0.1; }
.project-badge { position: absolute; top: 16px; left: 16px; padding: 6px 12px; background: var(--accent-gradient); color: var(--bg-primary); font-size: 0.75rem; font-weight: 600; border-radius: 100px; text-transform: uppercase; letter-spacing: 0.5px; }
.project-content { padding: 32px; }
.project-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 12px; display: flex; align-items: center; gap: 12px; }
.project-desc { color: var(--text-secondary); margin-bottom: 24px; line-height: 1.7; font-size: 0.95rem; }
.project-card.featured .project-desc { font-size: 1rem; }
.project-tech { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.tech-tag { padding: 6px 12px; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 8px; font-size: 0.75rem; font-family: var(--font-mono); color: var(--text-muted); }
.project-link { display: inline-flex; align-items: center; gap: 8px; color: var(--accent-primary); text-decoration: none; font-weight: 500; font-size: 0.9375rem; transition: gap var(--transition-fast); }
.project-link:hover { gap: 12px; }

/* COMING SOON */
.coming-soon { background: var(--bg-secondary); }
.coming-soon-card { background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%); border: 1px solid var(--border-color); border-radius: 24px; padding: 64px; display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; position: relative; overflow: hidden; }
.coming-soon-card::before { content: ''; position: absolute; top: -50%; right: -50%; width: 100%; height: 100%; background: var(--accent-gradient); opacity: 0.05; border-radius: 50%; filter: blur(100px); }
.coming-soon-image { width: 100%; height: 100%; object-fit: cover; border-radius: 16px; box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3); }
.coming-soon-visual { display: flex; align-items: center; justify-content: center; }
.coming-soon-badge { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; background: rgba(245, 158, 11, 0.1); border: 1px solid rgba(245, 158, 11, 0.3); border-radius: 100px; font-size: 0.875rem; color: var(--warning); margin-bottom: 24px; }
.coming-soon-title { font-size: 2.5rem; font-weight: 800; margin-bottom: 16px; }
.coming-soon-desc { color: var(--text-secondary); font-size: 1.125rem; margin-bottom: 32px; }
.features-list { list-style: none; }
.features-list li { display: flex; align-items: center; gap: 12px; padding: 12px 0; color: var(--text-secondary); border-bottom: 1px solid var(--border-color); }
.features-list li:last-child { border-bottom: none; }
.feature-icon { width: 24px; height: 24px; background: var(--accent-gradient); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 0.75rem; flex-shrink: 0; }
.coming-soon-visual { display: flex; align-items: center; justify-content: center; }
.app-mockup { width: 100%; max-width: 350px; background: var(--bg-primary); border: 1px solid var(--border-color); border-radius: 24px; overflow: hidden; box-shadow: 0 40px 80px rgba(0, 0, 0, 0.5); }
.mockup-header { padding: 16px 20px; background: var(--bg-secondary); border-bottom: 1px solid var(--border-color); display: flex; align-items: center; gap: 12px; }
.mockup-avatar { width: 36px; height: 36px; background: var(--accent-gradient); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.mockup-title { font-size: 0.9375rem; font-weight: 600; }
.mockup-subtitle { font-size: 0.75rem; color: var(--text-muted); }
.mockup-body { padding: 20px; }
.mockup-item { display: flex; align-items: center; gap: 12px; padding: 16px; background: var(--bg-secondary); border-radius: 12px; margin-bottom: 12px; }
.mockup-item-icon { width: 40px; height: 40px; background: var(--bg-tertiary); border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.mockup-item-text { flex: 1; }
.mockup-item-title { font-size: 0.875rem; font-weight: 500; }
.mockup-item-desc { font-size: 0.75rem; color: var(--text-muted); }

/* CONTACT */
.contact-header { text-align: center; margin-bottom: 64px; }
.contact-header p { color: var(--text-secondary); max-width: 500px; margin: 0 auto; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; }
.contact-form { background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 20px; padding: 40px; }
.form-group { margin-bottom: 24px; }
.form-label { display: block; font-size: 0.875rem; font-weight: 500; margin-bottom: 8px; color: var(--text-secondary); }
.form-input, .form-textarea { width: 100%; padding: 16px; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; font-family: var(--font-main); font-size: 1rem; color: var(--text-primary); transition: all var(--transition-fast); }
.form-input:focus, .form-textarea:focus { outline: none; border-color: var(--accent-primary); box-shadow: 0 0 0 4px rgba(0, 212, 255, 0.1); }
.form-textarea { resize: vertical; min-height: 150px; }
.form-input::placeholder, .form-textarea::placeholder { color: var(--text-muted); }
.contact-info { display: flex; flex-direction: column; justify-content: center; }
.contact-info-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 24px; }
.contact-info-text { color: var(--text-secondary); margin-bottom: 40px; }
.contact-links { display: flex; flex-direction: column; gap: 16px; }
.contact-link { display: flex; align-items: center; gap: 16px; padding: 20px; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 16px; text-decoration: none; color: var(--text-primary); transition: all var(--transition-medium); }
.contact-link:hover { border-color: var(--accent-primary); transform: translateX(8px); }
.contact-link-icon { width: 48px; height: 48px; background: var(--bg-tertiary); border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.25rem; }
.contact-link-text { font-weight: 500; }
.contact-link-label { font-size: 0.75rem; color: var(--text-muted); }

/* FOOTER */
.footer { padding: 48px 0; border-top: 1px solid var(--border-color); background: var(--bg-secondary); }
.footer-content { display: flex; justify-content: space-between; align-items: center; }
.footer-text { color: var(--text-muted); font-size: 0.875rem; }
.footer-links { display: flex; gap: 24px; }
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 0.875rem; transition: color var(--transition-fast); }
.footer-links a:hover { color: var(--accent-primary); }

/* SCROLL ANIMATIONS */
.reveal { opacity: 0; transform: translateY(40px); transition: all 0.8s ease; }
.reveal.active { opacity: 1; transform: translateY(0); }

/* MOBILE MENU */
.mobile-menu { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: var(--bg-primary); z-index: 999; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 32px; transform: translateX(100%); transition: transform var(--transition-medium); }
.mobile-menu.active { transform: translateX(0); }
.mobile-menu a { font-size: 1.5rem; font-weight: 600; color: var(--text-primary); text-decoration: none; }
.mobile-menu-close { position: absolute; top: 24px; right: 24px; background: none; border: none; color: var(--text-primary); font-size: 2rem; cursor: pointer; }

/* RESPONSIVE */
@media (max-width: 1024px) {
    .code-container { display: none; }
    .about-grid, .contact-grid { grid-template-columns: 1fr; gap: 48px; }
    .coming-soon-card { grid-template-columns: 1fr; padding: 40px; }
    .projects-grid { grid-template-columns: 1fr; }
    .project-card.featured { grid-column: span 1; }
}
@media (max-width: 768px) {
    :root { --section-padding: 80px; }
    .nav-links { display: none; }
    .mobile-menu-btn { display: flex; }
    .nav-cta { display: none; }
    .hero-buttons { flex-direction: column; }
    .about-stats { grid-template-columns: 1fr; }
    .skills-grid { grid-template-columns: 1fr; }
    .coming-soon-visual { display: none; }
    .footer-content { flex-direction: column; gap: 24px; text-align: center; }
}
@media (max-width: 480px) {
    .hero-title { font-size: 2rem; }
    .section-title { font-size: 1.75rem; }
    .project-content { padding: 24px; }
    .contact-form { padding: 24px; }
}
