:root {
  --forest: #002f5f;
  --forest-deep: #001e3d;
  --forest-mid: #0a4480;
  --cream: #f4f7fa;
  --white: #ffffff;
  --lime: #f9732a;
  --lime-hover: #ff8642;
  --ink: #0f2236;
  --muted: #586a7c;
  --border: #dce4ee;
  --danger: #c62828;
  --ok: #0e7a4b;
  --warn: #c46210;
  --radius: 16px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.45;
}

.hidden {
  display: none !important;
}

body.role-employee .admin-only {
  display: none !important;
}

/* Topbar */
.topbar {
  background: var(--forest-deep);
  color: var(--white);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: sticky;
  top: 0;
  z-index: 20;
}

.topbar-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 14px 22px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.brand-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-mark {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--white);
  padding: 4px;
  display: grid;
  place-items: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  flex-shrink: 0;
}

.logo-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.login-logo {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: var(--white);
  padding: 7px;
  margin-bottom: 14px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

.login-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-title {
  font-weight: 700;
  font-size: 16px;
}

.brand-sub {
  font-size: 12px;
  color: #a7bfd8;
}

.status-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  font-size: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: #dce9f5;
}

.pill-accent {
  background: rgba(249, 115, 42, 0.22);
  color: #ffb185;
}

.nav-tabs {
  display: flex;
  gap: 8px;
}

.nav-btn {
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: #e4eef7;
  padding: 8px 14px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  transition: 0.15s ease;
}

.nav-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.nav-btn.active {
  background: var(--lime);
  color: var(--white);
  border-color: var(--lime);
}

.nav-btn.subtle {
  color: #f3b5b5;
  border-color: rgba(255, 160, 160, 0.25);
}

/* Main Layout */
.container {
  max-width: 1320px;
  margin: 24px auto;
  padding: 0 22px 48px;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.grid-two {
  display: grid;
  grid-template-columns: 430px 1fr;
  gap: 20px;
  align-items: start;
}

@media (max-width: 980px) {
  .grid-two {
    grid-template-columns: 1fr;
  }
}

.card {
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 6px 24px rgba(13, 35, 23, 0.06);
}

.dark-card {
  background: var(--forest);
  color: var(--white);
}

.light-card {
  background: var(--white);
  border: 1px solid var(--border);
}

.card-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.9px;
  color: var(--lime);
  margin-bottom: 4px;
}

.dark-eyebrow {
  color: var(--forest-mid);
}

h2 {
  margin: 0;
  font-size: 20px;
}

h3 {
  margin: 0;
  font-size: 16px;
}

.badge-token {
  font-size: 11px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #dbeee3;
  white-space: nowrap;
}

.badge-usage {
  font-size: 11px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 999px;
  background: #eaf4ed;
  color: var(--forest);
}

/* Drop Zone */
.drop-zone {
  border: 2px dashed rgba(249, 115, 42, 0.55);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.18);
  padding: 18px;
  text-align: center;
  cursor: pointer;
  transition: 0.15s ease;
  margin-bottom: 16px;
}

.drop-zone.dragover {
  border-color: var(--lime);
  background: rgba(249, 115, 42, 0.14);
}

.drop-icon {
  font-size: 32px;
  margin-bottom: 8px;
}

.drop-title {
  font-size: 14px;
  margin-bottom: 4px;
}

.drop-hint {
  font-size: 12px;
  color: #b4cabe;
}

.preview-wrap img {
  max-width: 100%;
  max-height: 260px;
  border-radius: 10px;
  object-fit: contain;
  background: #ffffff;
}

.preview-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  font-size: 12px;
  color: #cde2d6;
}

/* Multi-Design Queue */
.queue-section {
  background: rgba(0, 0, 0, 0.18);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 14px;
}

.queue-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 700;
  color: #d7e8de;
  margin-bottom: 10px;
}

.queue-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 230px;
  overflow-y: auto;
}

.queue-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 9px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid transparent;
  cursor: pointer;
  transition: 0.12s ease;
}

.queue-item:hover {
  background: rgba(255, 255, 255, 0.13);
}

