:root {
    --bg-color: #0f172a; /* Dark tech aesthetic */
    --surface: #1e293b;
    --surface-hover: #334155;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --primary: #38bdf8; /* Cyan blue */
    --accent: #818cf8;
    --glass: rgba(30, 41, 59, 0.7);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* Grid Background */
.bg-grid {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background-image: 
        linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: -1;
    pointer-events: none;
}

.bg-glow {
    position: fixed;
    top: -20%; left: -10%; width: 50vw; height: 50vw;
    background: radial-gradient(circle, var(--primary) 0%, transparent 50%);
    opacity: 0.1;
    z-index: -1;
    pointer-events: none;
}

/* Navbar */
.pro-nav {
    background: transparent;
    position: fixed; width: 100%; top: 0; z-index: 1000;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.pro-nav.scrolled {
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(56, 189, 248, 0.15);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
    padding: 0;
}

.nav-container {
    display: flex; justify-content: space-between; align-items: center;
    padding: 15px 40px; max-width: 1400px; margin: 0 auto;
}

.nav-brand {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.6rem;
    color: var(--text-main);
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(56, 189, 248, 0.3);
}
.nav-brand span { color: var(--primary); }

.nav-links { display: flex; list-style: none; gap: 40px; margin: 0; padding: 0; }
.nav-links a {
    text-decoration: none; color: #ccc;
    font-size: 0.95rem; font-weight: 600; text-transform: uppercase; letter-spacing: 2px;
    transition: all 0.3s ease;
}
.nav-links a:hover { color: var(--primary); text-shadow: 0 0 15px rgba(56, 189, 248, 0.8); transform: translateY(-2px); }

.back-link {
    display: flex; align-items: center; gap: 8px;
    color: var(--text-muted); text-decoration: none; font-size: 0.9rem;
    transition: color 0.3s; text-transform: uppercase; font-weight: 600;
}
.back-link:hover { color: var(--primary); }

/* Hero */
.pro-hero {
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    text-align: center;
    padding-top: 80px;
}
.pro-hero h1 {
    font-size: 5.5rem; font-weight: 800; margin-bottom: 20px;
    background: linear-gradient(to right, #ffffff, var(--primary));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    text-shadow: 0 0 40px rgba(56, 189, 248, 0.4);
    letter-spacing: -1px;
}
.pro-hero p {
    font-size: 1.3rem; color: var(--text-muted); margin-bottom: 40px;
    max-width: 700px; margin-left: auto; margin-right: auto;
    min-height: 3rem; /* For typing effect */
}
.btn {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 15px 35px; border-radius: 30px; text-decoration: none;
    font-weight: 600; text-transform: uppercase; letter-spacing: 1px;
    transition: all 0.3s; background: transparent;
}
.btn-primary {
    background: var(--primary); color: #000;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.4); border: 2px solid var(--primary);
}
.btn-primary:hover {
    transform: translateY(-3px); box-shadow: 0 0 30px rgba(56, 189, 248, 0.6);
}

.pro-hero .btn-primary {
    animation: pulse-glow-btn 2s infinite;
    position: relative;
}

@keyframes pulse-glow-btn {
    0% { box-shadow: 0 0 0 0 rgba(56, 189, 248, 0.4); }
    70% { box-shadow: 0 0 0 20px rgba(56, 189, 248, 0); }
    100% { box-shadow: 0 0 0 0 rgba(56, 189, 248, 0); }
}

.tech-icons { margin-top: 50px; font-size: 2rem; color: var(--text-muted); display: flex; gap: 30px; justify-content: center; }
.tech-icons i { 
    transition: all 0.3s ease; 
    animation: float 3s ease-in-out infinite;
}
.tech-icons i:nth-child(2) { animation-delay: 0.2s; }
.tech-icons i:nth-child(3) { animation-delay: 0.4s; }
.tech-icons i:nth-child(4) { animation-delay: 0.6s; }
.tech-icons i:nth-child(5) { animation-delay: 0.8s; }
.tech-icons i:nth-child(6) { animation-delay: 1.0s; }

.tech-icons i:hover { color: var(--primary); transform: scale(1.3) translateY(-10px); filter: drop-shadow(0 0 10px var(--primary)); animation-play-state: paused; }

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

/* Sections */
.pro-section { padding: 100px 0; }
.section-title {
    font-size: 3rem; font-weight: 800; margin-bottom: 60px; text-align: center;
    color: var(--text-main); position: relative;
}
.section-title::after {
    content: ''; position: absolute; bottom: -15px; left: 50%; transform: translateX(-50%);
    width: 60px; height: 4px; background: var(--primary); border-radius: 2px;
}

/* About */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.about-text p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 20px; line-height: 1.8; }
.about-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.stat-box {
    background: var(--surface); padding: 40px 30px; border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.05); text-align: center;
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.stat-box:hover { transform: translateY(-10px); border-color: var(--primary); box-shadow: 0 10px 30px rgba(0,0,0,0.3); }
.stat-box i { font-size: 3rem; color: var(--primary); margin-bottom: 20px; }
.stat-box h3 { color: var(--text-main); margin-bottom: 10px; font-size: 1.2rem; }

/* Projects */
.project-card {
    background: var(--surface); border: 1px solid rgba(255,255,255,0.05);
    border-radius: 16px; padding: 40px; margin-bottom: 40px;
    display: flex; gap: 40px; flex-wrap: wrap; transition: all 0.3s;
    position: relative; overflow: hidden;
}
.project-card::before {
    content: ''; position: absolute; top: 0; left: 0; width: 4px; height: 100%;
    background: var(--primary); transform: scaleY(0); transition: transform 0.3s ease;
    transform-origin: bottom;
}
.project-card:hover { border-color: rgba(255,255,255,0.1); box-shadow: 0 10px 40px rgba(0,0,0,0.4); transform: translateY(-5px); }
.project-card:hover::before { transform: scaleY(1); }

.project-info { flex: 1.5; min-width: 300px; }
.project-info h3 { font-size: 2.2rem; color: var(--text-main); margin-bottom: 5px; }
.project-role { color: var(--accent); font-weight: 600; margin-bottom: 20px; display: inline-flex; align-items: center; gap: 8px; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; }
.project-info p { color: var(--text-muted); margin-bottom: 25px; font-size: 1.1rem; line-height: 1.7; }
.project-features { list-style: none; margin-bottom: 20px; }
.project-features li { margin-bottom: 15px; color: var(--text-muted); display: flex; gap: 15px; align-items: flex-start; }
.project-features li i { color: var(--primary); font-size: 1.2rem; margin-top: 3px; }

.project-quote {
    flex: 1; min-width: 250px; display: flex; align-items: center;
}
.quote-box {
    background: rgba(0,0,0,0.3); padding: 30px; border-radius: 12px;
    border-left: 4px solid var(--accent); box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
}
.quote-box p { font-style: italic; color: var(--text-muted); font-size: 1.1rem; line-height: 1.8; }

/* Animations */
.animate-on-scroll { opacity: 0; transform: translateY(40px); transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1); }
.animate-on-scroll.show { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 768px) {
    .about-grid { grid-template-columns: 1fr; gap: 20px; }
    .pro-hero h1 { font-size: 2.2rem; }
    .pro-hero p { font-size: 1.1rem; }
    .project-card { padding: 20px; }
    .container { width: 95%; }
    .btn { padding: 10px 20px; font-size: 0.85rem; }
    #hacker-terminal { width: 95vw; left: 2.5vw; bottom: 80px; height: 300px; }
    #hacker-terminal-btn { bottom: 20px; left: 20px; width: 50px; height: 50px; font-size: 1.2rem; }
    .hero-buttons { flex-direction: column; gap: 10px; width: 100%; }
    .hero-buttons .btn { width: 100%; }
}

/* Dynamic Interactive Elements */
.mouse-glow {
    position: fixed;
    width: 800px; height: 800px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.05) 0%, transparent 60%);
    border-radius: 50%;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: -1;
}

