html, body {
  height: 100%;
}

:root {
  --bg: #0b0c10;
  --card: #12141b;
  --text: #e9ecf1;
  --muted: #a7afbd;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #7aa2ff;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --radius: 16px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f6f7fb;
    --card: #ffffff;
    --text: #101418;
    --muted: #5a6472;
    --line: rgba(16, 20, 24, 0.1);
    --accent: #2f5cff;
    --shadow: 0 20px 60px rgba(20, 30, 50, 0.12);
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  background: radial-gradient(1200px 700px at 50% -10%, rgba(122, 162, 255, 0.25), transparent 60%), var(--bg);
  color: var(--text);
  min-height: 100vh;
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-size: cover;
}

.wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 56px 20px 40px;
}

.head h1 {
  margin: 0 0 18px;
  font-size: 28px;
  letter-spacing: -0.02em;
  font-weight: 700;
}

.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}

.search {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
  border-radius: 14px;
  padding: 18px 16px;
  font-size: 18px;
  outline: none;
}

.search:focus {
  border-color: rgba(122, 162, 255, 0.55);
  box-shadow: 0 0 0 4px rgba(122, 162, 255, 0.18);
}

.status {
  min-height: 22px;
  margin: 10px 2px 2px;
  font-size: 14px;
  color: var(--muted);
}

.results {
  margin-top: 14px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.row {
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 2px;
}

.k {
  color: var(--muted);
  font-size: 13px;
}

.v {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.copy {
  width: 44px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.copy:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.copy:not(:disabled):hover {
  border-color: rgba(122, 162, 255, 0.55);
}

.links {
  margin-top: 14px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  display: grid;
  gap: 8px;
}

.links-title {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 2px;
}

.link {
  color: var(--text);
  text-decoration: none;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.link[aria-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
}

.link:not([aria-disabled="true"]):hover {
  border-color: rgba(122, 162, 255, 0.55);
}

.links-hint, .hint {
  color: var(--muted);
  font-size: 13px;
}

.foot {
  margin-top: 14px;
  padding: 0 4px;
}

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

.subhead {
  margin: 8px 0 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.4;
}

.actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 180px;
}

.copied-msg {
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}

.favicon {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  flex: 0 0 auto;
  margin-right: 4px;
}

.copy-label {
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
  min-width: 88px;   /* prevents layout jump when it becomes “✓ Copied” */
  text-align: right;
  user-select: none;
}

.copy-label.is-copied {
  color: var(--accent);
}

.repo-foot {
  margin-top: 16px;
  padding: 0 4px;
  display: flex;
  justify-content: center;
}

.repo-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  border: 1px solid var(--line);
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.repo-link:hover {
  color: var(--text);
  border-color: rgba(122, 162, 255, 0.55);
}