.queue-item.selected {
  border-color: var(--lime);
  background: rgba(200, 243, 54, 0.12);
}

.queue-thumb {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  object-fit: cover;
  background: #ffffff;
  flex-shrink: 0;
}

.queue-info {
  flex: 1;
  min-width: 0;
}

.queue-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue-sub {
  font-size: 11px;
  color: #b5ccbe;
}

.queue-status {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #e2f0e8;
  white-space: nowrap;
}

.queue-status.done {
  background: rgba(200, 243, 54, 0.22);
  color: var(--lime);
}

.queue-status.err {
  background: rgba(255, 110, 110, 0.25);
  color: #ffc5c5;
}

.queue-remove {
  background: transparent;
  border: none;
  color: #b4cabe;
  cursor: pointer;
  font-size: 14px;
  padding: 2px 5px;
}

.cta-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-ghost-full {
  width: 100%;
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 11px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

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

.connector-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 12px 0;
}

.connector-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 12px;
  font-weight: 600;
}

.conn-pill {
  font-size: 11px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #d6e6dc;
}

.conn-pill.on {
  background: rgba(200, 243, 54, 0.22);
  color: var(--lime);
}

/* Form Elements */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

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

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
  font-size: 12px;
  font-weight: 600;
  color: #d7e8de;
}

.dark-field,
.light-field,
.light-card .field {
  color: var(--ink);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  font-size: 13px;
  font-family: inherit;
}

.field select option {
  color: var(--ink);
  background: var(--white);
}

.dark-field input,
.dark-field select,
.dark-field textarea,
.light-field input,
.light-field select,
.light-field textarea,
.light-card .field input,
.light-card .field select,
.light-card .field textarea {
  background: #f8fafc;
  color: var(--ink);
  border: 1.5px solid #cbd5e1;
}

.light-card .field input::placeholder,
.light-card .field textarea::placeholder,
.user-edit-row input::placeholder {
  color: #64748b;
}

.light-card .field input:focus,
.light-card .field select:focus,
.light-card .field textarea:focus,
.user-edit-row input:focus,
.user-edit-row select:focus {
  outline: none;
  border-color: var(--forest);
  background: var(--white);
}

.advanced-box {
  background: rgba(0, 0, 0, 0.14);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 12px;
}

.advanced-box summary {
  cursor: pointer;
  font-weight: 600;
  color: #cbe0d3;
}

.advanced-inner {
  margin-top: 12px;
}

/* Buttons */
.btn-lime {
  background: var(--lime);
  color: var(--white);
  border: none;
  border-radius: 12px;
  padding: 13px 18px;
  font-weight: 800;
  font-size: 14px;
  cursor: pointer;
  transition: 0.15s ease;
}

.desc-textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1.5px solid #cfd9e5;
  font-size: 13px;
  line-height: 1.5;
  font-family: inherit;
  resize: vertical;
  color: var(--ink);
  background: #fafcff;
}

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  margin: 12px 0;
  font-size: 12px;
  font-weight: 600;
}

.toggle-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--lime);
  cursor: pointer;
}

.btn-lime:hover:not(:disabled) {
  background: var(--lime-hover);
  transform: translateY(-1px);
}

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

.full-width {
  width: 100%;
}

.btn-ghost-sm {
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  border: none;
  border-radius: 8px;
  padding: 5px 10px;
  font-size: 12px;
  cursor: pointer;
}

.dark-ghost {
  background: #edf2ee;
  color: var(--ink);
}

.btn-copy,
.btn-copy-primary {
  border: 1px solid var(--border);
  background: #f5f8f5;
  color: var(--ink);
  padding: 5px 11px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.btn-copy-primary {
  background: var(--forest);
  color: var(--white);
  border-color: var(--forest);
}

.btn-dark {
  background: var(--forest);
  color: var(--white);
  border: none;
  border-radius: 10px;
  padding: 11px 16px;
  font-weight: 700;
  cursor: pointer;
}

.btn-outline {
  background: transparent;
  color: var(--forest);
  border: 1px solid var(--forest);
  border-radius: 10px;
  padding: 11px 16px;
  font-weight: 700;
  cursor: pointer;
}

.btn-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Result Area */
.empty-state,
.loading-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--muted);
}

