/* ===============================
   CSS VARIABLES & THEME SETUP
=============================== */
:root {
    --bg-main: #060913;
    --bg-secondary: #0c1122;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    
    --accent-glow: rgba(99, 102, 241, 0.5);
    --primary-color: #6366f1;
    --primary-color-hover: #4f46e5;
    --secondary-color: #06b6d4;
    
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* ===============================
   GLOBAL STYLES
=============================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    display: block;
}

/* ===============================
   BACKGROUND EFFECTS
=============================== */
.bg-shape {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    opacity: 0.5;
    animation: float 10s infinite ease-in-out alternate;
}

.shape-1 {
    top: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--primary-color) 0%, transparent 70%);
}

.shape-2 {
    bottom: -10%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--secondary-color) 0%, transparent 70%);
    animation-delay: -5s;
}

.shape-3 {
    top: 40%;
    left: 40%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.3) 0%, transparent 70%);
    animation-duration: 15s;
}

@keyframes float {
    0% { transform: translateY(0px) scale(1); }
    100% { transform: translateY(30px) scale(1.1); }
}

/* ===============================
   TYPOGRAPHY
=============================== */
h1, h2, h3, h4, h5 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.gradient-text {
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--primary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

/* ===============================
   COMPONENTS
=============================== */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: var(--glass-shadow);
    transition: var(--transition);
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.2);
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    border: none;
    outline: none;
    transition: var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--text-secondary);
}

.btn-secondary:hover {
    border-color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

/* ===============================
   NAVIGATION
=============================== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
    transition: var(--transition);
    padding: 1.5rem 0;
}

.navbar.scrolled {
    background: rgba(6, 9, 19, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 1rem 0;
    border-bottom: 1px solid var(--glass-border);
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.logo span {
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    font-weight: 500;
    color: var(--text-secondary);
    position: relative;
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.nav-link.nav-btn {
    padding: 0.5rem 1rem;
    border: 1px solid var(--primary-color);
    border-radius: 0.5rem;
    color: var(--text-primary);
}

.nav-link.nav-btn::after {
    display: none;
}

.nav-link.nav-btn:hover {
    background: var(--primary-color);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===============================
   LAYOUT CONSTRAINTS
=============================== */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 6rem 0;
}

/* ===============================
   HERO SECTION
=============================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    padding-top: 120px;
}

.hero-content {
    flex: 1;
}

.greeting {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.name {
    font-size: 4rem;
    margin-bottom: 0.5rem;
    color: #fff;
}

.role {
    font-size: 2.5rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.summary {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
    margin-bottom: 2rem;
}

.cta-group {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.social-links-hero {
    display: flex;
    gap: 1.5rem;
}

.social-links-hero a {
    color: var(--text-secondary);
    font-size: 1.5rem;
    transition: var(--transition);
}

.social-links-hero a:hover {
    color: var(--primary-color);
    transform: translateY(-3px);
}

.hero-visual {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

/* IDE / CODE WINDOW CSS */
.code-window {
    background: #0f172a;
    border-radius: 12px;
    border: 1px solid #1e293b;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    width: 100%;
    max-width: 500px;
    overflow: hidden;
}

.window-header {
    background: #1e293b;
    padding: 0.8rem 1rem;
    display: flex;
    gap: 0.5rem;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ef4444; }
.dot.yellow { background: #eab308; }
.dot.green { background: #22c55e; }

.window-body {
    padding: 1.5rem;
    font-family: 'Fira Code', monospace, monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    overflow-x: auto;
}

.window-body pre {
    margin: 0;
}

.keyword { color: #c678dd; }
.class-name { color: #e5c07b; }
.string { color: #98c379; }
.variable { color: #e06c75; }
.number { color: #d19a66; }
.function { color: #61afef; }

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

.achievement-card {
    text-align: center;
}

.icon-box {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 1.5rem auto;
}

/* ===============================
   EXPERIENCE / TIMELINE
=============================== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    width: 2px;
    background: var(--glass-border);
    top: 0;
    bottom: 0;
    left: 20px;
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    padding-left: 60px;
}

.timeline-dot {
    position: absolute;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--secondary-color);
    left: 13px;
    top: 20px;
    box-shadow: 0 0 10px var(--secondary-color);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.company {
    color: var(--primary-color);
    font-weight: 500;
}

.date {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.3rem 0.8rem;
    border-radius: 2rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.task-list {
    list-style: none;
    color: var(--text-secondary);
}

.task-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
}

.task-list li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

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

.project-card {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    overflow: hidden;
    padding: 0;
}

.project-image-container {
    width: 100%;
    height: 180px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    padding: 1rem;
    border-bottom: 1px solid var(--glass-border);
}

.project-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.multi-image {
    max-width: 45%; /* For side-by-side images */
}

.project-content {
    padding: 1.5rem;
}

.project-card h4 {
    font-size: 1.3rem;
    color: var(--text-primary);
}

.tag {
    font-size: 0.8rem;
    color: var(--secondary-color);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

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

.skill-category h4 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.tags span {
    background: rgba(99, 102, 241, 0.1);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

/* ===============================
   CONTACT PAGE
=============================== */
.contact-page {
    padding-top: 150px;
    min-height: calc(100vh - 80px); /* Minus footer */
}

.page-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: 1.2rem;
    max-width: 600px;
    margin-bottom: 4rem;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 4rem;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.contact-info p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.info-items {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.icon-box-small {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.info-item h5 {
    margin-bottom: 0.2rem;
    font-size: 1rem;
}

.info-item a {
    color: var(--text-secondary);
}

.info-item a:hover {
    color: var(--primary-color);
}

.social-links-contact p {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.social-links-contact .links {
    display: flex;
    gap: 1rem;
}

.social-links-contact a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: var(--transition);
}

.social-links-contact a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

/* Contact Form */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--glass-border);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(0, 0, 0, 0.4);
}

.w-100 {
    width: 100%;
}

/* ===============================
   FOOTER
=============================== */
footer {
    border-top: 1px solid var(--glass-border);
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-secondary);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

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

/* ===============================
   ANIMATIONS & UTILS
=============================== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ===============================
   RESPONSIVE QUERIES
=============================== */
@media (max-width: 992px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 150px;
    }
    
    .social-links-hero {
        justify-content: center;
    }
    
    .cta-group {
        justify-content: center;
    }

    .summary {
        margin: 0 auto 2rem auto;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 14px;
    }

    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--bg-main);
        flex-direction: column;
        padding: 2rem 0;
        gap: 1.5rem;
        transform: translateY(-150%);
        transition: transform 0.3s ease;
        border-bottom: 1px solid var(--glass-border);
        z-index: 99;
    }

    .nav-links.active {
        transform: translateY(0);
    }

    .timeline::before {
        left: 15px;
    }

    .timeline-item {
        padding-left: 45px;
    }

    .timeline-dot {
        left: 8px;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}
