/* ─── Base ─────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:       #0d0f14;
  --surface:  #15181f;
  --surface2: #1c2029;
  --border:   #272b36;
  --cyan:     #00c8d4;
  --cyan-dim: rgba(0,200,212,.15);
  --text:     #e8eaf0;
  --muted:    #6b7280;
  --warn:     #f59e0b;
  --danger:   #ef4444;
  --green:    #22c55e;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.5;
}

/* ─── Header ───────────────────────────────────────────────────────────────── */
.header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: .75rem 2rem;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
}
.logo {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: .3rem;
  font-weight: 700;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.logo-x    { color: var(--cyan); }
.header-nav { flex: 1; }
.nav-label  { color: var(--muted); font-size: .85rem; }
.header-user {
  display: flex;
  align-items: center;
  gap: .75rem;
}
.user-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 2px solid var(--border);
}
.user-name  { font-weight: 500; font-size: .875rem; }
.logout-btn {
  background: none; border: 1px solid var(--border);
  color: var(--muted); cursor: pointer;
  padding: .35rem .75rem; border-radius: 6px;
  font-size: .8rem;
  transition: color .15s, border-color .15s;
}
.logout-btn:hover { color: var(--text); border-color: var(--cyan); }

/* ─── Main layout ──────────────────────────────────────────────────────────── */
.main { max-width: 1000px; margin: 0 auto; padding: 2rem 1.5rem; }

/* ─── Login screen ─────────────────────────────────────────────────────────── */
.login-screen {
  display: flex; justify-content: center; align-items: center;
  min-height: 70vh;
}
.login-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 3rem 2.5rem;
  text-align: center;
  max-width: 420px; width: 100%;
}
.login-icon  { font-size: 3rem; margin-bottom: 1rem; }
.login-card h1 { font-size: 1.5rem; margin-bottom: .75rem; }
.login-card p  { color: var(--muted); margin-bottom: 2rem; line-height: 1.6; }

/* ─── Buttons ──────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .65rem 1.4rem;
  border-radius: 8px; border: none;
  cursor: pointer; font-size: .9rem; font-weight: 500;
  text-decoration: none;
  transition: opacity .15s, transform .1s;
}
.btn:hover   { opacity: .85; }
.btn:active  { transform: scale(.97); }
.btn-discord {
  background: #5865F2; color: #fff;
  font-size: 1rem; padding: .85rem 1.8rem;
}
.btn-primary { background: var(--cyan); color: #000; }
.btn-danger  { background: var(--danger); color: #fff; font-size: .8rem; padding: .3rem .7rem; }
.btn-back    {
  background: var(--surface2); border: 1px solid var(--border);
  color: var(--muted); cursor: pointer; font-size: .875rem;
  padding: .4rem .9rem; border-radius: 6px;
  transition: color .15s;
}
.btn-back:hover { color: var(--text); }

/* ─── Section header ───────────────────────────────────────────────────────── */
.section-header {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1.5rem;
}
.section-header h2 { font-size: 1.3rem; }
.section-header p  { color: var(--muted); margin: .25rem 0 0; font-size: .9rem; }

/* ─── Guild grid ───────────────────────────────────────────────────────────── */
.guild-screen .section-header { flex-direction: column; align-items: flex-start; }
.guild-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}
.guild-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, transform .15s;
}
.guild-card:hover { border-color: var(--cyan); transform: translateY(-2px); }
.guild-icon {
  width: 60px; height: 60px; border-radius: 50%;
  margin: 0 auto .75rem;
  object-fit: cover; background: var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; font-weight: 700; color: var(--cyan);
}
.guild-name { font-weight: 600; font-size: .9rem; }

/* ─── Tabs ─────────────────────────────────────────────────────────────────── */
.tabs {
  display: flex; gap: .25rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1.5rem;
  overflow-x: auto;
}
.tab {
  background: none; border: none; color: var(--muted);
  cursor: pointer; padding: .75rem 1.1rem;
  font-size: .875rem; font-weight: 500;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  transition: color .15s, border-color .15s;
  white-space: nowrap;
}
.tab:hover  { color: var(--text); }
.tab.active { color: var(--cyan); border-bottom-color: var(--cyan); }

