/*
 * La simulazione dell'interfaccia di NetScaler-Flows (pagina /solutions/netscaler-flows/demo, dentro
 * un iframe della landing). Colori e misure vengono da src/App.css e src/App.tsx del repository
 * NetScaler-Flows: testata e barra laterale petrolio, mappa su fondo a puntini, un colore per tipo di
 * oggetto (typeColors), pannello di ns.conf in basso. La mappa non e' React Flow: e' ridisegnata qui
 * con HTML e SVG, con la stessa disposizione dall'alto in basso.
 */

:root {
    --nf-primary: #003d48;
    --nf-primary-light: #005566;
    --nf-accent: #bef0ed;
    --nf-accent-dark: #8dd8d3;
    --nf-bg: #f3f3f3;
    --nf-border: #d0d0d0;
    --nf-text: #333333;
    --nf-text-light: rgba(255, 255, 255, .7);
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }

body {
    overflow: hidden;
    background: var(--nf-primary);
    color: var(--nf-text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

button { font: inherit; }
:focus-visible { outline: 2px solid var(--nf-accent-dark); outline-offset: 1px; }
#nf-app { display: flex; flex-direction: column; height: 100%; }

/* ---------------------------------------------------------------- testata */
.nf-header { display: flex; flex: 0 0 auto; align-items: center; gap: 14px; height: 56px; padding: 0 16px; background: var(--nf-primary); color: #fff; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.nf-title { min-width: 0; margin-right: 50px; overflow: hidden; font-size: 19px; font-weight: 600; letter-spacing: .2px; text-overflow: ellipsis; white-space: nowrap; }
.nf-title small { margin-left: 6px; color: var(--nf-text-light); font-size: 11px; font-weight: 400; }
.nf-dd { position: relative; flex-shrink: 0; }
.nf-dd-btn { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border: 1px solid rgba(255, 255, 255, .3); border-radius: 4px; background: transparent; color: #fff; font-size: 13px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: background .2s, border-color .2s; }
.nf-dd-btn svg { width: 16px; height: 16px; }
.nf-dd-btn:hover { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .5); }
.nf-dd-f5 .nf-dd-btn { border-color: rgba(224, 32, 32, .5); }
.nf-dd-f5 .nf-dd-btn:hover { background: rgba(224, 32, 32, .2); border-color: #e02020; }
.nf-arrow { margin-left: 4px; font-size: 10px; opacity: .7; }
.nf-dd-menu { position: absolute; top: 100%; left: 0; z-index: 30; display: none; min-width: 210px; margin-top: 4px; overflow: hidden; border: 1px solid rgba(255, 255, 255, .2); border-radius: 6px; background: var(--nf-primary); box-shadow: 0 8px 24px rgba(0, 0, 0, .3); }
.nf-dd.open .nf-dd-menu { display: block; }
.nf-dd-menu button { display: block; width: 100%; padding: 10px 16px; border: 0; background: none; color: #fff; font-size: 13px; text-align: left; cursor: pointer; }
.nf-dd-menu button + button { border-top: 1px solid rgba(255, 255, 255, .1); }
.nf-dd-menu button:hover { background: var(--nf-primary-light); }
.nf-dd-menu .nf-reset { color: #ff8a95; }
.nf-dd-menu .nf-reset:hover { background: rgba(220, 53, 69, .2); }
.nf-loading { display: flex; align-items: center; gap: 14px; padding: 4px 12px; border: 1px solid rgba(190, 240, 237, .3); border-radius: 6px; background: rgba(190, 240, 237, .15); }
.nf-loading-info { display: flex; flex-direction: column; gap: 2px; }
.nf-loading-msg { color: var(--nf-accent); font-size: 12px; font-weight: 500; white-space: nowrap; }
.nf-loading-stats { color: rgba(190, 240, 237, .7); font-size: 10px; white-space: nowrap; }
.nf-progress { position: relative; width: 150px; height: 18px; overflow: hidden; border-radius: 9px; background: rgba(255, 255, 255, .1); }
.nf-progress-bar { height: 100%; border-radius: 9px; background: linear-gradient(90deg, var(--nf-primary), var(--nf-accent)); transition: width .3s ease-out; }
.nf-progress span { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: #fff; font-size: 10px; font-weight: 600; text-shadow: 0 1px 2px rgba(0, 0, 0, .4); }
.nf-spacer { flex: 1; }
.nf-hbtn { padding: 8px 16px; border: 0; border-radius: 4px; background: var(--nf-accent-dark); color: var(--nf-primary); font-size: 13px; font-weight: 500; cursor: pointer; white-space: nowrap; }
.nf-hbtn:hover { background: var(--nf-accent); }

/* ---------------------------------------------------------------- barra laterale */
.nf-body { display: flex; flex: 1 1 auto; min-height: 0; }
.nf-side { display: flex; flex-direction: column; flex: 0 0 300px; width: 300px; min-height: 0; overflow: hidden; background: var(--nf-primary); color: #fff; transition: margin-left .25s ease; }
.nf-side.hidden { margin-left: -300px; }
.nf-sec { padding: 14px 16px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.nf-sec-title { margin-bottom: 10px; color: rgba(255, 255, 255, .85); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.nf-search { display: flex; align-items: center; gap: 8px; }
.nf-search input { flex: 1; min-width: 0; padding: 8px 10px; border: 1px solid rgba(255, 255, 255, .25); border-radius: 4px; background: rgba(255, 255, 255, .06); color: #fff; font: inherit; font-size: 13px; outline: none; }
.nf-search input::placeholder { color: rgba(255, 255, 255, .5); }
.nf-search button { display: none; width: 22px; height: 22px; border: 0; border-radius: 50%; background: #e53e3e; color: #fff; font-size: 12px; line-height: 22px; cursor: pointer; }
.nf-search.active button { display: block; }
.nf-showing { margin-top: 6px; color: var(--nf-text-light); font-size: 11.5px; text-align: center; }
.nf-browser { flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.nf-cat { display: flex; align-items: center; gap: 10px; width: 100%; padding: 7px 4px; border: 0; background: none; color: #fff; font-size: 13px; text-align: left; cursor: pointer; }
.nf-cat:hover { background: rgba(255, 255, 255, .05); }
.nf-cat-caret { width: 10px; color: rgba(255, 255, 255, .6); font-size: 9px; }
.nf-cat-icon { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 4px; color: #fff; }
.nf-cat-icon svg { width: 14px; height: 14px; }
.nf-cat-name { flex: 1; }
.nf-count { padding: 1px 7px; border-radius: 10px; background: rgba(255, 255, 255, .1); color: rgba(255, 255, 255, .6); font-size: 11px; }
.nf-items { margin: 2px 0 6px 28px; }
.nf-item { display: block; width: 100%; padding: 5px 10px; border: 0; border-left: 2px solid transparent; border-radius: 3px; background: none; color: #fff; font-size: 13px; text-align: left; cursor: pointer; }
.nf-item small { display: block; color: rgba(255, 255, 255, .45); font-size: 10.5px; }
.nf-item:hover { background: rgba(255, 255, 255, .06); }
.nf-item.active { background: rgba(190, 240, 237, .16); border-left-color: var(--nf-accent-dark); }
.nf-stats { color: var(--nf-text-light); font-size: 12.5px; line-height: 1.7; }
.nf-stats strong { color: #fff; font-weight: 500; }
.nf-viewing { margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, .1); color: #fff; }
.nf-browser-empty { padding: 20px 10px; color: rgba(255, 255, 255, .55); font-size: 12.5px; font-style: italic; text-align: center; }
.nf-about { color: var(--nf-text-light); font-size: 11.5px; line-height: 1.6; }
.nf-about strong { color: #fff; }

/* ---------------------------------------------------------------- mappa */
.nf-main { position: relative; flex: 1 1 auto; min-width: 0; padding: 8px; background: var(--nf-primary); }
.nf-canvas { position: relative; height: 100%; overflow: hidden; border: 1px solid var(--nf-border); border-radius: 2px; background-color: #fff; background-image: radial-gradient(#c7cdd3 1px, transparent 1px); background-size: 20px 20px; cursor: grab; touch-action: pan-y; }
.nf-canvas.dragging { cursor: grabbing; }
.nf-view { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
.nf-view.nf-anim { transition: transform .4s ease; }
.nf-edges { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; }
.nf-node {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: 180px;
    min-height: 66px;
    padding: 9px 12px;
    border: 2px solid rgba(255, 255, 255, .3);
    border-radius: 8px;
    color: #fff;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.25;
    text-align: center;
    white-space: pre-line;
    word-break: break-word;
    box-shadow: 0 4px 6px rgba(0, 0, 0, .1);
    transform: translate(-50%, -50%);
    cursor: pointer;
    transition: box-shadow .15s ease, transform .15s ease, opacity .3s ease;
}
.nf-node svg { width: 18px; height: 18px; flex: 0 0 auto; opacity: .9; }
.nf-node:hover { box-shadow: 0 6px 16px rgba(0, 0, 0, .22); transform: translate(-50%, calc(-50% - 1px)); }
.nf-node.selected { box-shadow: 0 0 0 3px rgba(0, 61, 72, .35), 0 8px 18px rgba(0, 0, 0, .2); }
.nf-node.enter { opacity: 0; }
.nf-empty { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: #8a949c; font-size: 14px; pointer-events: none; }
.nf-controls { position: absolute; left: 16px; bottom: 16px; display: flex; flex-direction: column; border-radius: 3px; background: #fff; box-shadow: 0 0 2px 1px rgba(0, 0, 0, .08); }
.nf-controls button { width: 38px; height: 38px; border: 0; border-bottom: 1px solid #eee; background: #fff; color: #333; font-size: 18px; line-height: 1; cursor: pointer; }
.nf-controls button:last-child { border-bottom: 0; }
.nf-controls button:hover { background: #f4f4f4; }
.nf-pop { position: absolute; top: 46px; right: 16px; z-index: 5; width: 300px; padding: 14px 16px; border: 1px solid var(--nf-border); border-radius: 4px; background: #fff; box-shadow: 0 6px 16px rgba(0, 0, 0, .12); color: #333; font-size: 13px; }
.nf-pop h4 { margin: 0 24px 10px 0; font-size: 13.5px; font-weight: 500; white-space: pre-line; }
.nf-pop p { margin: 6px 0 0; padding-top: 6px; border-top: 1px solid #eee; }
.nf-pop p:first-of-type { border-top: 0; padding-top: 0; }
.nf-pop button { position: absolute; top: 10px; right: 10px; width: 22px; height: 22px; border: 1px solid #ccc; border-radius: 3px; background: #fff; color: #555; cursor: pointer; }
.nf-watermark { position: absolute; right: 6px; bottom: 3px; color: #7aa; font-size: 10px; pointer-events: none; }

/* ---------------------------------------------------------------- pannello di ns.conf */
.nf-config { display: flex; flex-direction: column; flex: 0 0 200px; min-height: 0; background: var(--nf-primary); color: #fff; border-top: 1px solid rgba(255, 255, 255, .1); transition: flex-basis .25s ease; }
.nf-config.hidden { flex-basis: 44px; }
.nf-config-head { display: flex; align-items: center; justify-content: space-between; flex: 0 0 44px; padding: 0 16px; font-size: 12.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.nf-copy { padding: 6px 12px; border: 0; border-radius: 4px; background: var(--nf-accent); color: var(--nf-primary); font-size: 12.5px; font-weight: 500; letter-spacing: 0; text-transform: none; cursor: pointer; }
.nf-config-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; font-family: SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }
.nf-line { display: flex; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.nf-line span:first-child { flex: 0 0 56px; padding: 3px 12px 3px 0; color: rgba(255, 255, 255, .45); text-align: right; border-right: 1px solid rgba(255, 255, 255, .12); }
.nf-line span:last-child { padding: 3px 12px; white-space: pre; }
.nf-config-empty { padding: 18px; color: rgba(255, 255, 255, .55); font-family: inherit; font-size: 13px; text-align: center; }

/* ---------------------------------------------------------------- finestre */
.nf-overlay { position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, .55); }
.nf-modal { display: flex; flex-direction: column; width: min(900px, 100%); max-height: 92%; overflow: hidden; border-radius: 12px; background: #fff; box-shadow: 0 20px 60px rgba(0, 0, 0, .4); animation: nf-appear .2s ease-out; }
@keyframes nf-appear { from { opacity: 0; transform: scale(.97); } }
.nf-modal-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; background: var(--nf-primary); color: #fff; }
.nf-modal-head h2 { margin: 0; font-size: 17px; font-weight: 600; }
.nf-modal-head button { border: 0; background: none; color: #fff; font-size: 18px; cursor: pointer; }
.nf-modal-body { overflow-y: auto; padding: 18px 20px; font-size: 13.5px; }
.nf-modal-body h3 { margin: 18px 0 8px; font-size: 14.5px; }
.nf-modal-wide { width: min(1000px, 100%); height: 92%; }
.nf-head-actions { display: flex; align-items: center; gap: 8px; }
.nf-head-actions .nf-save { padding: 6px 12px; border-radius: 4px; background: var(--nf-accent); color: var(--nf-primary); font-size: 12.5px; font-weight: 500; }
.nf-head-actions .nf-save.pdf { background: #fde2e1; color: #b42318; }
.nf-head-actions .nf-save.word { background: #dbeafe; color: #1e3a8a; }
.nf-modal-body svg { width: 16px; height: 16px; flex: 0 0 auto; }
.nf-info { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 6px; background: #f0fff4; color: #276749; font-weight: 500; }
.nf-info svg { width: 20px; height: 20px; color: #48bb78; }
.nf-fix { display: flex; align-items: flex-start; gap: 8px; padding: 7px 0; border-bottom: 1px solid #eee; color: #4a5568; font-size: 13px; }
.nf-fix svg { margin-top: 2px; color: #718096; }
.nf-fix b { color: #2d3748; font-weight: 600; }
.nf-status { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 6px; font-weight: 500; }
.nf-status svg { width: 22px; height: 22px; }
.nf-status.valid { background: #f0fff4; color: #276749; }
.nf-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.nf-chips span { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 12px; background: #edf2f7; color: #2d3748; font-size: 12.5px; }
.nf-details { margin-top: 14px; }
.nf-details summary { color: var(--nf-primary-light); font-weight: 500; cursor: pointer; }
.nf-pre { max-height: 240px; overflow: auto; margin: 8px 0 0; padding: 10px 12px; border: 1px solid #ddd; border-radius: 6px; background: #f5f5f5; color: #333; font-family: SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; white-space: pre; }
.nf-stats-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 16px; padding: 12px; border-radius: 8px; background: #f1f5f9; font-size: 13px; }
.nf-stats-title { grid-column: 1 / -1; font-weight: 700; }
.nf-amber { color: #b45309; }
.nf-red { color: #dc2626; }
.nf-modal-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; padding: 12px 20px; border-top: 1px solid #e2e8f0; background: #f8fafc; }
.nf-mbtn { padding: 9px 16px; border: 0; border-radius: 6px; background: #4a5568; color: #fff; font-size: 13px; font-weight: 500; cursor: pointer; }
.nf-mbtn.violet { background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%); }
.nf-mbtn.primary { background: var(--nf-primary-light); }

/* il report di mapping */
.nf-cards { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-bottom: 10px; }
.nf-cards.three { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: 18px; }
.nf-card { padding: 12px; border-left: 3px solid #cbd5e0; border-radius: 6px; background: #f8fafc; color: #4a5568; font-size: 12px; }
.nf-card b { display: block; color: #2d3748; font-size: 22px; }
.nf-card.ok { border-left-color: #16a34a; } .nf-card.ok b { color: #16a34a; }
.nf-card.part { border-left-color: #d97706; } .nf-card.part b { color: #d97706; }
.nf-card.no { border-left-color: #dc2626; } .nf-card.no b { color: #dc2626; }
.nf-card.avg { border-left-color: var(--nf-primary); } .nf-card.avg b { color: var(--nf-primary); }
.nf-map { margin-bottom: 8px; overflow: hidden; border: 1px solid #e2e8f0; border-radius: 8px; }
.nf-map-head { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 0; background: #fff; color: #2d3748; font-size: 13px; text-align: left; cursor: pointer; }
.nf-map-names { flex: 1; min-width: 0; }
.nf-map-names small { display: block; margin-top: 2px; color: #718096; font-size: 11.5px; }
.nf-f5 { color: #c53030; font-weight: 600; }
.nf-ns { color: var(--nf-primary-light); font-weight: 600; }
.nf-conf { padding: 2px 8px; border-radius: 10px; color: #fff; font-size: 11px; font-weight: 600; }
.nf-conf.high { background: #16a34a; }
.nf-conf.medium { background: #d97706; }
.nf-conf.low { background: #dc2626; }
.nf-badge { padding: 2px 8px; border-radius: 10px; font-size: 11px; font-weight: 600; text-transform: capitalize; white-space: nowrap; }
.nf-badge.converted { background: #dcfce7; color: #166534; }
.nf-badge.partial { background: #fef3c7; color: #92400e; }
.nf-badge.not-converted { background: #fee2e2; color: #991b1b; }
.nf-map-body { display: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; padding: 0 12px 12px; background: #fff; }
.nf-map.open .nf-map-body { display: grid; }
.nf-map-body h4 { margin: 4px 0 6px; color: #4a5568; font-size: 12px; }
.nf-map-body h4 span { margin-right: 4px; padding: 1px 6px; border-radius: 4px; background: #c53030; color: #fff; font-size: 10.5px; }
.nf-map-body h4 span.ns { background: var(--nf-primary-light); }
.nf-map-body pre { margin: 0; padding: 8px; overflow-x: auto; border: 1px solid #e2e8f0; border-radius: 4px; background: #f8f9fa; font-family: SFMono-Regular, Menlo, Consolas, monospace; font-size: 11.5px; white-space: pre; }
.nf-map-body p { grid-column: 1 / -1; margin: 0; padding: 8px 10px; border-radius: 4px; background: #f0f9ff; color: #334155; font-size: 12.5px; }

/* l'anteprima della documentazione (lo stesso foglio che l'app genera) */
.nf-doc { background: #f3f3f3; }
.nf-doc-hero { margin-bottom: 18px; padding: 26px 22px; border-radius: 10px; background: var(--nf-primary); color: #fff; }
.nf-doc-hero h1 { margin: 0 0 10px; font-size: 26px; }
.nf-doc-hero p { margin: 2px 0; opacity: .9; font-size: 13.5px; }
.nf-doc section { margin-bottom: 16px; padding: 20px; border-radius: 10px; background: #fff; box-shadow: 0 2px 10px rgba(0, 0, 0, .1); }
.nf-doc h2 { margin: 0 0 14px; padding-bottom: 8px; border-bottom: 2px solid var(--nf-accent); color: var(--nf-primary); font-size: 18px; }
.nf-doc h3 { margin: 16px 0 10px; color: var(--nf-primary-light); font-size: 15px; }
.nf-doc table { width: 100%; border-collapse: collapse; margin-bottom: 12px; font-size: 12.5px; }
.nf-doc th, .nf-doc td { padding: 9px 10px; border-bottom: 1px solid #e2e8f0; text-align: left; }
.nf-doc th { background: var(--nf-primary); color: #fff; font-weight: 600; }
.nf-doc code { padding: 2px 6px; border-radius: 4px; background: var(--nf-accent); color: var(--nf-primary); font-size: 11.5px; }
.nf-doc-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.nf-doc-cards div { padding: 16px; border-radius: 10px; background: var(--nf-primary); color: #fff; font-size: 13px; text-align: center; }
.nf-doc-cards b { display: block; font-size: 30px; }
.nf-doc-cards .blue { background: var(--nf-primary-light); }
.nf-doc-cards .green { background: #38a169; }
.nf-doc-cards .orange { background: #f97316; }
.nf-doc-cards .yellow { background: #b7791f; }
.nf-doc-badge { display: inline-block; padding: 2px 9px; border-radius: 12px; font-size: 11px; font-weight: 500; }
.nf-doc-badge.blue { background: var(--nf-accent); color: var(--nf-primary); }
.nf-doc-badge.purple { background: #f3e8ff; color: #7c3aed; }
.nf-doc-badge.orange { background: #ffedd5; color: #c2410c; }
.nf-doc-badge.yellow { background: #fef3c7; color: #b45309; }
.nf-doc-badge.gray { background: #f1f5f9; color: #475569; }
.nf-doc-empty { color: #94a3b8; font-style: italic; }
.nf-doc-foot { padding: 14px; color: var(--nf-primary); font-size: 12.5px; text-align: center; }
.nf-toast { position: fixed; left: 50%; top: 70px; z-index: 60; transform: translateX(-50%); padding: 8px 14px; border-radius: 6px; background: var(--nf-primary-light); color: #fff; font-size: 13px; box-shadow: 0 6px 18px rgba(0, 0, 0, .25); }

/* La fascia della simulazione: dice che cosa si sta guardando. Non fa parte del prodotto. */
.nf-sim { position: fixed; right: .9rem; bottom: .7rem; z-index: 40; display: flex; align-items: center; gap: .5rem; max-width: calc(100% - 1.8rem); padding: .4rem .8rem; border-radius: 999px; background: rgba(0, 61, 72, .94); color: #fff; font-size: .78rem; box-shadow: 0 6px 20px rgba(0, 0, 0, .25); pointer-events: none; }
.nf-sim::before { content: ""; flex-shrink: 0; width: .5rem; height: .5rem; border-radius: 50%; background: #f5c26b; }

/* ---------------------------------------------------------------- schermi stretti */
/* L'iframe della landing e' alto 16:10 della sua larghezza: sotto i 760 px d'altezza la barra
   laterale si stringe e lascia il posto al browser degli oggetti. */
@media (max-height: 760px) {
    .nf-sec { padding: 10px 16px; }
    .nf-sec-title { margin-bottom: 8px; }
    .nf-about-sec { display: none; }
    .nf-config { flex-basis: 170px; }
}

@media (max-width: 1100px) {
    .nf-title { margin-right: 10px; font-size: 17px; }
    .nf-side { flex-basis: 250px; width: 250px; }
    .nf-side.hidden { margin-left: -250px; }
}

@media (max-width: 760px) {
    .nf-header { gap: 6px; height: 50px; padding: 0 10px; }
    .nf-title { margin-right: 0; font-size: 14px; }
    .nf-title small, .nf-hbtn, .nf-dd-btn svg { display: none; }
    .nf-dd-btn { gap: 4px; padding: 6px 8px; font-size: 12px; }
    .nf-side { display: none; }
    .nf-main { padding: 6px; }
    .nf-config { flex-basis: 150px; }
    .nf-config-head { font-size: 11px; }
    .nf-pop { top: 8px; right: 8px; left: 8px; width: auto; padding: 8px 10px; font-size: 12px; }
    .nf-pop h4 { margin-bottom: 4px; font-size: 12.5px; }
    .nf-pop p { display: inline; margin: 0 12px 0 0; padding: 0; border: 0; }
    .nf-map-body { grid-template-columns: minmax(0, 1fr); }
    .nf-cards, .nf-cards.three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nf-stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nf-head-actions .nf-save { display: none; }
    .nf-loading-info { display: none; }
    .nf-progress { width: 70px; }
    .nf-modal-body { padding: 14px; }
    .nf-sim { left: .6rem; right: .6rem; justify-content: center; font-size: .72rem; }
}

@media (max-width: 420px) {
    .nf-header:has(.nf-loading) .nf-title { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .nf-node, .nf-side, .nf-config, .nf-modal, .nf-progress-bar { transition: none; animation: none; }
}
