/* ===== Custom Styles for Kern's Kafe ===== */

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

body {
    overflow-x: hidden;
}

/* ===== Scroll Reveal ===== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal[data-reveal="delay-1"] { transition-delay: 0.1s; }
.reveal[data-reveal="delay-2"] { transition-delay: 0.2s; }
.reveal[data-reveal="delay-3"] { transition-delay: 0.3s; }

/* When JS is disabled, all content is visible (progressive enhancement) */
.no-js .reveal {
    opacity: 1 !important;
    transform: none !important;
}

/* ===== Floating Cards Animation ===== */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(1) { animation-delay: 0s; }
.floating-card:nth-child(2) { animation-delay: -1.5s; }
.floating-card:nth-child(3) { animation-delay: -3s; }
.floating-card:nth-child(4) { animation-delay: -4.5s; }

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

/* ===== Menu Tabs ===== */
.menu-tab {
    color: #94a3b8;
    background: transparent;
    border: none;
    cursor: pointer;
}

.menu-tab.active {
    color: #f8fafc;
    background: #0d9488;
    box-shadow: 0 4px 15px rgba(13, 148, 136, 0.3);
}

.menu-tab:not(.active):hover {
    color: #fbbf24;
    background: rgba(251, 191, 36, 0.08);
}

.menu-content {
    animation: fadeIn 0.4s ease forwards;
}

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

/* ===== Navbar Scrolled State ===== */
.nav-scrolled {
    background: rgba(2, 6, 23, 0.92) !important;
    backdrop-filter: blur(20px) !important;
    border-bottom: 1px solid rgba(100, 200, 180, 0.08) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3) !important;
}

/* ===== Selection ===== */
::selection {
    background: rgba(13, 148, 136, 0.3);
    color: #f8fafc;
}

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

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

::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #334155;
}

/* ===== Focus Styles ===== */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
    outline: 2px solid #14b8a6;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
    .floating-card {
        display: none;
    }
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}