/* ─── Stats ────────────────────────────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.25rem 1rem;
  text-align: center;
}
.stat-num   { font-size: 2rem; font-weight: 700; color: var(--cyan); }
.stat-label { font-size: .8rem; color: var(--muted); margin-top: .25rem; }

/* ─── Tables ───────────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
.data-table {
  width: 100%; border-collapse: collapse;
  font-size: .85rem;
}
.data-table th, .data-table td {
  padding: .75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.data-table th  { color: var(--muted); font-weight: 500; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; }
.data-table tr:hover td { background: var(--surface2); }

/* ─── Badges ───────────────────────────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: .2rem .55rem;
  border-radius: 4px;
  font-size: .75rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .03em;
}
.badge-ban    { background: rgba(239,68,68,.2); color: var(--danger); }
.badge-kick   { background: rgba(245,158,11,.2); color: var(--warn); }
.badge-warn   { background: rgba(234,179,8,.2);  color: #eab308; }
.badge-delete { background: var(--border); color: var(--muted); }

/* ─── Config form ──────────────────────────────────────────────────────────── */
.config-form  { max-width: 560px; }
.form-section { margin-bottom: 2rem; }
.form-section h3 { font-size: .95rem; font-weight: 600; margin-bottom: 1rem; color: var(--cyan); }
.form-row {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: .75rem 0;
  border-bottom: 1px solid var(--border);
}
.form-row label { color: var(--text); }
.hint  { color: var(--muted); font-size: .8rem; margin-left: .3rem; }
.form-row input[type="number"],
.form-row input[type="email"] {
  background: var(--surface2); border: 1px solid var(--border);
  color: var(--text); padding: .4rem .75rem;
  border-radius: 6px; font-size: .875rem;
  width: 120px; outline: none;
}
.form-row input[type="email"] { width: 240px; }
.form-row input:focus { border-color: var(--cyan); }
.form-actions { display: flex; align-items: center; gap: 1rem; margin-top: 1.5rem; }
.save-status  { color: var(--green); font-size: .875rem; }

/* Toggle */
.toggle { display: flex; align-items: center; cursor: pointer; }
.toggle input { display: none; }
.slider {
  width: 44px; height: 24px; background: var(--border);
  border-radius: 12px; position: relative;
  transition: background .2s;
}
.slider::after {
  content: ''; position: absolute;
  left: 3px; top: 3px;
  width: 18px; height: 18px;
  background: #fff; border-radius: 50%;
  transition: transform .2s;
}
.toggle input:checked + .slider             { background: var(--cyan); }
.toggle input:checked + .slider::after     { transform: translateX(20px); }

/* ─── Domain add ───────────────────────────────────────────────────────────── */
.domain-add {
  display: flex; gap: .75rem; margin-bottom: 1.25rem;
}
.domain-add input {
  flex: 1; background: var(--surface2); border: 1px solid var(--border);
  color: var(--text); padding: .5rem 1rem; border-radius: 8px;
  font-size: .9rem; outline: none;
}
.domain-add input:focus { border-color: var(--cyan); }

/* ─── Misc ─────────────────────────────────────────────────────────────────── */
.loading-spin {
  width: 32px; height: 32px;
  border: 3px solid var(--border);
  border-top-color: var(--cyan);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  margin: 3rem auto;
}
@keyframes spin { to { transform: rotate(360deg); } }
.empty-state { color: var(--muted); padding: 2rem 1rem; text-align: center; }

/* ─── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .header { padding: .75rem 1rem; }
  .main   { padding: 1.25rem 1rem; }
  .guild-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ─── Section header with action button ────────────────────────────────────── */
.section-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.section-header-row h2 { font-size: 1.3rem; }
.section-header-row p  { color: var(--muted); margin: .25rem 0 0; font-size: .9rem; }

/* ─── Section label (active / not added) ───────────────────────────────────── */
.guild-section-label {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 1.5rem 0 .75rem;
  padding-bottom: .4rem;
  border-bottom: 1px solid var(--border);
}

