.am-lab01 {
    background: #f2f4f7;
    padding: 28px;
    border-radius: 18px;
    margin: 24px 0;
}

.am-lab01-shell {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 18px;
    padding: 24px;
    box-shadow: 0 8px 26px rgba(15, 23, 42, 0.08);
}

.am-lab01-header {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: start;
    margin-bottom: 20px;
}

.am-lab01-header h2 {
    margin: 0 0 10px;
    font-size: 30px;
    line-height: 1.15;
}

.am-lab01-intro,
.am-lab01-note,
.am-lab01-mode-description {
    color: #334155;
}

.am-lab01-mode-wrap {
    min-width: 260px;
}

.am-lab01-mode-wrap label,
.am-lab01-controls label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #0f172a;
}

.am-lab01-layout {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.am-lab01-main {
    display: grid;
    gap: 18px;
}

.am-lab01-controls,
.am-lab01-canvas-wrap,
.am-lab01-system-state,
.am-lab01-legend {
    background: #f8fafc;
    border: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 14px;
    padding: 18px;
}

.am-lab01-controls h3,
.am-lab01-legend h3,
.am-lab01-system-state h3 {
    margin: 0 0 12px;
    font-size: 18px;
}

.am-lab01-control-row {
    margin-bottom: 16px;
}

.am-lab01-control-row input[type="range"] {
    width: 100%;
}

.am-lab01-mode-wrap select {
    width: 320px;
    max-width: 100%;
}

.am-lab01-strength-readout {
    margin: 2px 0 8px;
    font-size: 13px;
    color: #475569;
}

.am-lab01-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin: 20px 0 0;
}

.am-lab01-buttons .am-btn {
    appearance: none;
    border: 1px solid rgba(15, 23, 42, 0.2);
    color: #ffffff;
    border-radius: 10px;
    padding: 10px 14px;
    font-weight: 600;
    cursor: pointer;
}

.am-lab01-buttons .am-btn-start,
.am-lab01-buttons .am-btn-pause,
.am-lab01-buttons .am-btn-reset {
    background: #006f76;
}

.am-lab01-buttons .am-btn:hover {
    filter: brightness(0.94);
}

.am-lab01-lower {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.am-lab01-stat {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(15, 23, 42, 0.07);
}

.am-lab01-stat span {
    color: #334155;
}

.am-lab01-stat strong {
    color: #0f172a;
}

.am-lab01-legend div {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
    color: #334155;
}

.am-lab01-legend .shape {
    width: 16px;
    height: 16px;
    display: inline-block;
    position: relative;
}

.am-lab01-legend .circle { border-radius: 999px; background: #006f76; }
.am-lab01-legend .square { background: #00868a; }
.am-lab01-legend .diamond { background: #939597; transform: rotate(45deg); }
.am-lab01-legend .triangle {
    width: 0;
    height: 0;
    background: transparent;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 16px solid #c06b00;
}
.am-lab01-legend .pentagon { background: #5b5fa9; clip-path: polygon(50% 0%, 100% 38%, 81% 100%, 19% 100%, 0% 38%); }

.am-lab01-mode-description {
    font-size: 14px;
    margin-bottom: 14px;
}

.am-lab01 canvas {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid rgba(15, 23, 42, 0.08);
}

@media (max-width: 1100px) {
    .am-lab01-layout,
    .am-lab01-lower {
        grid-template-columns: 1fr;
    }

    .am-lab01-mode-wrap {
        flex-direction: column;
        align-items: flex-start;
    }

    .am-lab01-mode-wrap select {
        width: 100%;
    }
}

/* subtle barrier pulse */
.am-lab01-flash{
    box-shadow:0 0 12px rgba(0,111,118,0.45);
    transition:box-shadow 0.25s ease;
}
/* organisation hit flash */
.am-lab01-org-flash{
    box-shadow:0 0 16px rgba(220,38,38,0.55);
}

.am-lab01-mode-title{font-size:20px;font-weight:700;color:#006f76;margin-bottom:6px;}
