/* ===== PREMIUM RESET ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #000000;
    --secondary: #0a0a0a;
    --glass: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.03);
    --glass-border-hover: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.3);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.6);
    --text-tertiary: rgba(255, 255, 255, 0.3);
    --gradient-glass: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.02) 50%, rgba(255,255,255,0) 100%);
    --transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    --border-radius: 24px;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, sans-serif;
    background-color: var(--primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    font-weight: 300;
}

/* ===== 3D GLASS CORE ===== */
.glass-panel {
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(200%);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.glass-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-glass);
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
}

.glass-panel:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-2px);
    box-shadow: var(--glass-shadow);
}

.glass-panel:hover::before {
    opacity: 1;
}

.glass-3d {
    transform-style: preserve-3d;
    perspective: 1000px;
    transition: var(--transition);
}

.glass-3d:hover {
    transform: perspective(1000px) rotateX(1deg) rotateY(1deg) scale(1.02);
}

/* ===== CUSTOM CURSOR ===== */
.cursor {
    position: fixed;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    opacity: 0.5;
    mix-blend-mode: difference;
}

.cursor-follower {
    position: fixed;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    opacity: 0.3;
}

/* ===== 3D CANVAS ===== */
#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* ===== NAVIGATION ===== */
.nav {
    position: fixed;
    top: 2rem;
    left: 2rem;
    right: 2rem;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 2.5rem;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 100px;
    transition: var(--transition);
}

.nav.scrolled {
    top: 1.5rem;
    background: rgba(0, 0, 0, 0.6);
}

.logo {
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-primary);
    text-decoration: none;
}

.logo span {
    opacity: 0.5;
    margin: 0 0.2rem;
}

.nav-links {
    display: flex;
    gap: 3rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: white;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* ===== LOADING ===== */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 1s ease, visibility 1s ease;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s infinite linear;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== PROJECT HERO ===== */
.project-hero {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.project-hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.project-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    animation: heroZoom 20s infinite alternate;
}

@keyframes heroZoom {
    0% { transform: scale(1); }
    100% { transform: scale(1.1); }
}

.project-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.8) 100%);
    z-index: 2;
}

.project-hero-content {
    position: relative;
    z-index: 3;
    text-align: center;
    max-width: 900px;
    padding: 0 2rem;
}

.project-eyebrow {
    font-size: 0.8rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    opacity: 0.8;
}

.project-title {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 400;
    letter-spacing: -0.02em;
    line-height: 1;
    margin-bottom: 2rem;
}

.project-title span {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    color: var(--text-secondary);
    display: block;
    font-size: clamp(2rem, 6vw, 4rem);
}

.project-categories {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.project-category {
    padding: 0.5rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 100px;
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-secondary);
    transition: var(--transition);
}

.project-category:hover {
    border-color: rgba(255, 255, 255, 0.3);
    color: var(--text-primary);
}

.scroll-indicator {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    opacity: 0.5;
    text-decoration: none;
    color: white;
}

.scroll-indicator:hover {
    opacity: 1;
}

.scroll-text {
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    writing-mode: vertical-rl;
}

.scroll-line {
    width: 1px;
    height: 80px;
    background: linear-gradient(to bottom, white, transparent);
}

/* ===== PROJECT CONTENT ===== */
.project-content {
    position: relative;
    padding: 6rem 2rem;
    z-index: 10;
}

.project-container {
    max-width: 1400px;
    margin: 0 auto;
}

.section-number {
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    color: var(--text-tertiary);
    margin-bottom: 1rem;
}

/* Overview */
.project-overview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
    margin-bottom: 6rem;
}

.overview-left {
    position: sticky;
    top: 120px;
    height: fit-content;
}

.overview-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 400;
    letter-spacing: -0.02em;
    line-height: 1.2;
    margin-top: 2rem;
}

.overview-title span {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    color: var(--text-secondary);
    display: block;
}

