/**
 * Estilos de Administración - Solwed WP Plugin 
 * Estilo optimizado y simplificado
 */

/* === CONTENEDORES PRINCIPALES === */
.solwed-form-section,
.solwed-stat-card {
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 4px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 1px 1px rgba(0,0,0,0.04);
    max-width: 1200px;
}

.solwed-stat-card {
    text-align: center;
}

/* === CENTRADO PARA PESTAÑA DE APARIENCIA === */
.wrap .solwed-form-section {
    margin: 20px auto;
}

.solwed-form-section .form-table {
    max-width: 800px;
}

.solwed-form-section .form-table th {
    width: 180px;
    padding: 15px 10px 15px 0;
    vertical-align: top;
}

.solwed-form-section .form-table td {
    padding: 15px 0;
}

/* === VISTA PREVIA CENTRADA === */
.solwed-preview {
    margin: 30px 0;
    text-align: center;
}

.solwed-banner-preview {
    display: inline-block;
    max-width: 600px;
    margin: 15px auto;
    border: 2px dashed #c3c4c7;
    border-radius: 6px;
    padding: 20px;
}

/* === TÍTULOS Y TEXTO === */
.solwed-form-section h3 {
    color: #1d2327;
    font-size: 18px;
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #dcdcde;
}

.solwed-form-section .description,
.solwed-stat-label,
.logs-empty {
    color: #646970;
    font-size: 13px;
}

.logs-empty {
    text-align: center;
    padding: 40px 20px;
    font-size: 16px;
}

.logs-empty .dashicons {
    font-size: 48px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.logs-empty p {
    margin: 0;
}

/* === ESTADÍSTICAS === */
.solwed-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.solwed-stat-number {
    font-size: 24px;
    font-weight: 600;
    color: #1d2327;
    margin-bottom: 5px;
}

/* === BOTONES === */
.solwed-btn,
#smtp-test-btn,
.button.solwed-button {
    background: #2271b1 !important;
    border: 1px solid #2271b1 !important;
    color: #fff !important;
    padding: 8px 12px !important;
    border-radius: 3px !important;
    font-size: 13px !important;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    font-weight: normal;
    line-height: 1.4;
}

.solwed-btn:hover,
#smtp-test-btn:hover,
.button.solwed-button:hover {
    background: #135e96 !important;
    border-color: #135e96 !important;
    color: #fff !important;
}

/* === FORMULARIOS === */
.solwed-form-actions {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #dcdcde;
}

textarea {
    width: calc(100% - 50px);
    max-width: calc(100% - 50px);
    box-sizing: border-box;
}

/* === SWITCHES === */
.solwed-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.solwed-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.solwed-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #8c8f94;
    transition: 0.3s;
    border-radius: 12px;
}

.solwed-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .solwed-slider {
    background-color: #2271b1;
}

input:checked + .solwed-slider:before {
    transform: translateX(20px);
}

/* === BADGES Y TOOLTIPS === */
.solwed-status-badge {
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
    color: #fff;
}

.solwed-status-badge.sent {
    background: #00a32a;
}

.solwed-status-badge.failed {
    background: #d63638;
}

.solwed-error-tooltip {
    display: none;
    position: absolute;
    background: #1d2327;
    color: #fff;
    padding: 8px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
}

.solwed-log-error-message {
    position: relative;
}

.solwed-log-error-message:hover .solwed-error-tooltip {
    display: block;
}
