:root {
  color-scheme: dark;
  --bg: #0b0c0f;
  --surface: #151618;
  --surface-2: #1d1e21;
  --line: #2b2d31;
  --text: #f3f4ef;
  --muted: #a7aca2;
  --soft: #747a72;
  --accent: #45f0a5;
  --accent-2: #3bc7ff;
  --danger: #ff6b78;
  --good: #55e693;
  --shadow: 0 22px 80px rgba(0, 0, 0, 0.42);
  --radius: 8px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(69, 240, 165, 0.07), transparent 280px),
    var(--bg);
  color: var(--text);
}

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

a {
  color: inherit;
  text-decoration: none;
}

.hidden {
  display: none !important;
}

.app-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 48px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0 18px;
  background: rgba(11, 12, 15, 0.86);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.brand-logo {
  display: block;
  width: clamp(132px, 24vw, 210px);
  height: 42px;
  object-fit: contain;
  object-position: left center;
}

.main-nav,
.window-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line);
  background: rgba(21, 22, 24, 0.76);
  border-radius: var(--radius);
}

.nav-link,
.tab-button {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 6px;
  color: var(--muted);
  border: 0;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
}

.nav-link {
  display: inline-flex;
  align-items: center;
}

.nav-link.active,
.tab-button.active {
  color: var(--text);
  background: var(--surface-2);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.workspace {
  display: none;
}

.workspace.active {
  display: block;
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding: 34px 0 18px;
}

.page-head h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 0.95;
  letter-spacing: 0;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.metric-panel,
.panel,
.score-panel,
.rubric-item,
.streamer-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 22, 24, 0.92);
  box-shadow: var(--shadow);
}

.metric-panel {
  min-height: 112px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.metric-label,
.score-label,
label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.metric-value {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 42px;
  line-height: 1;
}

.panel {
  padding: 18px;
}

.panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.panel-head.compact {
  margin-bottom: 10px;
}

.panel-head h2,
.streamer-card h2,
.signed-in-panel h2 {
  margin: 0 0 4px;
  font-size: 18px;
}

.panel-head p,
.score-copy,
.rating-meta,
.streamer-card p,
.muted,
.status-block p {
  margin: 0;
  color: var(--muted);
}

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

.profile-actions .primary-button,
.profile-actions .text-button {
  min-height: 42px;
  width: auto;
  padding: 0 18px;
  border-radius: 999px;
  white-space: nowrap;
}

.profile-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 16px;
}

.profile-head > div:first-child {
  min-width: 0;
}

.profile-head h1 {
  overflow-wrap: anywhere;
}

.floating-live {
  position: fixed;
  top: 82px;
  right: max(16px, calc((100vw - 1180px) / 2));
  z-index: 30;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid color-mix(in srgb, var(--platform, var(--good)), transparent 38%);
  border-radius: 999px;
  background: color-mix(in srgb, var(--platform, var(--good)), transparent 82%);
  color: var(--platform, var(--good));
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(12px);
}

.icon-button,
.text-button,
.primary-button {
  min-height: 38px;
  border-radius: 6px;
  cursor: pointer;
}

.icon-button {
  width: 38px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--muted);
}

.text-button,
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
}

.text-button {
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text);
}

.primary-button {
  border: 0;
  background: var(--accent);
  color: #07100b;
  font-weight: 800;
}

.table-wrap {
  overflow-x: auto;
}

.rank-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  min-width: 560px;
}

