:root {
  --bg: #0b0b0c;
  --bg-elevated: #141416;
  --bg-card: rgba(24, 24, 27, 0.82);
  --border: rgba(255, 255, 255, 0.08);
  --text: #f4f4f5;
  --muted: #a1a1aa;
  --accent: #3b82f6;
  --accent-soft: rgba(59, 130, 246, 0.18);
  --danger: #ef4444;
  --ok: #22c55e;
  --radius: 14px;
  --font: "Segoe UI", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --page-pad: clamp(1rem, 2.5vw, 2rem);
}

* { box-sizing: border-box; }

[hidden] {
  display: none !important;
}

html {
  min-height: 100%;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
}

html::-webkit-scrollbar {
  width: 8px;
}

html::-webkit-scrollbar-track {
  background: transparent;
}

html::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.14);
  border-radius: 999px;
}

html::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.24);
}

body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  position: relative;
}

body.page-home {
  min-height: 100vh;
  overflow-x: hidden;
}

body.page-app {
  min-height: 100vh;
  overflow-x: hidden;
}

.bg-scene {
  pointer-events: none;
  position: fixed;
  inset: 0;
  background:
    url("/assets/hero-bg.jpg") center center / cover no-repeat;
  z-index: 0;
}

.bg-overlay {
  pointer-events: none;
  position: fixed;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 8, 10, 0.72) 0%, rgba(8, 8, 10, 0.88) 45%, rgba(8, 8, 10, 0.94) 100%),
    radial-gradient(ellipse at 50% 0%, rgba(59, 130, 246, 0.12), transparent 55%);
  z-index: 0;
}

.nav, .hero, .app-main, .gate {
  position: relative;
  z-index: 1;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem var(--page-pad);
}

.nav-full {
  width: 100%;
  max-width: none;
  margin: 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
}

.brand-logo {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.55rem;
  object-fit: cover;
  flex-shrink: 0;
}

.brand-name {
  font-weight: 650;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.nav-pill {
  text-decoration: none;
  color: #fff;
  background: var(--accent-soft);
  border: 1px solid rgba(59, 130, 246, 0.35);
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 550;
}

.nav-pill.active {
  background: rgba(59, 130, 246, 0.28);
  color: #fff;
}

.nav-link {
  color: #f4f4f5;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 550;
}

.nav-link:hover { color: #fff; }

.user-chip {
  color: #f4f4f5;
  font-size: 0.85rem;
  font-weight: 550;
  padding: 0.35rem 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
}

.account-menu {
  position: relative;
}

.account-menu-btn {
  cursor: pointer;
  font: inherit;
  line-height: inherit;
}

.account-menu-panel {
  position: absolute;
  top: calc(100% + 0.45rem);
  right: 0;
  z-index: 40;
  min-width: min(18rem, calc(100vw - 2rem));
  padding: 0.85rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(12, 16, 24, 0.96);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  display: grid;
  gap: 0.85rem;
}

.account-menu-section {
  display: grid;
  gap: 0.35rem;
}

.account-menu-section + .account-menu-section {
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.account-menu-label {
  margin: 0;
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.account-menu-value {
  margin: 0;
  color: #f8fafc;
  font-size: 0.92rem;
  font-weight: 550;
  line-height: 1.35;
  word-break: break-word;
}

.account-menu-action {
  justify-self: start;
  margin-top: 0.15rem;
  color: #93c5fd;
  font-size: 0.85rem;
  font-weight: 550;
  text-decoration: none;
}

.account-menu-action:hover {
  color: #bfdbfe;
}

.account-menu-action-btn {
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.apply-notes {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.apply-read-by-box {
  margin-top: 0.65rem;
  padding: 0.6rem 0.75rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
}

.apply-read-by-label {
  margin: 0 0 0.35rem;
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.apply-read-by-panel {
  padding: 0.65rem 0.8rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
}

.apply-read-by-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.35rem;
}

.apply-read-by-list li {
  color: #f8fafc;
  font-size: 0.92rem;
  line-height: 1.35;
}

.apply-read-by-list-compact li {
  font-size: 0.84rem;
}

.apply-read-by-name {
  font-weight: 550;
}

.apply-read-by-time {
  color: #94a3b8;
  font-size: 0.82rem;
}

.apply-read-by-empty {
  margin: 0;
}

.apply-note-item {
  position: relative;
  padding: 0.65rem 0.8rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  font-size: 1rem;
}

.apply-note-item-own {
  padding-right: 4.35rem;
}

.apply-note-meta {
  margin: 0 0 0.28rem;
  color: #94a3b8;
  font-size: 0.82rem;
  line-height: 1.3;
}

.apply-note-delete.btn {
  position: absolute;
  top: 0.5rem;
  right: 0.55rem;
  padding: 0.12rem 0.42rem;
  font-size: 0.72rem;
  line-height: 1.15;
  min-height: 0;
  font-weight: 600;
}

.apply-note-body {
  margin: 0;
  color: #f8fafc;
  font-size: 1rem;
  line-height: 1.4;
  white-space: pre-wrap;
}

.apply-note-compose {
  display: grid;
  gap: 0.55rem;
  margin-top: 0.85rem;
}

.apply-note-compose label {
  color: #cbd5e1;
  font-size: 0.92rem;
  font-weight: 550;
}

.apply-note-compose textarea {
  min-height: 6.5rem;
  resize: vertical;
}

.apply-note-actions {
  margin-top: 0.35rem;
}

.hero {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: clamp(2rem, 8vh, 5rem) var(--page-pad) 2rem;
}

.eyebrow {
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  margin: 0 0 0.85rem;
}

.home-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  min-height: calc(100vh - 4.5rem);
  padding: clamp(1.5rem, 4vh, 3rem) var(--page-pad) 1.5rem;
  display: flex;
  flex-direction: column;
  gap: clamp(1.5rem, 3vh, 2.5rem);
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: center;
  flex: 1;
}

.home-hero-copy {
  max-width: 44rem;
}

.home-lede {
  font-size: clamp(1rem, 1.6vw, 1.12rem);
  max-width: 36rem;
}

.home-preview {
  justify-self: end;
  width: min(100%, 26rem);
}

.preview-card {
  background: rgba(18, 18, 22, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: calc(var(--radius) + 2px);
  padding: 1.35rem 1.25rem;
  backdrop-filter: blur(14px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}

.preview-head {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.preview-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.55);
}

.preview-title {
  font-size: 0.82rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #d4d4d8;
}

.preview-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.preview-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0.85rem;
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.92rem;
}

.preview-list span {
  color: var(--muted);
}

.preview-list strong {
  font-weight: 650;
  color: #fff;
}

.preview-foot {
  margin: 1rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.45;
}

.home-info {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 1.25rem;
  backdrop-filter: blur(10px);
}

.info-label {
  margin: 0 0 0.45rem;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.info-card h2 {
  margin: 0 0 0.55rem;
  font-size: 1.08rem;
  letter-spacing: -0.02em;
}

.info-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.55;
}

.home-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  color: #71717a;
  font-size: 0.82rem;
}

h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1.05;
  margin: 0 0 1rem;
  letter-spacing: -0.03em;
}

.lede {
  max-width: 40rem;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.55;
  margin: 0 0 1.5rem;
}

.lede.tight { margin-bottom: 0; }

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.7rem 1.15rem;
  font-weight: 650;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
}

.btn-primary {
  background: #fff;
  color: #0b0b0c;
}

.btn-primary:hover { filter: brightness(0.95); }

.btn-muted {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.72);
  cursor: default;
  pointer-events: none;
}

.btn-ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
}

