/* ========================================
   SEÑOR TACO - 2026 Mobile-First CSS
   Add this to the END of style.min.css
======================================== */

/* ===== MOBILE-FIRST BASE ===== */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Safe Area for Notched Devices (iPhone, etc.) */
body {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
}

/* ===== TOUCH OPTIMIZATION ===== */
/* Minimum 44x44px touch targets (Apple HIG / Material Design) */
@media (max-width: 991px) {
    a, button, .btn, .nav-link {
        min-height: 44px;
        min-width: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Larger tap targets for mobile */
    .btn {
        padding: 14px 28px;
        font-size: 16px;
    }
}

/* ===== MOBILE BOTTOM NAVIGATION (2026 Standard) ===== */
.mobile-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 -2px 20px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    padding: 8px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

@media (max-width: 991px) {
    .mobile-nav {
        display: flex;
        justify-content: space-around;
        align-items: center;
    }
    
    body {
        padding-bottom: 80px;
    }
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px 8px;
    text-decoration: none !important;
    color: #666;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex: 1;
    position: relative;
    max-width: 90px;
}

.mobile-nav-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: var(--bg-color3);
    transition: width 0.3s ease;
}

.mobile-nav-item.active::before {
    width: 40px;
}

.mobile-nav-item:hover,
.mobile-nav-item:focus,
.mobile-nav-item.active {
    color: var(--bg-color3);
    text-decoration: none !important;
}

.mobile-nav-item i {
    font-size: 22px;
    margin-bottom: 4px;
    transition: transform 0.3s ease;
}

.mobile-nav-item.active i {
    transform: scale(1.1);
}

.mobile-nav-item span {
    font-size: 11px;
    font-weight: 600;
    font-family: var(--font-alt);
}

/* ===== STICKY HEADER ENHANCEMENTS ===== */
.top-menu {
    transition: all 0.3s ease;
}