.empty-emoji {
  font-size: 42px;
  margin-bottom: 8px;
}

.spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #dce6df;
  border-top-color: var(--forest);
  border-radius: 50%;
  margin: 0 auto 14px;
  animation: spin 0.8s linear infinite;
}

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

.mobile-preview-box {
  background: #f0f5fb;
  border: 1px solid #d0dfef;
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
}

.box-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--forest-mid);
  margin-bottom: 5px;
}

.light-label {
  color: var(--lime);
}

.mobile-hook {
  font-weight: 700;
  font-size: 15px;
  color: var(--ink);
}

.seo-block {
  margin-bottom: 18px;
}

.block-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.block-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--muted);
}

.block-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.counter-pill {
  font-size: 12px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: #edf2ee;
  color: var(--ink);
}

.counter-pill.ok {
  background: #dff4e6;
  color: var(--ok);
}

.counter-pill.warn {
  background: #fff3d6;
  color: var(--warn);
}

.title-textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1.5px solid #cbd7cf;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  resize: vertical;
  color: var(--ink);
}

.alt-title-box {
  background: #f9fbf9;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 500;
}

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

.tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 11px;
  border-radius: 10px;
  background: #eef4fa;
  border: 1px solid #c9d9ea;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.12s ease;
}

.tag-chip:hover {
  background: #e1ecf7;
}

.tag-len {
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--white);
  color: var(--ok);
  font-weight: 700;
}

.tag-src-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--forest-mid);
}

.tag-src-dot.bank {
  background: #0d8a4b;
}

.insight-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 700px) {
  .insight-grid {
    grid-template-columns: 1fr;
  }
}

.insight-box {
  background: #f8faf8;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
}

.insight-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--forest);
  margin-bottom: 8px;
}

.insight-text {
  font-size: 13px;
  margin: 0 0 8px;
}

.insight-sub {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 8px;
}

.query-chips,
.niche-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.q-chip {
  font-size: 11px;
  background: #e7efe9;
  color: var(--forest);
  padding: 4px 8px;
  border-radius: 999px;
}

/* History & Market Table */
.history-card {
  margin-top: 20px;
}

.history-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}

.history-item {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 12px;
  cursor: pointer;
  background: #fcfdfc;
}

.history-item:hover {
  border-color: var(--forest);
}

.history-thumb {
  width: 52px;
  height: 52px;
  border-radius: 9px;
  object-fit: contain;
  background: var(--white);
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.history-body {
  min-width: 0;
  flex: 1;
}

.output-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-right-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tag-chip-edit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border-radius: 10px;
  background: #eef4fa;
  border: 1px solid #c9d9ea;
}

.tag-chip-edit:focus-within {
  border-color: var(--lime);
  background: var(--white);
}

.tag-input {
  border: none;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  font-family: inherit;
  width: 132px;
  outline: none;
}

.tag-copy-mini {
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 12px;
  padding: 2px 4px;
  color: var(--muted);
}

.tag-copy-mini:hover {
  color: var(--forest);
}

.gaps-list,
.activity-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 360px;
  overflow-y: auto;
}

.gap-card,
.act-card {
  border: 1px solid var(--border);
  border-radius: 11px;
  padding: 10px 12px;
  background: #fafcff;
  font-size: 12px;
}

.act-card.clickable {
  cursor: pointer;
  transition: 0.12s ease;
}

.act-card.clickable:hover {
  border-color: var(--lime);
  background: #fff7f2;
}

.act-card.login-event {
  background: #f0f5fb;
  border-color: #d0dfef;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.act-row-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.act-open-hint {
  font-size: 11px;
  font-weight: 700;
  color: var(--lime);
  white-space: nowrap;
}

.gap-topic,
.act-title {
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 4px;
}

.gap-meta,
.act-meta {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 6px;
}

.kind-pill {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
}

.kind-pill.measured {
  background: #dff4e6;
  color: var(--ok);
}

.kind-pill.estimated {
  background: #fff3e6;
  color: var(--warn);
}

