/* Playground: full-width, no sidebar, side-by-side editor/output */

body.playground-page .sidebar,
body.playground-page .sidebar-overlay,
body.playground-page .menu-toggle {
  display: none !important;
}

body.playground-page .layout {
  display: block;
}

body.playground-page .content.playground-content {
  max-width: none;
  width: 100%;
  min-height: calc(100vh - var(--header-h));
  padding: 1.25rem 1.5rem 2rem;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}

.playground-header h1 {
  margin-bottom: 0.35rem;
}

.playground-header .lead {
  margin: 0;
}

.playground-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin: 1rem 0 1rem;
  flex-shrink: 0;
}

.playground-toolbar button {
  font: inherit;
  font-weight: 700;
  border: none;
  border-radius: 4px;
  padding: 0.55rem 1.1rem;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
}

.playground-toolbar button:hover:not(:disabled) {
  background: var(--accent-dark);
}

.playground-toolbar button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.playground-toolbar button.secondary {
  background: #5a6560;
}

.playground-toolbar button.secondary:hover:not(:disabled) {
  background: #3f4844;
}

.playground-status {
  font-size: 0.92rem;
  color: var(--muted);
  margin-left: 0.25rem;
}

.playground-status.is-ready {
  color: #2f6b3a;
  font-weight: 600;
}

.playground-status.is-error {
  color: #a33;
  font-weight: 600;
}

.playground-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  flex: 1;
  min-height: 0;
  align-items: stretch;
}

.playground-pane {
  display: flex;
  flex-direction: column;
  min-height: 0;
  min-width: 0;
}

.playground-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 0 0 0.35rem;
  flex-shrink: 0;
}

.playground-editor {
  width: 100%;
  flex: 1;
  min-height: 360px;
  box-sizing: border-box;
  border: 1px solid #2a3344;
  border-radius: 6px;
  overflow: hidden;
  background: #1e1e1e;
}

.playground-editor .monaco-editor,
.playground-editor .overflow-guard {
  border-radius: 6px;
}

.playground-output {
  width: 100%;
  flex: 1;
  min-height: 360px;
  overflow: auto;
  box-sizing: border-box;
  margin: 0;
  font-family: "SF Mono", "Fira Code", "Consolas", "Menlo", monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  color: #d4d4d4;
  background: #141820;
  border: 1px solid #2a3344;
  border-radius: 6px;
  padding: 1rem 1.1rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.playground-output.has-error {
  color: #f48771;
}

@media (max-width: 900px) {
  .playground-split {
    grid-template-columns: 1fr;
  }

  .playground-editor,
  .playground-output {
    min-height: 240px;
  }
}
