/* ========================================
   CUSTOM STYLES - GurmeClickPos
   Modern, minimal custom CSS
   Tailwind-first approach - Only styles that can't be done with Tailwind
   ======================================== */

/* ========================================
   1. ACCESSIBILITY
   ======================================== */

/* Skip Navigation Links - WCAG 2.1 AA Compliance */
.skip-navigation {
    position: relative;
    z-index: 9999;
}

.skip-link {
    position: absolute;
    top: -100px;
    left: 8px;
    background: #4088F5;
    color: white !important;
    padding: 12px 16px;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: top 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.skip-link:focus {
    top: 8px;
    outline: 3px solid rgba(255, 255, 255, 0.8);
    outline-offset: 2px;
}

.skip-link:hover {
    background: #3175F1;
    transform: scale(1.05);
}

/* Main content focus styles for skip navigation */
#main-content:focus {
    outline: none;
}

/* ========================================
   2. GLASS MORPHISM UTILITY
   ======================================== */

.glass-morphism {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

@supports not (backdrop-filter: blur(20px)) {
    .glass-morphism {
        background: rgba(255, 255, 255, 0.98);
    }
}

/* Dark mode glass morphism */
.dark .glass-morphism {
    background: rgba(17, 24, 39, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* ========================================
   3. HAMBURGER MENU ANIMATION
   ======================================== */

.hamburger-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    cursor: pointer;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hamburger-menu:hover {
    background: rgba(64, 136, 245, 0.1);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    border-color: rgba(64, 136, 245, 0.3);
}

.hamburger-menu:hover .hamburger-icon span {
    background-color: #2563eb !important;
}

.hamburger-menu:active {
    transform: scale(0.95);
}

.hamburger-menu:active .hamburger-icon {
    transform: scale(0.9);
}

.hamburger-icon {
    width: 24px;
    height: 18px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease;
}

.hamburger-icon span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #4088F5 !important;
    border-radius: 2px;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    transform-origin: center;
    margin-bottom: 4px;
    will-change: transform, opacity;
}

.hamburger-icon span:nth-child(1) {
    width: 100%;
}

.hamburger-icon span:nth-child(2) {
    width: 80%;
    margin-left: auto;
}

.hamburger-icon span:nth-child(3) {
    width: 60%;
    margin-left: auto;
    margin-bottom: 0;
}

/* Hamburger Animation - Open State */
.hamburger-icon.open {
    animation: pulse 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.hamburger-icon.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 7px);
    width: 100%;
    margin-bottom: 0;
}

.hamburger-icon.open span:nth-child(2) {
    opacity: 0;
    transform: scale(0) rotate(180deg);
    margin-bottom: 0;
}

.hamburger-icon.open span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -7px);
    width: 100%;
    margin-left: 0;
    margin-bottom: 0;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.15);
    }
    100% {
        transform: scale(1);
    }
}

/* Dark mode hamburger */
.dark .hamburger-menu {
    background: rgba(31, 41, 55, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.dark .hamburger-menu:hover {
    background: rgba(59, 130, 246, 0.15);
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
    .hamburger-menu {
        width: 40px;
        height: 40px;
        min-width: 40px;
        flex-shrink: 0;
    }

    .hamburger-icon {
        width: 20px;
        height: 16px;
    }
}

@media (max-width: 767px) {
    .hamburger-menu {
        width: 36px;
        height: 36px;
        min-width: 36px;
        margin-right: 8px;
    }

    .hamburger-icon {
        width: 18px;
        height: 14px;
    }

    .hamburger-icon span {
        height: 2px;
        margin-bottom: 3px;
    }

    .hamburger-icon span:last-child {
        margin-bottom: 0;
    }

    .hamburger-icon.open span:nth-child(1) {
        transform: rotate(45deg) translate(0, 6px);
    }

    .hamburger-icon.open span:nth-child(3) {
        transform: rotate(-45deg) translate(0, -6px);
    }
}

/* ========================================
   4. REDUCED MOTION SUPPORT
   ======================================== */

@media (prefers-reduced-motion: reduce) {
    .hamburger-menu,
    .hamburger-icon,
    .hamburger-icon span,
    .skip-link {
        animation: none !important;
        transition: none !important;
    }
}
