/* ============================================
   MOBILE-FIRST OPTIMIZED DESIGN
   Belgrade Tourism Platform - Phone Optimized
   ============================================ */

/* ============================================
   MOBILE-FIRST BASE (Start with mobile, scale up)
   ============================================ */

/* Touch-friendly targets */
* {
    -webkit-tap-highlight-color: rgba(184, 134, 11, 0.3);
    -webkit-touch-callout: none;
}

/* Smooth scrolling for mobile */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Prevent horizontal scroll on mobile */
body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

/* ============================================
   MOBILE NAVIGATION - BOTTOM NAV BAR
   ============================================ */
.mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(30, 58, 138, 0.98) 0%, rgba(30, 58, 138, 1) 100%);
    backdrop-filter: blur(20px);
    padding: 0.5rem 0;
    z-index: 1000;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.7rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.mobile-nav-item i {
    font-size: 1.3rem;
    margin-bottom: 0.25rem;
    transition: all 0.3s ease;
}

.mobile-nav-item.active {
    color: #ffd700;
}

.mobile-nav-item.active i {
    transform: scale(1.2);
}

.mobile-nav-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: #ffd700;
    transition: width 0.3s ease;
}

.mobile-nav-item.active::before {
    width: 60%;
}

/* Hide on desktop */
@media (min-width: 768px) {
    .mobile-bottom-nav {
        display: none;
    }
}

/* ============================================
   ENHANCED HERO SECTION - MOBILE OPTIMIZED
   ============================================ */
.hero {
    min-height: 100vh;
    min-height: -webkit-fill-available;
    padding-bottom: 80px; /* Space for bottom nav */
}

/* Better image optimization for mobile */
.hero__slide {
    background-size: cover;
    background-position: center;
    will-change: transform, opacity;
}

/* Faster animations on mobile */
@media (max-width: 767px) {
    .hero__slide {
        animation: mobileKenburns 15s ease-in-out infinite;
    }
    
    @keyframes mobileKenburns {
        0%, 100% {
            transform: scale(1);
        }
        50% {
            transform: scale(1.1);
        }
    }
}

/* Mobile hero content adjustments */
@media (max-width: 767px) {
    .hero__title {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    .hero__description {
        font-size: 0.95rem;
        line-height: 1.6;
    }
    
    .hero__buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .hero__buttons .btn {
        width: 100%;
        justify-content: center;
    }
    
    .hero__stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
}

/* ============================================
   TOUCH-FRIENDLY BUTTONS & INTERACTIONS
   ============================================ */
.btn,
.filter-pill,
.place-card,
.category__card {
    min-height: 48px; /* iOS recommended touch target */
    touch-action: manipulation;
}

/* Better touch feedback */
.btn:active,
.filter-pill:active {
    transform: scale(0.95);
}

/* ============================================
   MOBILE-OPTIMIZED CARDS
   ============================================ */
@media (max-width: 767px) {
    .place-card {
        margin-bottom: 1.5rem;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }
    
    .place-card__image {
        height: 200px;
    }
    
    .place-card__content {
        padding: 1rem;
    }
    
    .place-card__title {
        font-size: 1.25rem;
    }
}

/* ============================================
   SWIPEABLE CATEGORIES (Mobile)
   ============================================ */
@media (max-width: 767px) {
    .categories__grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        padding: 0 1rem 1rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    .categories__grid::-webkit-scrollbar {
        display: none;
    }
    
    .category__card {
        min-width: 280px;
        scroll-snap-align: center;
    }
}

/* ============================================
   FLOATING ACTION BUTTON (Mobile)
   ============================================ */
.mobile-fab {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #b8860b, #ffd700);
    color: white;
    border: none;
    box-shadow: 0 8px 24px rgba(184, 134, 11, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    z-index: 999;
    animation: fabPulse 2s ease-in-out infinite;
    cursor: pointer;
}

@keyframes fabPulse {
    0%, 100% {
        box-shadow: 0 8px 24px rgba(184, 134, 11, 0.4);
    }
    50% {
        box-shadow: 0 8px 32px rgba(184, 134, 11, 0.6);
        transform: scale(1.05);
    }
}

/* Hide FAB on desktop */
@media (min-width: 768px) {
    .mobile-fab {
        display: none;
    }
}

/* ============================================
   QUICK ACCESS PANEL (Mobile)
   ============================================ */
.quick-access-panel {
    position: fixed;
    bottom: 70px;
    right: 20px;
    background: white;
    border-radius: 1rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    padding: 1rem;
    transform: scale(0) translateY(20px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 998;
    max-width: 250px;
}

.quick-access-panel.active {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.quick-access-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    text-decoration: none;
    color: #1e3a8a;
    font-weight: 500;
    transition: all 0.2s;
}

.quick-access-item:last-child {
    margin-bottom: 0;
}

.quick-access-item:active {
    background: #f3f4f6;
    transform: scale(0.95);
}

.quick-access-item i {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1e3a8a, #b8860b);
    color: white;
    border-radius: 0.5rem;
    font-size: 0.9rem;
}

/* ============================================
   MOBILE SEARCH BAR - STICKY
   ============================================ */
@media (max-width: 767px) {
    .mobile-search-sticky {
        position: sticky;
        top: 80px;
        z-index: 90;
        background: white;
        padding: 1rem;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }
    
    .search-box {
        margin: 0;
    }
}

/* ============================================
   SCROLL ANIMATIONS - MOBILE OPTIMIZED
   ============================================ */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delay for multiple items */
.scroll-reveal:nth-child(1) { transition-delay: 0.1s; }
.scroll-reveal:nth-child(2) { transition-delay: 0.2s; }
.scroll-reveal:nth-child(3) { transition-delay: 0.3s; }
.scroll-reveal:nth-child(4) { transition-delay: 0.4s; }

/* ============================================
   LOGO PLACEMENTS - MOBILE OPTIMIZED
   ============================================ */
.mobile-logo-footer {
    text-align: center;
    padding: 2rem 0;
}

.mobile-logo-footer img {
    max-width: 150px;
    height: auto;
    opacity: 0.9;
}

.logo-watermark {
    position: fixed;
    bottom: 85px;
    left: 10px;
    opacity: 0.15;
    pointer-events: none;
    z-index: 1;
}

.logo-watermark img {
    width: 60px;
    height: auto;
}

/* ============================================
   BELGRADE-THEMED DECORATIVE ELEMENTS
   ============================================ */
.belgrade-pattern {
    background-image: 
        repeating-linear-gradient(45deg, transparent, transparent 35px, rgba(184, 134, 11, 0.03) 35px, rgba(184, 134, 11, 0.03) 70px);
}

.belgrade-accent {
    position: relative;
}

.belgrade-accent::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #1e3a8a, #b8860b);
    border-radius: 2px;
}

/* ============================================
   QUICK INFO CARDS (Mobile)
   ============================================ */
.quick-info-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    padding: 1rem;
    margin-bottom: 80px; /* Bottom nav space */
}

.quick-info-card {
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
    color: white;
    padding: 1.25rem;
    border-radius: 1rem;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.2);
    transition: all 0.3s ease;
}

