.sf-public-body {
    background: #f5f7fb;
}

.sf-lookup-card {
    background: #f8fafc;
}

.sf-section-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #0d6efd;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
}

.sf-section {
    background: #fff;
}

.sf-field[style*="display: none"] {
    margin-bottom: 0 !important;
}

.sf-locked-field {
    background-color: #e9ecef !important;
    cursor: not-allowed;
}

.sf-locked-select .select2-selection {
    background-color: #e9ecef !important;
    cursor: not-allowed;
}

.select2-container--bootstrap-5 .select2-selection {
    min-height: 38px;
}

.form-check-label {
    cursor: pointer;
}

@media (max-width: 576px) {
    .card-body {
        padding: 1.25rem !important;
    }

    .sf-section-number {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
}

.sf-repeater-item {
    background: #fbfcfe;
}

.sf-repeater-empty {
    border: 1px dashed #ced4da;
    border-radius: 0.5rem;
    padding: 0.85rem;
    background: #fff;
}

.sf-repeater .select2-container {
    width: 100% !important;
}

/* Validación por paso */
.select2-container--bootstrap-5 .select2-selection.is-invalid,
.sf-options.is-invalid,
.sf-repeater.is-invalid .sf-repeater-items {
    border-color: #dc3545 !important;
}

.sf-options.is-invalid,
.sf-repeater.is-invalid .sf-repeater-items {
    border: 1px solid #dc3545;
    border-radius: .375rem;
    padding: .5rem;
}


.sf-course-card {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}
.sf-course-card .badge {
    white-space: normal;
}


/* Curso: versión completa y compacta */
.sf-course-card-full {
    transition: opacity .2s ease, transform .2s ease;
}

.sf-course-compact {
    background: #f8fafc;
}

.sf-course-compact .btn {
    white-space: nowrap;
}

@media (max-width: 576px) {
    .sf-course-compact {
        font-size: .95rem;
    }
}


/* Admin shell */
.sf-admin-body {
    background: #f5f7fb;
}

.sf-admin-shell {
    min-height: 100vh;
}

.sf-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 245px;
    background: #111827;
    color: #e5e7eb;
    display: flex;
    flex-direction: column;
    z-index: 1040;
}

.sf-sidebar-brand {
    padding: 1.25rem 1rem;
    font-weight: 700;
    font-size: 1.1rem;
    border-bottom: 1px solid rgba(255,255,255,.08);
}

.sf-sidebar-nav {
    padding: .75rem;
    display: flex;
    flex-direction: column;
    gap: .25rem;
}

.sf-sidebar-link {
    display: block;
    color: #d1d5db;
    text-decoration: none;
    padding: .65rem .8rem;
    border-radius: .45rem;
    font-size: .95rem;
}

.sf-sidebar-link:hover {
    color: #fff;
    background: rgba(255,255,255,.08);
}

.sf-sidebar-link.active {
    color: #fff;
    background: #0d6efd;
}

.sf-sidebar-footer {
    margin-top: auto;
    padding: .75rem;
    border-top: 1px solid rgba(255,255,255,.08);
}

.sf-admin-main {
    margin-left: 245px;
    min-height: 100vh;
}

.sf-admin-topbar {
    height: 64px;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
}

.sf-admin-content {
    padding: 1.5rem;
}

.sf-actions {
    display: flex;
    justify-content: flex-end;
    gap: .35rem;
    flex-wrap: wrap;
}

.sf-actions .btn {
    min-width: 76px;
}

.sf-table-fixed {
    table-layout: fixed;
}

.sf-table-fixed th:nth-child(1) { width: 20%; }
.sf-table-fixed th:nth-child(2) { width: 13%; }
.sf-table-fixed th:nth-child(3) { width: 17%; }
.sf-table-fixed th:nth-child(4) { width: 25%; }
.sf-table-fixed th:nth-child(5) { width: 8%; }
.sf-table-fixed th:nth-child(6) { width: 9%; }
.sf-table-fixed th:nth-child(7) { width: 8%; }

