:root {
  color-scheme: dark;
  --profile-surface: #232428;
  --profile-section: #1b1c20;
  --profile-line: #36373d;
  --bg: #121214;
  --bg-elevated: #19191d;
  --panel: #1b1b1f;
  --panel-2: #25252b;
  --line: #39393f;
  --line-soft: #2b2b31;
  --text: #f2f3f5;
  --muted: #b5bac1;
  --dim: #989ba5;
  --brand: #8590ff;
  --brand-2: #8dbdff;
  --good: #57f287;
  --warn: #fee75c;
  --danger: #ed4245;
  --pink: #eb459e;
  --surface: rgba(255, 255, 255, .035);
  --surface-soft: rgba(255, 255, 255, .025);
  --surface-strong: rgba(255, 255, 255, .07);
  --surface-deep: rgba(0, 0, 0, .12);
  --surface-code: rgba(0, 0, 0, .18);
  --shadow: 0 8px 28px rgba(0, 0, 0, .12);
  --radius: 18px;
  --radius-sm: 11px;
  --font: "gg sans", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

:root[data-theme="light"] {
  color-scheme: light;
  --profile-surface: #ffffff;
  --profile-section: #f2f3f5;
  --profile-line: #dcdfe4;
  --bg: #f4f6fa;
  --bg-elevated: #ffffff;
  --panel: #ffffff;
  --panel-2: #eef2f7;
  --line: #d7dde7;
  --line-soft: #e6ebf3;
  --text: #171b22;
  --muted: #4d5968;
  --dim: #667385;
  --brand: #4752c4;
  --brand-2: #006eaa;
  --good: #18733b;
  --warn: #7b5b00;
  --danger: #bd2c31;
  --pink: #ad276f;
  --surface: rgba(26, 36, 52, .055);
  --surface-soft: rgba(26, 36, 52, .035);
  --surface-strong: rgba(26, 36, 52, .085);
  --surface-deep: rgba(26, 36, 52, .06);
  --surface-code: rgba(26, 36, 52, .085);
  --shadow: 0 18px 45px rgba(24, 34, 48, .12);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
  scroll-padding-top: 92px;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  color: var(--text);
  font-family: var(--font);
  background: radial-gradient(ellipse at 80% 0, rgba(88, 101, 242, .08), transparent 55%), var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

input,
textarea {
  user-select: text;
}

:root[data-theme="light"] body {
  background: radial-gradient(ellipse at 80% 0, rgba(88, 101, 242, .06), transparent 55%), var(--bg);
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

::selection {
  background: rgba(88, 101, 242, .45);
}

[hidden] {
  display: none !important;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border: 1px solid var(--brand-2);
  border-radius: var(--radius-sm);
  color: #fff;
  background: #273078;
  font-weight: 900;
  text-decoration: none;
  transform: translateY(-150%);
  transition: transform .16s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.topbar {
  position: relative;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding: 20px max(24px, calc((100vw - 1232px) / 2));
  border-bottom: 1px solid var(--line-soft);
  background: var(--bg);
}

:root[data-theme="light"] .topbar {
  background: var(--bg);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  border: 0;
  background: transparent;
  text-align: left;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  padding: 0;
}

.brand-mark {
  position: relative;
  display: inline-flex;
  width: 46px;
  height: 36px;
  flex: 0 0 46px;
  border-radius: var(--radius);
  isolation: isolate;
}

.brand-mark::before {
  content: "";
  position: absolute;
  inset: -8px;
  z-index: -1;
  border-radius: 14px;
  background:
    radial-gradient(circle at 30% 30%, rgba(88, 101, 242, .38), transparent 58%),
    radial-gradient(circle at 75% 65%, rgba(87, 242, 135, .32), transparent 60%);
  opacity: 0;
  transform: scale(.65);
  filter: blur(8px);
}

.brand-mark img {
  position: absolute;
  top: 2px;
  width: 32px;
  height: 32px;
  object-fit: contain;
  filter: drop-shadow(0 8px 12px rgba(0, 0, 0, .28));
}

.brand-mark img:first-child {
  left: 0;
  transform: rotate(-8deg);
}

.brand-mark img:last-child {
  right: 0;
  transform: rotate(8deg);
}

.brand:hover .brand-mark img:first-child {
  transform: translateX(-2px) rotate(-12deg);
}

.brand:hover .brand-mark img:last-child {
  transform: translateX(2px) rotate(12deg);
}

.brand-mark.logo-burst::before {
  animation: logoGlow .8s cubic-bezier(.16, .8, .24, 1);
}

.brand-mark.logo-burst img:first-child {
  animation: logoSpyglass .8s cubic-bezier(.16, .8, .24, 1);
}

.brand-mark.logo-burst img:last-child {
  animation: logoIdCard .8s cubic-bezier(.16, .8, .24, 1);
}

.brand-copy {
  display: grid;
  min-width: 0;
}

.brand-title {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: .01em;
}

.brand-subtitle {
  color: var(--dim);
  font-size: .76rem;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  margin-left: auto;
}

.version-pill,
.nav-btn,
.ghost-btn,
.action-btn,
.primary-btn,
.help-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: var(--radius);
  white-space: nowrap;
  text-decoration: none;
}

.version-pill {
  padding: 0 12px;
  border: 1px solid rgba(88, 101, 242, .34);
  color: #dfe3ff;
  background: rgba(88, 101, 242, .16);
  font-size: .76rem;
  font-weight: 800;
}

:root[data-theme="light"] .version-pill {
  color: #3640a3;
}

.nav-btn,
.ghost-btn,
.action-btn,
.help-link {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  padding: 0 13px;
  font-size: .82rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease;
}

.nav-btn:hover,
.ghost-btn:hover,
.action-btn:hover,
.help-link:hover {
  transform: translateY(-1px);
  border-color: rgba(88, 101, 242, .72);
  color: var(--text);
  background: rgba(88, 101, 242, .13);
}

.action-btn--share {
  position: relative;
  overflow: hidden;
}

.action-btn--share.is-copied {
  border-color: rgba(87, 242, 135, .78);
  color: transparent;
  background: rgba(24, 72, 44, .30);
  box-shadow: 0 0 0 3px rgba(87, 242, 135, .12), 0 10px 24px rgba(0, 0, 0, .18);
  transform: translateY(-1px) scale(1.02);
}

.action-btn--share.is-copied::after {
  content: "\2713  Copied";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #caffd9;
  background: linear-gradient(135deg, rgba(24, 72, 44, .96), rgba(31, 104, 60, .96));
  font-weight: 900;
  animation: copiedButtonPop 2s cubic-bezier(.16, 1, .3, 1) both;
}

:root[data-theme="light"] .action-btn--share.is-copied::after {
  color: #fff;
  background: linear-gradient(135deg, #176b39, #21894b);
}

.layout {
  width: min(1280px, 100%);
  margin: 0 auto;
  padding: 0 clamp(20px, 3vw, 40px) 40px;
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  grid-template-rows: auto auto 1fr;
  grid-template-areas: "intro intro" "search result" "help result";
  gap: 22px;
  align-items: start;
}

body.help-hidden .layout {
  grid-template-areas: "intro intro" "search result";
  grid-template-rows: auto 1fr;
}

.panel {
  position: relative;
  min-width: 0;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.search-panel::before {
  content: "";
  position: absolute;
  inset: 0 28px auto;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--brand), transparent);
}

.search-panel,
.help-panel {
  padding: 22px;
}

.result-panel {
  grid-area: result;
  min-height: 520px;
  padding: 0;
  scroll-margin-top: 20px;
}

.result-panel.is-ready {
  animation: resultIn .24s ease both;
}

.panel-heading {
  display: grid;
  gap: 5px;
  margin-bottom: 18px;
}

.panel-heading.compact {
  margin-bottom: 14px;
}

.eyebrow {
  margin: 0;
  color: var(--brand-2);
  font-size: .72rem;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(1.55rem, 3vw, 2.25rem);
  line-height: 1.04;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 1.18rem;
  line-height: 1.2;
}

.mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 6px;
  margin-bottom: 18px;
  background: var(--bg-elevated);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
}

.mode-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--dim);
  font-weight: 700;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}