.overview-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* Stats Grid */
.project-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: 6rem;
}

.stat-card {
    aspect-ratio: 1;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: rgba(0, 0, 0, 0.6);
}

.stat-card-number {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 0.5rem;
}

.stat-card-label {
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
}

/* Gallery Grid */
.project-gallery {
    margin-bottom: 6rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-top: 2rem;
}

.gallery-item {
    cursor: pointer;
    overflow: hidden;
    position: relative;
}

.gallery-item::after {
    content: '🔍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    font-size: 2rem;
    color: white;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 2;
    text-shadow: 0 0 10px rgba(0,0,0,0.5);
}

.gallery-item:hover::after {
    opacity: 0.8;
    transform: translate(-50%, -50%) scale(1);
}

.gallery-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.gallery-item:hover::before {
    opacity: 1;
}

.gallery-item-main {
    grid-column: span 2;
    grid-row: span 2;
    aspect-ratio: 4/3;
}

.gallery-item-small {
    aspect-ratio: 4/3;
}

.gallery-item-wide {
    grid-column: span 3;
    aspect-ratio: 4/1;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: var(--transition);
}

.gallery-item:hover img {
    filter: grayscale(0%);
    transform: scale(1.05);
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-image-container {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.lightbox-close {
    position: absolute;
    top: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10001;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10001;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
}

.lightbox-nav.prev {
    left: 2rem;
}

.lightbox-nav.next {
    right: 2rem;
}

.lightbox-counter {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: var(--text-secondary);
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    background: rgba(0,0,0,0.5);
    padding: 0.5rem 1rem;
    border-radius: 100px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Details Grid */
.project-details {
    margin-bottom: 6rem;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-top: 2rem;
}

.detail-item {
    aspect-ratio: 1;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: rgba(0, 0, 0, 0.6);
}

.detail-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-tertiary);
}

.detail-title {
    font-size: 0.9rem;
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 0.5rem;
}

.detail-text {
    font-size: 1rem;
    line-height: 1.5;
    color: var(--text-secondary);
}

/* Description */
.project-description {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
    margin-bottom: 6rem;
    padding: 4rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.02);
}

.description-subtitle {
    font-size: 1rem;
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 1.5rem;
}

.description-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

/* Next Project */
.next-project {
    text-align: center;
}

.next-project-label {
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 2rem;
}

.next-project-link {
    display: inline-flex;
    align-items: center;
    gap: 2rem;
    padding: 1.5rem 3rem;
    background: var(--glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
    font-size: 1.2rem;
}

.next-project-link:hover {
    border-color: var(--glass-border-hover);
    transform: translateX(10px);
}

.next-project-arrow {
    font-size: 1.2rem;
    opacity: 0.5;
    transition: var(--transition);
}

.next-project-link:hover .next-project-arrow {
    opacity: 1;
    transform: translateX(5px);
}

/* ===== FOOTER ===== */
.footer {
    padding: 4rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.02);
    position: relative;
    z-index: 10;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.copyright {
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .project-overview {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .overview-left {
        position: relative;
        top: 0;
    }
    
    .project-stats-grid,
    .details-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery-item-main {
        grid-column: span 2;
    }
    
    .gallery-item-wide {
        grid-column: span 2;
    }
    
    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .project-stats-grid,
    .details-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-item-main {
        grid-column: span 1;
    }
    
    .gallery-item-wide {
        grid-column: span 1;
        aspect-ratio: 4/3;
    }
    
    .project-description {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .next-project-link {
        padding: 1rem 2rem;
        font-size: 1rem;
        gap: 1rem;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .lightbox-nav {
        top: auto;
        bottom: 5rem;
        transform: none;
    }
    
    .lightbox-nav.prev {
        left: 1rem;
    }
    
    .lightbox-nav.next {
        right: 1rem;
    }
    
    .lightbox-close {
        top: 1rem;
        right: 1rem;
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
}