/**
 * Estilos del Frontend - Dinámicas Y Sorteos IW
 * Estética Casino: Rojo, Dorado, Negro
 * Desarrollado por Ingenial Web
 */

/* ============================================
   VARIABLES Y BASE
   ============================================ */
:root {
    --iw-rojo: #e74c3c;
    --iw-rojo-oscuro: #c0392b;
    --iw-dorado: #f0c040;
    --iw-dorado-oscuro: #b8860b;
    --iw-negro: #1a1a2e;
    --iw-negro-claro: #16213e;
    --iw-blanco: #ffffff;
    --iw-gris: #f5f5f5;
    --iw-verde: #27ae60;
    --iw-naranja: #f39c12;
}

/* ============================================
   CONTENEDOR PRINCIPAL
   ============================================ */
.iw-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* ============================================
   TITULOS CON ANIMACIÓN SHIMMER
   ============================================ */
.iw-titulo-casino {
    background: linear-gradient(135deg, var(--iw-dorado) 0%, #ffd700 50%, var(--iw-dorado) 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: iw-shimmer 3s linear infinite;
    font-size: 2.5em;
    font-weight: 800;
    text-align: center;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

@keyframes iw-shimmer {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}

/* ============================================
   GRID DE SORTEOS (ARCHIVE)
   ============================================ */
.iw-filtros {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.iw-filtro-btn {
    padding: 10px 25px;
    border: 2px solid var(--iw-dorado);
    background: transparent;
    color: var(--iw-dorado);
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 14px;
}

.iw-filtro-btn:hover,
.iw-filtro-btn.activo {
    background: var(--iw-dorado);
    color: var(--iw-negro);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(240, 192, 64, 0.4);
}

.iw-grid-sorteos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

/* ============================================
   TARJETA DE SORTEO
   ============================================ */
.iw-tarjeta-sorteo {
    background: linear-gradient(145deg, var(--iw-negro) 0%, var(--iw-negro-claro) 100%);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 2px solid transparent;
}

.iw-tarjeta-sorteo:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(231, 76, 60, 0.3);
    border-color: var(--iw-dorado);
}

.iw-tarjeta-imagen {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.iw-tarjeta-contenido {
    padding: 20px;
}

.iw-tarjeta-titulo {
    color: var(--iw-dorado);
    font-size: 1.4em;
    font-weight: 700;
    margin-bottom: 10px;
}

.iw-tarjeta-precio {
    color: var(--iw-blanco);
    font-size: 1.2em;
    margin-bottom: 15px;
}

.iw-tarjeta-precio strong {
    color: var(--iw-rojo);
    font-size: 1.4em;
}

.iw-tarjeta-info {
    display: flex;
    justify-content: space-between;
    color: #aaa;
    font-size: 0.9em;
    margin-bottom: 15px;
}

.iw-badge-estado {
    padding: 3px 12px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: 600;
}

.iw-badge-activo {
    background: var(--iw-verde);
    color: white;
}

.iw-badge-finalizado {
    background: var(--iw-rojo);
    color: white;
}

.iw-badge-pausado {
    background: var(--iw-naranja);
    color: white;
}

/* ============================================
   BOTONES CON ANIMACIÓN PULSE
   ============================================ */
.iw-btn-comprar {
    display: inline-block;
    width: 100%;
    padding: 15px 30px;
    background: linear-gradient(135deg, var(--iw-rojo) 0%, var(--iw-rojo-oscuro) 100%);
    color: var(--iw-blanco);
    border: none;
    border-radius: 30px;
    font-size: 1.1em;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    animation: iw-pulse 2s infinite;
    text-decoration: none;
}

.iw-btn-comprar:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(231, 76, 60, 0.5);
    animation: none;
}

@keyframes iw-pulse {
    0% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(231, 76, 60, 0); }
    100% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0); }
}

.iw-btn-dorado {
    background: linear-gradient(135deg, var(--iw-dorado) 0%, var(--iw-dorado-oscuro) 100%);
    color: var(--iw-negro);
}

.iw-btn-dorado:hover {
    box-shadow: 0 10px 25px rgba(240, 192, 64, 0.5);
}

/* ============================================
   FICHA INDIVIDUAL DEL SORTEO
   ============================================ */