.mode-btn.is-active {
  border-color: rgba(88, 101, 242, .55);
  color: var(--text);
  background:
    linear-gradient(135deg, rgba(88, 101, 242, .24), rgba(0, 168, 252, .13));
}

.btn-icon {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  margin-right: 7px;
  border-radius: 5px;
  background: rgba(255, 255, 255, .08);
  color: var(--text);
  font-size: .72rem;
  font-weight: 900;
}

.search-form {
  display: grid;
  gap: 9px;
}

.search-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.search-shortcut {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--dim);
  font-size: .72rem;
}

.search-shortcut kbd {
  min-width: 21px;
  min-height: 19px;
  margin: 0;
  font-size: .6rem;
}

.search-label {
  color: var(--muted);
  font-size: .8rem;
  font-weight: 800;
}

.search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

#searchId {
  width: 100%;
  min-width: 0;
  height: 50px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0 14px;
  color: var(--text);
  background: var(--bg-elevated);
  font-size: 16px;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}

#searchId:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(88, 101, 242, .18);
}

#searchId[aria-invalid="true"] {
  border-color: var(--danger);
  box-shadow: 0 0 0 4px rgba(237, 66, 69, .14);
}

.primary-btn {
  min-height: 48px;
  border: 1px solid #7985ff;
  background: #5865f2;
  color: #fff;
  padding: 0 18px;
  font-size: .875rem;
  font-weight: 750;
  cursor: pointer;
  transition: transform .15s ease, background .15s ease;
}

.primary-btn:active,
.ghost-btn:active,
.action-btn:active,
.nav-btn:active {
  transform: translateY(0) scale(.98);
}

.primary-btn:disabled,
.ghost-btn:disabled {
  cursor: not-allowed;
  filter: grayscale(.25);
  opacity: .5;
  transform: none;
  box-shadow: none;
}

.button-loader {
  display: none;
  width: 15px;
  height: 15px;
  margin-left: 8px;
  border: 2px solid rgba(255, 255, 255, .38);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .72s linear infinite;
}

.primary-btn.is-loading .button-loader {
  display: inline-block;
}

.primary-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow: 0 16px 28px rgba(88, 101, 242, .26);
}

.primary-btn.compact {
  min-height: 44px;
}

.helper-stack {
  display: grid;
  gap: 12px;
  margin-top: 13px;
}

.helper-stack p {
  margin: 0;
  color: var(--dim);
  font-size: .82rem;
  line-height: 1.45;
}

.helper-stack .input-feedback {
  min-height: 1.25em;
  margin-top: -7px;
  font-weight: 700;
}

.input-feedback[data-tone="success"] {
  color: var(--good);
}

.input-feedback[data-tone="info"] {
  color: var(--brand-2);
}

.input-feedback[data-tone="error"] {
  color: #ff8d90;
}

:root[data-theme="light"] .input-feedback[data-tone="error"] {
  color: #b22128;
}

.recent-searches {
  display: grid;
  gap: 10px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.recent-heading-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.recent-heading-row h2 {
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--dim);
}

.text-btn {
  min-height: 32px;
  padding: 0;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: .74rem;
  font-weight: 800;
  cursor: pointer;
}

