:root {
    --bg: #0f0f14;
    --panel: #181821;
    --accent: #e48ab6;
    --text: #f2f2f7;
    --muted: #9da3b4;
    --mutedaccent: #8c6176;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: radial-gradient(1200px 800px at 50% -200px, #1a1a25 0%, var(--bg) 60%);
    color: var(--text);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
}

/* Header */

header {
    text-align: center;
    padding: 4rem 1rem 2.5rem;
}

    header h1 {
        margin: 0;
        font-weight: 750;
        font-size: 2.2rem;
        letter-spacing: 0.05em;
    }

.subtitle {
    margin-top: 0.75rem;
    color: var(--muted);
    font-size: 1rem;
}

.subtitle2 {
    margin-top: 0.75rem;
    color: var(--mutedaccent);
    font-size: 1.5rem;
}

.divider {
    width: 500px;
    height: 2px;
    margin: 1rem auto 0;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    border-radius: 2px;
}

/* Gallery */

.gallery {
    max-width: 90%;
    margin: auto;
    perspective: 1200px;
}

/* Masonry sizing */

.grid-sizer,
.card {
    width: 20%;
    max-width: 400px;
    padding: 8px;
}

.card.dimmed {
    opacity: 0.15;
    filter: blur(4px);
    transition: opacity 0.4s ease, filter 0.4s ease;
}

@media (max-width: 1200px) {
    .grid-sizer,
    .card {
        width: 33.333%;
    }
}

@media (max-width: 800px) {
    .grid-sizer,
    .card {
        width: 50%;
    }
}

@media (max-width: 500px) {
    .grid-sizer,
    .card {
        width: 100%;
    }
}

.card-inner {
    background: var(--panel);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.45), 0 0 0 1px rgba(255,255,255,0.03);
    transition: transform 0.35s cubic-bezier(.2,.8,.2,1);
}

    .card-inner:hover {
        transform: translateY(-6px);
    }

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

/* Lightbox */

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.9);
    backdrop-filter: blur(20px);
    opacity: 0;
    z-index: 1500;
}

    .lightbox img {
        max-width: 90vw;
        max-height: 90vh;
        border-radius: 14px;
    }

.close-btn {
    position: fixed;
    top: 28px;
    right: 32px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(10px);
    color: white;
    font-size: 20px;
    cursor: pointer;
    z-index: 2500;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, background 0.3s ease, opacity 0.3s ease;
}

    .close-btn:hover {
        background: rgba(255,255,255,0.18);
        transform: scale(1.15);
    }

.hidden {
    display: none;
}

.loader {
    position: fixed;
    inset: 0;
    background: rgba(10, 10, 20, 0.85);
    backdrop-filter: blur(30px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5000;
    transition: opacity 0.6s ease;
}

    .loader.hidden {
        opacity: 0;
        pointer-events: none;
    }

.loader-content {
    text-align: center;
    color: white;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
    opacity: 0.9;
}

/* Spinner */
.spinner {
    width: 46px;
    height: 46px;
    margin: 0 auto 20px;
    border-radius: 50%;
    border: 3px solid rgba(255,255,255,0.15);
    border-top: 3px solid #e48ab6;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}