/* ─── Guild card — active badge ────────────────────────────────────────────── */
.guild-card { position: relative; }
.guild-active-badge {
  position: absolute;
  top: .6rem; right: .6rem;
  background: var(--cyan-dim);
  color: var(--cyan);
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: .15rem .45rem;
  border-radius: 4px;
  border: 1px solid rgba(0,200,212,.3);
}
/* Badge color variants */
.guild-active-badge--active  { background: rgba(0,200,100,.15); color: #00c864; border-color: rgba(0,200,100,.3); }
.guild-active-badge--trial   { background: rgba(255,180,0,.15); color: #ffb400; border-color: rgba(255,180,0,.3); }
.guild-active-badge--expired { background: rgba(220,50,50,.15);  color: #e05555; border-color: rgba(220,50,50,.3); }
.guild-active-badge--none    { background: rgba(120,120,120,.15); color: #888;  border-color: rgba(120,120,120,.3); }

.guild-action {
  margin-top: .4rem;
  font-size: .75rem;
  color: var(--cyan);
  opacity: 0;
  transition: opacity .2s;
}
.guild-card:hover .guild-action { opacity: 1; }

/* ─── Guild card — inactive (bot not added) ────────────────────────────────── */
.guild-card-inactive {
  border-color: var(--border);
  opacity: .7;
  cursor: default;
}
.guild-card-inactive:hover {
  border-color: var(--border);
  transform: none;
  opacity: 1;
}
.guild-icon-dim { color: var(--muted); background: var(--surface2); }

/* ─── Add bot button on inactive cards ─────────────────────────────────────── */
.btn-add-bot {
  display: inline-block;
  margin-top: .6rem;
  background: var(--cyan);
  color: #000;
  border: none;
  border-radius: 6px;
  padding: .35rem .85rem;
  font-size: .75rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .15s;
}
.btn-add-bot:hover { opacity: .85; }

/* ─── Trial banner ──────────────────────────────────────────────────────────── */
.trial-banner {
  background: linear-gradient(135deg, rgba(245,158,11,.15), rgba(245,158,11,.08));
  border: 1px solid rgba(245,158,11,.4);
  border-radius: 10px;
  padding: .85rem 1.25rem;
  margin-bottom: 1.25rem;
  font-size: .875rem;
  color: var(--warn);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .5rem;
}
.trial-banner strong { color: #f59e0b; }
.trial-upgrade-hint {
  color: var(--muted);
  font-size: .8rem;
}
.trial-upgrade-hint code {
  background: var(--surface2);
  border: 1px solid var(--border);
  padding: .1rem .4rem;
  border-radius: 4px;
  font-family: monospace;
  font-size: .8rem;
  color: var(--cyan);
}

/* ─── Paywall screen ────────────────────────────────────────────────────────── */
.paywall-screen {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 2rem;
  min-height: 70vh;
}
.paywall-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  max-width: 500px;
  width: 100%;
  text-align: center;
  position: relative;
}
.paywall-back {
  position: absolute;
  top: 1.25rem;
  left: 1.25rem;
  font-size: .8rem;
}
.paywall-icon {
  font-size: 2.5rem;
  margin-bottom: .75rem;
}
.paywall-server-name {
  font-size: .8rem;
  color: var(--cyan);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: .5rem;
}
.paywall-title {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: .6rem;
}
.paywall-subtitle {
  color: var(--muted);
  font-size: .9rem;
  line-height: 1.6;
  margin-bottom: 1.75rem;
}

/* Trial block */
.paywall-trial-block {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  text-align: left;
}
.paywall-trial-features {
  display: flex;
  flex-direction: column;
  gap: .45rem;
  margin-bottom: 1.25rem;
}
.paywall-feature {
  font-size: .875rem;
  color: var(--text);
}
.btn-trial {
  display: block;
  width: 100%;
  text-align: center;
  background: linear-gradient(135deg, var(--cyan), #00a8b4);
  color: #000;
  font-weight: 700;
  font-size: 1rem;
  padding: .9rem 1rem;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: opacity .15s, transform .1s;
  margin-bottom: .75rem;
}
.btn-trial:hover  { opacity: .9; }
.btn-trial:active { transform: scale(.98); }
.btn-trial:disabled { opacity: .5; cursor: not-allowed; }
.paywall-trial-note {
  font-size: .78rem;
  color: var(--muted);
  text-align: center;
}

/* Divider */
.paywall-divider {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin: 1.25rem 0;
  color: var(--muted);
  font-size: .8rem;
}
.paywall-divider::before,
.paywall-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Code block */
.paywall-code-block { text-align: left; }
.paywall-code-row {
  display: flex;
  gap: .5rem;
}
.paywall-code-input {
  flex: 1;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .55rem 1rem;
  border-radius: 8px;
  font-size: .9rem;
  font-family: monospace;
  letter-spacing: .05em;
  outline: none;
  transition: border-color .15s;
}
.paywall-code-input:focus { border-color: var(--cyan); }
.paywall-code-error {
  margin-top: .5rem;
  font-size: .82rem;
  color: var(--danger);
  min-height: 1.2rem;
}

/* ─── Pricing plan cards ────────────────────────────────────────────────────── */
.paywall-plans {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
.plan-card {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.25rem 1rem;
  text-align: center;
  position: relative;
}
.plan-card-featured {
  border-color: var(--cyan);
  background: rgba(0,212,212,.06);
}
.plan-badge {
  display: inline-block;
  background: var(--cyan);
  color: #000;
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .08em;
  padding: .15rem .5rem;
  border-radius: 4px;
  margin-bottom: .4rem;
}
.plan-name {
  font-size: .85rem;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: .3rem;
}
.plan-price {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: .2rem;
  line-height: 1;
}
.plan-period {
  font-size: .85rem;
  font-weight: 400;
  color: var(--muted);
}
.plan-saving {
  font-size: .75rem;
  color: var(--cyan);
  margin-bottom: .85rem;
}
.plan-btn {
  width: 100%;
  font-size: .85rem;
  padding: .6rem .75rem;
}

/* ─── Sub-plan badge next to server name ────────────────────────────────────── */
.sub-plan-badge {
  font-size: .75rem;
  font-weight: 600;
  padding: .2rem .6rem;
  border-radius: 6px;
  margin-left: .5rem;
}
.sub-plan-active { background: rgba(34,197,94,.15); color: var(--green); }
.sub-plan-trial  { background: rgba(245,158,11,.15); color: var(--warn); }
.sub-plan-admin  { background: rgba(0,200,212,.15);  color: var(--cyan); }

/* ─── Admin tab highlight ────────────────────────────────────────────────────── */
.tab-admin { color: var(--cyan) !important; }

/* ─── Badge green ────────────────────────────────────────────────────────────── */
.badge-green { background: rgba(34,197,94,.2); color: var(--green); }

/* ─── Updated form section header ───────────────────────────────────────────── */
.form-section-header { margin-bottom: 1rem; }
.form-section-header h3 { font-size: .95rem; font-weight: 600; color: var(--cyan); margin-bottom: .2rem; }
.form-section-header p  { font-size: .82rem; color: var(--muted); }
.form-row-label { display:flex; flex-direction:column; gap:.15rem; }
.form-row-label label { color: var(--text); font-weight: 500; }
.form-row-label .hint { font-size: .78rem; }

/* ─── Settings tab ───────────────────────────────────────────────────────────── */
.settings-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.25rem;
}
.settings-section-header { margin-bottom: 1rem; }
.settings-section-header h3 { font-size: 1rem; font-weight: 600; margin-bottom: .2rem; }
.settings-section-header p  { font-size: .85rem; color: var(--muted); line-height:1.5; }
.settings-section-header p code {
  background: var(--surface2); border: 1px solid var(--border);
  padding: .1rem .4rem; border-radius: 4px;
  font-family: monospace; font-size: .8rem; color: var(--cyan);
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .6rem 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: .75rem;
}
.settings-row-info { display: flex; flex-direction: column; gap: .15rem; }
.settings-row-info strong { font-size: .9rem; }

.settings-input-row {
  display: flex;
  gap: .5rem;
  margin-top: .75rem;
  align-items: center;
  flex-wrap: wrap;
}
.settings-input {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .5rem .85rem;
  border-radius: 8px;
  font-size: .875rem;
  outline: none;
  min-width: 0;
  flex: 1;
  transition: border-color .15s;
}
.settings-input:focus { border-color: var(--cyan); }

.settings-hint-block {
  background: rgba(0,200,212,.06);
  border: 1px solid rgba(0,200,212,.2);
  border-radius: 8px;
  padding: .75rem 1rem;
  font-size: .82rem;
  color: var(--muted);
  line-height: 1.6;
  margin-top: .75rem;
}
.settings-hint-block code {
  background: var(--surface2); border: 1px solid var(--border);
  padding: .1rem .4rem; border-radius: 4px;
  font-family: monospace; font-size: .8rem; color: var(--cyan);
}
.settings-status { margin-top: .6rem; font-size: .85rem; min-height: 1.2rem; }

/* Subscription card */
.subscription-card {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin-bottom: .75rem;
}
.sub-info-row {
  display: flex;
  justify-content: space-between;
  padding: .4rem 0;
  border-bottom: 1px solid var(--border);
  font-size: .875rem;
}
.sub-info-row:last-child { border-bottom: none; }
.sub-label { color: var(--muted); }

/* Danger zone */
.settings-danger-zone {
  border-color: rgba(239,68,68,.3);
  background: rgba(239,68,68,.04);
}
.settings-danger-zone .settings-section-header h3 { color: var(--danger); }
.danger-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.danger-row strong { font-size: .9rem; }
.danger-row .hint  { font-size: .8rem; color: var(--muted); margin-top: .15rem; }
.btn-danger-outline {
  background: transparent;
  border: 1px solid var(--danger);
  color: var(--danger);
  padding: .5rem 1.1rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: .875rem;
  font-weight: 600;
  transition: background .15s;
  white-space: nowrap;
}
.btn-danger-outline:hover { background: rgba(239,68,68,.12); }

/* ─── Admin panel ─────────────────────────────────────────────────────────────── */
.admin-header { margin-bottom: 1.25rem; }
.admin-header h3 { font-size: 1.1rem; font-weight: 700; color: var(--cyan); }
.admin-header p  { color: var(--muted); font-size: .875rem; }

/* ─── Config Info Tooltips ──────────────────────────────────────────────────── */
.label-with-info {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}

.info-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--cyan);
  font-size: .65rem;
  font-style: normal;
  font-weight: 700;
  cursor: default;
  flex-shrink: 0;
  position: relative;
  line-height: 1;
  transition: background .15s, border-color .15s;
  user-select: none;
}

.info-icon:hover {
  background: var(--cyan-dim);
  border-color: var(--cyan);
}

/* Tooltip bubble */
.info-icon::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%);
  background: #1e2330;
  border: 1px solid var(--border);
  color: var(--text);
  font-size: .75rem;
  font-weight: 400;
  line-height: 1.45;
  padding: .5rem .7rem;
  border-radius: 6px;
  width: 240px;
  white-space: normal;
  text-align: left;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity .15s, visibility .15s;
  z-index: 200;
  box-shadow: 0 4px 16px rgba(0,0,0,.4);
}

/* Caret */
.info-icon::before {
  content: '';
  position: absolute;
  left: 50%;
  bottom: calc(100% + 2px);
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--border);
  opacity: 0;
  visibility: hidden;
  transition: opacity .15s, visibility .15s;
  z-index: 201;
}

