/*
Theme Name: Best Bali Travel
Theme URI: https://bestbalitravel.com
Author: Best Bali Travel Team
Author URI: https://bestbalitravel.com
Description: A professional tour booking WordPress theme for Best Bali Travel. Features tour listings, booking system, multi-language support, and WooCommerce integration.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bestbalitravel
Tags: tour-booking, travel, woocommerce, custom-menu, featured-images, translation-ready

Best Bali Travel Theme - Mobile Navigation Styles
*/

/* ========================================
   CSS CUSTOM PROPERTIES
   ======================================== */
:root {
    --mobile-nav-height: 64px;
    --mobile-nav-safe-area: env(safe-area-inset-bottom, 0px);
    --mobile-nav-bg: rgba(255, 255, 255, 0.98);
    --mobile-nav-border: rgba(0, 0, 0, 0.08);
    --mobile-nav-active: #f5a623;
    --mobile-nav-inactive: #6b7280;
}

/* ========================================
   MOBILE BOTTOM NAVIGATION BAR
   ======================================== */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(var(--mobile-nav-height) + var(--mobile-nav-safe-area));
    padding-bottom: var(--mobile-nav-safe-area);
    background: var(--mobile-nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--mobile-nav-border);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    display: none;
}

/* Show only on mobile */
@media (max-width: 768px) {
    .mobile-bottom-nav {
        display: block;
    }

    /* Add padding to body for bottom nav */
    body {
        padding-bottom: calc(var(--mobile-nav-height) + var(--mobile-nav-safe-area));
    }

    /* Hide WhatsApp float when bottom nav is visible */
    .whatsapp-float {
        bottom: calc(var(--mobile-nav-height) + var(--mobile-nav-safe-area) + 16px);
    }
}

/* Navigation Items Container */
.mobile-bottom-nav-inner {
    display: flex;
    align-items: stretch;
    justify-content: space-around;
    height: var(--mobile-nav-height);
    padding: 0 8px;
}

/* Individual Nav Item */
.mobile-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 4px;
    text-decoration: none;
    color: var(--mobile-nav-inactive);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    -webkit-tap-highlight-color: transparent;
}

/* Icon Container */
.mobile-nav-icon {
    position: relative;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-nav-icon svg {
    width: 24px;
    height: 24px;
    transition: all 0.3s;
}

/* Label */
.mobile-nav-label {
    font-family: 'Plus Jakarta Sans', -apple-system, sans-serif;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.02em;
    white-space: nowrap;
    transition: all 0.3s;
}

/* Active State */
.mobile-nav-item.active,
.mobile-nav-item[aria-current="page"] {
    color: var(--mobile-nav-active);
}

.mobile-nav-item.active .mobile-nav-icon,
.mobile-nav-item[aria-current="page"] .mobile-nav-icon {
    transform: scale(1.1);
}

.mobile-nav-item.active .mobile-nav-label,
.mobile-nav-item[aria-current="page"] .mobile-nav-label {
    font-weight: 600;
}

/* Active Indicator Dot */
.mobile-nav-item.active::after,
.mobile-nav-item[aria-current="page"]::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    background: var(--mobile-nav-active);
    border-radius: 50%;
    animation: navDotPulse 2s ease-in-out infinite;
}

@keyframes navDotPulse {

    0%,
    100% {
        transform: translateX(-50%) scale(1);
        opacity: 1;
    }

    50% {
        transform: translateX(-50%) scale(1.5);
        opacity: 0.6;
    }
}

/* Hover/Touch State */
.mobile-nav-item:active {
    background: rgba(245, 166, 35, 0.1);
    transform: scale(0.95);
}

/* Badge for Cart/Notifications */
.mobile-nav-badge {
    position: absolute;
    top: -2px;
    right: -4px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    background: #ef4444;
    color: white;
    font-size: 10px;
    font-weight: 700;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: badgeBounce 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes badgeBounce {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.3);
    }

    100% {
        transform: scale(1);
    }
}

/* ========================================
   CENTER ACTION BUTTON (Book Now)
   ======================================== */
.mobile-nav-item.nav-action {
    position: relative;
}

.mobile-nav-item.nav-action .mobile-nav-icon {
    width: 52px;
    height: 52px;
    margin-top: -24px;
    background: linear-gradient(135deg, #f5a623 0%, #e69316 100%);
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(245, 166, 35, 0.4);
    transition: all 0.3s;
}

.mobile-nav-item.nav-action .mobile-nav-icon svg {
    color: white;
    width: 26px;
    height: 26px;
}

.mobile-nav-item.nav-action:active .mobile-nav-icon {
    transform: scale(0.9);
    box-shadow: 0 2px 10px rgba(245, 166, 35, 0.3);
}

.mobile-nav-item.nav-action .mobile-nav-label {
    color: var(--mobile-nav-active);
    font-weight: 600;
}

/* Ripple effect on action button */
.mobile-nav-item.nav-action .mobile-nav-icon::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: rgba(245, 166, 35, 0.2);
    animation: actionRipple 2s ease-out infinite;
}

@keyframes actionRipple {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }

    100% {
        transform: scale(1.4);
        opacity: 0;
    }
}

/* ========================================
   MOBILE HEADER ADJUSTMENTS
   ======================================== */
@media (max-width: 768px) {

    /* Compact header on mobile */
    .site-header .header-wrapper {
        padding: 8px 0;
    }

    /* Hide desktop nav items */
    .header-actions .language-selector,
    .header-actions .currency-selector {
        display: none;
    }

    /* Smaller logo */
    .site-branding img {
        height: 32px;
    }

    .site-logo-text {
        font-size: 1rem;
    }
}

/* ========================================
   MOBILE SEARCH BAR (App Style)
   ======================================== */