.iw-ficha-sorteo {
    background: linear-gradient(145deg, var(--iw-negro) 0%, var(--iw-negro-claro) 100%);
    border-radius: 20px;
    padding: 40px;
    border: 3px solid var(--iw-dorado);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.iw-ficha-header {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.iw-ficha-imagen-principal {
    width: 100%;
    border-radius: 15px;
    border: 3px solid var(--iw-dorado);
    box-shadow: 0 10px 30px rgba(240, 192, 64, 0.3);
}

.iw-ficha-info {
    color: var(--iw-blanco);
}

.iw-ficha-titulo {
    color: var(--iw-dorado);
    font-size: 2em;
    font-weight: 800;
    margin-bottom: 15px;
}

.iw-ficha-precio {
    font-size: 1.8em;
    color: var(--iw-rojo);
    font-weight: 700;
    margin-bottom: 20px;
}

.iw-ficha-descripcion {
    color: #ccc;
    line-height: 1.6;
    margin-bottom: 20px;
}

.iw-ficha-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.iw-meta-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 10px 15px;
    border-radius: 8px;
    border-left: 3px solid var(--iw-dorado);
}

.iw-meta-item label {
    color: var(--iw-dorado);
    font-size: 0.8em;
    display: block;
    margin-bottom: 3px;
}

.iw-meta-item span {
    color: var(--iw-blanco);
    font-weight: 600;
}

/* ============================================
   BUSCADOR DE NÚMEROS
   ============================================ */
.iw-buscador-seccion {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    border: 1px solid rgba(240, 192, 64, 0.2);
}

.iw-buscador-titulo {
    color: var(--iw-dorado);
    font-size: 1.3em;
    margin-bottom: 15px;
}

.iw-buscador-input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.iw-buscador-input {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid rgba(240, 192, 64, 0.3);
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--iw-blanco);
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.iw-buscador-input:focus {
    border-color: var(--iw-dorado);
    outline: none;
    box-shadow: 0 0 10px rgba(240, 192, 64, 0.3);
}

.iw-buscador-input::placeholder {
    color: #888;
}

.iw-buscador-btn {
    padding: 12px 30px;
    background: linear-gradient(135deg, var(--iw-dorado) 0%, var(--iw-dorado-oscuro) 100%);
    color: var(--iw-negro);
    border: none;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.iw-buscador-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(240, 192, 64, 0.4);
}

.iw-buscador-resultados {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.iw-resultado-item {
    padding: 10px 15px;
    border-radius: 8px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9em;
}

.iw-resultado-disponible {
    background: rgba(39, 174, 96, 0.2);
    border: 1px solid var(--iw-verde);
    color: var(--iw-verde);
    cursor: pointer;
    transition: all 0.3s ease;
}

.iw-resultado-disponible:hover {
    background: var(--iw-verde);
    color: white;
}

.iw-resultado-vendido {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid var(--iw-rojo);
    color: var(--iw-rojo);
    text-decoration: line-through;
}

.iw-resultado-reservado {
    background: rgba(243, 156, 18, 0.2);
    border: 1px solid var(--iw-naranja);
    color: var(--iw-naranja);
}

.iw-resultado-bloqueado,
.iw-resultado-invalido,
.iw-resultado-fuera_rango {
    background: rgba(149, 165, 166, 0.2);
    border: 1px solid #95a5a6;
    color: #95a5a6;
}

/* ============================================
   PAQUETES DE NÚMEROS
   ============================================ */
.iw-paquetes-seccion {
    margin-bottom: 30px;
}

.iw-paquetes-titulo {
    color: var(--iw-dorado);
    font-size: 1.3em;
    margin-bottom: 15px;
}

.iw-paquetes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 10px;
}

.iw-paquete-btn {
    padding: 15px 10px;
    background: linear-gradient(145deg, var(--iw-negro-claro) 0%, var(--iw-negro) 100%);
    border: 2px solid var(--iw-dorado);
    border-radius: 10px;
    color: var(--iw-dorado);
    font-weight: 700;
    font-size: 1.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.iw-paquete-btn:hover {
    background: var(--iw-dorado);
    color: var(--iw-negro);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(240, 192, 64, 0.4);
}

.iw-paquete-btn small {
    display: block;
    font-size: 0.7em;
    font-weight: 400;
    margin-top: 5px;
    opacity: 0.8;
}

/* ============================================
   GRID DE NÚMEROS
   ============================================ */
.iw-grid-seccion {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(240, 192, 64, 0.2);
}

.iw-grid-titulo {
    color: var(--iw-dorado);
    font-size: 1.3em;
    margin-bottom: 15px;
}

.iw-bloque-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.iw-bloque-nav-btn {
    padding: 8px 20px;
    background: var(--iw-negro-claro);
    border: 2px solid var(--iw-dorado);
    color: var(--iw-dorado);
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.iw-bloque-nav-btn:hover {
    background: var(--iw-dorado);
    color: var(--iw-negro);
}

.iw-bloque-info {
    color: var(--iw-blanco);
    font-weight: 600;
}

.iw-grid-numeros {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 8px;
    max-height: 400px;
    overflow-y: auto;
    padding: 10px;
}

.iw-numero-celda {
    padding: 10px 5px;
    text-align: center;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.9em;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.iw-numero-disponible {
    background: rgba(39, 174, 96, 0.15);
    color: var(--iw-verde);
    border-color: var(--iw-verde);
}

.iw-numero-disponible:hover {
    background: var(--iw-verde);
    color: white;
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(39, 174, 96, 0.4);
}

.iw-numero-vendido {
    background: rgba(231, 76, 60, 0.15);
    color: var(--iw-rojo);
    border-color: var(--iw-rojo);
    cursor: not-allowed;
    opacity: 0.6;
}

.iw-numero-reservado {
    background: rgba(243, 156, 18, 0.15);
    color: var(--iw-naranja);
    border-color: var(--iw-naranja);
    cursor: not-allowed;
    opacity: 0.6;
}

.iw-numero-bloqueado {
    background: rgba(149, 165, 166, 0.15);
    color: #95a5a6;
    border-color: #95a5a6;
    cursor: not-allowed;
    opacity: 0.4;
}

.iw-numero-seleccionado {
    background: var(--iw-dorado) !important;
    color: var(--iw-negro) !important;
    border-color: var(--iw-dorado) !important;
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(240, 192, 64, 0.5);
}

/* ============================================
   LEYENDA
   ============================================ */
.iw-leyenda {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.iw-leyenda-item {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #ccc;
    font-size: 0.85em;
}

.iw-leyenda-color {
    width: 15px;
    height: 15px;
    border-radius: 4px;
}

.iw-leyenda-disponible { background: var(--iw-verde); }
.iw-leyenda-vendido { background: var(--iw-rojo); }
.iw-leyenda-reservado { background: var(--iw-naranja); }
.iw-leyenda-bloqueado { background: #95a5a6; }

/* ============================================
   CARRITO FLOTANTE
   ============================================ */
.iw-carrito-flotante {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, var(--iw-dorado) 0%, var(--iw-dorado-oscuro) 100%);
    color: var(--iw-negro);
    padding: 15px 25px;
    border-radius: 30px;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(240, 192, 64, 0.5);
    z-index: 9999;
    display: none;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.iw-carrito-flotante:hover {
    transform: scale(1.05);
}

.iw-carrito-flotante.visible {
    display: block;
    animation: iw-slide-up 0.5s ease;
}

@keyframes iw-slide-up {
    from { transform: translateY(100px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ============================================
   ALERTAS
   ============================================ */
.iw-alerta {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: 600;
}

.iw-alerta-exito {
    background: rgba(39, 174, 96, 0.2);
    border: 2px solid var(--iw-verde);
    color: var(--iw-verde);
}

.iw-alerta-error {
    background: rgba(231, 76, 60, 0.2);
    border: 2px solid var(--iw-rojo);
    color: var(--iw-rojo);
}

.iw-alerta-info {
    background: rgba(240, 192, 64, 0.2);
    border: 2px solid var(--iw-dorado);
    color: var(--iw-dorado);
}

/* ============================================
   LOADING SPINNER
   ============================================ */
.iw-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(240, 192, 64, 0.3);
    border-top-color: var(--iw-dorado);
    border-radius: 50%;
    animation: iw-spin 0.8s linear infinite;
}

@keyframes iw-spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media screen and (max-width: 768px) {
    .iw-ficha-header {
        grid-template-columns: 1fr;
    }

    .iw-grid-numeros {
        grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    }

    .iw-buscador-input-group {
        flex-direction: column;
    }

    .iw-paquetes-grid {
        grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    }

    .iw-titulo-casino {
        font-size: 1.8em;
    }
}
/* ============================================
   FASE 6: CONTADOR REGRESIVO
   ============================================ */
.iw-contador-seccion {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.15) 0%, rgba(240, 192, 64, 0.15) 100%);
    border: 2px solid var(--iw-dorado);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
    text-align: center;
}

.iw-contador-titulo {
    color: var(--iw-dorado);
    font-size: 1.3em;
    margin-bottom: 20px;
    animation: iw-shimmer 3s linear infinite;
}

.iw-contador-grid {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.iw-contador-caja {
    background: linear-gradient(145deg, var(--iw-negro) 0%, var(--iw-negro-claro) 100%);
    border: 2px solid var(--iw-dorado);
    border-radius: 12px;
    padding: 15px 20px;
    min-width: 90px;
    box-shadow: 0 5px 20px rgba(240, 192, 64, 0.3);
}

.iw-contador-numero {
    display: block;
    font-size: 2.5em;
    font-weight: 800;
    color: var(--iw-dorado);
    line-height: 1;
}

.iw-contador-label {
    display: block;
    color: #ccc;
    font-size: 0.85em;
    margin-top: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.iw-contador-finalizado {
    color: var(--iw-rojo);
    font-size: 1.5em;
    font-weight: 700;
}

/* ============================================
   FASE 6: BOTONES DE COMPARTIR
   ============================================ */
.iw-compartir-seccion {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 25px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
}

.iw-compartir-label {
    color: var(--iw-dorado);
    font-weight: 600;
    margin-right: 5px;
}

.iw-compartir-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(240, 192, 64, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: #ffffff;
    padding: 0;
}

.iw-compartir-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
    transition: all 0.3s ease;
}

.iw-compartir-btn:hover {
    transform: translateY(-3px) scale(1.15);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    color: #ffffff;
}

/* Colores de marca al hacer hover */
.iw-compartir-copiar {
    color: #f0c040;
}
.iw-compartir-copiar:hover {
    background: #f0c040;
    border-color: #f0c040;
    color: #1a1a2e;
}

.iw-compartir-whatsapp {
    color: #25d366;
}
.iw-compartir-whatsapp:hover {
    background: #25d366;
    border-color: #25d366;
    color: #ffffff;
}

.iw-compartir-facebook {
    color: #1877f2;
}
.iw-compartir-facebook:hover {
    background: #1877f2;
    border-color: #1877f2;
    color: #ffffff;
}

.iw-compartir-telegram {
    color: #0088cc;
}
.iw-compartir-telegram:hover {
    background: #0088cc;
    border-color: #0088cc;
    color: #ffffff;
}

.iw-compartir-x {
    color: #ffffff;
}
.iw-compartir-x:hover {
    background: #000000;
    border-color: #ffffff;
    color: #ffffff;
}

.iw-copiar-mensaje {
    color: var(--iw-verde);
    font-size: 0.85em;
    font-weight: 600;
    margin-left: 5px;
}

/* ============================================
   FASE 6: CRÉDITOS INGENIAL WEB
   ============================================ */
.iw-creditos-frontend {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(240, 192, 64, 0.2);
}

.iw-creditos-frontend a {
    color: #888;
    text-decoration: none;
    font-size: 0.85em;
    transition: color 0.3s ease;
}

.iw-creditos-frontend a:hover {
    color: var(--iw-dorado);
}

.iw-creditos-frontend strong {
    color: var(--iw-dorado);
}

/* Responsive contador */
@media screen and (max-width: 768px) {
    .iw-contador-caja {
        min-width: 70px;
        padding: 10px 12px;
    }

    .iw-contador-numero {
        font-size: 1.8em;
    }

    .iw-compartir-seccion {
        justify-content: center;
    }
}
/* ============================================
   CORRECCIÓN: BOTÓN IR A PAGAR AHORA
   ============================================ */
.iw-btn-pagar {
    display: inline-block;
    width: 100%;
    max-width: 400px;
    padding: 18px 35px;
    background: linear-gradient(135deg, #f0c040 0%, #b8860b 100%);
    color: #1a1a2e !important;
    border: none;
    border-radius: 30px;
    font-size: 1.2em;
    font-weight: 800;
    cursor: pointer;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    animation: iw-pulse-gold 2s infinite;
    text-decoration: none;
    box-shadow: 0 5px 20px rgba(240, 192, 64, 0.5);
}

.iw-btn-pagar:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(240, 192, 64, 0.7);
    animation: none;
}

@keyframes iw-pulse-gold {
    0% { box-shadow: 0 0 0 0 rgba(240, 192, 64, 0.7); }
    70% { box-shadow: 0 0 0 20px rgba(240, 192, 64, 0); }
    100% { box-shadow: 0 0 0 0 rgba(240, 192, 64, 0); }
}
/* ============================================
   INTEGRACIÓN WHATSAPP EN CHECKOUT
   ============================================ */

.iw-whatsapp-seccion {
    background: linear-gradient(145deg, #1a1a2e 0%, #16213e 100%);
    border: 3px solid #25d366;
    border-radius: 20px;
    padding: 35px;
    margin: 30px 0;
    box-shadow: 0 15px 40px rgba(37, 211, 102, 0.25);
}

.iw-whatsapp-header h2 {
    color: #25d366;
    font-size: 1.8em;
    margin: 0 0 15px 0;
    font-weight: 800;
}

.iw-whatsapp-header p {
    color: #ffffff;
    font-size: 1.05em;
    line-height: 1.6;
    margin-bottom: 10px;
}

.iw-whatsapp-header strong {
    color: #f0c040;
}

.iw-nota-email {
    background: rgba(240, 192, 64, 0.15);
    border-left: 4px solid #f0c040;
    padding: 12px 18px;
    border-radius: 6px;
    color: #f0c040 !important;
    font-size: 0.95em !important;
    margin-top: 15px !important;
}

.iw-whatsapp-preview {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(37, 211, 102, 0.3);
    border-radius: 12px;
    padding: 20px;
    margin: 25px 0;
}

.iw-whatsapp-preview h3 {
    color: #25d366;
    font-size: 1.1em;
    margin: 0 0 12px 0;
}

.iw-mensaje-preview {
    background: #0b141a;
    color: #e9edef;
    padding: 18px;
    border-radius: 8px;
    font-family: 'Segoe UI', Tahoma, sans-serif;
    font-size: 0.92em;
    line-height: 1.7;
    white-space: pre-wrap;
    word-wrap: break-word;
    margin: 0;
    max-height: 300px;
    overflow-y: auto;
}

.iw-btn-whatsapp-grande {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    width: 100%;
    max-width: 600px;
    margin: 30px auto;
    padding: 28px 40px;
    background: linear-gradient(135deg, #25d366 0%, #128c7e 50%, #075e54 100%);
    background-size: 200% auto;
    color: #ffffff !important;
    border: 3px solid #f0c040;
    border-radius: 60px;
    font-size: 1.3em;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: all 0.4s ease;
    animation: iw-pulse-whatsapp 2s infinite, iw-shimmer-btn 3s linear infinite;
    box-shadow: 
        0 10px 40px rgba(37, 211, 102, 0.6),
        0 0 20px rgba(240, 192, 64, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.iw-btn-whatsapp-grande::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.15) 50%,
        transparent 70%
    );
    animation: iw-brillo-btn 2.5s ease-in-out infinite;
}

.iw-btn-whatsapp-grande:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 
        0 20px 60px rgba(37, 211, 102, 0.8),
        0 0 40px rgba(240, 192, 64, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    animation: none;
    color: #ffffff !important;
    text-decoration: none;
    border-color: #ffd700;
    background-position: right center;
}

.iw-btn-whatsapp-grande:active {
    transform: translateY(-2px) scale(1.02);
}

.iw-btn-icono {
    font-size: 2.8em;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    position: relative;
    z-index: 1;
}

.iw-btn-texto {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    position: relative;
    z-index: 1;
}

.iw-btn-texto strong {
    font-size: 1.2em;
    display: block;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.iw-btn-texto small {
    font-size: 0.7em;
    font-weight: 400;
    opacity: 0.95;
    margin-top: 5px;
    display: block;
    text-transform: none;
    letter-spacing: 0;
    color: #f0c040;
}

@keyframes iw-pulse-whatsapp {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7), 0 0 20px rgba(240, 192, 64, 0.3); }
    70% { box-shadow: 0 0 0 25px rgba(37, 211, 102, 0), 0 0 40px rgba(240, 192, 64, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0), 0 0 20px rgba(240, 192, 64, 0.3); }
}

@keyframes iw-shimmer-btn {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}

@keyframes iw-brillo-btn {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.iw-whatsapp-nota {
    text-align: center;
    color: #f39c12;
    font-size: 0.95em;
    margin-top: 20px;
    padding: 12px;
    background: rgba(243, 156, 18, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(243, 156, 18, 0.3);
}

/* Nota informativa en el checkout sobre el email */
.iw-nota-email-checkout {
    background: rgba(37, 211, 102, 0.08);
    border-left: 4px solid #25d366;
    padding: 12px 18px;
    border-radius: 6px;
    margin: 15px 0;
    font-size: 0.9em;
    color: #1d2327;
}

.iw-nota-email-checkout strong {
    color: #128c7e;
}

/* Responsive */
@media screen and (max-width: 768px) {
    .iw-whatsapp-seccion {
        padding: 20px;
    }

    .iw-whatsapp-header h2 {
        font-size: 1.4em;
    }

    .iw-btn-whatsapp-grande {
        padding: 15px 20px;
        flex-direction: column;
        text-align: center;
    }

    .iw-btn-texto {
        align-items: center;
        text-align: center;
    }

    .iw-mensaje-preview {
        font-size: 0.85em;
        padding: 12px;
    }
}