/* BASE & VARIABLES */
@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;600&family=Outfit:wght@300;400;600;800&display=swap');

:root {
    --bg-dark: #07090e;
    --bg-lighter: #12151e;
    --primary: #00f3ff;
    --secondary: #14c767;
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    --glass-bg: rgba(18, 21, 30, 0.6);
    --glass-border: rgba(255, 255, 255, 0.05);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* TYPOGRAPHY */
h1, h2, h3 { line-height: 1.2; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* NAVBAR */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 5%;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(7, 9, 14, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    transition: var(--transition);
}
.navbar.scrolled {
    padding: 1rem 5%;
    background: rgba(7, 9, 14, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}
.logo {
    font-size: 1.8rem; font-weight: 800; cursor: pointer;
}
.logo span { color: var(--primary); font-family: 'Fira Code', monospace; font-size: 1.4rem; }

.nav-links { display: flex; gap: 2rem; align-items: center; }
.nav-links a { font-weight: 500; font-size: 1rem; transition: var(--transition); }
.nav-links a:hover { color: var(--primary); }
.hamburger { display: none; font-size: 1.5rem; cursor: pointer; }

/* BUTTONS */
.btn-primary, .btn-secondary {
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), #00a2ff);
    color: #000;
    box-shadow: 0 4px 15px rgba(0, 243, 255, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 243, 255, 0.5);
}
.btn-secondary {
    background: transparent;
    border: 1px solid var(--secondary);
    color: var(--secondary);
}
.btn-secondary:hover {
    background: rgba(20, 199, 103, 0.1);
    transform: translateY(-2px);
}
.w-full { width: 100%; justify-content: center; }

/* HERO SECTION */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 5%;
    margin-top: 60px;
    position: relative;
    overflow: hidden;
}
/* Glowing background blur effect */
.hero::before {
    content: ''; position: absolute; width: 40vw; height: 40vw; top: 10%; right: -10%;
    background: radial-gradient(circle, rgba(0, 243, 255, 0.1) 0%, rgba(7, 9, 14, 0) 70%);
    z-index: -1;
}

.hero-content { flex: 1; z-index: 2; }
.hero-image { flex: 1; display: flex; justify-content: center; align-items: center; z-index: 2; }

.subtitle { color: var(--secondary); font-family: 'Fira Code', monospace; letter-spacing: 2px; margin-bottom: 1rem; text-transform: uppercase; }
.title { font-size: clamp(3rem, 5vw, 5rem); font-weight: 800; margin-bottom: 0.5rem; background: -webkit-linear-gradient(#ffffff, #94a3b8); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.typing-text { font-size: 2rem; color: var(--text-main); margin-bottom: 1.5rem; font-weight: 600;}
.typing-text #typed-output { color: var(--primary); }
.cursor { color: var(--primary); font-weight: 800; animation: blink 1s infinite; }

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.description { color: var(--text-muted); font-size: 1.1rem; max-width: 500px; margin-bottom: 2rem; }

.social-links { display: flex; gap: 1.2rem; margin-bottom: 2.5rem; }
.social-links a {
    width: 45px; height: 45px; border-radius: 50%;
    background: var(--bg-lighter);
    display: flex; justify-content: center; align-items: center;
    font-size: 1.2rem; transition: var(--transition);
    border: 1px solid var(--glass-border);
}
.social-links a:hover {
    background: var(--primary); color: #000;
    transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0, 243, 255, 0.4);
}

.hero-buttons { display: flex; gap: 1rem; }

/* 3D CUBE ANIMATION */
.cube-wrapper { perspective: 800px; width: 250px; height: 250px; }
.cube { width: 100%; height: 100%; position: relative; transform-style: preserve-3d; animation: spinCube 20s infinite linear; }
.face {
    position: absolute; width: 250px; height: 250px;
    background: rgba(18, 21, 30, 0.85);
    border: 2px solid var(--primary);
    display: flex; justify-content: center; align-items: center;
    font-size: 5rem; color: var(--text-main);
    box-shadow: inset 0 0 40px rgba(0, 243, 255, 0.2);
    backdrop-filter: blur(5px);
}
.face.front  { transform: translateZ(125px); }
.face.back   { transform: rotateY(180deg) translateZ(125px); }
.face.right  { transform: rotateY(90deg) translateZ(125px); color: var(--secondary); border-color: var(--secondary); box-shadow: inset 0 0 40px rgba(20, 199, 103, 0.2); }
.face.left   { transform: rotateY(-90deg) translateZ(125px); color: var(--secondary); border-color: var(--secondary); box-shadow: inset 0 0 40px rgba(20, 199, 103, 0.2); }
.face.top    { transform: rotateX(90deg) translateZ(125px); }
.face.bottom { transform: rotateX(-90deg) translateZ(125px); }

@keyframes spinCube {
    0% { transform: rotateX(0deg) rotateY(0deg); }
    100% { transform: rotateX(360deg) rotateY(360deg); }
}

/* SECTIONS COMMONS */
section { padding: 5rem 5%; }
.section-header { text-align: center; margin-bottom: 4rem; }
.section-header h2 { font-size: 2.5rem; position: relative; display: inline-block; margin-bottom: 1rem; color: #fff; }
.section-header h2::after { content: ''; position: absolute; bottom: -10px; left: 50%; transform: translateX(-50%); width: 50px; height: 4px; background: var(--primary); border-radius: 2px; }
.section-header p { color: var(--text-muted); font-size: 1.1rem; margin-top: 10px; }

/* SKILLS */
.skills-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}
.skill-card {
    background: var(--bg-lighter);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    transition: var(--transition);
    width: 200px;
}
.skill-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(0, 243, 255, 0.15);
}
.skill-icon { font-size: 3.5rem; margin-bottom: 1rem; }
.skill-card h3 { font-size: 1.1rem; font-weight: 600; }

/* PROJECTS */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    max-width: 1200px;
    margin: 0 auto;
}
.project-card {
    background: var(--bg-lighter);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--glass-border);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}
