/* Copyright 2020 VMware, Inc. */
/* SPDX-License-Identifier: Apache-2.0 */

/* Variables */
:root {
  --base-color: #1D428A;  /* "Indigo" */
}

/* Reset */
html, body, ol, ul, li { margin: 0; padding: 0; }
p {
  margin: 0 0 15px;
  padding: 0;
}

/* Font */
@font-face {
  font-family: 'Metropolis';
  src: url(data:font/ttf;base64,[encoded data, 55052 characters]);
}

/* Body */
body {
  font-family: Metropolis,Helvetica,Arial,sans-serif;
  font-size: 14px;
  font-weight: lighter;
  background: #fdfdfd;
  line-height: 1.5;
}

/* Links */
a, a:visited, a:hover {
  color: #0091DA  ;
  text-decoration: underline;
}

/* Content */
.content {
  margin: 0 auto;
  padding: 0 50px;
  width: 930px;
  background: #fdfdfd;
}

/* Use to hide required elements that are not ready */
.hidden {
 display: none !important;
}

/* Terminal */
.terminal {
  font-family: Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace;
  background: #000;
  color: #eee;
  padding: 7px 9px 7px 15px;
  overflow-x: auto;
  font-size: 100%;
}
.terminal .green { color: #AFCE5E; }
.terminal .red { color: #ef4f4f; }
.terminal .gray { color: #717074; }
.terminal .spacer-before {
  margin-top: 8px;
  display: inline-block;
}

/* Code */
li code,
p code {
  background: #f1f1f1;
  border-radius: 4px;
  border: 1px solid #eee;
  padding: 2px 4px;
  font-size: 80%;
}
code, .terminal, .logo {
  font-family: Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace;
}

li code, p code {
  font-size: 90%;
}

/* --- ytt specifics --- */

/* Variables */
:root {
  --base-color: #0091DA;  /* "Ocean" */
}

/* Fields */
input {
  font-family: sans-serif;
  font-size: 14px;
  border-radius: 3px;
  border: 1px solid #AAA;
  padding: 4px;
}
input[disabled] {
  background: #f7f7f7;
  border-color: #f7f7f7;
  color: #666;
}


/* Buttons */
.button:hover { text-decoration: underline; }
.button {
  border: none;
  border-radius: 3px;
  color: var(--base-color);
  padding: 5px 10px;
  margin: 0;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 13px;
  cursor: pointer;
}
.example-set-button:before {
  content: "▶ "
}
.example-set-button.expanded:before {
  content: "▼ "
}

/* Examples dropdown */
.dropdown {}
.button-container button {
  margin: 0 10px 0 0;
}
.example-set {
  display: none;
}
.example-set.expanded {display: block;}
.example-set-name {
  margin-bottom: 0px;
}
.example-set-description {
  font-style: italic;
  font-size: 10px;
  margin-top: 0px;
}
.dropdown-content {
  columns: 4;
  -webkit-columns: 4;
  -moz-columns: 4;
  margin: 0 0 40px 40px;
}

/* Playground */
#playground .playground-inner { position: relative; }
#playground .playground-inner .blocker {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #fff;
  opacity: 0.8;
  z-index: 10000;
}
.playground-expanded {
  background: #fff;
  position: relative;
}
.playground-expanded #playground {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  min-width: 1000px; /* Take up at least as much as .content */
  background: #fff;
}

#playground .playground-inner {
  display: flex;
  font-size: 12px;
  /* Avoids content jumping around when changing examples */
  /*min-height: 1000px; */
}
#playground .playground-inner .left,
#playground .playground-inner .right {
  flex: 1;
  max-width: 50%;
}
#playground .playground-inner .left {
  padding-right: 20px;
  box-sizing: border-box;
}

/* Playground controls */
#playground .playground-inner .left { position: relative; }
#playground .controls {
  position: absolute;
  right: 20px;
  top: 0;
}

/* Eidtor configs */
.CodeMirror,
.CodeMirror-scroll {
  height: auto;
  overflow: hidden !important;
}
.CodeMirror-hscrollbar {
  /* without following hor scrollbar isnt draggable */
  pointer-events: auto !important;
  outline: none;
}

#playground .config-boxes .CodeMirror { background: #fffff4; }

/* Editor results */
#playground .output h3 { margin: 2px 0; }
#playground .output .CodeMirror { background: #f7f7f7; }
#playground .output .CodeMirror-cursors { display: none; } /* results are readonly */
.output-errors {
  color: red;
}
.output-errors {
  white-space: pre-wrap;
  font-family: monospace;
}

/* Loading indicator */
.loading {
  position: fixed;
  z-index: 10000;
  bottom: 0;
  right: 0;
  background: #efefef;
  font-size: 80%;
  padding: 2px 4px;
  border-radius: 4px;
}

.playground-wrapper {
  margin: 0px -50px;
  padding: 12px 36px 36px;
  background: inherit;
  clear: both;
}