.output-design-thumb {
  width: 54px;
  height: 54px;
  border-radius: 10px;
  object-fit: contain;
  background: var(--white);
  border: 1.5px solid var(--border);
  flex-shrink: 0;
}

.history-title {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
}

.history-meta {
  font-size: 11px;
  color: var(--muted);
}

.trend-summary-box {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  padding: 14px;
  margin: 14px 0 18px;
}

.trend-text {
  font-size: 13px;
  color: #e4f0e8;
  margin: 0 0 10px;
}

.niche-chips .q-chip {
  background: rgba(200, 243, 54, 0.16);
  color: var(--lime);
}

.muted-p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 0;
}

.muted-light {
  font-size: 13px;
  color: #cde0d5;
  margin-top: 0;
}

.muted-small {
  font-size: 12px;
  color: var(--muted);
}

.search-input {
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  min-width: 220px;
}

.table-wrap {
  overflow-x: auto;
  max-height: 440px;
  overflow-y: auto;
}

.kw-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.kw-table th,
.kw-table td {
  text-align: left;
  padding: 9px 10px;
  border-bottom: 1px solid var(--border);
}

.kw-table th {
  position: sticky;
  top: 0;
  background: #f4f7f4;
  font-size: 12px;
  color: var(--muted);
}

.error-text {
  color: #ffb4b4;
  font-size: 13px;
  margin-top: 10px;
}

.light-card .error-text {
  color: var(--danger);
}

.status-msg {
  font-size: 13px;
  font-weight: 600;
  margin-top: 12px;
  color: var(--ok);
}

.light-status {
  color: var(--lime);
}

/* Login Modal */
.login-gate {
  position: fixed;
  inset: 0;
  background: rgba(11, 35, 23, 0.88);
  display: grid;
  place-items: center;
  z-index: 100;
  padding: 20px;
}

.login-card {
  background: var(--forest);
  color: var(--white);
  padding: 28px;
  border-radius: 18px;
  width: 100%;
  max-width: 390px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.brand-badge {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--lime);
  margin-bottom: 8px;
}

.login-card input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  margin-bottom: 12px;
  font-size: 14px;
}

/* Admin Settings & User Management */
.settings-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.perm-box {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
}

.perm-box-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--forest);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 10px;
}

.perm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
  gap: 8px 12px;
}

.perm-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
}

.perm-check input[type="checkbox"] {
  width: 15px;
  height: 15px;
  accent-color: var(--forest);
  cursor: pointer;
}

.users-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 620px;
  overflow-y: auto;
}

.user-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  background: #fbfcfd;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.user-card.disabled-user {
  opacity: 0.72;
  background: #f5f6f8;
}

.user-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.user-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.user-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--forest);
}

.user-handle {
  font-size: 12px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.role-pill {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  text-transform: uppercase;
}

.role-pill.admin {
  background: #fff1e6;
  color: #c2410c;
  border: 1px solid #fed7aa;
}

.role-pill.employee {
  background: #e8f1fa;
  color: var(--forest);
  border: 1px solid #c7dcef;
}

.role-pill.inactive {
  background: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.user-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.btn-danger-sm {
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
  border-radius: 8px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.btn-danger-sm:hover {
  background: #ffe4e6;
}

.user-edit-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

@media (max-width: 700px) {
  .user-edit-row {
    grid-template-columns: 1fr;
  }
}

.user-edit-row input,
.user-edit-row select {
  width: 100%;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 13px;
  background: var(--white);
}

.search-mode-wrap {
  display: flex;
  align-items: center;
}

.badge-token-select {
  appearance: auto;
  background: rgba(249, 115, 42, 0.2);
  color: #ffb88c;
  border: 1px solid rgba(249, 115, 42, 0.55);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  outline: none;
}

.badge-token-select:hover,
.badge-token-select:focus {
  background: rgba(249, 115, 42, 0.32);
  border-color: #f9732a;
}

.badge-token-select.live-active {
  background: rgba(16, 185, 129, 0.22);
  color: #a7f3d0;
  border-color: rgba(16, 185, 129, 0.65);
}

.badge-token-select option {
  background: #0f2942;
  color: #ffffff;
}
