/**
 * Estilos para el plugin de método de envío Zoom
 *
 * @package Dt24\MetodoZoom
 * @since 1.0.0
 */

/* Contenedor principal de campos Zoom */
/* #zoom_shipping_fields {
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
    margin: 20px 0;
} */

#zoom_shipping_fields h3 {
    margin-top: 0;
    color: #333;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 10px;
}

/* Campos requeridos */
.zoom-required-field {
    border-color: #ff6b6b !important;
    box-shadow: 0 0 5px rgba(255, 107, 107, 0.3);
}

.zoom-valid-field {
    border-color: #51cf66 !important;
    box-shadow: 0 0 5px rgba(81, 207, 102, 0.3);
}

/* Indicador de carga */
.zoom-loading {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
    text-align: center;
    font-weight: bold;
}

.zoom-loading:before {
    content: "⏳ ";
    margin-right: 5px;
}

/* Costo calculado */
.zoom-cost-display {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 15px;
    border-radius: 4px;
    margin: 15px 0;
    text-align: center;
    font-size: 16px;
}

.zoom-cost-display:before {
    content: "💰 ";
    margin-right: 5px;
}

/* Botones */
#recalcular-envio-zoom {
    background: #0073aa;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    margin: 10px 0;
    font-weight: bold;
}

#recalcular-envio-zoom:hover {
    background: #005a87;
}

#recalcular-envio-zoom:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Guía de envío */
/* .zoom-shipping-guide {
    background: #e7f3ff;
    border: 1px solid #b3d9ff;
    border-radius: 4px;
    padding: 20px;
    margin: 20px 0;
} */

.zoom-shipping-guide h3 {
    color: #0073aa;
    margin-top: 0;
}

#download-zoom-pdf,
.download-zoom-pdf-auto {
    background: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    margin: 10px 0;
}

#download-zoom-pdf:hover,
.download-zoom-pdf-auto:hover {
    background: #218838;
}

#download-zoom-pdf:disabled,
.download-zoom-pdf-auto:disabled {
    background: #6c757d;
    cursor: not-allowed;
}

/* Mensajes */
.woocommerce-error,
.woocommerce-message {
    padding: 10px 15px;
    margin: 10px 0;
    border-radius: 4px;
    border-left: 4px solid;
}

.woocommerce-error {
    background: #f8d7da;
    border-left-color: #dc3545;
    color: #721c24;
}

.woocommerce-message {
    background: #d1ecf1;
    border-left-color: #17a2b8;
    color: #0c5460;
}

/* Campos específicos por tipo de entrega */
.office_select,
.municipality_select,
.parish_select {
    transition: all 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
    #zoom_shipping_fields {
        padding: 15px;
        margin: 15px 0;
    }

    .zoom-cost-display {
        font-size: 14px;
        padding: 12px;
    }

    #recalcular-envio-zoom,
    #download-zoom-pdf,
    .download-zoom-pdf-auto {
        width: 100%;
        margin: 10px 0;
    }
}

/* Animaciones */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.zoom-cost-display,
.zoom-loading,
.woocommerce-error,
.woocommerce-message {
    animation: fadeIn 0.3s ease;
}

/* Estados de campos select */
select:disabled {
    background-color: #f5f5f5;
    color: #666;
    cursor: not-allowed;
}

select option:disabled {
    color: #999;
}

/* Tooltips para campos */
.zoom-field-tooltip {
    position: relative;
    display: inline-block;
    cursor: help;
    margin-left: 5px;
    color: #666;
}

.zoom-field-tooltip:hover:after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    white-space: nowrap;
    z-index: 1000;
    font-size: 12px;
}

.zoom-field-tooltip:hover:before {
    content: "";
    position: absolute;
    bottom: 120%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
    z-index: 1000;
}