.quick-info-card:active {
    transform: scale(0.95);
}

.quick-info-card i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: block;
    color: #ffd700;
}

.quick-info-card h4 {
    font-size: 0.9rem;
    margin: 0;
    font-weight: 600;
}

/* ============================================
   PERFORMANCE OPTIMIZATIONS
   ============================================ */

/* Lazy load images */
img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.3s;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================================
   MOBILE TYPOGRAPHY IMPROVEMENTS
   ============================================ */
@media (max-width: 767px) {
    h1 {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    h2 {
        font-size: 1.75rem;
        line-height: 1.3;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    p {
        font-size: 0.95rem;
        line-height: 1.6;
    }
    
    .section__title {
        font-size: 1.75rem;
    }
    
    .section__description {
        font-size: 0.95rem;
    }
}

/* ============================================
   MOBILE SPACING IMPROVEMENTS
   ============================================ */
@media (max-width: 767px) {
    .section {
        padding: 3rem 0;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    .section__header {
        margin-bottom: 2rem;
    }
}

/* ============================================
   BELGRADE TOURIST INFO SECTION
   ============================================ */
.tourist-info-bar {
    background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
    padding: 1.5rem;
    border-radius: 1rem;
    margin: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.tourist-info-items {
    display: flex;
    overflow-x: auto;
    gap: 1rem;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.tourist-info-items::-webkit-scrollbar {
    display: none;
}

.tourist-info-item {
    flex-shrink: 0;
    scroll-snap-align: start;
    background: white;
    padding: 1rem;
    border-radius: 0.75rem;
    min-width: 140px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.tourist-info-item i {
    font-size: 2rem;
    color: #b8860b;
    margin-bottom: 0.5rem;
    display: block;
}

.tourist-info-item h5 {
    font-size: 0.85rem;
    color: #1e3a8a;
    margin: 0 0 0.25rem 0;
    font-weight: 600;
}

.tourist-info-item p {
    font-size: 0.75rem;
    color: #6b7280;
    margin: 0;
}

/* ============================================
   SWIPE INDICATORS
   ============================================ */
.swipe-indicator {
    text-align: center;
    padding: 0.5rem 0;
    color: #6b7280;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.swipe-indicator i {
    animation: swipeHint 2s ease-in-out infinite;
}

@keyframes swipeHint {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(10px);
    }
}

/* ============================================
   LOADING STATES
   ============================================ */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   MICRO-INTERACTIONS
   ============================================ */
.bounce-on-tap:active {
    animation: bounceScale 0.3s ease;
}

@keyframes bounceScale {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(0.95);
    }
}

.ripple {
    position: relative;
    overflow: hidden;
}

.ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.ripple:active::after {
    width: 200px;
    height: 200px;
}

/* ============================================
   PULL TO REFRESH INDICATOR (Optional)
   ============================================ */
.pull-to-refresh {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    background: white;
    padding: 1rem 2rem;
    border-radius: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    opacity: 0;
    transition: all 0.3s ease;
}

.pull-to-refresh.active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* ============================================
   RESPONSIVE BREAKPOINTS
   ============================================ */

/* Small phones (320px - 480px) */
@media (max-width: 480px) {
    .hero__title {
        font-size: 1.75rem;
    }
    
    .quick-info-cards {
        grid-template-columns: 1fr;
    }
    
    .mobile-nav-item {
        font-size: 0.65rem;
    }
    
    .mobile-nav-item i {
        font-size: 1.1rem;
    }
}

/* Medium phones (481px - 767px) */
@media (min-width: 481px) and (max-width: 767px) {
    .quick-info-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablets (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
    .hero__title {
        font-size: 3rem;
    }
    
    .quick-info-cards {
        grid-template-columns: repeat(4, 1fr);
    }
}

