/**
 * TiendaVenta 2.0 - Estilos Personalizados
 * Archivo: assets/css/style.css
 */

/* =============================================
   VARIABLES CSS (Design Tokens)
   ============================================= */
:root {
    /* Colores principales - Basados en Logo TiendaVenta */
    --primary: #2563eb;
    /* Azul del logo */
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #10b981;
    --accent: #f59e0b;
    /* Naranja/Amarillo del logo */
    --accent-dark: #d97706;

    /* Colores neutros */
    --dark: #0f172a;
    --dark-light: #1e3a5f;
    --gray-900: #111827;
    --gray-800: #1f2937;
    --gray-700: #374151;
    --gray-600: #4b5563;
    --gray-400: #9ca3af;
    --gray-300: #d1d5db;
    --gray-100: #f3f4f6;
    --white: #ffffff;

    /* Estados */
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #2563eb;

    /* Gradientes - Armonizados con el logo */
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    --gradient-dark: linear-gradient(135deg, #0f172a 0%, #1e3a5f 100%);
    --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1e3a5f 50%, #2563eb 100%);
    --gradient-accent: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);

    /* Sombras */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.3);

    /* Bordes */
    --radius-sm: 0.375rem;
    --radius: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;

    /* Transiciones */
    --transition: all 0.3s ease;
    --transition-fast: all 0.15s ease;
}

/* =============================================
   BASE STYLES
   ============================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--gray-100);
    color: var(--gray-800);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* =============================================
   NAVBAR
   ============================================= */
.bg-gradient-primary {
    background: var(--gradient-dark) !important;
    box-shadow: var(--shadow-lg);
}

.navbar {
    padding: 1rem 0;
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(90deg, var(--white), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: var(--radius);
    transition: var(--transition);
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
}

.dropdown-menu-dark {
    background: var(--gray-900);
    border: 1px solid var(--gray-700);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
}

.dropdown-item:hover {
    background: var(--primary);
}

/* =============================================
   HERO SECTION
   ============================================= */
.hero-section {
    background: var(--gradient-hero);
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%239C92AC' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    color: var(--white);
    margin-bottom: 1.5rem;
}

.hero-title span {
    background: linear-gradient(90deg, var(--accent), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--gray-300);
    margin-bottom: 2rem;
    max-width: 500px;
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-lg);
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.5);
    background: var(--primary-dark);
}

.btn-success {
    background: var(--secondary);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
}

.btn-outline-light {
    border: 2px solid var(--white);
    color: var(--white);
}

.btn-outline-light:hover {
    background: var(--white);
    color: var(--dark);
    transform: translateY(-2px);
}

.btn-whatsapp {
    background: #25D366;
    color: white;
}

.btn-whatsapp:hover {
    background: #128C7E;
    color: white;
    transform: translateY(-2px);
}

/* =============================================
   CARDS
   ============================================= */
.card {
    background: var(--white);
    border: none;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.product-card {
    height: 100%;
}

.product-card .card-img-top {
    height: 200px;
    object-fit: cover;
    background: linear-gradient(135deg, var(--gray-100), var(--gray-200));
}

.product-card .card-body {
    padding: 1.5rem;
}

.product-card .card-title {
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.product-card .card-text {
    color: var(--gray-600);
    font-size: 0.9rem;
}

.price-tag {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
}

.price-tag.free {
    color: var(--secondary);
}

.badge-category {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
}

.badge-gratis {
    background: var(--secondary);
    color: white;
}

.badge-software {
    background: var(--info);
    color: white;
}

.badge-hardware {
    background: var(--warning);
    color: var(--dark);
}

/* =============================================
   FEATURES SECTION
   ============================================= */
.feature-card {
    text-align: center;
    padding: 2rem;
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: white;
    box-shadow: var(--shadow-glow);
}

.feature-icon-img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.feature-icon-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feature-title {
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.75rem;
}

/* =============================================
   FILTER BUTTONS
   ============================================= */
.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.filter-btn {
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius-2xl);
    background: var(--white);
    border: 2px solid var(--gray-300);
    color: var(--gray-700);
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

/* =============================================
   FORMS
   ============================================= */
.form-control,
.form-select {
    padding: 0.875rem 1rem;
    border-radius: var(--radius-lg);
    border: 2px solid var(--gray-300);
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.form-label {
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

/* =============================================
   AUTH PAGES
   ============================================= */
.auth-container {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    padding: 3rem 0;
}

.auth-card {
    max-width: 450px;
    margin: 0 auto;
    padding: 2.5rem;
}

.auth-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--dark);
    text-align: center;
    margin-bottom: 0.5rem;
}

.auth-subtitle {
    color: var(--gray-600);
    text-align: center;
    margin-bottom: 2rem;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
    background: var(--gradient-dark);
    color: var(--white);
    margin-top: auto;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--gray-400);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

/* =============================================
   UTILITIES
   ============================================= */
.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 1rem;
}

.section-subtitle {
    color: var(--gray-600);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto 3rem;
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.glassmorphism {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .auth-card {
        padding: 1.5rem;
    }
}

/* =============================================
   ANIMATIONS
   ============================================= */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* =============================================
   BOTÓN HERRAMIENTAS GRATIS - NAVBAR
   ============================================= */
@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-5px);
    }

    60% {
        transform: translateY(-3px);
    }
}

@keyframes glow {

    0%,
    100% {
        box-shadow: 0 4px 15px rgba(255, 165, 0, 0.4);
    }

    50% {
        box-shadow: 0 4px 25px rgba(255, 165, 0, 0.8), 0 0 30px rgba(255, 215, 0, 0.6);
    }
}

@keyframes shake {

    0%,
    100% {
        transform: rotate(0deg);
    }

    25% {
        transform: rotate(-3deg);
    }

    75% {
        transform: rotate(3deg);
    }
}

.animate-bounce {
    animation: bounce 2s ease infinite;
}

.nav-link.animate-pulse {
    animation: glow 1.5s ease-in-out infinite, shake 3s ease-in-out infinite;
}

.nav-link.animate-pulse:hover {
    animation: none;
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(255, 165, 0, 0.6);
}