.info-icon:hover::after,
.info-icon:hover::before {
  opacity: 1;
  visibility: visible;
}

/* ─── Button variants ───────────────────────────────────────────────────────── */
.btn-success { background: var(--green);   color: #000; }
.btn-success:hover { filter: brightness(1.15); }
.btn-danger  { background: var(--danger);  color: #fff; }
.btn-danger:hover  { filter: brightness(1.15); }

/* ─── Chat Guard Pending Approvals ─────────────────────────────────────────── */
.cg-pending-section {
  margin-bottom: 1.5rem;
}

.cg-pending-title {
  font-size: .9rem;
  font-weight: 600;
  color: var(--warn);
  margin-bottom: .75rem;
  display: flex;
  align-items: center;
  gap: .5rem;
}

.cg-badge {
  background: var(--warn);
  color: #000;
  font-size: .7rem;
  font-weight: 700;
  padding: .1rem .4rem;
  border-radius: 999px;
}

.cg-pending-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--warn);
  border-radius: 8px;
  padding: .85rem 1rem;
  margin-bottom: .6rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  transition: opacity .2s;
}

.cg-pending-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: .25rem;
}

.cg-pending-user {
  font-size: .9rem;
  color: var(--text);
}

.cg-uid {
  font-size: .75rem;
  color: var(--muted);
  margin-left: .3rem;
}