.text-btn:hover {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.recent-list {
  display: grid;
  gap: 7px;
}

.recent-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 54px;
  padding: 8px 10px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  color: var(--text);
  background: var(--surface-soft);
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.recent-item:hover {
  border-color: rgba(88, 101, 242, .58);
  background: rgba(88, 101, 242, .09);
  transform: translateX(2px);
}

.recent-kind {
  min-width: 44px;
  padding: 5px 7px;
  border-radius: 999px;
  color: #dfe3ff;
  background: rgba(88, 101, 242, .18);
  font-size: .62rem;
  font-weight: 900;
  text-align: center;
  text-transform: uppercase;
}

:root[data-theme="light"] .recent-kind {
  color: #3640a3;
}

.recent-copy {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.recent-copy strong,
.recent-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-copy strong {
  font-size: .82rem;
}

.recent-copy span {
  color: var(--dim);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: .68rem;
}

.recent-arrow {
  color: var(--dim);
  font-size: 1rem;
}

.utility-row,
.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.action-row.centered {
  justify-content: center;
}

.empty-state,
.error-card {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  min-height: 520px;
  padding: 40px;
  text-align: center;
}

.empty-state p,
.error-card p {
  max-width: 480px;
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.empty-glyph,
.error-code {
  display: inline-grid;
  place-items: center;
  min-width: 56px;
  height: 56px;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(88, 101, 242, .18), rgba(87, 242, 135, .12));
  border: 1px solid rgba(88, 101, 242, .38);
  color: #dfe3ff;
  font-size: 1rem;
  font-weight: 900;
}

.error-code {
  color: #fff;
  background: rgba(237, 66, 69, .18);
  border-color: rgba(237, 66, 69, .42);
}

:root[data-theme="light"] .empty-glyph {
  color: #303b9f;
}

.profile-card {
  position: relative;
  isolation: isolate;
  display: grid;
  gap: 20px;
  padding: 0 24px 24px;
  border-radius: calc(var(--radius) - 1px);
  --profile-accent: var(--brand);
  --profile-accent-rgb: 112, 126, 255;
  background: var(--profile-surface);
}

.pointer-light {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 16;
  pointer-events: none;
  contain: strict;
}

.profile-effect-layer,
.profile-frame-layer {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
}

.profile-effect-layer {
  z-index: 12;
}

.profile-frame-layer {
  z-index: 18;
}

.profile-effect-media,
.profile-frame-media {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: fill;
}

.profile-effect-media {
  object-fit: cover;
}

.media-banner {
  height: 210px;
  margin: 0 -24px;
  background-color: var(--profile-accent, var(--panel-2));
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--profile-line);
  position: relative;
}

.media-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 70%, rgba(0, 0, 0, .08));
}

.identity-block {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
  margin-top: -72px;
  position: relative;
  z-index: 2;
}

.avatar-wrap {
  position: relative;
  display: block;
  width: 112px;
  height: 112px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: inherit;
}

.avatar-wrap--interactive {
  cursor: pointer;
  touch-action: manipulation;
  transform-origin: 50% 82%;
}

.avatar-wrap--interactive:hover .avatar-img {
  display: block;
  width: 112px;
  height: 112px;
  border-radius: 50%;
  border: 6px solid var(--profile-surface);
  object-fit: cover;
  background: var(--panel-2);
  box-shadow: none;
}

.avatar-wrap--interactive.avatar-arrival {
  animation: avatarArrival .48s cubic-bezier(.16, .84, .28, 1.16) both;
}

.avatar-wrap--interactive.avatar-surprised {
  animation: avatarSurprised .42s cubic-bezier(.18, .84, .24, 1) both;
}

.avatar-img {
  filter: saturate(var(--stress-saturation, 1)) brightness(var(--stress-brightness, 1));
}

.avatar-img {
  width: 118px;
  height: 118px;
  border-radius: 50%;
  border: 7px solid var(--panel);
  object-fit: cover;
  background: var(--panel-2);
  box-shadow:
    0 16px 28px rgba(0, 0, 0, .32),
    0 0 0 3px rgba(var(--profile-accent-rgb), .58),
    0 0 30px rgba(var(--profile-accent-rgb), .34);
  transition: box-shadow .22s ease, filter .22s ease;
}

.profile-card:not(.guild-profile) .avatar-img {
  border-color: var(--profile-surface);
}

.profile-card:not(.guild-profile) .metric,
.profile-card:not(.guild-profile) .meta-cell,
.profile-card:not(.guild-profile) .api-field,
.profile-card:not(.guild-profile) .cosmetic-card,
.profile-card:not(.guild-profile) .raw-block {
  border-color: var(--profile-line);
  background: var(--profile-section);
}

.meta-cell--accent {
  background: var(--profile-section) !important;
  box-shadow: inset 3px 0 0 var(--shown-accent);
}

.color-swatch {
  display: inline-block;
  width: 13px;
  height: 13px;
  margin-right: 7px;
  border: 2px solid rgba(255, 255, 255, .70);
  border-radius: 50%;
  vertical-align: -2px;
  background: var(--shown-accent);
  box-shadow: none;
}

.avatar-fallback {
  display: grid;
  place-items: center;
  color: var(--text);
  font-size: 1.6rem;
  font-weight: 800;
}

.avatar-decoration {
  position: absolute;
  inset: -18px;
  width: calc(100% + 36px);
  height: calc(100% + 36px);
  object-fit: contain;
  pointer-events: none;
}

.identity-copy {
  min-width: 0;
  padding: 58px 0 0;
}

:root[data-theme="light"] .identity-copy {
  background: transparent;
}

.identity-copy h2 {
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  font-weight: 750;
  line-height: 1.2;
  overflow-wrap: anywhere;
  letter-spacing: -.025em;
}

.identity-copy p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.4;
  word-break: break-word;
}

.badge-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px;
  width: fit-content;
  max-width: 100%;
  margin-top: 12px;
  padding: 3px;
  border: 1px solid var(--profile-line);
  border-radius: 9px;
  background: var(--profile-section);
}

.badge {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  max-width: 100%;
  padding: 5px 11px 5px 5px;
  border: 1px solid rgba(255, 255, 255, .10);
  border-radius: 999px;
  color: var(--muted);
  background: linear-gradient(135deg, var(--surface-strong), var(--surface-soft));
  font-size: .76rem;
  font-weight: 800;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .045);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.badge:hover {
  transform: translateY(-1px);
  border-color: rgba(88, 101, 242, .55);
  background: linear-gradient(135deg, rgba(88, 101, 242, .16), rgba(255, 255, 255, .035));
}

.badge-icon {
  position: relative;
  overflow: hidden;
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(11, 13, 17, .42);
  flex: 0 0 28px;
  transition: transform .18s ease;
}

.badge-img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.badge-fallback {
  font-size: .52rem;
  font-weight: 900;
  color: var(--text);
}

.badge-symbol {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  color: #fff;
}

.badge-symbol--verified-bot {
  background: var(--brand);
  clip-path: polygon(50% 0, 63% 9%, 79% 7%, 88% 21%, 100% 31%, 95% 48%, 100% 64%, 87% 75%, 80% 92%, 63% 91%, 50% 100%, 36% 91%, 20% 93%, 12% 78%, 0 66%, 5% 50%, 0 34%, 13% 23%, 20% 7%, 37% 9%);
  filter: drop-shadow(0 3px 5px rgba(88, 101, 242, .35));
}

.badge-symbol--verified-bot span {
  font-size: .82rem;
  font-weight: 1000;
  line-height: 1;
  transform: translateY(-1px);
}

