/* Home page: interactive Echo capability map. */
.emp-section {
    width: 100%;
    background: #f1f3f6;
    padding: 5rem 1.5rem 5.5rem;
    display: flex;
    justify-content: center;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}
.emp-inner { width: 100%; max-width: 1180px; }

.emp-head { text-align: center; max-width: 46rem; margin: 0 auto 2.4rem; }
.emp-title {
    margin: 0;
    /* identical to the home hero heading (.ed-title) */
    font-family: 'Inter Tight', 'Inter', system-ui, sans-serif;
    font-size: clamp(26px, min(4.3vw, 6.2vh), 46px);
    font-weight: 500;
    color: #0f172a;
    letter-spacing: -0.022em;
    line-height: 1.08;
    text-wrap: balance;
}
.emp-title span { color: inherit; }
.emp-sub { margin: 1rem auto 0; max-width: 36rem; font-size: 1.04rem; line-height: 1.6; color: #475569; }
.emp-cta { margin-top: 1.5rem; display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; }
.emp-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: .95rem 1.7rem; border-radius: 8px;   /* same rectangle as the hero buttons */
    font: inherit; font-size: .98rem; font-weight: 600; text-decoration: none; cursor: pointer;
    border: 1px solid transparent;
    transition: transform .15s, box-shadow .15s, background .15s;
}
.emp-btn:hover { transform: translateY(-2px); }
.emp-btn:focus-visible { outline: 3px solid #00A896; outline-offset: 3px; }
.emp-btn--primary { background: #0b1020; color: #fff; box-shadow: 0 8px 24px rgba(11, 16, 32, .18); }
.emp-btn--primary:hover { box-shadow: 0 12px 30px rgba(11, 16, 32, .25); background: #1e293b; }
.emp-btn--ghost { background: #fff; color: #0b1020; border-color: rgba(15, 23, 42, .10); }
.emp-stat { margin-top: 1rem; font-size: .8rem; color: #64748b; letter-spacing: .02em; }

/* ── The map card ── */
.emap {
    --bg: #1f2430;
    position: relative;
    height: clamp(460px, 62vw, 700px);
    border-radius: 18px;
    background: var(--bg);
    overflow: hidden;
    box-shadow: 0 30px 60px -34px rgba(11, 16, 32, .6), 0 0 0 1px rgba(255, 255, 255, .04) inset;
    color: #e8e4d6;
    user-select: none;
    -webkit-user-select: none;
    transform-origin: 50% 100%;
    will-change: transform;
    --emap-p: 0;
}
.emap.is-full { position: fixed; inset: 0; z-index: 2147483000; height: auto; border-radius: 0; transform: none !important; will-change: auto; }
html.emap-lock { overflow: hidden; }

.emap-svg { display: block; width: 100%; height: 100%; cursor: grab; touch-action: pan-y pinch-zoom; }
.emap.is-full .emap-svg { touch-action: none; }
.emap.is-dragging .emap-svg { cursor: grabbing; }
.emap-sky { transition: opacity .3s; }

/* ── Entrance: same motion as the dashboard map ──
   Every animation lives on a wrapper <g>; dimming and search live on inner nodes,
   because an animation's `forwards` opacity would otherwise override them. */
.emap-draw {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
}
.emap.is-in .emap-draw {
    animation: emap-drawline .55s ease forwards;
    animation-delay: var(--d, 0s);
}
@keyframes emap-drawline { to { stroke-dashoffset: 0; } }

.emap-pop { opacity: 0; transform-box: fill-box; transform-origin: center; }
.emap.is-in .emap-pop {
    animation: emap-nodepop .45s cubic-bezier(.2, .9, .3, 1.4) forwards;
    animation-delay: var(--d, 0s);
}
@keyframes emap-nodepop { from { opacity: 0; transform: scale(.3); } to { opacity: 1; transform: scale(1); } }

.emap-fade { opacity: 0; }
.emap.is-in .emap-fade { animation: emap-fadein .5s ease forwards; animation-delay: var(--d, 0s); }
@keyframes emap-fadein { to { opacity: 1; } }

/* Ambient: stars breathe out of sync, and the whole constellation sways a hair. */
.emap-star { fill: #fff; opacity: var(--o, .3); animation: emap-twinkle 6s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes emap-twinkle { 0%, 100% { opacity: var(--o, .3); } 50% { opacity: calc(var(--o, .3) * .28); } }
.emap-spark { opacity: var(--o, .7); animation: emap-spark 3.4s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes emap-spark { 50% { opacity: calc(var(--o, .7) * .35); } }
.emap-drift { animation: emap-drift 12s ease-in-out infinite alternate; transition: opacity .45s ease; }
@keyframes emap-drift { from { transform: translate(2.4px, -2.8px); } to { transform: translate(-2.4px, 2.8px); } }

/* Edges */
.emap-e-spoke { stroke: rgba(255, 255, 255, .22); stroke-width: 1.6; stroke-linecap: round; fill: none; }
.emap-e-branch { stroke-width: 1.8; stroke-linecap: round; fill: none; opacity: .5; }
.emap-e-twig { stroke: rgba(255, 255, 255, .3); stroke-width: 1.6; stroke-linecap: round; fill: none; }
.emap-f-edge { stroke: rgba(255, 255, 255, .28); stroke-width: 1.8; stroke-linecap: round; }
.emap-dept-edges, .emap-dept, .emap-label { transition: opacity .3s; }
.emap-dept-edges.is-dim, .emap-dept.is-dim, .emap-label.is-dim { opacity: .2; }
.emap-dept.is-dim .emap-leaf, .emap-dept.is-dim .emap-hub { pointer-events: none; }

/* Nodes */
.emap-leaf { cursor: pointer; outline: none; }
.emap-leaf-hit { fill: transparent; }
.emap-leaf-dot { fill: #f2eedf; stroke: #1f2430; stroke-width: 2; transition: r .18s ease, fill .18s ease, opacity .25s; }
.emap-leaf:hover .emap-leaf-dot, .emap-leaf:focus-visible .emap-leaf-dot { fill: #fff; r: 13.5; }
.emap-leaf:focus-visible .emap-leaf-dot { stroke: #00A896; stroke-width: 3; }
.emap-leaf-ring { fill: none; stroke: #f2eedf; stroke-width: 1.4; stroke-dasharray: 3 3; opacity: .75; transition: opacity .25s; }
.emap-leaf.is-selected .emap-leaf-dot { fill: #fff; r: 14; }
.emap-leaf.is-selected .emap-leaf-ring { stroke: #fff; opacity: 1; r: 21; }
.emap-group { opacity: .9; }

.emap-hub { cursor: pointer; outline: none; }
.emap-hub-hit { fill: transparent; }
.emap-hub-ring { fill: #1f2430; stroke: var(--c); stroke-width: 2.5; transition: r .18s ease, filter .2s; }
.emap-hub-dot { fill: var(--c); }
.emap-hub:hover .emap-hub-ring, .emap-hub:focus-visible .emap-hub-ring { r: 30; filter: drop-shadow(0 0 10px var(--c)); }
.emap-hub:focus-visible .emap-hub-ring { stroke-width: 4; }

.emap-core { cursor: pointer; outline: none; }
.emap-core-hit { fill: transparent; }
.emap-core:focus-visible .emap-core-hit { stroke: #00A896; stroke-width: 3; }
.emap-core-name { font-family: 'Inter Tight', 'Inter', sans-serif; font-weight: 700; font-size: 17px; letter-spacing: .26em; fill: #e8eaf0; }
.emap-core-sub { font-family: 'Inter', sans-serif; font-size: 12px; letter-spacing: .06em; fill: #6b7482; }

/* labels */
.emap-label { cursor: pointer; }
.emap-label-name { font-family: 'Inter Tight', 'Inter', sans-serif; font-weight: 600; font-size: 30px; letter-spacing: .2em; fill: #f2eedf; transition: fill .2s; }
.emap-label-sub { font-family: 'Inter', sans-serif; font-size: 15px; letter-spacing: .06em; fill: #7f8799; }
.emap-label:hover .emap-label-name { fill: var(--c); }

/* ── Fan: one department alone ── */
.emap-ghost { font-family: 'Inter Tight', 'Inter', sans-serif; font-weight: 800; font-size: 190px; letter-spacing: .1em; fill: #fff; opacity: .025; pointer-events: none; }
.emap-fan-group { font-family: 'Inter', sans-serif; font-weight: 700; font-size: 13px; letter-spacing: .18em; fill: #8b94a3; pointer-events: none; }
.emap-fnode { cursor: pointer; outline: none; transition: opacity .3s; }
.emap-fnode-hit { fill: transparent; }
.emap-fnode-halo { opacity: 0; transition: opacity .2s; pointer-events: none; }
.emap-fnode-disc { fill: #ece9e0; stroke: rgba(255, 255, 255, .3); stroke-width: 1; transition: r .18s ease, opacity .25s; }
.emap-fnode-core { fill: #1a1d26; opacity: .85; transition: opacity .25s; pointer-events: none; }
.emap-fnode.is-beta .emap-fnode-disc { fill: #12151d; stroke: var(--c); stroke-width: 2; stroke-dasharray: 3 3; }
.emap-fnode.is-beta .emap-fnode-core { fill: var(--c); }
.emap-fnode-sel { fill: none; stroke: #fff; stroke-width: 1.8; opacity: 0; pointer-events: none; transition: opacity .2s; }
.emap-fnode-name { font-family: 'Inter', sans-serif; font-weight: 500; font-size: 14px; fill: #aeb6c4; pointer-events: none; transition: fill .2s; }
.emap-fnode:hover .emap-fnode-halo, .emap-fnode:focus-visible .emap-fnode-halo, .emap-fnode.is-selected .emap-fnode-halo { opacity: 1; }
.emap-fnode:hover .emap-fnode-disc, .emap-fnode:focus-visible .emap-fnode-disc { r: 24; }
.emap-fnode:hover .emap-fnode-name, .emap-fnode.is-selected .emap-fnode-name { fill: #fff; font-weight: 700; }
.emap-fnode:focus-visible .emap-fnode-disc { stroke: #00A896; stroke-width: 3; }
.emap-fnode.is-selected .emap-fnode-sel { opacity: 1; }
.emap-fnode.is-dim { opacity: .24; }
.emap-fan-root { cursor: pointer; outline: none; }
.emap-fan-ring { fill: #0b0d13; stroke-width: 2; }
.emap-fan-name { font-family: 'Inter Tight', 'Inter', sans-serif; font-weight: 700; font-size: 17px; letter-spacing: .26em; fill: #e8eaf0; }
.emap-fan-sub { font-family: 'Inter', sans-serif; font-size: 13px; letter-spacing: .06em; fill: #6b7482; }

/* search (dims the dot/disc, not the animated wrapper) */
.emap.is-searching .emap-leaf.is-miss .emap-leaf-dot,
.emap.is-searching .emap-leaf.is-miss .emap-leaf-ring,
.emap.is-searching .emap-fnode.is-miss .emap-fnode-disc,
.emap.is-searching .emap-fnode.is-miss .emap-fnode-core,
.emap.is-searching .emap-fnode.is-miss .emap-fnode-name { opacity: .16; }
.emap.is-searching .emap-leaf.is-hit .emap-leaf-dot { fill: #34d399; r: 14; }
.emap.is-searching .emap-leaf.is-hit .emap-leaf-hit { fill: rgba(52, 211, 153, .12); }
.emap.is-searching .emap-fnode.is-hit .emap-fnode-disc { fill: #34d399; }
.emap.is-searching .emap-fnode.is-hit .emap-fnode-halo { opacity: 1; }

/* chrome: top bar */
.emap-top {
    position: absolute; top: 12px; left: 12px; right: 12px;
    display: flex; align-items: center; gap: 10px;
    pointer-events: none;
}
.emap-top > * { pointer-events: auto; }
.emap-iconbtn, .emap-expand {
    display: inline-flex; align-items: center; gap: 7px;
    height: 34px; padding: 0 12px;
    border-radius: 9px;
    background: rgba(255, 255, 255, .07);
    border: 1px solid rgba(255, 255, 255, .09);
    color: #e8e4d6;
    font: inherit; font-size: .76rem; font-weight: 600;
    cursor: pointer;
    transition: background .15s;
}
.emap-iconbtn:hover, .emap-expand:hover { background: rgba(255, 255, 255, .14); }
.emap-iconbtn:focus-visible, .emap-expand:focus-visible, .emap-panel button:focus-visible { outline: 2px solid #34d399; outline-offset: 2px; }
.emap-expand svg { width: 15px; height: 15px; }
.emap-search {
    position: relative; flex: 1; max-width: 260px;
}
.emap-search svg { position: absolute; left: 11px; top: 50%; width: 14px; height: 14px; transform: translateY(-50%); opacity: .55; }
.emap-search input {
    width: 100%; height: 34px; padding: 0 56px 0 33px;
    border-radius: 9px;
    background: rgba(255, 255, 255, .07);
    border: 1px solid rgba(255, 255, 255, .09);
    color: #f2eedf; font: inherit; font-size: .8rem;
}
.emap-search input::-webkit-search-cancel-button { display: none; }
.emap-search input::placeholder { color: #8a92a5; }
.emap-search input:focus { outline: 2px solid #34d399; outline-offset: 1px; }
.emap-count { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font-size: .68rem; color: #34d399; pointer-events: none; }
.emap-spacer { flex: 1; }
.emap-book {
    display: inline-flex; align-items: center; height: 34px; padding: 0 14px;
    border-radius: 9px; background: #f2eedf; color: #1f2430;
    font-size: .78rem; font-weight: 700; text-decoration: none;
    transition: background .15s;
}
.emap-book:hover { background: #fff; }

/* zoom controls */
.emap-zoom {
    position: absolute; right: 12px; bottom: 12px;
    display: flex; align-items: center; gap: 2px;
    padding: 3px;
    border-radius: 10px;
    background: rgba(255, 255, 255, .07);
    border: 1px solid rgba(255, 255, 255, .09);
}
.emap-zoom button {
    min-width: 30px; height: 28px; padding: 0 8px;
    border: 0; border-radius: 7px; background: transparent;
    color: #e8e4d6; font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer;
}
.emap-zoom button:hover { background: rgba(255, 255, 255, .12); }
.emap-zoom button:focus-visible { outline: 2px solid #34d399; outline-offset: 1px; }
.emap-zoomval { min-width: 42px; text-align: center; font-size: .7rem; color: #9aa2b4; }
.emap-rot {
    position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%);
    display: flex; gap: 10px; transition: opacity .25s;
}
.emap.is-fan .emap-rot, .emap.is-diving .emap-rot { opacity: 0; pointer-events: none; }
.emap-rot button {
    width: 34px; height: 34px; border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .06);
    color: #e8e4d6; cursor: pointer; display: grid; place-items: center;
    transition: background .15s, transform .15s;
}
.emap-rot button:hover { background: rgba(255, 255, 255, .15); transform: scale(1.08); }
.emap-rot button:focus-visible { outline: 2px solid #34d399; outline-offset: 2px; }
.emap-rot svg { width: 15px; height: 15px; }
.emap-hint .on-full { display: none; }
.emap.is-full .emap-hint .on-full { display: inline; }
.emap.is-full .emap-hint .on-inline { display: none; }
.emap-hint {
    position: absolute; left: 14px; bottom: 16px;
    max-width: calc(100% - 220px);
    font-size: .7rem; line-height: 1.45; color: #7f8799; pointer-events: none;
}

/* tooltip */
.emap-tip {
    position: absolute; z-index: 5;
    transform: translate(-50%, -100%);
    padding: 5px 10px; border-radius: 7px;
    background: #f2eedf; color: #1f2430;
    font-size: .74rem; font-weight: 600; white-space: nowrap;
    pointer-events: none; opacity: 0; transition: opacity .12s;
}
.emap-tip.is-on { opacity: 1; }

/* detail sidebar (docked on the left, below the top bar) */
.emap-panel {
    position: absolute; z-index: 4;
    top: 58px; left: 12px; bottom: 12px;
    width: 300px;
    padding: 20px 16px 16px;
    overflow-y: auto;
    border-radius: 14px;
    background: rgba(18, 21, 30, .94);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, .09);
    box-shadow: 0 24px 50px -24px rgba(0, 0, 0, .7);
    opacity: 0; transform: translateX(-16px); pointer-events: none;
    transition: opacity .25s, transform .3s cubic-bezier(.2, .7, .2, 1);
    scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .18) transparent;
}
.emap-panel.is-open { opacity: 1; transform: none; pointer-events: auto; }
.emap-panel.is-swap.is-open .emap-body { animation: emap-panelin .35s cubic-bezier(.2, .7, .2, 1); }
@keyframes emap-panelin { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.emap.has-sidebar .emap-hint { display: none; }
.emap-panel-x {
    position: absolute; top: 8px; right: 10px;
    width: 28px; height: 28px; border: 0; border-radius: 7px;
    background: transparent; color: #9aa2b4; font-size: 1.3rem; line-height: 1; cursor: pointer;
}
.emap-panel-x:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.emap-pill {
    display: inline-block; padding: 3px 9px; border-radius: 999px;
    border: 1px solid var(--c); color: var(--c);
    font-size: .62rem; font-weight: 700; letter-spacing: .08em;
}
.emap-panel h4 {
    margin: 12px 0 8px;
    font-family: 'Inter Tight', 'Inter', sans-serif;
    font-weight: 600; font-size: 1.15rem; letter-spacing: -.02em; line-height: 1.2;
    color: #fff; padding-right: 22px;
}
.emap-panel p { margin: 0; font-size: .84rem; line-height: 1.55; color: #b4bbcb; }
.emap-beta, .emap-meta {
    display: block; margin-top: 12px;
    font-size: .68rem; font-weight: 600; letter-spacing: .06em; color: #fbbf24;
}
.emap-meta { color: #8a92a5; }
.emap-back {
    margin-top: 16px; padding: 7px 12px;
    border-radius: 8px; border: 1px solid rgba(255, 255, 255, .14);
    background: transparent; color: #e8e4d6;
    font: inherit; font-size: .76rem; font-weight: 600; cursor: pointer;
}
.emap-back:hover { background: rgba(255, 255, 255, .1); }

/* capability list inside the sidebar */
.emap-nav { margin-top: 18px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .08); }
.emap-nav h5 {
    margin: 12px 0 5px;
    font-size: .62rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #7f8799;
}
.emap-nav h5:first-child { margin-top: 0; }
.emap-nav button {
    display: flex; align-items: center; gap: 8px; width: 100%;
    padding: 6px 8px; margin: 0;
    border: 0; border-radius: 7px; background: transparent;
    color: #c3c9d6; font: inherit; font-size: .8rem; text-align: left; cursor: pointer;
    transition: background .15s, color .15s;
}
.emap-nav button::before {
    content: ""; flex-shrink: 0; width: 6px; height: 6px; border-radius: 50%;
    background: var(--c, #f2eedf); opacity: .55;
}
.emap-nav button.is-beta::before { background: transparent; border: 1.3px dashed var(--c); opacity: 1; }
.emap-nav button:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.emap-nav button.is-current { background: rgba(255, 255, 255, .12); color: #fff; font-weight: 600; }
.emap-nav button.is-current::before { opacity: 1; }
.emap-nav button:focus-visible { outline: 2px solid #34d399; outline-offset: -2px; }

@media (max-width: 760px) {
    .emp-section { padding: 3.25rem 1rem 3.5rem; }
    .emap { height: 540px; }
    .emap-search { max-width: none; }
    .emap-book, .emap-hint { display: none; }
    .emap-panel {
        top: auto; right: 10px; left: 10px; bottom: 54px;
        width: auto; max-height: 46%; transform: translateY(14px);
    }
    .emap-nav { display: none; }
    .emap-expand span { display: none; }
    .emap-expand { padding: 0 10px; }
}
@media (prefers-reduced-motion: reduce) {
    .emap .emap-draw, .emap .emap-pop, .emap .emap-fade, .emap-star, .emap-spark, .emap-drift, .emap-panel.is-swap.is-open {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
        stroke-dashoffset: 0 !important;
    }
    .emap-star { opacity: var(--o, .3) !important; }
    .emap-panel, .emap-leaf-dot, .emap-hub-ring { transition: none; }
}
