@import url("https://fonts.googleapis.com/css?family=IBM+Plex+Mono:400");
@import url("https://fonts.googleapis.com/css?family=IBM+Plex+Sans:400");

:root {
  --base-spacing: 4px;
  --base: #fff;
  --overlay: #f8f9fa;
  --surface: #f1f3f5;
  --text: #030405;
  --subtle: #07090a;
  --warn: #e5c07b;
  --success: #98c379;
  --toolbar-height: 42px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --base: #232b32;
    --overlay: #20272d;
    --surface: #1c2228;
    --text: white;
    --subtle: #e9eaeb;
  }
}

* {
  box-sizing: border-box;
}

body {
  font-family: "IBM Plex Sans", sans-serif;
  background: var(--base);
  color: var(--text);
}

a {
  color: #1085ff;
}

.code-editor {
  font-family: "IBM Plex Mono", monospace;
  line-height: 2;
}

.preview-dot {
  height: 10px;
  width: 10px;
  border-radius: 25px;
  background: var(--warn);
}

.preview-dot.on {
  background: var(--success);
}

.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.flex-1 {
  flex: 1;
}

.justify-between {
  justify-content: space-between;
}

.align-center {
  align-items: center;
}

.p-5 {
  padding: calc(var(--base-spacing) * 5);
}

.mt-1 {
  margin-top: calc(var(--base-spacing) * 1);
}

.mb-2 {
  margin-bottom: calc(var(--base-spacing) * 2);
}

.mr-2 {
  margin-right: calc(var(--base-spacing) * 2);
}

.w-full {
  width: 100%;
}

.min-w-screen {
  min-width: 100vw;
}

.min-h-screen {
  min-height: 100vh;
}

.toolbar {
  color: var(--subtle);
  height: var(--toolbar-height);
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  padding-right: 10px;
  display: inline-flex;
  position: fixed;
  bottom: 20px;
  left: 50%;
  min-width: 350px;
  border-radius: 50px;
  transform: translateX(-50%);
  background: var(--overlay);
  box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.12);
}

.trigger {
  min-width: 50px;
  max-width: 150px;
  border-radius: 0px !important;
  height: var(--toolbar-height);
  padding-left: 16px !important;
  padding-right: 16px !important;
}

.trigger.active {
  color: var(--success);
}

.relative {
  position: relative;
}

.absolute {
  position: absolute;
}

.ql-container {
  font-size: 14px;
  background-color: var(--base);
  color: var(--text);
}

.ql-toolbar {
  background-color: var(--surface);
  border-radius: 10px;
  box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.12);
  border: 1px solid var(--overlay);
}

.ql-bubble .ql-editor code {
  background: var(--surface);
  color: var(--text);
}

.ql-bubble .ql-editor .ql-code-block-container {
  background: var(--overlay);
  color: var(--text);
}

.ql-code-block-container .ql-ui {
  background: var(--surface);
  padding: 4px 8px;
  color: var(--text);
  border: 0px;
  border-radius: 4px;
}
