/* NRF2–KEAP1 redoxostat interactive research page */
html:has(#nrf2-redoxostat-lab), body:has(#nrf2-redoxostat-lab) {
  min-height:100%;
  background:#050d1d !important;
}
body:has(#nrf2-redoxostat-lab) {
  color:#e8f1ff !important;
  background:
    radial-gradient(ellipse at 85% 4%,rgba(40,83,157,.34),transparent 34rem),
    radial-gradient(ellipse at 8% 48%,rgba(9,129,145,.14),transparent 30rem),
    linear-gradient(145deg,#0a1934 0%,#061126 48%,#050b19 100%) fixed !important;
}
body:has(#nrf2-redoxostat-lab) .post,
body:has(#nrf2-redoxostat-lab) main,
body:has(#nrf2-redoxostat-lab) .container {
  background:transparent !important;
  max-width:none !important;
}
body:has(#nrf2-redoxostat-lab) .post-header,
body:has(#nrf2-redoxostat-lab) .page-header {
  display:none !important;
}
.nrf2-lab,.nrf2-lab * { box-sizing:border-box; }
.nrf2-lab {
  --n2-ink:#e8f1ff;
  --n2-muted:#9bb0d0;
  --n2-line:rgba(147,197,253,.2);
  --n2-cyan:#67e8f9;
  --n2-green:#86efac;
  --n2-violet:#c4b5fd;
  --n2-red:#fda4af;
  width:min(1240px,calc(100% - 2rem));
  margin:0 auto 4rem;
  color:var(--n2-ink);
  font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
.nrf2-lab p { text-align:left !important; }
.nrf2-lab a { color:#93c5fd; }
.nrf2-home {
  display:inline-flex;
  align-items:center;
  gap:.5rem;
  margin:1rem 0 1.15rem;
  padding:.72rem 1rem;
  border:1px solid var(--n2-line);
  border-radius:999px;
  color:#dbeafe !important;
  background:rgba(13,31,65,.66);
  font-weight:750;
  text-decoration:none !important;
}
.nrf2-home:hover { border-color:rgba(103,232,249,.6); background:rgba(30,64,125,.5); }
.nrf2-hero {
  position:relative;
  overflow:hidden;
  padding:clamp(1rem,3.4vw,2.5rem);
  border:1px solid rgba(96,165,250,.27);
  border-radius:25px;
  background:
    radial-gradient(ellipse at 82% 12%,rgba(37,99,235,.2),transparent 35%),
    radial-gradient(ellipse at 8% 72%,rgba(13,148,136,.12),transparent 34%),
    linear-gradient(145deg,rgba(12,29,61,.99),rgba(5,14,31,.99));
  box-shadow:0 24px 60px rgba(0,0,0,.24),inset 0 1px 0 rgba(255,255,255,.04);
}
.nrf2-hero::after {
  content:"";
  position:absolute;
  width:320px;
  height:320px;
  top:-220px;
  right:-140px;
  border:1px solid rgba(103,232,249,.16);
  border-radius:50%;
  box-shadow:0 0 0 26px rgba(103,232,249,.025),0 0 0 57px rgba(103,232,249,.02);
  pointer-events:none;
}
.nrf2-hero > * { position:relative; z-index:1; }
.nrf2-eyebrow,.nrf2-kicker {
  display:flex;
  align-items:center;
  gap:.55rem;
  color:#93c5fd;
  font-size:.68rem;
  font-weight:900;
  letter-spacing:.15em;
  line-height:1.4;
  text-transform:uppercase;
}
.nrf2-live-dot {
  flex:0 0 7px;
  width:7px;
  height:7px;
  border-radius:50%;
  background:#86efac;
  box-shadow:0 0 0 4px rgba(134,239,172,.1),0 0 14px rgba(134,239,172,.65);
}
.nrf2-hero h1 {
  max-width:950px;
  margin:.75rem 0 .1rem !important;
  color:#f2f7ff !important;
  font-size:clamp(2rem,5.2vw,4rem) !important;
  font-weight:800 !important;
  line-height:1.03;
  letter-spacing:-.055em;
}
.nrf2-subtitle {
  margin:.55rem 0 1rem !important;
  color:#a5b4fc;
  font-size:clamp(1.05rem,2vw,1.45rem);
  font-weight:650;
  letter-spacing:-.025em;
}
.nrf2-byline { margin:0 0 1rem; color:#b8c9e5; font-size:.94rem; }
.nrf2-byline strong { color:#f2f7ff; }
.nrf2-hero-meta {
  display:flex;
  flex-wrap:wrap;
  gap:.5rem;
  margin:1rem 0 1.2rem;
}
.nrf2-hero-meta span {
  display:flex;
  flex-wrap:wrap;
  gap:.35rem;
  padding:.5rem .66rem;
  border:1px solid rgba(147,197,253,.16);
  border-radius:9px;
  color:#b4c7e8;
  background:rgba(8,24,51,.62);
  font-size:.72rem;
}
.nrf2-hero-meta b { color:#e8f1ff; }
.nrf2-hero-meta a { text-decoration:none; }
.nrf2-hero-figure {
  position:relative;
  padding:.5rem;
  border:1px solid rgba(147,197,253,.15);
  border-radius:18px;
  background:linear-gradient(140deg,rgba(18,43,81,.66),rgba(3,12,26,.66));
}
.nrf2-desktop-diagram { display:block; width:100%; height:auto; overflow:visible; }
.n2-svg-title { fill:#8da9d4; font:900 13px system-ui,sans-serif; letter-spacing:2px; }
.n2-svg-node rect { fill:url(#n2bg); stroke:rgba(147,197,253,.4); stroke-width:1.4; }
.n2-svg-node { cursor:default; }
.n2-svg-node rect { transition:stroke .2s ease,filter .2s ease; }
.n2-svg-node:hover rect { stroke:#67e8f9; filter:drop-shadow(0 5px 12px rgba(37,99,235,.15)); }
.n2-svg-head { fill:#e8f1ff; font:800 12px system-ui,sans-serif; letter-spacing:.4px; }
.n2-svg-copy { fill:#9bb7db; font:12px system-ui,sans-serif; }
.n2-svg-icon { fill:#07152c; font:900 14px system-ui,sans-serif; }
.n2-icon-red { fill:#fda4af; }
.n2-icon-violet { fill:#c4b5fd; }
.n2-icon-cyan { fill:#67e8f9; }
.n2-icon-green { fill:#86efac; }
.n2-icon-gold { fill:#fcd34d; }
.n2-svg-arrow { fill:none; stroke:#67e8f9; stroke-width:2.5; stroke-linecap:round; stroke-dasharray:5 6; animation:n2-flow 3s linear infinite; }
.n2-svg-feedback { fill:none; stroke:#c4b5fd; stroke-width:2.2; stroke-dasharray:5 5; animation:n2-flow 4.2s linear infinite reverse; }
.n2-svg-resolution { fill:rgba(91,76,170,.12); stroke:rgba(196,181,253,.52); stroke-width:1.4; }
.n2-svg-res-title { fill:#ddd6fe; font:850 13px system-ui,sans-serif; letter-spacing:.8px; }
.n2-svg-res-copy { fill:#b8c9e5; font:12px system-ui,sans-serif; }
.n2-svg-tiny { fill:#9fb3d4; font:800 10px system-ui,sans-serif; letter-spacing:1px; }
.n2-svg-foot { fill:#6685b4; font:850 10px system-ui,sans-serif; letter-spacing:1.4px; }
.nrf2-mobile-diagram { display:none; }
.nrf2-figure-note {
  margin:.65rem .1rem 0 !important;
  color:#8da6cb;
  font-size:.73rem;
  line-height:1.45;
}
@keyframes n2-flow { to { stroke-dashoffset:-44; } }

.nrf2-panel {
  margin:1.1rem 0;
  padding:clamp(1rem,2.7vw,1.7rem);
  border:1px solid var(--n2-line);
  border-radius:19px;
  background:linear-gradient(145deg,rgba(12,28,56,.96),rgba(6,16,34,.98));
  box-shadow:0 16px 40px rgba(0,0,0,.14),inset 0 1px 0 rgba(255,255,255,.025);
}
.nrf2-section-head {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:1rem;
  margin-bottom:1.2rem;
}
.nrf2-section-head h2 {
  margin:.35rem 0 .42rem !important;
  color:#eaf2ff !important;
  font-size:clamp(1.35rem,3.1vw,2rem) !important;
  font-weight:800 !important;
  letter-spacing:-.04em;
  line-height:1.15;
}
.nrf2-section-head p { margin:0 !important; color:var(--n2-muted); font-size:.88rem; line-height:1.55; }
.nrf2-tag {
  flex:0 0 auto;
  padding:.35rem .56rem;
  border:1px solid rgba(147,197,253,.18);
  border-radius:999px;
  color:#9cc5ff;
  background:rgba(37,99,235,.08);
  font-size:.61rem;
  font-weight:850;
  letter-spacing:.1em;
  text-transform:uppercase;
}
.nrf2-presets,.nrf2-model-tabs { display:flex; flex-wrap:wrap; gap:.48rem; margin-bottom:1rem; }
.n2-chip,.nrf2-model-tabs button {
  min-height:38px;
  padding:.58rem .82rem;
  border:1px solid rgba(147,197,253,.2);
  border-radius:999px;
  color:#a9bddc;
  background:rgba(15,35,70,.38);
  font:inherit;
  font-size:.8rem;
  font-weight:800;
  cursor:pointer;
  transition:background .2s ease,border-color .2s ease,color .2s ease,transform .2s ease;
}
.n2-chip:hover,.nrf2-model-tabs button:hover { border-color:rgba(103,232,249,.45); transform:translateY(-1px); }
.n2-chip.is-active,.nrf2-model-tabs button.is-active {
  border-color:rgba(103,232,249,.57);
  color:#e6fbff;
  background:linear-gradient(135deg,rgba(8,145,178,.3),rgba(37,99,235,.22));
  box-shadow:inset 0 1px 0 rgba(255,255,255,.04);
}
.nrf2-sim-layout { display:grid; grid-template-columns:minmax(240px,.72fr) minmax(0,1.5fr); gap:1rem; align-items:stretch; }
.nrf2-controls,.nrf2-sim-readout {
  min-width:0;
  padding:1rem;
  border:1px solid rgba(147,197,253,.13);
  border-radius:14px;
  background:rgba(3,12,27,.44);
}
.n2-range-row { display:flex; align-items:center; justify-content:space-between; gap:.8rem; margin:.25rem 0 .15rem; color:#dce8fc; font-size:.82rem; font-weight:750; }
.n2-range-row output { color:#67e8f9; font-size:.78rem; font-weight:900; font-variant-numeric:tabular-nums; }
.nrf2-controls input[type=range] { display:block; width:100%; margin:.3rem 0 1.1rem; accent-color:#67e8f9; cursor:pointer; }
.n2-control-help { margin:-.7rem 0 1rem !important; color:#7f96bb; font-size:.7rem; line-height:1.45; }
.nrf2-reset {
  width:100%;
  min-height:40px;
  margin-top:.1rem;
  border:1px solid rgba(147,197,253,.25);
  border-radius:9px;
  color:#dbeafe;
  background:rgba(37,99,235,.13);
  font:inherit;
  font-size:.8rem;
  font-weight:800;
  cursor:pointer;
}
.nrf2-reset:hover { border-color:#67e8f9; background:rgba(37,99,235,.24); }
.n2-status-line { display:flex; align-items:center; gap:.55rem; margin-bottom:.65rem; color:#d8e8ff; font-size:.8rem; font-weight:850; }
.n2-status-dot { width:8px; height:8px; border-radius:50%; background:#86efac; box-shadow:0 0 0 4px rgba(134,239,172,.1); }
.n2-status-line.is-persistent .n2-status-dot { background:#fda4af; box-shadow:0 0 0 4px rgba(253,164,175,.12); }
.n2-chart { display:block; width:100%; height:auto; overflow:visible; border:1px solid rgba(147,197,253,.12); border-radius:11px; background:rgba(2,8,20,.38); }
.n2-gridlines path { stroke:rgba(147,197,253,.12); stroke-dasharray:3 5; }
.n2-axis { fill:none; stroke:rgba(147,197,253,.4); stroke-width:1.2; }
.n2-axis-label { fill:#7f9bc4; font:700 10px system-ui,sans-serif; letter-spacing:.6px; }
.n2-input-trace { fill:none; stroke:#fbbf24; stroke-width:2.2; stroke-linejoin:round; }
.n2-output-trace { fill:none; stroke:#67e8f9; stroke-width:3.2; stroke-linecap:round; stroke-linejoin:round; filter:drop-shadow(0 0 4px rgba(103,232,249,.25)); }
.n2-resolved-trace { fill:none; stroke:#c4b5fd; stroke-width:2.2; stroke-dasharray:6 5; stroke-linecap:round; }
.nrf2-chart-legend { display:flex; flex-wrap:wrap; gap:.5rem 1rem; margin:.65rem 0 .85rem; color:#a9bddb; font-size:.7rem; }
.nrf2-chart-legend span { display:flex; align-items:center; gap:.4rem; }
.nrf2-chart-legend i { display:inline-block; width:17px; height:3px; border-radius:999px; }
.n2-legend-input { background:#fbbf24; }
.n2-legend-output { background:#67e8f9; }
.n2-legend-resolved { background:#c4b5fd; }
.nrf2-readout-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:.55rem; }
.nrf2-readout-grid div { padding:.7rem .75rem; border:1px solid rgba(147,197,253,.14); border-radius:10px; background:rgba(15,35,70,.35); }
.nrf2-readout-grid span { display:block; margin-bottom:.2rem; color:#91a8ca; font-size:.68rem; }
.nrf2-readout-grid strong { color:#e7f3ff; font-size:1.25rem; font-variant-numeric:tabular-nums; }
.nrf2-output-note { min-height:2.8em; margin:.8rem 0 0 !important; color:#b9cde9; font-size:.82rem; line-height:1.5; }

.nrf2-node-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:.62rem; }
.n2-arch-node {
  display:grid;
  grid-template-columns:34px minmax(0,1fr);
  gap:.05rem .65rem;
  align-items:center;
  min-width:0;
  min-height:76px;
  padding:.72rem;
  border:1px solid rgba(147,197,253,.17);
  border-radius:12px;
  color:#deebff;
  background:linear-gradient(145deg,rgba(18,43,83,.6),rgba(5,16,33,.8));
  text-align:left;
  cursor:pointer;
  transition:transform .2s ease,border-color .2s ease,background .2s ease;
}
.n2-arch-node:hover { transform:translateY(-2px); border-color:rgba(103,232,249,.45); }
.n2-arch-node.is-active { border-color:rgba(103,232,249,.62); background:linear-gradient(145deg,rgba(8,145,178,.2),rgba(37,99,235,.13)); }
.n2-arch-node > span { grid-row:span 2; display:grid; place-items:center; width:32px; height:32px; border:1px solid rgba(147,197,253,.2); border-radius:9px; color:#67e8f9; background:rgba(3,12,27,.6); font-size:.67rem; font-weight:900; }
.n2-arch-node b { font-size:.86rem; line-height:1.3; }
.n2-arch-node small { color:#91a8ca; font-size:.69rem; line-height:1.4; }
.nrf2-node-detail {
  display:grid;
  grid-template-columns:64px minmax(0,1fr);
  gap:1rem;
  align-items:start;
  margin-top:.8rem;
  padding:1rem;
  border:1px solid rgba(147,197,253,.16);
  border-radius:14px;
  background:rgba(3,12,27,.46);
}
.n2-detail-icon { display:grid; place-items:center; width:58px; height:58px; border:1px solid rgba(103,232,249,.35); border-radius:16px; color:#67e8f9; background:rgba(8,145,178,.11); font-size:1.5rem; font-weight:900; }
.nrf2-node-detail h3,.nrf2-failure-detail h3,.nrf2-experiment-output h3,.nrf2-context-detail h3 { margin:.28rem 0 .45rem !important; color:#eaf2ff !important; font-size:1.18rem !important; font-weight:800 !important; line-height:1.22; }
.nrf2-node-detail p,.nrf2-failure-detail p,.nrf2-experiment-output p,.nrf2-context-detail p { margin:.3rem 0 !important; color:#9fb4d5; font-size:.83rem; line-height:1.6; }
.n2-function,.n2-failure-row,.n2-context-bottom,.n2-experiment-readout { display:grid; grid-template-columns:145px minmax(0,1fr); gap:.7rem; margin-top:.85rem; padding:.7rem .75rem; border:1px solid rgba(147,197,253,.12); border-radius:9px; background:rgba(15,35,70,.35); }
.n2-function b,.n2-failure-row b,.n2-context-bottom b,.n2-experiment-readout b { color:#c7d8f1; font-size:.72rem; }
.n2-function span,.n2-failure-row span,.n2-context-bottom span,.n2-experiment-readout span { color:#94acd0; font-size:.77rem; line-height:1.5; }

.nrf2-failure-layout { display:grid; grid-template-columns:minmax(280px,.86fr) minmax(0,1.2fr); gap:1rem; }
.nrf2-failure-list { display:grid; align-content:start; gap:.45rem; }
.n2-failure-btn { display:grid; grid-template-columns:32px minmax(0,1fr) 16px; gap:.65rem; align-items:center; min-width:0; padding:.68rem; border:1px solid rgba(147,197,253,.15); border-radius:11px; color:#dbeafe; background:rgba(6,18,38,.6); text-align:left; cursor:pointer; transition:border-color .2s ease,background .2s ease; }
.n2-failure-btn:hover,.n2-failure-btn.is-active { border-color:rgba(253,164,175,.5); background:rgba(127,29,29,.13); }
.n2-failure-num { display:grid; place-items:center; width:30px; height:30px; border:1px solid rgba(253,164,175,.25); border-radius:8px; color:#fda4af; font-size:.68rem; font-weight:900; }
.n2-failure-btn b { display:block; font-size:.8rem; line-height:1.3; }
.n2-failure-btn small { display:block; margin-top:.15rem; color:#8fa6c9; font-size:.68rem; line-height:1.35; }
.n2-failure-btn > i { color:#fda4af; font-style:normal; }
.nrf2-failure-detail { min-width:0; padding:1rem; border:1px solid rgba(253,164,175,.18); border-radius:14px; background:linear-gradient(145deg,rgba(65,25,46,.22),rgba(3,12,27,.53)); }
.n2-failure-visual { margin:-.1rem 0 .85rem; padding:.45rem; border:1px solid rgba(253,164,175,.13); border-radius:10px; background:rgba(3,12,27,.3); }
.n2-failure-track { stroke:rgba(147,197,253,.15); stroke-width:3; }
.n2-failure-node { fill:#132d52; stroke:rgba(147,197,253,.42); stroke-width:1.5; }
.n2-failure-visual text:not(.n2-mini-label) { fill:#deebff; font:900 12px system-ui,sans-serif; }
.n2-failure-link { fill:none; stroke:#67e8f9; stroke-width:2.2; }
.n2-failure-break { fill:none; stroke:#fda4af; stroke-width:4; stroke-linecap:round; }
.n2-mini-label { fill:#829bc1; font:700 9px system-ui,sans-serif; letter-spacing:.5px; }

.nrf2-model-visual { padding:.6rem; border:1px solid rgba(147,197,253,.13); border-radius:13px; background:rgba(3,12,27,.43); }
#n2-model-chart { display:block; width:100%; height:auto; }
.n2-model-grid { fill:none; stroke:rgba(147,197,253,.12); stroke-dasharray:3 6; }
.n2-model-axis { fill:none; stroke:rgba(147,197,253,.35); stroke-width:1.2; }
.n2-model-line { fill:none; stroke:#67e8f9; stroke-width:3; stroke-linecap:round; stroke-linejoin:round; }
.n2-model-line-secondary { stroke:#fda4af; stroke-width:2.5; stroke-dasharray:7 6; }
.nrf2-model-visual[data-model="switch"] .n2-model-line-secondary { opacity:.95; }
.nrf2-model-visual[data-model="switch"] .n2-model-line { opacity:.5; }
.nrf2-model-visual[data-model="circuit"] .n2-model-line-secondary { opacity:.3; }
.nrf2-model-visual[data-model="circuit"] .n2-model-line { opacity:1; }
.nrf2-model-caption { padding:.75rem .4rem .3rem; color:#9fb4d5; font-size:.82rem; line-height:1.55; }
.nrf2-model-caption b { color:#e0ecff; }
.nrf2-compare-grid { display:grid; grid-template-columns:1fr 1fr; gap:.65rem; margin-top:.7rem; }
.nrf2-compare-grid article { padding:.9rem; border:1px solid rgba(147,197,253,.13); border-radius:12px; background:rgba(15,35,70,.28); }
.nrf2-compare-grid h3 { margin:.6rem 0 .3rem !important; color:#e8f1ff !important; font-size:.95rem !important; }
.nrf2-compare-grid p { margin:0 !important; color:#95add0; font-size:.78rem; line-height:1.5; }
.n2-compare-mark { display:inline-flex; padding:.27rem .45rem; border-radius:6px; font-size:.62rem; font-weight:900; letter-spacing:.08em; }
.switch-mark { color:#fda4af; background:rgba(190,24,93,.12); }
.circuit-mark { color:#67e8f9; background:rgba(8,145,178,.12); }

.nrf2-experiment-builder { display:grid; grid-template-columns:minmax(260px,.8fr) minmax(0,1.15fr); gap:1rem; }
.nrf2-builder-controls,.nrf2-experiment-output { min-width:0; padding:1rem; border:1px solid rgba(147,197,253,.14); border-radius:13px; background:rgba(3,12,27,.42); }
.nrf2-builder-controls label { display:block; margin:.2rem 0 .38rem; color:#d6e5fb; font-size:.8rem; font-weight:800; }
.nrf2-builder-controls select { display:block; width:100%; min-height:43px; margin-bottom:1rem; padding:.55rem .65rem; border:1px solid rgba(147,197,253,.23); border-radius:9px; color:#e8f1ff; background:#0b1c38; font:inherit; font-size:.8rem; }
.nrf2-primary-btn { width:100%; min-height:42px; padding:.65rem .9rem; border:1px solid rgba(103,232,249,.45); border-radius:9px; color:#eaffff; background:linear-gradient(120deg,rgba(8,145,178,.38),rgba(37,99,235,.4)); font:inherit; font-size:.82rem; font-weight:900; cursor:pointer; }
.nrf2-primary-btn:hover { border-color:#67e8f9; filter:brightness(1.1); }
.nrf2-experiment-output { background:linear-gradient(145deg,rgba(15,39,74,.55),rgba(3,12,27,.55)); }
.n2-experiment-path { display:flex; align-items:center; justify-content:space-between; gap:.3rem; margin:1rem 0; }
.n2-experiment-path span { flex:1; padding:.58rem .3rem; border:1px solid rgba(103,232,249,.22); border-radius:8px; color:#cdeeff; background:rgba(8,145,178,.07); font-size:.69rem; font-weight:850; text-align:center; }
.n2-experiment-path i { color:#67e8f9; font-style:normal; }
.nrf2-experiment-output .nrf2-kicker { font-size:.62rem; }
.n2-experiment-status { margin:.65rem 0 0 !important; color:#8ea8d0; font-size:.7rem; line-height:1.4; }
.nrf2-experiment-output[data-generated="false"] { border-color:rgba(251,191,36,.35); }
.n2-experiment-compare { display:grid; grid-template-columns:1fr 1fr; gap:.65rem; margin:.9rem 0; }
.n2-experiment-compare article { min-width:0; padding:.8rem; border:1px solid rgba(147,197,253,.15); border-radius:10px; background:rgba(4,14,30,.48); }
.n2-experiment-compare article:last-child { border-color:rgba(103,232,249,.28); background:rgba(8,55,71,.19); }
.n2-prediction-label { display:block; color:#8faed9; font-size:.61rem; font-weight:900; letter-spacing:.09em; line-height:1.4; }
.n2-experiment-compare article:last-child .n2-prediction-label { color:#67e8f9; }
.n2-experiment-compare p { margin:.45rem 0 0 !important; color:#aac0df; font-size:.77rem; line-height:1.55; }
.n2-experiment-details { display:grid; gap:.45rem; margin-top:.75rem; }
.n2-experiment-details .n2-experiment-readout { grid-template-columns:125px minmax(0,1fr); margin:0; align-items:start; }
.n2-experiment-readout b { align-self:start; }
.n2-experiment-readout span { overflow-wrap:anywhere; }


.nrf2-context-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:.6rem; }
.n2-context { display:flex; flex-direction:column; align-items:flex-start; min-width:0; min-height:126px; padding:.85rem; border:1px solid rgba(147,197,253,.15); border-radius:12px; color:#dce9ff; background:rgba(3,12,27,.45); text-align:left; cursor:pointer; transition:transform .2s ease,border-color .2s ease,background .2s ease; }
.n2-context:hover { transform:translateY(-2px); border-color:rgba(103,232,249,.38); }
.n2-context.is-active { border-color:rgba(103,232,249,.56); background:linear-gradient(145deg,rgba(8,145,178,.17),rgba(37,99,235,.13)); }
.n2-context-icon { display:grid; place-items:center; width:36px; height:36px; margin-bottom:.6rem; border:1px solid rgba(103,232,249,.22); border-radius:10px; color:#67e8f9; background:rgba(8,145,178,.1); font-size:1.2rem; }
.n2-context b { font-size:.81rem; line-height:1.35; }
.n2-context small { margin-top:.3rem; color:#91a8ca; font-size:.68rem; line-height:1.4; }
.nrf2-context-detail { display:grid; grid-template-columns:70px minmax(0,1fr); gap:1rem; align-items:start; margin-top:.75rem; padding:1rem; border:1px solid rgba(147,197,253,.13); border-radius:13px; background:rgba(3,12,27,.43); }
.n2-context-big { display:grid; place-items:center; width:64px; height:64px; border:1px solid rgba(103,232,249,.25); border-radius:19px; color:#67e8f9; background:rgba(8,145,178,.1); font-size:1.9rem; }

.nrf2-takeaway {
  display:grid;
  grid-template-columns:110px minmax(0,1fr);
  align-items:center;
  gap:1.3rem;
  margin:1.1rem 0;
  padding:1.25rem;
  border:1px solid rgba(103,232,249,.23);
  border-radius:18px;
  background:radial-gradient(ellipse at 12% 50%,rgba(8,145,178,.13),transparent 40%),linear-gradient(130deg,rgba(12,29,61,.91),rgba(5,14,31,.97));
}
.nrf2-takeaway h2 { margin:.45rem 0 .5rem !important; color:#eaf2ff !important; font-size:clamp(1.35rem,3vw,2rem) !important; font-weight:850 !important; line-height:1.15; letter-spacing:-.04em; }
.nrf2-takeaway p { margin:0 0 .75rem !important; color:#a6bbda; font-size:.85rem; line-height:1.55; }
.nrf2-takeaway a { font-size:.82rem; font-weight:850; text-decoration:none; }
.nrf2-takeaway-orbit { position:relative; display:grid; place-items:center; width:104px; height:104px; border:1px solid rgba(103,232,249,.3); border-radius:50%; }
.nrf2-takeaway-orbit::before,.nrf2-takeaway-orbit::after { position:absolute; inset:12px; content:""; border:1px solid rgba(196,181,253,.32); border-radius:50%; transform:rotate(45deg) scaleX(.48); }
.nrf2-takeaway-orbit::after { transform:rotate(-45deg) scaleX(.48); border-color:rgba(103,232,249,.36); }
.nrf2-takeaway-orbit span { position:absolute; width:8px; height:8px; border-radius:50%; background:#67e8f9; box-shadow:0 0 12px rgba(103,232,249,.5); }
.nrf2-takeaway-orbit span:nth-child(1) { top:7px; left:48px; }
.nrf2-takeaway-orbit span:nth-child(2) { right:10px; bottom:29px; background:#c4b5fd; }
.nrf2-takeaway-orbit span:nth-child(3) { left:12px; bottom:23px; background:#86efac; }
.nrf2-takeaway-orbit i { z-index:2; color:#e8f1ff; font-size:1.5rem; font-style:normal; font-weight:950; }
.nrf2-bottom { display:flex; justify-content:space-between; gap:1rem; padding:.5rem .15rem; color:#708bb5; font-size:.72rem; }
.nrf2-bottom a { font-weight:800; text-decoration:none; }

.nrf2-lab button:focus-visible,.nrf2-lab select:focus-visible,.nrf2-lab input:focus-visible,.nrf2-lab a:focus-visible { outline:2px solid #67e8f9; outline-offset:3px; }
@media(max-width:900px) {
  .nrf2-sim-layout,.nrf2-failure-layout,.nrf2-experiment-builder { grid-template-columns:1fr; }
  .nrf2-controls { display:grid; grid-template-columns:1fr 1fr; column-gap:1rem; }
  .nrf2-controls .nrf2-reset { grid-column:1/-1; }
  .nrf2-node-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .nrf2-context-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media(max-width:680px) {
  .nrf2-lab { width:calc(100% - 1rem); margin-bottom:2.5rem; }
  .nrf2-home { margin-top:.55rem; font-size:.86rem; }
  .nrf2-hero { padding:1rem; border-radius:18px; }
  .nrf2-hero h1 { font-size:clamp(1.9rem,8vw,2.75rem) !important; }
  .nrf2-hero-meta { display:grid; grid-template-columns:1fr; }
  .nrf2-hero-meta span { font-size:.75rem; }
  .nrf2-desktop-diagram { display:none; }
  .nrf2-mobile-diagram { display:grid; gap:0; padding:.5rem; }
  .n2-mobile-node { display:grid; grid-template-columns:43px minmax(0,1fr); gap:.7rem; align-items:center; padding:.7rem; border:1px solid rgba(147,197,253,.24); border-radius:11px; background:linear-gradient(145deg,rgba(18,43,83,.78),rgba(5,16,33,.9)); }
  .n2-mobile-node > span { display:grid; place-items:center; width:38px; height:38px; border:1px solid rgba(103,232,249,.3); border-radius:11px; color:#67e8f9; background:rgba(8,145,178,.1); font-size:1rem; font-weight:950; }
  .n2-mobile-node.stress > span { color:#fda4af; border-color:rgba(253,164,175,.3); }
  .n2-mobile-node b { display:block; color:#e8f1ff; font-size:.87rem; }
  .n2-mobile-node small { display:block; margin-top:.15rem; color:#91a8ca; font-size:.72rem; }
  .nrf2-mobile-diagram > i { height:22px; color:#67e8f9; font-size:1.2rem; font-style:normal; text-align:center; }
  .n2-mobile-return { display:grid; grid-template-columns:28px minmax(0,1fr); gap:.15rem .5rem; margin-top:.55rem; padding:.75rem; border:1px solid rgba(196,181,253,.32); border-radius:11px; color:#ddd6fe; background:rgba(91,76,170,.1); font-size:.83rem; }
  .n2-mobile-return:first-letter { font-size:1.1rem; }
  .n2-mobile-return small { grid-column:2; color:#aab9d8; font-size:.72rem; line-height:1.45; }
  .nrf2-section-head { display:block; }
  .nrf2-tag { display:inline-flex; margin-top:.65rem; }
  .nrf2-panel { padding:.9rem; border-radius:15px; }
  .nrf2-controls { grid-template-columns:1fr; }
  .nrf2-controls .nrf2-reset { grid-column:auto; }
  .nrf2-readout-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .nrf2-readout-grid div { padding:.58rem; }
  .nrf2-readout-grid strong { font-size:1.02rem; }
  .nrf2-node-grid { grid-template-columns:1fr 1fr; gap:.45rem; }
  .n2-arch-node { grid-template-columns:28px minmax(0,1fr); gap:.05rem .5rem; min-height:69px; padding:.55rem; }
  .n2-arch-node > span { width:27px; height:27px; font-size:.61rem; }
  .n2-arch-node b { font-size:.76rem; }
  .n2-arch-node small { font-size:.62rem; }
  .nrf2-node-detail { grid-template-columns:45px minmax(0,1fr); gap:.7rem; padding:.8rem; }
  .n2-detail-icon { width:42px; height:42px; border-radius:12px; font-size:1.15rem; }
  .n2-function,.n2-failure-row,.n2-context-bottom,.n2-experiment-readout { grid-template-columns:1fr; gap:.28rem; }
  .nrf2-failure-layout { grid-template-columns:minmax(0,1fr); }
  .n2-failure-btn { padding:.6rem; }
  .nrf2-compare-grid { grid-template-columns:1fr; }
  .n2-experiment-compare { grid-template-columns:1fr; }
  .n2-experiment-details .n2-experiment-readout { grid-template-columns:1fr; }
  .n2-experiment-path span { font-size:.61rem; }
  .nrf2-context-grid { grid-template-columns:1fr 1fr; gap:.45rem; }
  .n2-context { min-height:110px; padding:.65rem; }
  .n2-context b { font-size:.75rem; }
  .nrf2-context-detail { grid-template-columns:44px minmax(0,1fr); gap:.65rem; padding:.8rem; }
  .n2-context-big { width:42px; height:42px; border-radius:12px; font-size:1.2rem; }
  .nrf2-takeaway { grid-template-columns:1fr; gap:.85rem; padding:1rem; }
  .nrf2-takeaway-orbit { width:75px; height:75px; }
  .nrf2-takeaway-orbit::before,.nrf2-takeaway-orbit::after { inset:9px; }
  .nrf2-takeaway-orbit span:nth-child(1) { left:33px; top:4px; }
  .nrf2-bottom { flex-direction:column; gap:.45rem; }
}
@media(max-width:360px) {
  .nrf2-readout-grid strong { font-size:.92rem; }
  .n2-arch-node { grid-template-columns:1fr; }
  .n2-arch-node > span { grid-row:auto; margin-bottom:.2rem; }
}
@media(prefers-reduced-motion:reduce) {
  .nrf2-lab *, .nrf2-lab *::before, .nrf2-lab *::after { animation:none !important; transition:none !important; scroll-behavior:auto !important; }
}
