/**
 * Estilos para WhatsApp Flotante Pro
 * Incluye estilos para frontend y backend en un solo archivo
 */

/* ======= ESTILOS FRONTEND ======= */

/* Estilos principales del botón */
.wafb-button {
    position: fixed;
    bottom: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Efecto hover */
.wafb-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4);
}

/* Posiciones del botón */
.wafb-position-right {
    right: 20px;
}

.wafb-position-left {
    left: 20px;
}

/* Animación de pulsación */
@keyframes wafb-pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

.wafb-pulse {
    animation: wafb-pulse 2s infinite;
}

/* Responsividad */
@media screen and (max-width: 480px) {
    .wafb-button {
        width: 50px;
        height: 50px;
        bottom: 15px;
    }
    
    .wafb-position-right {
        right: 15px;
    }
    
    .wafb-position-left {
        left: 15px;
    }
    
    .wafb-button svg {
        width: 20px;
        height: 20px;
    }
}

/* Estilos para el tooltip opcional */
.wafb-tooltip {
    position: absolute;
    background-color: #fff;
    color: #333;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.wafb-position-right .wafb-tooltip {
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
}

.wafb-position-left .wafb-tooltip {
    left: 70px;
    top: 50%;
    transform: translateY(-50%);
}

.wafb-button:hover .wafb-tooltip {
    opacity: 1;
    visibility: visible;
}

/* ======= ESTILOS ADMIN ======= */

/* Estilos generales del panel de administración */
.wafb-admin-wrap {
    max-width: 1200px;
    margin: none;
}

.wafb-admin-wrap h1 {
    margin-bottom: 20px;
    color: #23282d;
    font-size: 23px;
    font-weight: 400;
    padding: 9px 0 4px;
    line-height: 1.3;
}

/* Estilos para el filtro de fechas */
.wafb-date-filter {
    margin-bottom: 20px;
    padding: 15px;
    background: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
    border-radius: 3px;
}

.wafb-date-filter select {
    margin-right: 10px;
    min-width: 150px;
}

/* Estilos para el resumen de estadísticas */
.wafb-stats-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.wafb-stats-card {
    flex: 1;
    min-width: 200px;
    background: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
    padding: 20px;
    text-align: center;
    border-radius: 3px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.wafb-stats-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
}

.wafb-stats-card h3 {
    margin-top: 0;
    color: #23282d;
    font-size: 16px;
    font-weight: 600;
}

.wafb-stats-number {
    font-size: 32px;
    font-weight: bold;
    color: #0073aa;
    margin: 10px 0;
}

/* Estilos para secciones de datos */
.wafb-popular-urls,
.wafb-latest-clicks {
    margin-top: 30px;
    background: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
    padding: 20px;
    border-radius: 3px;
}

.wafb-popular-urls h3,
.wafb-latest-clicks h3 {
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #f1f1f1;
    color: #23282d;
    font-size: 16px;
    font-weight: 600;
}

/* Estilo para las tablas */
.wafb-admin-wrap .wp-list-table {
    border-collapse: collapse;
    margin-top: 10px;
    width: 100%;
}

.wafb-admin-wrap .wp-list-table th {
    text-align: left;
    padding: 10px;
    font-weight: 600;
}

.wafb-admin-wrap .wp-list-table td {
    padding: 10px;
    vertical-align: middle;
}

.wafb-admin-wrap .wp-list-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.wafb-admin-wrap .wp-list-table a {
    color: #0073aa;
    text-decoration: none;
}

.wafb-admin-wrap .wp-list-table a:hover {
    color: #00a0d2;
    text-decoration: underline;
}

/* Estilos para la paginación */
.wafb-pagination {
    margin-top: 20px;
    text-align: right;
}

.wafb-pagination .tablenav-pages {
    float: none;
    display: inline-block;
}

.wafb-pagination .tablenav-pages a,
.wafb-pagination .tablenav-pages span.current {
    display: inline-block;
    min-width: 28px;
    min-height: 28px;
    margin: 0 3px;
    padding: 0 5px;
    text-align: center;
    line-height: 28px;
    background: #f3f5f6;
    border: 1px solid #ccc;
    border-radius: 3px;
    font-size: 13px;
}

.wafb-pagination .tablenav-pages a:hover {
    background: #e9e9e9;
    border-color: #999;
}

.wafb-pagination .tablenav-pages span.current {
    background: #0073aa;
    border-color: #006799;
    color: #fff;
    font-weight: 600;
}

/* Estilos para el formulario de configuración */
.wafb-admin-wrap .form-table th {
    width: 200px;
    padding: 20px 10px 20px 0;
}

.wafb-admin-wrap .form-table td {
    padding: 15px 10px;
}

.wafb-admin-wrap .form-table .description {
    font-style: italic;
    color: #666;
    margin-top: 4px;
}

/* Estilos para el color picker */
.wp-picker-container {
    display: inline-block;
}

.wp-picker-container .wp-color-result {
    margin: 0 6px 0 0;
}