Files
roi-theme/wp-content/themes/apus-theme/assets/css/css-tablas-apu.css
FrankZamora d52814c81d ARQUITECTURA: Completar renombramientos CSS - Carpetas 10-20 - Issue #133
RENOMBRAMIENTOS COMPLETADOS (19 archivos adicionales):

COMPONENTES (carpetas 10, 12, 14, 15, 17, 18, 19):
 post-content.css → componente-post-content.css (10)
 cta-box-sidebar.css → componente-cta-box-sidebar.css (12)
 cta.css → componente-cta-ab-testing.css (14)
 related-posts.css → componente-related-posts.css (15)
 header.css → componente-footer-principal.css (17)
 modal-contact.css → componente-modal-contacto.css (18)
 tables-apu.css → css-tablas-apu.css (19)

CSS GLOBALES (carpeta 20):
 variables.css → css-global-variables.css
 fonts.css → css-global-fonts.css
 utilities.css → css-global-utilities.css
 animations.css → css-global-animations.css
 responsive.css → css-global-responsive.css
 accessibility.css → css-global-accessibility.css
 print.css → css-global-print.css
 badges.css → css-global-badges.css
 pagination.css → css-global-pagination.css
 toc.css → css-global-toc.css
 generic-tables.css → css-global-generic-tables.css
 video.css → css-global-video.css

ACTUALIZACIONES:
- enqueue-scripts.php: Todas las referencias actualizadas (48 cambios)
- functions.php: Version bump 1.0.9 → 1.0.10

TOTAL RENOMBRAMIENTOS:
- Commit 8d876: 7 archivos (carpetas 05, 06, 07, 08, 11, 13, 16)
- Este commit: 19 archivos (carpetas 10, 12, 14, 15, 17, 18, 19 + globales 20)
- TOTAL: 26 archivos renombrados

CORRESPONDENCIA 1-A-1 COMPLETADA:
 Cada componente tiene su archivo CSS con nombre de carpeta
 Archivos globales con prefijo css-global-
 Sin duplicaciones
 Nomenclatura consistente

Issue: #133

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-08 17:27:08 -06:00

502 lines
13 KiB
CSS

