/* =========================================================
   NOOKS COFFEE & EATERY
   GALLERY PAGE
   MODERN EMERALD GREEN THEME
========================================================= */

/* =========================================================
   RESET & ROOT
========================================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --green: #0d2b24;       /* Deep Emerald Mewah */
    --green-2: #164238;     /* Medium Emerald */
    --green-3: #2b6857;
    --accent-gold: #c5a059; /* Sentuhan aksen emas premium */
    --sage: #d6e2d9;
    --sage-light: #e9f0eb;
    --cream: #f9f7f2;       /* Cream mewah lembut */
    --white: #ffffff;
    --ink: #141c19;
    --muted: #626f68;
    --line: #d2dbd5;
    --radius: 16px;
    --luxury-shadow: 0 20px 40px rgba(13, 43, 36, 0.08);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "DM Sans", sans-serif;
    color: var(--ink);
    background: var(--cream);
    line-height: 1.7;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
}

/* =========================================================
   HEADER & NAVIGATION
========================================================= */
.site-header {
    width: min(1200px, 92%);
    margin: 0 auto;
    min-height: 90px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(13, 43, 36, 0.06);
    border-radius: 0 0 24px 24px;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo-img {
    width: 140px;
    height: 52px;
    object-fit: contain;
    display: block;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 36px;
}

.desktop-nav a {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .1em;
    color: var(--green);
    position: relative;
    transition: color 0.3s;
}

.desktop-nav a:hover {
    color: var(--green-2);
}

.desktop-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 0;
    height: 2px;
    background: var(--accent-gold);
    transition: width .3s cubic-bezier(0.4, 0, 0.2, 1);
}

.desktop-nav a:hover::after,
.desktop-nav a.active::after {
    width: 100%;
}

.desktop-nav a.active {
    color: var(--green);
}

.menu-toggle {
    display: none;
    width: 40px;
    height: 40px;
    padding: 5px;
    border: none;
    background: transparent;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    margin: 6px auto;
    background: var(--green);
    transition: 0.3s ease;
}

/* =========================================================
   MOBILE MENU
========================================================= */
.mobile-menu {
    display: none;
}

/* =========================================================
   GALLERY HEADING
========================================================= */
.gallery-heading {
    width: min(850px, 90%);
    margin: 0 auto;
    padding: 75px 0 35px;
    text-align: center;
}