.badge-symbol--bot-account {
  align-content: center;
}

.bot-antenna {
  position: absolute;
  top: 0;
  left: 50%;
  width: 2px;
  height: 5px;
  border-radius: 999px;
  background: currentColor;
  transform: translateX(-50%);
}

.bot-antenna::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 50%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
  transform: translateX(-50%);
}

.bot-face {
  display: flex;
  align-items: center;
  justify-content: space-evenly;
  width: 21px;
  height: 15px;
  margin-top: 5px;
  border: 2px solid currentColor;
  border-radius: 6px;
}

.bot-face span {
  width: 3px;
  height: 4px;
  border-radius: 999px;
  background: currentColor;
}

.badge-label {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.badge-copy {
  display: grid;
  min-width: 0;
  line-height: 1.08;
}

.badge-detail {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--dim);
  font-size: .62rem;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.badge--server {
  border-color: rgba(87, 242, 135, .30);
  background: linear-gradient(135deg, rgba(87, 242, 135, .13), rgba(88, 101, 242, .10));
}

.badge--server .badge-icon {
  background: rgba(87, 242, 135, .10);
}

.badge--nitro {
  border-color: rgba(235, 69, 158, .34);
  background: linear-gradient(135deg, rgba(235, 69, 158, .15), rgba(88, 101, 242, .12));
}

.badge--nitro .badge-icon {
  background: rgba(235, 69, 158, .11);
}

.badge--account .badge-icon {
  border-radius: 9px;
  background: rgba(88, 101, 242, .14);
}

.badge--account .badge-symbol--bot-account {
  color: #8ea1ff;
}

.badge--server-capability {
  border-style: dashed;
  border-color: rgba(87, 242, 135, .32);
}

.badge-labels-off .badge {
  width: 36px;
  height: 36px;
  min-height: 36px;
  padding: 5px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
}

.badge-labels-off .badge-copy {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 13px);
  z-index: 30;
  width: max-content;
  max-width: min(270px, calc(100vw - 28px));
  height: auto;
  padding: 10px 12px;
  overflow: visible;
  clip: auto;
  border: 1px solid rgba(var(--profile-accent-rgb), .55);
  border-radius: 12px;
  color: var(--text);
  background: var(--profile-section);
  box-shadow: 0 16px 38px rgba(0, 0, 0, .45);
  line-height: 1.15;
  text-align: left;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, 8px) scale(.88) ;
  transform-origin: 50% 100%;
  transition: opacity .18s ease, transform .25s cubic-bezier(.16, 1, .3, 1), visibility .18s ease;
}

.badge-labels-off .badge-copy::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 100%;
  width: 9px;
  height: 9px;
  border-right: 1px solid rgba(var(--profile-accent-rgb), .55);
  border-bottom: 1px solid rgba(var(--profile-accent-rgb), .55);
  background: var(--panel);
  transform: translate(-50%, -5px) rotate(45deg);
}

.badge-labels-off .badge:hover,
.badge-labels-off .badge:focus-visible {
  z-index: 25;
  transform: translateY(-1px);
  border-color: transparent;
  background: var(--surface-strong);
  box-shadow: none;
}

.badge-labels-off .badge:hover .badge-copy,
.badge-labels-off .badge:focus-visible .badge-copy {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0) scale(1);
}

.badge-labels-off .badge:hover .badge-icon,
.badge-labels-off .badge:focus-visible .badge-icon {
  transform: none;
}

.badge-labels-off .badge-detail {
  margin-top: 5px;
  color: var(--muted);
  font-size: .68rem;
}

.muted-text {
  color: var(--dim);
  font-size: .82rem;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.metric,
.meta-cell,
.note-box,
.feature-detail {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface);
}

.metric {
  min-height: 84px;
  padding: 13px;
  display: grid;
  align-content: space-between;
  gap: 10px;
}

.metric span,
.meta-label,
.section-title-row span {
  color: var(--dim);
  font-size: .72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.metric strong {
  color: var(--text);
  font-size: .94rem;
  line-height: 1.25;
  word-break: break-word;
}

.meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.meta-cell {
  display: grid;
  gap: 6px;
  min-height: 70px;
  padding: 12px;
  color: inherit;
  text-align: left;
}

button.meta-cell {
  cursor: pointer;
}

.meta-value {
  color: var(--muted);
  line-height: 1.35;
  word-break: break-word;
}

.meta-cell--split {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  padding: 0;
}

.meta-copy {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.owner-copy {
  align-self: stretch;
  padding: 12px;
  border: 0;
  border-radius: inherit;
  color: inherit;
  background: transparent;
  text-align: left;
}

.meta-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
  padding-right: 12px;
}

.mini-btn {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--muted);
  padding: 0 9px;
  font-size: .72rem;
  font-weight: 900;
  cursor: pointer;
}

.mini-btn:hover {
  border-color: rgba(87, 242, 135, .55);
  color: var(--text);
}

.mini-btn--primary {
  border-color: rgba(88, 101, 242, .55);
  background: rgba(88, 101, 242, .16);
  color: var(--text);
}

.copyable {
  position: relative;
  cursor: copy;
  overflow: hidden;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.copyable:hover {
  transform: translateY(-1px);
  border-color: rgba(112, 126, 255, .6);
  background: var(--surface-strong);
  box-shadow: none;
}

.copyable.is-copied {
  border-color: rgba(87, 242, 135, .95);
  box-shadow: 0 0 0 3px rgba(87, 242, 135, .14), 0 12px 28px rgba(0, 0, 0, .20);
}

.copyable.is-copied::after {
  content: "COPIED";
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
  padding: 4px 7px;
  border: 1px solid rgba(87, 242, 135, .48);
  border-radius: 999px;
  color: #b8ffcf;
  background: rgba(24, 72, 44, .92);
  font-family: var(--font);
  font-size: .58rem;
  font-weight: 900;
  letter-spacing: .08em;
  animation: copiedPop 2s ease both;
}

.note-box {
  padding: 13px;
  display: grid;
  gap: 4px;
  color: var(--muted);
  line-height: 1.45;
}

.note-box strong {
  color: var(--text);
}

.feature-section {
  display: grid;
  gap: 11px;
}

.activity-section,
.cosmetics-section,
.api-details {
  display: grid;
  gap: 11px;
}

.cosmetics-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cosmetic-card {
  display: grid;
  align-content: start;
  gap: 6px;
  min-height: 94px;
  padding: 13px;
  border: 1px solid rgba(var(--profile-accent-rgb), .25);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(var(--profile-accent-rgb), .10), transparent 68%),
    var(--surface);
}

