body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #ffffff;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 40px;
    background-color: #3463A4;
}

.logo img {
    height: 40px;
}

.icon-svg {
    fill: #fefefe;
}

h1 {
    font-size: 1.5em;
    color: #fff;
}

.container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 2rem;
    background-color: #fff;
    border-radius: 5px;
}

h2 {
    color: #3463A4;
    font-size: 1.2em;
    border-bottom: 2px solid #3463A4;
    padding-bottom: 5px;
    margin-bottom: 20px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px 20px;
    margin-bottom: 20px;
}

.form-grid div {
    display: flex;
    flex-direction: column;
}

label {
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

input:disabled {
    background-color: #e9ecef;
}

.input-container {
    position: relative;
    display: inline-block;
    width: 100%;
    /* max-width: 350px; */
}


.input-container input {
    width: 100%;
    padding: 8px 12px 8px 36px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}


.input-container img {
    position: absolute;
    left: 8px;
    top: 1rem;
    transform: translateY(-50%);
    width: 1.4rem;
    height: 1.4rem;
    filter: opacity(50%);
    pointer-events: none;
}


.tooltip {
    position: absolute;
    bottom: -35px;
    left: 0;
    background-color: #333;
    color: #fff;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 12px;
    opacity: 0;
    transform: scale(0.95);
    transform-origin: top left;
    transition: opacity 0.2s ease, transform 0.2s ease;
    white-space: nowrap;
    pointer-events: none;
}


.input-container:hover .tooltip,
.input-container:focus-within .tooltip {
    opacity: 1;
    transform: scale(1);
}


.tooltip::after {
    content: '';
    position: absolute;
    top: -.2rem;
    left: 10px;
    width: 8px;
    height: 8px;
    background: #333;
    transform: rotate(45deg);
}

.button-group {
    justify-content: flex-end;
    align-items: flex-end;
}

button:disabled {
    background-color: #ccc;
    color: #666;
    cursor: not-allowed;
    opacity: 0.7;
}

.btn {
    display: flex;
    justify-content: space-between;
    align-self: center;
    padding: .4rem .5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
    color: #fff;
}

.btn p {
    margin: 0 .8rem;
    margin-top: .2rem;
}

.btn-icon {
    padding: .3rem .5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
    color: #fff;
}

#prev-page-btn,
#next-page-btn {
    color: #004a99;
}

#agregar-beneficiario-modal-btn,
#agregar-beneficiario-btn {
    background-color: #004a99;
}

.actions {
    display: flex;
    justify-content: end;
    gap: 10px;
    margin-bottom: 20px;
}

@media (max-width: 800px) {
    .actions button p {
        display: none;
    }

    header .logo img {
        display: none !important;
    }

    .actions #add-column-btn {
        min-width: auto !important;
    }
}

.btn-secondary {
    background-color: #D7ECFE;
    color: #3667AA;
    font-weight: 600;
}

.btn-warning {
    background-color: #F0D228;
    color: #333;
}

.btn-success {
    background-color: #5fb172;
    color: #fff;
    font-weight: 600;
}

.btn-danger {
    background-color: #dc3545;
}

.table-container {
    width: 100%;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: .2rem;
}

th,
td {
    border: 1px solid #ddd;
    padding: .2rem;
}

th {
    background-color: #F7F7F8;
    color: #3f3f3f;
    text-align: center;
    padding: .6rem 0;
}

textarea {
    width: 100%;
    height: 120px;
    box-sizing: border-box;
    margin-bottom: 10px;
}

.controls {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    margin-bottom: 20px;
}

#toTable {
    background-color: #007bff;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 5px;
}

.close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close-button:hover,
.close-button:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.btn-danger {
    background-color: #dc3545;
}

.tooltip-error {
    position: absolute;
    display: none;
    padding: 8px;
    background-color: #333;
    color: #fff;
    border-radius: 4px;
    font-size: 0.9em;
    z-index: 10;
}

.tooltip-error::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: #333 transparent transparent transparent;
}

.cell-error {
    background-color: #FFCCCB !important;
}

.cell-duplicate {
    background-color: yellow !important;
}

.c-pointer {
    cursor: pointer;
}

.pagination-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 5px;
}

.page-numbers {
    display: inline-flex;
}

.page-numbers button {
    margin: 0 2px;
}

.page-numbers button.active {
    background-color: #004a99;
    color: #fff;
    font-weight: bold;
}

.pagination-summary {
    display: flex;
    align-items: center;
    gap: 10px;
}

.form-select {
    padding: 5px;

    #custom-alert-modal .modal-content {
        text-align: center;
    }

    #custom-alert-close-btn {
        background-color: #007bff;
        margin-top: 15px;
    }

    border-radius: 4px;
    border: 1px solid #ccc;
}

/* --- Navegación de Pestañas (Botones) --- */
.tabs-nav {
    display: flex;
    border-bottom: 1px solid #e5e7eb;
    /* Equivalente a border-gray-200 */
}

.tab-button {
    padding: 0.75rem 1.5rem;
    /* Equivalente a py-3 px-6 */
    font-weight: 500;
    /* Equivalente a font-medium */
    color: #4b5563;
    /* Equivalente a text-gray-700 */
    background-color: transparent;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s, border-bottom-color 0.2s;

    /* Borde inferior para el estado activo */
    border-bottom: 2px solid transparent;
    /* Corregir el desplazamiento de 1px por el borde */
    margin-bottom: -1px;
}

.tab-button:hover {
    background-color: #f9fafb;
    /* Equivalente a hover:bg-gray-50 */
}

.tab-button:focus {
    /* Estilo de foco simple */
    outline: 2px solid #3b82f6;
    outline-offset: -2px;
}

/* Estado activo del botón */
.tab-button.active {
    color: #2563eb;
    /* Equivalente a text-blue-600 */
    border-bottom-color: #3b82f6;
    /* Equivalente a border-blue-500 */
    background-color: #eff6ff;
    /* Equivalente a bg-blue-50 */
}

/* --- Contenido de las Pestañas --- */
.tabs-content {
    padding: 1.5rem 0;
    /* Equivalente a p-6 */
}

.tab-panel {
    background-color: #ececec;
    padding: 1.2rem;
    border-radius: .5rem;
}

/* Clase 'hidden' que JS usará para ocultar paneles */
.tab-panel.hidden {
    display: none;
}

/* --- Estilos del Contenido Interno --- */
.tab-panel h2 {
    font-size: 1.2rem;
    /* Equivalente a text-2xl */
    font-weight: 700;
    /* Equivalente a font-bold */
    color: #1f2937;
    /* Equivalente a text-gray-800 */
    margin-top: 0;
    margin-bottom: 0.75rem;
    /* Equivalente a mb-3 */
}

.tab-panel p {
    color: #4b5563;
    /* Equivalente a text-gray-600 */
    line-height: 1.6;
    margin-top: 1rem;
}

.tab-panel p:first-child {
    margin-top: 0;
}

.tab-panel ul {
    list-style-type: disc;
    list-style-position: inside;
    margin-top: 1rem;
    /* Equivalente a mt-4 */
    padding-left: 0.5rem;
    color: #4b5563;
    /* Equivalente a text-gray-600 */
}