/* ==========================================================================
   ULTRA-MINIMALIST DESIGN SYSTEM (HIGH CONTRAST LIGHT MODE)
   ========================================================================== */
:root {
    /* Color Palette */
    --bg-main: #fcfcfd;        /* Near-white soft warm ivory */
    --bg-sidebar: #ffffff;
    --border-color: rgba(15, 23, 42, 0.05);
    
    /* Typography Colors */
    --text-primary: #090d16;   /* Rich deep obsidian */
    --text-secondary: #475569; /* Slate 600 */
    --text-muted: #8e9cae;     /* Slate 400 */
    
    /* Accent Elements */
    --accent: #2c2c2c;         /* Indigo 600 */
    --accent-light: rgba(79, 70, 229, 0.05);
    
    /* Layout Constants */
    --sidebar-width: 380px;
    --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    --radius-sm: 6px;
    --radius-md: 12px;
}

/* ==========================================================================
   RESET & SYSTEM BASICS
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-secondary);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3 {
    color: var(--text-primary);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.04em;
}

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

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(15, 23, 42, 0.08);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(15, 23, 42, 0.16);
}

/* ==========================================================================
   SPLIT LAYOUT CONTAINER
   ========================================================================== */
.portfolio-container {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
}

/* ==========================================================================
   MINIMALIST SIDEBAR (LEFT COLUMN)
   ========================================================================== */
.sidebar {
    background-color: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    height: 100vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    padding: 5rem 4rem 4rem 4rem;
}

/* Brand Details */
.sidebar-brand {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin: auto 0;
}

.avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    transition: var(--transition-smooth);
}

.avatar-text {
    color: #ffffff;
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 0.05em;
}

.brand-name {
    font-size: 2.25rem;
    font-weight: 900;
    letter-spacing: -0.05em;
    color: var(--text-primary);
}

.brand-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 0.35rem;
}

.brand-bio {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-secondary);
    max-width: 280px;
    margin-top: 1rem;
}

/* Footer / Socials */
.sidebar-footer {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: auto;
}

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

.social-btn {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background-color: var(--bg-main);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.social-btn:hover {
    color: var(--text-primary);
    background-color: #ffffff;
    border-color: var(--text-primary);
    transform: translateY(-2px);
}

.sidebar-copyright {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.02em;
}

/* ==========================================================================
   WORKS PANELS (RIGHT COLUMN - INDEPENDENT SCROLL)
   ========================================================================== */
.content-scroll {
    height: 100vh;
    overflow-y: auto;
    background-color: var(--bg-main);
    padding: 0;
}

.works-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 6rem 8% 8rem 8%;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Project Item - List/Index Style */
.project-item {
    padding: 5rem 0;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    transition: var(--transition-smooth);
}

/* Sibling focus fade interaction */
.works-container:hover .project-item:not(:hover) {
    opacity: 0.25;
    filter: blur(0.5px);
}

.project-header {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    position: relative;
}

.project-num {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent);
}

.project-name {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--text-primary);
    transition: var(--transition-smooth);
    position: relative;
    display: inline-block;
}

/* Subtle line-reveal effect on hover */
.project-name::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--text-primary);
    transition: var(--transition-smooth);
}

.project-item:hover .project-name::after {
    width: 100%;
}

.project-year {
    margin-left: auto;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
}

/* Big cover image element */
.project-cover {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
    margin: 1.5rem 0 0.5rem 0;
    background-color: var(--bg-main);
}

.cover-img {
    width: 100%;
    /* height: 100%; */
    object-fit: cover;
    display: block;
    transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Image zoom micro-interaction on hover */
.project-item:hover .cover-img {
    transform: scale(1.04);
}

.project-description {
    font-size: 1.05rem;
    line-height: 1.65;
    color: var(--text-secondary);
    max-width: 760px;
}

.project-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 0.5rem;
}

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

.tag {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    background-color: #ffffff;
    border: 1px solid var(--border-color);
    padding: 0.3rem 0.65rem;
    border-radius: var(--radius-sm);
}

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

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
}

.project-link:hover {
    color: var(--accent);
}

.project-link svg {
    transition: transform 0.25s ease;
}

.project-link:hover svg {
    transform: translate(2px, -2px);
}

/* ==========================================================================
   RESPONSIVE DESIGN BREAKPOINTS (MOBILE & TABLET VIEWS)
   ========================================================================== */

@media (max-width: 1023px) {
    .portfolio-container {
        grid-template-columns: 1fr;
        height: auto;
        overflow: visible;
    }
    
    /* Top header for mobile */
    .sidebar {
        height: auto;
        position: relative; /* Scrolls naturally with content */
        padding: 3.5rem 2rem 2.5rem 2rem;
        background: var(--bg-sidebar);
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        gap: 1.5rem;
    }
    
    .sidebar-brand {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.25rem;
        margin: 0;
        width: 100%;
    }
    
    .avatar {
        width: 36px;
        height: 36px;
        border-radius: var(--radius-sm);
    }
    
    .avatar-text {
        font-size: 0.8rem;
    }
    
    .brand-name {
        font-size: 1.25rem;
    }
    
    .sidebar-meta, .sidebar-footer {
        display: none; /* Keep metadata and social footers hidden */
    }
    
    .brand-title {
        display: block;
        font-size: 0.8rem;
        font-weight: 700;
        color: var(--accent);
        text-transform: uppercase;
        letter-spacing: 0.08em;
        margin-top: 0.15rem;
    }
    
    .brand-bio {
        display: block;
        font-size: 0.95rem;
        line-height: 1.6;
        color: var(--text-secondary);
        max-width: 100%;
        margin-top: 0.75rem;
    }
    
    .content-scroll {
        height: auto;
        overflow: visible;
    }
    
    .works-container {
        padding: 4rem 1.5rem 6rem 1.5rem;
    }
    
    .project-item {
        padding: 3rem 0;
    }
    
    .project-name {
        font-size: 1.6rem;
    }
    
    .project-description {
        font-size: 0.95rem;
    }
    
    .project-cover {
        margin: 1rem 0 0.25rem 0;
    }
}

@media (max-width: 480px) {
    .sidebar {
        padding: 2.5rem 1.25rem 2rem 1.25rem;
    }
    
    .avatar {
        width: 32px;
        height: 32px;
    }
    
    .brand-name {
        font-size: 1.1rem;
    }
    
    .project-header {
        flex-wrap: wrap;
        gap: 0.25rem;
    }
    
    .project-year {
        width: 100%;
        margin-left: 0;
        margin-top: 0.25rem;
    }
    
    .project-name {
        font-size: 1.4rem;
    }
}