.btn-ghost:hover { background: rgba(255, 255, 255, 0.05); }

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.error {
  margin-top: 1rem;
  color: #fca5a5;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  max-width: 40rem;
}

.app-main {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0.5rem var(--page-pad) 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.section-head {
  margin-bottom: 0.25rem;
}

.section-head.quota-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.panel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem;
}

.panel-grid-moderation {
  align-items: stretch;
}

.panel-grid-moderation > .panel:not(.panel-wide) {
  height: 100%;
}

.panel-grid-moderation #ban-form .btn-primary,
.panel-grid-moderation #unban-form .btn {
  margin-top: auto;
}

.panel {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

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

.panel h2 {
  margin: 0 0 0.25rem;
  font-size: 1.1rem;
  flex-shrink: 0;
}

label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.85rem;
}

input, select, textarea {
  background: rgba(15, 15, 18, 0.85);
  border: 1px solid var(--border);
  border-radius: 0.7rem;
  color: var(--text);
  padding: 0.65rem 0.75rem;
  font: inherit;
}

textarea {
  min-height: 5rem;
  resize: vertical;
  line-height: 1.45;
}

input:focus, select:focus, textarea:focus {
  outline: 2px solid rgba(59, 130, 246, 0.45);
  outline-offset: 1px;
}

.row {
  display: flex;
  gap: 0.75rem;
  align-items: end;
}

.grow { flex: 1; }

