/* ===== Custom Styles for Dewster's ===== */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* ===== Hero Animations ===== */
.hero-subtitle {
    animation: fadeUp 0.8s ease forwards 0.2s;
}

.hero-title {
    animation: fadeUp 0.8s ease forwards 0.4s;
}

.hero-desc {
    animation: fadeUp 0.8s ease forwards 0.6s;
}

.hero-ctas {
    animation: fadeUp 0.8s ease forwards 0.8s;
}

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

/* ===== Scroll Reveal ===== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

.reveal:nth-child(2) { transition-delay: 0.1s; }
.reveal:nth-child(3) { transition-delay: 0.2s; }
.reveal:nth-child(4) { transition-delay: 0.3s; }
.reveal:nth-child(5) { transition-delay: 0.4s; }

/* ===== Menu Card Hover ===== */
.menu-card {
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}

.menu-card:hover {
    transform: translateY(-4px);
}

/* ===== Gallery Item ===== */
.gallery-item {
    cursor: pointer;
}

.gallery-item img {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ===== Navigation ===== */
#navbar {
    backdrop-filter: blur(0px);
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(13, 13, 13, 0.9);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, #ff6b4a, #e8c46a);
    transition: width 0.3s ease, left 0.3s ease;
}

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

.nav-link:hover {
    color: #ff6b4a !important;
}

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

#mobile-menu.open .mobile-link {
    animation: mobileLinkIn 0.4s ease forwards;
}

#mobile-menu.open .mobile-link:nth-child(1) { animation-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(2) { animation-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(3) { animation-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(4) { animation-delay: 0.25s; }
#mobile-menu.open .mobile-link:nth-child(5) { animation-delay: 0.3s; }

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

/* Menu button active state */
#menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-toggle.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 1.5rem;
}

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #0d0d0d;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #ff6b4a, #e8c46a);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #ff7f5f, #f0d48a);
}

/* ===== Selection Color ===== */
::selection {
    background: rgba(255, 107, 74, 0.3);
    color: #fff;
}

/* ===== Focus Styles ===== */
input:focus, textarea:focus {
    outline: none;
}

/* ===== Subtle grain texture overlay ===== */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.015;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px 256px;
}