.sf-truncate {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 991.98px) {
    .sf-sidebar {
        transform: translateX(-100%);
        transition: transform .2s ease;
    }
    .sf-sidebar-open .sf-sidebar {
        transform: translateX(0);
    }
    .sf-admin-main {
        margin-left: 0;
    }
    .sf-admin-content {
        padding: 1rem;
    }
}

/* Dashboard */
.card .stretched-link:focus-visible {
    outline: 2px solid #0d6efd;
    outline-offset: 4px;
}

/* Public index */
.sf-public-container {
    max-width: 1120px;
}

.sf-public-category-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    box-shadow: 0 .35rem 1.25rem rgba(15, 23, 42, .05);
    padding: 1.25rem;
}

.sf-public-category-icon {
    width: 42px;
    height: 42px;
    border-radius: .9rem;
    background: #eff6ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex: 0 0 auto;
}

.sf-public-form-card {
    display: block;
    position: relative;
    height: 100%;
    min-height: 142px;
    text-decoration: none;
    color: #0f172a;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: .85rem;
    padding: 1rem 2.75rem 1rem 1rem;
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease, background .15s ease;
}

.sf-public-form-card:hover {
    color: #0f172a;
    background: #fff;
    border-color: #0d6efd;
    transform: translateY(-2px);
    box-shadow: 0 .45rem 1.1rem rgba(13, 110, 253, .12);
}