.rank-table th,
.rank-table td {
  padding: 13px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

.rank-table th {
  color: var(--soft);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.rank-table th:nth-child(1),
.rank-table td:nth-child(1) {
  width: 7%;
  text-align: center;
}

.rank-table th:nth-child(2),
.rank-table td:nth-child(2) {
  width: 25%;
}

.rank-table th:nth-child(3),
.rank-table td:nth-child(3),
.rank-table th:nth-child(4),
.rank-table td:nth-child(4),
.rank-table th:nth-child(5),
.rank-table td:nth-child(5),
.rank-table th:nth-child(6),
.rank-table td:nth-child(6) {
  text-align: center;
}

.rank-table th:nth-child(3),
.rank-table td:nth-child(3) {
  width: 13%;
}

.rank-table th:nth-child(4),
.rank-table td:nth-child(4) {
  width: 12%;
}

.rank-table th:nth-child(5),
.rank-table td:nth-child(5) {
  width: 7%;
  padding-left: 4px;
  padding-right: 4px;
}

.rank-table th:nth-child(6),
.rank-table td:nth-child(6) {
  width: 15%;
}

.rank-table th:nth-child(7),
.rank-table td:nth-child(7) {
  width: 21%;
}

.rank-table tbody tr {
  cursor: pointer;
}

.rank-table tbody tr:hover {
  background: rgba(69, 240, 165, 0.05);
}

.rank-table small {
  display: block;
  margin-top: 3px;
  color: var(--soft);
}

.score-chip,
.status-badge,
.trend-badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  justify-content: center;
  border-radius: 6px;
  font-weight: 800;
}

.score-chip {
  min-width: 64px;
  color: #07100b;
  background: var(--accent);
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
}

.score-chip.unrated {
  min-width: 76px;
  border: 1px solid var(--line);
  color: var(--soft);
  background: rgba(255, 255, 255, 0.06);
  font-size: 12px;
}

.status-badge,
.trend-badge {
  padding: 0 10px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: var(--surface-2);
  font-size: 12px;
}

.trend-badge {
  min-width: 34px;
  gap: 4px;
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
}

.trend-badge.up {
  border-color: rgba(85, 230, 147, 0.45);
  color: var(--good);
  background: rgba(85, 230, 147, 0.08);
}

.trend-badge.down {
  border-color: rgba(255, 107, 107, 0.42);
  color: var(--bad);
  background: rgba(255, 107, 107, 0.08);
}

.trend-badge.steady {
  color: var(--soft);
}

.trend-badge.new {
  border-color: rgba(255, 204, 102, 0.42);
  color: var(--warn);
  background: rgba(255, 204, 102, 0.08);
}

.status-badge.live {
  border-color: rgba(85, 230, 147, 0.45);
  color: var(--good);
}

.status-link {
  text-decoration: none;
}

.status-link:hover {
  background: rgba(85, 230, 147, 0.12);
}

.status-badge.offline {
  color: var(--soft);
}

.profile-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
  margin-bottom: 14px;
}

.creator-card {
  min-height: 240px;
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 22, 24, 0.92);
  box-shadow: var(--shadow);
}

.profile-photo {
  width: 132px;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.profile-media {
  display: grid;
  gap: 10px;
}

.creator-copy {
  display: grid;
  gap: 12px;
}

.creator-status-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.creator-status-line > span:last-child {
  color: var(--muted);
  font-size: 13px;
}

.creator-bio,
.creator-schedule {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.creator-schedule {
  color: var(--text);
}

.score-panel {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 240px;
  padding: 22px;
}

.score-ring {
  width: 152px;
  aspect-ratio: 1;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, var(--surface) 58%, transparent 59%),
    conic-gradient(var(--accent) calc(var(--score) * 1%), rgba(255, 255, 255, 0.08) 0);
}

.score-ring span {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 44px;
  font-weight: 900;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 18px;
}

.stat-pill {
  min-height: 72px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
}

.stat-pill span,
.rating-score-preview span {
  color: var(--soft);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.stat-pill strong {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stream-panel {
  min-height: 240px;
}

.platform-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
  min-width: 0;
}

.platform-link {
  max-width: 100%;
  min-height: 32px;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  padding: 0 11px;
  border: 1px solid color-mix(in srgb, var(--platform), transparent 30%);
  border-radius: 999px;
  color: var(--platform);
  background: color-mix(in srgb, var(--platform), transparent 88%);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}

.rank-table .platform-links {
  gap: 6px;
  justify-content: flex-start;
}

.rank-table .platform-link {
  min-height: 28px;
  padding: 0 9px;
  font-size: 12px;
}

.no-link {
  color: var(--soft);
}

.status-block {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.category-bars {
  display: grid;
  gap: 12px;
}

.bar-row {
  display: grid;
  grid-template-columns: minmax(160px, 240px) minmax(120px, 1fr) 56px;
  align-items: center;
  gap: 12px;
}

.bar-label {
  color: var(--muted);
}

.bar-track {
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
}

.bar-value {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  text-align: right;
}

.rating-list {
  display: grid;
  gap: 10px;
}

.rating-row {
  min-height: 64px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
}

.rating-row strong {
  display: block;
  margin-bottom: 4px;
}

.rating-form {
  display: grid;
  gap: 14px;
}

.form-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 16px;
  align-items: stretch;
}

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

.streamer-form-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

label {
  display: grid;
  gap: 8px;
}

input,
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #101113;
  color: var(--text);
  outline: none;
}

textarea {
  min-height: 90px;
  padding: 12px;
  resize: vertical;
}

select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 18px,
    calc(100% - 12px) 18px;
  background-repeat: no-repeat;
  background-size: 6px 6px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(69, 240, 165, 0.13);
}

