/* Assume light mode by default */
@import "https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.10.0/styles/atom-one-light.min.css"
  screen;

/* Supersede dark mode when applicable */
@import "https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.10.0/styles/atom-one-dark.min.css"
  screen and (prefers-color-scheme: dark);

:root {
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  --font-mono: Consolas, monaco, "Ubuntu Mono", "Liberation Mono", "Courier New",
    Courier, monospace;

  /* Light theme */
  --tx-1: #1a1a1a;
  --bg-1: #ffffff;
  --bg-2: #fafafa;
  --lk-1: #0070f3;

  /* Dark theme */
  --d-tx-1: #d1d7e0;
  --d-bg-1: #212830;
  --d-bg-2: #282c34;
  --d-lk-1: #478be6;
}

@media (prefers-color-scheme: dark) {
  :root {
    --tx-1: var(--d-tx-1);
    --bg-1: var(--d-bg-1);
    --bg-2: var(--d-bg-2);
    --lk-1: var(--d-lk-1);
  }
}
html {
  font-family: var(--font-sans);
}

body {
  background: var(--bg-1);
  color: var(--tx-1);
  font-family: sans-serif;
  line-height: 1.5;
  margin: 2rem auto;
  max-width: 720px;
  padding: 1rem;
}

header {
  text-align: center;
}

h1,
h2 {
  line-height: 1;
}

h2 {
  padding-top: 0.875rem;
}

a {
  color: var(--lk-1);
}

dt {
  font-weight: bold;
  padding-top: 0.4375rem;
}

dd {
  margin: 0;
}

ul {
  padding-inline-start: 16px;
}

code,
pre {
  background: var(--bg-2);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.5;
  min-height: 6.75rem; /* Set min-height to 5 lines */
}

#ip-input {
  border: none;
  background: none;
  background: var(--bg-2);
  color: var(--lk-1);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  outline: none;
  padding: 0;
  text-align: center;
  text-decoration: underline;
  width: 9ch;
  min-width: 1ch;
}