.project-card:hover { transform: translateY(-10px); box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7); border-color: var(--secondary); }
.project-img { width: 100%; height: 220px; overflow: hidden; }
.project-img img { width: 100%; height: 100%; object-fit: cover; transition: all 0.5s ease; filter: brightness(0.85); }
.project-card:hover .project-img img { transform: scale(1.05); filter: brightness(1.1); }

.project-content { padding: 2rem; flex: 1; display: flex; flex-direction: column; }
.project-content h3 { font-size: 1.4rem; margin-bottom: 1rem; color: #fff; }
.project-content p { color: var(--text-muted); margin-bottom: 1.5rem; font-size: 0.95rem; flex: 1; }
.project-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.5rem; }
.project-tags span { background: rgba(0, 243, 255, 0.1); color: var(--primary); padding: 0.3rem 0.8rem; border-radius: 20px; font-size: 0.8rem; font-weight: 600; font-family: 'Fira Code', monospace; }
.project-link { display: inline-flex; align-items: center; gap: 0.5rem; color: var(--text-main); font-weight: 600; transition: var(--transition); margin-top: auto; }
.project-link:hover { color: var(--primary); }

/* CONTACT */
.contact-section { display: flex; justify-content: center; padding-bottom: 8rem; }
.contact-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    padding: 4rem 3rem;
    border-radius: 20px;
    text-align: center;
    max-width: 600px;
    width: 100%;
}
.contact-card h2 {font-size: 2.2rem; margin-bottom: 1rem; color: #fff;}
.contact-card p { color: var(--text-muted); margin: 0 0 2.5rem 0; font-size: 1.1rem; }

/* FOOTER */
footer { text-align: center; padding: 2rem 5%; border-top: 1px solid var(--glass-border); color: var(--text-muted); font-size: 0.9rem; background: var(--bg-lighter);}

/* RESPONSIVE */
@media (max-width: 900px) {
    .navbar { padding: 1rem 5%; }
    .hero { flex-direction: column-reverse; justify-content: center; text-align: center; padding-top: 2rem; min-height: auto;}
    .hero-content { margin-top: 3rem; display: flex; flex-direction: column; align-items: center; margin-bottom: 4rem;}
    .hero-buttons, .social-links { justify-content: center; }
    .description { text-align: center; }
    .nav-links { display: none; } /* Mobile toggle implementation can be added */
    .cube-wrapper { transform: scale(0.8); margin-top: 2rem;}
}