.form-msg {
  min-height: 1.25rem;
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.form-msg.ok { color: var(--ok); }
.form-msg.err { color: #fca5a5; }

.lookup-results {
  margin-top: 0.5rem;
  display: grid;
  gap: 0.75rem;
}

.result-card {
  background: rgba(16, 16, 20, 0.88);
  border: 1px solid var(--border);
  border-radius: 0.9rem;
  padding: 1rem;
}

.result-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.meta {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

.tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.45rem;
  border-radius: 0.4rem;
  background: var(--accent-soft);
  color: #93c5fd;
  margin-right: 0.35rem;
}

.tag.warn {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}

.tag.bad {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
}

.tag.terminated {
  background: rgba(168, 85, 247, 0.18);
  color: #e9d5ff;
}

.infraction-row.terminated {
  border-color: rgba(168, 85, 247, 0.28);
}

.quota-sub.terminated-text {
  color: #e9d5ff;
  font-weight: 600;
}

.history-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
}

.history-list li {
  padding: 0.65rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}

.pager {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.gate {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  color: var(--muted);
  background: rgba(8, 8, 10, 0.88);
  backdrop-filter: blur(8px);
}

.gate[hidden] {
  display: none !important;
}

.quota-summary {
  display: flex;
  gap: 0.85rem;
  position: relative;
  z-index: 0;
  isolation: isolate;
}

.quota-summary .stat-card {
  flex: 1 1 0;
  min-width: 0;
  backdrop-filter: none;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  backdrop-filter: blur(10px);
}

.stat-label {
  margin: 0 0 0.35rem;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.stat-value {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.account-panel {
  margin-top: 1rem;
}

.account-linked-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius);
  border: 1px solid rgba(34, 197, 94, 0.35);
  background: rgba(34, 197, 94, 0.08);
  color: #bbf7d0;
}

.account-linked-banner p {
  margin: 0;
}

.btn-danger {
  border-color: rgba(239, 68, 68, 0.45);
  color: #fecaca;
}

.btn-danger:hover {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.65);
}

.link-code-box {
  margin: 0.85rem 0;
  padding: 0.85rem;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
}

.link-code {
  margin: 0.25rem 0 0.5rem;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.account-history {
  display: grid;
  gap: 0.65rem;
}

.account-history-row {
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
}

.account-status {
  display: inline-block;
  margin-left: 0.45rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 650;
  text-transform: uppercase;
}

.account-status-pending {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}

.account-status-approved {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
}

.account-status-paid {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
}

.account-status-returned {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
}

.account-status-denied {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.stat-value.stat-small {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.4;
}

.stat-value.stat-quota-target {
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
}

.quota-error {
  margin-bottom: 0.75rem;
}

.apply-form label:not(.apply-choice),
.apply-fieldset label:not(.apply-choice) {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
  font-size: 0.88rem;
}

.apply-fieldset {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  margin: 0 0 1rem;
}

.apply-fieldset legend {
  padding: 0 0.35rem;
  font-weight: 600;
}

.apply-intro {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.55;
}

.apply-edit-notice {
  margin-top: 0.65rem;
  color: #fcd34d;
}

.apply-connect-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.apply-connect-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 1.15rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.apply-connect-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
}

.apply-connect-btn img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  object-fit: contain;
}

.apply-connect-btn img.apply-connect-icon-roblox {
  width: 32px;
  height: 32px;
  padding: 1px;
}

.apply-connect-btn-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.apply-connect-btn-done {
  border-color: rgba(34, 197, 94, 0.45);
  background: rgba(34, 197, 94, 0.1);
  color: var(--ok);
  pointer-events: none;
  cursor: default;
}

.apply-connect-btn-done-roblox {
  border-color: rgba(59, 130, 246, 0.55);
  background: rgba(59, 130, 246, 0.14);
  color: #60a5fa;
  pointer-events: none;
  cursor: default;
}

.apply-connect-btn-disabled {
  opacity: 0.55;
  pointer-events: none;
  cursor: not-allowed;
}

.apply-edit-banner {
  margin-bottom: 0.75rem;
}

.char-count {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.78rem;
  color: var(--muted);
  text-align: right;
}

.char-count-ok { color: var(--ok); }

.apply-fieldset textarea,
.apply-fieldset input[type="text"],
.apply-fieldset select {
  width: 100%;
  box-sizing: border-box;
}

.apply-fieldset .quota-meta.tight {
  margin: 0.25rem 0 0;
}

.apply-choice-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-top: 0.65rem;
}

.apply-choice-list-horizontal {
  flex-direction: row;
  flex-wrap: wrap;
}

label.apply-choice,
label.apply-checkbox {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 0;
  padding: 0.6rem 0.85rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid transparent;
  cursor: pointer;
  user-select: none;
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.35;
  transition: background 0.15s ease, border-color 0.15s ease;
}

label.apply-choice:hover,
label.apply-checkbox:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.06);
}

label.apply-choice:has(input:checked) {
  background: rgba(88, 101, 242, 0.12);
  border-color: rgba(88, 101, 242, 0.45);
}

label.apply-checkbox:has(input:checked) {
  background: rgba(88, 101, 242, 0.1);
  border-color: rgba(88, 101, 242, 0.35);
}

.apply-choice input[type="radio"],
.apply-checkbox input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  width: 18px;
  height: 18px;
  min-width: 18px;
  min-height: 18px;
  max-width: 18px;
  max-height: 18px;
  margin: 0;
  padding: 0;
  flex: 0 0 18px;
  align-self: center;
  border: 2px solid rgba(255, 255, 255, 0.35);
  background: rgba(0, 0, 0, 0.25);
  display: block;
  line-height: 1;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.apply-choice input[type="radio"] {
  border-radius: 50%;
  aspect-ratio: 1;
}

.apply-checkbox input[type="checkbox"] {
  border-radius: 0.32rem;
}

.apply-choice input[type="radio"]:checked {
  border-color: #5865f2;
  background: #5865f2;
  box-shadow: inset 0 0 0 3px rgba(8, 10, 18, 0.85);
}

.apply-checkbox input[type="checkbox"]:checked {
  border-color: #5865f2;
  background-color: #5865f2;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10'%3E%3Cpath fill='none' stroke='white' stroke-width='2' d='M1 5l3 3 7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 0.65rem;
}

.apply-choice input:focus-visible,
.apply-checkbox input:focus-visible {
  outline: 2px solid rgba(88, 101, 242, 0.65);
  outline-offset: 2px;
}

.apply-evidence-queue {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.apply-evidence-queue-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.65rem;
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.88rem;
}

.apply-evidence-queue-meta {
  color: var(--muted);
  font-size: 0.78rem;
  white-space: nowrap;
}

