/* --- 1. RESET & VARS --- */
:root {
    --sidebar-width: 300px;
    --bg-color: #0a0a0a;
    --sidebar-bg: #111111;
    --card-bg: #161616;
    --accent: #00ff9d; /* Cyberpunk Green */
    --text-main: #e0e0e0;
    --text-dim: #888888;
    --border: #333333;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
}

/* TYPOGRAPHY */
h1, h2, h3, h4, .nav-item, .project-title, .tab-btn {
    font-family: 'JetBrains Mono', monospace;
}

a { text-decoration: none; color: inherit; transition: 0.2s; }

/* --- 2. LAYOUT --- */
.app-container { display: flex; min-height: 100vh; }

/* SIDEBAR */
.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border);
    position: fixed;
    top: 0; left: 0; bottom: 0;
    padding: 120px 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    z-index: 1000;
}

.profile-img {
    width: 200px; height: 200px;
    background-color: #333; /* Fallback color */
    background-size: cover; background-position: center;
    border-radius: 50%;
    margin: 0 auto 15px;
    border: 2px solid var(--border);
}

.profile-name { font-size: 1.2rem; font-weight: 700; text-align: center; color: #fff; }
.profile-role { font-size: 0.85rem; color: var(--accent); margin-top: 5px; text-align: center; font-family: 'JetBrains Mono'; }

.nav-menu { display: flex; flex-direction: column; gap: 10px; margin-top: 40px; }
.nav-item {
    display: block;
    padding: 10px 0;
    color: var(--text-dim);
    font-size: 1.2rem;
    border-left: 2px solid transparent;
}
.nav-item:hover, .nav-item.active {
    color: var(--accent);
    padding-left: 15px;
    border-left: 2px solid var(--accent);
}

.social-links { display: flex; gap: 15px; justify-content: center; margin-bottom: 20px;}
.social-icon { width: 24px; height: 24px; fill: var(--text-dim); }
.social-icon:hover { fill: var(--accent); }

/* MAIN CONTENT */
.main-content {
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
    padding: 80px 100px;
    max-width: none;
}

section { margin-bottom: 120px; scroll-margin-top: 50px; max-width: 1200px; /* Controls how wide the content gets */
    margin-left: auto;
    margin-right: auto;}

.section-header {
    font-size: 2rem;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
    color: #fff;
    display: flex; align-items: center;
}
.section-header::before { content: '#'; color: var(--accent); margin-right: 15px; }

.intro-text { font-size: 1.1rem; color: #ccc; max-width: 800px; margin-bottom: 40px; }
.accent { color: var(--accent); }

/* TECH GRID */
.tech-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px; margin-top: 20px;
}
.tech-item {
    background: var(--card-bg); border: 1px solid var(--border);
    padding: 13px; text-align: center; border-radius: 8px;
    font-weight: 600; color: #fff;
}
.tech-item span { display: block; font-size: 0.75rem; color: var(--text-dim); margin-top: 5px; font-weight: 400; }

/* PROJECT CARDS */
.project-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 50px;
}

.project-header {
    padding: 25px; background: #1a1a1a;
    border-bottom: 1px solid var(--border);
    display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px;
}
.project-title { font-size: 1.3rem; font-weight: bold; color: #fff; }
.project-subtitle { font-size: 0.85rem; color: #888; font-family: 'Inter'; }

.tag-container { display: flex; gap: 8px; }
.tag { font-size: 0.75rem; padding: 4px 10px; background: #333; border-radius: 4px; color: #ccc; font-family: 'JetBrains Mono'; }
.tag.highlight { border: 1px solid var(--accent); color: var(--accent); background: rgba(0,255,157,0.05); }

/* TABS */
.tab-nav { display: flex; border-bottom: 1px solid var(--border); background: #111; }
.tab-btn {
    background: none; border: none; color: var(--text-dim);
    padding: 15px 25px; cursor: pointer; font-size: 0.85rem;
    border-bottom: 2px solid transparent; transition: 0.2s;
}
.tab-btn:hover { color: #fff; }
.tab-btn.active { color: var(--accent); border-bottom: 2px solid var(--accent); background: rgba(0,255,157,0.05); }

.tab-content { padding: 30px; display: none; animation: fadeIn 0.3s ease; color: #ccc;}
.tab-content.active { display: block; }
.tab-content ul { margin-left: 20px; margin-top: 10px; }
.tab-content li { margin-bottom: 5px; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }

/* CODE SNIPPETS */
.code-snippet {
    background: #000; padding: 20px; border-radius: 6px;
    font-family: 'Courier New', monospace; font-size: 0.85rem;
    color: #d4d4d4; border-left: 3px solid var(--accent);
    margin-top: 20px; white-space: pre-wrap; overflow-x: auto;
}

/* IMAGES & VIDEO */
.project-image { width: 100%; border-radius: 4px; margin-top: 15px; border: 1px solid var(--border); }
.video-container {
    position: relative; padding-bottom: 56.25%; /* 16:9 */
    height: 0; overflow: hidden; margin-top: 15px; border-radius: 4px;
}
.video-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }

/* CV & ARTICLES */
.cv-box { text-align: center; padding: 40px; background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px; }
.download-btn { background: var(--accent); color: #000; padding: 12px 30px; font-weight: bold; border-radius: 4px; display: inline-block; margin-top: 15px; }
.download-btn:hover { background: #fff; }

.article-item {
    display: flex; justify-content: space-between; padding: 20px 0;
    border-bottom: 1px solid var(--border); cursor: pointer;
}
.article-item:hover .article-title { color: var(--accent); }
.article-title { font-weight: 600; color: #fff; }
.article-date { color: var(--text-dim); font-family: 'JetBrains Mono'; font-size: 0.85rem; }

/* FOOTER */
footer { text-align: center; color: #555; font-size: 0.8rem; margin-top: 80px; }

/* --- MOBILE RESPONSIVE --- */
@media (max-width: 900px) {
    .app-container { flex-direction: column; }
    
    .sidebar {
        position: relative; width: 100%; height: auto;
        flex-direction: row; align-items: center; padding: 15px 20px;
        border-right: none; border-bottom: 1px solid var(--border);
    }
    .nav-menu, .social-links, .profile-role { display: none; }
    
    .profile-section { margin: 0; text-align: left; display: flex; align-items: center; gap: 15px; }
    .profile-img { margin: 0; width: 60px; height: 60px; }
    .profile-name { font-size: 1rem; }
    
    .main-content { margin-left: 0; width: 100%; padding: 40px 20px; }
    .project-header { flex-direction: column; align-items: flex-start; }
    .tag-container { margin-top: 5px; }
}