:root {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #20252b;
  background: #f0f2f4;
  font-synthesis: none;
  --blue: #3858e9;
  --line: #d9dde3;
  --muted: #606a77;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  border: 1px solid #c9ced6;
  background: white;
  border-radius: 5px;
  padding: 9px 13px;
  font-weight: 550;
  color: #26323e;
  white-space: nowrap;
}
button:hover {
  background: #eef1f8;
  border-color: #8b96a8;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
button.primary {
  background: var(--blue);
  border-color: var(--blue);
  color: white;
}
button.primary:hover {
  background: #2944c5;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid #8c9eff;
  outline-offset: 3px;
}
::selection {
  background: #dce3ff;
  color: #17265c;
}
input,
textarea {
  caret-color: var(--blue);
}
.app-header {
  height: 76px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 26px;
}
.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 18px;
  letter-spacing: -0.025em;
  font-weight: 650;
  color: #20252b;
  text-decoration: none;
}
.brand svg {
  color: var(--blue);
}
.app-purpose {
  font-size: 13px;
  color: var(--muted);
}
.header-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
}
.workspace {
  height: calc(100dvh - 76px);
  display: grid;
  grid-template-columns: 350px minmax(0, 1fr);
}
.editor-pane {
  display: flex;
  flex-direction: column;
  background: white;
  min-height: 0;
  border-right: 1px solid var(--line);
}
.pane-heading {
  padding: 21px 20px 16px;
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 8px;
}
.pane-heading h1 {
  margin: 0;
  font-size: 16px;
  font-weight: 650;
}
.pane-heading p {
  font-size: 12px;
  color: var(--muted);
  margin: 6px 0 0;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.state {
  font-size: 12px;
  border-radius: 4px;
  background: #f0f3f6;
  color: #576371;
  padding: 4px 6px;
  white-space: nowrap;
}
.editor-toolbar {
  display: flex;
  justify-content: space-between;
  padding: 10px 20px;
  color: var(--muted);
  font-size: 12px;
  border-block: 1px solid #e8ebef;
}
.editor-toolbar label {
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
#readme {
  border: 0;
  resize: none;
  width: 100%;
  min-height: 180px;
  flex: 1;
  padding: 19px 20px;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  line-height: 1.85;
  color: #39485b;
  tab-size: 2;
  scrollbar-color: #bec7d2 transparent;
}
#readme:focus {
  outline: 0;
  background: #fcfdff;
  box-shadow: inset 2px 0 var(--blue);
}
#readme::placeholder {
  color: #6c7685;
}
.checks {
  border-top: 1px solid var(--line);
  padding: 18px 20px;
  max-height: 245px;
  overflow: auto;
  scrollbar-width: thin;
}
.checks-heading {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.checks h2 {
  font-size: 13px;
  margin: 0;
}
.checks-heading span {
  font-size: 12px;
  color: var(--muted);
}
.check {
  font-size: 12px;
  line-height: 1.5;
  margin: 8px 0;
  display: flex;
  gap: 9px;
  align-items: start;
}
.check svg {
  flex-shrink: 0;
  margin-top: 1px;
}
.check.good {
  color: #226447;
}
.check.warn {
  color: #855818;
}
.check.info {
  color: #52617a;
}
.muted {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
}
.asset-panel {
  border-top: 1px solid var(--line);
  padding: 14px 20px;
  font-size: 12px;
  max-height: 180px;
  overflow: auto;
}
.asset-panel summary {
  cursor: pointer;
  font-weight: 600;
}
.asset-panel summary span {
  float: right;
  font-weight: 400;
  color: var(--muted);
}
.asset-panel p {
  line-height: 1.6;
  color: var(--muted);
}
.asset-panel ul {
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.asset-panel button {
  font-size: 12px;
  padding: 6px 10px;
}
.preview-pane {
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.preview-toolbar {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px 23px;
  min-height: 69px;
  flex-wrap: wrap;
}
.view-switch,
.size-switch {
  display: flex;
  gap: 2px;
  background: #e3e7ec;
  padding: 3px;
  border-radius: 6px;
}
.preview-toolbar button {
  background: transparent;
  border: 0;
  font-size: 12px;
  padding: 7px 10px;
}
.preview-toolbar button.selected {
  background: white;
  box-shadow: 0 1px 3px #1a2a3c15;
  color: #203cb7;
}
.size-switch {
  margin-left: auto;
}
#parse-status {
  font-size: 12px;
  color: var(--muted);
  min-width: 96px;
  text-align: right;
}
.preview-stage {
  flex: 1;
  min-height: 0;
  margin: 0 23px;
  display: flex;
  justify-content: center;
  position: relative;
  background: #e5e9ed;
  overflow: hidden;
  border: 1px solid #d1d7df;
  border-radius: 5px;
  box-shadow: 0 8px 24px #2736480a;
}
#preview {
  width: 100%;
  height: 100%;
  border: 0;
  background: white;
}
#preview.mobile {
  width: 390px;
  max-width: 100%;
}
.preview-footer {
  padding: 13px 23px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: #626d7c;
}
#empty-preview {
  position: absolute;
  inset: 0;
  background: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  text-align: center;
  color: #75839a;
}
#empty-preview h2 {
  color: #253044;
  font-size: 25px;
  letter-spacing: -0.025em;
  font-weight: 600;
  margin: 24px 0 0;
}
#empty-preview p {
  font-size: 14px;
  line-height: 1.8;
  margin: 12px 0 24px;
  color: var(--muted);
}
[hidden] {
  display: none !important;
}
dialog {
  border: 0;
  border-radius: 10px;
  padding: 30px;
  width: 500px;
  max-width: calc(100vw - 32px);
  box-shadow: 0 22px 80px #15213b3b;
  color: #26313e;
}
dialog::backdrop {
  background: #13203d66;
}
dialog h2 {
  font-size: 22px;
  letter-spacing: -0.025em;
  margin: 0 0 12px;
}
dialog p {
  font-size: 14px;
  line-height: 1.65;
  color: var(--muted);
}
.close-button {
  float: right;
  border: 0;
  padding: 0 0 6px 12px;
  margin-top: -10px;
  font-size: 25px;
  line-height: 1;
  background: transparent;
}
.open-options {
  display: flex;
  gap: 10px;
  margin: 22px 0;
}
.privacy {
  font-size: 12px !important;
  background: #f2f5fa;
  padding: 12px;
  border-radius: 5px;
}
.error {
  color: #a22828 !important;
  min-height: 10px;
}
#image-dialog {
  width: min(1100px, 94vw);
  max-height: 94vh;
}
#large-image {
  max-width: 100%;
  max-height: 78vh;
  display: block;
  margin: 16px auto 0;
  object-fit: contain;
}
#image-caption {
  text-align: center;
  margin-bottom: 0;
}
body {
  scrollbar-color: #bec7d2 #f0f2f4;
  scrollbar-width: thin;
}
@media (min-width: 1600px) {
  .workspace {
    grid-template-columns: 400px minmax(0, 1fr);
  }
}
@media (max-width: 1100px) {
  .app-purpose {
    display: none;
  }
  .workspace {
    grid-template-columns: 300px minmax(0, 1fr);
  }
  .preview-toolbar {
    gap: 8px;
    padding: 13px;
  }
  #parse-status {
    flex-basis: 100%;
    text-align: left;
  }
  .preview-stage {
    margin: 0 13px;
  }
  .preview-footer {
    padding: 12px 13px;
    flex-direction: column;
    gap: 4px;
  }
}
@media (max-width: 760px) {
  .app-header {
    height: auto;
    min-height: 70px;
    flex-wrap: wrap;
    padding: 16px;
    gap: 13px;
  }
  .brand {
    font-size: 16px;
  }
  .header-actions {
    gap: 6px;
  }
  .header-actions button {
    font-size: 12px;
    padding: 8px;
  }
  .workspace {
    height: auto;
    display: flex;
    flex-direction: column;
  }
  .editor-pane {
    border-right: 0;
  }
  .pane-heading {
    padding: 15px 20px;
  }
  #readme {
    height: 220px;
    flex: none;
  }
  .checks {
    max-height: 180px;
  }
  .asset-panel {
    max-height: 160px;
  }
  .preview-pane {
    height: 850px;
  }
  .preview-stage {
    margin: 0 10px;
  }
  .preview-footer {
    font-size: 12px;
  }
  .open-options {
    flex-direction: column;
  }
}
@media (prefers-reduced-motion: reduce) {
  #preview {
    transition: none;
  }
}