.mobile-search-bar {
    display: none;
    padding: 8px 16px 12px;
    background: white;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

@media (max-width: 768px) {
    .mobile-search-bar {
        display: block;
    }
}

.mobile-search-bar form {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    background: #f5f5f5;
    border-radius: 12px;
    transition: all 0.3s;
}

.mobile-search-bar form:focus-within {
    background: white;
    box-shadow: 0 0 0 2px var(--mobile-nav-active);
}

.mobile-search-bar input {
    flex: 1;
    border: none;
    background: transparent;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 14px;
    outline: none;
}

.mobile-search-bar input::placeholder {
    color: #9ca3af;
}

.mobile-search-bar button {
    padding: 0;
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
}

/* ========================================
   CATEGORY TABS (Horizontal Scroll)
   ======================================== */
.category-tabs {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
}

.category-tabs::-webkit-scrollbar {
    display: none;
}

.category-tab {
    flex: 0 0 auto;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 12px 16px;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    text-decoration: none;
    color: #374151;
    transition: all 0.3s;
    min-width: 80px;
}

.category-tab:active {
    transform: scale(0.95);
}

.category-tab.active {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #f5a623;
    color: #92400e;
}

.category-tab-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    border-radius: 50%;
    font-size: 20px;
    transition: all 0.3s;
}

.category-tab.active .category-tab-icon {
    background: linear-gradient(135deg, #f5a623, #e69316);
    color: white;
}

.category-tab-label {
    font-size: 11px;
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
}

/* ========================================
   FILTER CHIPS (Quick Filters)
   ======================================== */
.filter-chips {
    display: flex;
    gap: 8px;
    padding: 8px 16px;
    overflow-x: auto;
    scrollbar-width: none;
}

.filter-chips::-webkit-scrollbar {
    display: none;
}

.filter-chip {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 13px;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.filter-chip:active {
    transform: scale(0.95);
}

.filter-chip.active {
    background: var(--mobile-nav-active);
    border-color: var(--mobile-nav-active);
    color: white;
}

.filter-chip svg {
    width: 14px;
    height: 14px;
}

/* ========================================
   MOBILE FILTER BOTTOM SHEET
   ======================================== */
.filter-sheet-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 1100;
}

.filter-sheet-overlay.active {
    opacity: 1;
    visibility: visible;
}

.filter-sheet {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: 85vh;
    background: white;
    border-radius: 20px 20px 0 0;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.32, 0.72, 0, 1);
    z-index: 1101;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.filter-sheet.active {
    transform: translateY(0);
}

/* Sheet Handle */
.filter-sheet-handle {
    padding: 12px 0 8px;
    text-align: center;
}

.filter-sheet-handle::before {
    content: '';
    display: inline-block;
    width: 40px;
    height: 4px;
    background: #d1d5db;
    border-radius: 2px;
}

/* Sheet Header */
.filter-sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 20px 16px;
    border-bottom: 1px solid #f3f4f6;
}

.filter-sheet-title {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #111827;
}

.filter-sheet-close {
    padding: 8px;
    background: #f3f4f6;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.2s;
}

.filter-sheet-close:active {
    background: #e5e7eb;
}

/* Sheet Content */
.filter-sheet-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

/* Sheet Footer */
.filter-sheet-footer {
    padding: 16px 20px;
    padding-bottom: calc(16px + var(--mobile-nav-safe-area));
    background: white;
    border-top: 1px solid #f3f4f6;
    display: flex;
    gap: 12px;
}

.filter-sheet-btn {
    flex: 1;
    padding: 14px 20px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 14px;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-sheet-btn.secondary {
    background: #f3f4f6;
    border: none;
    color: #374151;
}

.filter-sheet-btn.primary {
    background: linear-gradient(135deg, #f5a623, #e69316);
    border: none;
    color: white;
    box-shadow: 0 4px 15px rgba(245, 166, 35, 0.3);
}

.filter-sheet-btn:active {
    transform: scale(0.98);
}

/* ========================================
   TOUR CARD MOBILE OPTIMIZATIONS
   ======================================== */
@media (max-width: 768px) {
    .bbt-tours-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 0 16px;
    }

    /* Card as horizontal layout on mobile */
    .tour-card {
        display: flex;
        flex-direction: row;
        border-radius: 16px;
        overflow: hidden;
        background: white;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    }

    .tour-card-image {
        width: 120px;
        min-height: 120px;
        flex-shrink: 0;
    }

    .tour-card-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .tour-card-content {
        flex: 1;
        padding: 12px;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }

    .tour-card-title {
        font-size: 14px;
        font-weight: 600;
        line-height: 1.3;
        margin-bottom: 4px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .tour-card-location {
        font-size: 12px;
        color: #6b7280;
    }

    .tour-card-price {
        font-size: 16px;
        font-weight: 700;
        color: #f5a623;
    }

    .tour-card-rating {
        display: flex;
        align-items: center;
        gap: 4px;
        font-size: 12px;
        color: #f59e0b;
    }
}

/* ========================================
   PAGE HEADER MOBILE STYLE
   ======================================== */
@media (max-width: 768px) {
    .bbt-page-header {
        padding: 100px 16px 24px;
        background: linear-gradient(135deg, #f5a623 0%, #10b981 100%);
    }

    .bbt-page-title {
        font-size: 24px;
        color: white;
        text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    }

    .bbt-breadcrumbs {
        display: none;
    }
}

/* ========================================
   SKELETON LOADING STATES
   ======================================== */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.5s infinite;
    border-radius: 8px;
}

@keyframes skeletonShimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

.skeleton-card {
    height: 120px;
    margin-bottom: 16px;
}

.skeleton-text {
    height: 14px;
    margin-bottom: 8px;
}

.skeleton-text.short {
    width: 60%;
}