.cg-pending-channel {
  font-size: .78rem;
  color: var(--muted);
}

.cg-pending-msg {
  font-size: .82rem;
  color: var(--text);
  background: var(--surface2);
  border-radius: 5px;
  padding: .35rem .5rem;
  margin-top: .15rem;
  font-style: italic;
  word-break: break-word;
}

.cg-pending-time {
  font-size: .72rem;
  color: var(--muted);
  margin-top: .1rem;
}

.cg-pending-actions {
  display: flex;
  flex-direction: column;
  gap: .4rem;
  flex-shrink: 0;
}

.cg-btn {
  font-size: .8rem;
  padding: .35rem .75rem;
  white-space: nowrap;
}

.cg-resolved {
  font-size: .85rem;
  color: var(--muted);
  padding: .5rem;
  text-align: center;
}

.btn-ban { background: #7c3aed; color: #fff; }
.btn-ban:hover { filter: brightness(1.15); }

/* ─── Header logo + wordmark (exact match vyndexo.com) ─────────────────────── */
.header-logo-img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  border-radius: 0;
  flex-shrink: 0;
  display: block;
  background: transparent;
}
.logo-wordmark {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: #ffffff;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.logo-vx { color: #00c8d4 !important; }
.hosted-by {
  font-size: 0.65rem;
  color: var(--muted);
  opacity: 0.55;
  letter-spacing: 0.02em;
  white-space: nowrap;
  align-self: flex-end;
  padding-bottom: 2px;
  margin-left: 4px;
}

/* ─── Logo drag-and-drop upload zone ────────────────────────────────────────── */
.logo-drop-zone {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border: 1.5px dashed var(--border);
  border-radius: 10px;
  cursor: pointer;
  transition: border-color .15s, background .15s;
  max-width: 380px;
  background: var(--surface2);
}
.logo-drop-zone:hover, .logo-drop-zone.dragover {
  border-color: var(--cyan);
  background: rgba(0,200,212,0.05);
}
#logo-drop-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.btn-xs { font-size:.72rem !important; padding:.15rem .5rem !important; line-height:1.4; border-radius:4px; cursor:pointer; }

/* ── Protection / Auto-scan ──────────────────────────────────────────────── */
.protection-section { border: 1px solid rgba(0,200,212,0.25); border-radius: 10px; background: rgba(0,200,212,0.04); }
.protection-toggle-row { margin-top: 8px; }

.autoscan-pill {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .06em;
  padding: 2px 8px;
  border-radius: 99px;
  margin-left: 8px;
  vertical-align: middle;
}
.autoscan-pill-on  { background: rgba(76,217,100,0.15); color: #4CD964; border: 1px solid rgba(76,217,100,0.35); }
.autoscan-pill-off { background: rgba(255,107,138,0.15); color: #FF6B8A; border: 1px solid rgba(255,107,138,0.35); }

.autoscan-warn-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: rgba(245,166,35,0.10);
  border: 1px solid rgba(245,166,35,0.35);
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--text-primary);
}
.autoscan-warn-banner .autoscan-warn-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.autoscan-warn-banner strong { display: block; margin-bottom: 4px; color: #F5A623; }
.autoscan-warn-banner p { color: var(--text-muted); font-size: 12px; line-height: 1.5; margin: 0; }
.autoscan-warn-banner .btn { margin-left: auto; flex-shrink: 0; align-self: flex-start; }

/* ── History Scan section ──────────────────────────────────────────────────── */
.scan-section { border: 1px solid rgba(114,137,218,0.25); border-radius: 10px; background: rgba(114,137,218,0.04); }

.scan-warn-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: rgba(245,166,35,0.10);
  border: 1px solid rgba(245,166,35,0.35);
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 16px;
  font-size: 13px;
}
.scan-warn-banner strong { display: block; margin-bottom: 4px; color: #F5A623; }
.scan-warn-banner p { color: var(--text-muted); font-size: 12px; line-height: 1.5; margin: 0; }

.scan-action-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }

.scan-status { font-size: 13px; }
.scan-status-running { color: var(--text-muted); }
.scan-status-ok  { color: #4CD964; }
.scan-status-err { color: #FF6B8A; }


/* ── About Bot tab ── */
.tab-scamguard {
  background: rgba(0,200,212,0.10) !important;
  color: #00C8D4 !important;
  border: 1px solid rgba(0,200,212,0.3) !important;
  border-radius: 8px !important;
  font-weight: 700 !important;
}
.tab-scamguard:hover {
  background: rgba(0,200,212,0.20) !important;
  transform: translateY(-1px);
}
