/**
 * =====================================================
 * ESTILOS PERSONALIZADOS - E-COMMERCE E-RENOVAR SAS
 * =====================================================
 * Archivo: assets/css/style.css
 * Descripción: Estilos modernos y responsivos
 * =====================================================
 */

/* =====================================================
   VARIABLES CSS Y CONFIGURACIÓN GENERAL
   ===================================================== */
:root {
    /* Colores principales */
    --primary-green: #00A676;
    --primary-orange: #FF7A00;
    --primary-dark: #003F5C;
    --secondary-cyan: #00D9FF;
    --secondary-purple: #7B2CBF;
    
    /* Colores de estado */
    --success-color: #28a745;
    --error-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    
    /* Colores neutros */
    --white: #ffffff;
    --light-gray: #f8f9fa;
    --medium-gray: #6c757d;
    --dark-gray: #343a40;
    
    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, var(--primary-green), var(--primary-dark));
    --gradient-secondary: linear-gradient(135deg, var(--primary-orange), var(--secondary-purple));
    --gradient-hero: linear-gradient(135deg, #00A676 0%, #003F5C 50%, #7B2CBF 100%);
    
    /* Sombras */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.2);
    
    /* Transiciones */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Fuentes */
    --font-primary: 'Roboto', sans-serif;
    --font-heading: 'Montserrat', sans-serif;
    --font-italic: 'Open Sans', italic;
}

/* Reset y configuración base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background: var(--gradient-hero);
    color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
}

/* Efecto de partículas animadas en el fondo */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(0, 166, 118, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 122, 0, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(123, 44, 191, 0.1) 0%, transparent 50%);
    animation: backgroundAnimation 20s ease-in-out infinite;
    z-index: -1;
}

@keyframes backgroundAnimation {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* =====================================================
   TIPOGRAFÍA
   ===================================================== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

.quote {
    font-family: var(--font-italic);
    font-style: italic;
}

/* =====================================================
   HEADER
   ===================================================== */
header {
    text-align: center;
    padding: 4rem 2rem;
    position: relative;
    z-index: 10;
}

.logo-container {
    margin-bottom: 2rem;
    animation: fadeInDown 1s ease-out;
}

.main-logo {
    max-width: 200px;
    height: auto;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.3));
    transition: transform var(--transition-normal);
}

.main-logo:hover {
    transform: scale(1.05) rotate(2deg);
}

h1.display-4 {
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    font-weight: 800;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease-out 0.3s backwards;
}

.lead.quote {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    max-width: 900px;
    margin: 0 auto;
    opacity: 0.95;
    text-shadow: 1px 1px 5px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 1s ease-out 0.6s backwards;
}

/* =====================================================
   CONTADOR REGRESIVO
   ===================================================== */
.countdown-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 3rem 2rem;
    margin: 3rem auto;
    max-width: 900px;
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: fadeInScale 1s ease-out 0.9s backwards;
}

.countdown-title {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    margin-bottom: 2rem;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.countdown-timer {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.countdown-item {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(5px);
    border-radius: 15px;
    padding: 1.5rem 2rem;
    min-width: 120px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all var(--transition-normal);
    animation: pulse 2s ease-in-out infinite;
}

.countdown-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    border-color: var(--primary-orange);
}

.countdown-number {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 900;
    display: block;
    color: var(--primary-orange);
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
}

.countdown-label {
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 0.5rem;
    opacity: 0.9;
}

/* Mensaje cuando el contador llega a cero */
.countdown-finished {
    display: none;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: bold;
    color: var(--primary-orange);
    text-align: center;
    animation: celebrate 1s ease-in-out infinite;
}

@keyframes celebrate {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* =====================================================
   SECCIÓN DE PROYECTOS
   ===================================================== */
.projects-section {
    padding: 3rem 0;
}

.project-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-normal);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    animation: fadeInUp 0.8s ease-out backwards;
}

.project-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-orange);
    background: rgba(255, 255, 255, 0.15);
}

.proj-img {
    width: 151px;
    height: 151px;
    margin: 0 auto;
}

.project-logo {
    width: 150px;
    height: auto;
    max-height: 150px;
    margin: 0 auto 1.5rem;
    display: block;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.2));
    transition: transform var(--transition-normal);
}

.project-card:hover .project-logo {
    transform: scale(1.1);
}

.project-card h2 {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    color: var(--primary-orange);
    margin-bottom: 1rem;
    text-align: center;
}

.project-card p {
    font-size: clamp(0.9rem, 2vw, 1rem);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    opacity: 0.95;
    flex-grow: 1;
}

.project-card a {
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: var(--gradient-primary);
    border-radius: 50px;
    transition: all var(--transition-normal);
    text-align: center;
    justify-content: center;
}

.project-card a:hover {
    background: var(--gradient-secondary);
    transform: translateX(5px);
    box-shadow: var(--shadow-md);
}

.project-card a i {
    transition: transform var(--transition-fast);
}

