/* ============================================
   INFINITY PORTFOLIO - Minimal Design System
   ============================================ */

:root {
    --bg: #fafafa;
    --text: #1a1a1a;
    --muted: #888;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    font-size: 18px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

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

a:hover {
    opacity: 0.6;
}

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

/* ============================================
   Header
   ============================================ */

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 24px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    mix-blend-mode: difference;
}

.logo {
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #fff;
}

.back-link {
    font-size: 14px;
    color: #fff;
}

/* ============================================
   Hero Sections (Homepage)
   ============================================ */

.hero-section {
    min-height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-image {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 8s ease-out;
}

.hero-section:hover .hero-image img {
    transform: scale(1.03);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.1) 0%,
        rgba(0, 0, 0, 0.3) 100%
    );
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    text-align: center;
    color: #fff;
    padding: 40px;
}

.hero-content h2 {
    font-size: clamp(36px, 8vw, 72px);
    font-weight: 300;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.hero-content .meta {
    font-size: 14px;
    letter-spacing: 0.1em;
    opacity: 0.8;
    margin-bottom: 32px;
}

.view-link {
    display: inline-block;
    font-size: 14px;
    letter-spacing: 0.1em;
    color: #fff;
    padding: 12px 32px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    transition: all var(--transition);
}

.view-link:hover {
    background: #fff;
    color: var(--text);
    opacity: 1;
}

/* ============================================
   About Section
   ============================================ */

.about-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 120px 40px;
    text-align: center;
}

.about-section h2 {
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 48px;
    color: var(--muted);
}

.about-section p {
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 300;
    line-height: 1.5;
    max-width: 800px;
}

/* ============================================
   Project Detail Page
   ============================================ */

.project-hero {
    height: 70vh;
    position: relative;
    overflow: hidden;
}

.project-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-info {
    max-width: 800px;
    margin: 0 auto;
    padding: 80px 40px;
}

.project-info h1 {
    font-size: clamp(32px, 6vw, 56px);
    font-weight: 300;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.project-info .meta {
    font-size: 14px;
    color: var(--muted);
    letter-spacing: 0.05em;
    margin-bottom: 48px;
}

.project-info .description {
    font-size: 18px;
    line-height: 1.8;
    max-width: 65ch;
}

.project-info .description p {
    margin-bottom: 24px;
}

/* ============================================
   Gallery Grid
   ============================================ */

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    padding: 0 40px 120px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Gallery Item */
.gallery-item {
    position: relative;
    overflow: hidden;
}

.gallery-item a {
    display: block;
}

.gallery-item a:hover {
    opacity: 1;
}

.gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform var(--transition);
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-item .item-number {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 4px;
    opacity: 0;
    transition: opacity var(--transition);
}

.gallery-item:hover .item-number {
    opacity: 1;
}

/* Lightbox link */
.glightbox-clean .gslide-description {
    background: transparent;
}

.glightbox-clean .gdesc-inner {
    padding: 12px 0;
    text-align: center;
}

.lightbox-link {
    display: inline-block;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    text-decoration: none;
    transition: color 0.2s;
}

.lightbox-link:hover {
    color: #fff;
    opacity: 1;
}

/* ============================================
   Collection Link
   ============================================ */

.collection-link {
    text-align: center;
    padding: 80px 40px 120px;
}

.collection-link a {
    display: inline-block;
    font-size: 14px;
    letter-spacing: 0.1em;
    padding: 16px 48px;
    border: 1px solid var(--text);
    transition: all var(--transition);
}

.collection-link a:hover {
    background: var(--text);
    color: var(--bg);
    opacity: 1;
}

/* ============================================
   Scroll Reveal Animation
   ============================================ */

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

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

/* Staggered children */
.reveal-children > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal-children.visible > *:nth-child(1) { transition-delay: 0.1s; opacity: 1; transform: translateY(0); }
.reveal-children.visible > *:nth-child(2) { transition-delay: 0.2s; opacity: 1; transform: translateY(0); }
.reveal-children.visible > *:nth-child(3) { transition-delay: 0.3s; opacity: 1; transform: translateY(0); }
.reveal-children.visible > *:nth-child(4) { transition-delay: 0.4s; opacity: 1; transform: translateY(0); }

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 768px) {
    .header {
        padding: 20px 24px;
    }

    .hero-content h2 {
        letter-spacing: 0.1em;
    }

    .about-section {
        padding: 80px 24px;
    }

    .project-info {
        padding: 60px 24px;
    }

    .gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        padding: 0 24px 80px;
    }

    .collection-link {
        padding: 60px 24px 80px;
    }
}

@media (max-width: 480px) {
    .gallery {
        grid-template-columns: 1fr;
    }
}
