/* assets/css/style.css */
@import './reset.css';
@import './typography.css';

/* Layout */
.container {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 var(--gap-m);
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 var(--gap-m);
    z-index: 1005;
    /* Increased to stay above nav-overlay (1001) */
    mix-blend-mode: difference;
}

.logo {
    font-weight: 700;
    font-size: 1.25rem;
    color: white;
    /* mix-blend-mode makes this black on white bg */
}

.nav-toggle {
    display: flex;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.nav-toggle span {
    width: 24px;
    height: 1px;
    background-color: white;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: 100px;
}

.hero .display-text {
    margin-bottom: var(--gap-m);
}

/* Infinite Stream (Grid) */
.stream {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: var(--gap-m);
    padding-bottom: var(--gap-xl);
}

.stream-item {
    grid-column: span 12;
    opacity: 0;
    transform: translateY(50px);
    transition: transform 1.2s var(--ease-out-expo), opacity 1.2s var(--ease-out-expo);
}

.stream-item.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.stream-item.large {
    grid-column: span 12;
}

.stream-item.medium {
    grid-column: span 6;
}

.stream-item.small {
    grid-column: span 4;
}

.work-card {
    position: relative;
    overflow: hidden;
    background-color: var(--bg-accent);
}

.work-card img {
    width: 100%;
    aspect-ratio: 16/10;
    object-fit: cover;
    transition: transform 0.8s var(--ease-out-expo);
}

.work-card:hover img {
    transform: scale(1.05);
}

.work-info {
    margin-top: var(--gap-s);
}

.work-info .title {
    font-size: 1.25rem;
    font-weight: 500;
}

.work-info .category {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Mix-in Card (About/Contact link in grid) */
.mixin-card {
    grid-column: span 12;
    background-color: var(--text-primary);
    color: white;
    padding: var(--gap-l);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    aspect-ratio: 16/7;
}

/* Ambient Background */
.ambient-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-color: var(--bg-white);
    transition: background-color 1s ease;
}

.blob {
    position: absolute;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(230, 230, 230, 0.4) 0%, rgba(255, 255, 255, 0) 70%);
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    transition: transform 2s var(--ease-out-expo);
}

/* Responsive */
@media (max-width: 1024px) {
    .stream-item.medium {
        grid-column: span 12;
    }

    .stream-item.small {
        grid-column: span 6;
    }
}

@media (max-width: 768px) {
    :root {
        --gap-xl: 80px;
        --gap-l: 60px;
        --gap-m: 20px;
    }

    header {
        height: 70px;
    }

    .stream-item.small {
        grid-column: span 12;
    }

    .mixin-card {
        padding: var(--gap-m);
        aspect-ratio: 1/1;
    }

    .display-text {
        font-size: 3rem;
    }
}

/* Navigation Overlay */
.nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--text-primary);
    z-index: 1001;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.6s var(--ease-out-expo);
}

.nav-overlay.is-active {
    opacity: 1;
    visibility: visible;
}

.nav-menu {
    text-align: center;
}

.nav-menu ul li {
    margin-bottom: var(--gap-s);
    overflow: hidden;
}

.nav-menu ul li a {
    font-family: var(--font-eng);
    font-size: clamp(2rem, 5vw, 4rem);
    color: white;
    font-weight: 300;
    display: block;
    transform: translateY(100%);
    transition: transform 0.8s var(--ease-out-expo);
}

.nav-overlay.is-active .nav-menu ul li a {
    transform: translateY(0);
}

/* Nav Toggle Active State */
.nav-toggle.is-active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.is-active span:nth-child(2) {
    transform: translateY(-7px) rotate(-45deg);
}

.nav-toggle span {
    transition: all 0.3s ease;
}

/* Category Filter UI */
.filter-nav {
    position: sticky;
    top: 100px;
    /* Aligned with header height */
    background-color: transparent;
    padding: 20px 0;
    margin: 0;
    margin-bottom: var(--gap-m);
    display: flex;
    gap: var(--gap-m);
    flex-wrap: wrap;
    z-index: 900;
    transition: background-color 0.4s var(--ease-out-expo), padding 0.4s var(--ease-out-expo);
}

.filter-nav.is-sticky {
    background-color: rgba(255, 255, 255, 0.4);
    /* Reduced opacity for a lighter feel */
    backdrop-filter: blur(20px) saturate(180%);
    /* Enhanced blur and saturation */
    padding: 15px var(--gap-m);
    margin-left: calc(var(--gap-m) * -1);
    margin-right: calc(var(--gap-m) * -1);
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    /* Extremely subtle border */
}

@media (max-width: 768px) {
    .filter-nav {
        top: 70px;
        padding: 10px 0;
    }

    .filter-nav.is-sticky {
        padding: 10px var(--gap-m);
    }
}

.filter-btn {
    font-size: 0.875rem;
    font-weight: 500;
    opacity: 0.4;
    transition: opacity 0.3s;
}

.filter-btn.is-active {
    opacity: 1;
    border-bottom: 1px solid var(--accent);
}