/* ===== Espresso Gallery — Custom Styles ===== */

/* --- Base --- */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: rgba(103, 197, 167, 0.3);
    color: #0A1F3F;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0A1F3F;
}
::-webkit-scrollbar-thumb {
    background: #45B791;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #67C5A7;
}

/* --- Reveal Animations (progressive enhancement) --- */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    .reveal.delay-1 { transition-delay: 0.1s; }
    .reveal.delay-2 { transition-delay: 0.2s; }
    .reveal.delay-3 { transition-delay: 0.3s; }
}

/* --- Navbar --- */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #8DD3BD;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: #8DD3BD;
}

/* --- Mobile Menu Transitions --- */
#mobile-menu {
    transition: opacity 0.4s ease, pointer-events 0.4s ease;
}

#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

.mobile-nav-link {
    position: relative;
}

.mobile-nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background-color: #8DD3BD;
    transition: width 0.3s ease;
}

.mobile-nav-link:hover::after {
    width: 100%;
}

/* --- Buttons --- */
a {
    text-decoration: none;
}

/* --- Image Loading --- */
img {
    display: block;
    max-width: 100%;
}

/* --- Focus Styles --- */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #67C5A7;
    outline-offset: 2px;
    border-radius: 2px;
}

/* --- Hero Parallax (subtle) --- */
@media (prefers-reduced-motion: no-preference) {
    #hero img {
        will-change: transform;
    }
}

/* --- Print --- */
@media print {
    nav, #back-to-top, #mobile-menu {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    section {
        page-break-inside: avoid;
    }
}
