/* ========== VARIABLES Y RESET ========== */
:root {
    --primary: #00f0ff;
    --primary-dark: #00b8c4;
    --secondary: #ff00ea;
    --accent: #7b2dff;
    --dark: #0a0a1a;
    --dark-light: #12122a;
    --dark-card: #1a1a3a;
    --text: #e0e0ff;
    --text-muted: #8888aa;
    --gradient-1: linear-gradient(135deg, #00f0ff, #7b2dff);
    --gradient-2: linear-gradient(135deg, #ff00ea, #00f0ff);
    --glow-cyan: 0 0 20px rgba(0, 240, 255, 0.5);
    --glow-purple: 0 0 20px rgba(123, 45, 255, 0.5);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--dark);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Fondo animado */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 20% 20%, rgba(123, 45, 255, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(0, 240, 255, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(255, 0, 234, 0.05) 0%, transparent 70%);
    z-index: -1;
    animation: bgPulse 8s ease-in-out infinite;
}

@keyframes bgPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ========== HEADER ========== */
header {
    background: rgba(10, 10, 26, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 240, 255, 0.2);
    box-shadow: 0 4px 30px rgba(0, 240, 255, 0.1);
}

header h1 {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-transform: uppercase;
    letter-spacing: 3px;
    text-align: center;
    margin-bottom: 1rem;
    text-shadow: var(--glow-cyan);
    animation: titleGlow 2s ease-in-out infinite;
}

@keyframes titleGlow {
    0%, 100% { filter: drop-shadow(0 0 10px rgba(0, 240, 255, 0.5)); }
    50% { filter: drop-shadow(0 0 25px rgba(0, 240, 255, 0.8)); }
}

nav ul {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    list-style: none;
    flex-wrap: wrap;
}

nav ul li a {
    color: var(--text);
    text-decoration: none;
    padding: 0.7rem 1.5rem;
    border-radius: 50px;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    border: 1px solid transparent;
}

nav ul li a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--gradient-1);
    transition: left 0.3s ease;
    z-index: -1;
    opacity: 0.2;
}

nav ul li a:hover {
    border-color: var(--primary);
    box-shadow: var(--glow-cyan);
    transform: translateY(-2px);
}

nav ul li a:hover::before {
    left: 0;
}

/* ========== HR PERSONALIZADO ========== */
hr {
    border: none;
    height: 2px;
    background: var(--gradient-1);
    margin: 0;
    opacity: 0.5;
}

/* ========== MAIN ========== */
main {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

main > h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

main > h2::after {
    content: '';
    display: block;
    width: 100px;
    height: 4px;
    background: var(--gradient-1);
    margin: 1rem auto 0;
    border-radius: 2px;
}

/* ========== PRODUCTOS ========== */
center {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    justify-items: center;
}

.producto-destacado {
    background: var(--dark-card);
    border-radius: 20px;
    padding: 1.5rem;
    width: 100%;
    max-width: 350px;
    border: 1px solid rgba(0, 240, 255, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.producto-destacado::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(
        from 0deg,
        transparent,
        var(--primary),
        transparent,
        var(--secondary),
        transparent
    );
    animation: rotateBorder 4s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.producto-destacado::after {
    content: '';
    position: absolute;
    inset: 2px;
    background: var(--dark-card);
    border-radius: 18px;
    z-index: 0;
}

.producto-destacado > * {
    position: relative;
    z-index: 1;
}

@keyframes rotateBorder {
    100% { transform: rotate(360deg); }
}

.producto-destacado:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 
        0 20px 40px rgba(0, 240, 255, 0.2),
        0 0 60px rgba(123, 45, 255, 0.1);
}

.producto-destacado:hover::before {
    opacity: 1;
}

.producto-destacado h3 {
    font-size: 1.4rem;
    color: var(--primary);
    margin-bottom: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.producto-destacado p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.producto-destacado img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    border: 2px solid rgba(0, 240, 255, 0.2);
}

.producto-destacado:hover img {
    border-color: var(--primary);
    box-shadow: var(--glow-cyan);
}

.precio {
    font-size: 1.5rem !important;
    font-weight: 700;
    color: var(--secondary) !important;
    margin: 1rem 0 !important;
}

/* ========== BOTONES ========== */
button {
    width: 100%;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    background: var(--gradient-1);
    color: var(--dark);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.4),
        transparent
    );
    transition: left 0.5s ease;
}

button:hover {
    transform: scale(1.05);
    box-shadow: var(--glow-cyan), var(--glow-purple);
}

button:hover::before {
    left: 100%;
}

button:active {
    transform: scale(0.98);
}

/* ========== FOOTER ========== */
footer {
    background: var(--dark-light);
    padding: 2rem;
    text-align: center;
    border-top: 1px solid rgba(0, 240, 255, 0.2);
    margin-top: 2rem;
}

footer p {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

footer a {
    color: var(--primary);
    text-decoration: none;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
    border-radius: 5px;
}

footer a:hover {
    color: var(--secondary);
    text-shadow: 0 0 10px var(--secondary);
}

/* ========== SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--dark);
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-1);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    header h1 {
        font-size: 1.5rem;
        letter-spacing: 1px;
    }

    nav ul {
        gap: 0.3rem;
    }

    nav ul li a {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }

    main > h2 {
        font-size: 1.8rem;
    }

    .producto-destacado {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    header {
        padding: 1rem;
    }

    nav ul li a {
        padding: 0.4rem 0.8rem;
        font-size: 0.75rem;
    }

    main {
        padding: 2rem 1rem;
    }

    button {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

}