:root {
  --site-bg: #0d1117;
  --site-panel: #161b22;
  --site-panel-raised: #1b222c;
  --site-control: #0f141b;
  --site-border: #30363d;
  --site-text: #e6edf3;
  --site-muted: #8b949e;
  --site-radius: 10px;
  --site-control-radius: 6px;
  --site-content-width: 1280px;
  --site-focus: var(--link, #ff9b96);
}

html {
  color-scheme: dark;
  background: var(--site-bg);
  scrollbar-color: #4b5563 var(--site-bg);
  scrollbar-width: thin;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body:not(.embedded) {
  min-width: 0;
  background: var(--site-bg) !important;
  color: var(--site-text) !important;
  font-family: Arial, Helvetica, sans-serif !important;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: color-mix(in srgb, var(--site-focus) 34%, transparent);
  color: #fff;
}

body > header {
  padding: 12px 22px 10px !important;
  background: var(--panel, var(--site-panel)) !important;
  border-bottom: 1px solid var(--border, var(--site-border)) !important;
}

body > header :is(.header-inner, .logo-wrap, .brand) {
  min-height: 68px !important;
  line-height: 0;
}

body > header .site-logo-link {
  display: flex !important;
  flex: 0 0 96px !important;
  align-items: center !important;
  justify-content: center !important;
  width: 96px !important;
  height: 68px !important;
  line-height: 0 !important;
}

body > header :is(.site-logo, .brand-img, #site-mascot) {
  display: block !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: 96px !important;
  height: 68px !important;
  max-height: 68px !important;
  margin: 0 auto !important;
  border-radius: 10px !important;
  object-fit: contain !important;
}

body > header .c0ld-primary-nav {
  width: 100% !important;
  max-width: var(--site-content-width) !important;
  margin: 9px auto 0 !important;
}

body > main {
  width: 100%;
  max-width: var(--site-content-width) !important;
  min-width: 0;
  margin-inline: auto !important;
}

:where(h1, h2, h3) {
  color: var(--text, var(--site-text));
  text-wrap: balance;
}

:where(.hero h1, .page-head h1) {
  font-size: clamp(25px, 2.4vw, 28px) !important;
  line-height: 1.12 !important;
}

:where(.muted, .subtle, .meta, .label, .dates) {
  color: var(--muted, var(--site-muted));
}

:where(.hero, .section, .card, .box, .panel, .profile-shell, .profile-header, .battle-card) {
  border-color: var(--border, var(--site-border));
  border-radius: var(--site-radius);
}

:where(button, input, select, textarea) {
  max-width: 100%;
  font: inherit;
}

:where(input, select, textarea) {
  min-height: 38px;
  border-color: var(--border, var(--site-border));
  border-radius: var(--site-control-radius);
  background: var(--panel-2, var(--panel2, var(--site-control)));
  color: var(--text, var(--site-text));
}

:where(button, [role="button"], input, select, textarea, a, summary):focus-visible {
  outline: 2px solid var(--site-focus) !important;
  outline-offset: 2px !important;
}

:where(button, [role="button"]):disabled {
  cursor: not-allowed;
  opacity: 0.56;
}

:where(.table-wrap, .table-scroll, pre) {
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
}

:where(table, .numeric, .value, .stat-value, .rank) {
  font-variant-numeric: tabular-nums;
}

:where(img, video, canvas, svg) {
  max-width: 100%;
}

.tool-header {
  flex-wrap: wrap;
}

.model-badge {
  min-width: 0;
  max-width: 100%;
  white-space: normal !important;
  text-align: right;
}

@media (max-width: 720px) {
  body > header {
    padding: 10px 12px 9px !important;
  }

  body > header :is(.header-inner, .logo-wrap, .brand) {
    min-height: 60px !important;
  }

  body > header .site-logo-link {
    width: 88px !important;
    height: 60px !important;
    flex-basis: 88px !important;
  }

  body > header :is(.site-logo, .brand-img, #site-mascot) {
    width: auto !important;
    min-width: 0 !important;
    max-width: 88px !important;
    height: 60px !important;
    max-height: 60px !important;
  }

  body > main {
    padding-inline: 16px !important;
  }

  .tool-header {
    align-items: flex-start;
  }

  .model-badge {
    width: 100%;
    justify-content: flex-start;
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
