:root {
  color-scheme: dark;
  --bg: #000000;
  --bg-2: #070707;
  --surface: #0b0b0b;
  --surface-2: #131313;
  --surface-3: #1b1b1b;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #fafafa;
  --text-2: #a3a3a3;
  --text-3: #6b6b6b;
  --moon: #ffffff;
  --moon-2: #ffffff;
  --moon-ink: #000000;
  --moon-glow: rgba(255, 255, 255, 0.1);
  --lunar: #d4d4d4;
  --blue: #9a9a9a;
  --green: #fafafa;
  --red: #ff5c67;
  --amber: #c7c7c7;
  --violet: #6f6f6f;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 20px 50px -20px rgba(0, 0, 0, 0.6);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  /* system-ui is the platform font everywhere (SF, Segoe UI, Roboto); every extra family
     listed is a font lookup on a cold start, which showed up as long layout tasks. */
  --sans: system-ui, sans-serif;
  --mono: ui-monospace, Menlo, Consolas, monospace;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
}

img,
svg {
  display: block;
  max-width: 100%;
}

code,
kbd,
pre {
  font-family: var(--mono);
  font-size: 0.92em;
}

:focus-visible {
  outline: 2px solid var(--moon);
  outline-offset: 2px;
  border-radius: 6px;
}

::selection {
  background: rgba(255, 255, 255, 0.3);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.btn {
  --btn-bg: var(--surface-2);
  --btn-fg: var(--text);
  --btn-line: var(--line-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border-radius: 10px;
  border: 1px solid var(--btn-line);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: 600 14px/1 var(--sans);
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s var(--ease), background 0.15s, border-color 0.15s, box-shadow 0.2s;
}

.btn:hover {
  --btn-line: rgba(255, 255, 255, 0.24);
  background: var(--surface-3);
}

.btn:active {
  transform: translateY(1px);
}

.btn[disabled] {
  opacity: 0.55;
  pointer-events: none;
}

.btn-primary {
  --btn-bg: #ffffff;
  --btn-fg: #000000;
  --btn-line: transparent;
  background: var(--btn-bg);
  box-shadow: 0 8px 30px -12px rgba(255, 255, 255, 0.35);
}

.btn-primary:hover {
  background: #e6e6e6;
  box-shadow: 0 10px 36px -12px rgba(255, 255, 255, 0.45);
}

.btn-ghost {
  --btn-bg: transparent;
  --btn-line: transparent;
  color: var(--text-2);
}

.btn-ghost:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.btn-danger {
  --btn-bg: rgba(255, 107, 122, 0.1);
  --btn-fg: #ffb3bb;
  --btn-line: rgba(255, 107, 122, 0.3);
}

.btn-danger:hover {
  background: rgba(255, 107, 122, 0.18);
}

.btn-sm {
  height: 32px;
  padding: 0 12px;
  font-size: 13px;
  border-radius: 8px;
}

.btn-lg {
  height: 48px;
  padding: 0 22px;
  font-size: 15px;
  border-radius: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  font: 600 11.5px/1 var(--sans);
  letter-spacing: 0.02em;
  border: 1px solid var(--line-2);
  color: var(--text-2);
  background: rgba(255, 255, 255, 0.04);
  white-space: nowrap;
}

.badge-moon {
  color: var(--moon-2);
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

.badge-green {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

.badge-red {
  color: #ffb3bb;
  border-color: rgba(255, 107, 122, 0.35);
  background: rgba(255, 107, 122, 0.08);
}

.badge-blue {
  color: #d4d4d4;
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

.badge-violet {
  color: #bdbdbd;
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  flex: none;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font: 700 17px/1 var(--sans);
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
}

.logo svg {
  width: 26px;
  height: 26px;
}

.logo img {
  display: block;
  width: auto;
  height: 30px;
}

input,
select,
textarea {
  font: inherit;
  color: inherit;
}

.field {
  display: grid;
  gap: 7px;
}

.field > span,
.label {
  font: 600 13px/1.3 var(--sans);
  color: var(--text-2);
}

.input,
.select,
.textarea {
  width: 100%;
  height: 42px;
  padding: 0 13px;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: var(--bg-2);
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.textarea {
  height: auto;
  min-height: 96px;
  padding: 11px 13px;
  resize: vertical;
  line-height: 1.5;
}

.input:hover,
.select:hover,
.textarea:hover {
  border-color: rgba(255, 255, 255, 0.22);
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.12);
}

.input::placeholder,
.textarea::placeholder {
  color: var(--text-3);
}

.mono {
  font-family: var(--mono);
}

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