/* Weard demo - Architecture atlas (React Flow). All rules scoped under .pg-atlas. */
.pg-atlas { height: 100%; min-height: 640px; display: flex; flex-direction: column; color: var(--text); font-family: var(--font); background: var(--navy); }
.pg-atlas *, .pg-atlas *::before, .pg-atlas *::after { box-sizing: border-box; }

.pg-atlas .at-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; padding: 22px 26px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.pg-atlas .at-eyebrow { font: 600 10.5px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--teal); margin-bottom: 8px; }
.pg-atlas h1 { margin: 0; font-size: 26px; font-weight: 700; letter-spacing: -.02em; background: linear-gradient(90deg, #fff, #cbd5e1); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pg-atlas .at-head p { margin: 6px 0 0; color: var(--muted); font-size: 13.5px; max-width: 620px; line-height: 1.5; }
.pg-atlas .at-legend { display: grid; grid-template-columns: repeat(2, auto); gap: 6px 18px; font-size: 11.5px; color: var(--muted); }
.pg-atlas .at-leg { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }

.pg-atlas .at-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 262px minmax(0, 1fr) 300px; }

/* selector */
.pg-atlas .at-list { border-right: 1px solid var(--line); overflow-y: auto; padding: 14px 10px 24px; background: linear-gradient(180deg, rgba(17,26,46,.6), transparent); }
.pg-atlas .at-select { display: none; }
.pg-atlas .at-group + .at-group { margin-top: 16px; }
.pg-atlas .at-group-t { font: 600 10px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); padding: 6px 10px 8px; }
.pg-atlas .at-item { width: 100%; display: grid; grid-template-columns: 22px 1fr auto; align-items: center; gap: 8px; text-align: left; padding: 8px 10px; border-radius: 10px; border: 1px solid transparent; background: transparent; color: var(--muted); font: 500 13px/1.25 var(--font); cursor: pointer; transition: background .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease); }
.pg-atlas .at-item:hover { background: rgba(255,255,255,.03); color: var(--text); }
.pg-atlas .at-item.is-on { background: rgba(45,212,191,.08); border-color: rgba(45,212,191,.35); color: #fff; box-shadow: inset 2px 0 0 var(--teal); }
.pg-atlas .at-num { font: 500 10.5px/1 var(--mono); color: var(--dim); }
.pg-atlas .at-item.is-on .at-num { color: var(--teal); }

/* maturity pills */
.pg-atlas .at-pill { display: inline-flex; align-items: center; gap: 5px; font: 600 9.5px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; padding: 4px 7px; border-radius: 999px; white-space: nowrap; border: 1px solid currentColor; }
.pg-atlas .at-pill.m-built { color: var(--m-built); background: rgba(34,197,94,.08); }
.pg-atlas .at-pill.m-progress { color: var(--m-progress); background: rgba(59,130,246,.1); }
.pg-atlas .at-pill.m-roadmap { color: var(--m-roadmap); background: rgba(167,139,250,.1); }
.pg-atlas .at-pill.m-design { color: var(--m-design); background: rgba(45,212,191,.08); }

/* canvas */
.pg-atlas .at-canvas { position: relative; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.pg-atlas .at-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.pg-atlas .at-bar-t { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.pg-atlas .at-ctrls { display: flex; gap: 6px; }
.pg-atlas .at-btn { height: 32px; min-width: 32px; padding: 0 12px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--card); color: var(--text); font: 600 12.5px/1 var(--font); cursor: pointer; transition: transform .15s var(--ease), background .2s, border-color .2s; }
.pg-atlas .at-btn:hover:not(:disabled) { border-color: var(--teal); }
.pg-atlas .at-btn:active:not(:disabled) { transform: scale(.97); }
.pg-atlas .at-btn:disabled { opacity: .35; cursor: default; }
.pg-atlas .at-play { background: var(--grad); color: #04121a; border: 0; padding: 0 16px; }
.pg-atlas .at-play.is-on { background: #1e2b44; color: #fff; }
.pg-atlas .at-ghost { background: transparent; }
.pg-atlas .at-flow { flex: 1; min-height: 420px; position: relative; }
.pg-atlas .at-caption { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); max-width: min(640px, 90%); display: flex; gap: 12px; align-items: center; padding: 10px 16px; border-radius: 12px; background: rgba(15,23,42,.92); border: 1px solid var(--line-2); backdrop-filter: blur(8px); font-size: 13px; color: var(--muted); box-shadow: var(--shadow); transition: border-color .3s, color .3s; z-index: 5; pointer-events: none; }
.pg-atlas .at-caption.is-on { color: #fff; border-color: rgba(45,212,191,.55); }
.pg-atlas .at-cap-n { font: 600 11px/1 var(--mono); color: var(--teal); white-space: nowrap; }
.pg-atlas .at-cap-idle { font-size: 12px; }

/* React Flow theming */
.pg-atlas .react-flow { background: radial-gradient(1200px 600px at 30% 0%, rgba(45,212,191,.05), transparent 60%), var(--navy); }
.pg-atlas .react-flow__controls { box-shadow: none; border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.pg-atlas .react-flow__controls-button { background: var(--card); border-bottom: 1px solid var(--line); fill: var(--muted); }
.pg-atlas .react-flow__controls-button:hover { background: var(--card-2); }
.pg-atlas .react-flow__minimap { border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.pg-atlas .react-flow__node-zone { pointer-events: none !important; }
.pg-atlas .react-flow__node { font-family: var(--font); }
.pg-atlas .react-flow__edge-textbg { rx: 6; }
.pg-atlas .react-flow__edge.is-active .react-flow__edge-path { stroke-dashoffset: 0; }

.pg-atlas .at-h { opacity: 0; width: 6px; height: 6px; min-width: 0; min-height: 0; border: 0; background: transparent; pointer-events: none; }

.pg-atlas .at-node { position: relative; width: 196px; min-height: 58px; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: linear-gradient(180deg, #13203a, var(--card)); border: 1px solid var(--line-2); box-shadow: 0 8px 22px -14px rgba(0,0,0,.9); color: var(--text); cursor: pointer; transition: opacity .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s var(--ease); }
.pg-atlas .at-node:hover { border-color: rgba(45,212,191,.6); }
.pg-atlas .at-node.is-sel { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(45,212,191,.18), 0 10px 26px -12px rgba(45,212,191,.35); }
.pg-atlas .at-node.is-dim { opacity: .28; }
.pg-atlas .at-node.is-from, .pg-atlas .at-node.is-to { border-color: var(--teal); transform: translateY(-2px); box-shadow: 0 0 0 3px rgba(45,212,191,.2), 0 0 28px -4px rgba(45,212,191,.55); }
.pg-atlas .at-node.is-to { border-color: var(--green); box-shadow: 0 0 0 3px rgba(34,197,94,.22), 0 0 28px -4px rgba(34,197,94,.55); }
.pg-atlas .at-ico { flex: none; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 9px; background: rgba(45,212,191,.1); color: var(--teal); border: 1px solid rgba(45,212,191,.22); }
.pg-atlas .at-ico.lg { width: 40px; height: 40px; border-radius: 11px; }
.pg-atlas .at-txt { min-width: 0; }
.pg-atlas .at-title { font-size: 12.8px; font-weight: 650; line-height: 1.2; }
.pg-atlas .at-sub { font-size: 10.8px; color: var(--muted); line-height: 1.3; margin-top: 3px; font-family: var(--mono); letter-spacing: -.01em; }
.pg-atlas .at-dot { position: absolute; top: 8px; right: 8px; width: 7px; height: 7px; border-radius: 50%; }
.pg-atlas .at-dot.m-built { background: var(--m-built); box-shadow: 0 0 8px var(--m-built); }
.pg-atlas .at-dot.m-progress { background: var(--m-progress); box-shadow: 0 0 8px var(--m-progress); }
.pg-atlas .at-dot.m-roadmap { background: var(--m-roadmap); box-shadow: 0 0 8px var(--m-roadmap); }
.pg-atlas .at-dot.m-design { background: var(--m-design); box-shadow: 0 0 8px var(--m-design); }

.pg-atlas .at-store { padding: 0; flex-direction: column; align-items: stretch; border-radius: 50% / 14px; overflow: visible; }
.pg-atlas .at-cyl-top { height: 14px; margin: -1px -1px 0; border-radius: 50%; border: 1px solid var(--line-2); background: radial-gradient(ellipse at center, #1c2c4a, #13203a); }
.pg-atlas .at-store-body { display: flex; align-items: center; gap: 10px; padding: 6px 12px 12px; }
.pg-atlas .at-store .at-ico { background: rgba(59,130,246,.12); color: #7fb0ff; border-color: rgba(59,130,246,.3); }

.pg-atlas .at-ext { border-style: dashed; border-radius: 30px; background: rgba(15,23,42,.8); }
.pg-atlas .at-ext .at-ico { border-radius: 50%; background: rgba(167,139,250,.1); color: #c4b5fd; border-color: rgba(167,139,250,.3); }

.pg-atlas .at-zone { width: 100%; height: 100%; border-radius: 20px; border: 1px dashed; position: relative; }
.pg-atlas .at-zone-label { position: absolute; top: -11px; left: 16px; padding: 3px 10px; border-radius: 999px; font: 600 10.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; background: var(--navy); border: 1px solid; }
.pg-atlas .tone-cust { border-color: rgba(34,197,94,.35); background: rgba(34,197,94,.035); }
.pg-atlas .tone-cust .at-zone-label { color: #86efac; border-color: rgba(34,197,94,.4); }
.pg-atlas .tone-weard { border-color: rgba(45,212,191,.4); background: rgba(45,212,191,.04); }
.pg-atlas .tone-weard .at-zone-label { color: var(--teal); border-color: rgba(45,212,191,.45); }
.pg-atlas .tone-pub { border-color: rgba(167,139,250,.38); background: rgba(167,139,250,.04); }
.pg-atlas .tone-pub .at-zone-label { color: #c4b5fd; border-color: rgba(167,139,250,.45); }
.pg-atlas .tone-aud { border-color: rgba(245,158,11,.35); background: rgba(245,158,11,.035); }
.pg-atlas .tone-aud .at-zone-label { color: #fcd34d; border-color: rgba(245,158,11,.4); }

/* detail panel */
.pg-atlas .at-detail { border-left: 1px solid var(--line); overflow-y: auto; padding: 16px; background: linear-gradient(180deg, rgba(17,26,46,.5), transparent); }
.pg-atlas .at-card { animation: atIn .35s var(--ease); }
@keyframes atIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.pg-atlas .at-card h3 { margin: 0 0 6px; font-size: 17px; letter-spacing: -.01em; }
.pg-atlas .at-card-h { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.pg-atlas .at-card-h h3 { margin: 0; }
.pg-atlas .at-what { color: #cbd5e1; font-size: 13px; line-height: 1.55; margin: 12px 0; }
.pg-atlas .at-card dl { margin: 0; display: grid; gap: 4px; }
.pg-atlas .at-card dt { font: 600 10px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); margin-top: 10px; }
.pg-atlas .at-card dd { margin: 0; font-size: 13px; color: var(--text); }
.pg-atlas .at-go { margin-top: 16px; width: 100%; height: 38px; border: 0; border-radius: 10px; background: var(--grad); color: #04121a; font: 700 13px/1 var(--font); cursor: pointer; transition: transform .15s var(--ease); }
.pg-atlas .at-go:active { transform: scale(.98); }
.pg-atlas .at-link { margin-top: 12px; background: none; border: 0; color: var(--muted); font-size: 12px; cursor: pointer; padding: 0; text-decoration: underline; text-underline-offset: 3px; }
.pg-atlas .at-steps { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 2px; counter-reset: s; }
.pg-atlas .at-steps li { counter-increment: s; display: grid; grid-template-columns: 22px 8px 1fr; gap: 8px; align-items: baseline; padding: 7px 8px; border-radius: 8px; font-size: 12.3px; line-height: 1.4; color: var(--muted); cursor: pointer; transition: background .2s, color .2s; }
.pg-atlas .at-steps li::before { content: counter(s, decimal-leading-zero); font: 500 10.5px/1 var(--mono); color: var(--dim); }
.pg-atlas .at-steps li i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; transform: translateY(-1px); }
.pg-atlas .at-steps li:hover { background: rgba(255,255,255,.03); color: var(--text); }
.pg-atlas .at-steps li.is-on { background: rgba(45,212,191,.09); color: #fff; }
.pg-atlas .at-note { margin-top: 16px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); font-size: 11.5px; color: var(--muted); line-height: 1.5; }

@media (prefers-reduced-motion: reduce) {
  .pg-atlas .at-node, .pg-atlas .at-card { transition: none; animation: none; }
}

@media (max-width: 1180px) {
  .pg-atlas .at-body { grid-template-columns: 250px minmax(0, 1fr); }
  .pg-atlas .at-detail { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--line); max-height: 320px; }
}
@media (max-width: 760px) {
  .pg-atlas .at-head { padding: 16px; }
  .pg-atlas .at-legend { grid-template-columns: 1fr; }
  .pg-atlas .at-body { grid-template-columns: 1fr; }
  .pg-atlas .at-list { border-right: 0; border-bottom: 1px solid var(--line); padding: 10px 16px; }
  .pg-atlas .at-group { display: none; }
  .pg-atlas .at-select { display: block; width: 100%; height: 40px; border-radius: 10px; background: var(--card); color: var(--text); border: 1px solid var(--line-2); padding: 0 12px; font: 500 14px var(--font); }
  .pg-atlas .at-flow { min-height: 460px; }
  .pg-atlas .at-caption { bottom: 10px; font-size: 12px; }
  .pg-atlas .at-detail { max-height: none; }
}
.pg-atlas .at-elabel { position: absolute; pointer-events: none; font: 600 10px/1 var(--mono); color: #cbd5e1; background: rgba(11,18,32,.94); border: 1px solid; border-radius: 6px; padding: 4px 6px; white-space: nowrap; z-index: 5; transition: opacity .3s var(--ease); }
.pg-atlas .at-elabel.is-active { color: #fff; box-shadow: 0 0 12px currentColor; }
.pg-atlas .at-elabel.is-dim { opacity: .2; }