.sf-public-form-arrow {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    border: 1px solid #dbeafe;
    color: #0d6efd;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}

@media (max-width: 576px) {
    .sf-public-category-card {
        padding: 1rem;
    }
    .sf-public-form-card {
        min-height: auto;
    }
}

/* === Refinamientos categorías/tipos === */
.sf-sidebar-brand { letter-spacing: .01em; }
.sf-row-actions { display: inline-flex; flex-wrap: wrap; gap: .35rem; justify-content: flex-end; min-width: 190px; }
.sf-actions-table td { vertical-align: middle; }
.sf-icon-preview { display:inline-flex; align-items:center; justify-content:center; width:2rem; height:2rem; border-radius:.75rem; background:#f1f5f9; }
.sf-type-badge { border: 1px solid transparent; font-weight: 700; border-radius: 999px; padding: .32rem .55rem; }
.sf-type-inscripcion { background: #eef6ff; color: #075985; border-color: #bfdbfe; }
.sf-type-registro { background: #f1f5f9; color: #334155; border-color: #cbd5e1; }
.sf-type-general { background: #f8fafc; color: #475569; border-color: #e2e8f0; }

.sf-public-body { background: #f3f6fb; }
.sf-public-container { max-width: 1180px; }
.sf-public-category-card { background:#fff; border:1px solid #e2e8f0; border-radius:1rem; padding:1.35rem; box-shadow:0 14px 40px rgba(15,23,42,.06); }
.sf-public-category-icon { flex:0 0 auto; display:flex; align-items:center; justify-content:center; width:42px; height:42px; border-radius:14px; background:#eff6ff; font-size:1.2rem; }
.sf-public-form-card { position:relative; display:block; height:100%; min-height:165px; padding:1rem; border:1px solid #dbe3ee; border-radius:.85rem; color:#0f172a; background:#f8fafc; text-decoration:none; transition:all .16s ease-in-out; }
.sf-public-form-card:hover { transform:translateY(-2px); border-color:#0d6efd; box-shadow:0 12px 30px rgba(13,110,253,.10); }
.sf-public-form-arrow { display:inline-flex; align-items:center; justify-content:center; width:28px; height:28px; border-radius:999px; border:1px solid #bfdbfe; color:#0d6efd; background:#fff; font-weight:700; }
.sf-public-form-title { line-height:1.35; }
.sf-course-mini { border-top:1px dashed #d8e2ef; padding-top:.65rem; }
.sf-course-mini-title { font-size:.95rem; font-weight:700; color:#0f172a; }

@media (max-width: 991.98px) {
  .sf-row-actions { justify-content:flex-start; min-width:0; }
}

/* Public index v2 */
.sf-public-form-card-v2 {
    min-height: 230px;
    padding: 1.05rem;
}

.sf-public-form-card-v2 .sf-public-form-title {
    padding-right: 1.75rem;
    font-size: 1rem;
}

.sf-public-form-subtitle {
    color: #475569;
    font-size: .9rem;
    line-height: 1.4;
}

.sf-public-details {
    display: flex;
    flex-direction: column;
    gap: .55rem;
    margin-top: .75rem;
    padding-top: .85rem;
    border-top: 1px solid #e2e8f0;
}

.sf-public-detail-item {
    display: flex;
    align-items: flex-start;
    gap: .5rem;
    color: #334155;
    font-size: .88rem;
    line-height: 1.35;
}

.sf-public-detail-icon {
    width: 1.15rem;
    flex: 0 0 1.15rem;
    text-align: center;
}

.sf-public-detail-text {
    min-width: 0;
}

.sf-public-detail-label {
    display: block;
    color: #64748b;
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .03em;
    margin-bottom: .05rem;
}

@media (max-width: 576px) {
    .sf-public-form-card-v2 {
        min-height: auto;
    }
}

/* Login */
.sf-auth-body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(13, 110, 253, .12), transparent 30%),
        linear-gradient(180deg, #f6f8fc 0%, #eef3f9 100%);
}

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

.sf-auth-card {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: 1rem;
    padding: 2rem;
}

.sf-auth-logo {
    width: 56px;
    height: 56px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #0d6efd;
    color: #fff;
    font-weight: 800;
    font-size: 1.6rem;
    box-shadow: 0 12px 28px rgba(13, 110, 253, .25);
}

.sf-auth-card .form-control,
.sf-auth-card .btn {
    border-radius: .65rem;
}

.sf-auth-link {
    color: #475569;
    text-decoration: none;
}

.sf-auth-link:hover {
    color: #0d6efd;
    text-decoration: underline;
}

/* Dashboard estadístico */
.sf-dashboard-card {
    min-height: 112px;
}

.sf-dashboard-bars {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.sf-dashboard-bar-row {
    min-width: 0;
}

.sf-dashboard-bar-track {
    height: .65rem;
    background: #e9eef6;
    border-radius: 999px;
    overflow: hidden;
}

.sf-dashboard-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #0d6efd, #4f8cff);
    border-radius: 999px;
    min-width: 0;
}

.sf-dashboard-table th {
    color: #475569;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .03em;
    white-space: nowrap;
}

.sf-dashboard-table td {
    vertical-align: middle;
}


/* User box */
.sf-userbox {
    min-height: 42px;
}
.sf-user-avatar {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: #eef4ff;
    color: #0d6efd;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    border: 1px solid #dbeafe;
}
.sf-user-meta {
    line-height: 1.1;
    text-align: right;
}
.sf-user-name {
    font-size: .875rem;
    font-weight: 600;
    color: #111827;
}
.sf-user-role {
    font-size: .75rem;
    color: #6b7280;
    margin-top: .15rem;
}
.sf-logout-btn {
    margin-left: .25rem;
}
.sf-row-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: .35rem;
    flex-wrap: wrap;
}
.sf-row-actions .btn {
    min-width: 72px;
}

/* Estadísticas */
.sf-stat-kpi {
    min-height: 112px;
    border-radius: 1rem;
}
.sf-stat-kpi .card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.sf-stat-layout {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 1rem;
    grid-auto-flow: dense;
}

.sf-stat-grid-item {
    grid-column: span 4;
}

.sf-stat-card--hero {
    grid-column: span 8;
}

.sf-stat-card--wide {
    grid-column: span 6;
}

.sf-stat-card--medium {
    grid-column: span 4;
}

.sf-stat-card--compact {
    grid-column: span 4;
}

.sf-stat-card {
    overflow: hidden;
    border-radius: 1rem;
}

.sf-stat-card .card-body {
    padding: 1rem 1rem 1.1rem;
}

.sf-stat-card h2 {
    color: #0f172a;
}

.sf-stat-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .75rem;
}

.sf-stat-card-kicker {
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: .2rem;
}

.sf-stat-pill {
    flex-shrink: 0;
    padding: .35rem .65rem;
    border-radius: 999px;
    background: #eff6ff;
    color: #1d4ed8;
    font-size: .75rem;
    font-weight: 600;
    white-space: nowrap;
}

.sf-chart-wrap {
    position: relative;
    width: 100%;
    height: var(--sf-chart-height, 260px);
}

@media (max-width: 1399.98px) {
    .sf-stat-grid-item,
    .sf-stat-card--compact,
    .sf-stat-card--medium {
        grid-column: span 6;
    }
    .sf-stat-card--wide,
    .sf-stat-card--hero {
        grid-column: span 12;
    }
}

@media (max-width: 991.98px) {
    .sf-stat-layout {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .sf-stat-grid-item,
    .sf-stat-card--compact,
    .sf-stat-card--medium,
    .sf-stat-card--wide,
    .sf-stat-card--hero {
        grid-column: span 1;
    }
}

@media (max-width: 767.98px) {
    .sf-stat-layout {
        grid-template-columns: 1fr;
    }
    .sf-stat-grid-item,
    .sf-stat-card--compact,
    .sf-stat-card--medium,
    .sf-stat-card--wide,
    .sf-stat-card--hero {
        grid-column: 1 / -1;
    }
    .sf-stat-card-head {
        flex-direction: column;
        align-items: flex-start;
    }
    .sf-chart-wrap {
        height: min(320px, var(--sf-chart-height, 260px));
    }
}


/* Public cards: compact detail layout */
.sf-public-form-card-v2 {
    display: flex;
    flex-direction: column;
    min-height: 250px;
}

.sf-public-details {
    display: grid;
    grid-template-columns: 1fr;
    gap: .48rem;
    margin-top: .8rem;
    padding-top: .8rem;
    border-top: 1px solid #e2e8f0;
}

.sf-public-detail-item {
    display: grid;
    grid-template-columns: 1.15rem minmax(0, 1fr);
    gap: .45rem;
    align-items: start;
    color: #334155;
    font-size: .86rem;
    line-height: 1.35;
}

.sf-public-detail-icon {
    width: 1.15rem;
    line-height: 1.35;
    text-align: center;
    opacity: .9;
}

.sf-public-detail-text {
    min-width: 0;
}

.sf-public-detail-label {
    display: inline;
    color: #64748b;
    font-size: .72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .025em;
    margin: 0 .25rem 0 0;
}

.sf-public-detail-label::after {
    content: ':';
}

/* Editor JSON amplio */
.code-editor,
.sf-json-editor,
textarea[name="config_json"] {
    min-height: 560px !important;
    height: 62vh !important;
    max-height: 78vh;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: .875rem;
    line-height: 1.55;
    resize: vertical;
    tab-size: 2;
    white-space: pre;
}

@media (max-width: 991.98px) {
    .code-editor,
    .sf-json-editor,
    textarea[name="config_json"] {
        min-height: 420px !important;
        height: 55vh !important;
    }
}

@media (max-width: 575.98px) {
    .code-editor,
    .sf-json-editor,
    textarea[name="config_json"] {
        min-height: 360px !important;
        height: 50vh !important;
        font-size: .8rem;
    }
}


/* === Intranet v3: menú agrupado, tarjetas públicas, curso compacto, tesorería === */
.sf-sidebar-nav {
    overflow-y: auto;
    padding: .75rem .65rem;
}
.sf-sidebar-group {
    padding: .35rem 0 .65rem;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.sf-sidebar-group:last-child { border-bottom: 0; }
.sf-sidebar-heading {
    color: #94a3b8;
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    padding: .45rem .65rem .25rem;
}
.sf-sidebar-link {
    display: flex;
    align-items: center;
    gap: .55rem;
}
.sf-sidebar-link-icon {
    width: 1.2rem;
    flex: 0 0 1.2rem;
    text-align: center;
    opacity: .9;
}
.sf-public-form-card-v2 {
    min-height: 285px;
}
.sf-public-card-action .btn {
    border-radius: .65rem;
    font-weight: 700;
}
.sf-course-compact-public {
    background: #f8fafc;
}
.sf-course-compact-line {
    font-weight: 700;
    color: #0f172a;
    line-height: 1.35;
}
.sf-course-detail-inline {
    display: flex;
    flex-wrap: wrap;
    gap: .45rem .85rem;
    font-size: .9rem;
    color: #334155;
}
.sf-course-detail-chip {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    max-width: 100%;
}
.sf-dashboard-modules {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 1rem;
}
.sf-dashboard-module {
    grid-column: span 6;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    box-shadow: 0 .35rem 1.25rem rgba(15, 23, 42, .05);
    padding: 1rem;
}
.sf-dashboard-module:nth-child(3) {
    grid-column: span 12;
}
.sf-dashboard-module-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}
.sf-dashboard-kicker {
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: .72rem;
    font-weight: 800;
    margin-bottom: .15rem;
}
.sf-kpi-card {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: .85rem;
    padding: .9rem 1rem;
    min-height: 88px;
}
.sf-kpi-number {
    font-size: 2rem;
    line-height: 1.15;
    font-weight: 500;
    color: #0f172a;
}
.sf-kpi-money {
    font-size: 1.25rem;
    line-height: 1.25;
    font-weight: 800;
    color: #0f172a;
    word-break: break-word;
}
@media (max-width: 1199.98px) {
    .sf-dashboard-module,
    .sf-dashboard-module:nth-child(3) { grid-column: span 12; }
}
@media (max-width: 767.98px) {
    .sf-dashboard-modules { grid-template-columns: 1fr; }
    .sf-dashboard-module,
    .sf-dashboard-module:nth-child(3) { grid-column: 1 / -1; }
    .sf-dashboard-module-head { flex-direction: column; }
    .sf-course-detail-inline { flex-direction: column; gap: .4rem; }
    .sf-public-form-card-v2 { min-height: auto; }
}


/* === Intranet v4: menú formal tipo WordPress, ajustes responsivos === */
.sf-sidebar {
    width: 252px;
    background: #0f172a;
}
.sf-sidebar-brand {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.sf-admin-main {
    margin-left: 252px;
}
.sf-sidebar-nav {
    padding: .7rem .55rem;
    gap: .15rem;
}
.sf-nav-module {
    margin-bottom: .2rem;
}
.sf-nav-module-toggle {
    width: 100%;
    border: 0;
    background: transparent;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: .68rem .75rem;
    border-radius: .45rem;
    font-size: .94rem;
    text-align: left;
    transition: background .15s ease, color .15s ease;
}
.sf-nav-module-toggle:hover,
.sf-nav-module-toggle.active {
    background: rgba(255,255,255,.08);
    color: #fff;
}
.sf-nav-module-icon {
    width: 1.15rem;
    display: inline-flex;
    justify-content: center;
    color: #94a3b8;
    font-size: 1.02rem;
}
.sf-nav-module-toggle.active .sf-nav-module-icon,
.sf-nav-module-toggle:hover .sf-nav-module-icon {
    color: #fff;
}
.sf-nav-module-title {
    flex: 1 1 auto;
    min-width: 0;
}
.sf-nav-module-caret {
    color: #94a3b8;
    font-size: .75rem;
    transition: transform .18s ease;
}
.sf-nav-module-toggle[aria-expanded="true"] .sf-nav-module-caret {
    transform: rotate(180deg);
}
.sf-nav-submenu {
    padding: .15rem 0 .35rem 2.6rem;
}
.sf-nav-subitem {
    display: block;
    color: #cbd5e1;
    text-decoration: none;
    font-size: .9rem;
    padding: .45rem .65rem;
    border-radius: .4rem;
    position: relative;
}
.sf-nav-subitem::before {
    content: "";
    position: absolute;
    left: -.65rem;
    top: 50%;
    width: .35rem;
    height: 1px;
    background: rgba(203,213,225,.32);
}
.sf-nav-subitem:hover {
    color: #fff;
    background: rgba(255,255,255,.06);
}
.sf-nav-subitem.active {
    color: #fff;
    background: #0d6efd;
}
.sf-nav-public-link {
    display: flex;
    align-items: center;
    gap: .6rem;
    color: #cbd5e1;
    text-decoration: none;
    padding: .65rem .75rem;
    border-radius: .45rem;
}
.sf-nav-public-link:hover {
    color: #fff;
    background: rgba(255,255,255,.08);
}
.sf-sidebar-backdrop {
    display: none;
}
.sf-page-actions .btn {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

/* Curso compacto */
.sf-course-compact-public,
.sf-course-compact {
    padding: .7rem .85rem !important;
}
.sf-course-compact-line {
    font-size: .95rem;
}
.sf-course-compact-details {
    font-size: .9rem;
}
.sf-course-detail-inline {
    gap: .35rem .75rem;
}
.sf-course-detail-chip {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    padding: .25rem .55rem;
    line-height: 1.25;
}
@media (max-width: 767.98px) {
    .sf-course-detail-chip {
        width: 100%;
        border-radius: .65rem;
    }
}

/* Public cards: botón visible y ordenado */
.sf-public-form-card-v2 {
    padding: 1rem !important;
}
.sf-public-form-arrow {
    display: none;
}
.sf-public-card-action {
    margin-top: auto;
}

/* Tablas responsivas más limpias */
.sf-actions-table th,
.sf-actions-table td {
    vertical-align: middle;
}
.sf-row-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: .35rem;
    flex-wrap: wrap;
}

/* Admin forms */
@media (max-width: 991.98px) {
    .sf-sidebar {
        transform: translateX(-100%);
        transition: transform .2s ease;
        width: min(290px, 85vw);
    }
    .sf-sidebar-open .sf-sidebar {
        transform: translateX(0);
    }
    .sf-sidebar-open .sf-sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, .45);
        z-index: 1030;
    }
    .sf-admin-main {
        margin-left: 0;
    }
}


/* === v6 refinamientos visuales === */
.sf-nav-subitem::before {
    display: none !important;
}
.sf-nav-submenu {
    padding-left: 2.25rem;
}
.sf-public-detail-icon,
.sf-public-category-icon {
    color: #64748b;
}
.sf-public-category-icon i {
    font-size: 1.25rem;
    line-height: 1;
}
.sf-public-detail-icon i {
    font-size: .95rem;
    line-height: 1;
}
.sf-public-form-card .bi,
.sf-course-detail-chip .bi {
    color: #64748b;
}
.sf-academic-kpi {
    min-height: 96px;
}
.sf-attendance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: .75rem;
}
.sf-attendance-person {
    border: 1px solid #e5e7eb;
    border-radius: .75rem;
    padding: .75rem;
    background: #fff;
}
@media (max-width: 767.98px) {
    .sf-public-container {
        padding-top: 1.5rem !important;
        padding-bottom: 1.5rem !important;
    }
    .sf-public-category-card {
        padding: 1rem !important;
    }
}


/* === v9 asistencia de células === */
.sf-attendance-toggle {
    flex-wrap: wrap;
    gap: .25rem;
}
.sf-attendance-toggle .btn {
    border-radius: .375rem !important;
}
@media (max-width: 991.98px) {
    .sf-attendance-toggle {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }
}

/* === v14 estándar visual de acciones y reportes === */
.sf-page-actions .btn,
.sf-page-actions.btn,
.sf-toolbar-actions .btn {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.sf-page-actions .btn-sm {
    min-height: 32px;
}
