/* ================================================================
   TRANSPORTES PINEDA - NAVBAR PREMIUM V2.0
   Diseño moderno y profesional para sistema de rentacar
   ================================================================ */

/* ================================================================
   VARIABLES CSS - FÁCIL PERSONALIZACIÓN
   ================================================================ */
:root {
    --primary-color: #1e40af;
    --primary-hover: #1e3a8a;
    --secondary-color: #3b82f6;
    --accent-color: #f59e0b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --dark: #1f2937;
    --light: #f9fafb;
    --white: #ffffff;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --navbar-height: 80px;
}

/* ================================================================
   RESET Y BASE
   ================================================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ================================================================
   NAVBAR PRINCIPAL
   ================================================================ */

/* ================================================================
   CONTAINER
   ================================================================ */


/* ================================================================
   LOGO
   ================================================================ */
.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
    transition: var(--transition);
    user-select: none;
}

.logo:hover {
    transform: translateY(-2px);
}

.logo img {
    height: 50px;
    width: 50px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.logo:hover img {
    box-shadow: var(--shadow-md);
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.navbar.scrolled .logo img {
    height: 40px;
    width: 40px;
}

.navbar.scrolled .logo-text {
    font-size: 1.3rem;
}

/* ================================================================
   NAVEGACIÓN DESKTOP
   ================================================================ */
.nav-links {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
}

.nav-links > li {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    color: var(--dark);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 12px;
    transition: var(--transition);
    position: relative;
}





/* Efecto de línea inferior animada */
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 60%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
    transition: transform 0.3s ease;
}

.nav-link.active::after,
.nav-link:hover::after {
    transform: translateX(-50%) scaleX(1);
}

/* ================================================================
   DROPDOWN ADMINISTRADOR
   ================================================================ */
.nav-dropdown {
    position: relative;
}

.nav-dropdown .nav-link {
    cursor: pointer;
}

.dropdown-arrow {
    font-size: 0.7rem;
    transition: transform 0.3s ease;
    margin-left: 0.3rem;
}

.nav-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

.admin-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    background: linear-gradient(135deg, var(--accent-color), #f97316);
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    border-radius: 6px;
    margin-left: 0.5rem;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
}

/* Contenido del dropdown */
.dropdown-content {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    min-width: 280px;
    background: white;
    border-radius: 16px;
    box-shadow: var(--shadow-xl);
    padding: 0.75rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-dropdown:hover .dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    color: var(--dark);
    text-decoration: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
    margin-bottom: 0.25rem;
}

.dropdown-item:last-child {
    margin-bottom: 0;
}

.dropdown-item:hover {
    background: rgba(30, 64, 175, 0.08);
    color: var(--primary-color);
    transform: translateX(5px);
}

.dropdown-item.active {
    background: rgba(30, 64, 175, 0.12);
    color: var(--primary-color);
    font-weight: 600;
}

/* Indicador de item activo */
.nav-dropdown.has-active .nav-link {
    color: var(--primary-color);
    background: rgba(30, 64, 175, 0.08);
}

/* ================================================================
   CARRITO
   ================================================================ */



@keyframes cartPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* ================================================================
   BOTÓN RESERVAR
   ================================================================ */
.book-btn {
    padding: 0.85rem 1.75rem !important;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
    color: white !important;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3);
    position: relative;
    overflow: hidden;
}

.book-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.book-btn:hover::before {
    left: 100%;
}

.book-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(30, 64, 175, 0.4);
}

.book-btn:active {
    transform: translateY(-1px);
}

/* ================================================================
   HAMBURGER MENU - MÓVIL
   ================================================================ */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 32px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.hamburger span {
    display: block;
    height: 3px;
    width: 100%;
    background: white;
    border-radius: 3px;
    transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

/* ================================================================
   MENÚ MÓVIL
   ================================================================ */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #000000 0%, #000000 100%);
    z-index: 999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-100%);
    transition: var(--transition);
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* Pattern decorativo */
.mobile-menu::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.mobile-nav-links {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: relative;
    z-index: 2;
}

.mobile-nav-links li {
    transform: translateX(-50px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu.active .mobile-nav-links li {
    transform: translateX(0);
    opacity: 1;
}

/* Animación escalonada */
.mobile-menu.active .mobile-nav-links li:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu.active .mobile-nav-links li:nth-child(2) { transition-delay: 0.15s; }
.mobile-menu.active .mobile-nav-links li:nth-child(3) { transition-delay: 0.2s; }
.mobile-menu.active .mobile-nav-links li:nth-child(4) { transition-delay: 0.25s; }
.mobile-menu.active .mobile-nav-links li:nth-child(5) { transition-delay: 0.3s; }
.mobile-menu.active .mobile-nav-links li:nth-child(6) { transition-delay: 0.35s; }
.mobile-menu.active .mobile-nav-links li:nth-child(7) { transition-delay: 0.4s; }

.mobile-nav-links a {
    display: block;
    padding: 1.2rem 1.5rem;
    color: white !important;
    text-decoration: none;
    font-size: 1.15rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: var(--transition);
}

.mobile-nav-links a:hover,
.mobile-nav-links a.active {
    background: rgba(255, 255, 255, 0.25);
    transform: translateX(10px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Dropdown móvil */
.mobile-nav-links .nav-dropdown .nav-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.mobile-nav-links .nav-dropdown .dropdown-content {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    margin-top: 0.75rem;
    padding: 0;
    background: transparent;
    box-shadow: none;
    border: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.mobile-nav-links .nav-dropdown.mobile-active .dropdown-content {
    max-height: 500px;
}

.mobile-nav-links .dropdown-item {
    padding: 1rem 1.5rem;
    margin-bottom: 0.5rem;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.mobile-nav-links .dropdown-item:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateX(5px);
}

/* Carrito móvil */
.mobile-cart-icon {
    padding: 1.2rem 1.5rem;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;
    color: white;
    font-size: 1.15rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.mobile-cart-icon:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.05);
}

/* Botón reservar móvil */
.mobile-book-btn {
    padding: 1.3rem 2rem !important;
    background: white !important;
    color: var(--primary-color) !important;
    font-weight: 700;
    font-size: 1.1rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 14px;
    text-align: center;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    border: none;
}

.mobile-book-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

/* ================================================================
   OVERLAY
   ================================================================ */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 1024px) {
    .nav-container {
        padding: 0 1.5rem;
    }
    
    .nav-links {
        gap: 0.3rem;
    }
    
    .nav-link {
        padding: 0.65rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none !important;
    }
    
    .hamburger {
        display: flex;
    }
    
    .nav-container {
        padding: 0 1rem;
    }
    
    .logo img {
        height: 40px;
        width: 40px;
    }
    
    .logo-text {
        font-size: 1.2rem;
    }
    
    .navbar {
        height: 65px;
    }
    
    .navbar.scrolled {
        height: 60px;
    }
}

@media (max-width: 480px) {
    .logo-text {
        font-size: 1rem;
    }
    
    .logo img {
        height: 35px;
        width: 35px;
    }
    
    .mobile-nav-links {
        max-width: 100%;
    }
    
    .mobile-nav-links a {
        font-size: 1rem;
        padding: 1rem 1.25rem;
    }
}