.eyebrow {
    color: var(--green-2);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.gallery-heading h1 {
    font-family: "Playfair Display", serif;
    color: var(--green);
    font-size: clamp(45px, 6vw, 70px);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.gallery-description {
    max-width: 600px;
    margin: 20px auto 0;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.8;
}

/* =========================================================
   GALLERY FILTER
========================================================= */
.gallery-filter {
    width: min(1100px, 90%);
    margin: 0 auto;
    padding: 15px 0 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.filter-btn {
    border: 1px solid var(--line);
    padding: 12px 24px;
    border-radius: 50px;
    background: var(--white);
    color: var(--green);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: var(--sage);
    border-color: var(--green-2);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: var(--green);
    color: var(--white);
    border-color: var(--green);
    box-shadow: 0 8px 20px rgba(13, 43, 36, 0.15);
}

.filter-btn.active:hover {
    background: var(--green-2);
    color: var(--white);
}

/* =========================================================
   GALLERY GRID & ITEMS
========================================================= */
.gallery-grid {
    width: min(1100px, 90%);
    margin: 0 auto;
    padding-bottom: 30px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.view-more-container {
    margin-bottom: 60px;
    text-align: center;
}

.view-more-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 4px;
    border-bottom: 2px solid #123c32;
    color: #123c32;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.5px;
    transition: opacity 0.3s;
}

.view-more-link:hover {
    opacity: 0.7;
}

.view-more-link span {
    font-size: 15px;
    line-height: 1;
}

.gallery-empty {
    grid-column: 1 / -1;
    color: var(--muted);
    text-align: center;
}

.gallery-item {
    height: 360px;
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--sage);
    position: relative;
    box-shadow: 0 10px 30px rgba(13, 43, 36, 0.05);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.4s ease;
}

.gallery-item.hidden {
    display: none;
}

.gallery-item.show {
    display: block;
    animation: galleryFade 0.4s ease;
}

@keyframes galleryFade {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.gallery-image-trigger {
    position: absolute;
    inset: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: zoom-in;
}

.gallery-image-trigger:focus-visible {
    outline: 3px solid var(--accent-gold);
    outline-offset: -4px;
}

.gallery-image-trigger img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.gallery-item:hover {
    transform: translateY(-6px);
    box-shadow: var(--luxury-shadow);
}

.gallery-item:hover .gallery-image-trigger img {
    transform: scale(1.07);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    padding: 25px;
    background: linear-gradient(transparent 45%, rgba(13, 43, 36, 0.85));
    opacity: 1;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.gallery-overlay span {
    position: relative;
    z-index: 2;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(13, 43, 36, 0.82);
    color: var(--white);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
}

.gallery-lightbox {
    position: fixed;
    width: min(92vw, 1100px);
    max-width: none;
    max-height: 92vh;
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 12px;
    background: #101815;
    color: var(--white);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

.gallery-lightbox::backdrop {
    background: rgba(0, 0, 0, 0.84);
    backdrop-filter: blur(4px);
}

.lightbox-image {
    display: block;
    width: 100%;
    max-height: 80vh;
    object-fit: contain;
    background: #080c0a;
}

.lightbox-title {
    padding: 16px 20px 18px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
}

.lightbox-close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.65);
    border-radius: 50%;
    background: rgba(13, 43, 36, 0.82);
    color: var(--white);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

/* =========================================================
   FOOTER
========================================================= */
footer {
    min-height: 90px;
    padding: 30px 6%;
    background: #071713;
    color: rgba(255, 255, 255, 0.75);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    font-size: 11px;
    letter-spacing: .05em;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    font-weight: 800;
}

.brand-mark {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: var(--white);
    color: var(--green);
    display: grid;
    place-items: center;
    font-family: "Playfair Display", serif;
    font-size: 18px;
}

.footer-social {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-social a {
    width: 38px;
    height: 38px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 15px;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    background: var(--white);
    color: var(--green);
    border-color: var(--white);
    transform: scale(1.1);
}

/* =========================================================
   RESPONSIVE / TABLET & MOBILE
========================================================= */
@media (max-width: 850px) {
    .desktop-nav { 
        display: none; 
    }
    
    .menu-toggle { 
        display: block; 
    }

    .site-header {
        width: 94%;
        min-height: 78px;
        padding: 0 20px;
        border-radius: 0 0 18px 18px;
    }

    .logo-img {
        width: 125px;
        height: 50px;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        width: 92%;
    }

    .gallery-item {
        height: 300px;
    }

    footer {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 520px) {
    .site-header {
        width: 94%;
        min-height: 72px;
        padding: 0 16px;
        border-radius: 0 0 16px 16px;
    }

    .logo-img {
        width: 115px;
        height: 48px;
    }

    .gallery-heading {
        padding: 60px 0 25px;
    }

    .gallery-heading h1 {
        font-size: 38px;
    }

    .gallery-description {
        font-size: 14px;
    }

    .gallery-filter {
        width: 92%;
        padding-bottom: 35px;
        gap: 8px;
    }

    .filter-btn {
        padding: 10px 18px;
        font-size: 10px;
    }

    .gallery-grid {
        width: 92%;
        grid-template-columns: 1fr;
        gap: 20px;
        padding-bottom: 25px;
    }

    .gallery-item {
        height: 320px;
    }

    .gallery-lightbox {
        width: calc(100vw - 24px);
        max-height: 90vh;
    }

    .lightbox-image {
        max-height: 76vh;
    }

    footer {
        padding: 30px 20px;
        flex-direction: column;
        gap: 15px;
    }
}