/* A/B Test Outcome Decision Matrix
   Layout: top toolbar + 2/3 diagram panel + 1/3 info panel
*/
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body {
    width: 100%; height: 100%; overflow: hidden;
    font-family: Arial, Helvetica, sans-serif;
    background: #fff;
}

/* Top toolbar with title and novelty-effect toggle */
.toolbar {
    height: 40px;
    padding: 8px 14px;
    background: #37474f;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
}
.toolbar-title { font-weight: 600; font-size: 15px; }
.toggle { display: flex; align-items: center; gap: 6px; cursor: pointer; user-select: none; }
.toggle input { cursor: pointer; }

/* Main container fills remainder */
.container {
    display: flex;
    width: 100%;
    height: calc(100% - 40px);
}

/* Left 2/3: Mermaid diagram */
.diagram-panel {
    width: 66.67%;
    height: 100%;
    background-color: aliceblue;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 10px;
    overflow: visible;
}
.mermaid { width: 100%; }
.mermaid svg { max-width: 100%; height: auto; }

/* Right 1/3: Info panel */
.info-panel {
    width: 33.33%;
    height: 100%;
    background-color: #f8f9fa;
    border-left: 1px solid #dee2e6;
    padding: 12px 14px;
    overflow: visible;
}

/* Legend at top of info panel */
.legend {
    margin-bottom: 12px;
    font-size: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 8px 10px;
    background: #fff;
}
.legend-title { font-weight: 600; margin-bottom: 4px; color: #334155; }
.legend-item { display: flex; align-items: center; gap: 6px; padding: 2px 0; color: #475569; }
.dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; }

.info-panel h3 {
    font-size: 16px;
    color: #333;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 2px solid #c1440e;
}

/* Y-following info card */
#panelWrap {
    position: relative;
    height: 480px;
}
#panel {
    position: absolute;
    left: 0; right: 0; top: 8px;
    background-color: #fff;
    color: #1f2937;
    border: 1px solid #e2e8f0;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 13px;
    line-height: 1.5;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.info-title {
    font-size: 14px;
    font-weight: 700;
    color: #c1440e;
    margin-bottom: 6px;
}
.info-meta {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 6px;
    font-style: italic;
}
.info-placeholder { color: #888; font-style: italic; font-size: 13px; }
.info-numbers {
    margin-top: 6px;
    padding: 6px 8px;
    background: #f1f5f9;
    border-radius: 4px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 12px;
    color: #334155;
}

/* Mermaid node hover */
.node { cursor: pointer; }
.node:hover rect,
.node:hover circle,
.node:hover polygon { filter: brightness(1.08); }
