/* Python Blocks: convert.js. The multi-line Python block's editor, and the
   block a failed run came from (lit red until it changes or the next run). */

.pb-lines { display: flex; flex-direction: column; gap: 8px; }
.pb-lines-edit {
  width: 100%;
  min-height: 240px;
  max-height: 60vh;
  padding: 10px 12px;
  color: #e9e4f5;
  background: #14111d;
  border: 1px solid var(--border);
  border-radius: 0;
  font: 0.84rem/1.55 var(--mono);
  tab-size: 4;
  white-space: pre;
  overflow: auto;
  resize: vertical;
}
.pb-lines-edit:focus-visible { outline: none; box-shadow: var(--focus-ring); }
/* A mistake Done found in the lines: their line, in words. */
.pb-lines-err { margin: 0; color: #ff8b8b; font-size: 0.84rem; }
.pb-lines-err[hidden] { display: none; }

.pb-err-block > .blocklyPath, .pb-err-block.blocklySelected > .blocklyPath { stroke: #ff3b3b; stroke-width: 4px; }
.pb-err-block { filter: drop-shadow(0 0 6px rgba(255, 59, 59, 0.95)) drop-shadow(0 0 14px rgba(255, 59, 59, 0.6)); }
.pb-err-banner { position: absolute; right: 24px; top: 56px; z-index: 30; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; max-width: min(640px, calc(100% - 24px)); padding: 8px 8px 8px 14px; border-radius: 0; background: #3a1418; border: 1px solid #ff5a5a; color: #ffd9d9; font: 600 13px/1.35 Inter, system-ui, sans-serif; box-shadow: 3px 3px 0 var(--edge); }
/* Its buttons go under the words when the two will not fit side by side (a narrow phone). */
.pb-err-banner span { flex: 1 1 12em; min-width: 0; overflow-wrap: anywhere; user-select: text; -webkit-user-select: text; }
.pb-err-banner .pb-err-why { display: block; margin-top: 4px; font-weight: 400; }
.pb-err-banner button { flex: none; min-height: 36px; padding: 0 12px; border-radius: 0; border: 1px solid #ff8a8a; background: transparent; color: #ffd9d9; font: inherit; cursor: pointer; }
.pb-err-banner .pb-err-close { min-width: 36px; padding: 0; border-color: transparent; font-size: 18px; }

@media (max-width: 760px) {
  .pb-lines-edit { min-height: 180px; font-size: 16px; }
  /* Clear of the categories down the left. */
  .pb-err-banner { left: 86px; right: 10px; max-width: none; }
}
/* The error's bubble on its block (it opens from the ⚠), dark red rather than the block's colour, without Blockly's emboss lightening it. */
.blocklyTextBubble .blocklyEmboss { filter: none; }
.blocklyTextBubble path, .blocklyTextBubble rect { fill: #4a161b; stroke: #ff5a5a; stroke-width: 1.5px; fill-opacity: 1; }
.blocklyTextBubble text, .blocklyTextBubble .blocklyText { fill: #ffd9d9; }
/* A block collapse.js just changed (a drop that Python reads back as other blocks): a short glow. */
.pb-changed > .blocklyPath { stroke: #ffd84a; stroke-width: 3px; }
.pb-changed { filter: drop-shadow(0 0 6px rgba(255, 216, 74, 0.9)); transition: filter 0.6s; }
/* main.js: while a program runs, the block running now glows yellow and its stack softly; Stop leaves an outline on the block it stopped in. */
.pb-now > .blocklyPath, .pb-now.blocklySelected > .blocklyPath { stroke: #ffd84a; stroke-width: 3px; }
.pb-now { filter: drop-shadow(0 0 5px rgba(255, 216, 74, 0.95)) drop-shadow(0 0 12px rgba(255, 216, 74, 0.55)); }
.pb-now-stack { filter: drop-shadow(0 0 8px rgba(255, 216, 74, 0.35)); }
.pb-now-stopped > .blocklyPath { stroke: #ffd84a; stroke-width: 3px; stroke-dasharray: 6 4; }