.cosmetic-card > span {
  color: var(--dim);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.cosmetic-card strong {
  color: var(--text);
  line-height: 1.3;
}

.cosmetic-card small {
  color: var(--muted);
  font-size: .74rem;
  line-height: 1.4;
}

.activity-card {
  display: grid;
  gap: 5px;
  min-height: 74px;
  padding: 13px;
  border: 1px solid rgba(var(--profile-accent-rgb), .25);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(var(--profile-accent-rgb), .10), transparent 68%),
    var(--surface);
}

.activity-card strong {
  color: var(--text);
}

.activity-card > span:last-child:not(.activity-type) {
  color: var(--muted);
  font-size: .8rem;
  line-height: 1.4;
}

.activity-type,
.presence-status {
  color: var(--dim);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.presence-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.presence-status::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--dim);
}

.presence-status--online::before {
  background: var(--good);
}

.presence-status--idle::before {
  background: var(--warn);
}

.presence-status--dnd::before {
  background: var(--danger);
}

.section-title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.section-title-row h3 {
  margin: 0;
  font-size: 1rem;
}

.feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.feature-pill {
  min-height: 36px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
  padding: 0 10px;
  font-size: .76rem;
  font-weight: 800;
  cursor: pointer;
}

.feature-pill:hover,
.feature-pill.is-active {
  border-color: rgba(87, 242, 135, .55);
  color: var(--text);
  background: rgba(87, 242, 135, .10);
}

.feature-detail {
  padding: 13px;
  color: var(--muted);
  line-height: 1.45;
}

.feature-detail strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text);
}

.api-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.api-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 68px;
  padding: 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface);
}

button.api-field {
  width: 100%;
  color: inherit;
  text-align: left;
}

.api-field-copy {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.guild-tag-strip {
  margin-top: 10px;
}

.raw-block {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface-deep);
  overflow: hidden;
}

.raw-block summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 13px;
  cursor: pointer;
  color: var(--muted);
  font-size: .8rem;
  font-weight: 900;
  list-style: none;
}

.raw-block summary::-webkit-details-marker,
.help-details summary::-webkit-details-marker {
  display: none;
}

.raw-block pre {
  max-height: 310px;
  margin: 0;
  padding: 14px;
  overflow: auto;
  border-top: 1px solid var(--line-soft);
  color: var(--muted);
  background: var(--surface-code);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: .76rem;
  line-height: 1.5;
  text-align: left;
}

.raw-copy {
  cursor: copy;
  outline-offset: -3px;
}

.chevron {
  width: 9px;
  height: 9px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

details[open] > summary .chevron {
  transform: rotate(225deg);
}

.loading-card {
  min-height: 570px;
  padding: 22px;
  display: grid;
  align-content: start;
  gap: 16px;
}

.skeleton {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel-2);
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 20%, rgba(255, 255, 255, .12) 45%, transparent 70%);
  transform: translateX(-100%);
  animation: shimmer 1.4s infinite;
}

.banner-skeleton {
  height: 190px;
}

.avatar-skeleton {
  width: 118px;
  height: 118px;
  border-radius: 50%;
  margin-top: -76px;
  margin-left: 18px;
  border: 7px solid var(--panel);
}

.line-skeleton {
  width: 46%;
  height: 18px;
}

.line-skeleton.wide {
  width: 68%;
}

.skeleton-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.metric-skeleton {
  min-height: 84px;
}

.help-panel {
  display: grid;
  gap: 14px;
}

.help-panel.is-collapsed {
  display: none;
}

.help-grid {
  display: grid;
  gap: 8px;
}

.help-item {
  display: grid;
  grid-template-columns: auto 48px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 42px;
  padding: 9px 10px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
  font-size: .82rem;
}

.help-item strong {
  color: var(--text);
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--dim);
}

.status-dot.ok {
  background: var(--good);
}

.status-dot.warn {
  background: var(--warn);
}

.status-dot.wait {
  background: var(--brand-2);
}

.status-dot.err {
  background: var(--danger);
}

.help-details {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface);
}

.help-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 42px;
  padding: 0 12px;
  cursor: pointer;
  color: var(--text);
  font-weight: 900;
  list-style: none;
}

.details-body {
  display: grid;
  gap: 8px;
  padding: 0 12px 12px;
}

.help-link {
  width: 100%;
  min-height: 44px;
  justify-content: flex-start;
}

.shortcut-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: .8rem;
}

kbd {
  display: inline-grid;
  place-items: center;
  min-width: 24px;
  min-height: 22px;
  padding: 0 6px;
  margin-right: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
  background: var(--bg-elevated);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: .68rem;
  font-weight: 900;
}

.quick-actions {
  display: flex;
  gap: 8px;
}

.round-btn {
  position: relative;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .02)),
    var(--panel);
  color: var(--text);
  font-size: 1rem;
  font-weight: 900;
  cursor: pointer;
  box-shadow: var(--shadow);
}

.round-btn .settings-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 25px;
  height: 25px;
  display: block;
  filter: invert(1) drop-shadow(0 4px 10px rgba(0, 0, 0, .24));
  transform: translate(calc(-50% + 1px), -50%);
  transform-origin: center;
  transition: transform .22s ease;
}

:root[data-theme="light"] .round-btn .settings-icon {
  filter: invert(.18) drop-shadow(0 4px 10px rgba(24, 34, 48, .12));
}

.round-btn:hover .settings-icon {
  transform: translate(calc(-50% + 1px), -50%) rotate(28deg);
}

.round-btn:hover {
  border-color: rgba(88, 101, 242, .72);
}

.settings-panel {
  position: fixed;
  right: max(24px, env(safe-area-inset-right));
  top: 90px;
  z-index: 31;
  width: min(320px, calc(100vw - 32px));
  max-height: calc(100vh - 110px);
  max-height: calc(100dvh - 110px);
  overflow-y: auto;
  overscroll-behavior: contain;
  display: grid;
  gap: 8px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
  visibility: hidden;
  transform: translateY(8px);
  opacity: 0;
  pointer-events: none;
  transition: transform .16s ease, opacity .16s ease, visibility .16s;
}

