/*
 * Estilos para Tablas de Conversión de Criptomonedas
 * Plugin: Calculadoras Cripto
 * Diseño: Tablas lado a lado, sin pestañas
 */

/* Importar fuente Poppins */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/* Contenedor principal - Flex para dos columnas */
.crypto-conversion-wrapper {
    font-family: 'Poppins', sans-serif;
    margin: 30px auto;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    max-width: 1200px;
    width: 100%;
}

/* Cada tabla individual */
.crypto-conversion-single {
    background: #ffffff;
    border: 1px solid #C4CBD3;
    border-radius: 35px;
    padding: 30px;
    flex: 1;
    min-width: 300px;
    max-width: 500px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

/* Encabezado con icono y título */
.crypto-table-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 25px;
}

.crypto-header-icons {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    gap: 10px;
}

.crypto-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    transition: transform 0.3s ease;
}

/* Imagen del icono */
.crypto-icon-img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    display: block;
}

.crypto-arrow {
    font-size: 18px;
    color: #6b7280;
    margin: 0 8px;
}

.crypto-table-title {
    font-family: 'Poppins', sans-serif;
    font-size: 24px;
    font-weight: 600;
    line-height: 32px;
    color: #1F2A37;
    text-align: center;
    margin: 0;
}

.crypto-table-subtitle {
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    color: #6b7280;
    text-align: center;
    margin: 5px 0 0 0;
}

/* Lista de conversiones */
.crypto-conversion-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.crypto-conversion-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    /* Sin border-bottom para eliminar líneas */
}

.crypto-conversion-row:last-child {
    padding-bottom: 0;
}

/* Valores de la izquierda */
.crypto-amount {
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 24px;
    color: #1F2A37;
    display: flex;
    align-items: center;
    gap: 5px;
}

.crypto-amount-symbol {
    font-weight: 600;
}

/* Separador */
.crypto-separator {
    color: #6b7280;
    font-size: 14px;
    margin: 0 10px;
}

/* Valores convertidos de la derecha */
.crypto-value {
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    color: #265FF1;
    text-align: right;
}

/* Fecha dinámica */
.crypto-date {
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
}

/* Estados de carga */
.crypto-loading {
    text-align: center;
    padding: 40px;
    color: #6b7280;
    font-family: 'Poppins', sans-serif;
}

.crypto-loading::before {
    content: '⟳';
    display: inline-block;
    margin-right: 10px;
    animation: spin 1s linear infinite;
    font-size: 18px;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Estados de error */
.crypto-error {
    background: #ffffff;
    color: #dc2626;
    padding: 25px;
    border-radius: 35px;
    margin: 20px;
    border: 1px solid #fecaca;
    font-family: 'Poppins', sans-serif;
}

.crypto-error h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    font-weight: 600;
    color: #1F2A37;
}

.crypto-error ul {
    margin: 10px 0 0 20px;
    padding: 0;
}

/* Responsive Design */

/* Tablets - menos de 1024px */
@media (max-width: 1024px) {
    .crypto-conversion-wrapper {
        flex-direction: column;
        gap: 20px;
        align-items: center;
    }
    
    .crypto-conversion-single {
        width: 100%;
        max-width: 600px;
        min-width: unset;
        margin: 0 auto;
    }
}

/* Móviles - menos de 768px */
@media (max-width: 768px) {
    .crypto-conversion-wrapper {
        flex-direction: column;
        gap: 15px;
        align-items: center;
    }
    
    .crypto-conversion-single {
        width: 100%;
        max-width: none;
        min-width: unset;
        padding: 20px;
        border-radius: 25px;
        margin: 0;
    }
    
    .crypto-table-title {
        font-size: 20px;
        line-height: 28px;
    }
    
    .crypto-icon {
        width: 35px;
        height: 35px;
    }

    .crypto-icon-img {
        width: 28px;
        height: 28px;
    }
    
    .crypto-conversion-row {
        padding: 10px 0;
    }
    
    .crypto-amount,
    .crypto-value {
        font-size: 14px;
        line-height: 20px;
    }
}

@media (max-width: 480px) {
    .crypto-conversion-single {
        padding: 15px;
        border-radius: 20px;
    }
    
    .crypto-table-title {
        font-size: 18px;
        line-height: 24px;
    }
    
    .crypto-icon {
        width: 30px;
        height: 30px;
    }

    .crypto-icon-img {
        width: 24px;
        height: 24px;
    }
    
    .crypto-conversion-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
        padding: 8px 0;
    }
    
    .crypto-amount,
    .crypto-value {
        font-size: 13px;
        line-height: 18px;
        width: 100%;
    }
    
    .crypto-value {
        text-align: left;
    }
    
    .crypto-separator {
        display: none;
    }
}

/* Utilidades */
.crypto-hidden {
    display: none !important;
}

