/* Estilos de la sección independiente Backup General y Restauración */

.backup-status-banner {
    background: linear-gradient(135deg, #0a2540 0%, #1e60a8 100%);
    color: #ffffff;
    border-radius: 14px;
    padding: 18px 22px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    box-shadow: 0 10px 24px -10px rgba(10, 37, 64, 0.4);
}

.backup-banner-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.backup-banner-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.16);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.45rem;
    flex-shrink: 0;
}

.backup-banner-left h2 {
    margin: 0 0 4px;
    font-family: 'Outfit', sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
}

.backup-banner-left p {
    margin: 0;
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.85);
}

.backup-banner-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.backup-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    font-size: 0.8rem;
    font-weight: 600;
}

.backup-workspace-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
}

@media (max-width: 1080px) {
    .backup-workspace-grid {
        grid-template-columns: 1fr;
    }
}

.backup-modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(185px, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.backup-module-stat {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 11px 13px;
}

.backup-module-stat-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
    font-size: 0.78rem;
    color: #64748b;
    font-weight: 600;
}

.backup-module-stat-val {
    font-family: 'Outfit', sans-serif;
    font-size: 1.35rem;
    font-weight: 800;
    color: #0f172a;
}

.backup-module-stat-sub {
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 2px;
}

.backup-options-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 16px;
}

.backup-check-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
}

.backup-check-row input {
    margin-top: 3px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.backup-check-row strong {
    display: block;
    font-size: 0.86rem;
    color: #0f172a;
}

.backup-check-row span {
    display: block;
    font-size: 0.78rem;
    color: #64748b;
    margin-top: 2px;
}

.backup-action-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-backup-primary {
    background: linear-gradient(135deg, #1e60a8, #0284c7);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 10px 18px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.btn-backup-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px -6px rgba(30, 96, 168, 0.55);
}

.btn-backup-primary:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none;
}

.btn-restore-danger {
    background: #dc2626;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 10px 18px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s ease;
}

.btn-restore-danger:hover {
    background: #b91c1c;
}

.btn-restore-danger:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.backup-dropzone {
    border: 2px dashed #94a3b8;
    border-radius: 12px;
    background: #f8fafc;
    padding: 26px 18px;
    text-align: center;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.backup-dropzone.drag-over {
    border-color: #1e60a8;
    background: #eff6ff;
}

.backup-dropzone i.fa-file-arrow-up {
    font-size: 2.2rem;
    color: #1e60a8;
    margin-bottom: 10px;
}

.backup-dropzone h4 {
    margin: 0 0 6px;
    font-size: 0.98rem;
    color: #0f172a;
}

.backup-dropzone p {
    margin: 0 0 14px;
    font-size: 0.82rem;
    color: #64748b;
}

.restore-preview-panel {
    margin-top: 16px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 16px;
    background: #ffffff;
}

.restore-integrity-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 0.86rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.restore-integrity-bar.is-valid {
    background: #ecfdf5;
    border: 1px solid #6ee7b7;
    color: #065f46;
}

.restore-integrity-bar.is-invalid {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    color: #991b1b;
}

.restore-meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
    gap: 8px;
    margin-bottom: 12px;
    font-size: 0.8rem;
    background: #f8fafc;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.restore-table-wrap {
    overflow-x: auto;
    margin-bottom: 14px;
}

.restore-compare-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.84rem;
}

.restore-compare-table th {
    background: #0a2540;
    color: #ffffff;
    text-align: left;
    padding: 8px 10px;
}

.restore-compare-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #e2e8f0;
}

.restore-mode-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 14px;
}

.restore-mode-title {
    font-weight: 700;
    font-size: 0.86rem;
    color: #0f172a;
    margin-bottom: 8px;
}

.restore-radio-opt {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 8px 10px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
}

.restore-radio-opt input {
    margin-top: 3px;
}

.restore-radio-opt strong {
    display: block;
    font-size: 0.84rem;
    color: #0f172a;
}

.restore-radio-opt span {
    display: block;
    font-size: 0.77rem;
    color: #64748b;
}

.restore-selective-boxes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-top: 6px;
}

@media (max-width: 640px) {
    .restore-selective-boxes {
        grid-template-columns: 1fr;
    }
}

.restore-selective-boxes label {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 0.8rem;
    color: #1e293b;
    cursor: pointer;
}

.backup-bottom-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 16px;
}

@media (max-width: 850px) {
    .backup-bottom-grid {
        grid-template-columns: 1fr;
    }
}

.backup-tool-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px 16px;
}

.backup-tool-card h4 {
    margin: 0 0 6px;
    font-size: 0.94rem;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.backup-tool-card p {
    margin: 0 0 12px;
    font-size: 0.82rem;
    color: #475569;
    line-height: 1.45;
}

.backup-cmd-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: #0f172a;
    color: #e2e8f0;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 0.78rem;
    overflow-x: auto;
}

.btn-copy-mini {
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    padding: 5px 10px;
    font-size: 0.75rem;
    cursor: pointer;
    flex-shrink: 0;
}

.btn-copy-mini:hover {
    background: rgba(255, 255, 255, 0.24);
}

/* Modal Confirmación */
.backup-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(3px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 16px;
}

.backup-modal-overlay.active {
    display: flex;
}

.backup-modal-box {
    background: #ffffff;
    border-radius: 14px;
    padding: 24px;
    max-width: 460px;
    width: 100%;
    text-align: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.backup-modal-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 12px;
    border-radius: 50%;
    background: #fef2f2;
    color: #dc2626;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
}

.backup-modal-box h3 {
    margin: 0 0 8px;
    font-size: 1.25rem;
    color: #0f172a;
}

.backup-modal-box p {
    margin: 0 0 18px;
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.45;
}

.backup-modal-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}