.rating-score-preview {
  min-height: 100%;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 16px;
  border: 1px solid rgba(69, 240, 165, 0.28);
  border-radius: 6px;
  background:
    linear-gradient(145deg, rgba(69, 240, 165, 0.13), rgba(59, 199, 255, 0.07)),
    var(--surface-2);
}

.rating-score-preview strong {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 48px;
  line-height: 1;
}

.rating-score-preview p {
  margin: 0;
  color: var(--muted);
  line-height: 1.35;
}

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

.rubric-item {
  min-height: 166px;
  padding: 16px;
}

.rubric-item legend {
  padding: 0 0 12px;
  font-size: 16px;
  font-weight: 800;
}

.score-options {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.score-options label {
  min-height: 74px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--muted);
  cursor: pointer;
}

.score-options input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  opacity: 0;
}

.option-value {
  color: var(--text);
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 20px;
  font-weight: 900;
}

.option-label {
  font-size: 11px;
  line-height: 1.2;
}

.score-options label:has(input:checked) {
  border-color: rgba(69, 240, 165, 0.7);
  background: rgba(69, 240, 165, 0.12);
  color: var(--text);
}

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

.search-panel {
  margin-bottom: 14px;
}

.streamer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.streamer-card {
  min-height: 260px;
  display: grid;
  gap: 14px;
  padding: 18px;
}

.streamer-card-head {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.streamer-card-head h2 {
  margin: 0 0 4px;
}

.streamer-card-head p {
  margin: 0;
  color: var(--muted);
}

.streamer-photo-link,
.streamer-name-link {
  color: inherit;
  text-decoration: none;
}

.streamer-photo-link {
  display: block;
  width: 58px;
  border-radius: 8px;
}

.streamer-photo-link:focus-visible,
.streamer-name-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.streamer-name-link:hover {
  color: var(--accent);
}

.streamer-live-link {
  color: var(--good);
  font-weight: 800;
  text-decoration: none;
}

.streamer-live-link:hover {
  text-decoration: underline;
}

.streamer-thumb {
  width: 58px;
  aspect-ratio: 1;
  display: block;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.streamer-card-snapshot {
  display: grid;
  grid-template-columns: minmax(92px, 0.45fr) minmax(0, 1fr);
  gap: 10px;
}

.streamer-card-score {
  min-height: 82px;
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
}

.streamer-card-score span,
.streamer-card-score small,
.rating-snapshot span,
.rating-snapshot small {
  color: var(--muted);
  font-size: 12px;
}

.streamer-card-score strong {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 34px;
  line-height: 1;
}

.rating-snapshot {
  min-height: 82px;
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
}

.snapshot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.snapshot-head > span,
.rating-snapshot > strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.snapshot-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.snapshot-nav {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  cursor: pointer;
}

.snapshot-nav:hover {
  border-color: rgba(57, 255, 136, 0.38);
  color: var(--accent);
}

.snapshot-value {
  display: flex;
  align-items: baseline;
  gap: 5px;
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
}

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

.snapshot-stats span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  white-space: nowrap;
}

.creator-editor {
  margin-bottom: 14px;
}

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

.wide-field {
  grid-column: 1 / -1;
}

.link-editor {
  display: grid;
  gap: 10px;
}

.link-editor > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.link-editor-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.platform-input span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.platform-swatch {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--platform);
  box-shadow: 0 0 14px color-mix(in srgb, var(--platform), transparent 48%);
}