/**
* Tablas APU - Análisis de Precios Unitarios
* Estilos específicos para tablas de construcción
*
* @package Apus_Theme
* @since 1.0.0
*/
/* ========================================
CONTENEDOR PRINCIPAL DE TABLA APU
======================================== */
.analisis,
.desglose {
margin: 2rem 0;
overflow-x: auto;
-webkit-overflow-scrolling: touch;
}
/* ========================================
TABLA BASE
======================================== */
.analisis table,
.desglose table {
width: 100%;
border-collapse: collapse;
background: #ffffff;
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
border-radius: 8px;
border: none;
border-spacing: 0;
}
/* Eliminar todos los bordes */
.analisis table td,
.desglose table td,
.analisis table tbody,
.desglose table tbody,
.analisis table tr,
.desglose table tr {
border: none;
}
/* ========================================
ANCHOS DE COLUMNAS
======================================== */
.analisis table td:nth-child(1),
.analisis table th:,
.desglose table th:nth-child(1) {
width: 150px;
min-width: 100px;
}
.analisis table td:nth-child(2),
.analisis table th:,
.desglose table th:nth-child(2) {
width: auto;
min-width: 300px;
}
.analisis table td:nth-child(3),
.analisis table th:,
.desglose table th:nth-child(3) {
width: 80px;
min-width: 60px;
}
.analisis table td:nth-child(4),
.analisis table th:,
.desglose table th:nth-child(4) {
width: 110px;
min-width: 90px;
}
.analisis table td:nth-child(5),
.analisis table th:,
.desglose table th:nth-child(5) {
width: 120px;
min-width: 100px;
}
.analisis table td:nth-child(6),
.analisis table th:,
.desglose table th:nth-child(6) {
width: 120px;
min-width: 100px;
}
/* ========================================
ENCABEZADOS DE TABLA (THEAD)
======================================== */
.analisis table thead tr th,
.desglose table thead tr th {
background: linear-gradient(135deg, #1e3a5f 0%, #2c5282 100%);
color: #ffffff;
font-weight: 600;
text-align: center !important;
padding: 1rem;
border: none;
position: sticky;
top: 0;
z-index: 10;
}
/* ESPECIAL: Primera fila de .analisis cuando NO tiene <thead>
(para tablas de resumen que solo tienen <tbody>) */
.analisis table tbody tr:first-child td {
background: linear-gradient(135deg, #1e3a5f 0%, #2c5282 100%);
color: #ffffff;
font-weight: 600;
text-align: center !important;
padding: 1rem;
border: none;
}
/* Esquinas redondeadas superiores para primera fila de .analisis */
.analisis table tbody tr:first-child td:first-child {
border-top-left-radius: 8px;
}
.analisis table tbody tr:first-child td:last-child {
border-top-right-radius: 8px;
}
/* ========================================
FILAS NORMALES
======================================== */
.analisis table tbody td,
.desglose table tbody td {
padding: 0.75rem 1rem;
border: none;
}
/* ========================================
ZEBRA STRIPING - Filas alternadas
======================================== */
.analisis table tbody tr:nth-child(even):not(.section-header):not(.subtotal-row):not(.total-row),
.desglose table tbody tr:nth-child(even):not(.section-header):not(.subtotal-row):not(.total-row) {
background-color: #f8f9fa;
}
.analisis table tbody tr:nth-child(odd):not(.section-header):not(.subtotal-row):not(.total-row),
.desglose table tbody tr:nth-child(odd):not(.section-header):not(.subtotal-row):not(.total-row) {
background-color: #ffffff;
}
/* ========================================
ALINEACIÓN DE COLUMNAS
======================================== */
/* Columnas 1 y 2: Clave y Descripción - izquierda */
.analisis table td:nth-child(1),
.analisis table td:nth-child(2) {
text-align: left;
}
/* Columna 3: Unidad - centrada */
.analisis table td:nth-child(3),
.analisis table td.c3,
.desglose table td.c3 {
text-align: center !important;
color: #6c757d;
font-size: 0.9em;
}
/* Columnas 4, 5, 6 en .analisis: Cantidad, Costo, Importe - con fuente monospace */
.analisis table td:nth-child(4),
.analisis table td.c4,
.analisis table td:nth-child(5),
.analisis table td.c5,
.analisis table td:nth-child(6),
.analisis table td.c6 {
text-align: right !important;
font-family: 'Courier New', Courier, monospace;
font-weight: 500;
color: #1e3a5f;
}
/* Columnas 4, 5, 6 en .desglose: Cantidad, Costo, Importe - SIN fuente monospace */
.desglose table td.c4,
.desglose table td.c5,
.desglose table td.c6 {
text-align: right !important;
font-weight: 500;
color: #1e3a5f;
}
/* ========================================
HOVER EN FILAS DE DATOS
======================================== */
.analisis table tbody tr:not(.section-header):not(.subtotal-row):not(.total-row):hover,
.desglose table tbody tr:not(.section-header):not(.subtotal-row):not(.total-row):hover {
background-color: #fff3cd !important;
transition: background-color 0.2s ease;
cursor: pointer;
}
/* ========================================
ENCABEZADOS DE SECCIÓN
(Material, Mano de Obra, Herramienta, Equipo)
======================================== */
.analisis table tr.section-header,
.desglose table tr.section-header {
background-color: #e9ecef !important;
}
.analisis table tr.section-header td,
.desglose table tr.section-header td {
font-weight: 600;
color: #1e3a5f;
padding: 0.75rem 1rem;
border: none !important;
}
/* ========================================
FILAS DE SUBTOTALES
(Suma de Material, Suma de Mano de Obra, etc)
======================================== */
.analisis table tr.subtotal-row,
.desglose table tr.subtotal-row {
background-color: rgba(255, 133, 0, 0.1) !important;
}
.analisis table tr.subtotal-row td,
.desglose table tr.subtotal-row td {
font-weight: 700;
color: var(--color-orange-primary);
padding: 0.875rem 1rem;
border: none !important;
}
.analisis table tr.subtotal-row td:nth-child(2) {
font-style: italic;
}
.analisis table tr.subtotal-row td.c6,
.analisis table tr.subtotal-row td:nth-child(6) {
font-size: 1.05rem;
color: var(--color-orange-primary);
}
/* ========================================
FILA DE TOTAL FINAL
(Costo Directo)
======================================== */
.analisis table tr.total-row,
.desglose table tr.total-row {
background: linear-gradient(135deg, #1e3a5f 0%, #2c5282 100%) !important;
}
.analisis table tr.total-row td,
.desglose table tr.total-row td {
color: #ffffff !important;
font-weight: 700;
font-size: 1.1rem;
padding: 1.125rem 1rem !important;
border: none !important;
text-transform: uppercase;
letter-spacing: 0.5px;
}
.analisis table tr.total-row td.c6,
.analisis table tr.total-row td:nth-child(6) {
font-size: 1.25rem;
letter-spacing: 0.5px;
}
/* ========================================
ESTILOS PARA IMPRESIÓN
======================================== */
@media print {
.analisis {
margin: 1rem 0;
overflow: visible;
box-shadow: none;
}
.analisis table,
.desglose table {
box-shadow: none;
border: 1px solid #dee2e6;
}
.analisis table thead tr th,
.desglose table thead tr th {
background: #1e3a5f !important;
color: #ffffff !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
position: static;
}
.analisis table tr.section-header,
.desglose table tr.section-header {
background-color: #e9ecef !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.analisis table tr.subtotal-row,
.desglose table tr.subtotal-row {
background-color: rgba(255, 133, 0, 0.1) !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.analisis table tr.total-row,
.desglose table tr.total-row {
background: #1e3a5f !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.analisis table tbody tr:nth-child(even):not(.section-header):not(.subtotal-row):not(.total-row),
.desglose table tbody tr:nth-child(even):not(.section-header):not(.subtotal-row):not(.total-row) {
background-color: #f8f9fa !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
/* Evitar saltos de página dentro de las tablas */
.analisis table,
.desglose table {
page-break-inside: avoid;
}
.analisis table tr,
.desglose table tr {
page-break-inside: avoid;
page-break-after: auto;
}
/* No mostrar hover en impresión */
.analisis table tbody tr:hover {
background-color: inherit !important;
}
}
/* ========================================
RESPONSIVE - TABLETS (768px - 991px)
======================================== */
@media (max-width: 991px) {
.analisis {
font-size: 0.9rem;
}
.analisis table td {
padding: 0.6rem 0.8rem !important;
}
.analisis table thead tr th,
.desglose table thead tr th {
padding: 0.8rem 0.6rem;
font-size: 0.9rem;
}
.analisis table tr.total-row td,
.desglose table tr.total-row td {
font-size: 1rem !important;
padding: 1rem 0.8rem !important;
}
.analisis table tr.total-row td.c6,
.analisis table tr.total-row td:nth-child(6) {
font-size: 1.15rem !important;
}
/* Ajustar anchos mínimos en tablets */
.analisis table td:nth-child(1),
.analisis table th:,
.desglose table th:nth-child(1) {
min-width: 80px;
}
.analisis table td:nth-child(2),
.analisis table th:,
.desglose table th:nth-child(2) {
min-width: 200px;
}
}
/* ========================================
RESPONSIVE - MÓVILES (max 767px)
======================================== */
@media (max-width: 767px) {
.analisis {
font-size: 0.85rem;
margin: 1.5rem 0;
}
.analisis table td {
padding: 0.5rem !important;
}
.analisis table thead tr th,
.desglose table thead tr th {
padding: 0.7rem 0.5rem;
font-size: 0.85rem;
}
.analisis table tr.section-header td,
.desglose table tr.section-header td {
font-size: 0.85em;
padding: 0.6rem 0.5rem;
}
.analisis table tr.subtotal-row td,
.desglose table tr.subtotal-row td {
padding: 0.7rem 0.5rem;
}
.analisis table tr.subtotal-row td.c6,
.analisis table tr.subtotal-row td:nth-child(6) {
font-size: 1rem;
}
.analisis table tr.total-row td,
.desglose table tr.total-row td {
font-size: 0.95rem !important;
padding: 0.875rem 0.5rem !important;
}
.analisis table tr.total-row td.c6,
.analisis table tr.total-row td:nth-child(6) {
font-size: 1.1rem !important;
}
/* Ajustar anchos mínimos en móviles */
.analisis table td:nth-child(1),
.analisis table th:,
.desglose table th:nth-child(1) {
width: 80px;
min-width: 60px;
}
.analisis table td:nth-child(2),
.analisis table th:,
.desglose table th:nth-child(2) {
min-width: 150px;
}
.analisis table td:nth-child(3),
.analisis table th:,
.desglose table th:nth-child(3),
.analisis table td:nth-child(4),
.analisis table th:,
.desglose table th:nth-child(4),
.analisis table td:nth-child(5),
.analisis table th:,
.desglose table th:nth-child(5),
.analisis table td:nth-child(6),
.analisis table th:,
.desglose table th:nth-child(6) {
min-width: 70px;
}
}
/* ========================================
ACCESIBILIDAD
======================================== */
/* Mejorar contraste para lectores de pantalla */
.analisis table thead tr th,
.desglose table thead tr th {
outline: none;
}
/* Focus visible para navegación por teclado */
.analisis table tbody tr:focus-within,
.desglose table tbody tr:focus-within {
outline: 2px solid #0d6efd;
outline-offset: -2px;
}
/* ========================================
COMPATIBILIDAD CON BOOTSTRAP
======================================== */
/* Anular estilos de Bootstrap que puedan interferir */
.analisis table.table,
.desglose table.table {
margin-bottom: 0;
}
.analisis table.table > :not(caption) > * > *,
.desglose table.table > :not(caption) > * > * {
padding: inherit;
background-color: inherit;
border-bottom-width: 0;
box-shadow: none;
}
/* Mantener compatibilidad con clases de Bootstrap si se usan */
.analisis table.table-striped > tbody > tr:nth-of-type(odd) > *:not(.section-header):not(.subtotal-row):not(.total-row),
.desglose table.table-striped > tbody > tr:nth-of-type(odd) > *:not(.section-header):not(.subtotal-row):not(.total-row) {
background-color: #ffffff;
}
.analisis table.table-striped > tbody > tr:nth-of-type(even) > *:not(.section-header):not(.subtotal-row):not(.total-row),
.desglose table.table-striped > tbody > tr:nth-of-type(even) > *:not(.section-header):not(.subtotal-row):not(.total-row) {
background-color: #f8f9fa;
}