.project-card a:hover i {
    transform: translateX(5px);
}

/* =====================================================
   FORMULARIO DE SUSCRIPCIÓN
   ===================================================== */
.subscription-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 3rem 2rem;
    margin: 3rem auto;
    max-width: 700px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-xl);
    animation: fadeInScale 1s ease-out 1.2s backwards;
}

.subscription-section h2 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    margin-bottom: 2rem;
    text-align: center;
}

.subscription-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    font-size: 1rem;
    color: var(--white);
}

.form-control {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid transparent;
    border-radius: 10px;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    font-family: var(--font-primary);
    color: var(--primary-dark);
    transition: all var(--transition-normal);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-orange);
    box-shadow: 0 0 0 4px rgba(255, 122, 0, 0.2);
    background: var(--white);
}

.form-control::placeholder {
    color: var(--medium-gray);
}

.btn-subscribe {
    background: var(--gradient-secondary);
    color: var(--white);
    border: none;
    border-radius: 50px;
    padding: 1.2rem 3rem;
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-md);
    margin-top: 1rem;
}

.btn-subscribe:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    background: var(--primary-orange);
}

.btn-subscribe:active {
    transform: translateY(-1px);
}

.btn-subscribe:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.form-note {
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.8;
    margin-top: 1rem;
}

/* =====================================================
   FOOTER
   ===================================================== */
footer {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    padding: 2rem 0;
    margin-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer p {
    margin-bottom: 1rem;
}

footer a {
    color: var(--white);
    text-decoration: none;
    transition: color var(--transition-fast);
}

footer a:hover {
    color: var(--primary-orange);
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
}

.social-links a {
    font-size: 1.5rem;
    transition: all var(--transition-normal);
}

.social-links a:hover {
    transform: translateY(-5px);
    color: var(--primary-orange);
}

/* =====================================================
   ANIMACIONES
   ===================================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
}

/* Añadir delays escalonados a las cards */
.project-card:nth-child(1) { animation-delay: 0.1s; }
.project-card:nth-child(2) { animation-delay: 0.2s; }
.project-card:nth-child(3) { animation-delay: 0.3s; }
.project-card:nth-child(4) { animation-delay: 0.4s; }
.project-card:nth-child(5) { animation-delay: 0.5s; }
.project-card:nth-child(6) { animation-delay: 0.6s; }

/* =====================================================
   COOKIE CONSENT
   ===================================================== */
.cookie-consent {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 63, 92, 0.98);
    backdrop-filter: blur(10px);
    padding: 1.5rem;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    transform: translateY(100%);
    transition: transform var(--transition-slow);
    border-top: 3px solid var(--primary-orange);
}

.cookie-consent.show {
    transform: translateY(0);
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.cookie-consent p {
    margin: 0;
    flex: 1;
    min-width: 250px;
}

.cookie-consent-buttons {
    display: flex;
    gap: 1rem;
}

.btn-cookie {
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
}

.btn-cookie-accept {
    background: var(--primary-orange);
    color: var(--white);
}

.btn-cookie-accept:hover {
    background: var(--primary-green);
    transform: translateY(-2px);
}

.btn-cookie-decline {
    background: rgba(255, 255, 255, 0.2);
    color: var(--white);
}

.btn-cookie-decline:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* =====================================================
   RESPONSIVE DESIGN
   ===================================================== */

/* Tablets */
@media (max-width: 768px) {
    header {
        padding: 3rem 1.5rem;
    }
    
    .countdown-section {
        padding: 2rem 1.5rem;
    }
    
    .countdown-timer {
        gap: 1rem;
    }
    
    .countdown-item {
        min-width: 100px;
        padding: 1rem 1.5rem;
    }
    
    .project-card {
        padding: 1.5rem;
    }
    
    .subscription-section {
        padding: 2rem 1.5rem;
    }
    
    .cookie-consent-content {
        flex-direction: column;
        text-align: center;
    }
}

/* Móviles */
@media (max-width: 480px) {
    header {
        padding: 2rem 1rem;
    }
    
    .main-logo {
        max-width: 150px;
    }
    
    .countdown-timer {
        gap: 0.5rem;
    }
    
    .countdown-item {
        min-width: 80px;
        padding: 0.8rem 1rem;
    }
    
    .countdown-number {
        font-size: 2rem;
    }
    
    .countdown-label {
        font-size: 0.75rem;
    }
    
    .project-card {
        padding: 1.5rem 1rem;
    }
    
    .btn-subscribe {
        padding: 1rem 2rem;
        font-size: 1rem;
    }
    
    .social-links {
        gap: 1rem;
    }
    
    .cookie-consent-buttons {
        width: 100%;
        flex-direction: column;
    }
    
    .btn-cookie {
        width: 100%;
    }
}

/* =====================================================
   UTILIDADES
   ===================================================== */
.text-center {
    text-align: center;
}

.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-5 { margin-top: 3rem; }

.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }

/* =====================================================
   FIN DE ESTILOS
   ===================================================== */