.apply-evidence-queue-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.apply-file-input {
  width: 100%;
  box-sizing: border-box;
  padding: 0.65rem 0.75rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px dashed rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.2);
  color: var(--muted);
  font-size: 0.88rem;
}

.apply-file-input::file-selector-button {
  margin-right: 0.75rem;
  padding: 0.45rem 0.85rem;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
}

.apply-other-field {
  margin-top: 0.65rem;
}

.submissions-main {
  width: 100%;
  max-width: 88rem;
  margin-inline: auto;
  padding-bottom: 2.5rem;
}

.submissions-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.apply-stats-banner {
  margin-bottom: 0.85rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.03);
}

.apply-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem 1rem;
  min-width: 0;
}

.apply-stats-item {
  font-size: 0.88rem;
  color: var(--text);
}

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

.apply-stats-total {
  grid-column: 1 / -1;
  padding-top: 0.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.apply-detail-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  justify-content: flex-end;
}

.confirm-dialog,
.apply-delete-dialog {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #111827;
  color: var(--text);
  padding: 0;
  max-width: min(92vw, 26rem);
}

.confirm-dialog::backdrop,
.apply-delete-dialog::backdrop {
  background: rgba(0, 0, 0, 0.65);
}

.confirm-dialog-inner,
.apply-delete-dialog-inner {
  padding: 1.1rem 1.15rem;
}

.confirm-dialog-inner h3,
.apply-delete-dialog-inner h3 {
  margin: 0 0 0.45rem;
}

.confirm-dialog-inner p,
.apply-delete-dialog-inner p {
  margin: 0 0 0.85rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.confirm-dialog-destructive,
.apply-delete-confirm-btn {
  background: #dc2626 !important;
  color: #ffffff !important;
  border: 1px solid #f87171 !important;
  font-weight: 700;
  box-shadow: 0 0 0 1px rgba(248, 113, 113, 0.35);
}

.confirm-dialog-destructive:hover,
.apply-delete-confirm-btn:hover {
  background: #b91c1c !important;
  border-color: #fca5a5 !important;
  color: #ffffff !important;
}

.submissions-review-layout {
  min-width: 0;
}

.submissions-list-panel {
  margin-bottom: 0.75rem;
  min-width: 0;
}

.submissions-list-dimmed {
  opacity: 0.45;
  pointer-events: none;
}

.submissions-list-head {
  margin-bottom: 0.65rem;
}

.submissions-list-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.25rem;
}

.submissions-list-title {
  margin: 0;
  font-size: 1rem;
}

.submissions-sort-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.submissions-sort-text {
  font-size: 0.72rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.submissions-sort-select {
  min-width: 7.5rem;
  padding: 0.32rem 0.5rem;
  font-size: 0.78rem;
}

.submissions-list-hint {
  margin: 0;
  font-size: 0.78rem;
}

.submissions-list-scroll {
  min-height: 0;
  min-width: 0;
  overflow-x: hidden;
}

.submissions-list-scroll.quota-list {
  gap: 0.35rem;
}

.submissions-list-scroll .apply-submission-row {
  padding: 0.65rem 0.85rem;
  min-width: 0;
}

.apply-submission-card {
  display: grid;
  gap: 0.45rem;
  min-width: 0;
}

.apply-submission-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem 0.75rem;
  align-items: start;
}

.apply-submission-card-name-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.55rem;
  min-width: 0;
}

.apply-submission-card-name {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 650;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
  word-break: break-word;
}

.apply-submission-card-sub {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.4;
  white-space: normal;
  overflow-wrap: anywhere;
}

.submissions-list-scroll .apply-status-pill {
  font-size: 0.76rem;
  white-space: nowrap;
  line-height: 1.25;
  flex-shrink: 0;
}

.apply-submission-read-line {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.4;
  white-space: normal;
  overflow-wrap: anywhere;
}

.apply-submission-card-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.3rem;
  flex-shrink: 0;
}

.submissions-list-scroll .apply-dm-list-btn,
.submissions-list-scroll .apply-delete-list-btn {
  flex-shrink: 0;
  font-size: 0.72rem;
  padding: 0.2rem 0.5rem;
}

.apply-submission-row {
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.apply-submission-row:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.apply-submission-row-active {
  border-color: rgba(96, 165, 250, 0.55);
  background: rgba(59, 130, 246, 0.08);
  box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.2);
}

.apply-detail-panel {
  margin-top: 0.75rem;
  padding: 1.1rem 1.15rem;
  min-width: 0;
}

.apply-detail-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 12rem;
  padding: 2rem 1rem;
  color: var(--muted);
  text-align: center;
}

.apply-detail-empty p {
  margin: 0;
  font-size: 0.95rem;
  max-width: 18rem;
  line-height: 1.45;
}

