/* ============================================ */
/* ESTILOS BASE */
/* ============================================ */

:root {
    --primary: #1e40af;
    --bg: #f8fafc;
    --text: #1e293b;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    margin: 0;
    color: var(--text);
}

.logo {
    font-size: 22px;
    font-weight: 900;
    color: var(--primary);
    text-decoration: none;
}

.nav-links a {
    text-decoration: none;
    color: #64748b;
    margin-left: 20px;
    font-weight: 600;
}

/* Layout: Filtros + Grid */
.main-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
    max-width: 1300px;
    margin: 40px auto;
    padding: 0 20px;
}

.sidebar {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    height: fit-content;
}

.sidebar h3 {
    margin-top: 0;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 10px;
    font-size: 18px;
}

/* Tarjetas */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    transition: 0.3s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card-body {
    padding: 20px;
}

.card-price {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary);
}

.card-specs {
    display: flex;
    gap: 15px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #f1f5f9;
    font-size: 14px;
}

/* Pestañas */
.tab-btn {
    transition: all 0.3s ease;
    cursor: pointer;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    background: transparent;
    border: none;
    color: #64748b;
    border-radius: 0.5rem 0.5rem 0 0;
}

.tab-btn:hover {
    color: #1e40af;
    background: #f1f5f9;
}

.tab-btn.active {
    color: #1e40af;
    background: white;
    border-bottom: 3px solid #1e40af;
}

.tab-pane {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================ */
/* HERO SLIDER RESPONSIVE */
/* ============================================ */

.hero-slider-container {
    height: 500px;
    min-height: 300px;
    position: relative;
    width: 100%;
    overflow: hidden;
}

.hero-slider-track {
    display: flex;
    transition: transform 0.5s ease-out;
    height: 100%;
}

.hero-slide {
    flex-shrink: 0;
    width: 100%;
    height: 100%;
    position: relative;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content-overlay {
    position: relative;
    z-index: 10;
    height: 500px;
    margin-top: -500px;
}

/* Imagen sola */
.hero-single-container {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
}

.hero-single-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-single-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    padding: 0 20px;
}

/* Botones del slider */
.hero-slider-btn {
    cursor: pointer;
    z-index: 20;
    transition: all 0.3s ease;
}

.hero-slider-dots {
    z-index: 20;
}

.hero-slider-dot {
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 1rem;
    background-color: #f3f4f6;
}

.slider-track {
    display: flex;
    transition: transform 0.4s ease-in-out;
}

.slider-slide {
    flex-shrink: 0;
    width: 100%;
}

.slider-slide img {
    width: 100%;
    height: 450px;
    object-fit: cover;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
}

.slider-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(1.05);
}

.slider-btn-prev {
    left: 20px;
}
.slider-btn-next {
    right: 20px;
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    padding: 0;
}

.slider-dot.active {
    width: 25px;
    border-radius: 5px;
    background: white;
}

/* ============================================ */
/* RESPONSIVE MEDIA QUERIES */
/* ============================================ */

/* Desktop grande */
@media (min-width: 1280px) {
    .hero-slider-container {
        height: 600px;
    }
    .hero-content-overlay {
        height: 600px;
        margin-top: -600px;
    }
    .hero-single-container {
        height: 600px;
    }
}

/* Tablet */
@media (max-width: 768px) {
    .hero-slider-container {
        height: 400px;
    }
    .hero-content-overlay {
        height: 400px;
        margin-top: -400px;
    }
    .hero-single-container {
        height: 400px;
    }
    .tab-btn {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }
    .slider-btn {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    .slider-slide img {
        height: 300px;
    }
    .hero-content-overlay h1 {
        font-size: 2rem;
    }
    .hero-content-overlay p {
        font-size: 1rem;
    }
}

/* Móvil */
@media (max-width: 480px) {
    .hero-slider-container {
        height: 300px;
    }
    .hero-content-overlay {
        height: 300px;
        margin-top: -300px;
    }
    .hero-single-container {
        height: 300px;
    }
    .grid {
        gap: 12px !important;
    }
    .card img {
        height: 150px;
    }
    .card-body {
        padding: 10px;
    }
    .card-price {
        font-size: 16px;
    }
    .tab-btn {
        padding: 0.25rem 0.75rem;
        font-size: 0.7rem;
    }
    .slider-btn {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
    .hero-content-overlay h1 {
        font-size: 1.3rem;
    }
    .hero-content-overlay p {
        font-size: 0.8rem;
    }
    .hero-slider-btn {
        width: 25px !important;
        height: 25px !important;
        font-size: 10px !important;
    }
}
