/* ========== CONTENEDOR GENERAL ========== */
.uac-rt-wrapper {
    width: 100%;
    margin: 24px 0;
    overflow-x: auto;
}

/* ========== TABLA BASE (ESCRITORIO) ========== */
.uac-rt-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 14px;
    background: linear-gradient(180deg, #f8f9ff 0%, #ffffff 40%);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

/* Bordes y padding */
.uac-rt-table th,
.uac-rt-table td {
    border: 0;
    border-bottom: 1px solid #e5e7eb;
    padding: 12px 18px;
    vertical-align: middle;
}

/* Quitar borde de la última fila */
.uac-rt-table tbody tr:last-child td {
    border-bottom: 0;
}

/* Encabezados (color de fondo lo controlas desde ajustes del plugin) */
.uac-rt-table thead th {
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-size: 13px;
    white-space: nowrap;
    color: #ffffff !important;   /* 🔥 ahora siempre se verá */
}

/* Zebra (aplicada solo al body) */
.uac-rt-table--zebra tbody tr:nth-child(even) {
    background-color: #f9fafb;
}

/* Hover en filas (solo escritorio) */
@media (min-width: 769px) {
    .uac-rt-table tbody tr:hover {
        background-color: #eef4ff;
    }
}

/* Alineación */
.uac-rt-table--align-left th,
.uac-rt-table--align-left td {
    text-align: left;
}

.uac-rt-table--align-center th,
.uac-rt-table--align-center td {
    text-align: center;
}

.uac-rt-table--align-right th,
.uac-rt-table--align-right td {
    text-align: right;
}

/* Última columna centrada en escritorio (Descargar anexos) */
@media (min-width: 769px) {
    .uac-rt-table td:last-child,
    .uac-rt-table th:last-child {
        text-align: center;
        white-space: nowrap;
    }
}

/* ========== BOTÓN DESCARGAR ========== */
.uac-rt-btn-download {
    display: inline-block;
    padding: 6px 18px;
    text-decoration: none;
    border-radius: 999px;
    border: 0;
    background: #0052a3;
    color: #ffffff;
    font-size: 13px;
    line-height: 1.4;
    cursor: pointer;
    font-weight: 500;
    box-shadow: 0 2px 6px rgba(0, 82, 163, 0.35);
}

.uac-rt-btn-download:hover,
.uac-rt-btn-download:focus {
    background: #004487;
    color: #ffffff;
    box-shadow: 0 3px 8px rgba(0, 68, 135, 0.45);
}

/* ========== MÓVIL: TARJETA TIPO FICHA (≤ 768px) ========== */
@media (max-width: 768px) {
    .uac-rt-wrapper {
        overflow-x: visible;
    }

    .uac-rt-table {
        border: 0;
        box-shadow: none;
        background: transparent;
    }

    .uac-rt-table thead {
        display: none;
    }

    .uac-rt-table tbody {
        display: block;
    }

    .uac-rt-table tbody tr {
        display: block;
        margin-bottom: 20px;
        background: #ffffff;
        border-radius: 16px;
        box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
        overflow: hidden;
    }

    .uac-rt-table td {
        display: block;
        border: 0;
        border-bottom: 1px solid #edf1f7;
        padding: 10px 16px;
        font-size: 14px;
    }

    .uac-rt-table tbody tr:last-child td:last-child {
        border-bottom: 0;
    }

    .uac-rt-table td:last-child {
        border-bottom: 0;
        padding-bottom: 14px;
    }

    /* Etiqueta (N°, TÍTULO, etc.) arriba, contenido debajo */
    .uac-rt-table td::before {
        content: attr(data-label);
        display: block;
        font-weight: 700;
        text-transform: uppercase;
        font-size: 11px;
        letter-spacing: 0.06em;
        color: #0052a3;
        margin-bottom: 2px;
    }

    /* Contenido debajo alineado a la izquierda */
    .uac-rt-table td,
    .uac-rt-table td > *:not(.uac-rt-btn-download) {
        text-align: left;
    }

    /* Botón ancho completo centrado */
    .uac-rt-btn-download {
        display: block;
        width: 100%;
        text-align: center;
        margin-top: 4px;
    }
}