.crypto-fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(10px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

.crypto-highlight {
    background: linear-gradient(90deg, #dbeafe 0%, #bfdbfe 100%) !important;
    color: #1e40af !important;
}

/* ========================================
   ESTILOS PARA SHORTCODES - DISEÑO OPTIMIZADO
   ======================================== */

/* Contenedor del shortcode de tabla */
.fluyeze-calc-table-wrapper {
    font-family: 'Poppins', sans-serif;
    margin: 30px 0;
    max-width: 100%;
}

/* Header con iconos y título */
.fluyeze-calc-table-header {
    margin-bottom: 24px;
    text-align: center;
}

.fluyeze-calc-table-icons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 20px;
}

.fluyeze-calc-coin-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: contain;
    background: transparent;
    border: none;
    padding: 0;
    display: block;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
    transition: transform 0.2s ease, filter 0.2s ease;
}

.fluyeze-calc-coin-icon:hover {
    transform: translateY(-2px);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.12));
}

.fluyeze-calc-arrow {
    font-size: 18px;
    color: #6b7280;
    font-weight: 500;
}

.fluyeze-calc-table-title {
    font-size: 20px;
    font-weight: 600;
    color: #1F2A37;
    margin: 0;
    text-align: center;
    letter-spacing: -0.02em;
}

/* Tabla del shortcode - Estilo optimizado */
.fluyeze-calc-table {
    background: #ffffff;
    border: 1px solid #E1E9F4;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    border-collapse: separate;
    border-spacing: 0;
}

/* Encabezado de la tabla - Mostrar con estilo mejorado */
.fluyeze-calc-table thead {
    display: table-header-group;
}

.fluyeze-calc-table thead th {
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 0 16px 0;
    border: none;
    text-align: left;
}

.fluyeze-calc-table thead th:last-child {
    text-align: right;
}

/* Cuerpo de la tabla */
.fluyeze-calc-table tbody {
    display: table-row-group;
}

.fluyeze-calc-table tbody tr {
    display: table-row;
    transition: background-color 0.2s ease;
    border: none;
}

.fluyeze-calc-table tbody tr:hover {
    background-color: #FAFAFA;
}

.fluyeze-calc-table tbody tr:last-child td {
    border-bottom: none;
}

/* Celdas de la tabla */
.fluyeze-calc-table tbody td {
    padding: 14px 0;
    border-bottom: 1px solid #F0F4F8;
    vertical-align: middle;
}

/* Valores de la izquierda */
.fluyeze-calc-table tbody td:first-child {
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    color: #1F2A37;
    text-align: left;
    padding-right: 16px;
}

/* Valores convertidos de la derecha */
.fluyeze-calc-table tbody td:last-child {
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
    color: #265FF1;
    text-align: right;
    padding-left: 16px;
    white-space: nowrap;
}

/* Responsive para shortcodes */
@media (max-width: 768px) {
    .fluyeze-calc-table-wrapper {
        margin: 24px 0;
    }
    
    .fluyeze-calc-table-title {
        font-size: 18px;
    }
    
    .fluyeze-calc-table-icons {
        gap: 12px;
        margin-bottom: 16px;
    }
    
    .fluyeze-calc-coin-icon {
        width: 40px;
        height: 40px;
        border-radius: 10px;
    }
    
    .fluyeze-calc-table {
        padding: 20px;
        border-radius: 12px;
        max-width: 100%;
    }
    
    .fluyeze-calc-table thead th {
        font-size: 12px;
        padding-bottom: 12px;
    }
    
    .fluyeze-calc-table tbody td {
        padding: 12px 0;
    }
    
    .fluyeze-calc-table tbody td:first-child,
    .fluyeze-calc-table tbody td:last-child {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .fluyeze-calc-table-wrapper {
        margin: 20px 0;
    }
    
    .fluyeze-calc-table-title {
        font-size: 16px;
    }
    
    .fluyeze-calc-table {
        padding: 16px;
        border-radius: 12px;
    }
    
    .fluyeze-calc-table thead th {
        font-size: 11px;
        padding-bottom: 10px;
    }
    
    .fluyeze-calc-table tbody td {
        padding: 10px 0;
    }
    
    .fluyeze-calc-table tbody td:first-child {
        font-size: 14px;
        padding-right: 12px;
    }
    
    .fluyeze-calc-table tbody td:last-child {
        font-size: 14px;
        padding-left: 12px;
    }
    
    .fluyeze-calc-table-icons {
        gap: 10px;
        margin-bottom: 14px;
    }
    
    .fluyeze-calc-coin-icon {
        width: 36px;
        height: 36px;
        border-radius: 8px;
    }
    
    .fluyeze-calc-arrow {
        font-size: 16px;
    }
    
    .fluyeze-calc-table-title {
        font-size: 16px;
    }
    
    .fluyeze-calc-table-update {
        font-size: 11px;
    }
}

/* Footer con fecha de actualización */
.fluyeze-calc-table-footer {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #F0F4F8;
    text-align: center;
}

.fluyeze-calc-table-update {
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    color: #6b7280;
    margin: 0;
    font-style: italic;
}

.fluyeze-calc-table-update span {
    font-weight: 500;
    color: #3D4C60;
} 