/* ============================================================
   龙灵 15 大超级超算引擎 · 高维协同模式 + 引擎间共振矩阵  V52
   独立样式层（叠加于 common.css / v47-common.css / biz-v48.css 之上）
   纯原生实现，零第三方依赖，零内联
   ============================================================ */

.eng-hero { --hero-bd: rgba(110,160,255,.28); --badge-bg: rgba(80,130,255,.14); --badge-bd: rgba(110,160,255,.4); --badge-c: #9dc0ff; --hero-glow1: radial-gradient(circle at 18% 12%, rgba(79,123,255,.26), transparent 58%); --title-grad: linear-gradient(96deg,#eaf2ff 5%,#8fb6ff 45%,#c39bff 92%); --sub-c: #a9bade; }
.eng-hero::before { background: radial-gradient(circle at 18% 12%, rgba(79,123,255,.26), transparent 58%); }

/* ---------- 高维协同说明条 ---------- */
.emm-mode { display:grid; grid-template-columns:repeat(auto-fit,minmax(210px,1fr)); gap:14px; margin:0 0 26px; }
.emm-mode-i { background:rgba(255,255,255,.04); border:1px solid rgba(120,160,255,.16); border-radius:14px; padding:16px 18px; }
.emm-mode-i b { display:block; font-size:14px; color:#cfe0ff; margin-bottom:4px; }
.emm-mode-i span { font-size:12px; color:#8d9cbd; line-height:1.6; }

/* ---------- 三重共振 ---------- */
.emm-triple { display:grid; grid-template-columns:repeat(auto-fit,minmax(280px,1fr)); gap:18px; margin-bottom:22px; }
.emm-tri { position:relative; border-radius:18px; padding:24px 22px; overflow:hidden; border:1px solid rgba(120,160,255,.18); background:rgba(255,255,255,.035); }
.emm-tri::after { content:""; position:absolute; right:-40px; top:-40px; width:150px; height:150px; border-radius:50%; opacity:.22; filter:blur(6px); }
.emm-tri.c1::after { background:radial-gradient(circle,#4f7bff,transparent 70%); }
.emm-tri.c2::after { background:radial-gradient(circle,#22d3ee,transparent 70%); }
.emm-tri.c3::after { background:radial-gradient(circle,#a855f7,transparent 70%); }
.emm-tri-n { font-size:12px; letter-spacing:2px; color:#7f8fb5; margin-bottom:8px; }
.emm-tri-t { font-size:20px; font-weight:800; color:#fff; margin-bottom:10px; }
.emm-tri-d { font-size:13px; color:#98a8c8; line-height:1.75; }
.emm-tri-w { margin-top:14px; font-size:12px; color:#7fb0ff; border-top:1px dashed rgba(120,160,255,.2); padding-top:10px; }

/* ---------- 共振矩阵 ---------- */
.emm-mx-tools { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin-bottom:14px; }
.emm-mx-h { font-size:18px; }
.emm-mx-tip { font-size:12px; color:#7f8fb5; }
.emm-mx-scroll { overflow-x:auto; padding-bottom:8px; }
.emm-matrix { display:grid; gap:3px; min-width:840px; grid-template-columns:repeat(16,minmax(0,1fr)); }
.emm-mx-cell { width:100%; aspect-ratio:1/1; border-radius:6px; border:1px solid rgba(255,255,255,.05); background:rgba(255,255,255,.03); cursor:pointer; transition:transform .12s, box-shadow .12s; position:relative; }
.emm-mx-cell:hover { transform:scale(1.16); z-index:6; box-shadow:0 0 0 2px rgba(150,190,255,.6); }
.emm-mx-cell.diag { background:rgba(255,255,255,.08); border-color:rgba(150,190,255,.25); cursor:default; }
.emm-mx-cell.l0 { background:rgba(120,160,255,.05); }
.emm-mx-cell.l1 { background:rgba(79,123,255,.20); }
.emm-mx-cell.l2 { background:rgba(79,123,255,.38); }
.emm-mx-cell.l3 { background:rgba(34,211,238,.52); }
.emm-mx-cell.l4 { background:rgba(168,85,247,.66); }
.emm-mx-cell.l5 { background:rgba(236,72,153,.82); box-shadow:0 0 10px rgba(236,72,153,.5) inset; }
.emm-mx-lab { display:flex; align-items:center; justify-content:center; font-size:10px; color:#93a3c4; border-radius:6px; padding:2px; text-align:center; line-height:1.15; background:transparent; }
.emm-mx-lab.corner { color:#5f6f90; }
.emm-mx-lab.on { color:#dce8ff; font-weight:700; }

.emm-legend { display:flex; align-items:center; gap:8px; flex-wrap:wrap; margin-top:14px; font-size:12px; color:#8d9cbd; }
.emm-legend i { width:16px; height:16px; border-radius:4px; display:inline-block; }
.emm-legend i.l0 { background:rgba(120,160,255,.05); border:1px solid rgba(255,255,255,.08); }
.emm-legend i.l1 { background:rgba(79,123,255,.20); }
.emm-legend i.l2 { background:rgba(79,123,255,.38); }
.emm-legend i.l3 { background:rgba(34,211,238,.52); }
.emm-legend i.l4 { background:rgba(168,85,247,.66); }
.emm-legend i.l5 { background:rgba(236,72,153,.82); }

.emm-pair-pick { margin-top:16px; border-radius:14px; border:1px solid rgba(120,160,255,.16); background:rgba(255,255,255,.035); padding:16px 18px; font-size:13px; color:#a9bade; }
.emm-pair-pick b { color:#eaf2ff; }

/* ---------- 最强共振组合 ---------- */
.emm-pairs { display:grid; grid-template-columns:repeat(auto-fit,minmax(260px,1fr)); gap:12px; }
.emm-pair { border-radius:12px; border:1px solid rgba(120,160,255,.16); background:rgba(255,255,255,.035); padding:14px 16px; display:flex; align-items:center; justify-content:space-between; gap:12px; }
.emm-pair-l { font-size:13px; color:#cfe0ff; line-height:1.5; }
.emm-pair-l em { font-style:normal; color:#7f8fb5; display:block; font-size:11px; margin-top:3px; }
.emm-pair-v { font-size:20px; font-weight:800; background:linear-gradient(90deg,#22d3ee,#a855f7); -webkit-background-clip:text; -webkit-text-fill-color:transparent; }

/* ---------- 维度族筛选 ---------- */
.emm-tabs { display:flex; gap:8px; flex-wrap:wrap; margin:4px 0 20px; }
.emm-tab { padding:8px 16px; border-radius:20px; border:1px solid rgba(120,160,255,.2); background:rgba(255,255,255,.04); color:#a9bade; font-size:13px; cursor:pointer; transition:all .2s; }
.emm-tab:hover { border-color:rgba(120,160,255,.45); color:#eaf2ff; }
.emm-tab.on { background:linear-gradient(90deg,#4f7bff,#7f4fff); color:#fff; border-color:transparent; box-shadow:0 4px 16px rgba(80,120,255,.35); }
.emm-sort { float:right; display:flex; gap:8px; }

/* ---------- 引擎卡片 ---------- */
.emm-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(340px,1fr)); gap:18px; }
.emm-card { position:relative; border-radius:18px; padding:22px; border:1px solid rgba(120,160,255,.16); background:rgba(255,255,255,.035); transition:all .3s; overflow:hidden; }
.emm-card::before { content:""; position:absolute; left:0; top:0; bottom:0; width:4px; background:linear-gradient(180deg,#4f7bff,#a855f7); opacity:.85; }
.emm-card:hover { transform:translateY(-4px); border-color:rgba(120,160,255,.42); box-shadow:0 10px 30px rgba(80,120,255,.16); }
.emm-hd { display:flex; align-items:flex-start; gap:14px; margin-bottom:12px; }
.emm-ic { width:50px; height:50px; border-radius:13px; display:flex; align-items:center; justify-content:center; font-size:25px; flex-shrink:0; background:linear-gradient(135deg,rgba(79,123,255,.24),rgba(168,85,247,.24)); border:1px solid rgba(140,175,255,.28); }
.emm-nm { font-size:17px; font-weight:800; color:#fff; line-height:1.3; }
.emm-code { font-size:11px; color:#7f8fb5; margin-top:3px; letter-spacing:.4px; }
.emm-role { display:inline-block; margin-top:7px; font-size:11px; padding:3px 10px; border-radius:12px; background:rgba(34,211,238,.14); border:1px solid rgba(34,211,238,.32); color:#7ee8f5; }
.emm-d { font-size:13px; color:#98a8c8; line-height:1.7; margin-bottom:12px; min-height:44px; }
.emm-caps { display:flex; flex-wrap:wrap; gap:7px; margin-bottom:12px; }
.emm-cap { font-size:11.5px; padding:4px 10px; border-radius:8px; background:rgba(79,123,255,.13); border:1px solid rgba(110,160,255,.24); color:#a9c4ff; }
.emm-specs { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-bottom:12px; }
.emm-sp { display:flex; justify-content:space-between; font-size:12px; padding:7px 10px; border-radius:8px; background:rgba(255,255,255,.03); }
.emm-sp span { color:#8d9cbd; }
.emm-sp b { color:#dfeaff; font-weight:700; }
.emm-gain { display:flex; align-items:center; justify-content:space-between; padding:10px 12px; border-radius:10px; background:linear-gradient(90deg,rgba(79,123,255,.14),rgba(168,85,247,.14)); border:1px solid rgba(120,160,255,.2); margin-bottom:14px; }
.emm-gain-l { font-size:12px; color:#98a8c8; }
.emm-gain-v { font-size:18px; font-weight:800; background:linear-gradient(90deg,#22d3ee,#a855f7); -webkit-background-clip:text; -webkit-text-fill-color:transparent; }
.emm-foot { display:flex; gap:8px; flex-wrap:wrap; }
.emm-btn { flex:1; min-width:96px; text-align:center; padding:9px 12px; border-radius:10px; font-size:12.5px; font-weight:600; cursor:pointer; border:1px solid rgba(120,160,255,.24); background:rgba(255,255,255,.05); color:#c8d8ff; transition:all .2s; }
.emm-btn:hover { border-color:rgba(120,160,255,.5); color:#fff; background:rgba(79,123,255,.16); }
.emm-btn.pri { background:linear-gradient(90deg,#4f7bff,#7f4fff); color:#fff; border-color:transparent; }

/* ---------- 详情弹窗 ---------- */
.emm-mask { position:fixed; inset:0; background:rgba(3,6,16,.78); backdrop-filter:blur(6px); display:none; align-items:center; justify-content:center; z-index:900; padding:20px; }
.emm-mask.on { display:flex; }
.emm-modal { width:min(720px,100%); max-height:88vh; overflow:auto; border-radius:20px; border:1px solid rgba(120,160,255,.28); background:linear-gradient(160deg,#0b1226,#0a0f20); padding:28px; position:relative; animation:emmIn .22s ease; }
@keyframes emmIn { from{ transform:translateY(16px); opacity:0 } to{ transform:translateY(0); opacity:1 } }
.emm-modal-x { position:absolute; right:16px; top:16px; width:34px; height:34px; border-radius:10px; border:1px solid rgba(120,160,255,.25); background:rgba(255,255,255,.05); color:#c8d8ff; cursor:pointer; font-size:15px; }
.emm-modal-x:hover { background:rgba(255,80,120,.2); color:#fff; }
.emm-mh { display:flex; gap:14px; align-items:center; margin-bottom:18px; }
.emm-mh .emm-ic { width:58px; height:58px; font-size:29px; }
.emm-mt { font-size:22px; font-weight:800; color:#fff; }
.emm-mc { font-size:12px; color:#7f8fb5; margin-top:4px; }
.emm-block { margin-bottom:18px; }
.emm-block-t { font-size:14px; font-weight:700; color:#cfe0ff; margin-bottom:10px; display:flex; align-items:center; gap:8px; }
.emm-block-t::before { content:""; width:4px; height:16px; border-radius:2px; background:linear-gradient(180deg,#4f7bff,#a855f7); }
.emm-kv { display:grid; grid-template-columns:repeat(auto-fit,minmax(180px,1fr)); gap:8px; }
.emm-kv-i { font-size:12.5px; padding:9px 12px; border-radius:9px; background:rgba(255,255,255,.04); display:flex; justify-content:space-between; }
.emm-kv-i span { color:#8d9cbd; }
.emm-kv-i b { color:#dfeaff; }
.emm-part { display:flex; flex-wrap:wrap; gap:8px; }
.emm-part-i { font-size:12px; padding:6px 12px; border-radius:9px; background:rgba(34,211,238,.12); border:1px solid rgba(34,211,238,.3); color:#9fe9f5; cursor:pointer; }
.emm-part-i:hover { background:rgba(34,211,238,.22); }
.emm-bars { display:flex; flex-direction:column; gap:9px; }
.emm-bar-l { display:flex; justify-content:space-between; font-size:12px; color:#98a8c8; margin-bottom:5px; }
.emm-bar-v { height:7px; border-radius:4px; background:rgba(255,255,255,.07); overflow:hidden; }
.emm-bar-v i { display:block; height:100%; border-radius:4px; background:linear-gradient(90deg,#4f7bff,#a855f7); width:0; }
.emm-bar-v i.bw10 { width:10%; } .emm-bar-v i.bw20 { width:20%; } .emm-bar-v i.bw30 { width:30%; }
.emm-bar-v i.bw40 { width:40%; } .emm-bar-v i.bw50 { width:50%; } .emm-bar-v i.bw60 { width:60%; }
.emm-bar-v i.bw70 { width:70%; } .emm-bar-v i.bw80 { width:80%; } .emm-bar-v i.bw90 { width:90%; }
.emm-bar-v i.bw100 { width:100%; }

/* ---------- toast ---------- */
.emm-toast { position:fixed; left:50%; bottom:36px; transform:translateX(-50%) translateY(20px); background:rgba(12,20,40,.96); border:1px solid rgba(120,160,255,.35); color:#dbe7ff; padding:12px 22px; border-radius:12px; font-size:13.5px; z-index:1200; opacity:0; pointer-events:none; transition:all .25s; }
.emm-toast.on { opacity:1; transform:translateX(-50%) translateY(0); }

@media(max-width:768px){
  .emm-grid { grid-template-columns:1fr; }
  .emm-specs { grid-template-columns:1fr; }
  .emm-matrix { min-width:680px; }
  .emm-sort { float:none; margin-top:10px; }
}
