.playground-main { padding-top: 54px; padding-bottom: 40px; }
.playground-intro { max-width: 780px; margin-bottom: 36px; }
.playground-intro h1 { margin-bottom: 20px; }
.playground-intro > p:last-child { color: var(--muted); max-width: 700px; font-size: 18px; }
.problem-picker { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); border: 1px solid var(--line); margin-bottom: 34px; }
.problem-picker button { text-align: left; border: 0; border-right: 1px solid var(--line); padding: 20px 24px; background: transparent; color: var(--ink); }
.problem-picker button:last-child { border-right: 0; }
.problem-picker button[aria-pressed="true"] { background: var(--ink); color: white; }
.problem-picker button:hover:not([aria-pressed="true"]) { background: var(--surface); }
.problem-index { display: block; font-size: 12px; letter-spacing: .12em; opacity: .75; margin-bottom: 5px; }
.problem-picker small { display: block; font-size: 12px; opacity: .8; margin-top: 3px; }
.lab-layout { display: grid; grid-template-columns: 255px minmax(0,1fr); border: 1px solid var(--line); }
.lab-controls { padding: 26px; border-right: 1px solid var(--line); background: var(--surface); }
.lab-controls h2 { font-size: 26px; margin-bottom: 24px; }
.lab-controls .eyebrow, .canvas-heading .eyebrow { margin-bottom: 8px; }
.lab-controls label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.lab-controls input,.lab-controls select { width: 100%; min-height: 42px; border: 1px solid #a7bcb3; border-radius: 0; background: var(--paper); color: var(--ink); font: inherit; padding: 6px 10px; margin-bottom: 16px; }
.lab-controls input:focus-visible,.lab-controls select:focus-visible { outline: 3px solid #ac7841; outline-offset: 2px; }
.seed-control { display: flex; gap: 6px; }
.seed-control input { min-width: 0; margin-bottom: 0; }
.seed-control button { background: transparent; border: 1px solid #a7bcb3; color: var(--accent); font-size: 12px; padding: 4px 8px; }
.field-help { font-size: 12px; color: var(--muted); line-height: 1.5; margin: 8px 0 20px; }
.lab-button { display: block; width: 100%; padding: 11px 12px; font-size: 14px; border: 1px solid var(--accent); margin: 10px 0 0; }
.lab-button.primary { background: var(--accent); color: white; }
.lab-button.secondary { background: transparent; color: var(--accent); }
.lab-button:hover { filter: brightness(.92); }
.lab-button:disabled { opacity: .5; cursor: not-allowed; }
#lab-status { font-size: 12px; line-height: 1.6; margin: 16px 0; }
.download-button { font-size: 12px; padding: 0 0 3px; color: var(--accent); border: 0; border-bottom: 1px solid #a7bcb3; background: transparent; text-align: left; }
.download-button:disabled { opacity: .5; cursor: not-allowed; }
.lab-output { min-width: 0; padding: 26px; }
.canvas-heading { display: flex; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.canvas-heading h2 { font-size: 26px; margin: 0; }
.state-badge { background: var(--surface); color: var(--accent); padding: 3px 9px; font-size: 11px; white-space: nowrap; }
.state-badge.warning { background: #faecd5; color: #704513; }
.visualization { border: 1px solid var(--line); background-color: #fff; background-image: radial-gradient(#dce6df .8px,transparent .8px); background-size: 16px 16px; }
.visualization svg { display: block; width: 100%; height: auto; }
.graph-scroll { overflow-x: auto; }
.graph-scroll svg { min-width: 560px; }
.graph-scroll:focus-visible { outline: 3px solid #ac7841; outline-offset: 3px; }
.graph-edge { stroke: #bccbc4; stroke-width: 1.5; }
.tour-baseline { fill: none; stroke: #879b94; stroke-width: 1.5; stroke-dasharray: 6 5; }
.solution-line { fill: none; stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.node { fill: white; stroke: var(--accent); stroke-width: 2; }
.node.endpoint { fill: var(--accent); }
.node-label { fill: var(--ink); font: 12px system-ui,sans-serif; text-anchor: middle; dominant-baseline: central; }
.node-label.endpoint { fill: white; }
.edge-label { font: 11px system-ui,sans-serif; fill: #445b54; stroke: white; stroke-width: 4px; paint-order: stroke; text-anchor: middle; }
.lab-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 11px; color: var(--muted); margin: 12px 0 22px; }
.legend-item { display: inline-flex; align-items: center; gap: 6px; }
.legend-key { width: 18px; height: 3px; background: var(--accent); }
.legend-key.baseline { height: 0; background: none; border-top: 2px dashed #879b94; }
.legend-key.day { height: 13px; background: #dbece0; border: 1px solid #789983; }
.legend-key.night { height: 13px; background: #334b62; }
.legend-key.off { height: 13px; background: white; border: 1px solid var(--line); }
.legend-key.unavailable { height: 13px; background: #ede9e2; border: 1px solid #b5a999; }
.lab-metrics { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); border-top: 1px solid var(--line); padding-top: 18px; gap: 12px; }
.metric-value { font: 29px/1.3 Georgia,serif; display: block; }
.metric-label { font-size: 11px; color: var(--muted); display: block; margin-top: 5px; }
.result-detail { font-size: 13px; line-height: 1.6; color: var(--muted); margin: 16px 0 0; overflow-wrap: anywhere; }
.method-section { display: grid; grid-template-columns: 1fr 1.8fr; gap: 48px; margin: 44px 0 10px; padding-top: 30px; border-top: 1px solid var(--line); }
.method-section h2 { font-size: 28px; }
.method-section p,.method-section ul { font-size: 14px; color: var(--muted); }
.method-caveat { border-left: 2px solid #ac7841; padding-left: 16px; }
.schedule-scroll { overflow-x: auto; max-height: 470px; overflow-y: auto; background: white; }
.schedule-scroll:focus-visible { outline: 3px solid #ac7841; outline-offset: 3px; }
.schedule-table { border-collapse: collapse; width: 100%; font-size: 11px; text-align: center; white-space: nowrap; }
.schedule-table caption { text-align: left; padding: 12px; color: var(--muted); white-space: normal; }
.schedule-table th,.schedule-table td { padding: 8px 6px; border: 1px solid var(--line); min-width: 32px; }
.schedule-table th { font-weight: 500; background: var(--paper); }
.schedule-table th:first-child { position: sticky; left: 0; z-index: 1; }
.schedule-table td.day { background: #dbece0; color: #214a32; }
.schedule-table td.night { background: #334b62; color: white; }
.schedule-table td.unavailable { background: #ede9e2; color: #64594d; }
.schedule-table td.shortage { color: #704513; background: #faecd5; font-weight: 700; }
@media(min-width:1081px) { .playground-page .nav { gap: 18px; } .playground-page .nav nav { gap: 13px; } }
@media(max-width:850px) { .lab-layout { grid-template-columns: 220px minmax(0,1fr); } .lab-controls,.lab-output { padding: 20px; } .canvas-heading { align-items: flex-start; flex-direction: column; } }
@media(max-width:650px) {
    .playground-main { padding-top: 34px; }
    .playground-intro > p:last-child { font-size: 16px; }
    .problem-picker button { padding: 12px 9px; font-size: 12px; }
    .problem-picker small { display: none; }
    .lab-layout { grid-template-columns: 1fr; }
    .lab-controls { border-right: 0; border-bottom: 1px solid var(--line); }
    .lab-output { padding: 18px 12px; }
    .lab-metrics { gap: 8px; }
    .metric-value { font-size: 24px; }
    .method-section { grid-template-columns: 1fr; gap: 0; }
}