.settings-panel.is-open {
  visibility: visible;
  transform: none;
  opacity: 1;
  pointer-events: auto;
}

body.captcha-open {
  overflow: hidden;
}

.captcha-layer {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 18px;
}

.captcha-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 7, 10, .84);
}

.captcha-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 16px;
  width: min(430px, 100%);
  padding: 22px;
  border: 1px solid rgba(88, 101, 242, .58);
  border-radius: var(--radius);
  color: var(--text);
  background:
    radial-gradient(circle at 12% 0, rgba(88, 101, 242, .22), transparent 44%),
    var(--panel);
  box-shadow: 0 28px 80px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .04);
}

.captcha-heading-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.captcha-heading-row .eyebrow {
  margin-bottom: 5px;
}

.captcha-card > p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.turnstile-widget {
  display: grid;
  place-items: center;
  min-height: 70px;
  overflow: hidden;
}

.captcha-feedback {
  min-height: 1.4em;
  font-size: .8rem;
  font-weight: 800;
  text-align: center;
}

.captcha-feedback[data-tone="success"] {
  color: var(--good);
}

.captcha-feedback[data-tone="info"] {
  color: var(--brand-2);
}

.captcha-feedback[data-tone="warn"] {
  color: var(--warn);
}

.captcha-feedback[data-tone="error"] {
  color: #ff8d90;
}

:root[data-theme="light"] .captcha-feedback[data-tone="error"] {
  color: var(--danger);
}

.settings-heading-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 2px;
}

.settings-panel h2 {
  font-size: .9rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--dim);
}

.settings-heading-row p {
  margin: 4px 0 0;
  color: var(--dim);
  font-size: .72rem;
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  color: var(--muted);
  background: var(--surface);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.icon-btn:hover {
  border-color: rgba(88, 101, 242, .65);
  color: var(--text);
  background: rgba(88, 101, 242, .12);
}

.switch-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-weight: 800;
  font-size: .84rem;
  cursor: pointer;
  min-height: 38px;
}

.switch-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.switch-ui {
  position: relative;
  width: 44px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
}

.switch-ui::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--dim);
  transition: transform .18s ease, background .18s ease;
}

.switch-row input:checked + .switch-ui {
  border-color: rgba(88, 101, 242, .72);
  background: rgba(88, 101, 242, .18);
}

.switch-row input:checked + .switch-ui::after {
  transform: translateX(20px);
  background: var(--brand);
}

.switch-row input:focus-visible + .switch-ui {
  outline: 2px solid var(--brand-2);
  outline-offset: 3px;
}

.status-live {
  position: fixed;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.footer {
  display: flex;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  padding: 18px;
  color: var(--dim);
  font-size: .78rem;
}

.footer a {
  color: var(--text);
  font-weight: 900;
  text-decoration: none;
  border-bottom: 1px solid rgba(88, 101, 242, .65);
}

.footer a:hover {
  color: var(--brand-2);
  border-bottom-color: currentColor;
}

:focus-visible {
  outline: 2px solid var(--brand-2);
  outline-offset: 3px;
}

.result-panel:focus-visible {
  outline-offset: 5px;
}

.reduced-motion *,
.reduced-motion *::before,
.reduced-motion *::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}

.reduced-motion.badge-labels-off .badge:hover,
.reduced-motion.badge-labels-off .badge:focus-visible,
.reduced-motion.badge-labels-off .badge:hover .badge-icon,
.reduced-motion.badge-labels-off .badge:focus-visible .badge-icon,
.reduced-motion .copyable:hover {
  transform: none;
}

.reduced-motion.badge-labels-off .badge:hover .badge-copy,
.reduced-motion.badge-labels-off .badge:focus-visible .badge-copy {
  transform: translate(-50%, 0);
}

