/**
 * @fileoverview Styles für den Playground KI Arena.
 * Entry-Point bleibt ../html/playground/arena.html.
 *
 * Ergänzt die globalen Basis-Styles aus css/style.css
 * um arena-spezifische Layout- und Tuner-Regeln.
 */

.lab-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toolbar-left,
.toolbar-center,
.toolbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toolbar-center {
    margin: 0 auto;
}

.toolbar-right {
    margin-left: auto;
}

.col-game {
    flex: 0 0 280px;
    min-width: 280px;
    width: 280px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.lab-grid {
    overflow: hidden;
}

.col-tree {
    min-height: 0;
    overflow: hidden;
}

.tree-container {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 8px;
}

.canvas-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    padding: 5px 0;
}

canvas {
    max-width: 100%;
    height: auto;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.stats-box {
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 12px;
    font-size: 0.9em;
    line-height: 1.6;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    border-bottom: 1px solid #eee;
}

.stat-row:last-child {
    border-bottom: none;
}

.stat-label {
    font-weight: 500;
    color: #555;
}

.stat-value {
    font-weight: bold;
    color: #2c3e50;
}

.stat-value.blue {
    color: #3498db;
}

.stat-value.red {
    color: #e74c3c;
}

.stat-value.draw {
    color: #95a5a6;
}

.random-mascot {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 10px;
    margin: 10px;
    border: 2px dashed #d0d0d0;
    border-radius: 10px;
    background: #fafafa;
    color: #666;
    text-align: center;
    gap: 8px;
}

.random-emoji {
    font-size: 40px;
}

.random-text {
    font-size: 0.95em;
    font-weight: 600;
}

.minimax-panel {
    background: #fdfdfd;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin: 10px;
}

.desc-box {
    margin-top: 10px;
    padding: 10px;
    background: #eee;
    border-radius: 4px;
    font-size: 0.85em;
    color: #555;
    font-style: italic;
}

.desc-details {
    margin-top: 10px;
}

.desc-summary {
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9em;
    color: #2c3e50;
    user-select: none;
}

.formula-box {
    margin-top: 5px;
    font-family: monospace;
    background: #fff;
    padding: 4px;
    border: 1px solid #ccc;
    font-size: 0.8em;
}

.warn-msg {
    color: #d35400;
    font-weight: bold;
    font-size: 0.85em;
    margin-top: 5px;
}

.tuner-details {
    margin-top: 10px;
    border-top: 1px solid #ececec;
    padding-top: 8px;
}

.tuner-summary {
    cursor: pointer;
    font-size: 0.9em;
    color: #2c3e50;
    font-weight: 600;
    user-select: none;
    outline: none;
}

.tuner-grid {
    margin-top: 8px;
    display: grid;
    gap: 8px;
}

.tuner-toolbar {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
}

.tuner-row {
    background: #fafafa;
    border: 1px solid #ececec;
    border-radius: 6px;
    padding: 8px;
}

.tuner-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 6px;
}

.tuner-key {
    font-family: monospace;
    font-size: 0.85em;
    color: #34495e;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tuner-info {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #dfe6e9;
    color: #2c3e50;
    font-size: 0.72em;
    font-weight: 700;
    cursor: help;
    border: 1px solid #c8d0d4;
    position: relative;
    user-select: none;
}

.tuner-info::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    transform: translateX(-50%);
    background: #2c3e50;
    color: #fff;
    font-size: 0.75em;
    line-height: 1.35;
    padding: 8px 10px;
    border-radius: 6px;
    width: min(280px, 70vw);
    text-align: left;
    opacity: 0;
    pointer-events: none;
    z-index: 50;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
    transition: opacity 0.15s ease;
    white-space: normal;
}

.tuner-info::before {
    content: '';
    position: absolute;
    left: 50%;
    bottom: calc(100% + 2px);
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid #2c3e50;
    opacity: 0;
    transition: opacity 0.15s ease;
    pointer-events: none;
    z-index: 50;
}

.tuner-info:hover::after,
.tuner-info:hover::before,
.tuner-info:focus-visible::after,
.tuner-info:focus-visible::before {
    opacity: 1;
}

.tuner-value {
    font-weight: 700;
    font-size: 0.85em;
    color: #2980b9;
}

.tuner-explain {
    font-size: 0.78em;
    color: #666;
    margin-top: 4px;
    line-height: 1.35;
}

/* =========================================
   FLOWCHART NODES → see css/flowchart.css
   (Formerly duplicated here; now centralized)
   ========================================= */