.auth-gate {
  display: grid;
  gap: 8px;
  max-width: 520px;
  margin-bottom: 14px;
  padding: 16px;
  border: 1px solid rgba(255, 204, 102, 0.28);
  border-radius: var(--radius);
  background: rgba(255, 204, 102, 0.08);
}

.auth-gate p {
  margin: 0;
  color: var(--muted);
}

.compact-gate {
  max-width: none;
}

.disabled-block {
  opacity: 0.45;
  pointer-events: none;
}

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

.auth-card {
  display: grid;
  gap: 14px;
}

.account-dashboard {
  display: grid;
  gap: 14px;
}

.account-hero {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
}

.account-avatar {
  width: 58px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(57, 255, 136, 0.42);
  border-radius: 8px;
  background: rgba(57, 255, 136, 0.12);
  color: var(--accent);
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 26px;
  font-weight: 800;
}

.account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.account-identity {
  min-width: 0;
}

.account-identity h2 {
  margin: 0 0 4px;
  font-size: 28px;
}

.account-handle {
  margin: 0 0 4px;
  color: var(--accent);
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 13px;
}

.account-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.account-stat {
  min-height: 108px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.account-stat span,
.account-row p {
  margin: 0;
  color: var(--muted);
}

.account-stat strong {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 34px;
  line-height: 1;
}

.account-settings {
  max-width: 680px;
}

.account-list {
  display: grid;
  gap: 0;
}

.account-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.account-row:first-child {
  border-top: 0;
  padding-top: 0;
}

.account-row:last-child {
  padding-bottom: 0;
}

.account-row strong {
  display: block;
  margin-bottom: 4px;
}

.empty-state {
  padding: 20px;
  border: 1px dashed var(--line);
  border-radius: 6px;
  color: var(--muted);
  text-align: center;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 30;
  transform: translate(-50%, 16px);
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.modal-layer {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.66);
  backdrop-filter: blur(12px);
}

.modal-card {
  width: min(560px, 100%);
  max-height: min(86vh, 920px);
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.large-modal {
  width: min(1000px, 100%);
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.modal-head h2 {
  margin: 0;
  font-size: 26px;
}

.modal-form-panel {
  margin-bottom: 14px;
}

.modal-rating-summary {
  margin-bottom: 14px;
}

.claim-form {
  display: grid;
  gap: 14px;
}

@media (max-width: 920px) {
  .streamer-form-grid,
  .streamer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .link-editor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .app-shell {
    width: min(100% - 22px, 760px);
    padding-top: 12px;
  }

  .topbar,
  .page-head:not(.profile-head),
  .signed-in-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .main-nav,
  .window-tabs {
    overflow-x: auto;
  }

  .rank-table {
    min-width: 560px;
  }

  .rank-table th,
  .rank-table td {
    padding: 12px 9px;
  }

  .metric-grid,
  .profile-layout,
  .creator-card,
  .form-panel,
  .form-grid,
  .creator-form-grid,
  .streamer-form-grid,
  .streamer-grid,
  .account-panel,
  .account-stats,
  .rubric-list {
    grid-template-columns: 1fr;
  }

  .score-panel {
    min-height: auto;
    align-items: flex-start;
  }

  .profile-actions {
    align-items: center;
    justify-content: flex-start;
    margin-left: 0;
  }

  .profile-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
  }

  .floating-live {
    top: 16px;
    right: 16px;
  }

  .bar-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .bar-value {
    text-align: left;
  }
}

@media (max-width: 560px) {
  .link-editor-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .profile-head {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .profile-actions {
    justify-content: flex-start;
  }

  .page-head h1 {
    font-size: 38px;
  }

  .score-panel {
    flex-direction: column;
  }

  .creator-card {
    grid-template-columns: 1fr;
  }

  .score-options {
    grid-template-columns: repeat(5, minmax(58px, 1fr));
    overflow-x: auto;
  }

  .rank-table {
    min-width: 540px;
  }

  .rank-table th,
  .rank-table td {
    padding: 11px 8px;
  }

  .account-hero,
  .account-row {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .account-hero .text-button,
  .account-row .text-button {
    width: 100%;
  }

  .profile-stats {
    grid-template-columns: 1fr;
  }
}
