:root {
    --green-700: #2e7d32;
    --green-600: #388e3c;
    --gray-50: #f7f8f6;
    --gray-200: #e2e5e0;
    --gray-700: #3a3f38;
    --red-600: #c62828;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, "Segoe UI", Roboto, sans-serif;
    background: var(--gray-50);
    color: var(--gray-700);
}

.center-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    padding: 2rem;
    width: 100%;
    max-width: 380px;
}

.card h1 {
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
}

label {
    display: block;
    font-size: 0.85rem;
    margin-bottom: 0.35rem;
    font-weight: 600;
}

/* Estilo base de todos los controles de formulario (text, email, password,
   number, date, tel, file, textarea, select). :where() deja la especificidad
   en 0 para que las variantes compactas (.line-row, .search-bar) la pisen. */
:where(input:not([type="checkbox"], [type="radio"], [type="hidden"], [type="submit"], [type="button"], [type="range"], [type="color"]), select, textarea) {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    border: 1px solid var(--gray-200);
    background-color: #fff;
    color: var(--gray-700);
    margin-bottom: 1.1rem;
    font-family: inherit;
    font-size: 1rem;
    line-height: 1.25;
}

:where(input, select, textarea):focus {
    outline: none;
    border-color: var(--green-600);
    box-shadow: 0 0 0 3px rgba(56, 142, 60, 0.15);
}

