/* ============================================
   Addley's Coffee — Custom Styles
   ============================================ */

/* Scroll-behavior */
html {
    scroll-behavior: smooth;
}

/* Navbar */
#navbar {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

#navbar.scrolled #nav-logo-text {
    color: #134e4a;
}

#navbar.scrolled .nav-link {
    color: #475569;
}

#navbar.scrolled .nav-link:hover {
    color: #0d9488;
}

/* Hero */
#hero {
    background: linear-gradient(135deg, #042f2e 0%, #134e4a 40%, #0f766e 100%);
}

/* Reveal animations (progressive enhancement) */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.js-scroll .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.js-scroll .reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered reveal delays */
.js-scroll .reveal:nth-child(1) { transition-delay: 0.05s; }
.js-scroll .reveal:nth-child(2) { transition-delay: 0.12s; }
.js-scroll .reveal:nth-child(3) { transition-delay: 0.19s; }
.js-scroll .reveal:nth-child(4) { transition-delay: 0.26s; }
.js-scroll .reveal:nth-child(5) { transition-delay: 0.33s; }

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

/* Gallery hover */
#gallery img {
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

#gallery img:hover {
    transform: scale(1.05);
}

/* Smooth focus */
a:focus-visible, button:focus-visible {
    outline: 2px solid #2dd4bf;
    outline-offset: 3px;
    border-radius: 4px;
}

/* Selection */
::selection {
    background: #99f6e4;
    color: #042f2e;
}

/* Form reset for contact form */
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 0.75rem;
    font-family: inherit;
    font-size: 0.9375rem;
    color: #1e293b;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    resize: none;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #14b8a6;
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.15);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #94a3b8;
}

/* Success message */
.form-success {
    display: none;
    text-align: center;
    padding: 2rem;
}

.form-success.show {
    display: block;
    animation: fadeInUp 0.4s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    #gallery img,
    .group img {
        transition: none;
    }
    .animate-bounce {
        animation: none;
    }
    .animate-pulse {
        animation: none;
    }
}