@media (min-width: 960px) {
  .submissions-review-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1rem;
    align-items: stretch;
  }

  .submissions-list-panel,
  .apply-detail-panel {
    min-width: 0;
    max-height: calc(100vh - 6rem);
  }

  .submissions-list-panel {
    position: sticky;
    top: 5.5rem;
    display: flex;
    flex-direction: column;
    margin-bottom: 0;
    overflow: hidden;
  }

  .submissions-list-scroll {
    overflow-y: auto;
    flex: 1;
    padding-right: 0.2rem;
  }

  .apply-detail-panel {
    margin-top: 0;
    overflow-y: auto;
  }

  .apply-detail-empty {
    min-height: calc(100vh - 9rem);
  }

  .apply-detail-head-actions .btn {
    font-size: 0.78rem;
    padding: 0.35rem 0.55rem;
  }

  .apply-stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 959px) {
  .apply-detail-panel:not(.apply-detail-panel-open) {
    display: none;
  }
}

.apply-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.85rem;
  margin-bottom: 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.apply-detail-head-text {
  min-width: 0;
}

.apply-detail-head h2 {
  margin: 0;
  font-size: 1.25rem;
  line-height: 1.25;
}

.apply-detail-meta {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.apply-accounts {
  display: grid;
  gap: 0.65rem;
}

.apply-account-card {
  padding: 0.75rem 0.85rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-account-label {
  margin: 0 0 0.2rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.apply-account-value {
  margin: 0 0 0.55rem;
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.35;
}

.apply-account-meta {
  display: grid;
  gap: 0.4rem;
  margin: 0;
}

.apply-account-meta div {
  display: grid;
  grid-template-columns: 5.5rem minmax(0, 1fr);
  gap: 0.5rem;
  align-items: baseline;
}

.apply-account-meta dt {
  margin: 0;
  font-size: 0.76rem;
  color: var(--muted);
}

.apply-account-meta dd {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.45;
  word-break: break-word;
}

.apply-account-meta code {
  font-size: 0.78rem;
}

.apply-detail-section + .apply-detail-section {
  margin-top: 1.15rem;
  padding-top: 1.15rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-section-title {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.apply-metrics-group + .apply-metrics-group {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-metrics-group-title {
  margin: 0 0 0.65rem;
  font-size: 0.82rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.apply-context-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}

.apply-metrics-group .apply-context-stats {
  margin-bottom: 0;
}

.apply-stat {
  padding: 0.65rem 0.7rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-stat-label {
  margin: 0 0 0.25rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.apply-stat-value {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.35;
}

.apply-ban-wrap {
  padding: 0.75rem 0.85rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.apply-ban-title {
  margin: 0 0 0.5rem;
  font-size: 0.82rem;
  font-weight: 600;
}

.apply-ban-history {
  margin: 0;
  padding-left: 1.1rem;
  line-height: 1.5;
  font-size: 0.84rem;
}

.apply-ban-empty {
  margin: 0;
  font-size: 0.84rem;
  color: var(--muted);
}

.apply-response-group + .apply-response-group {
  margin-top: 1rem;
}

.apply-response-group-title {
  margin: 0 0 0.55rem;
  font-size: 0.92rem;
  font-weight: 600;
}

.apply-response-list {
  display: grid;
  gap: 0.65rem;
}

.apply-answer-block {
  padding: 0.75rem 0.85rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-question {
  margin: 0 0 0.55rem;
  font-size: 0.86rem;
  font-weight: 600;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.92);
}

.apply-answer-body {
  margin: 0;
  padding: 0.65rem 0.75rem;
  border-radius: 0.5rem;
  background: rgba(0, 0, 0, 0.22);
  font-size: 0.86rem;
  line-height: 1.6;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
}

.apply-answer-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
}

.apply-answer-pill-yes {
  color: #86efac;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.apply-answer-pill-no {
  color: #fca5a5;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.22);
}

.apply-submission-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}

.apply-submission-row button {
  flex-shrink: 0;
}

.apply-status-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.apply-status-pending {
  color: #fde68a;
  background: rgba(234, 179, 8, 0.12);
  border-color: rgba(234, 179, 8, 0.25);
}

.apply-status-backup {
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.25);
}

.apply-status-considering {
  color: #c4b5fd;
  background: rgba(139, 92, 246, 0.12);
  border-color: rgba(139, 92, 246, 0.25);
}

.apply-status-needs_further_review {
  color: #fdba74;
  background: rgba(249, 115, 22, 0.12);
  border-color: rgba(249, 115, 22, 0.25);
}

.apply-status-denied {
  color: #fca5a5;
  background: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.22);
}

.apply-status-accepted {
  color: #86efac;
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.25);
}

.apply-status-panel {
  display: grid;
  gap: 0.75rem;
}

.apply-status-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-status-reason {
  margin: 0;
  padding: 0.65rem 0.75rem;
  border-radius: 0.55rem;
  background: rgba(0, 0, 0, 0.22);
  font-size: 0.84rem;
  line-height: 1.55;
}

.apply-status-updated {
  margin: 0;
}

.apply-status-reason-input {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.apply-status-reason-input textarea {
  min-height: 4.5rem;
  resize: vertical;
}

.apply-status-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.apply-status-btn.active-choice {
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

@media (max-width: 640px) {
  .apply-context-stats {
    grid-template-columns: 1fr;
  }
}

.quota-panel {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.quota-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.quota-panel-head h2 {
  margin: 0;
  font-size: 1.1rem;
}

.quota-meta {
  color: var(--muted);
  font-size: 0.85rem;
}

.quota-search {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.quota-search input {
  width: 100%;
  max-width: 20rem;
  padding: 0.5rem 0.7rem;
  font-size: 0.88rem;
}

.quota-empty,
.quota-empty-inline {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.55;
}

.quota-empty p,
.quota-empty-inline {
  margin: 0;
}

.ticket-quota-panel {
  margin-top: 1rem;
  position: relative;
  z-index: 1;
  isolation: isolate;
}

.ticket-quota-panel .quota-panel-head {
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.5rem 1rem;
  position: relative;
  z-index: 2;
  margin-bottom: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: var(--bg-card);
}

.ticket-quota-panel .quota-panel-head h2 {
  flex: 0 0 auto;
}

.ticket-quota-panel .quota-meta {
  flex: 1 1 12rem;
  text-align: right;
  line-height: 1.45;
}

.ticket-quota-panel.is-loading .quota-list {
  opacity: 0.55;
  pointer-events: none;
}

.ticket-quota-note {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  position: relative;
  z-index: 1;
}

.ticket-quota-note code {
  font-size: 0.72rem;
}

.quota-list {
  display: grid;
  gap: 0.4rem;
}

.quota-row-expandable .quota-row-toggle {
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
}

.quota-row-expandable.is-open .quota-row-toggle h3 {
  color: var(--accent, #7eb6ff);
}

.quota-row-details {
  margin-top: 0.55rem;
  padding-top: 0.55rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.quota-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: 0.45rem 1rem;
  margin: 0 0 0.35rem;
}

.quota-details-grid dt {
  font-size: 0.72rem;
  opacity: 0.72;
  margin: 0;
}

.quota-details-grid dd {
  margin: 0.1rem 0 0;
  font-size: 0.88rem;
  font-weight: 600;
}

.quota-row {
  padding: 0.5rem 0.7rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.quota-row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.ticket-quota-row .quota-row-top {
  align-items: flex-start;
}

.quota-row-info {
  min-width: 0;
}

.quota-row h3 {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.quota-sub {
  margin: 0.1rem 0 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.2;
}

.quota-percent {
  font-size: 0.82rem;
  font-weight: 700;
  color: #93c5fd;
  white-space: nowrap;
  flex-shrink: 0;
}

.quota-percent.complete {
  color: var(--ok);
}

.quota-percent.strike {
  color: #f87171;
}

.quota-percent.warning {
  color: #fbbf24;
}

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

.quota-bar-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.85), rgba(96, 165, 250, 0.95));
  transition: width 0.35s ease;
}

.quota-bar-fill.complete {
  background: linear-gradient(90deg, rgba(34, 197, 94, 0.85), rgba(74, 222, 128, 0.95));
}

.infractions-issue {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.infractions-issue h2 {
  margin: 0;
  font-size: 1.1rem;
}

.app-main-narrow {
  width: min(100%, 56rem);
  margin-inline: auto;
}

.infractions-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  align-items: end;
}

.infractions-form .btn-primary {
  justify-self: start;
}

.infractions-form .checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  cursor: pointer;
  user-select: none;
}

.infractions-form .checkbox-label input[type="checkbox"] {
  margin-top: 0.2rem;
  flex-shrink: 0;
}

.infractions-form .checkbox-label span {
  line-height: 1.45;
}

.transcript-main {
  width: min(100%, 52rem);
  margin-inline: auto;
}

.transcript-panel {
  min-height: 12rem;
}

.transcript-state {
  padding: 1rem 0;
}

.transcript-head {
  margin-bottom: 1rem;
}

.transcript-head h1 {
  margin: 0 0 0.35rem;
}

.transcript-messages {
  display: grid;
  gap: 0.65rem;
}

.transcript-msg {
  padding: 0.65rem 0.75rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.transcript-msg.bot {
  border-color: rgba(59, 130, 246, 0.25);
}

.transcript-msg-head {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: baseline;
  margin-bottom: 0.35rem;
  font-size: 0.92rem;
}

.transcript-msg-head span {
  color: var(--muted);
  font-size: 0.82rem;
}

.transcript-msg-body {
  white-space: pre-wrap;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.transcript-msg-body a {
  color: var(--accent);
}

.transcript-msg-empty {
  color: var(--muted);
  font-style: italic;
}

.transcript-mention {
  color: #c4d7ff;
  background: rgba(88, 101, 242, 0.18);
  border-radius: 0.25rem;
  padding: 0 0.2rem;
}

.transcript-inline-code,
.transcript-code-block code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88em;
}

.transcript-inline-code {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 0.25rem;
  padding: 0.05rem 0.3rem;
}

.transcript-code-block {
  margin: 0.35rem 0 0;
  padding: 0.55rem 0.65rem;
  border-radius: 0.45rem;
  background: rgba(0, 0, 0, 0.35);
  overflow-x: auto;
}

.transcript-attachments {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.45rem;
}

.transcript-attachments a {
  color: var(--accent);
  font-size: 0.9rem;
}

.transcript-attachment-image,
.transcript-embed-image,
.transcript-embed-thumb {
  display: block;
  max-width: min(100%, 28rem);
  border-radius: 0.45rem;
  margin-top: 0.45rem;
}

.transcript-embed-thumb {
  max-width: min(100%, 5rem);
}

.transcript-embed {
  margin-top: 0.45rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.55rem;
  border-left: 3px solid var(--accent);
  background: rgba(59, 130, 246, 0.08);
}

.transcript-embed-author {
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.transcript-embed-title {
  display: inline-block;
  font-weight: 650;
  margin-bottom: 0.35rem;
  color: inherit;
  text-decoration: none;
}

.transcript-embed-title:hover {
  text-decoration: underline;
}

.transcript-embed-description,
.transcript-embed-field-value {
  white-space: pre-line;
  line-height: 1.45;
  font-size: 0.92rem;
}

.transcript-embed-fields {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.45rem;
}

.transcript-embed-field.inline {
  display: inline-block;
  min-width: 8rem;
  margin-right: 0.75rem;
}

.transcript-embed-field-name {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.15rem;
}

.transcript-embed-footer {
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.78rem;
}

.infractions-panel .quota-search {
  margin-bottom: 0.75rem;
}

.infractions-list {
  display: grid;
  gap: 0.45rem;
}

.infraction-row {
  padding: 0.55rem 0.75rem;
  border-radius: 0.65rem;
  background: rgba(16, 16, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.infraction-row-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.infraction-row-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.45rem;
  flex-shrink: 0;
}

.infraction-details {
  margin-top: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: grid;
  gap: 0.5rem;
}

.infraction-detail-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.55rem 0.65rem;
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.infraction-detail-copy {
  min-width: 0;
  flex: 1;
}

.infraction-detail-top {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 0.25rem;
}

.infraction-id {
  color: var(--muted);
  font-size: 0.74rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.infraction-field-label {
  margin: 0.35rem 0 0.15rem;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.infraction-reason {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.5;
  word-break: break-word;
  white-space: pre-line;
}

.infraction-evidence {
  margin: 0 0 0.15rem;
  color: #e4e4e7;
  font-size: 0.82rem;
  line-height: 1.5;
  word-break: break-word;
  white-space: pre-line;
}

.infraction-evidence:empty {
  display: none;
}

.infraction-meta-line {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-size: 0.74rem;
}

.infraction-row h3 {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 650;
}

.infraction-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: flex-end;
}

.btn-small {
  padding: 0.35rem 0.7rem;
  font-size: 0.78rem;
}

@media (max-width: 900px) {
  .home-hero {
    grid-template-columns: 1fr;
  }

  .home-preview {
    justify-self: stretch;
    width: 100%;
  }

  .home-info {
    grid-template-columns: 1fr;
  }

  .home-foot {
    flex-direction: column;
    align-items: flex-start;
  }

  .quota-summary {
    flex-wrap: wrap;
  }

  .quota-summary .stat-card {
    flex: 1 1 calc(50% - 0.45rem);
  }

  .section-head.quota-head {
    flex-direction: column;
    align-items: stretch;
  }

  .panel-grid {
    grid-template-columns: 1fr;
  }

  .panel-wide {
    grid-column: auto;
  }

  .row {
    flex-direction: column;
    align-items: stretch;
  }

  .infraction-row-main {
    flex-direction: column;
    align-items: flex-start;
  }

  .infraction-row-actions {
    align-items: flex-start;
    width: 100%;
  }

  .infraction-detail-row {
    flex-direction: column;
    align-items: stretch;
  }
}

.legal-main {
  max-width: 760px;
  margin: 0 auto;
}

.legal-panel h1 {
  margin-top: 0;
}

.legal-panel h2 {
  margin: 1.5rem 0 0.5rem;
  font-size: 1.1rem;
}

.legal-panel p,
.legal-panel li {
  color: var(--muted);
  line-height: 1.6;
}

.legal-panel code {
  font-size: 0.9em;
  padding: 0.1em 0.35em;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.link-method-block + .link-method-block {
  margin-top: 1rem;
}

.link-method-title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.link-method-divider {
  margin: 1.25rem 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
  text-transform: lowercase;
}

.legal-links-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.legal-link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  backdrop-filter: blur(8px);
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.legal-link-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.24);
  transform: translateY(-1px);
}

.legal-inline-link {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.35);
  text-underline-offset: 0.15em;
}

.legal-inline-link:hover {
  text-decoration-color: rgba(255, 255, 255, 0.7);
}

.daily-vote-main,
.daily-vote-admin-main,
.sea-lion-vote-main,
.sea-lion-admin-main {
  max-width: 1200px;
  margin: 0 auto;
}

.daily-vote-panel-image {
  margin: 0 0 1.25rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  max-height: 320px;
}

.daily-vote-panel-image img {
  width: 100%;
  max-height: 320px;
  object-fit: cover;
  display: block;
}

.daily-vote-grid,
.daily-vote-admin-grid,
.sea-lion-vote-grid,
.sea-lion-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.daily-vote-card,
.daily-vote-admin-card,
.sea-lion-vote-card,
.sea-lion-admin-card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-card);
}

.daily-vote-card.is-voted,
.sea-lion-vote-card.is-voted {
  border-color: rgba(59, 130, 246, 0.45);
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.18);
}

.daily-vote-media-wrap,
.sea-lion-vote-image-wrap {
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: calc(var(--radius) - 4px);
  background: rgba(255, 255, 255, 0.04);
}

.daily-vote-media-wrap img,
.sea-lion-vote-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.daily-vote-text-entry {
  margin: 0;
  padding: 1.25rem;
  height: 100%;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: clamp(1.35rem, 4vw, 1.85rem);
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.daily-vote-caption {
  margin: 0.15rem 0 0;
  color: inherit;
  font-size: clamp(1.15rem, 3.5vw, 1.45rem);
  font-weight: 600;
  white-space: pre-wrap;
  word-break: break-word;
}

.daily-vote-meta,
.sea-lion-vote-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.daily-vote-user,
.sea-lion-vote-user {
  margin: 0;
  font-weight: 600;
}

.daily-vote-count,
.sea-lion-vote-count,
.daily-vote-admin-card .quota-meta,
.sea-lion-admin-card .quota-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.daily-vote-btn,
.sea-lion-vote-btn {
  margin-top: auto;
}

.daily-vote-admin-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: auto;
}

.daily-vote-admin-actions .delete-btn {
  border-color: rgba(239, 68, 68, 0.45);
  color: #fca5a5;
}

.daily-vote-admin-actions .delete-btn:hover {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.65);
}

#vote-page-link {
  color: var(--accent);
  text-decoration: none;
}

#vote-page-link:hover {
  text-decoration: underline;
}

.character-monitor-main {
  max-width: 1100px;
  margin: 0 auto;
}

.character-monitor-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 0 0 1rem;
}

.character-monitor-log-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.character-monitor-log-row {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  padding: 0.85rem 1rem;
}

.character-monitor-log-head {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
  margin-bottom: 0.35rem;
}

.character-monitor-type {
  color: var(--accent);
  font-size: 0.95rem;
}

.character-monitor-ts {
  color: var(--muted);
  font-size: 0.85rem;
}

.character-monitor-user {
  margin: 0 0 0.35rem;
  font-weight: 600;
}

.character-monitor-path {
  margin: 0 0 0.35rem;
  word-break: break-all;
}

.character-monitor-path code {
  font-size: 0.85rem;
}

.character-monitor-details {
  margin: 0.5rem 0 0;
  padding: 0.65rem 0.75rem;
  border-radius: calc(var(--radius) - 4px);
  background: rgba(255, 255, 255, 0.04);
  overflow: auto;
  max-height: 220px;
  font-size: 0.78rem;
  line-height: 1.35;
  white-space: pre-wrap;
  word-break: break-word;
}

.apply-scale-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.45rem;
  margin-top: 0.65rem;
}

@media (min-width: 520px) {
  .apply-scale-row {
    grid-template-columns: repeat(10, minmax(0, 1fr));
  }
}

label.apply-scale-option {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0.35rem;
  padding: 0.55rem 0.25rem;
  text-align: center;
  min-width: 0;
}

label.apply-scale-option input[type="radio"] {
  flex: 0 0 18px;
}

label.apply-scale-option .apply-scale-num {
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--muted);
}

