:root{
  --bg:#f6f9ff;
  --bg2:#eef5ff;
  --ink:#0b1745;
  --muted:#6673a6;
  --line:#dce6fb;
  --card:rgba(255,255,255,.88);
  --glass:rgba(255,255,255,.72);
  --shadow:0 18px 55px rgba(43,74,140,.14);
  --shadow-soft:0 10px 25px rgba(43,74,140,.10);
  --blue:#3678ff;
  --indigo:#6557ff;
  --purple:#8f5cff;
  --teal:#2ccbb3;
  --green:#28c77b;
  --amber:#ffb836;
  --rose:#ff5f93;
  --danger:#ff5470;
  --radius:22px;
}
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  color:var(--ink);
  background:
    radial-gradient(circle at 12% 12%, rgba(112,210,255,.40), transparent 28%),
    radial-gradient(circle at 84% 2%, rgba(148,111,255,.34), transparent 24%),
    radial-gradient(circle at 90% 85%, rgba(44,203,179,.22), transparent 28%),
    linear-gradient(135deg,#fafdff,#f3f7ff 45%,#eef8ff);
  overflow:hidden;
}
button,input,select{font:inherit}
button{cursor:pointer}
.app-shell{height:100vh;display:grid;grid-template-rows:88px minmax(0,1fr) 190px;}
.topbar{
  display:grid;grid-template-columns:260px 1fr auto;align-items:center;gap:22px;
  padding:12px 22px 10px 12px;
  background:rgba(255,255,255,.72);backdrop-filter:blur(18px);
  border-bottom:1px solid rgba(189,205,238,.7);
  box-shadow:0 10px 34px rgba(31,63,127,.08);
  z-index:10;
}
.brand-block{height:76px;display:flex;align-items:center;gap:16px;border-right:1px solid var(--line);padding-right:20px;}
.brand-icon{position:relative;width:64px;height:64px;border-radius:18px;background:linear-gradient(155deg,#e7fbff,#f7f0ff);display:grid;place-items:center;box-shadow:inset 0 0 0 1px rgba(68,112,190,.12), var(--shadow-soft);}
.flask{font-size:36px;filter:drop-shadow(0 5px 8px rgba(43,160,190,.22))}
.bubble{position:absolute;border-radius:999px;background:#4be3d2;box-shadow:0 0 16px rgba(75,227,210,.7)}
.b1{width:8px;height:8px;left:16px;top:16px}.b2{width:12px;height:12px;right:15px;bottom:13px;background:#8874ff}
.brand-block h1{margin:0;font-size:25px;letter-spacing:-.8px;font-weight:900}
.brand-block p{margin:4px 0 0;color:#4154c7;font-weight:700;font-size:12px}
.toolbar{display:flex;gap:12px;align-items:center;min-width:0;overflow-x:auto;padding-bottom:2px}
.primary-btn,.ghost-btn,.icon-btn,.avatar-chip{
  border:1px solid rgba(174,191,229,.85);background:rgba(255,255,255,.85);color:var(--ink);border-radius:12px;height:40px;padding:0 16px;display:inline-flex;align-items:center;gap:9px;white-space:nowrap;font-weight:750;box-shadow:0 7px 16px rgba(31,63,127,.06);transition:.18s ease;
}
.primary-btn{background:linear-gradient(135deg,#695dff,#8d64ff);color:white;border-color:transparent;box-shadow:0 12px 25px rgba(101,87,255,.28)}
.primary-btn:hover,.ghost-btn:hover,.icon-btn:hover{transform:translateY(-1px);box-shadow:0 14px 26px rgba(31,63,127,.12)}
.ghost-btn.file-label{cursor:pointer}
.top-icons{display:flex;align-items:center;gap:12px}.icon-btn{width:40px;padding:0;justify-content:center;border-radius:14px}.avatar-chip{height:46px;border-radius:16px;padding:0 16px}.avatar-chip span{font-size:24px}
.workspace{display:grid;grid-template-columns:260px minmax(0,1fr) 296px;gap:0;min-height:0;}
.module-library,.inspector{
  background:rgba(255,255,255,.64);backdrop-filter:blur(18px);border-right:1px solid rgba(189,205,238,.7);padding:18px 17px;overflow:auto;
}
.inspector{border-right:0;border-left:1px solid rgba(189,205,238,.7)}
.panel-title{display:flex;justify-content:space-between;align-items:end;text-transform:uppercase;font-size:12px;font-weight:900;letter-spacing:.6px;color:#18286e;margin-bottom:12px}.panel-title small{color:var(--muted);text-transform:none;letter-spacing:0;font-weight:700}
.search-box{height:38px;border:1px solid rgba(174,191,229,.95);border-radius:11px;display:flex;align-items:center;background:rgba(255,255,255,.72);padding:0 10px;margin-bottom:15px}
.search-box input{border:0;outline:0;background:transparent;width:100%;color:var(--ink);font-weight:650}.search-box span{color:#4262d2;font-size:18px}
.library-group{border:1px solid rgba(204,216,241,.85);background:rgba(255,255,255,.52);border-radius:14px;overflow:hidden;margin-bottom:14px;box-shadow:0 10px 22px rgba(31,63,127,.04)}
.library-group h3{margin:0;padding:11px 12px 6px;color:#7180b8;text-transform:uppercase;font-size:11px;letter-spacing:.7px;border-bottom:1px solid rgba(204,216,241,.55)}
.library-item{width:100%;border:0;background:transparent;padding:10px 10px;display:grid;grid-template-columns:32px 1fr;grid-template-rows:auto auto;column-gap:10px;text-align:left;color:var(--ink);align-items:center}
.library-item:hover{background:rgba(101,87,255,.07)}
.library-item .mi{grid-row:1/3;width:30px;height:30px;border-radius:10px;display:grid;place-items:center;background:#eef4ff;box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}
.library-item b{font-size:13px}.library-item small{font-size:11px;color:var(--muted);font-weight:650;margin-top:2px}.mi.green{background:#e8fff6}.mi.amber{background:#fff7dd}.mi.blue{background:#e9f1ff}.mi.purple{background:#f1eaff}.mi.indigo{background:#edf0ff}.mi.teal{background:#e7fff9}.mi.rose{background:#ffeaf2}
.drop-hint{border:1px dashed #b9c9ed;border-radius:16px;background:rgba(255,255,255,.48);padding:16px;text-align:center;color:#6f7fb6}.drop-hint div{font-size:32px}.drop-hint b{font-size:13px;color:#30418b}.drop-hint p{font-size:12px;line-height:1.35;margin:6px 0 0}
.canvas-section{min-width:0;display:grid;grid-template-rows:44px minmax(0,1fr);}
.canvas-toolbar{display:flex;align-items:center;justify-content:space-between;padding:7px 18px;border-bottom:1px solid rgba(189,205,238,.55);background:rgba(244,249,255,.55);}
.canvas-status{display:flex;align-items:center;gap:10px;color:#34458d;font-size:13px}.canvas-status b{color:var(--ink)}#datasetBadge{padding:5px 9px;border-radius:999px;background:rgba(255,255,255,.75);border:1px solid rgba(185,201,237,.75);font-weight:750;color:#6b77a7}.pulse-dot{width:9px;height:9px;border-radius:50%;background:var(--green);box-shadow:0 0 0 8px rgba(40,199,123,.12)}
.mini-actions{display:flex;gap:8px}.mini-actions button{border:1px solid rgba(174,191,229,.8);background:rgba(255,255,255,.8);border-radius:10px;height:30px;padding:0 10px;color:#4658a4;font-weight:800;font-size:12px}
.flow-canvas{position:relative;overflow:hidden;min-height:0;background-image:radial-gradient(rgba(82,116,190,.22) 1px, transparent 1px);background-size:22px 22px;}
.grid-glow{position:absolute;inset:0;background:radial-gradient(circle at 45% 48%,rgba(105,93,255,.06),transparent 45%),radial-gradient(circle at 70% 30%,rgba(44,203,179,.08),transparent 38%);pointer-events:none}
.edge-svg{position:absolute;inset:0;width:100%;height:100%;z-index:1;pointer-events:none;overflow:visible}.nodes-layer{position:absolute;inset:0;z-index:2;}
.node{
  position:absolute;width:222px;min-height:122px;border-radius:18px;background:rgba(255,255,255,.88);border:2px solid var(--accent,#8db0ff);box-shadow:var(--shadow);padding:16px;user-select:none;transition:box-shadow .18s ease, transform .18s ease, border-color .18s ease;overflow:visible;
}
.node:hover{box-shadow:0 24px 70px rgba(38,70,135,.18);transform:translateY(-1px)}.node.selected{box-shadow:0 0 0 6px rgba(101,87,255,.14), var(--shadow);}
.node-header{display:flex;align-items:center;gap:11px}.node-number{width:24px;height:24px;border-radius:999px;background:var(--accent,#6557ff);display:grid;place-items:center;color:white;font-weight:900;font-size:12px;box-shadow:0 8px 14px rgba(0,0,0,.15)}.node-title{font-weight:900;font-size:15px;letter-spacing:-.2px}.node-menu{margin-left:auto;border:0;background:transparent;font-size:20px;color:#8190bd;padding:0 2px}
.node-body{display:grid;grid-template-columns:42px 1fr;gap:12px;margin-top:17px;align-items:center}.node-emoji{width:42px;height:42px;border-radius:13px;background:color-mix(in srgb, var(--accent) 15%, white);display:grid;place-items:center;font-size:24px;border:1px solid color-mix(in srgb, var(--accent) 25%, white)}.node-copy b{display:block;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.node-copy small{display:block;margin-top:5px;color:#465a99;font-weight:650;font-size:11px;line-height:1.35}.node-status{display:inline-flex;align-items:center;gap:5px;margin-top:14px;border-radius:999px;padding:6px 11px;background:color-mix(in srgb, var(--accent) 14%, white);color:color-mix(in srgb, var(--accent) 75%, #17205f);font-size:11px;font-weight:900}.port{position:absolute;width:13px;height:13px;border-radius:999px;background:white;border:3px solid var(--accent);box-shadow:0 3px 10px rgba(31,63,127,.20);z-index:5}.port.input{left:-8px;top:52%}.port.output{right:-8px;top:52%}.port:hover,.port.armed{transform:scale(1.35);box-shadow:0 0 0 7px color-mix(in srgb, var(--accent) 20%, transparent)}
.node[data-status="empty"]{opacity:.94}.node[data-status="running"]{animation:nodePulse 1s ease-in-out infinite alternate}.node[data-status="error"]{border-color:var(--danger)!important}.node[data-status="complete"] .node-status{background:#e8fff6;color:#077c4a}@keyframes nodePulse{from{filter:brightness(1)}to{filter:brightness(1.035);box-shadow:0 0 0 6px rgba(101,87,255,.1),var(--shadow)}}
.sparkline{height:34px;width:82px;border-radius:8px;background:linear-gradient(180deg,#fff,#f5f8ff);border:1px solid rgba(202,215,241,.7);overflow:hidden;display:flex;gap:3px;align-items:end;padding:5px}.sparkline i{flex:1;background:var(--accent);border-radius:3px 3px 0 0;opacity:.72}.mini-scatter{width:84px;height:42px;border:1px solid rgba(202,215,241,.7);border-radius:8px;background:linear-gradient(180deg,#fff,#f5f8ff);position:relative;overflow:hidden}.mini-scatter span{position:absolute;width:5px;height:5px;border-radius:50%;background:var(--accent);opacity:.75}.mini-scatter:after{content:"";position:absolute;left:8px;right:8px;top:27px;height:2px;background:var(--accent);transform:rotate(-20deg);transform-origin:left center;opacity:.45}.mini-bars{width:90px}.mini-bars div{height:5px;background:var(--accent);border-radius:999px;margin:4px 0;opacity:.72}
.inspector-header{display:grid;grid-template-columns:48px 1fr 32px;gap:12px;align-items:center;margin-bottom:16px}.large-icon{width:48px;height:48px;border-radius:16px;background:#eef2ff;display:grid;place-items:center;font-size:27px}.inspector h2{margin:0;font-size:19px;letter-spacing:-.5px}.inspector p{margin:4px 0 0;color:var(--muted);font-weight:700;font-size:12px}.x-btn{border:0;background:transparent;color:#7c89b5;font-size:24px;width:32px;height:32px;border-radius:10px}.x-btn:hover{background:rgba(101,87,255,.08)}.tabs{display:grid;grid-template-columns:repeat(3,1fr);border-bottom:1px solid var(--line);margin:0 -17px 15px}.tab{height:43px;border:0;background:transparent;font-weight:850;color:#7884b3}.tab.active{color:#5e54ff;border-bottom:3px solid #6557ff;background:rgba(101,87,255,.05)}
.field{margin-bottom:16px}.field label{display:block;font-size:11px;text-transform:uppercase;letter-spacing:.6px;color:#23337e;font-weight:900;margin-bottom:8px}.field select,.field input[type="range"],.field input[type="number"]{width:100%}.field select,.field input[type="number"]{height:38px;border:1px solid #c9d6f1;border-radius:10px;background:rgba(255,255,255,.75);padding:0 11px;color:var(--ink);font-weight:700}.toggle-row,.radio-row{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:10px 0;color:#26387d;font-size:13px;font-weight:700}.switch{position:relative;width:42px;height:24px;background:#dbe4fb;border-radius:999px;display:inline-block}.switch input{display:none}.switch span{position:absolute;width:20px;height:20px;background:white;top:2px;left:2px;border-radius:999px;box-shadow:0 2px 8px rgba(31,63,127,.2);transition:.18s}.switch input:checked+span{left:20px;background:white}.switch:has(input:checked){background:linear-gradient(135deg,#6557ff,#9270ff)}.inspector-card{border:1px solid rgba(204,216,241,.85);background:rgba(255,255,255,.64);border-radius:16px;padding:14px;margin-bottom:12px}.inspector-card b{display:block;margin-bottom:5px}.inspector-card small{color:var(--muted);line-height:1.45}.pill-row{display:flex;flex-wrap:wrap;gap:7px}.pill{padding:6px 9px;border-radius:999px;background:#eef4ff;color:#4254a3;font-size:11px;font-weight:850}.danger-note{border-left:4px solid var(--amber);padding:10px 12px;background:#fff9e9;border-radius:10px;color:#5c4914;font-size:12px;line-height:1.45;font-weight:650}
.bottom-dock{display:grid;grid-template-columns:45% 1fr 260px;gap:14px;padding:8px 128px 13px;background:rgba(244,249,255,.66);border-top:1px solid rgba(189,205,238,.65);z-index:9}.log-panel,.metrics-panel,.bot-help{background:rgba(255,255,255,.78);backdrop-filter:blur(16px);border:1px solid rgba(189,205,238,.75);border-radius:16px;box-shadow:var(--shadow-soft)}.log-panel,.metrics-panel{overflow:hidden}.dock-header{height:40px;display:flex;align-items:center;justify-content:space-between;padding:0 14px;border-bottom:1px solid rgba(204,216,241,.75);font-size:13px}.dock-header span{color:#1aae72;font-weight:850;font-size:12px}.execution-log{height:132px;overflow:auto;padding:8px 12px;font-size:11px}.log-line{display:grid;grid-template-columns:62px 140px 1fr 22px;gap:8px;align-items:center;padding:4px 2px;color:#28387d}.log-line time{color:#7784b7}.log-line b{font-size:11px}.log-line span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ok{color:#13b76e}.warn{color:#dd9100}.err{color:#e7445f}.dock-tabs{height:35px;display:flex;gap:10px;align-items:end;padding:0 14px;border-bottom:1px solid rgba(204,216,241,.75)}.dock-tabs button{height:35px;border:0;background:transparent;font-size:11px;font-weight:850;color:#7180b8}.dock-tabs .active{color:#6557ff;border-bottom:2px solid #6557ff}.metric-cards{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;padding:10px 12px 6px}.metric-card{height:54px;border:1px solid rgba(204,216,241,.9);border-radius:10px;background:rgba(255,255,255,.76);padding:8px 10px}.metric-card small{display:block;font-size:11px;color:#47599d;font-weight:800}.metric-card strong{font-size:20px;letter-spacing:-.8px}.chart-strip{height:82px;padding:0 12px 10px;display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.empty-chart{grid-column:1/-1;border:1px dashed #c3d1ed;border-radius:12px;display:grid;place-items:center;color:#7180b8;font-weight:750;font-size:13px}.small-chart{border:1px solid rgba(204,216,241,.9);border-radius:10px;background:rgba(255,255,255,.76);position:relative;overflow:hidden}.small-chart svg{width:100%;height:100%;display:block}.small-chart b{position:absolute;left:8px;top:6px;font-size:9px;color:#2e407f}.bot-help{border:0;display:flex;align-items:center;gap:12px;padding:15px 18px;text-align:left;align-self:center;height:92px;background:linear-gradient(135deg,rgba(255,255,255,.82),rgba(238,246,255,.92));}.bot-face{font-size:42px;filter:drop-shadow(0 8px 16px rgba(85,117,200,.2))}.bot-help b{display:block;color:#5149dd}.bot-help small{display:block;color:#6878ad;font-weight:750;margin-top:4px}
.toast-stack{position:fixed;right:22px;bottom:215px;z-index:99;display:grid;gap:10px}.toast{background:rgba(255,255,255,.94);border:1px solid #d7e2f7;border-left:4px solid var(--green);border-radius:14px;padding:12px 14px;box-shadow:var(--shadow);min-width:260px;animation:toastIn .24s ease}.toast.warn{border-left-color:var(--amber)}.toast.err{border-left-color:var(--danger)}.toast b{display:block;font-size:13px}.toast small{display:block;color:var(--muted);margin-top:4px;font-weight:650}@keyframes toastIn{from{transform:translateY(10px);opacity:0}to{transform:none;opacity:1}}
.report-dialog{border:0;background:transparent;max-width:920px;width:92vw;padding:0}.report-dialog::backdrop{background:rgba(13,21,57,.42);backdrop-filter:blur(6px)}.report-card{position:relative;background:#fff;border-radius:24px;box-shadow:0 35px 100px rgba(0,0,0,.25);padding:30px;max-height:86vh;overflow:auto}.close-report{position:absolute;right:16px;top:14px}.report-hero{background:linear-gradient(135deg,#eef6ff,#f5efff);border:1px solid #dce6fb;border-radius:20px;padding:22px;margin-bottom:16px}.report-hero h2{font-size:30px;margin:0 0 8px}.report-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin:16px 0}.report-metric{border:1px solid #dce6fb;border-radius:14px;padding:13px;background:#f9fbff}.report-metric small{display:block;color:#6673a6;font-weight:800}.report-metric b{font-size:22px}.report-section{margin-top:20px}.report-section h3{margin-bottom:8px}.report-table{width:100%;border-collapse:collapse;font-size:13px}.report-table th,.report-table td{border-bottom:1px solid #e4ecfa;padding:8px;text-align:left}.report-table th{color:#35478e;background:#f6f9ff}
@media (max-width:1200px){.workspace{grid-template-columns:230px minmax(0,1fr) 280px}.bottom-dock{padding-left:20px;padding-right:20px;grid-template-columns:1fr 1fr}.bot-help{display:none}.topbar{grid-template-columns:250px 1fr}.top-icons{display:none}}
@media (max-width:900px){body{overflow:auto}.app-shell{height:auto;min-height:100vh;grid-template-rows:auto auto auto}.topbar,.workspace,.bottom-dock{display:block}.module-library,.inspector{height:auto}.flow-canvas{height:720px}.bottom-dock{padding:12px}.metrics-panel{margin-top:12px}.toolbar{flex-wrap:wrap}.brand-block{border-right:0}}

.module-actions{margin-top:14px;border-top:1px solid rgba(204,216,241,.75);padding-top:14px}.danger-btn{width:100%;height:40px;border:1px solid rgba(255,84,112,.35);background:rgba(255,84,112,.08);color:#b92742;border-radius:12px;font-weight:900;cursor:pointer}.danger-btn:hover{background:rgba(255,84,112,.14);transform:translateY(-1px)}.node-menu{cursor:pointer;border-radius:999px;width:24px;height:24px;line-height:20px}.node-menu:hover{background:rgba(255,84,112,.12);color:#b92742}

/* v3: full module popups and click-to-upload canvas UX */
.module-dialog{max-width:1080px;width:94vw}.module-card{padding:28px 30px 32px}.module-hero{padding:18px 20px}.modal-title-row{display:flex;align-items:center;gap:16px}.modal-title-row>span{width:58px;height:58px;border-radius:18px;background:rgba(255,255,255,.78);display:grid;place-items:center;font-size:32px;box-shadow:var(--shadow-soft)}.modal-title-row h2{margin:0;font-size:28px}.modal-title-row p{margin:5px 0 0;color:var(--muted);font-weight:750}.summary-kpis{display:grid;grid-template-columns:repeat(6,1fr);gap:12px;margin:16px 0}.summary-kpi{border:1px solid #dce6fb;border-radius:17px;background:linear-gradient(180deg,#fff,#f7faff);padding:14px;box-shadow:0 10px 24px rgba(43,74,140,.07)}.summary-kpi small{display:block;color:#6673a6;font-weight:900;text-transform:uppercase;font-size:10px;letter-spacing:.5px}.summary-kpi b{display:block;margin-top:4px;font-size:24px;letter-spacing:-.8px}.modal-two-col{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:14px 0}.modal-table-wrap{max-height:430px;overflow:auto;border:1px solid #dce6fb;border-radius:16px}.fancy-summary-table th{position:sticky;top:0;z-index:1}.type-pill{display:inline-flex;border-radius:999px;padding:4px 8px;font-size:11px;font-weight:900;background:#eef4ff;color:#4254a3}.type-pill.numeric{background:#e8fff6;color:#08764b}.type-pill.categorical{background:#fff7dd;color:#8a6500}.modal-chart-card{border:1px solid #dce6fb;border-radius:18px;background:linear-gradient(180deg,#fff,#f8fbff);padding:16px;box-shadow:0 10px 24px rgba(43,74,140,.06)}.modal-chart-card h3{margin:0 0 10px;color:#18286e}.modal-chart-card svg{width:100%;height:220px}.corr-bar{height:10px;width:140px;border-radius:999px;background:#eef3ff;overflow:hidden}.corr-bar span{display:block;height:100%;border-radius:999px;background:linear-gradient(90deg,#2ccbb3,#6557ff)}
.node[data-node-id]{cursor:grab}.node[data-node-id]:active{cursor:grabbing}.node-copy small:after{content:" · click to open";color:#7e8ab6;font-weight:800}.node[data-status="empty"] .node-copy small:after{content:" · click to upload";color:#28a66d}
@media (max-width:900px){.summary-kpis{grid-template-columns:repeat(2,1fr)}.modal-two-col{grid-template-columns:1fr}.modal-chart-card svg{height:160px}}

/* v4: cleaner wow layer + final document */
.report-top-btn{
  height:40px;border:0;border-radius:14px;padding:0 18px;display:inline-flex;align-items:center;gap:9px;white-space:nowrap;font-weight:900;color:white;
  background:linear-gradient(135deg,#ff5f93,#8f5cff 55%,#2ccbb3);
  box-shadow:0 14px 30px rgba(143,92,255,.26), inset 0 0 0 1px rgba(255,255,255,.22);
  cursor:pointer;transition:.18s ease;
}
.report-top-btn:hover{transform:translateY(-1px);box-shadow:0 18px 34px rgba(143,92,255,.34)}
.node{background:linear-gradient(180deg,rgba(255,255,255,.92),rgba(255,255,255,.80));box-shadow:0 22px 44px rgba(36,70,140,.12), inset 0 0 0 1px rgba(255,255,255,.48)}
.node:hover{transform:translateY(-2px);box-shadow:0 24px 58px rgba(36,70,140,.18),0 0 0 5px color-mix(in srgb,var(--accent) 10%,transparent)}
.node.selected{box-shadow:0 24px 62px rgba(74,83,255,.22),0 0 0 5px color-mix(in srgb,var(--accent) 16%,transparent)}
.node-emoji,.mi,.large-icon{box-shadow:inset 0 0 0 1px rgba(255,255,255,.55),0 10px 22px rgba(39,68,130,.10)}
.canvas-section{background:linear-gradient(135deg,rgba(225,246,255,.78),rgba(244,238,255,.76) 52%,rgba(230,255,249,.76));}
.flow-canvas{background:radial-gradient(circle at 25% 22%,rgba(93,220,255,.18),transparent 33%),radial-gradient(circle at 82% 66%,rgba(255,95,147,.12),transparent 28%)}
.flow-map-report{display:flex;align-items:center;flex-wrap:wrap;gap:8px;padding:15px;border:1px solid #dce6fb;border-radius:18px;background:linear-gradient(135deg,#f7fbff,#fff7fb);box-shadow:0 12px 26px rgba(43,74,140,.07);margin:16px 0}
.flow-map-report span{display:inline-flex;align-items:center;border-radius:999px;padding:8px 11px;background:white;border:1px solid #e1e9fb;font-weight:900;font-size:12px;color:#27377e}.flow-map-report em{font-style:normal;color:#8a93bd;font-weight:900}
.final-hero{display:flex;justify-content:space-between;gap:18px;align-items:flex-start;background:radial-gradient(circle at 15% 0,rgba(44,203,179,.22),transparent 32%),linear-gradient(135deg,#eef8ff,#f7efff 60%,#fff4f8);border:1px solid #dce6fb;border-radius:24px;padding:24px;margin-bottom:16px;box-shadow:0 18px 44px rgba(57,77,150,.10)}
.final-hero h2{font-size:34px;margin:8px 0 8px;letter-spacing:-1.2px}.final-hero p{margin:0;color:#52619b;font-weight:750}.report-badge{display:inline-flex;border-radius:999px;padding:7px 10px;background:#0b1745;color:white;font-size:11px;text-transform:uppercase;letter-spacing:.7px;font-weight:950}.report-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}.exec-card{border:1px solid #dce6fb;border-radius:20px;padding:18px 20px;background:linear-gradient(180deg,#fff,#f8fbff);box-shadow:0 14px 30px rgba(43,74,140,.08)}.exec-card h3{margin:0 0 8px}.exec-card p{margin:0;line-height:1.65;color:#24316e;font-weight:650}.wow-grid{grid-template-columns:repeat(4,1fr)}.report-metric.highlight{background:linear-gradient(135deg,#eef6ff,#f3efff);border-color:#cbd7ff}.report-two-col{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:16px}.cardish{border:1px solid #dce6fb;border-radius:20px;background:linear-gradient(180deg,#fff,#f8fbff);padding:18px;box-shadow:0 12px 30px rgba(43,74,140,.07)}.cardish h3{margin-top:0}.cardish svg{width:100%;height:250px}.caveats{border:1px solid #ffe0ab;background:linear-gradient(180deg,#fffaf0,#fff);border-radius:20px;padding:18px}.caveats ul{margin:0;padding-left:20px;line-height:1.65}.next-steps{border:1px solid #cceee8;background:linear-gradient(180deg,#f4fffc,#fff);border-radius:20px;padding:18px}.next-steps ol{margin:0;padding-left:20px;line-height:1.65}.exported-report{max-width:1100px;margin:0 auto;padding:28px;background:#fff}
@media (max-width:900px){.final-hero,.report-two-col{display:block}.report-actions{justify-content:flex-start;margin-top:14px}.wow-grid{grid-template-columns:repeat(2,1fr)}}
@media print{body{overflow:auto;background:white}.app-shell>*:not(.report-dialog),.close-report,.report-actions{display:none!important}.report-dialog{position:static!important;display:block!important;max-width:none;width:100%;padding:0}.report-card{box-shadow:none;max-height:none;overflow:visible;border-radius:0;padding:0}.report-dialog::backdrop{display:none}.final-hero,.exec-card,.cardish,.caveats,.next-steps,.flow-map-report{box-shadow:none;break-inside:avoid}.report-two-col{break-inside:avoid}.report-table{font-size:11px}}

/* v5: scatter + histogram + stronger neon wow */
body{
  background:
    radial-gradient(circle at 10% 12%, rgba(111,208,255,.52), transparent 25%),
    radial-gradient(circle at 88% 8%, rgba(145,95,255,.36), transparent 22%),
    radial-gradient(circle at 88% 82%, rgba(44,203,179,.22), transparent 26%),
    linear-gradient(135deg,#fbfdff,#eef5ff 42%,#f7efff 74%,#efffff);
}
.brand-icon{
  background:linear-gradient(160deg,#effdff,#f5f0ff 60%,#fdf6ff);
  box-shadow:inset 0 0 0 1px rgba(68,112,190,.12),0 18px 36px rgba(74,92,179,.18);
}
.primary-btn,.report-top-btn{
  background:linear-gradient(135deg,#5dcbff 0%,#7a68ff 45%,#ff6ba1 100%);
  box-shadow:0 16px 30px rgba(102,92,255,.24);
}
.ghost-btn,.icon-btn,.avatar-chip{backdrop-filter:blur(14px)}
.canvas-section{
  background:
    radial-gradient(circle at 18% 16%, rgba(93,220,255,.18), transparent 30%),
    radial-gradient(circle at 84% 64%, rgba(255,95,147,.12), transparent 30%),
    linear-gradient(135deg,rgba(229,247,255,.84),rgba(247,241,255,.82) 52%,rgba(236,255,249,.84));
}
.flow-canvas{
  background-image:
    radial-gradient(rgba(98,127,206,.2) 1px, transparent 1px),
    radial-gradient(circle at 38% 42%,rgba(105,93,255,.09),transparent 34%),
    radial-gradient(circle at 70% 20%,rgba(44,203,179,.09),transparent 26%);
  background-size:22px 22px, auto, auto;
}
.node{
  width:230px;
  border-radius:28px;
  border-width:1px;
  background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(255,255,255,.84));
  box-shadow:0 24px 48px rgba(36,70,140,.14), 0 0 0 1px rgba(255,255,255,.35) inset;
}
.node:before{
  content:"";
  position:absolute;
  inset:0;
  border-radius:28px;
  padding:1px;
  background:linear-gradient(135deg,color-mix(in srgb, var(--accent) 72%, white), rgba(255,255,255,.3));
  -webkit-mask:linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite:xor;
  mask-composite:exclude;
  pointer-events:none;
}
.node-header{align-items:flex-start}
.node-number{width:28px;height:28px;box-shadow:0 8px 20px color-mix(in srgb, var(--accent) 35%, transparent)}
.node-emoji{width:46px;height:46px;border-radius:16px;font-size:25px}
.library-group{border-radius:18px}
.library-item{padding:12px 12px}
.library-item .mi{width:34px;height:34px;border-radius:12px}
.library-item:hover{background:linear-gradient(90deg,rgba(93,203,255,.08),rgba(124,104,255,.06),rgba(255,107,161,.07))}
.module-dialog{max-width:1180px}
.chart-control-row{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin:8px 0 14px}
.chart-control-row .field{margin-bottom:0}
.chart-control-row input[type="range"]{width:100%}
.range-readout{display:block;margin-top:6px;color:#6071ad;font-weight:800}
.wide-card{grid-column:1 / span 1}
.big-svg{width:100%;height:320px;display:block}
.slim-kpis{grid-template-columns:repeat(2,1fr);margin-top:12px}
.chart-note{line-height:1.6;color:#33427f;font-weight:650}
#moduleDialogContent .modal-two-col{grid-template-columns:1.35fr .85fr}
#moduleDialogContent .modal-chart-card{padding:18px}
#moduleDialogContent .summary-kpi b{font-size:20px}
.inspector-card,.summary-kpi,.metric-card,.log-panel,.metrics-panel{box-shadow:0 12px 24px rgba(43,74,140,.06)}
.small-chart{background:linear-gradient(180deg,rgba(255,255,255,.95),rgba(244,248,255,.92))}
@media (max-width:900px){
  .chart-control-row{grid-template-columns:1fr}
  #moduleDialogContent .modal-two-col{grid-template-columns:1fr}
  .big-svg{height:260px}
}

/* v6 premium polish — Light Neon Glass Lab */
:root{
  --premium-bg:#f8fbff;
  --premium-ink:#07133f;
  --premium-cyan:#5ed8ff;
  --premium-violet:#705cff;
  --premium-pink:#ff65a3;
  --premium-mint:#2ed9bd;
  --premium-gold:#ffbd4a;
}
body{
  color:var(--premium-ink);
  background:
    radial-gradient(circle at 9% 10%, rgba(94,216,255,.50), transparent 25%),
    radial-gradient(circle at 90% 10%, rgba(112,92,255,.32), transparent 23%),
    radial-gradient(circle at 80% 86%, rgba(46,217,189,.20), transparent 28%),
    linear-gradient(135deg,#fbfdff 0%,#edf7ff 42%,#f8f1ff 72%,#efffff 100%);
}
.app-shell{grid-template-rows:76px minmax(0,1fr) 154px}
.topbar{
  grid-template-columns:226px 1fr auto;
  background:rgba(255,255,255,.72);
  border-bottom:1px solid rgba(180,199,238,.58);
  box-shadow:0 16px 38px rgba(45,72,136,.10);
}
.brand-block{height:62px}
.brand-icon{width:52px;height:52px;border-radius:18px}
.flask{font-size:29px}
.brand-block h1{font-size:23px}
.brand-block p{font-size:10px;letter-spacing:.15px}
.toolbar{gap:10px}
.primary-btn,.ghost-btn,.report-top-btn,.icon-btn,.avatar-chip{border-radius:15px;height:38px;font-weight:900}
.primary-btn,.report-top-btn{background:linear-gradient(135deg,var(--premium-cyan),var(--premium-violet) 48%,var(--premium-pink));box-shadow:0 14px 28px rgba(112,92,255,.26), inset 0 1px 0 rgba(255,255,255,.36)}
.ghost-btn{background:rgba(255,255,255,.78);border:1px solid rgba(151,174,226,.76)}
.workspace{grid-template-columns:216px minmax(0,1fr) 282px;transition:grid-template-columns .22s ease}
body.inspector-collapsed .workspace{grid-template-columns:216px minmax(0,1fr) 0}
body.inspector-collapsed .inspector{opacity:0;padding:0;overflow:hidden;border-left:0;pointer-events:none}
.module-library{padding:12px 10px;background:rgba(255,255,255,.54)}
.panel-title{font-size:10px;margin-bottom:8px}
.search-box{height:35px;border-radius:14px;margin-bottom:10px}
.library-group{border-radius:18px;margin-bottom:10px;overflow:hidden;box-shadow:0 14px 30px rgba(39,66,130,.06)}
.library-group h3{font-size:10px;padding:9px 11px 5px}
.library-item{grid-template-columns:30px 1fr;padding:9px 10px}
.library-item .mi{width:28px;height:28px;border-radius:11px;font-weight:950}
.library-item b{font-size:12px}.library-item small{font-size:10px}.drop-hint{display:none}
.canvas-toolbar{height:40px;padding:6px 14px;background:rgba(246,250,255,.72)}
.mini-actions button{border-radius:13px;background:rgba(255,255,255,.80)}
.flow-canvas{background-image:radial-gradient(rgba(91,126,210,.18) 1px, transparent 1px),radial-gradient(circle at 22% 24%,rgba(94,216,255,.14),transparent 28%),radial-gradient(circle at 74% 46%,rgba(255,101,163,.10),transparent 30%),radial-gradient(circle at 50% 84%,rgba(46,217,189,.11),transparent 32%);background-size:21px 21px, auto, auto, auto}
.empty-canvas{position:absolute;inset:58px auto auto 50%;transform:translateX(-50%);z-index:3;width:min(560px,80%);padding:28px 30px;border-radius:32px;background:linear-gradient(135deg,rgba(255,255,255,.86),rgba(247,251,255,.66));border:1px solid rgba(178,200,242,.75);box-shadow:0 32px 90px rgba(45,72,136,.18), inset 0 1px 0 rgba(255,255,255,.62);text-align:center;backdrop-filter:blur(18px)}
.empty-canvas.hidden{display:none}.empty-orb{width:68px;height:68px;margin:0 auto 14px;display:grid;place-items:center;border-radius:24px;color:white;font-size:30px;background:linear-gradient(135deg,var(--premium-cyan),var(--premium-violet),var(--premium-pink));box-shadow:0 18px 45px rgba(112,92,255,.32)}
.empty-canvas h2{margin:0;font-size:30px;letter-spacing:-1.1px}.empty-canvas p{margin:9px auto 18px;max-width:440px;color:#52619b;font-weight:750;line-height:1.55}.empty-actions{display:flex;justify-content:center;gap:10px;flex-wrap:wrap}
.node{width:218px;min-height:112px;border:0;border-radius:30px;padding:14px;background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(255,255,255,.82)),radial-gradient(circle at 10% 0,color-mix(in srgb,var(--accent) 22%,transparent),transparent 40%);box-shadow:0 22px 45px rgba(36,70,140,.13), inset 0 0 0 1px rgba(255,255,255,.70)}
.node:before{border-radius:30px;background:linear-gradient(135deg,color-mix(in srgb,var(--accent) 85%,white),rgba(255,255,255,.15),color-mix(in srgb,var(--accent) 45%,transparent))}
.node:hover{transform:translateY(-3px) scale(1.006);box-shadow:0 30px 68px rgba(36,70,140,.20),0 0 0 5px color-mix(in srgb,var(--accent) 13%,transparent)}
.node.selected{box-shadow:0 30px 76px rgba(82,94,255,.24),0 0 0 6px color-mix(in srgb,var(--accent) 16%,transparent)}
.node.active-run{animation:activeRun 680ms ease-in-out infinite alternate}@keyframes activeRun{from{filter:brightness(1)}to{filter:brightness(1.07);box-shadow:0 34px 82px color-mix(in srgb,var(--accent) 30%,rgba(36,70,140,.18)),0 0 0 8px color-mix(in srgb,var(--accent) 16%,transparent)}}
.node-number{width:25px;height:25px;background:linear-gradient(135deg,var(--accent),color-mix(in srgb,var(--accent) 65%,#ffffff))}.node-title{font-size:14px;line-height:1.05}.node-menu{font-size:18px;color:#8b98c4}.node-body{grid-template-columns:40px 1fr;gap:10px;margin-top:13px}.node-emoji{width:40px;height:40px;border-radius:16px;font-size:22px;font-weight:950;color:color-mix(in srgb,var(--accent) 70%,#07133f);background:linear-gradient(180deg,rgba(255,255,255,.78),color-mix(in srgb,var(--accent) 15%,white))}.node-copy b{font-size:11px}.node-copy small{font-size:10px}.node-copy small:after{content:"";display:none}.node-status{margin-top:10px;padding:5px 10px;font-size:10px}.port{width:12px;height:12px;border-width:3px;box-shadow:0 0 0 4px color-mix(in srgb,var(--accent) 10%,transparent),0 6px 14px rgba(31,63,127,.20)}
.edge-path{stroke-width:3!important;opacity:.36!important;filter:none!important}.flow-canvas.flow-running .edge-path{opacity:.82!important;stroke-dasharray:14 14;animation:edgeRun 700ms linear infinite;filter:url(#glow)!important}@keyframes edgeRun{to{stroke-dashoffset:-28}}
.bottom-dock{padding:8px 98px 10px 98px;grid-template-columns:minmax(420px,1fr) minmax(420px,1.4fr) 190px}.log-panel,.metrics-panel,.bot-help{border-radius:22px;background:rgba(255,255,255,.72);border:1px solid rgba(180,199,238,.70);box-shadow:0 22px 52px rgba(39,66,130,.10)}.execution-log{max-height:98px}.metrics-panel{padding:10px 12px}.metric-cards{gap:8px}.metric-card{border-radius:16px;padding:10px 12px}.chart-strip{height:62px}.small-chart{height:58px;border-radius:16px}.bot-help{height:78px}.bot-face{font-size:34px}
.inspector{background:rgba(255,255,255,.61);backdrop-filter:blur(20px);transition:opacity .22s ease,padding .22s ease}.inspector-header{gap:11px}.large-icon{width:50px;height:50px;border-radius:18px;display:grid;place-items:center;color:#fff;background:linear-gradient(135deg,var(--premium-cyan),var(--premium-violet),var(--premium-pink))}.tabs{margin-left:-17px;margin-right:-17px}.tab{font-size:12px}.inspector-card{border-radius:20px;background:linear-gradient(180deg,rgba(255,255,255,.88),rgba(248,251,255,.75))}
.module-dialog{max-width:1240px;width:95vw}.report-card{border-radius:34px;background:linear-gradient(180deg,rgba(255,255,255,.98),rgba(249,252,255,.96))}.report-dialog::backdrop{background:rgba(8,14,42,.50);backdrop-filter:blur(10px)}.module-hero,.final-hero{border-radius:28px;background:radial-gradient(circle at 10% 0,rgba(94,216,255,.22),transparent 36%),radial-gradient(circle at 100% 0,rgba(255,101,163,.16),transparent 30%),linear-gradient(135deg,#f0fbff,#f8f2ff 56%,#fff4fa)}.modal-title-row>span{color:white;background:linear-gradient(135deg,var(--premium-cyan),var(--premium-violet),var(--premium-pink))}.chart-control-row{border:1px solid #dce6fb;border-radius:22px;padding:14px;background:rgba(248,251,255,.76)}.big-svg{height:360px;border-radius:24px;filter:drop-shadow(0 18px 35px rgba(16,23,54,.18))}.modal-chart-card{border-radius:24px}.final-hero h2{font-size:38px}.report-badge{background:linear-gradient(135deg,#07133f,#342b87)}.flow-map-report span{border-radius:999px;background:linear-gradient(180deg,#fff,#f8fbff)}.caveats,.next-steps,.cardish,.exec-card{border-radius:24px}
@media (max-width:1200px){.workspace,body.inspector-collapsed .workspace{grid-template-columns:200px minmax(0,1fr)}.inspector{display:none}.bottom-dock{grid-template-columns:1fr 1fr;padding:8px 20px}}
@media (max-width:900px){.app-shell{grid-template-rows:auto auto auto}.topbar{grid-template-columns:1fr}.workspace{display:block}.module-library{display:none}.flow-canvas{height:760px}.bottom-dock{display:block}.log-panel{display:none}.metrics-panel{margin-top:8px}.empty-canvas{position:absolute;top:30px;width:90%}}


/* v7: edge undo */
.undo-btn{
  position:relative;
  min-width:74px;
}
.undo-btn:disabled{
  opacity:.42;
  cursor:not-allowed;
  filter:saturate(.65);
}
.undo-btn.has-undo{
  border-color:rgba(112,92,255,.42)!important;
  background:linear-gradient(180deg,rgba(255,255,255,.92),rgba(244,248,255,.82))!important;
  color:#4036b8!important;
  box-shadow:0 10px 22px rgba(112,92,255,.12);
}
.undo-btn.has-undo:before{
  content:"";
  position:absolute;
  width:7px;height:7px;
  right:7px;top:7px;
  border-radius:999px;
  background:#2ed9bd;
  box-shadow:0 0 0 5px rgba(46,217,189,.14);
}


/* v8: clearer Target Relationships module */
.relationship-explainer{
  display:grid;
  grid-template-columns:1.4fr 1fr 1fr;
  gap:14px;
  margin:12px 0 16px;
}
.explain-card{
  border:1px solid #dce6fb;
  border-radius:22px;
  padding:16px;
  background:linear-gradient(180deg,rgba(255,255,255,.92),rgba(246,250,255,.80));
  box-shadow:0 14px 30px rgba(43,74,140,.07);
}
.main-explain{
  display:flex;
  gap:14px;
  align-items:flex-start;
}
.explain-icon{
  min-width:52px;
  height:52px;
  border-radius:18px;
  display:grid;
  place-items:center;
  color:white;
  font-size:26px;
  font-weight:950;
  background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
  box-shadow:0 15px 35px rgba(112,92,255,.25);
}
.explain-card h3{margin:0 0 7px;font-size:19px}
.explain-card p{margin:0;color:#465a99;font-weight:700;line-height:1.55}
.explain-card b{display:block;margin-bottom:7px;color:#07133f}
.warning-explain{border-color:#ffe0ab;background:linear-gradient(180deg,#fffaf0,#fff)}
.relationship-grid{grid-template-columns:1.35fr .85fr!important}
.relationship-table td,.relationship-table th{font-size:12px}
@media (max-width:900px){
  .relationship-explainer,.relationship-grid{grid-template-columns:1fr!important}
}


/* v9: bigger scatter + recommended visuals in Smart Summary */
.scatter-layout{grid-template-columns:minmax(0,1.55fr) minmax(300px,.75fr)!important;align-items:stretch}
.scatter-primary-card .big-svg{height:430px}
.recommended-visuals-block{margin:18px 0 20px}
.recommended-visuals-head{display:flex;justify-content:space-between;gap:14px;align-items:end;margin-bottom:12px;flex-wrap:wrap}
.recommended-visuals-head h3{margin:0;font-size:22px;color:#0b1d59}
.recommended-visuals-head p{margin:0;color:#5a6ba5;font-weight:700}
.recommended-visuals-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.recommended-card{border-radius:24px;background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(246,250,255,.88));box-shadow:0 18px 40px rgba(43,74,140,.08)}
.recommended-card .big-svg{height:260px}
.recommended-card h3{margin-bottom:8px}
@media (max-width: 980px){.recommended-visuals-grid{grid-template-columns:1fr}.scatter-layout{grid-template-columns:1fr!important}.scatter-primary-card .big-svg{height:320px}}


/* v10: Guided flow + visual analysis + aurora premium canvas */
.flow-canvas{
  background-image:
    radial-gradient(rgba(116,197,255,.25) 1px, transparent 1px),
    radial-gradient(circle at 18% 20%,rgba(89,216,255,.22),transparent 30%),
    radial-gradient(circle at 82% 18%,rgba(255,101,163,.18),transparent 28%),
    radial-gradient(circle at 52% 86%,rgba(46,217,189,.16),transparent 33%),
    linear-gradient(135deg,#071226 0%,#101a3a 42%,#18204a 70%,#09182c 100%);
  background-size:22px 22px, auto, auto, auto, auto;
}
.canvas-toolbar{
  background:linear-gradient(90deg,rgba(8,17,38,.86),rgba(20,28,66,.78));
  border-bottom:1px solid rgba(105,188,255,.25);
}
.canvas-status,.canvas-status b{color:#eef6ff}
#datasetBadge{
  background:rgba(255,255,255,.12);
  color:#dbe9ff;
  border-color:rgba(160,205,255,.30);
}
.mini-actions button{
  color:#e8f2ff;
  background:rgba(255,255,255,.10);
  border-color:rgba(172,208,255,.28);
}
.node{
  background:
    linear-gradient(180deg,rgba(255,255,255,.98),rgba(240,246,255,.88)),
    radial-gradient(circle at 0 0,color-mix(in srgb,var(--accent) 26%,transparent),transparent 45%);
  box-shadow:0 24px 58px rgba(0,0,0,.28),0 0 0 1px rgba(255,255,255,.56) inset;
}
.node:hover{
  box-shadow:0 30px 80px rgba(0,0,0,.34),0 0 0 6px color-mix(in srgb,var(--accent) 17%,transparent);
}
.edge-path{opacity:.50!important;stroke-width:3.4!important;filter:url(#glow)!important}
body .empty-canvas{
  background:linear-gradient(135deg,rgba(255,255,255,.92),rgba(237,247,255,.80));
}
.viz-target-row{
  display:flex;align-items:center;gap:12px;flex-wrap:wrap;
  border:1px solid #dce6fb;border-radius:22px;
  background:linear-gradient(180deg,#fff,#f6faff);
  padding:14px 16px;margin:8px 0 14px;
}
.viz-target-row span{text-transform:uppercase;font-size:11px;font-weight:950;letter-spacing:.7px;color:#6a78aa}
.viz-target-row b{font-size:22px;color:#07133f}
.viz-target-row small{color:#6071ad;font-weight:800}
.viz-tabs{
  display:flex;gap:10px;flex-wrap:wrap;
  padding:8px;border:1px solid #dce6fb;border-radius:20px;
  background:rgba(248,251,255,.78);margin-bottom:14px;
}
.viz-tab{
  height:38px;border:0;border-radius:14px;padding:0 16px;
  background:transparent;color:#52619b;font-weight:950;
}
.viz-tab.active{
  color:white;background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
  box-shadow:0 12px 24px rgba(112,92,255,.22);
}
.viz-pane{display:none}
.viz-pane.active{display:block}
.data-source-hero,.target-inline-card{
  border:1px solid #dce6fb;border-radius:24px;
  background:linear-gradient(180deg,#fff,#f7fbff);
  padding:18px;display:flex;justify-content:space-between;gap:18px;align-items:center;margin-bottom:14px;
}
.data-source-hero h3,.target-inline-card h3{margin:0 0 6px;font-size:22px}
.data-source-hero p,.target-inline-card p{margin:0;color:#52619b;font-weight:750;line-height:1.5}
.data-source-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}
.target-field{min-width:300px;margin-bottom:0}
.target-inline-card.disabled{opacity:.62}
.library-group:first-of-type h3:after{
  content:" · simple path";
  text-transform:none;letter-spacing:0;color:#7c8ab8;font-weight:800;
}
.node[data-status="complete"] .node-status{background:linear-gradient(90deg,#e8fff6,#eef5ff)}
@media (max-width:900px){
  .data-source-hero,.target-inline-card{display:block}
  .data-source-actions{justify-content:flex-start;margin-top:12px}
  .target-field{min-width:0;margin-top:12px}
  .viz-tabs{gap:6px}.viz-tab{padding:0 10px}
}


/* v13: histogram visibility fix */
.histogram-svg rect{
  vector-effect:non-scaling-stroke;
}
.viz-pane[data-pane="histogram"] .histogram-svg,
.recommended-card .histogram-svg{
  min-height:260px;
}
.scatter-primary-card .histogram-svg{
  height:430px;
}


/* v14: real high-contrast histogram bars */
.histogram-svg .hist-bg{
  fill:#101736 !important;
}
.histogram-svg .hist-grid{
  stroke:rgba(210,226,255,.16) !important;
  stroke-width:1 !important;
}
.histogram-svg .hist-axis{
  stroke:rgba(230,240,255,.55) !important;
  stroke-width:1.4 !important;
}
.histogram-svg .hist-bar{
  fill:#39d7c5 !important;
  stroke:rgba(255,255,255,.42) !important;
  stroke-width:1 !important;
  filter:drop-shadow(0 8px 14px rgba(57,215,197,.28));
}
.histogram-svg .hist-count{
  fill:#f3fbff !important;
  font-size:12px;
  font-weight:800;
}
.histogram-svg .hist-tick,
.histogram-svg .hist-muted{
  fill:#9fb2df !important;
  font-size:11px;
  font-weight:700;
}
.histogram-svg .hist-x-label,
.histogram-svg .hist-y-label,
.histogram-svg .hist-empty{
  fill:#dce6ff !important;
  font-size:14px;
  font-weight:800;
}
.histogram-svg .hist-empty{
  font-size:18px;
}
.histogram-svg .hist-mean-line{
  stroke:#ffbd4a !important;
  stroke-width:2.2 !important;
  stroke-dasharray:6 6;
}
.histogram-svg .hist-mean-label{
  fill:#ffdf90 !important;
  font-size:11px;
  font-weight:900;
  text-transform:uppercase;
}


/* v15: histogram inline SVG layout guard */
.histogram-svg{
  display:block!important;
  width:100%!important;
  height:100%!important;
  min-height:360px!important;
  background:#101736!important;
  border-radius:24px!important;
}
.viz-pane[data-pane="histogram"] .scatter-primary-card .big-svg{
  height:430px!important;
  min-height:390px!important;
}


/* v16: Data Source modal refresh UX */
.data-loaded-card{
  display:flex;
  align-items:center;
  gap:12px;
  border:1px solid #dce6fb;
  border-radius:20px;
  padding:14px 16px;
  margin:12px 0 14px;
  background:linear-gradient(180deg,#fff,#f7fbff);
}
.data-loaded-card.loaded{
  border-color:rgba(46,217,189,.42);
  background:linear-gradient(180deg,#f0fffb,#ffffff);
}
.loaded-dot{
  width:14px;
  height:14px;
  border-radius:999px;
  background:#b7c3df;
  box-shadow:0 0 0 6px rgba(183,195,223,.16);
}
.data-loaded-card.loaded .loaded-dot{
  background:#2ed9bd;
  box-shadow:0 0 0 7px rgba(46,217,189,.17);
}
.data-loaded-card b{
  font-size:15px;
  color:#07133f;
}
.data-loaded-card p{
  margin:3px 0 0;
  color:#5b6ca2;
  font-weight:750;
}
.columns-preview{
  border:1px solid #dce6fb;
  border-radius:20px;
  background:rgba(248,251,255,.72);
  padding:14px 16px;
  margin:12px 0 14px;
}
.columns-preview b{
  display:block;
  margin-bottom:9px;
}
.columns-preview div{
  display:flex;
  flex-wrap:wrap;
  gap:7px;
}
.data-chip{
  display:inline-flex;
  align-items:center;
  min-height:27px;
  padding:0 10px;
  border-radius:999px;
  background:#eef5ff;
  color:#243d82;
  font-weight:850;
  font-size:12px;
}
.data-source-next-row{
  display:flex;
  justify-content:flex-end;
  margin:14px 0 10px;
}
.data-source-next-row button:disabled{
  opacity:.45;
  cursor:not-allowed;
}


/* v17: product branding + bright data-flow edges */
.app-shell{
  grid-template-rows:76px minmax(0,1fr) 154px 48px;
}
.edge-path{
  opacity:.92!important;
  stroke-width:4.6!important;
  filter:
    drop-shadow(0 0 4px rgba(124,247,255,.95))
    drop-shadow(0 0 12px rgba(124,247,255,.58))
    drop-shadow(0 0 24px rgba(167,139,255,.35))!important;
  mix-blend-mode:screen;
}
.flow-canvas.flow-running .edge-path{
  opacity:1!important;
  stroke-width:5.2!important;
  stroke-dasharray:16 12;
  animation:edgeRun 620ms linear infinite;
  filter:
    drop-shadow(0 0 6px rgba(124,247,255,1))
    drop-shadow(0 0 18px rgba(255,117,200,.65))
    drop-shadow(0 0 32px rgba(66,245,179,.46))!important;
}
.edge-layer path:nth-of-type(2n){
  filter:
    drop-shadow(0 0 4px rgba(167,139,255,.95))
    drop-shadow(0 0 14px rgba(167,139,255,.54))!important;
}
.edge-layer path:nth-of-type(3n){
  filter:
    drop-shadow(0 0 4px rgba(255,117,200,.95))
    drop-shadow(0 0 14px rgba(255,117,200,.50))!important;
}
.edge-layer path:nth-of-type(4n){
  filter:
    drop-shadow(0 0 4px rgba(66,245,179,.95))
    drop-shadow(0 0 14px rgba(66,245,179,.50))!important;
}
.product-footer{
  grid-column:1 / -1;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  padding:0 22px;
  background:
    linear-gradient(90deg,rgba(7,18,38,.96),rgba(18,24,58,.94),rgba(7,18,38,.96));
  border-top:1px solid rgba(124,247,255,.22);
  box-shadow:0 -18px 40px rgba(0,0,0,.18);
  color:#eaf6ff;
}
.footer-brand{
  display:flex;
  align-items:center;
  gap:10px;
}
.footer-mark{
  width:30px;
  height:30px;
  border-radius:12px;
  display:grid;
  place-items:center;
  color:white;
  background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
  box-shadow:0 0 18px rgba(124,247,255,.32);
}
.footer-brand b{
  display:block;
  font-size:13px;
  letter-spacing:.2px;
}
.footer-brand small{
  display:block;
  margin-top:1px;
  color:#9fb2df;
  font-size:10px;
  font-weight:800;
}
.footer-credit{
  display:flex;
  align-items:center;
  gap:14px;
  flex-wrap:wrap;
  font-size:12px;
  font-weight:850;
  color:#dce9ff;
}
.footer-credit a,
.report-signature a{
  color:#7cf7ff;
  text-decoration:none;
  font-weight:950;
}
.footer-credit a:hover,
.report-signature a:hover{
  text-decoration:underline;
}
.author-chip{
  color:#07133f;
  background:linear-gradient(180deg,#ffffff,#eff7ff);
  border-color:rgba(124,247,255,.45);
}
.email-chip{
  color:#17235d;
  background:rgba(255,255,255,.78);
  border-color:rgba(167,139,255,.35);
}
.report-signature{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:16px;
  margin:24px 0 8px;
  padding:18px 20px;
  border-radius:24px;
  color:#eaf6ff;
  background:
    radial-gradient(circle at 0 0,rgba(94,216,255,.28),transparent 36%),
    linear-gradient(135deg,#071226,#111c44 58%,#271b4f);
  box-shadow:0 22px 50px rgba(7,18,38,.24);
}
.report-signature b{
  display:block;
  font-size:18px;
}
.report-signature span{
  display:block;
  color:#b8c8f0;
  font-weight:850;
  margin-top:3px;
}
.report-signature div:last-child{
  text-align:right;
}
@media (max-width:900px){
  .app-shell{
    grid-template-rows:auto auto auto auto;
  }
  .product-footer{
    flex-direction:column;
    align-items:flex-start;
    padding:12px 16px;
    min-height:72px;
  }
  .footer-credit{
    gap:8px;
  }
  .email-chip{
    display:none;
  }
  .report-signature{
    display:block;
  }
  .report-signature div:last-child{
    text-align:left;
    margin-top:12px;
  }
}


/* v18: make the product brand unmistakable */
.brand-block{
  min-width:270px;
}
.brand-block h1{
  font-size:24px;
  letter-spacing:-.85px;
  background:linear-gradient(135deg,#07133f,#1a58ff 45%,#ff65a3);
  -webkit-background-clip:text;
  background-clip:text;
  color:transparent;
}
.brand-block p{
  color:#44578f;
  font-size:10.5px;
  font-weight:950;
}
.brand-product-chip{
  color:#fff;
  background:linear-gradient(135deg,#071226,#1a2a70 54%,#7c3cff);
  border-color:rgba(124,247,255,.46);
  box-shadow:0 12px 26px rgba(20,38,100,.20);
}
.canvas-brand-watermark{
  position:absolute;
  right:22px;
  bottom:18px;
  z-index:4;
  display:flex;
  align-items:center;
  gap:11px;
  padding:12px 15px;
  border-radius:20px;
  color:#eaf6ff;
  background:
    radial-gradient(circle at 0 0,rgba(124,247,255,.20),transparent 35%),
    linear-gradient(135deg,rgba(7,18,38,.88),rgba(22,28,70,.78));
  border:1px solid rgba(124,247,255,.26);
  box-shadow:0 18px 50px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.12);
  backdrop-filter:blur(14px);
  pointer-events:none;
}
.canvas-brand-watermark span{
  width:34px;
  height:34px;
  border-radius:13px;
  display:grid;
  place-items:center;
  background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
  color:white;
  box-shadow:0 0 20px rgba(124,247,255,.38);
}
.canvas-brand-watermark b{
  display:block;
  font-size:14px;
  letter-spacing:.1px;
}
.canvas-brand-watermark small{
  display:block;
  margin-top:2px;
  color:#b8c8f0;
  font-size:10px;
  font-weight:850;
}
.footer-brand b{
  font-size:14px;
}
.footer-credit span{
  color:#ffffff;
}
.footer-credit a{
  padding:6px 10px;
  border-radius:999px;
  background:rgba(124,247,255,.10);
  border:1px solid rgba(124,247,255,.20);
}
.brand-hero-signature{
  display:inline-flex;
  align-items:center;
  margin-top:12px;
  padding:9px 13px;
  border-radius:999px;
  color:#eaf6ff;
  background:linear-gradient(135deg,#071226,#1a2a70);
  font-weight:950;
  box-shadow:0 12px 26px rgba(20,38,100,.22);
}
.report-signature{
  border:1px solid rgba(124,247,255,.25);
}
@media (max-width:900px){
  .brand-block{
    min-width:0;
  }
  .brand-block h1{
    font-size:21px;
  }
  .brand-product-chip,
  .canvas-brand-watermark{
    display:none;
  }
}


/* v19: Open CSV variable role/type settings */
.variable-settings-panel{
  border:1px solid #dce6fb;
  border-radius:24px;
  background:linear-gradient(180deg,#ffffff,#f7fbff);
  padding:16px;
  margin:14px 0;
}
.variable-settings-head{
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:flex-start;
  margin-bottom:12px;
}
.variable-settings-head h3{
  margin:0 0 6px;
  font-size:22px;
}
.variable-settings-head p{
  margin:0;
  color:#52619b;
  font-weight:750;
  line-height:1.45;
}
.settings-legend{
  display:flex;
  flex-direction:column;
  gap:6px;
  min-width:250px;
  color:#5869a2;
  font-size:12px;
  font-weight:800;
}
.settings-legend span{
  display:block;
  padding:7px 10px;
  border-radius:14px;
  background:#eef5ff;
}
.variable-table-wrap{
  max-height:360px;
  overflow:auto;
  border-radius:18px;
}
.variable-settings-table td,
.variable-settings-table th{
  font-size:12px;
  vertical-align:middle;
}
.variable-settings-table td:first-child small{
  display:block;
  margin-top:3px;
  color:#7c8ab8;
  font-size:10px;
  font-weight:800;
}
.var-role-select,
.var-type-select{
  width:130px;
  height:34px;
  border-radius:12px;
  border:1px solid #cfe0ff;
  background:#fff;
  color:#07133f;
  font-weight:850;
  padding:0 8px;
}
.role-pill{
  display:inline-flex;
  padding:5px 9px;
  border-radius:999px;
  font-size:11px;
  font-weight:950;
  text-transform:uppercase;
}
.role-pill.regular{
  color:#0d6d58;
  background:#e8fff8;
}
.role-pill.meta{
  color:#70531a;
  background:#fff5dc;
}
.target-ok,
.target-no{
  display:inline-flex;
  padding:5px 9px;
  border-radius:999px;
  font-size:11px;
  font-weight:950;
}
.target-ok{
  color:#0d6d58;
  background:#e8fff8;
}
.target-no{
  color:#7682a6;
  background:#f0f3fb;
}
@media(max-width:900px){
  .variable-settings-head{
    display:block;
  }
  .settings-legend{
    min-width:0;
    margin-top:10px;
  }
  .variable-table-wrap{
    overflow:auto;
  }
}


/* v20: Quality Check module */
.quality-modal-controls{
  display:grid;
  grid-template-columns:1fr 1fr auto;
  gap:12px;
  align-items:end;
  padding:14px;
  margin:10px 0 16px;
  border:1px solid #dce6fb;
  border-radius:22px;
  background:linear-gradient(180deg,#fff,#f7fbff);
}
.quality-modal-controls .primary-btn{
  height:42px;
}
.muted-control{
  opacity:.48;
  filter:saturate(.7);
}
@media(max-width:900px){
  .quality-modal-controls{
    grid-template-columns:1fr;
  }
}


/* v21: richer final report, fewer author repetitions */
.clean-report-hero h2{
  font-size:42px;
  max-width:760px;
}
.clean-report-hero .brand-hero-signature{
  display:none!important;
}
.report-visual-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
  margin-top:12px;
}
.report-visual-card{
  border:1px solid #dce6fb;
  border-radius:26px;
  padding:16px;
  background:linear-gradient(180deg,#ffffff,#f7fbff);
  box-shadow:0 18px 42px rgba(43,74,140,.08);
}
.report-visual-card h4{
  margin:0 0 8px;
  font-size:20px;
  color:#07133f;
}
.report-visual-card p{
  margin:0 0 12px;
  color:#52619b;
  font-weight:750;
  line-height:1.45;
}
.report-visual-card .big-svg{
  height:300px!important;
  min-height:300px!important;
}
.analysis-conclusion{
  margin-top:16px;
  padding:18px 20px;
  border-radius:24px;
  background:linear-gradient(135deg,#f0fbff,#fff6fb);
  border:1px solid #dce6fb;
}
.analysis-conclusion b{
  display:block;
  font-size:18px;
  margin-bottom:6px;
  color:#07133f;
}
.analysis-conclusion p{
  margin:0;
  color:#2d3d78;
  font-weight:800;
  line-height:1.55;
}
.conclusion-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:14px;
}
.conclusion-grid .exec-card h4{
  margin:0 0 8px;
  font-size:18px;
}
.conclusion-grid .exec-card p{
  margin:0;
  line-height:1.55;
}
.compact-signature{
  margin-top:18px;
  opacity:.95;
}
@media(max-width:900px){
  .report-visual-grid,
  .conclusion-grid{
    grid-template-columns:1fr;
  }
  .clean-report-hero h2{
    font-size:32px;
  }
}


/* v23: equation, multi-visual report and correlation matrix */
.equation-box{
  border:1px solid #dce6fb;
  border-radius:24px;
  padding:18px 20px;
  background:
    radial-gradient(circle at 0 0,rgba(94,216,255,.18),transparent 34%),
    linear-gradient(180deg,#ffffff,#f7fbff);
  margin-bottom:14px;
}
.equation-formula{
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size:18px;
  font-weight:900;
  color:#07133f;
  line-height:1.55;
  overflow-wrap:anywhere;
}
.equation-note{
  margin-top:8px;
  color:#52619b;
  font-weight:800;
  line-height:1.45;
}
.equation-table td:nth-child(2){
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight:850;
}
.multi-visuals{
  grid-template-columns:repeat(3,minmax(0,1fr));
}
.multi-visuals .report-visual-card .big-svg{
  height:260px!important;
  min-height:260px!important;
}
.corr-matrix-wrap{
  overflow:auto;
  border-radius:20px;
  border:1px solid #dce6fb;
  margin-bottom:16px;
}
.corr-matrix{
  min-width:720px;
}
.corr-matrix th{
  position:sticky;
  left:0;
  background:#f7fbff;
  z-index:1;
}
.corr-matrix td{
  text-align:center;
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight:850;
}
.corr-matrix .corr-warn{
  background:#fff5dc;
  color:#7b5200;
}
.corr-matrix .corr-danger{
  background:#ffe8ef;
  color:#9b133d;
}
.analysis-conclusion.safe{
  background:linear-gradient(135deg,#f0fffb,#ffffff);
  border-color:rgba(46,217,189,.36);
}
.analysis-conclusion.danger{
  background:linear-gradient(135deg,#fff5f8,#fffaf0);
  border-color:rgba(255,101,163,.34);
}
@media(max-width:1100px){
  .multi-visuals{
    grid-template-columns:1fr;
  }
  .multi-visuals .report-visual-card .big-svg{
    height:320px!important;
  }
}


/* v24: corrected regression equation display */
.equation-label{
  display:inline-flex;
  padding:6px 10px;
  margin-bottom:10px;
  border-radius:999px;
  color:#ffffff;
  background:linear-gradient(135deg,#071226,#1a2a70);
  font-size:12px;
  font-weight:950;
  text-transform:uppercase;
  letter-spacing:.4px;
}
.equation-subformula{
  margin-top:10px;
  padding:10px 12px;
  border-radius:16px;
  background:#eef5ff;
  color:#243d82;
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight:850;
  line-height:1.45;
  overflow-wrap:anywhere;
}
.equation-table th,
.equation-table td{
  font-size:12px;
}
.equation-table td:nth-child(2),
.equation-table td:nth-child(3),
.equation-table td:nth-child(4),
.equation-table td:nth-child(5){
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight:850;
}


/* v25: final all-data equation clarity */
.technical-equation-details{
  margin-top:12px;
  border-radius:18px;
  background:#eef5ff;
  padding:10px 12px;
}
.technical-equation-details summary{
  cursor:pointer;
  color:#243d82;
  font-weight:950;
  font-size:13px;
}
.technical-equation-details .equation-subformula{
  margin-top:10px;
  background:#ffffff;
}
.equation-note b{
  color:#07133f;
}


/* v26: stronger scatter grid */
.scatter-svg line{
  vector-effect:non-scaling-stroke;
}
.scatter-svg circle{
  vector-effect:non-scaling-stroke;
}


/* v27: mobile guided mode */
.mobile-guided-panel{
  display:none;
}
.node{
  touch-action:none;
}
@media (max-width: 900px){
  body{
    overflow:auto;
  }
  .app-shell{
    grid-template-rows:auto minmax(0,1fr) auto auto;
  }
  .topbar{
    display:block;
    padding:10px 12px;
  }
  .brand-block{
    margin-bottom:10px;
  }
  .toolbar{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:8px;
  }
  .toolbar button,
  .toolbar label{
    width:100%;
    justify-content:center;
    min-height:42px;
  }
  .workspace{
    display:block!important;
  }
  .canvas-shell{
    min-height:calc(100vh - 210px);
  }
  .canvas-toolbar{
    height:auto;
    display:block;
    padding:10px 12px;
  }
  .canvas-status{
    margin-bottom:8px;
  }
  .mini-actions{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:8px;
  }
  .mini-actions button{
    min-height:38px;
  }
  .flow-canvas{
    min-height:calc(100vh - 260px);
    height:auto!important;
    padding:14px;
    overflow:visible;
  }
  .mobile-guided-panel{
    position:relative;
    z-index:8;
    display:block;
    width:100%;
    max-width:560px;
    margin:0 auto;
    padding:14px;
    border-radius:28px;
    background:linear-gradient(180deg,rgba(255,255,255,.94),rgba(240,247,255,.88));
    border:1px solid rgba(180,210,255,.56);
    box-shadow:0 24px 70px rgba(0,0,0,.30), inset 0 1px 0 rgba(255,255,255,.62);
    backdrop-filter:blur(18px);
  }
  .mobile-hero{
    display:flex;
    align-items:center;
    gap:12px;
    padding:12px;
    border-radius:22px;
    background:
      radial-gradient(circle at 0 0,rgba(94,216,255,.26),transparent 34%),
      linear-gradient(135deg,#071226,#19245d 60%,#49246d);
    color:white;
    margin-bottom:12px;
  }
  .mobile-hero span{
    min-width:42px;
    height:42px;
    border-radius:16px;
    display:grid;
    place-items:center;
    background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
    box-shadow:0 0 22px rgba(124,247,255,.36);
  }
  .mobile-hero b{
    display:block;
    font-size:17px;
  }
  .mobile-hero small{
    display:block;
    margin-top:2px;
    color:#c5d6ff;
    font-weight:800;
  }
  .mobile-quick-actions{
    display:grid;
    grid-template-columns:1.3fr .8fr .8fr;
    gap:8px;
    margin-bottom:12px;
  }
  .mobile-quick-actions button{
    min-height:42px;
    justify-content:center;
    padding:0 10px;
  }
  .mobile-steps{
    display:grid;
    gap:10px;
  }
  .mobile-step{
    display:grid;
    grid-template-columns:42px 1fr auto;
    align-items:center;
    gap:11px;
    width:100%;
    text-align:left;
    border:1px solid #dce6fb;
    border-radius:22px;
    background:linear-gradient(180deg,#ffffff,#f7fbff);
    padding:12px;
    box-shadow:0 12px 26px rgba(43,74,140,.08);
  }
  .mobile-step:disabled{
    opacity:.50;
    filter:saturate(.75);
  }
  .mobile-step-num{
    width:42px;
    height:42px;
    border-radius:15px;
    display:grid;
    place-items:center;
    color:white;
    font-weight:950;
    background:linear-gradient(135deg,#5ed8ff,#705cff);
  }
  .mobile-step.complete .mobile-step-num{
    background:linear-gradient(135deg,#2ed9bd,#42f5b3);
  }
  .mobile-step.error .mobile-step-num{
    background:linear-gradient(135deg,#ff5f93,#ffbd4a);
  }
  .mobile-step-main b{
    display:block;
    color:#07133f;
    font-size:15px;
  }
  .mobile-step-main small,
  .mobile-step-main em{
    display:block;
    color:#5a6ba5;
    font-weight:750;
    font-style:normal;
    line-height:1.35;
    margin-top:2px;
  }
  .mobile-step-main em{
    color:#243d82;
    font-weight:900;
  }
  .mobile-step-status{
    padding:6px 8px;
    border-radius:999px;
    color:#42558f;
    background:#eef5ff;
    font-size:10px;
    font-weight:950;
    white-space:nowrap;
  }
  .mobile-step.complete .mobile-step-status{
    color:#0d6d58;
    background:#e8fff8;
  }
  .nodes-layer,
  .edge-svg,
  .canvas-brand-watermark,
  .empty-canvas{
    display:none!important;
  }
  .inspector{
    display:none!important;
  }
  .bottom-dock{
    display:none!important;
  }
  .product-footer{
    position:relative;
  }
  .module-dialog,
  .report-card{
    width:96vw!important;
    max-width:96vw!important;
    max-height:92vh!important;
    border-radius:24px!important;
  }
  .report-card{
    overflow:auto;
  }
  .module-dialog::backdrop,
  .report-dialog::backdrop{
    backdrop-filter:blur(8px);
  }
  .modal-two-col,
  .scatter-layout,
  .relationship-grid,
  .report-visual-grid,
  .conclusion-grid,
  .recommended-visuals-grid{
    grid-template-columns:1fr!important;
  }
  .chart-control-row,
  .quality-modal-controls{
    grid-template-columns:1fr!important;
  }
  .big-svg,
  .scatter-primary-card .big-svg,
  .report-visual-card .big-svg{
    height:300px!important;
    min-height:300px!important;
  }
  .variable-settings-head,
  .data-source-hero,
  .target-inline-card{
    display:block!important;
  }
  .data-source-actions{
    margin-top:12px;
    justify-content:flex-start;
  }
  .variable-table-wrap,
  .modal-table-wrap,
  .corr-matrix-wrap{
    overflow:auto;
    -webkit-overflow-scrolling:touch;
  }
}
@media (max-width: 520px){
  .toolbar,
  .mobile-quick-actions,
  .mini-actions{
    grid-template-columns:1fr;
  }
  .mobile-step{
    grid-template-columns:36px 1fr;
  }
  .mobile-step-status{
    grid-column:2;
    width:max-content;
  }
  .mobile-step-num{
    width:36px;
    height:36px;
  }
  .final-hero,
  .module-hero{
    padding:18px!important;
  }
  .final-hero h2,
  .module-hero h2{
    font-size:28px!important;
  }
}


/* v28: studio / showcase modes */
.mode-switch{
  display:inline-flex;
  align-items:center;
  gap:4px;
  padding:4px;
  border-radius:999px;
  background:rgba(255,255,255,.72);
  border:1px solid rgba(185,205,255,.65);
  box-shadow:0 10px 24px rgba(43,74,140,.08);
}
.mode-btn{
  border:none;
  background:transparent;
  color:#41558f;
  font-weight:900;
  font-size:12px;
  padding:9px 14px;
  border-radius:999px;
  cursor:pointer;
}
.mode-btn.active{
  color:#fff;
  background:linear-gradient(135deg,#071226,#2448d8 60%,#7c3cff);
  box-shadow:0 10px 24px rgba(36,72,216,.22);
}
.showcase-stage{ display:none; }
body.mode-showcase .showcase-stage{
  display:block;
  position:relative;
  z-index:9;
  width:100%;
  min-height:calc(100vh - 220px);
}
body.mode-showcase .module-library,
body.mode-showcase .inspector,
body.mode-showcase .bottom-dock,
body.mode-showcase .canvas-toolbar,
body.mode-showcase #nodesLayer,
body.mode-showcase #edgeSvg,
body.mode-showcase .canvas-brand-watermark,
body.mode-showcase .mobile-guided-panel{
  display:none !important;
}
body.mode-showcase .workspace{
  display:block;
}
body.mode-showcase .canvas-section{
  width:100%;
}
body.mode-showcase .flow-canvas{
  min-height:calc(100vh - 170px);
  padding:24px;
}
body.mode-showcase #saveFlowBtn,
body.mode-showcase #exportFlowBtn,
body.mode-showcase #resetViewBtn,
body.mode-showcase #globalHelpBtn,
body.mode-showcase .avatar-chip,
body.mode-showcase #autoLayoutBtn,
body.mode-showcase #clearEdgesBtn,
body.mode-showcase #undoEdgesBtn{
  display:none !important;
}
body.mode-showcase .topbar{
  grid-template-columns:minmax(220px,340px) 1fr auto;
}
.showcase-shell{
  min-height:calc(100vh - 220px);
  border-radius:34px;
  padding:24px;
  background:
    radial-gradient(circle at 0 0,rgba(94,216,255,.16),transparent 28%),
    radial-gradient(circle at 100% 0,rgba(255,101,163,.12),transparent 28%),
    linear-gradient(180deg,rgba(255,255,255,.88),rgba(245,249,255,.92));
  border:1px solid rgba(195,215,255,.56);
  box-shadow:0 30px 90px rgba(0,0,0,.16), inset 0 1px 0 rgba(255,255,255,.62);
  backdrop-filter:blur(18px);
}
.showcase-head{
  display:flex;
  justify-content:space-between;
  gap:18px;
  align-items:flex-start;
  margin-bottom:16px;
}
.showcase-badge{
  display:inline-flex;
  padding:7px 12px;
  border-radius:999px;
  background:linear-gradient(135deg,#071226,#1c2c75);
  color:#fff;
  font-size:11px;
  font-weight:950;
  text-transform:uppercase;
  letter-spacing:.35px;
}
.showcase-head h2{
  margin:12px 0 6px;
  color:#07133f;
  font-size:36px;
  letter-spacing:-1px;
}
.showcase-head p{
  margin:0;
  color:#53639b;
  font-weight:800;
}
.showcase-head-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  justify-content:flex-end;
}
.showcase-tab{
  border:none;
  background:#eef5ff;
  color:#32467c;
  font-weight:900;
  font-size:12px;
  padding:11px 14px;
  border-radius:14px;
  cursor:pointer;
}
.showcase-tab.active{
  color:#fff;
  background:linear-gradient(135deg,#5ed8ff,#3260ff 55%,#9656ff);
  box-shadow:0 14px 30px rgba(50,96,255,.25);
}
.showcase-insight-card{
  padding:16px 18px;
  border-radius:24px;
  background:linear-gradient(135deg,#effbff,#fff5fb);
  border:1px solid #dce6fb;
  margin-bottom:14px;
}
.showcase-insight-card b{
  display:block;
  margin-bottom:6px;
  color:#07133f;
  font-size:18px;
}
.showcase-insight-card p{
  margin:0;
  color:#2e3d75;
  font-weight:800;
  line-height:1.55;
}
.showcase-controls-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
  margin-bottom:14px;
}
.showcase-controls-grid.compact{
  grid-template-columns:repeat(2,minmax(0,1fr));
}
.showcase-note-pill{
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:0 14px;
  border-radius:14px;
  background:#eef5ff;
  color:#35487d;
  font-weight:850;
}
.showcase-chart-wrap{
  min-height:62vh;
  display:flex;
  align-items:stretch;
}
.showcase-plot-frame,
.showcase-corr-frame,
.showcase-empty{
  width:100%;
  border-radius:28px;
  padding:16px;
  background:linear-gradient(180deg,#0c1430,#15214b 60%,#131b3d);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.06), 0 28px 60px rgba(6,14,38,.34);
}
.showcase-corr-frame{
  background:linear-gradient(180deg,#ffffff,#f7fbff);
  border:1px solid #dce6fb;
}
.showcase-empty{
  display:grid;
  place-items:center;
  text-align:center;
  color:#dce6ff;
}
.showcase-empty b{
  font-size:22px;
}
.showcase-empty small{
  display:block;
  margin-top:8px;
  color:#a9bbe4;
  font-weight:800;
}
.showcase-plot-frame .big-svg{
  height:72vh !important;
  min-height:620px !important;
}
.showcase-corr-frame .corr-matrix-wrap{
  height:72vh;
  overflow:auto;
  background:#fff;
}
.showcase-footer-note{
  margin-top:12px;
  color:#6a79a8;
  font-size:12px;
  font-weight:800;
  text-align:right;
}
@media (max-width: 1100px){
  .showcase-head,
  body.mode-showcase .topbar{
    display:block;
  }
  .showcase-head-actions{
    margin-top:12px;
    justify-content:flex-start;
  }
  .showcase-controls-grid,
  .showcase-controls-grid.compact{
    grid-template-columns:1fr;
  }
  .showcase-plot-frame .big-svg{
    height:54vh !important;
    min-height:360px !important;
  }
}


/* v29: Showcase is now the clean clickable flow diagram, not a separate chart stage */
body.mode-showcase .showcase-stage{
  display:none!important;
}
body.mode-showcase .module-library,
body.mode-showcase .inspector,
body.mode-showcase .bottom-dock,
body.mode-showcase .canvas-toolbar,
body.mode-showcase .mobile-guided-panel{
  display:none!important;
}
body.mode-showcase .workspace{
  display:block!important;
}
body.mode-showcase .canvas-section{
  width:100%;
  min-height:calc(100vh - 92px);
}
body.mode-showcase .flow-canvas{
  min-height:calc(100vh - 112px);
  height:calc(100vh - 112px);
  padding:0;
  overflow:hidden;
  background-image:
    radial-gradient(rgba(124,247,255,.20) 1px, transparent 1px),
    radial-gradient(circle at 18% 20%,rgba(89,216,255,.26),transparent 32%),
    radial-gradient(circle at 84% 18%,rgba(255,101,163,.18),transparent 30%),
    radial-gradient(circle at 50% 88%,rgba(66,245,179,.16),transparent 34%),
    linear-gradient(135deg,#061023 0%,#101a3a 42%,#1a1d4d 72%,#07182d 100%)!important;
  background-size:24px 24px, auto, auto, auto, auto;
}
body.mode-showcase #nodesLayer,
body.mode-showcase #edgeSvg{
  display:block!important;
}
body.mode-showcase #edgeSvg{
  opacity:1;
}
body.mode-showcase .edge-path{
  opacity:1!important;
  stroke-width:5.6!important;
  filter:
    drop-shadow(0 0 6px rgba(124,247,255,1))
    drop-shadow(0 0 18px rgba(124,247,255,.58))
    drop-shadow(0 0 34px rgba(255,117,200,.32))!important;
}
body.mode-showcase .node{
  width:246px;
  min-height:126px;
  cursor:pointer;
  transform:scale(1.05);
  box-shadow:
    0 32px 90px rgba(0,0,0,.34),
    0 0 0 1px rgba(255,255,255,.72) inset,
    0 0 34px color-mix(in srgb,var(--accent) 24%,transparent);
}
body.mode-showcase .node:hover{
  transform:scale(1.09) translateY(-4px);
  box-shadow:
    0 38px 110px rgba(0,0,0,.42),
    0 0 0 6px color-mix(in srgb,var(--accent) 20%,transparent),
    0 0 42px color-mix(in srgb,var(--accent) 34%,transparent);
}
body.mode-showcase .node-menu{
  display:none!important;
}
body.mode-showcase .port{
  visibility:hidden!important;
  opacity:0!important;
  pointer-events:none!important;
}
body.mode-showcase .node-title{
  font-size:15px;
}
body.mode-showcase .node-copy small{
  font-size:10.5px;
}
body.mode-showcase .node-status{
  font-size:10.5px;
}
body.mode-showcase .topbar{
  grid-template-columns:minmax(260px,420px) 1fr auto;
  background:linear-gradient(90deg,rgba(7,18,38,.96),rgba(18,24,58,.92));
  border-bottom:1px solid rgba(124,247,255,.22);
}
body.mode-showcase .brand-block h1{
  color:#ffffff;
  -webkit-text-fill-color:#ffffff;
}
body.mode-showcase .brand-block p{
  color:#b8c8f0;
}
body.mode-showcase #saveFlowBtn,
body.mode-showcase #exportFlowBtn,
body.mode-showcase #resetViewBtn,
body.mode-showcase #globalHelpBtn,
body.mode-showcase .avatar-chip{
  display:none!important;
}
.showcase-flow-hint{
  display:none;
}
body.mode-showcase .showcase-flow-hint{
  display:flex;
  position:absolute;
  z-index:6;
  left:28px;
  bottom:26px;
  align-items:center;
  gap:12px;
  padding:14px 16px;
  border-radius:22px;
  color:#eaf6ff;
  background:
    radial-gradient(circle at 0 0,rgba(124,247,255,.22),transparent 34%),
    linear-gradient(135deg,rgba(7,18,38,.88),rgba(20,30,78,.78));
  border:1px solid rgba(124,247,255,.28);
  box-shadow:0 22px 60px rgba(0,0,0,.32), inset 0 1px 0 rgba(255,255,255,.12);
  backdrop-filter:blur(14px);
  pointer-events:none;
}
.showcase-flow-hint span{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:42px;
  height:42px;
  border-radius:16px;
  background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
  color:white;
  font-weight:950;
  box-shadow:0 0 22px rgba(124,247,255,.38);
}
.showcase-flow-hint b{
  font-size:15px;
}
body.mode-showcase .canvas-brand-watermark{
  display:flex!important;
  top:26px;
  right:28px;
  bottom:auto;
}
body.mode-showcase .product-footer{
  display:none;
}
body.mode-showcase .module-dialog .report-card,
body.mode-showcase .report-dialog .report-card{
  box-shadow:0 34px 100px rgba(0,0,0,.44);
}
@media(max-width:900px){
  body.mode-showcase .topbar{
    display:block;
  }
  body.mode-showcase .flow-canvas{
    min-height:calc(100vh - 160px);
    height:auto;
  }
  body.mode-showcase .node{
    transform:none;
  }
}


/* v30: showcase edges fix */
body.mode-showcase #edgeSvg{
  display:block!important;
  opacity:1!important;
  z-index:2!important;
}
body.mode-showcase #nodesLayer{
  z-index:3!important;
}
body.mode-showcase .edge-path{
  opacity:1!important;
  stroke-width:5.6!important;
  filter:
    drop-shadow(0 0 6px rgba(124,247,255,1))
    drop-shadow(0 0 18px rgba(124,247,255,.62))
    drop-shadow(0 0 34px rgba(255,117,200,.34))!important;
}


/* v33: clean usable showcase = only the diagram */
body.mode-showcase .showcase-stage,
body.mode-showcase .showcase-flow-hint,
body.mode-showcase .canvas-brand-watermark,
body.mode-showcase .product-footer,
body.mode-showcase .module-library,
body.mode-showcase .inspector,
body.mode-showcase .bottom-dock,
body.mode-showcase .canvas-toolbar,
body.mode-showcase .mobile-guided-panel,
body.mode-showcase .node-menu,
body.mode-showcase .avatar-chip,
body.mode-showcase #saveFlowBtn,
body.mode-showcase #exportFlowBtn,
body.mode-showcase #resetViewBtn,
body.mode-showcase #globalHelpBtn,
body.mode-showcase #autoLayoutBtn,
body.mode-showcase #clearEdgesBtn,
body.mode-showcase #undoEdgesBtn{
  display:none !important;
}

body.mode-showcase .workspace{
  display:block !important;
}
body.mode-showcase .canvas-section{
  width:100% !important;
  min-height:calc(100vh - 82px) !important;
}
body.mode-showcase .topbar{
  grid-template-columns:minmax(220px,420px) 1fr auto !important;
  background:linear-gradient(90deg,rgba(7,18,38,.96),rgba(18,24,58,.92)) !important;
  border-bottom:1px solid rgba(124,247,255,.18) !important;
}
body.mode-showcase .flow-canvas{
  min-height:calc(100vh - 82px) !important;
  height:calc(100vh - 82px) !important;
  padding:0 !important;
  overflow:hidden !important;
  background-image:
    radial-gradient(rgba(124,247,255,.16) 1px, transparent 1px),
    radial-gradient(circle at 18% 20%,rgba(89,216,255,.22),transparent 32%),
    radial-gradient(circle at 84% 18%,rgba(255,101,163,.14),transparent 30%),
    radial-gradient(circle at 50% 88%,rgba(66,245,179,.12),transparent 34%),
    linear-gradient(135deg,#061023 0%,#101a3a 42%,#1a1d4d 72%,#07182d 100%) !important;
  background-size:24px 24px, auto, auto, auto, auto !important;
}
body.mode-showcase #nodesLayer,
body.mode-showcase #edgeSvg{
  display:block !important;
  visibility:visible !important;
}
body.mode-showcase #nodesLayer{
  z-index:3 !important;
}
body.mode-showcase #edgeSvg{
  z-index:2 !important;
  opacity:1 !important;
  pointer-events:none !important;
}
body.mode-showcase .port{
  visibility:hidden !important;
  opacity:0 !important;
  pointer-events:none !important;
}
body.mode-showcase .edge-path{
  opacity:1 !important;
  stroke-width:5.8 !important;
  filter:
    drop-shadow(0 0 7px rgba(124,247,255,.98))
    drop-shadow(0 0 20px rgba(124,247,255,.60))
    drop-shadow(0 0 34px rgba(255,117,200,.28)) !important;
}
body.mode-showcase .node{
  width:246px !important;
  min-height:126px !important;
  cursor:grab !important;
  transform:scale(1.04);
  box-shadow:
    0 28px 80px rgba(0,0,0,.32),
    0 0 0 1px rgba(255,255,255,.70) inset,
    0 0 28px color-mix(in srgb,var(--accent) 22%,transparent) !important;
}
body.mode-showcase .node:hover{
  transform:scale(1.07) translateY(-2px) !important;
}
body.mode-showcase .node:active{
  cursor:grabbing !important;
}
body.mode-showcase .node.selected,
body.mode-showcase .node.active-run{
  box-shadow:
    0 34px 96px rgba(0,0,0,.38),
    0 0 0 2px rgba(255,255,255,.86) inset,
    0 0 0 6px color-mix(in srgb,var(--accent) 22%,transparent),
    0 0 36px color-mix(in srgb,var(--accent) 38%,transparent) !important;
}
body.mode-showcase .module-dialog::backdrop,
body.mode-showcase .report-dialog::backdrop{
  background:rgba(4,10,24,.58) !important;
  backdrop-filter:blur(8px) !important;
}
body.mode-showcase .module-card,
body.mode-showcase .report-card{
  box-shadow:0 36px 110px rgba(0,0,0,.44) !important;
}
@media (max-width:900px){
  body.mode-showcase .topbar{
    display:block !important;
  }
  body.mode-showcase .flow-canvas{
    min-height:calc(100vh - 126px) !important;
    height:calc(100vh - 126px) !important;
  }
}


/* v34: two shared interfaces — professional studio + literal data sandbox */
.mode-welcome{
  position:fixed;
  inset:0;
  z-index:200;
  display:grid;
  place-items:center;
  padding:24px;
  background:
    radial-gradient(circle at 14% 12%,rgba(90,220,255,.26),transparent 28%),
    radial-gradient(circle at 86% 18%,rgba(255,188,75,.30),transparent 30%),
    linear-gradient(135deg,rgba(7,18,48,.92),rgba(26,31,82,.92));
  backdrop-filter:blur(14px);
  transition:opacity .24s ease, visibility .24s ease;
}
.mode-welcome.hidden{
  opacity:0;
  visibility:hidden;
  pointer-events:none;
}
.mode-welcome-card{
  width:min(860px,96vw);
  padding:34px;
  border-radius:34px;
  text-align:center;
  color:#102052;
  background:rgba(255,255,255,.96);
  border:1px solid rgba(255,255,255,.72);
  box-shadow:0 42px 120px rgba(0,0,0,.34),inset 0 1px 0 #fff;
}
.mode-welcome-mark{
  width:68px;
  height:68px;
  margin:-4px auto 12px;
  border-radius:24px;
  display:grid;
  place-items:center;
  font-size:34px;
  font-weight:950;
  color:white;
  background:linear-gradient(135deg,#5ed8ff,#705cff 55%,#ff65a3);
  box-shadow:0 18px 42px rgba(99,87,255,.30);
}
.mode-welcome-kicker{
  margin:0;
  color:#6557ff;
  font-size:12px;
  font-weight:950;
  letter-spacing:.12em;
  text-transform:uppercase;
}
.mode-welcome h2{
  margin:8px 0 9px;
  font-size:clamp(30px,4vw,46px);
  line-height:1.04;
  letter-spacing:-1.6px;
}
.mode-welcome-copy{
  max-width:650px;
  margin:0 auto 24px;
  color:#5c6999;
  font-weight:700;
  line-height:1.55;
}
.mode-choice-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:16px;
}
.mode-choice{
  min-height:180px;
  padding:24px;
  border:2px solid transparent;
  border-radius:26px;
  text-align:left;
  display:grid;
  grid-template-columns:74px 1fr;
  align-items:center;
  gap:18px;
  color:#102052;
  transition:transform .2s ease,box-shadow .2s ease,border-color .2s ease;
}
.mode-choice:hover{
  transform:translateY(-5px);
}
.mode-choice-studio{
  background:linear-gradient(145deg,#f5f9ff,#e9efff);
  border-color:#d7e2ff;
}
.mode-choice-studio:hover{
  border-color:#776aff;
  box-shadow:0 22px 50px rgba(90,88,205,.18);
}
.mode-choice-sandbox{
  background:
    radial-gradient(circle at 18% 18%,rgba(255,255,255,.34) 0 2px,transparent 3px),
    linear-gradient(145deg,#fff3bd,#eab96b);
  background-size:15px 15px,auto;
  border-color:#e9b253;
}
.mode-choice-sandbox:hover{
  border-color:#c57c25;
  box-shadow:0 22px 50px rgba(169,105,35,.22);
}
.mode-choice-art{
  width:74px;
  height:74px;
  border-radius:24px;
  display:grid;
  place-items:center;
  font-size:42px;
  background:rgba(255,255,255,.72);
  box-shadow:0 12px 28px rgba(34,52,100,.12);
}
.mode-choice b{
  display:block;
  margin-bottom:8px;
  font-size:24px;
}
.mode-choice small{
  display:block;
  color:#52618e;
  font-weight:750;
  line-height:1.45;
}
.mode-welcome-note{
  display:block;
  margin-top:18px;
  color:#7580a8;
  font-weight:750;
}

.sandbox-decor,
.sandbox-title{
  display:none;
}

body.mode-showcase{
  background:#e8bd70;
}
body.mode-showcase .topbar{
  color:#4b2c16 !important;
  background:
    radial-gradient(circle at 12% 20%,rgba(255,255,255,.54),transparent 25%),
    linear-gradient(90deg,#fff1bd,#f5cf82 54%,#e9ad55) !important;
  border-bottom:2px solid rgba(142,85,32,.28) !important;
  box-shadow:0 12px 34px rgba(112,71,26,.20) !important;
}
body.mode-showcase .brand-block{
  border-right-color:rgba(139,86,35,.24);
}
body.mode-showcase .brand-block h1{
  color:#4a2b15 !important;
  -webkit-text-fill-color:#4a2b15 !important;
}
body.mode-showcase .brand-block p{
  color:#7c4b25 !important;
}
body.mode-showcase .brand-icon{
  background:linear-gradient(145deg,#ffef9d,#f39d44);
  box-shadow:inset 0 0 0 2px rgba(129,72,24,.16),0 12px 24px rgba(137,80,26,.18);
}
body.mode-showcase .primary-btn,
body.mode-showcase .report-top-btn{
  background:linear-gradient(135deg,#ff6f4f,#e84737) !important;
  box-shadow:0 12px 24px rgba(184,55,36,.26) !important;
}
body.mode-showcase .ghost-btn{
  color:#633a1d;
  background:rgba(255,249,220,.82);
  border-color:rgba(132,78,32,.30);
}
body.mode-showcase .mode-switch{
  background:rgba(111,64,25,.12);
  border-color:rgba(111,64,25,.26);
}
body.mode-showcase .toolbar{
  gap:8px;
  overflow-x:auto;
  scrollbar-width:none;
}
body.mode-showcase .toolbar::-webkit-scrollbar{
  display:none;
}
body.mode-showcase .toolbar .primary-btn,
body.mode-showcase .toolbar .ghost-btn,
body.mode-showcase .toolbar .report-top-btn{
  padding-left:13px;
  padding-right:13px;
}
body.mode-showcase .mode-btn{
  color:#75431f;
}
body.mode-showcase .mode-btn.active{
  color:#fff9e7;
  background:linear-gradient(135deg,#1ba99a,#087f76);
  box-shadow:0 8px 18px rgba(7,112,103,.26);
}
body.mode-showcase .flow-canvas{
  isolation:isolate;
  border-top:5px solid rgba(116,70,28,.16);
  background-color:#e7bd70 !important;
  background-image:
    radial-gradient(circle at 16% 22%,rgba(255,248,197,.55) 0 2px,transparent 3px),
    radial-gradient(circle at 68% 58%,rgba(126,77,31,.12) 0 1px,transparent 2px),
    radial-gradient(circle at 44% 74%,rgba(255,255,255,.20) 0 1px,transparent 2px),
    linear-gradient(155deg,#f4d893 0%,#e8bd6e 48%,#d9a453 100%) !important;
  background-size:29px 29px,19px 19px,13px 13px,auto !important;
  box-shadow:inset 0 18px 45px rgba(109,66,25,.12),inset 0 -18px 60px rgba(94,54,17,.18);
}
body.mode-showcase .flow-canvas::after{
  content:"";
  position:absolute;
  inset:0;
  z-index:0;
  pointer-events:none;
  opacity:.42;
  background:
    radial-gradient(ellipse at 10% 82%,transparent 0 52px,rgba(125,76,28,.24) 54px 57px,transparent 59px),
    radial-gradient(ellipse at 77% 20%,transparent 0 82px,rgba(255,247,191,.28) 84px 88px,transparent 90px),
    radial-gradient(ellipse at 54% 68%,transparent 0 104px,rgba(126,77,31,.15) 106px 110px,transparent 112px);
}
body.mode-showcase .grid-glow{
  z-index:0;
  background:
    radial-gradient(circle at 45% 38%,rgba(255,245,189,.32),transparent 36%),
    radial-gradient(circle at 80% 78%,rgba(130,78,29,.12),transparent 34%);
}
body.mode-showcase .sandbox-decor,
body.mode-showcase .sandbox-title{
  display:block;
}
.sandbox-decor{
  position:absolute;
  inset:0;
  z-index:1;
  pointer-events:none;
  overflow:hidden;
}
.sandbox-sun{
  position:absolute;
  right:42px;
  top:34px;
  width:86px;
  height:86px;
  border-radius:50%;
  background:radial-gradient(circle at 36% 32%,#fff7a7,#ffc642 58%,#ed8f1e);
  box-shadow:0 0 0 16px rgba(255,205,61,.14),0 0 54px rgba(255,183,34,.32);
}
.sandbox-sun::before,
.sandbox-sun::after{
  content:"";
  position:absolute;
  left:50%;
  top:50%;
  width:132px;
  height:7px;
  border-radius:99px;
  background:#efaa2e;
  opacity:.52;
  transform:translate(-50%,-50%) rotate(18deg);
}
.sandbox-sun::after{
  transform:translate(-50%,-50%) rotate(108deg);
}
.sandbox-bucket{
  position:absolute;
  left:34px;
  bottom:28px;
  width:102px;
  height:82px;
  border-radius:15px 15px 38px 38px;
  background:linear-gradient(115deg,#36cbb5,#0e948d);
  border:5px solid rgba(55,61,37,.18);
  box-shadow:inset 12px 0 rgba(255,255,255,.18),0 16px 20px rgba(104,59,19,.22);
  transform:rotate(-7deg);
}
.sandbox-bucket::before{
  content:"";
  position:absolute;
  left:9px;
  right:9px;
  top:-43px;
  height:58px;
  border:7px solid #e85f47;
  border-bottom:0;
  border-radius:52px 52px 0 0;
}
.sandbox-bucket span{
  position:absolute;
  left:24px;
  top:25px;
  width:47px;
  height:13px;
  border-radius:99px;
  background:rgba(255,255,255,.34);
}
.sandbox-shovel{
  position:absolute;
  right:54px;
  bottom:42px;
  width:28px;
  height:168px;
  border-radius:18px;
  background:linear-gradient(90deg,#ef5d48,#b8332a);
  transform:rotate(24deg);
  box-shadow:0 13px 18px rgba(102,58,20,.22);
}
.sandbox-shovel::before{
  content:"";
  position:absolute;
  left:-18px;
  top:-38px;
  width:64px;
  height:54px;
  border:11px solid #ef5d48;
  border-bottom-width:7px;
  border-radius:34px 34px 18px 18px;
  background:transparent;
}
.sandbox-shovel span{
  position:absolute;
  left:-20px;
  bottom:-39px;
  width:68px;
  height:58px;
  border-radius:12px 12px 40px 40px;
  background:linear-gradient(145deg,#ffd65b,#e99c21);
  border:4px solid rgba(109,69,24,.16);
}
.sandbox-cake{
  position:absolute;
  z-index:0;
  width:116px;
  height:64px;
  border-radius:18px 18px 8px 8px;
  background:linear-gradient(160deg,#dba656,#bb7a31);
  box-shadow:inset 0 6px rgba(255,231,165,.28),0 10px 18px rgba(96,56,18,.18);
}
.sandbox-cake::before{
  content:"";
  position:absolute;
  left:19px;
  top:-35px;
  width:78px;
  height:44px;
  border-radius:50% 50% 8px 8px;
  background:linear-gradient(160deg,#e6b864,#c88b3a);
}
.sandbox-cake span,
.sandbox-cake i{
  position:absolute;
  width:13px;
  height:13px;
  border-radius:50%;
  background:#ef664d;
  top:18px;
  left:25px;
}
.sandbox-cake i{
  left:auto;
  right:24px;
  background:#2aa89d;
}
.cake-one{
  left:45%;
  bottom:24px;
  transform:rotate(3deg) scale(.82);
}
.cake-two{
  right:21%;
  top:18px;
  transform:rotate(-5deg) scale(.64);
  opacity:.78;
}
.sandbox-shell{
  position:absolute;
  font-size:40px;
  filter:drop-shadow(0 8px 8px rgba(91,55,20,.18));
}
.shell-one{
  left:21%;
  bottom:21px;
  transform:rotate(-18deg);
}
.shell-two{
  right:14%;
  top:28%;
  transform:rotate(12deg);
}
.sandbox-title{
  position:absolute;
  z-index:5;
  right:34px;
  top:28px;
  padding:12px 16px;
  border-radius:22px;
  color:#5b351a;
  background:rgba(255,247,203,.82);
  border:2px solid rgba(132,77,29,.18);
  box-shadow:0 14px 28px rgba(104,61,20,.16);
  backdrop-filter:blur(8px);
}
.sandbox-title>span{
  float:left;
  margin-right:10px;
  font-size:30px;
}
.sandbox-title b,
.sandbox-title small{
  display:block;
}
.sandbox-title b{
  font-size:16px;
}
.sandbox-title small{
  margin-top:3px;
  color:#87552c;
  font-weight:750;
}

body.mode-showcase .edge-path{
  stroke:#9a642f !important;
  stroke-width:5.4px !important;
  opacity:.50 !important;
  filter:drop-shadow(0 4px 1px rgba(255,232,169,.58)) drop-shadow(0 -2px 1px rgba(105,62,22,.30)) !important;
  stroke-dasharray:2 4;
}
body.mode-showcase .node{
  width:238px !important;
  min-height:132px !important;
  padding:15px !important;
  color:#3d2a1c;
  border:4px solid rgba(87,60,32,.18) !important;
  border-radius:32px 22px 34px 20px !important;
  background:linear-gradient(145deg,#ffdf65,#f39f34) !important;
  box-shadow:
    inset 9px 9px 0 rgba(255,255,255,.18),
    inset -8px -10px 0 rgba(113,55,20,.10),
    0 15px 0 rgba(111,66,25,.13),
    0 27px 38px rgba(92,52,18,.20) !important;
  transform:rotate(-1deg) !important;
}
body.mode-showcase .node::after{
  content:attr(data-toy);
  position:absolute;
  right:-17px;
  top:-22px;
  width:48px;
  height:48px;
  display:grid;
  place-items:center;
  border-radius:19px;
  font-size:27px;
  background:rgba(255,250,218,.93);
  border:3px solid rgba(103,64,31,.16);
  box-shadow:0 10px 18px rgba(91,52,19,.18);
  transform:rotate(8deg);
}
body.mode-showcase .node:nth-child(even){
  transform:rotate(1.2deg) !important;
}
body.mode-showcase .node:hover{
  transform:translateY(-5px) rotate(0deg) scale(1.025) !important;
  box-shadow:
    inset 9px 9px 0 rgba(255,255,255,.22),
    inset -8px -10px 0 rgba(113,55,20,.10),
    0 18px 0 rgba(111,66,25,.12),
    0 34px 50px rgba(92,52,18,.26) !important;
}
body.mode-showcase .node[data-type="data-source"]{
  background:linear-gradient(145deg,#3ed6c2,#159e95) !important;
}
body.mode-showcase .node[data-type="smart-summary"]{
  background:linear-gradient(145deg,#ffdb55,#ed9d2d) !important;
}
body.mode-showcase .node[data-type="visual-explorer"],
body.mode-showcase .node[data-type="scatter-plot"]{
  background:linear-gradient(145deg,#65c8ff,#3e76dc) !important;
  color:#102a5e;
}
body.mode-showcase .node[data-type="linear-regression"]{
  background:linear-gradient(145deg,#ad80ff,#7754de) !important;
  color:#281856;
}
body.mode-showcase .node[data-type="quality check"]{
  background:linear-gradient(145deg,#63e6a8,#21ad70) !important;
}
body.mode-showcase .node[data-type="feature-importance"]{
  background:linear-gradient(145deg,#ffbd5b,#ed703d) !important;
}
body.mode-showcase .node[data-type="report"]{
  background:linear-gradient(145deg,#ff8cae,#df4f82) !important;
}
body.mode-showcase .node-number{
  color:#fff;
  background:#6e4322 !important;
  box-shadow:0 5px 0 rgba(77,41,15,.20);
}
body.mode-showcase .node-title{
  font-size:16px;
  color:#382417;
}
body.mode-showcase .node-emoji{
  color:#432b1b;
  background:rgba(255,250,221,.56);
  border:2px solid rgba(86,51,24,.12);
}
body.mode-showcase .node-copy small{
  color:#4f3727;
}
body.mode-showcase .node-status{
  color:#54351d !important;
  background:rgba(255,248,213,.64) !important;
  border:1px solid rgba(88,52,24,.12);
}
body.mode-showcase .node.selected,
body.mode-showcase .node.active-run{
  outline:7px solid rgba(255,250,206,.58);
  box-shadow:
    inset 9px 9px 0 rgba(255,255,255,.25),
    0 15px 0 rgba(111,66,25,.13),
    0 0 0 11px rgba(34,163,150,.26),
    0 34px 55px rgba(92,52,18,.28) !important;
}
body.mode-showcase .showcase-flow-hint{
  display:flex !important;
  left:174px;
  bottom:24px;
  color:#5c351a;
  background:rgba(255,243,189,.88);
  border:2px solid rgba(124,72,28,.20);
  box-shadow:0 16px 32px rgba(99,57,19,.18);
}
body.mode-showcase .showcase-flow-hint span{
  background:linear-gradient(135deg,#38c7b4,#158b84);
  box-shadow:0 7px 16px rgba(20,123,116,.24);
}

@media (max-width:900px){
  .mode-welcome{
    padding:12px;
    overflow:auto;
  }
  .mode-welcome-card{
    padding:24px 18px;
    border-radius:26px;
  }
  .mode-choice-grid{
    grid-template-columns:1fr;
  }
  .mode-choice{
    min-height:126px;
    padding:18px;
    grid-template-columns:58px 1fr;
  }
  .mode-choice-art{
    width:58px;
    height:58px;
    border-radius:18px;
    font-size:32px;
  }
  .mode-choice b{
    font-size:20px;
  }
  body.mode-showcase .flow-canvas{
    height:auto !important;
    min-height:calc(100vh - 126px) !important;
    overflow:visible !important;
  }
  body.mode-showcase #edgeSvg{
    display:none !important;
  }
  body.mode-showcase #nodesLayer{
    position:relative !important;
    min-height:1260px;
    padding:118px 18px 150px;
    display:grid !important;
    grid-template-columns:1fr;
    align-content:start;
    gap:24px;
  }
  body.mode-showcase #nodesLayer::before{
    content:"";
    position:absolute;
    left:50%;
    top:92px;
    bottom:110px;
    width:8px;
    border-radius:99px;
    background:repeating-linear-gradient(to bottom,#9c6634 0 10px,transparent 10px 18px);
    opacity:.34;
  }
  body.mode-showcase .node,
  body.mode-showcase .node:nth-child(even){
    position:relative !important;
    left:auto !important;
    top:auto !important;
    width:min(100%,430px) !important;
    margin:0 auto;
    transform:none !important;
  }
  body.mode-showcase .sandbox-title{
    left:16px;
    right:16px;
    top:18px;
  }
  body.mode-showcase .sandbox-sun{
    display:none;
  }
  body.mode-showcase .sandbox-bucket{
    left:20px;
    bottom:26px;
    transform:scale(.72) rotate(-7deg);
    transform-origin:left bottom;
  }
  body.mode-showcase .sandbox-shovel{
    right:30px;
    bottom:34px;
    transform:scale(.72) rotate(24deg);
    transform-origin:right bottom;
  }
  body.mode-showcase .showcase-flow-hint{
    display:none !important;
  }
}

/* v35: Meta / ID columns stay visible but are excluded from analysis */
.data-chip.meta-chip{
  background:#fff3d8;
  color:#70531a;
  border:1px solid #f0d49b;
}
.data-chip i{
  margin-left:7px;
  padding:2px 6px;
  border-radius:999px;
  background:rgba(112,83,26,.10);
  font-size:9px;
  font-style:normal;
  text-transform:uppercase;
  letter-spacing:.4px;
}
.data-preview-panel{
  border:1px solid #dce6fb;
  border-radius:24px;
  background:linear-gradient(180deg,#ffffff,#f7fbff);
  padding:16px;
  margin:14px 0;
}
.data-preview-head{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:14px;
  margin-bottom:12px;
}
.data-preview-head h3{
  margin:0 0 5px;
  font-size:22px;
}
.data-preview-head p{
  margin:0;
  color:#52619b;
  font-weight:750;
  line-height:1.45;
}
.data-preview-head>span{
  flex:none;
  padding:7px 10px;
  border-radius:999px;
  background:#eef5ff;
  color:#52619b;
  font-size:11px;
  font-weight:900;
}
.raw-data-table-wrap{
  max-height:360px;
}
.raw-data-table{
  min-width:max-content;
}
.raw-data-table th{
  position:sticky;
  top:0;
  z-index:2;
  min-width:130px;
  white-space:nowrap;
}
.raw-data-table th span,
.raw-data-table th small{
  display:block;
}
.raw-data-table th small{
  margin-top:3px;
  color:#7c8ab8;
  font-size:9px;
  font-weight:850;
}
.raw-data-table .row-index{
  min-width:44px;
  width:44px;
  text-align:center;
  color:#7180aa;
  background:#f4f7fd;
  font-weight:900;
}
.raw-data-table .meta-column{
  background:#fff8e8;
  color:#70531a;
  border-left:1px solid #f2dfb6;
  border-right:1px solid #f2dfb6;
}
.raw-data-table th.meta-column{
  background:#ffefc9;
}
.missing-cell{
  color:#9a6a00;
  font-size:10px;
  font-style:italic;
  font-weight:850;
}
.meta-summary-row td{
  background:#fffaf0;
}
.meta-summary-row td:first-child small{
  display:block;
  margin-top:3px;
  color:#9a7a3b;
  font-size:10px;
  font-weight:850;
}
.excluded-stat{
  display:inline-flex;
  padding:4px 8px;
  border-radius:999px;
  background:#fff0cc;
  color:#79591b;
  font-size:10px;
  font-weight:900;
}
.meta-exclusion-note{
  display:grid;
  grid-template-columns:auto 1fr;
  gap:5px 12px;
  align-items:center;
  margin:14px 0;
  padding:14px 16px;
  border:1px solid #f0d49b;
  border-radius:18px;
  background:linear-gradient(180deg,#fff8e8,#fffdf8);
}
.meta-exclusion-note b{
  color:#70531a;
}
.meta-exclusion-note span{
  color:#8a6724;
  font-weight:900;
  overflow-wrap:anywhere;
}
.meta-exclusion-note small{
  grid-column:1 / -1;
  color:#7c6b4d;
  font-weight:750;
}
@media(max-width:900px){
  .data-preview-head{
    display:block;
  }
  .data-preview-head>span{
    display:inline-flex;
    margin-top:10px;
  }
  .meta-exclusion-note{
    grid-template-columns:1fr;
  }
  .meta-exclusion-note small{
    grid-column:auto;
  }
}

/* v36: smart summary overflow fix + stronger sandbox styling */
.recommended-visuals-grid{
  align-items:start;
}
.recommended-card{
  display:flex;
  flex-direction:column;
  overflow:hidden;
}
.recommended-card svg,
.recommended-card .big-svg,
.recommended-card .histogram-svg{
  display:block;
  width:100%;
  height:280px !important;
  min-height:280px !important;
  max-height:280px !important;
  flex:none;
}
.modal-table-wrap{
  position:relative;
  z-index:1;
  margin-top:12px;
  background:linear-gradient(180deg,#ffffff,#f9fbff);
}

body.mode-showcase .summary-kpi,
body.mode-showcase .inspector-card,
body.mode-showcase .modal-chart-card,
body.mode-showcase .data-preview-panel,
body.mode-showcase .meta-exclusion-note,
body.mode-showcase .columns-preview,
body.mode-showcase .modal-table-wrap{
  border-color:rgba(154,98,39,.24);
  background:linear-gradient(180deg,rgba(255,249,231,.96),rgba(255,241,205,.90));
  box-shadow:0 14px 32px rgba(133,83,34,.10);
}
body.mode-showcase .recommended-card{
  background:
    radial-gradient(circle at 10% 10%,rgba(255,255,255,.35),transparent 24%),
    linear-gradient(180deg,rgba(255,250,236,.98),rgba(255,237,198,.92));
}
body.mode-showcase .recommended-visuals-head h3,
body.mode-showcase .data-preview-head h3,
body.mode-showcase .modal-chart-card h3,
body.mode-showcase .meta-exclusion-note b{
  color:#6a3e1c;
}
body.mode-showcase .recommended-visuals-head p,
body.mode-showcase .data-preview-head p,
body.mode-showcase .chart-note,
body.mode-showcase .meta-exclusion-note small,
body.mode-showcase .data-preview-head>span,
body.mode-showcase .summary-kpi small,
body.mode-showcase .inspector-card small{
  color:#8a5b32;
}
body.mode-showcase .summary-kpi b,
body.mode-showcase .data-preview-head>span,
body.mode-showcase .modal-chart-card b,
body.mode-showcase .meta-exclusion-note span{
  color:#5b3417;
}
body.mode-showcase .pill{
  background:rgba(255,248,224,.92);
  border:1px solid rgba(173,116,54,.22);
  color:#8a5428;
}
body.mode-showcase .report-table th,
body.mode-showcase .raw-data-table th,
body.mode-showcase .fancy-summary-table th{
  background:#ffefc7;
  color:#7a471f;
}
body.mode-showcase .report-table td,
body.mode-showcase .raw-data-table td,
body.mode-showcase .fancy-summary-table td{
  border-bottom-color:#efd8b0;
}
body.mode-showcase .raw-data-table .row-index{
  background:#fff5dd;
  color:#8a5a30;
}
body.mode-showcase .raw-data-table .meta-column,
body.mode-showcase .meta-summary-row td{
  background:#fff2cf;
}
body.mode-showcase .excluded-stat{
  background:#ffe7b3;
  color:#85531f;
}
body.mode-showcase .data-preview-head>span{
  background:#fff3cf;
}

@media (max-width:980px){
  .recommended-card svg,
  .recommended-card .big-svg,
  .recommended-card .histogram-svg{
    height:240px !important;
    min-height:240px !important;
    max-height:240px !important;
  }
}

/* v37 — faster guided UX, explicit choices and purposeful wow */
.topbar{
  grid-template-columns:226px minmax(0,1fr)!important;
}
.toolbar-v37{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:8px;
  min-width:0;
}
.next-step-btn{
  min-height:40px;
  padding:0 17px;
  border:0;
  border-radius:15px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  color:#fff;
  background:linear-gradient(135deg,#0d9e8d,#6557ff 62%,#ff65a3);
  box-shadow:0 14px 30px rgba(94,78,225,.25),inset 0 1px 0 rgba(255,255,255,.35);
  font-weight:950;
  white-space:nowrap;
  transition:transform .18s ease,box-shadow .18s ease,filter .18s ease;
}
.next-step-btn:hover:not(:disabled){
  transform:translateY(-2px);
  box-shadow:0 18px 38px rgba(94,78,225,.31),inset 0 1px 0 rgba(255,255,255,.35);
}
.next-step-btn:disabled{opacity:.72;cursor:wait}
.next-step-btn span{font-size:18px}
.contextual-report-btn{display:none!important}
.contextual-report-btn.is-visible{display:inline-flex!important}
.context-hidden{display:none!important}
.more-menu{position:relative;flex:none}
.more-menu summary{
  list-style:none;
  width:40px;
  height:40px;
  border:1px solid rgba(151,174,226,.76);
  border-radius:14px;
  display:grid;
  place-items:center;
  color:#42528d;
  background:rgba(255,255,255,.84);
  font-size:24px;
  font-weight:950;
  cursor:pointer;
  user-select:none;
}
.more-menu summary::-webkit-details-marker{display:none}
.more-menu[open] summary{color:#fff;background:linear-gradient(135deg,#5ed8ff,#705cff);border-color:transparent}
.more-menu-panel{
  position:absolute;
  z-index:80;
  right:0;
  top:48px;
  width:250px;
  padding:8px;
  border:1px solid #dce6fb;
  border-radius:18px;
  background:rgba(255,255,255,.98);
  box-shadow:0 24px 60px rgba(20,35,83,.23);
  backdrop-filter:blur(18px);
}
.more-menu-panel button{
  width:100%;
  min-height:40px;
  border:0;
  border-radius:12px;
  background:transparent;
  color:#24366f;
  text-align:left;
  padding:8px 11px;
  font-weight:850;
}
.more-menu-panel button:hover{background:#eef4ff}

.target-confirmation-card{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(280px,.8fr);
  gap:18px;
  align-items:center;
  margin:16px 0;
  padding:20px;
  border:2px solid rgba(255,185,54,.65);
  border-radius:25px;
  background:
    radial-gradient(circle at 0 0,rgba(255,216,118,.28),transparent 34%),
    linear-gradient(180deg,#fffaf0,#fff);
  box-shadow:0 18px 44px rgba(179,113,27,.12);
}
.target-confirmation-card.confirmed{
  border-color:rgba(46,217,189,.55);
  background:linear-gradient(180deg,#effff9,#fff);
}
.target-confirmation-card.disabled{opacity:.58}
.target-confirmation-copy h3{margin:7px 0 7px;font-size:25px;color:#172861}
.target-confirmation-copy p{margin:0;color:#5c6998;font-weight:750;line-height:1.5}
.target-confirmation-controls{display:flex;align-items:end;gap:10px;justify-content:flex-end}
.target-confirmation-controls .field{min-width:190px;margin:0}
.target-badge{
  display:inline-flex;
  width:max-content;
  padding:6px 10px;
  border-radius:999px;
  background:#fff0c8;
  color:#81561b;
  font-size:10px;
  font-weight:950;
  letter-spacing:.45px;
  text-transform:uppercase;
}
.target-confirmation-card.confirmed .target-badge{background:#dcfff3;color:#08745d}
.compact-source-kpis{grid-template-columns:repeat(4,1fr)}

.summary-tabs{
  display:flex;
  gap:8px;
  padding:7px;
  margin:2px 0 16px;
  border:1px solid #dce6fb;
  border-radius:18px;
  background:#f7faff;
  overflow-x:auto;
}
.summary-tabs button{
  min-height:38px;
  padding:0 15px;
  border:0;
  border-radius:12px;
  color:#5869a0;
  background:transparent;
  font-weight:950;
  white-space:nowrap;
}
.summary-tabs button.active{
  color:#fff;
  background:linear-gradient(135deg,#1db9a6,#6557ff);
  box-shadow:0 10px 24px rgba(89,77,214,.22);
}
.summary-pane{animation:summaryPaneIn .2s ease}
@keyframes summaryPaneIn{from{opacity:.35;transform:translateY(5px)}to{opacity:1;transform:none}}
.smart-story{
  display:grid;
  grid-template-columns:62px 1fr;
  gap:16px;
  align-items:start;
  padding:20px;
  border-radius:25px;
  background:
    radial-gradient(circle at 0 0,rgba(94,216,255,.26),transparent 31%),
    linear-gradient(135deg,#f0fbff,#f8f1ff 65%,#fff7de);
  border:1px solid #d9e5fb;
  box-shadow:0 18px 42px rgba(53,76,144,.10);
}
.smart-story>span{
  width:62px;height:62px;border-radius:20px;display:grid;place-items:center;
  color:#fff;font-size:31px;background:linear-gradient(135deg,#5ed8ff,#705cff,#ff65a3);
  box-shadow:0 15px 32px rgba(106,88,224,.25);
}
.smart-story small{display:block;color:#6473a4;font-size:10px;font-weight:950;letter-spacing:.8px;text-transform:uppercase}
.smart-story h3{margin:5px 0 7px;font-size:25px;line-height:1.2;color:#10215a}
.smart-story p{margin:0;color:#53649a;font-weight:750;line-height:1.55}
.summary-main-kpis{grid-template-columns:repeat(4,1fr)}
.summary-main-chart{
  display:grid;
  grid-template-columns:minmax(240px,.64fr) minmax(0,1.36fr);
  gap:18px;
  align-items:center;
  margin-top:14px;
  overflow:hidden;
}
.summary-main-chart .summary-chart-copy{padding:8px 4px 8px 8px}
.summary-chart-copy h3{margin:9px 0 7px;font-size:24px;color:#172861}
.summary-chart-copy p{margin:0 0 15px;color:#5c6998;font-weight:750;line-height:1.5}
.summary-main-chart .big-svg{height:285px!important;min-height:285px!important;max-height:285px!important}
.summary-table-only{max-height:58vh;margin-top:0}
.warning-cards{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.warning-card{
  display:grid;grid-template-columns:42px 1fr;gap:12px;align-items:start;
  padding:16px;border:1px solid #dce6fb;border-radius:20px;background:#fff;
}
.warning-card>span{width:42px;height:42px;border-radius:14px;display:grid;place-items:center;font-weight:950;background:#eef4ff;color:#4960a8}
.warning-card.good{border-color:#cbeee5;background:#f5fffb}.warning-card.good>span{background:#dffff5;color:#08745d}
.warning-card.warn{border-color:#f2d59c;background:#fffaf0}.warning-card.warn>span{background:#ffe9b7;color:#8c5b18}
.warning-card.info{background:#f5f8ff}
.warning-card b{color:#16265e}.warning-card p{margin:5px 0 0;color:#596a9e;font-weight:730;line-height:1.45}

.model-result-hero{
  display:flex;justify-content:space-between;gap:18px;align-items:center;
  padding:20px;border-radius:25px;border:1px solid #d9e5fb;
  background:radial-gradient(circle at 0 0,rgba(46,217,189,.25),transparent 32%),linear-gradient(135deg,#effff9,#f3f5ff 62%,#fff2f8);
}
.model-result-hero h3{margin:8px 0 6px;font-size:29px;color:#10215a}
.model-result-hero p{margin:0;color:#52639a;font-weight:750;line-height:1.5}
.model-score-orb{min-width:100px;height:100px;border-radius:50%;display:grid;place-content:center;text-align:center;color:#fff;background:linear-gradient(135deg,#19b7a4,#6557ff);box-shadow:0 20px 42px rgba(86,76,211,.28)}
.model-score-orb small{font-weight:900}.model-score-orb b{font-size:27px}
.actual-predicted-card{margin-top:15px;padding:18px;border:1px solid #dce6fb;border-radius:25px;background:linear-gradient(180deg,#fff,#f7faff);box-shadow:0 15px 38px rgba(43,74,140,.08)}
.actual-predicted-card h3{margin:0 0 4px;color:#172861}.actual-predicted-card p{margin:0 0 10px;color:#6170a1;font-weight:750}
.actual-predicted-svg{display:block;width:100%;height:auto;min-height:330px;border-radius:24px}
.ap-bg{fill:#101736}.ap-grid{stroke:rgba(211,226,255,.14);stroke-width:1}.ap-perfect{stroke:#39d7c5;stroke-width:3;stroke-dasharray:9 7}.ap-point{fill:#72d8ff;stroke:rgba(255,255,255,.55);stroke-width:1;opacity:.82;transition:r .15s ease,opacity .15s ease}.ap-point:hover{r:8;opacity:1;fill:#ffbd4a}.ap-tick{fill:#a7b8e9;font-size:11px;font-weight:800}.ap-label{fill:#e8efff;font-size:14px;font-weight:900}.ap-caption{fill:#ffdf90;font-size:12px;font-weight:900}
.residual-card{margin-top:14px}.residual-card svg{height:190px!important}

.celebration-dialog{border:0;padding:0;background:transparent;width:min(920px,96vw);max-width:920px}
.celebration-dialog::backdrop{background:rgba(7,13,39,.70);backdrop-filter:blur(12px)}
.celebration-card{position:relative;padding:25px;border-radius:32px;background:radial-gradient(circle at 12% 0,rgba(255,216,86,.26),transparent 28%),radial-gradient(circle at 92% 6%,rgba(94,216,255,.22),transparent 28%),linear-gradient(180deg,#fffdf5,#f5f8ff);box-shadow:0 42px 120px rgba(0,0,0,.38);overflow:auto;max-height:92vh}
.celebration-close{position:absolute;right:14px;top:13px;width:40px;height:40px;border:0;border-radius:14px;background:rgba(255,255,255,.82);font-size:26px;color:#536193}
.celebration-top{display:flex;align-items:center;gap:17px;padding-right:40px}
.castle-pop{width:82px;height:82px;display:grid;place-items:center;border-radius:25px;font-size:45px;background:linear-gradient(145deg,#fff1a8,#f0b75c);box-shadow:0 18px 38px rgba(163,103,30,.24);animation:castlePop .55s cubic-bezier(.2,.9,.25,1.25)}
@keyframes castlePop{from{transform:scale(.45) rotate(-8deg);opacity:0}to{transform:none;opacity:1}}
.celebration-top small{color:#9b671f;font-weight:950;text-transform:uppercase;letter-spacing:.7px}.celebration-top h2{margin:3px 0 4px;font-size:35px;color:#10215a}.celebration-top p{margin:0;color:#5b6998;font-weight:750}
.celebration-metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:17px 0}.celebration-metrics>div{padding:12px 15px;border:1px solid #dce6fb;border-radius:17px;background:rgba(255,255,255,.8)}.celebration-metrics small{display:block;color:#6674a5;font-weight:900}.celebration-metrics b{font-size:23px;color:#10215a}
.celebration-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:14px}

body.mode-showcase .next-step-btn{background:linear-gradient(135deg,#16a997,#087c73);box-shadow:0 14px 28px rgba(8,112,103,.25)}
body.mode-showcase .more-menu summary{color:#73431f;background:rgba(255,249,220,.84);border-color:rgba(132,78,32,.30)}
body.mode-showcase .more-menu-panel{border-color:#e7c892;background:#fffaf0}
body.mode-showcase .more-menu-panel button{color:#70421f}body.mode-showcase .more-menu-panel button:hover{background:#fff0c9}
body.mode-showcase .smart-story,body.mode-showcase .summary-main-chart,body.mode-showcase .warning-card,body.mode-showcase .target-confirmation-card{border-color:rgba(154,98,39,.25);background:linear-gradient(180deg,#fff9e8,#fff0ca)}
body.mode-showcase .summary-tabs{border-color:#e7c892;background:#fff3d3}
body.mode-showcase .summary-tabs button.active{background:linear-gradient(135deg,#1ba99a,#087f76)}

@media(max-width:1100px){
  .toolbar-v37{flex-wrap:wrap}.topbar{grid-template-columns:210px minmax(0,1fr)!important}
  .toolbar-v37 .mode-switch{order:5}
}
@media(max-width:900px){
  .topbar{display:block!important}
  .toolbar-v37{display:grid!important;grid-template-columns:1fr 1fr!important}
  .toolbar-v37 .next-step-btn{grid-column:1 / -1;min-height:48px;font-size:15px}
  .toolbar-v37 .mode-switch{grid-column:1 / -1;order:initial}
  .toolbar-v37 .more-menu{position:absolute;right:12px;top:14px}
  .toolbar-v37 .more-menu summary{background:rgba(255,255,255,.96)}
  .contextual-report-btn.is-visible{display:none!important}
  .flow-canvas{padding:12px!important;min-height:auto!important}
  .mobile-guided-panel{display:block!important}
  .sandbox-title,.sandbox-decor,.showcase-flow-hint,.showcase-stage{display:none!important}
  .target-confirmation-card,.summary-main-chart{grid-template-columns:1fr}
  .target-confirmation-controls{display:block}.target-confirmation-controls .field{margin-bottom:10px}.target-confirmation-controls button{width:100%;justify-content:center}
  .summary-main-kpis,.compact-source-kpis{grid-template-columns:1fr 1fr!important}
  .warning-cards{grid-template-columns:1fr}
  .summary-main-chart .big-svg{height:250px!important;min-height:250px!important;max-height:250px!important}
  .model-result-hero{align-items:flex-start}.model-score-orb{min-width:82px;height:82px}
  .actual-predicted-svg{min-height:260px}
  .celebration-card{padding:18px}.celebration-top{align-items:flex-start}.castle-pop{width:64px;height:64px;font-size:36px}.celebration-top h2{font-size:29px}.celebration-actions{display:grid}.celebration-actions button{width:100%;justify-content:center}
}
@media(max-width:520px){
  .toolbar-v37{grid-template-columns:1fr!important}.toolbar-v37 .next-step-btn,.toolbar-v37 .mode-switch{grid-column:auto}
  .smart-story{grid-template-columns:48px 1fr;padding:15px}.smart-story>span{width:48px;height:48px;border-radius:16px;font-size:25px}.smart-story h3{font-size:20px}
  .summary-main-kpis,.compact-source-kpis,.celebration-metrics{grid-template-columns:1fr 1fr!important}
  .celebration-top{display:block}.castle-pop{margin-bottom:10px}
}

/* v37.1 — override old showcase desktop rules on phones */
.data-source-dialog{display:flex;flex-direction:column}
.data-source-dialog>.data-source-hero{order:1}
.data-source-dialog>.data-loaded-card{order:2}
.data-source-dialog>.summary-kpis{order:3}
.data-source-dialog>.target-confirmation-card{order:4}
.data-source-dialog>.columns-preview{order:5}
.data-source-dialog>.data-preview-panel{order:6}
.data-source-dialog>.variable-settings-panel{order:7}
.data-source-dialog>.data-source-next-row{order:8}
.data-source-dialog>.danger-note{order:9}
@keyframes summaryPaneIn{from{opacity:.88;transform:translateY(4px)}to{opacity:1;transform:none}}
body.mode-showcase .more-menu-panel #saveFlowBtn,
body.mode-showcase .more-menu-panel #loadSavedSchemeBtn,
body.mode-showcase .more-menu-panel #exportFlowBtn,
body.mode-showcase .more-menu-panel #resetViewBtn,
body.mode-showcase .more-menu-panel #globalHelpBtn,
body.mode-showcase .more-menu-panel #runFlowBtn{display:block!important}
@media(max-width:900px){
  body.mode-showcase .mobile-guided-panel{display:block!important}
  body.mode-showcase #nodesLayer,
  body.mode-showcase #edgeSvg,
  body.mode-showcase .nodes-layer,
  body.mode-showcase .edge-svg,
  body.mode-showcase .canvas-brand-watermark,
  body.mode-showcase .sandbox-title,
  body.mode-showcase .sandbox-decor,
  body.mode-showcase .showcase-stage,
  body.mode-showcase .showcase-flow-hint{display:none!important}
  body.mode-showcase .flow-canvas{
    min-height:auto!important;
    height:auto!important;
    padding:12px!important;
    overflow:visible!important;
    background:#e7bd70!important;
  }
  body.mode-showcase .canvas-section{min-height:auto!important}
  body.mode-showcase .workspace{display:block!important}
}

/* v37.2 — mobile target first and unobtrusive notifications */
.data-source-dialog>.target-confirmation-card{order:3}
.data-source-dialog>.summary-kpis{order:4}
@media(max-width:900px){
  .data-source-dialog.has-data>.data-source-hero{display:none!important}
  .data-source-dialog.has-data>.target-confirmation-card{margin-top:0}
  .toast-stack{left:10px;right:10px;bottom:10px;display:block}
  .toast{min-width:0;width:100%;margin-top:8px}
  .toast:not(:last-child){display:none}
}