:where(input, select, textarea):disabled { background-color: var(--gray-50); color: #6b6f68; }

:where(textarea) { min-height: 6rem; resize: vertical; }

:where(select) {
    -webkit-appearance: none;
    appearance: none;
    padding-right: 2.5rem;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%233a3f38' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
}

:where(input[type="file"]) { padding: 0.65rem 0.85rem; cursor: pointer; }

.btn {
    display: inline-block;
    width: 100%;
    padding: 0.95rem 1rem;
    border-radius: 10px;
    border: none;
    background: var(--green-700);
    color: #fff;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
}

.btn:hover { background: var(--green-600); }
.btn.danger { background: var(--red-600); }
.btn.danger:hover { background: #b02a2a; }

.error {
    background: #fdecea;
    color: var(--red-600);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.info {
    background: #e8f5e9;
    color: var(--green-700);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.topbar {
    background: #fff;
    padding: 1rem 1.5rem;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.topbar-left { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }

.topnav { display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; }
.topnav a { color: var(--gray-700); text-decoration: none; font-size: 0.9rem; font-weight: 600; }
.topnav a:hover { color: var(--green-700); }

.container { padding: 1.5rem; max-width: 1100px; margin: 0 auto; }

.kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }

.kpi-card { background: #fff; border-radius: 14px; padding: 1.25rem; box-shadow: 0 2px 10px rgba(0,0,0,0.05); }

.kpi-card .value { font-size: 1.8rem; font-weight: 700; color: var(--green-700); }

.kpi-card .label { font-size: 0.85rem; color: #6b6f68; }

table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; }

th, td { text-align: left; padding: 0.75rem 1rem; border-bottom: 1px solid var(--gray-200); font-size: 0.9rem; }

.messages { max-width: 1100px; margin: 1rem auto 0; padding: 0 1.5rem; }
.message { padding: 0.75rem 1rem; border-radius: 10px; margin-bottom: 0.75rem; font-size: 0.9rem; }
.message.success { background: #e8f5e9; color: var(--green-700); }
.message.error { background: #fdecea; color: var(--red-600); }

.page-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.page-header h1 { font-size: 1.3rem; margin: 0; }

.btn-sm { display: inline-block; padding: 0.4rem 0.85rem; border-radius: 8px; font-size: 0.85rem; font-weight: 600; text-decoration: none; }
.btn-sm.primary { background: var(--green-700); color: #fff; }
.btn-sm.danger { background: #fdecea; color: var(--red-600); border: none; cursor: pointer; }
.btn-sm.neutral { background: var(--gray-200); color: var(--gray-700); }

.form-card { background: #fff; border-radius: 16px; padding: 2rem; max-width: 480px; box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); }
.errorlist { list-style: none; padding: 0; margin: -0.75rem 0 1rem; color: var(--red-600); font-size: 0.85rem; }
.checkbox-row { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1.1rem; }
.checkbox-row input { width: auto; margin: 0; }
.back-link { display: inline-block; margin-bottom: 1rem; color: var(--gray-700); text-decoration: none; font-size: 0.9rem; }
.new-voucher-menu { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.search-bar { display: flex; gap: 0.5rem; margin-bottom: 1rem; max-width: 420px; }
.search-bar input, .search-bar select { padding: 0.6rem 0.85rem; border-radius: 8px; font-size: 0.9rem; margin: 0; }
.search-bar input { flex: 1; }
.search-bar select { width: auto; padding-right: 2.25rem; background-position: right 0.85rem center; }
.search-bar input[type="date"] { flex: none; width: auto; }
.pagination { display: flex; gap: 1rem; align-items: center; margin-top: 1rem; font-size: 0.85rem; }
.pagination a { color: var(--green-700); text-decoration: none; font-weight: 600; }
.formset-section { margin-top: 1.5rem; }
.formset-section h2 { font-size: 1.05rem; margin-bottom: 0.5rem; }
.delete-checkbox-wrap { display: none; }

.autocomplete { position: relative; }
.autocomplete-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 20;
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
    max-height: 220px;
    overflow-y: auto;
    margin-top: 2px;
}
.autocomplete-item { padding: 0.55rem 0.75rem; font-size: 0.9rem; cursor: pointer; }
.autocomplete-item:hover { background: var(--gray-50); }
.autocomplete-hint { font-size: 0.8rem; color: #6b6f68; margin: 0.2rem 0 0.75rem; }
.line-row td { vertical-align: middle; }
.line-row select, .line-row input, .line-row textarea { width: 100%; min-width: 5rem; padding: 0.55rem 0.7rem; margin: 0; border-radius: 8px; font-size: 0.9rem; }
.line-row select { padding-right: 2rem; background-position: right 0.7rem center; }
.line-row input[type="checkbox"] { width: auto; min-width: 0; }

/* ---------- Responsive ---------- */

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: 12px; }
.page-header { flex-wrap: wrap; gap: 0.75rem; }
.search-bar { flex-wrap: wrap; }

/*
 * Filas de formsets (impuestos, líneas, información adicional...): en vez de
 * una tabla horizontal (una de 8 columnas no cabe ni en escritorio), cada fila
 * es una tarjeta con una grilla que se acomoda al ancho disponible, con la
 * etiqueta de cada campo encima (data-label, ver labelFormsetCells).
 */
.formset-section table,
.formset-section tbody,
.formset-section tr,
.formset-section td { display: block; }
.formset-section table { background: transparent; border-radius: 0; overflow: visible; }
.formset-section thead { display: none; }
.formset-section td { padding: 0; border: 0; font-size: 0.9rem; }

.formset-section tr.line-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
    gap: 0.85rem 1rem;
    align-items: start;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 0.75rem;
}
.formset-section tr.line-row > td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
}
.formset-section .line-subtotal { font-weight: 600; padding-top: 0.15rem; }
/* Celda con el buscador de producto/cliente: más ancha, ocupa 2 columnas */
.formset-section tr.line-row > td:has(.autocomplete) { grid-column: span 2; }
/* Botón Eliminar: última celda, a la derecha, en su propia línea si hace falta */
.formset-section tr.line-row > td:last-child { grid-column: 1 / -1; text-align: right; }
.formset-section tr:not(.line-row) td { margin: -0.4rem 0 0.75rem; }

@media (max-width: 600px) {
    .container { padding: 1rem; }
    .messages { padding: 0 1rem; }
    .topbar { padding: 0.75rem 1rem; }
    .form-card { padding: 1.25rem; border-radius: 14px; }
    .formset-section tr.line-row { grid-template-columns: 1fr; padding: 0.85rem; }
    .formset-section tr.line-row > td:has(.autocomplete) { grid-column: auto; }
    /* 16px evita el zoom automático de iOS al enfocar un campo */
    :where(input, select, textarea),
    .line-row input, .line-row select, .line-row textarea,
    .search-bar input, .search-bar select { font-size: 1rem; }
    .search-bar > * { flex: 1 1 100%; width: 100%; }
    .btn-sm { padding: 0.55rem 1rem; }
}

/* Campos sueltos en grilla (documento sustento del comprobante de retención) */
.field-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: 0.25rem 1rem; }
.field-grid .field[hidden] { display: none; }
.field-grid .field :where(input, select, textarea) { margin-bottom: 0.4rem; }
.field-grid .errorlist { margin: 0 0 0.6rem; }
.field label .req { color: var(--red-600); }

/* ---------- Asistente de retención (templates/vouchers/retencion_guiada.html) ---------- */
.guiada-intro { font-size: 0.9rem; color: #5b5f58; margin: 0 0 1.25rem; line-height: 1.5; }
.guiada-intro a { color: var(--green-700); font-weight: 600; }
.guiada .paso { border-top: 1px solid var(--gray-200); padding-top: 1.25rem; margin-top: 1.25rem; }
.guiada .paso:first-of-type { border-top: 0; margin-top: 0; padding-top: 0; }
.guiada .paso h2 { display: flex; align-items: center; gap: 0.6rem; font-size: 1.1rem; margin: 0 0 0.75rem; }
.guiada .paso-num {
    display: inline-flex; align-items: center; justify-content: center; flex: none;
    width: 1.7rem; height: 1.7rem; border-radius: 50%;
    background: var(--green-700); color: #fff; font-size: 0.9rem; font-weight: 700;
}
.guiada .subtitulo { font-size: 0.95rem; margin: 1rem 0 0.5rem; }
.guiada .mas-datos { margin: 0.5rem 0 0.75rem; }
.guiada .mas-datos > summary { cursor: pointer; font-size: 0.85rem; font-weight: 600; color: var(--green-700); padding: 0.35rem 0; }
.guiada .mas-datos[open] > summary { margin-bottom: 0.5rem; }
.guiada .autocomplete-hint { margin: 0.2rem 0 0.75rem; }

.totales-doc, .resumen-ret {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: 0.75rem;
    background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 12px; padding: 0.85rem 1rem; margin-top: 0.75rem;
}
.totales-doc div, .resumen-ret div { display: flex; flex-direction: column; gap: 0.15rem; }
.totales-doc span, .resumen-ret span { font-size: 0.8rem; color: #6b6f68; }
.totales-doc strong, .resumen-ret strong { font-size: 1.15rem; }
.resumen-ret strong { color: var(--green-700); }

.sugerencia {
    margin-top: 0.75rem; padding: 0.85rem 1rem; border-radius: 12px;
    background: #e8f5e9; border: 1px solid #c8e6c9; font-size: 0.9rem; line-height: 1.5;
}
.sugerencia ul { margin: 0.4rem 0 0.25rem; padding-left: 1.1rem; }
.sugerencia .muted { color: #5b5f58; }
.sugerencia .sug-aviso { margin: 0.4rem 0 0; color: #7a4a00; }
.sugerencia button { margin-top: 0.5rem; }

.guiada .formset-section tr.line-row { grid-template-columns: minmax(0, 3fr) repeat(3, minmax(6rem, 1fr)); }
.guiada .line-row .errorlist { margin: 0.25rem 0 0; }
.guiada .line-row input[readonly] { background: var(--gray-50); color: #5b5f58; }
.guiada .valor-out { display: block; font-weight: 700; font-size: 1.05rem; padding-top: 0.4rem; }
.guiada .manual-code { margin-top: 0.4rem; }

.avisos { list-style: none; padding: 0; margin: 0.75rem 0 0; display: grid; gap: 0.4rem; }
.aviso { padding: 0.6rem 0.85rem; border-radius: 10px; font-size: 0.85rem; line-height: 1.4; }
.aviso-warn { background: #fff4e0; color: #7a4a00; }
.aviso-error { background: #fdecea; color: var(--red-600); }
.aviso-info { background: #e8f5e9; color: #1b5e20; margin: 0 0 1.25rem; }

@media (max-width: 600px) {
    .guiada .formset-section tr.line-row { grid-template-columns: 1fr; }
}

/* Panel de totales (formularios y detalle de Factura/Nota de Crédito/Liquidación) */
.totals-panel { margin: 1.5rem 0 0 auto; max-width: 380px; background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 12px; padding: 1rem 1.25rem; }
.totals-panel h2 { font-size: 1.05rem; margin: 0 0 0.5rem; }
.totals-panel.totals-static { margin-top: 1rem; }
.totals-table { background: transparent; border-radius: 0; }
.totals-table td { padding: 0.35rem 0; border: 0; font-size: 0.9rem; }
.totals-table td:last-child { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.totals-table .totals-input input { width: 8rem; margin: 0; text-align: right; padding: 0.4rem 0.6rem; }
.totals-table .totals-input .errorlist { margin: 0.25rem 0 0; }
.totals-table tbody + tbody tr:first-child td { border-top: 1px solid var(--gray-200); }
.totals-table .totals-grand td { font-size: 1.15rem; font-weight: 700; color: var(--green-700); padding-top: 0.6rem; }
.totals-note { font-size: 0.75rem; color: #6b6f68; margin: 0.6rem 0 0; }
.totals-note.is-error { color: var(--red-600); }
.totals-panel.is-loading .totals-table { opacity: 0.55; }
@media (max-width: 600px) { .totals-panel { max-width: none; } }

/* Menú de usuario de la barra superior (<details>, sin JS para abrir/cerrar salvo el cierre al hacer clic fuera). */
.user-menu { position: relative; }
.user-menu summary {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    cursor: pointer;
    padding: 0.3rem 0.6rem 0.3rem 0.3rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    user-select: none;
}
.user-menu summary::-webkit-details-marker { display: none; }
.user-menu summary:hover, .user-menu[open] summary { background: var(--gray-50); }
.user-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--green-700);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}
.user-summary-text { max-width: 14rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-caret { width: 0; height: 0; border-left: 4px solid transparent; border-right: 4px solid transparent; border-top: 5px solid var(--gray-700); }
.user-menu-panel {
    position: absolute;
    right: 0;
    top: calc(100% + 0.4rem);
    min-width: 15rem;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.14);
    padding: 0.4rem 0;
    z-index: 50;
}
.user-menu-header { display: flex; flex-direction: column; gap: 0.15rem; padding: 0.6rem 1rem 0.75rem; border-bottom: 1px solid var(--gray-200); margin-bottom: 0.3rem; }
.user-menu-email { font-size: 0.8rem; color: #6b6f68; overflow-wrap: anywhere; }
.user-menu-role { align-self: flex-start; margin-top: 0.25rem; font-size: 0.75rem; font-weight: 600; background: #e8f5e9; color: var(--green-700); padding: 0.1rem 0.55rem; border-radius: 999px; }
.user-menu-panel a, .user-menu-panel button {
    display: block;
    width: 100%;
    padding: 0.55rem 1rem;
    background: none;
    border: none;
    text-align: left;
    font: inherit;
    font-size: 0.9rem;
    color: var(--gray-700);
    text-decoration: none;
    cursor: pointer;
}
.user-menu-panel a:hover, .user-menu-panel button:hover { background: var(--gray-50); }
.user-menu-panel form { margin: 0; border-top: 1px solid var(--gray-200); margin-top: 0.3rem; padding-top: 0.3rem; }
.user-menu-panel form button { color: var(--red-600); }

@media (max-width: 600px) {
    .user-summary-text { display: none; }
}

/* ---------- Factura simplificada (templates/vouchers/factura_guiada.html) ---------- */
.acciones-cliente, .acciones-lineas { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.5rem 0 1rem; }
.acciones-lineas { margin-top: 0.75rem; }
.guiada .btn-mini { font-size: 0.7rem; padding: 0.15rem 0.4rem; margin-top: 0.25rem; }
/* El descuento por línea solo se muestra si el usuario lo pide (o ya hay uno cargado). */
#lines-table:not(.show-desc) .col-desc { display: none; }
.radio-inline { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin-bottom: 0.75rem; }
.radio-opt { display: inline-flex; align-items: center; gap: 0.4rem; font-weight: 400; font-size: 0.95rem; margin: 0; cursor: pointer; }
.radio-opt input { width: auto; margin: 0; }

/* ---------- Guía de remisión (templates/vouchers/guia_guiada.html, guia_remision_form.html) ---------- */
/* Productos de la guía: producto, cantidad y quitar en una sola fila (sin precios ni descuento). */
.formset-section.guia-prod tr.line-row { grid-template-columns: minmax(0, 3fr) minmax(6rem, 1fr) auto; align-items: end; }
.formset-section.guia-prod tr.line-row > td:has(.autocomplete),
.formset-section.guia-prod tr.line-row > td:last-child { grid-column: auto; }
/* Modo completo: cada destinatario es una tarjeta con sus propios productos. */
.dest-card { border: 1px solid var(--gray-200); border-radius: 12px; padding: 1rem; margin-bottom: 1rem; }
.dest-card-head { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; margin-bottom: 0.75rem; }
.dest-card-head h3 { font-size: 1rem; margin: 0; }
.dest-card .formset-section { margin-top: 0.75rem; }
@media (max-width: 600px) {
    .formset-section.guia-prod tr.line-row { grid-template-columns: 1fr; }
    .formset-section.guia-prod tr.line-row > td:last-child { text-align: right; }
}

/* ---------- Establecimientos y puntos de emisión (templates/accounts/company_series.html) ---------- */
.series-page button.btn-sm { border: 0; cursor: pointer; font-family: inherit; }
.series-intro { background: #fff; border-radius: 12px; padding: 1rem 1.25rem; margin-bottom: 1.25rem; font-size: 0.9rem; }
.series-intro p { margin: 0 0 0.75rem; }
.series-example { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 0.5rem; margin: 0 !important; }
.series-example span { display: flex; flex-direction: column; background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 8px; padding: 0.4rem 0.75rem; }
.series-example b { font-size: 1.05rem; font-variant-numeric: tabular-nums; color: var(--green-700); }
.series-example small { font-size: 0.72rem; color: #6b6f68; }
.series-example i { font-style: normal; font-weight: 700; padding-top: 0.55rem; }

.series-card { background: #fff; border-radius: 14px; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05); padding: 1.25rem; margin-bottom: 1.25rem; }
.series-card.is-inactive { opacity: 0.75; }
.series-card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.75rem; margin-bottom: 1rem; }
.series-card-title { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; min-width: 0; }
.series-card-title strong { font-size: 1.05rem; overflow-wrap: anywhere; }
.series-subtitle { font-size: 0.95rem; margin: 1.25rem 0 0.6rem; }
.series-card > .series-subtitle:first-child { margin-top: 0; }

.serie-code { display: inline-block; background: #e8f5e9; color: var(--green-700); font-weight: 700; font-variant-numeric: tabular-nums; border-radius: 6px; padding: 0.15rem 0.5rem; font-size: 0.9rem; }
.status-pill { font-size: 0.72rem; font-weight: 600; border-radius: 999px; padding: 0.15rem 0.6rem; }
.status-pill.on { background: #e8f5e9; color: var(--green-700); }
.status-pill.off { background: var(--gray-200); color: #6b6f68; }

.series-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 0.75rem 1rem; align-items: end; }
.series-fields input { margin-bottom: 0; }
.series-fields .btn-sm { justify-self: start; padding: 0.7rem 1.1rem; }
.series-fields.add-point { margin-top: 0.85rem; padding-top: 0.85rem; border-top: 1px dashed var(--gray-200); }

.point-list { list-style: none; margin: 0; padding: 0; }
.point-row { display: flex; align-items: center; gap: 0.75rem; padding: 0.55rem 0; border-bottom: 1px solid var(--gray-200); }
.point-row:last-child { border-bottom: 0; }
.point-row.is-inactive .point-name { color: #6b6f68; }
.point-name { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 0.9rem; }
.point-row form { margin: 0; }

.seq-form { display: flex; gap: 0.5rem; align-items: center; margin: 0; }
.seq-form input { width: 9rem; margin: 0; padding: 0.5rem 0.7rem; }
.seq-table td { vertical-align: middle; }

@media (max-width: 600px) {
    .series-card { padding: 1rem; }
    .series-card-head form, .series-card-head .btn-sm { width: 100%; text-align: center; }
    .series-fields { grid-template-columns: 1fr; }
    .series-fields .btn-sm { justify-self: stretch; text-align: center; }
    .point-row { flex-wrap: wrap; }
    .point-name { flex-basis: calc(100% - 6rem); }
    .point-row .btn-sm { padding: 0.5rem 0.85rem; }
    /* Secuenciales: cada fila de la tabla pasa a ser una tarjeta con etiquetas */
    .seq-table, .seq-table tbody, .seq-table tr, .seq-table td { display: block; }
    .seq-table { background: transparent; overflow: visible; }
    .seq-table thead { display: none; }
    .seq-table tr { background: #fff; border-radius: 12px; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05); padding: 0.5rem 1rem; margin-bottom: 0.75rem; }
    .seq-table td { display: flex; justify-content: space-between; align-items: center; gap: 1rem; border-bottom: 1px solid var(--gray-200); padding: 0.6rem 0; }
    .seq-table td:last-child { border-bottom: 0; }
    .seq-table td::before { content: attr(data-label); font-size: 0.8rem; font-weight: 600; color: #6b6f68; flex: none; }
    .seq-form { flex: 1; justify-content: flex-end; }
    .seq-form input { flex: 1; min-width: 0; width: auto; }
}