.top-menu.scrolled {
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* ===== IMPROVED HERO CAROUSEL ===== */
@media (max-width: 767px) {
    .carousel-inner {
        min-height: 500px;
    }
    
    .carousel-item > div {
        min-height: 500px !important;
        padding: 60px 20px;
    }
    
    .carousel-caption h1,
    .delaySliderContent h1 {
        font-size: 2rem !important;
    }
    
    .carousel-caption p,
    .delaySliderContent p {
        font-size: 1rem !important;
    }
    
    .carousel-caption .btn,
    .delaySliderContent .btn {
        font-size: 14px !important;
        padding: 12px 24px !important;
    }
}

/* ===== CARDS & SERVICES - MOBILE OPTIMIZED ===== */
@media (max-width: 767px) {
    .card {
        margin-bottom: 24px;
    }
    
    .services-home .service,
    .hvr-shutter-in-horizontal {
        margin-bottom: 20px;
    }
}

/* Touch-friendly card interactions */
.card,
.hvr-shutter-in-horizontal {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (hover: none) and (pointer: coarse) {
    /* For touch devices */
    .card:active,
    .hvr-shutter-in-horizontal:active {
        transform: scale(0.98);
    }
}

/* ===== IMPROVED FORMS - MOBILE FIRST ===== */
@media (max-width: 767px) {
    .form-control {
        font-size: 16px !important; /* Prevents zoom on iOS */
        padding: 14px 16px !important;
        border-radius: 12px !important;
    }
    
    select.form-control {
        font-size: 16px !important;
    }
    
    textarea.form-control {
        min-height: 120px;
    }
}

/* ===== NAVIGATION IMPROVEMENTS ===== */
@media (max-width: 991px) {
    .navbar-collapse {
        background: white;
        padding: 20px;
        border-radius: 12px;
        margin-top: 15px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    }
    
    .navbar-nav .nav-item {
        margin: 8px 0;
    }
    
    .navbar-nav .nav-link {
        padding: 12px 16px !important;
        border-radius: 8px;
        transition: all 0.3s ease;
    }
    
    .navbar-nav .nav-link:hover,
    .navbar-nav .nav-link:active {
        background: rgba(224, 0, 6, 0.05);
        color: var(--bg-color3) !important;
    }
    
    .dropdown-menu {
        border: none !important;
        box-shadow: none !important;
        background: rgba(224, 0, 6, 0.05) !important;
        margin-top: 8px !important;
    }
}

/* ===== FOOTER - 2026 UPDATE ===== */
.footer {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    position: relative;
    overflow: hidden;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(178, 212, 26, 0.5), transparent);
}

.copyright-2026 {
    font-size: 14px;
    opacity: 0.9;
    font-family: var(--font-regular);
}

@media (max-width: 767px) {
    .footer .col-lg-4,
    .footer .col-lg-2,
    .footer .col-lg-3,
    .footer .col-md-6 {
        margin-bottom: 30px;
        text-align: center;
    }
    
    .footer h3,
    .footer h4,
    .footer h5 {
        margin-top: 20px;
    }
}

/* ===== BACK TO TOP BUTTON - ENHANCED ===== */
.go-up {
    position: fixed;
    bottom: 90px; /* Above mobile nav */
    right: 20px;
    width: 50px;
    height: 50px;
    background: var(--bg-color3);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(224, 0, 6, 0.3);
    transition: all 0.3s ease;
    z-index: 999;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.go-up:not(.hide-top) {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.go-up::before {
    content: '↑';
    font-size: 24px;
    font-weight: bold;
    color: white;
}

.go-up:hover {
    background: var(--bg-color4);
    box-shadow: 0 6px 25px rgba(0, 50, 162, 0.4);
    transform: translateY(-5px);
}

@media (max-width: 991px) {
    .go-up {
        bottom: 90px;
        right: 15px;
        width: 45px;
        height: 45px;
    }
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
/* Lazy loading placeholder */
img[loading="lazy"] {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

img[loading="lazy"].loaded {
    animation: none;
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===== IMPROVED TYPOGRAPHY FOR MOBILE ===== */
@media (max-width: 767px) {
    h1, .h1 { font-size: 2rem !important; }
    h2, .h2 { font-size: 1.75rem !important; }
    h3, .h3 { font-size: 1.5rem !important; }
    h4, .h4 { font-size: 1.25rem !important; }
    h5, .h5 { font-size: 1.1rem !important; }
    h6, .h6 { font-size: 1rem !important; }
    
    .display-1 { font-size: 3.5rem !important; }
    .display-2 { font-size: 3rem !important; }
    .display-3 { font-size: 2.5rem !important; }
    .display-4 { font-size: 2rem !important; }
    
    p, .lead {
        font-size: 16px !important;
        line-height: 1.6;
    }
}

/* ===== GLASSMORPHISM EFFECTS (2026 Trend) ===== */
.glass-card {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* ===== SMOOTH SCROLL BEHAVIOR ===== */
html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* ===== SECTION SPACING - MOBILE OPTIMIZED ===== */
@media (max-width: 767px) {
    section {
        padding: 40px 0 !important;
    }
    
    .py-5 {
        padding-top: 40px !important;
        padding-bottom: 40px !important;
    }
    
    .container {
        padding-left: 20px;
        padding-right: 20px;
    }
}

/* ===== IMPROVED SHADOWS - 2026 DEPTH ===== */
.shadow-sm {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

.shadow {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12) !important;
}

.shadow-lg {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15) !important;
}

/* ===== HOVER STATES FOR TOUCH DEVICES ===== */
@media (hover: hover) and (pointer: fine) {
    /* Desktop hover states */
    .btn:hover {
        transform: translateY(-2px);
    }
    
    .card:hover {
        transform: translateY(-4px);
    }
}

/* ===== FOCUS STATES FOR ACCESSIBILITY ===== */
a:focus,
button:focus,
.btn:focus {
    outline: 3px solid var(--bg-color2);
    outline-offset: 2px;
}

/* ===== LOADING SPINNER (for dynamic content) ===== */
.loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(224, 0, 6, 0.1);
    border-top-color: var(--bg-color3);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== IMPROVED CAROUSEL CONTROLS - MOBILE ===== */
@media (max-width: 767px) {
    .carousel-control-prev,
    .carousel-control-next {
        width: 40px;
    }
    
    .carousel-control-prev-icon,
    .carousel-control-next-icon {
        width: 30px;
        height: 30px;
        background-size: 30px 30px;
    }
    
    .carousel-indicators {
        bottom: 20px;
    }
    
    .carousel-indicators li {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        margin: 0 4px;
    }
}

/* ===== SOCIAL MEDIA ICONS - ENHANCED ===== */
.footer .fab {
    transition: all 0.3s ease;
}

.footer a:hover .fab {
    transform: scale(1.2) rotate(5deg);
}

/* ===== UTILITY CLASSES - 2026 ===== */
.text-gradient {
    background: linear-gradient(135deg, var(--bg-color3), var(--bg-color4));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient-primary {
    background: linear-gradient(135deg, var(--bg-color3) 0%, var(--bg-color4) 100%) !important;
}

.bg-gradient-secondary {
    background: linear-gradient(135deg, var(--bg-color1) 0%, var(--bg-color2) 100%) !important;
}

/* ===== PRINT STYLES ===== */
@media print {
    .mobile-nav,
    .go-up,
    .navbar,
    .carousel-control-prev,
    .carousel-control-next,
    .carousel-indicators {
        display: none !important;
    }
}

/* ===== DARK MODE SUPPORT (Future Ready) ===== */
@media (prefers-color-scheme: dark) {
    /* Add dark mode styles here if needed in future */
}

/* ===== END OF MOBILE-FIRST 2026 CSS ===== */