/* Estilos Componente Tablas */

.table-container, /* Aplicar a ambos */
.formulas-table-container {
    margin: 40px 0;
    overflow-x: auto; 
    background-color: #fff;
    border-radius: 12px; /* Ligero ajuste */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06); /* Sombra ajustada */
    padding: 25px; /* Padding ajustado */
}

.table-title, /* Aplicar a ambos */
.formulas-table-container .table-title {
    text-align: center;
    font-size: 1.6rem; /* Tamaño ajustado */
    color: var(--primary-color);
    margin-bottom: 25px; /* Espacio ajustado */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    padding-bottom: 15px;
}

.table-title:after,
.formulas-table-container .table-title:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
}

.styled-table,
.formulas-table {
    width: 100%;
    border-collapse: separate; /* Separar bordes para radios */
    border-spacing: 0; /* Quitar espacio entre celdas */
    margin-bottom: 30px; /* Espacio ajustado */
    border: 1px solid rgba(var(--primary-rgb), 0.1);
    border-radius: 8px; /* Redondear esquinas tabla */
    overflow: hidden; /* Para aplicar radios */
    font-size: 0.95rem;
    box-shadow: 0 3px 15px rgba(var(--primary-rgb), 0.05);
}

.styled-table th,
.styled-table td,
.formulas-table th,
.formulas-table td {
    padding: 15px 18px; /* Padding ajustado */
    text-align: left;
    border-bottom: 1px solid rgba(var(--primary-rgb), 0.08); /* Borde solo inferior */
    vertical-align: middle; /* Centrar verticalmente */
}

.styled-table th,
.formulas-table th {
    background: linear-gradient(135deg, var(--primary-color), #0086b3); /* Fondo degradado */
    font-weight: 600;
    color: var(--white);
    border-right: 1px solid rgba(255, 255, 255, 0.1); /* Línea divisoria vertical */
    white-space: nowrap; /* Evitar que texto largo rompa */
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.styled-table th:last-child,
.formulas-table th:last-child {
    border-right: none; /* Quitar borde derecho última cabecera */
}

/* Celdas de datos */
.styled-table td,
.formulas-table td {
    color: #555; /* Color texto */
    line-height: 1.6;
    border-right: 1px solid rgba(var(--primary-rgb), 0.05); /* Línea divisoria suave */
    transition: background-color 0.3s ease;
}

.styled-table td:last-child,
.formulas-table td:last-child {
    border-right: none; /* Quitar borde derecho última celda */
}

/* Estilo hover para filas */
.styled-table tbody tr:hover,
.formulas-table tbody tr:hover {
    background-color: rgba(var(--primary-rgb), 0.03); /* Fondo hover suave */
    cursor: default;
}

/* Estilo para filas alternas */
.styled-table tbody tr:nth-child(even),
.formulas-table tbody tr:nth-child(even) {
    background-color: rgba(var(--primary-rgb), 0.015);
}

/* Quitar borde inferior última fila */
.styled-table tbody tr:last-child td,
.formulas-table tbody tr:last-child td {
    border-bottom: none;
}

/* Estilos específicos para las tablas de Fórmulas Gominolas */
.formulas-table th:first-child { /* Columna Nombre */
    width: 25%; /* Ancho sugerido */
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-color-dark));
}

.formulas-table td:nth-child(2) { /* Columna Descripción */
    width: 40%; /* Ancho sugerido */
    color: var(--text-color);
    font-weight: 500;
}

.formulas-table td:nth-child(3) { /* Columna Ingredientes */
    width: 35%; /* Ancho sugerido */
    font-size: 0.9rem; /* Letra un poco más pequeña */
    color: var(--grey-color);
    background-color: rgba(var(--primary-rgb), 0.01);
}

/* Estilos para h2 dentro de formulas-table-container */
.formulas-table-container h2 {
    font-size: 1.4rem;
    color: var(--primary-color);
    margin: 35px 0 20px;
    padding-left: 15px;
    border-left: 4px solid var(--accent-color);
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Nota: Estilos responsivos para tablas irán en responsive.css */ 