.scroll-progress {
    position: fixed; top: 0; left: 0; height: 3px;
    background: var(--primary);
    z-index: 1000; width: 0%;
    box-shadow: 0 0 15px var(--primary);
    transition: width 0.1s ease;
}

/* 3D Transform Prep for JS */
.project-card, .stat-box {
    transform-style: preserve-3d;
    transition: transform 0.1s, border-color 0.3s, box-shadow 0.3s !important; 
}
.project-card:hover, .stat-box:hover {
    box-shadow: 0 15px 40px rgba(0,0,0,0.6);
}
.project-info, .project-quote, .stat-box i {
    transform: translateZ(40px);
}

/* Hacker Terminal */
#hacker-terminal-btn {
    position: fixed; bottom: 30px; left: 30px; z-index: 1000;
    width: 60px; height: 60px; background: rgba(0,0,0,0.8);
    border: 1px solid var(--primary); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: var(--primary); font-size: 1.5rem; cursor: pointer;
    box-shadow: 0 0 15px rgba(56, 189, 248, 0.4);
    transition: all 0.3s ease;
}
#hacker-terminal-btn:hover { transform: scale(1.1); box-shadow: 0 0 25px rgba(56, 189, 248, 0.8); }

#hacker-terminal {
    position: fixed; bottom: 100px; left: 30px; z-index: 1000;
    width: 500px; max-width: 90vw; height: 350px;
    background: rgba(10, 10, 10, 0.95);
    border: 1px solid #333; border-radius: 8px;
    display: flex; flex-direction: column;
    box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    transition: opacity 0.3s, transform 0.3s;
    backdrop-filter: blur(5px);
    overflow: hidden;
}
#hacker-terminal.terminal-hidden { opacity: 0; pointer-events: none; transform: translateY(20px); }

.terminal-header {
    background: #1e1e1e; padding: 10px; display: flex; align-items: center;
    border-bottom: 1px solid #333; cursor: grab;
}
.terminal-header:active { cursor: grabbing; }

.terminal-body {
    padding: 15px; flex: 1; overflow-y: auto;
    font-family: monospace; font-size: 0.95rem; line-height: 1.5;
    scrollbar-width: thin; scrollbar-color: #333 transparent;
}

@media (max-width: 768px) {
  .pro-nav .nav-container { flex-direction: column; justify-content: center; gap: 15px; padding: 15px; }
  .nav-brand { position: relative; left: 0; transform: none; margin-bottom: 10px; }
  .nav-links { gap: 15px; justify-content: center; flex-wrap: wrap; }
}


@media (max-width: 768px) {
  .nav-brand { font-size: 1.2rem !important; }
  .nav-links a { font-size: 0.8rem !important; }
  .pro-hero { padding-top: 100px !important; }
}


body, html { max-width: 100vw; overflow-x: hidden; }