@keyframes shimmer {
  to {
    transform: translateX(100%);
  }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes resultIn {
  from {
    opacity: .6;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes avatarArrival {
  0% {
    opacity: 0;
    transform: translateY(-46px) scale(.84) rotate(-7deg);
  }
  42% {
    opacity: 1;
    transform: translateY(9px) scale(1.08, .93) rotate(4deg);
  }
  62% {
    transform: translateY(-15px) scale(.96, 1.06) rotate(-2deg);
  }
  80% {
    transform: translateY(4px) scale(1.03, .98) rotate(1deg);
  }
  100% {
    opacity: 1;
    transform: translate(0) scale(1) rotate(0);
  }
}

@keyframes avatarSurprised {
  0%, 100% {
    transform: translate(0) scale(1) rotate(0);
  }
  12% {
    transform: translateY(5px) scale(1.08, .90) rotate(-2deg);
  }
  30% {
    transform: translateY(-38px) scale(.88, 1.14) rotate(7deg);
  }
  48% {
    transform: translateY(-25px) scale(.94, 1.08) rotate(-6deg);
  }
  68% {
    transform: translateY(4px) scale(1.08, .93) rotate(3deg);
  }
  84% {
    transform: translateY(-8px) scale(.98, 1.03) rotate(-1deg);
  }
}

@keyframes copiedPop {
  0% { opacity: 0; transform: translateY(-5px) scale(.82); }
  16%, 72% { opacity: 1; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(-3px) scale(.94); }
}

@keyframes copiedButtonPop {
  0% { opacity: 0; transform: translateY(100%); }
  12%, 84% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-100%); }
}

@keyframes logoGlow {
  0% {
    opacity: 0;
    transform: scale(.65);
  }
  42% {
    opacity: 1;
    transform: scale(1.08);
  }
  100% {
    opacity: 0;
    transform: scale(1.22);
  }
}

@keyframes logoSpyglass {
  0% {
    transform: translateX(0) rotate(-8deg) scale(1);
  }
  38% {
    transform: translateX(-8px) translateY(-3px) rotate(-22deg) scale(1.08);
  }
  70% {
    transform: translateX(3px) translateY(1px) rotate(-2deg) scale(.98);
  }
  100% {
    transform: translateX(0) rotate(-8deg) scale(1);
  }
}

@keyframes logoIdCard {
  0% {
    transform: translateX(0) rotate(8deg) scale(1);
  }
  38% {
    transform: translateX(8px) translateY(3px) rotate(22deg) scale(1.08);
  }
  70% {
    transform: translateX(-3px) translateY(-1px) rotate(2deg) scale(.98);
  }
  100% {
    transform: translateX(0) rotate(8deg) scale(1);
  }
}

/* v1.5 layout and input surfaces */
.intro {
  grid-area: intro;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 52px 0 26px;
}

.intro .eyebrow { display: flex; align-items: center; gap: 8px; color: var(--muted); }
.intro-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }
.intro h1 { margin: 16px 0; font-size: clamp(2rem, 4.8vw, 3.5rem); font-weight: 700; letter-spacing: -.055em; line-height: 1.12; }
.intro h1 span { color: var(--brand); }
.intro-description { margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.7; }
.intro-note { display: flex; align-items: center; gap: 18px; padding-right: 20px; }
.intro-note > span { color: var(--brand); font-size: 3.5rem; line-height: 1; }
.intro-note p { margin: 0; color: var(--dim); font-size: .8rem; line-height: 1.6; }
.search-panel { grid-area: search; }
.help-panel { grid-area: help; box-shadow: none; }
.panel-description { margin: 5px 0 0; color: var(--dim); font-size: .84rem; }
.panel-heading h2 { font-size: 1.45rem; letter-spacing: -.025em; }
.help-panel .panel-heading h2 { font-size: 1.05rem; }
.help-panel .eyebrow { color: var(--dim); }
.control-icon { flex: 0 0 18px; width: 18px; height: 18px; margin-right: 8px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.version-pill { gap: 8px; font-variant-numeric: tabular-nums; }
.version-pill > span { color: var(--dim); }
.nav-btn { gap: 12px; }
.nav-btn > span { color: var(--dim); }
.brand { min-height: 44px; }
.brand-title { font-size: 1.05rem; letter-spacing: -.02em; }
.brand-subtitle { font-size: .72rem; }
.avatar-anchor { width: 112px; height: 112px; border-radius: 50%; }
.avatar-wrap.is-tracking { will-change: transform; }
.media-banner--fallback::after { display: none; }
.profile-card .badge-icon { width: 24px; height: 24px; flex-basis: 24px; border-radius: 0; background: transparent; }
.profile-card .badge-img { width: 22px; height: 22px; }
.profile-card .activity-card, .profile-card .cosmetic-card { background: var(--profile-section); border-color: var(--profile-line); }
.profile-card .data-disclosure { border-color: var(--profile-line); }
.profile-card .action-btn { background: #41434a; color: #f2f3f5; border-color: transparent; border-radius: 8px; }
.profile-card .action-btn:hover { background: #4e5058; }
.profile-card .action-btn--share { background: #5865f2; }
.profile-card .action-btn--share:hover { background: #4752c4; }
:root[data-theme="light"] .profile-card .action-btn:not(.action-btn--share) { background: #e3e5e8; color: #232428; }
.avatar-presence { position: absolute; right: 2px; bottom: 2px; width: 28px; height: 28px; border: 5px solid var(--profile-surface); border-radius: 50%; background: #23a55a; }
.avatar-presence--idle { background: #f0b232; }
.avatar-presence--idle::after { content: ""; position: absolute; width: 11px; height: 11px; top: -2px; left: -2px; border-radius: 50%; background: var(--profile-surface); }
.avatar-presence--dnd { background: #f23f43; }
.avatar-presence--dnd::after { content: ""; position: absolute; width: 10px; height: 3px; left: 4px; top: 8px; border-radius: 2px; background: var(--profile-surface); }
.avatar-presence--offline { background: var(--profile-surface); box-shadow: inset 0 0 0 4px #80848e; }
.brand-title { overflow-wrap: anywhere; }

.identity-copy p { overflow-wrap: anywhere; }
.empty-state h2 { max-width: 400px; font-size: clamp(1.3rem, 2.5vw, 1.8rem); letter-spacing: -.035em; }
.empty-state p { max-width: 360px; font-size: .9rem; }
.empty-glyph { width: 66px; height: 66px; margin-bottom: 8px; font-family: ui-monospace, Consolas, monospace; font-size: 1.15rem; transform: rotate(-7deg); }
.raw-block pre { max-height: 28rem; overflow: auto; overscroll-behavior: contain; user-select: text; font-size: .78rem; line-height: 1.6; }
.raw-copy { -webkit-overflow-scrolling: touch; }
.meta-value, .api-field, .cosmetic-card, .activity-card, .feature-detail { overflow-wrap: anywhere; min-width: 0; }
.captcha-card { max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain; }
.footer { padding: 32px 24px calc(32px + env(safe-area-inset-bottom)); font-size: .72rem; }
.footer strong { color: var(--muted); font-weight: 600; }
.noscript-message { margin: 24px; padding: 16px; border: 1px solid var(--line); color: var(--text); text-align: center; }
.data-disclosure { border: 1px solid var(--line-soft); border-radius: var(--radius-sm); }
.data-disclosure > summary { display: flex; align-items: center; gap: 12px; padding: 12px; cursor: pointer; font-size: .8rem; font-weight: 700; list-style: none; }
.data-disclosure > summary::-webkit-details-marker { display: none; }
.data-disclosure > summary .chevron { margin-left: 2px; flex-shrink: 0; }
.disclosure-meta { margin-left: auto; font-size: .65rem; color: var(--dim); white-space: nowrap; font-weight: 500; }
.data-disclosure[open] > .api-grid, .data-disclosure[open] > .cosmetics-grid { padding: 0 12px 12px; }
button, a, summary, [role="button"] { touch-action: manipulation; }
summary { min-height: 44px; }
button.badge { color: inherit; font: inherit; text-align: left; }
.badge-labels-off .badge[aria-expanded="true"] { z-index: 25; }
.badge-labels-off .badge[aria-expanded="true"] .badge-copy { opacity: 1; visibility: visible; transform: translate(-50%, 0) scale(1); }
body:has(.captcha-layer:not([hidden])) .pointer-light { display: none; }

@media (min-width: 821px) and (max-width: 1080px) {
  .layout { grid-template-columns: 290px minmax(0, 1fr); gap: 16px; }
  .search-panel, .help-panel { padding: 20px; }
  .metrics-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .identity-block { gap: 16px; align-items: start; }

  .cosmetics-grid, .api-grid { grid-template-columns: minmax(0, 1fr); }
  .intro-note { padding-right: 0; }
}

@media (max-width: 820px) {
  html { scroll-padding-top: 16px; }
  .topbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; padding: 16px 24px; }
  .top-actions { grid-row: 2; grid-column: 1 / -1; justify-content: flex-start; margin-left: 0; }
  .quick-actions { grid-row: 1; grid-column: 2; }
  .layout, body.help-hidden .layout {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto;
    grid-template-areas: "intro" "search" "result" "help";
    max-width: 740px;
    padding: 0 24px 24px;
    gap: 18px;
  }
  body.help-hidden .layout { grid-template-areas: "intro" "search" "result"; }
  .intro { padding: 34px 0 14px; }
  .intro-note { display: none; }
  .search-row { grid-template-columns: minmax(0, 1fr) auto; }
  .search-row .primary-btn { min-width: 140px; }
  .search-panel, .help-panel { padding: 24px; }
  .utility-row { justify-content: flex-start; }
  .empty-state, .error-card, .result-panel { min-height: 380px; }
  .metrics-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .help-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .help-item { grid-template-columns: auto minmax(0, 1fr); }
  .help-item > span:last-child { grid-column: 1 / -1; }

}

@media (max-width: 520px) {
  .topbar { padding: 14px 16px; gap: 14px; }
  .brand { gap: 8px; }
  .brand-title { font-size: .98rem; }
  .top-actions { width: 100%; justify-content: flex-start; gap: 8px; }
  .version-pill, .nav-btn { min-height: 44px; padding: 0 11px; font-size: .72rem; }
  .layout, body.help-hidden .layout { padding: 0 max(12px, env(safe-area-inset-left)) 24px; gap: 14px; }
  .intro { padding: 28px 6px 12px; }
  .intro h1 { font-size: clamp(1.85rem, 8.1vw, 2.65rem); }
  .intro .eyebrow { font-size: .62rem; letter-spacing: .1em; }
  .intro-description { font-size: .86rem; }
  .desktop-break { display: none; }
  .search-panel, .help-panel { padding: 20px; }
  .search-shortcut { display: none; }
  .search-row { grid-template-columns: minmax(0, 1fr); }
  .primary-btn { min-height: 48px; }
  .profile-card { padding: 0 18px 18px; gap: 16px; }
  .media-banner { height: 160px; margin: 0 -18px; }
  .identity-block { grid-template-columns: minmax(0, 1fr); justify-items: start; text-align: left; gap: 12px; margin-top: -72px; }
  .identity-copy { width: 100%; padding: 4px 0; }
  .identity-copy h2 { font-size: 1.5rem; }
  .badge-strip { justify-content: flex-start; gap: 2px; }
  .cosmetics-grid, .api-grid { grid-template-columns: minmax(0, 1fr); }
  .meta-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meta-grid > .meta-cell:first-child, .meta-grid > .meta-cell:last-child { grid-column: 1 / -1; }
  .api-field { grid-template-columns: minmax(0, 1fr); }
  .meta-cell--split { grid-template-columns: minmax(0, 1fr); }
  .meta-actions { justify-content: flex-start; padding: 0 12px 12px; }
  .metric { padding: 12px; gap: 8px; min-height: 84px; }
  .metric strong { font-size: .86rem; }
  .metric > span { font-size: .62rem; letter-spacing: .04em; }
  .empty-state, .error-card { padding: 32px 20px; min-height: 340px; }
  .result-panel { min-height: 0; }
  .action-row .action-btn { flex: 1 1 calc(50% - 9px); white-space: normal; text-align: center; padding: 10px; }
  .settings-panel { right: max(12px, env(safe-area-inset-right)); top: 74px; }
  .captcha-layer { padding: 12px; }
  .captcha-card { padding: 18px; }
  .footer { justify-content: flex-start; gap: 8px; padding-inline: 20px; }
}

@media (max-width: 359px) {
  .top-actions { gap: 6px; }
  .version-pill, .nav-btn { padding-inline: 8px; font-size: .66rem; }
  .search-panel, .help-panel { padding: 16px; }
  .metrics-grid, .help-grid, .meta-grid { grid-template-columns: minmax(0, 1fr); }
  .action-row .action-btn { flex-basis: 100%; }
}

/* Touch users can read badge names without needing hover. */
@media (hover: none), (pointer: coarse) {
  .badge-labels-off .badge { width: auto; height: auto; min-height: 44px; max-width: 100%; padding: 6px 10px; transform: none; }
  .badge-labels-off .badge-copy { position: static; width: auto; max-width: 100%; padding: 0; border: 0; box-shadow: none; background: none; opacity: 1; visibility: visible; transform: none; white-space: normal; }
  .badge-labels-off .badge-copy::after { display: none; }
  .badge-labels-off .badge-detail { display: none; }
  .badge-labels-off .badge[aria-expanded="true"] .badge-copy { transform: none; }
  .badge-labels-off .badge[aria-expanded="true"] .badge-detail { display: block; }
  .badge-labels-off .badge:hover, .badge-labels-off .badge:focus-visible { transform: none; }
  .badge-labels-off .badge:hover .badge-icon, .badge-labels-off .badge:focus-visible .badge-icon { transform: none; }
  .nav-btn:hover, .ghost-btn:hover, .action-btn:hover, .copyable:hover, .recent-item:hover { transform: none; }
}

@media (hover: hover) and (pointer: fine) {
  .badge-labels-off .badge.is-dismissed .badge-copy { opacity: 0; visibility: hidden; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .pointer-light { display: none; }
}

@media (forced-colors: active) {
  .panel, .recent-item, .mode-btn, .primary-btn, .ghost-btn, .action-btn, .nav-btn, .round-btn, .settings-panel, .captcha-card, .badge { border: 1px solid CanvasText; }
  .intro h1 span { color: LinkText; }
  .pointer-light { display: none; }
  .status-dot, .color-swatch, .switch-ui::after { forced-color-adjust: none; }
}

@media print {
  .top-actions, .search-panel, .help-panel, .quick-actions, .settings-panel, .pointer-light, .action-row { display: none; }
  .layout { display: block; padding: 0; }
  .intro { padding: 16px 0; }
  .panel { box-shadow: none; }
}
