code-playground {
  margin-bottom: 2em;
}

/** In case the playground component is not loaded, fall back to displaying the
source */
code-playground div {
  white-space: pre-wrap;
  font-family: var(--monospace-font-family);
  background: var(--console-background);
  color: var(--console-color);
  border-radius: 8px;
  padding: 8px;
  margin-bottom: .5em;
  font-size: .9em;
  border: 1px solid var(--content-border-color);
}


code-playground::part(label) {
    font-weight: 700;
    padding-top: 4px;
    padding-bottom: 4px;
    display: block;
    border-radius: 4px 4px 0 0;
    padding-left: 4px;
}

code-playground::part(button-bar) {
    margin-bottom: 8px;
    margin-top: 8px;
    display: flex;
    gap: 1em;
    align-items: center;
    justify-content: center;
    background:  var(--glass-background);
    backdrop-filter: var(--glass-backdrop-filter);
    translate: 0 -33%;
    width: fit-content;
    min-width: 10%;
    align-self: center;
    padding: 8px;
    border-radius: 10vh;
    border-top: 1px solid var(--neutral-900);
    border-bottom: 1px solid var(--neutral-700);
    box-shadow: var(--glass-box-shadow);
}

code-playground::part(button) {
  min-height: 2em;
  padding-left: 1em;
  padding-right: 1.25em;
  border-radius: 100px;
  font-size: 1rem;
  font-weight: 700;
  background: var(--neutral-900);
  color: var(--neutral-400);
  border: 1px solid var(--neutral-700);
  box-shadow: 0 0 3px 0 rgba(0,0,0,.1);
}

code-playground::part(button):hover {
  color: var(--primary-color-dark);
  border-color: var(--primary-color);
  background: var(--primary-color-light);
}

code-playground::part(button):active {
  color: #fff;
  background: var(--primary-color);
  border-color: var(--primary-color);
}



code-playground::part(output) {
  display: flex;
  flex-direction: column;
}



code-playground::part(editor):hover {
  border-color: #fff;
}

code-playground::part(editor):focus-within {
  border-color: #fff;
  outline: -webkit-focus-ring-color solid 2px;
}

code-playground::part(editor) {
  position: relative;
  padding: 0.5em;

  border: 3px solid transparent;
  --base-00: var(--console-background, var(--blue-900));
  background: var(--console-background);
  background-image: linear-gradient(90deg, rgba(0, 0, 0, 0.3) 0%, transparent 50%, rgba(0, 0, 0, 0.4) 100%);
  color: var(--console-color) !important;

  text-shadow: 0 0 5px #C8C8C870;
  box-shadow: inset 1px 1px 15px #000;
  border-radius: 8px;

  font-size: .9rem;
  line-height: 1.3;
}


code-playground::part(console) {
  position: relative;
  --base-00: var(--console-background, var(--blue-900));
  background: var(--console-background);
  background-image: linear-gradient(90deg, rgba(0, 0, 0, 0.3) 0%, transparent 50%, rgba(0, 0, 0, 0.4) 100%);

  color: var(--console-color);

  --selection-background: var(--semantic-blue, #0066ce);
  --selection-color: var(--semantic-orange);
}