label.apply-scale-option:has(input:checked) .apply-scale-num {
  color: var(--text);
}

.apply-evidence-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: 0.35rem;
}

.apply-evidence-file-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.35rem;
}

.apply-evidence-file-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.65rem;
  font-size: 0.86rem;
  padding: 0.4rem 0.55rem;
  border-radius: calc(var(--radius) - 4px);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.apply-evidence-file-name {
  font-weight: 600;
  word-break: break-word;
}

.apply-evidence-file-meta {
  color: var(--muted);
  font-size: 0.78rem;
}

.page-events-reviewer .submissions-main {
  max-width: 76rem;
}

@media (min-width: 960px) {
  .page-events-reviewer .submissions-review-layout {
    grid-template-columns: minmax(0, 24rem) minmax(0, 1fr);
    gap: 0.75rem;
    align-items: start;
  }

  .page-events-reviewer .submissions-list-panel,
  .page-events-reviewer .apply-detail-panel {
    max-height: calc(100vh - 7.5rem);
  }

  .page-events-reviewer .apply-detail-empty {
    min-height: 8rem;
  }

  .page-events-reviewer .apply-detail-section + .apply-detail-section {
    margin-top: 0.85rem;
    padding-top: 0.85rem;
  }
}

.evidence-gallery-modal[hidden] {
  display: none !important;
}

.evidence-gallery-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.evidence-gallery-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 12, 0.82);
  backdrop-filter: blur(6px);
}

.evidence-gallery-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 72rem);
  max-height: min(92vh, 900px);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem 1.1rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(12, 14, 20, 0.96);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}

.evidence-gallery-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.evidence-gallery-head h2 {
  margin: 0;
  font-size: 1.05rem;
}

.evidence-gallery-grid {
  overflow: auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.75rem;
  padding-right: 0.15rem;
}

.evidence-gallery-card {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  min-width: 0;
  padding: 0.45rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.evidence-gallery-card img,
.evidence-gallery-card video {
  width: 100%;
  max-height: 220px;
  object-fit: contain;
  border-radius: calc(var(--radius) - 4px);
  background: rgba(0, 0, 0, 0.35);
}

.evidence-gallery-card figcaption {
  display: grid;
  gap: 0.25rem;
}

.evidence-gallery-name {
  font-size: 0.82rem;
  font-weight: 600;
  word-break: break-word;
}

.evidence-gallery-meta {
  font-size: 0.75rem;
  color: var(--muted);
}

body.evidence-gallery-open {
  overflow: hidden;
}
