/*THEME VARIABLES*/
:root {
    /* Dark Theme */
    --bg-body: #0a0a0a;
    --bg-sidebar: #000000;
    --text-main: #ffffff;
    --text-muted: #a3a3a3;
    
    /* #A 2 -- Accent Color (Darkened for contrast compliance:: checking done by https://webaim.org/resources/contrastchecker/) */
    --accent: #7c3aed; 
    --accent-hover: #6d28d9;
    
    --card-bg: #171717;
    --border-color: #333333;
    
    /* Fonts */
    --font-main: 'Roboto', sans-serif;
    --font-pixel: 'VT323', monospace;
    
    --sidebar-width: 260px;
}

/* light theme*/
[data-theme="light"] {
    --bg-body: #f3f4f6;
    --bg-sidebar: #ffffff;
    --text-main: #111827;
    --text-muted: #4b5563;
    --accent: #2563eb; 
    --accent-hover: #1d4ed8;
    --card-bg: #ffffff;
    --border-color: #e5e7eb;
}

/* resting and base ( source from https://stackoverflow.com/questions/46923610/css-resetting-margin-and-padding ) */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* global Focus State for keyboard navigation( from https://wise.design/foundations/focus-states) */
:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    transition: background-color 0.3s, color 0.3s;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* Utility class for screen readers */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.pixel-font {
    font-family: var(--font-pixel);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* --- wrapping layout --- */
.layout-wrapper {
    display: flex;
    min-height: 100vh;
}

/* styling sidebar (https://ui.shadcn.com/docs/components/sidebar) */
.sidebar {
    width: var(--sidebar-width);
    background-color: var(--bg-sidebar);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    padding: 2rem;
    border-right: 1px solid var(--border-color);
    z-index: 100;
    transition: transform 0.3s ease;
}

.profile-container {
    text-align: center;
    margin-bottom: 3rem;
}

.profile-img-circle {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 1rem;
    border: 3px solid var(--accent);
    background-color: #333;
}

.profile-img-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-name {
    font-size: 2rem;
    line-height: 1;
    color: var(--text-main);
}

/* Navigation Links */
.vertical-nav ul {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.nav-link {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 1px;
}

.nav-link:hover, .nav-link.active {
    color: var(--accent);
    padding-left: 5px; 
}

/* Sidebar Footer & Socials */
.sidebar-footer {
    margin-top: auto;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.social-list {
    display: flex;
    flex-direction: column; 
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.social-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.95rem;
    transition: transform 0.2s, color 0.2s;
}

.social-item:hover {
    color: var(--accent);
    transform: translateX(5px); /* small slide effect on hover */
}

.social-icon {
    width: 22px;
    height: 22px;
    fill: currentColor; /* to inherits text color */
}

.copyright {
    font-size: 0.8rem;
    opacity: 0.7;
}


/* MAIN CONTENT AREA*/
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    width: calc(100% - var(--sidebar-width));
}

.section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem;
    border-bottom: 1px solid var(--border-color);
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    width: 100%;
}

.section-title {
    font-size: 3rem;
    margin-bottom: 2rem;
    color: var(--text-main);
    opacity: 0.9;
}

/* HERO SECTION */
.hero-section {
    background-color: var(--bg-body);
    position: relative;
    display: flex;
    align-items: center;
}

.hero-overlay h1 {
    font-size: 8rem;
    line-height: 0.9;
    margin-bottom: 1rem;
}

.hero-intro {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 2rem;
}

.highlight {
    color: var(--accent);
    font-weight: 700;
}

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

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: var(--accent);
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
    border: 2px solid var(--accent);
    cursor: pointer;
    transition: 0.3s;
}

.btn:hover {
    background-color: transparent;
    color: var(--accent);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--text-main);
    color: var(--text-main);
}

.btn-outline:hover {
    background-color: var(--text-main);
    color: var(--bg-body);
    border-color: var(--text-main);
}

/*ABOUT GRID*/
.about-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
}

.timeline li {
    margin-bottom: 1rem;
    border-left: 2px solid var(--accent);
    padding-left: 1rem;
}

.skill-tags span {
    display: inline-block;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 5px 10px;
    margin: 3px;
    font-size: 0.9rem;
    color: var(--accent);
    font-weight: bold;
}

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

.project-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    transition: transform 0.3s;
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent);
}

.card-image {
    height: 180px;
    background-color: #2a2a2a; 
    overflow: hidden; 
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
}

.card-content {
    padding: 1.5rem;
}

.card-category {
    color: var(--accent);
    font-size: 0.9rem;
    display: block;
    margin-bottom: 0.5rem;
}

/* --- CONTACT FORM --- */
.contact-wrapper {
    max-width: 600px;
}

.contact-sub {
    margin-bottom: 2rem;
    color: var(--text-muted);
}

.input-group {
    margin-bottom: 1.5rem;
}

.input-group input, .input-group textarea {
    width: 100%;
    padding: 1rem;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    font-family: var(--font-main);
    font-size: 1rem;
}

.input-group input:focus, .input-group textarea:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-color: var(--accent);
}

.feedback-msg {
    margin-top: 1rem;
    padding: 1rem;
    background-color: var(--accent);
    color: white;
    display: none;
}

.feedback-success { display: block; }

/*THEME TOGGLE BUTTONN*/
.theme-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--card-bg);
    border: 2px solid var(--accent);
    color: var(--accent);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

.theme-btn:hover {
    background-color: var(--accent);
    color: white;
}

/*FOR MOBILE TOGGLE*/
.mobile-toggle {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 200;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
}

.mobile-toggle span {
    width: 30px;
    height: 3px;
    background-color: var(--accent);
}

/*RESPONSIVE INTERFACE*/
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%); 
        width: 80%;
    }
    
    .sidebar.active {
        transform: translateX(0); 
    }

    .main-content {
        margin-left: 0;
        width: 100%;
    }

    .mobile-toggle {
        display: flex;
    }

    .section {
        padding: 4rem 1.5rem;
    }

    .hero-overlay h1 {
        font-size: 4rem;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }
}
