/* ============================================
   GUILD HUB V3 — Clean Left-Panel Layout
   Modern, high-UX sidebar + content design
   ============================================ */

:root {
  /* Core palette */
  --gh-bg: #060610;
  --gh-bg-sidebar: #0a0b16;
  --gh-bg-card: rgba(12, 14, 24, 0.9);
  --gh-bg-elevated: rgba(18, 20, 34, 0.95);
  --gh-bg-hover: rgba(28, 32, 52, 0.7);
  --gh-bg-input: rgba(10, 12, 20, 0.9);
  --gh-bg-active: rgba(0, 255, 163, 0.06);

  /* Accent — neon green */
  --gh-green: #00ffa3;
  --gh-green-dim: rgba(0, 255, 163, 0.10);
  --gh-green-glow: rgba(0, 255, 163, 0.35);
  --gh-green-dark: #00cc82;

  /* Purple */
  --gh-purple: #a855f7;
  --gh-purple-dim: rgba(168, 85, 247, 0.10);
  --gh-purple-glow: rgba(168, 85, 247, 0.3);

  /* Gold */
  --gh-gold: #fbbf24;
  --gh-gold-dim: rgba(251, 191, 36, 0.10);
  --gh-gold-glow: rgba(251, 191, 36, 0.3);

  /* Red */
  --gh-red: #f43f5e;
  --gh-red-dim: rgba(244, 63, 94, 0.10);

  /* Blue */
  --gh-blue: #3b82f6;
  --gh-blue-dim: rgba(59, 130, 246, 0.10);

  /* Orange */
  --gh-orange: #fb923c;
  --gh-cyan: #22d3ee;

  /* Text */
  --gh-text: #f1f5f9;
  --gh-text-secondary: #8b95a8;
  --gh-text-muted: #4b5568;

  /* Borders */
  --gh-border: rgba(255, 255, 255, 0.06);
  --gh-border-light: rgba(255, 255, 255, 0.09);
  --gh-border-focus: rgba(0, 255, 163, 0.35);

  /* Radius */
  --gh-radius: 14px;
  --gh-radius-lg: 20px;
  --gh-radius-sm: 10px;
  --gh-radius-xs: 6px;

  /* Shadows */
  --gh-shadow: 0 2px 16px rgba(0, 0, 0, 0.3);
  --gh-shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.45);

  /* Sidebar width */
  --sidebar-width: 280px;
}

/* ============================================
   BASE RESETS
   ============================================ */
html, body {
  margin: 0;
  padding: 0;
  background: var(--gh-bg);
  color: var(--gh-text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

#root { min-height: 100vh; }
* { scroll-behavior: smooth; box-sizing: border-box; }

/* ============================================
   LOADING STATE
   ============================================ */
.gh-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  gap: 18px;
  color: var(--gh-text-muted);
}

.gh-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255, 255, 255, 0.06);
  border-top-color: var(--gh-green);
  border-radius: 50%;
  animation: gh-spin 0.7s linear infinite;
}

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

/* ============================================
   MAIN SHELL — Sidebar + Content
   ============================================ */
.guild-hub {
  min-height: 100vh;
  position: relative;
}

.gh-shell {
  display: flex;
  min-height: 100vh;
  padding-top: 64px; /* space for navbar */
}

/* ============================================
   LEFT SIDEBAR
   ============================================ */
.gh-sidebar-panel {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  height: calc(100vh - 64px);
  position: sticky;
  top: 64px;
  display: flex;
  flex-direction: column;
  background: var(--gh-bg-sidebar);
  border-right: 1px solid var(--gh-border);
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 10;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.08) transparent;
}

.gh-sidebar-panel::-webkit-scrollbar {
  width: 4px;
}
.gh-sidebar-panel::-webkit-scrollbar-track {
  background: transparent;
}
.gh-sidebar-panel::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.08);
  border-radius: 4px;
}

/* --- Guild Identity Card --- */
.gh-side-identity {
  padding: 24px 20px 20px;
  border-bottom: 1px solid var(--gh-border);
}

.gh-side-guild-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.gh-side-emblem {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 18px;
  position: relative;
  flex-shrink: 0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.gh-side-emblem svg {
  width: 22px;
  height: 22px;
}

.gh-side-emblem-level {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: var(--gh-bg-sidebar);
  border: 2px solid var(--gh-green);
  font-size: 9px;
  font-weight: 800;
  color: var(--gh-green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Sora', 'Inter', sans-serif;
}

.gh-side-guild-info {
  flex: 1;
  min-width: 0;
}

.gh-side-guild-name {
  font-family: 'Sora', 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 800;
  color: var(--gh-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.gh-side-guild-tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--gh-green);
  letter-spacing: 0.5px;
}

.gh-side-guild-slogan {
  margin-top: 10px;
  font-size: 11.5px;
  color: var(--gh-text-secondary);
  font-style: italic;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- Quick Stats Grid --- */
.gh-side-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--gh-border);
}

.gh-side-stat {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: background 0.2s;
}

.gh-side-stat:hover {
  background: rgba(255,255,255,0.04);
}

.gh-side-stat-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gh-text-muted);
  font-weight: 600;
}

.gh-side-stat-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 14px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-side-stat-value.green { color: var(--gh-green); }
.gh-side-stat-value.gold { color: var(--gh-gold); }
.gh-side-stat-value.purple { color: var(--gh-purple); }

/* --- Navigation --- */
.gh-side-nav {
  padding: 12px 12px;
  flex: 1;
}

.gh-side-nav-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--gh-text-muted);
  font-weight: 700;
  padding: 8px 10px 6px;
  margin-top: 4px;
}

.gh-side-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--gh-radius-sm);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--gh-text-secondary);
  cursor: pointer;
  transition: all 0.15s ease;
  border: 1px solid transparent;
  text-decoration: none;
  position: relative;
}

.gh-side-nav-item:hover {
  background: var(--gh-bg-hover);
  color: var(--gh-text);
}

.gh-side-nav-item.active {
  background: var(--gh-bg-active);
  color: var(--gh-green);
  border-color: rgba(0, 255, 163, 0.12);
  font-weight: 600;
}

.gh-side-nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 18px;
  background: var(--gh-green);
  border-radius: 0 3px 3px 0;
}

.gh-side-nav-item svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  opacity: 0.7;
}

.gh-side-nav-item.active svg {
  opacity: 1;
}

.gh-side-nav-item-badge {
  margin-left: auto;
  background: var(--gh-red);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
  line-height: 1.3;
}

.gh-side-nav-item-tag {
  margin-left: auto;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--gh-green-dim);
  color: var(--gh-green);
}

/* --- Casino CTA in sidebar --- */
.gh-side-casino-cta {
  margin: 8px 12px 0;
  padding: 14px 16px;
  background: linear-gradient(135deg, rgba(0, 255, 163, 0.08) 0%, rgba(168, 85, 247, 0.06) 100%);
  border: 1px solid rgba(0, 255, 163, 0.15);
  border-radius: var(--gh-radius-sm);
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
}

.gh-side-casino-cta:hover {
  background: linear-gradient(135deg, rgba(0, 255, 163, 0.12) 0%, rgba(168, 85, 247, 0.08) 100%);
  border-color: rgba(0, 255, 163, 0.25);
  transform: translateY(-1px);
}

.gh-side-casino-cta-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  flex-shrink: 0;
}

.gh-side-casino-cta-icon svg {
  width: 18px;
  height: 18px;
}

.gh-side-casino-cta-text {
  flex: 1;
}

.gh-side-casino-cta-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-side-casino-cta-sub {
  font-size: 11px;
  color: var(--gh-text-secondary);
}

.gh-side-casino-cta-live {
  font-size: 9px;
  font-weight: 800;
  color: var(--gh-red);
  background: var(--gh-red-dim);
  padding: 3px 7px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  animation: gh-pulse-live 2s ease-in-out infinite;
}

@keyframes gh-pulse-live {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

/* --- Sidebar Footer --- */
.gh-side-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--gh-border);
}

.gh-side-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.gh-side-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--gh-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.gh-side-user-info {
  flex: 1;
  min-width: 0;
}

.gh-side-user-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--gh-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gh-side-user-role {
  font-size: 10px;
  font-weight: 600;
  text-transform: capitalize;
}

.gh-side-user-role.leader { color: var(--gh-gold); }
.gh-side-user-role.officer { color: var(--gh-purple); }
.gh-side-user-role.member { color: var(--gh-text-muted); }

/* ============================================
   MAIN CONTENT AREA
   ============================================ */
.gh-content {
  flex: 1;
  min-width: 0;
  padding: 28px 36px;
  max-width: 1160px;
}

/* Page header */
.gh-page-header {
  margin-bottom: 28px;
}

.gh-page-title {
  font-family: 'Sora', 'Inter', sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: var(--gh-text);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.gh-page-title svg {
  width: 24px;
  height: 24px;
  color: var(--gh-green);
}

.gh-page-subtitle {
  font-size: 13.5px;
  color: var(--gh-text-secondary);
  margin-top: 6px;
}

/* ============================================
   CARDS — Unified card system
   ============================================ */
.gh-card {
  background: var(--gh-bg-card);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
  overflow: hidden;
  transition: border-color 0.2s;
}

.gh-card:hover {
  border-color: var(--gh-border-light);
}

.gh-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--gh-border);
}

.gh-card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-card-title svg {
  width: 18px;
  height: 18px;
  color: var(--gh-green);
}

.gh-card-body {
  padding: 20px 22px;
}

/* ============================================
   OVERVIEW — Two-column grid
   ============================================ */
.gh-overview-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 24px;
  align-items: start;
}

.gh-overview-main {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.gh-overview-aside {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: sticky;
  top: 92px;
}

@media (max-width: 1100px) {
  .gh-overview-layout {
    grid-template-columns: 1fr;
  }
  .gh-overview-aside {
    position: static;
  }
}

/* ============================================
   CASINO QUICK-PLAY BANNER
   ============================================ */
.gh-casino-banner {
  background: linear-gradient(135deg, rgba(0, 255, 163, 0.06) 0%, rgba(168, 85, 247, 0.04) 100%);
  border: 1px solid rgba(0, 255, 163, 0.12);
  border-radius: var(--gh-radius);
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 24px;
  transition: all 0.25s;
}

.gh-casino-banner:hover {
  border-color: rgba(0, 255, 163, 0.2);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0, 255, 163, 0.06);
}

.gh-casino-banner-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  flex-shrink: 0;
  box-shadow: 0 4px 20px rgba(0, 255, 163, 0.2);
}

.gh-casino-banner-icon svg {
  width: 26px;
  height: 26px;
}

.gh-casino-banner-text {
  flex: 1;
}

.gh-casino-banner-title {
  font-family: 'Sora', 'Inter', sans-serif;
  font-size: 18px;
  font-weight: 800;
  color: var(--gh-text);
}

.gh-casino-banner-desc {
  font-size: 13px;
  color: var(--gh-text-secondary);
  margin-top: 4px;
}

.gh-casino-banner-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.gh-casino-banner-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--gh-radius-sm);
  font-size: 13px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
}

.gh-casino-banner-btn.primary {
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  color: #000;
}

.gh-casino-banner-btn.primary:hover {
  box-shadow: 0 4px 16px rgba(0, 255, 163, 0.25);
  transform: translateY(-1px);
}

.gh-casino-banner-btn.secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--gh-text);
  border: 1px solid var(--gh-border-light);
}

.gh-casino-banner-btn.secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.gh-casino-banner-btn svg {
  width: 16px;
  height: 16px;
}

/* ============================================
   QUICK ACTIONS — Compact row
   ============================================ */
.gh-quick-actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.gh-section-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--gh-text);
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.gh-section-title svg {
  width: 18px;
  height: 18px;
  color: var(--gh-green);
}

.gh-quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.gh-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 20px 12px;
  background: var(--gh-bg-card);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  color: var(--gh-text);
  font-size: 12.5px;
  font-weight: 600;
}

.gh-action-btn:hover {
  background: var(--gh-bg-hover);
  border-color: var(--gh-border-light);
  transform: translateY(-2px);
}

.gh-action-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-action-icon svg {
  width: 20px;
  height: 20px;
}

.gh-action-btn.invite .gh-action-icon {
  background: var(--gh-purple-dim);
  color: var(--gh-purple);
}

.gh-action-btn.play .gh-action-icon {
  background: var(--gh-green-dim);
  color: var(--gh-green);
}

.gh-action-btn.games .gh-action-icon {
  background: var(--gh-gold-dim);
  color: var(--gh-gold);
}

/* --- Leader Casino Banner --- */
.gh-leader-casino-btn {
  width: 100%;
  padding: 14px 18px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.06) 0%, rgba(168, 85, 247, 0.04) 100%);
  border: 1px solid rgba(251, 191, 36, 0.15);
  border-radius: var(--gh-radius);
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  overflow: hidden;
}

.gh-leader-casino-btn:hover {
  border-color: rgba(251, 191, 36, 0.25);
  transform: translateY(-1px);
}

.gh-leader-casino-btn-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 50%, rgba(251, 191, 36, 0.06), transparent 70%);
  pointer-events: none;
}

.gh-leader-casino-btn-content {
  display: flex;
  align-items: center;
  gap: 14px;
  position: relative;
}

.gh-leader-casino-btn-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--gh-gold), #f59e0b);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  flex-shrink: 0;
}

.gh-leader-casino-btn-icon svg {
  width: 18px;
  height: 18px;
}

.gh-leader-casino-btn-text {
  flex: 1;
  text-align: left;
}

.gh-leader-casino-btn-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
  display: block;
}

.gh-leader-casino-btn-sub {
  font-size: 11px;
  color: var(--gh-text-secondary);
  display: block;
}

.gh-leader-casino-btn-balance {
  text-align: right;
}

.gh-leader-casino-btn-balance-label {
  font-size: 10px;
  color: var(--gh-text-muted);
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gh-leader-casino-btn-balance-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 14px;
  font-weight: 700;
  color: var(--gh-gold);
  display: block;
}

.gh-leader-casino-btn-arrow {
  color: var(--gh-text-muted);
}

.gh-leader-casino-btn-arrow svg {
  width: 16px;
  height: 16px;
}

/* ============================================
   HIGHLIGHTS
   ============================================ */
.gh-highlights .gh-card-body {
  padding: 16px 22px 20px;
}

.gh-highlights-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.gh-highlight-item {
  text-align: center;
}

.gh-highlight-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gh-text-muted);
  font-weight: 600;
  margin-bottom: 8px;
}

.gh-highlight-value {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gh-text);
}

.gh-highlight-value.big {
  font-family: 'Sora', 'JetBrains Mono', monospace;
  font-size: 22px;
  font-weight: 800;
  color: var(--gh-green);
}

.gh-highlight-value.rank {
  color: var(--gh-gold);
}

.gh-highlight-avatar {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: var(--gh-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.gh-highlight-avatar.new {
  background: var(--gh-green);
  color: #000;
}

/* Achievements */
.gh-achievements-section {
  border-top: 1px solid var(--gh-border);
  padding-top: 16px;
}

.gh-achievements-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
}

.gh-achievements-title svg {
  width: 16px;
  height: 16px;
  color: var(--gh-gold);
}

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

.gh-achievement {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--gh-radius-xs);
  border: 1px solid var(--gh-border);
  background: rgba(255,255,255,0.02);
  font-size: 11.5px;
  font-weight: 600;
  transition: all 0.2s;
}

.gh-achievement.unlocked {
  border-color: rgba(0, 255, 163, 0.15);
  background: rgba(0, 255, 163, 0.04);
  color: var(--gh-green);
}

.gh-achievement.locked {
  opacity: 0.4;
  color: var(--gh-text-muted);
}

.gh-achievement-icon {
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-achievement-icon svg {
  width: 14px;
  height: 14px;
}

.gh-achievement-name {
  white-space: nowrap;
}

/* ============================================
   LIVE ACTIVITY FEED
   ============================================ */
.gh-activity-feed {
  max-height: 420px;
  overflow-y: auto;
}

.gh-activity-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--gh-border);
}

.gh-activity-item:last-child {
  border-bottom: none;
}

.gh-activity-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.gh-activity-icon svg {
  width: 16px;
  height: 16px;
}

.gh-activity-icon.win {
  background: var(--gh-green-dim);
  color: var(--gh-green);
}

.gh-activity-icon.loss {
  background: var(--gh-red-dim);
  color: var(--gh-red);
}

.gh-activity-icon.jackpot {
  background: var(--gh-gold-dim);
  color: var(--gh-gold);
}

.gh-activity-icon.join {
  background: var(--gh-blue-dim);
  color: var(--gh-blue);
}

.gh-activity-content {
  flex: 1;
  min-width: 0;
}

.gh-activity-text {
  font-size: 12.5px;
  color: var(--gh-text-secondary);
  line-height: 1.4;
}

.gh-activity-text strong {
  color: var(--gh-text);
  font-weight: 600;
}

.gh-activity-text .amount {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  color: var(--gh-green);
}

.gh-activity-text .amount.loss {
  color: var(--gh-red);
}

.gh-activity-time {
  font-size: 11px;
  color: var(--gh-text-muted);
  margin-top: 2px;
}

/* War Live Badge */
.gh-war-live {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 800;
  color: var(--gh-red);
  letter-spacing: 0.5px;
}

.gh-war-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gh-red);
  animation: gh-pulse-live 2s ease-in-out infinite;
}

/* ============================================
   BUTTONS — Shared
   ============================================ */
.gh-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--gh-radius-sm);
  font-size: 13px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}

.gh-btn svg {
  width: 16px;
  height: 16px;
}

.gh-btn-primary {
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  color: #000;
}

.gh-btn-primary:hover {
  box-shadow: 0 4px 16px rgba(0, 255, 163, 0.2);
  transform: translateY(-1px);
}

.gh-btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.gh-btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--gh-text);
  border: 1px solid var(--gh-border-light);
}

.gh-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.gh-btn-danger {
  background: var(--gh-red);
  color: #fff;
}

.gh-btn-danger-outline {
  background: var(--gh-red-dim);
  color: var(--gh-red);
  border: 1px solid rgba(244, 63, 94, 0.2);
}

.gh-btn-war {
  background: linear-gradient(135deg, var(--gh-purple), #7c3aed);
  color: #fff;
}

.gh-btn-sm {
  padding: 7px 14px;
  font-size: 12px;
}

/* ============================================
   FORMS — Inputs, toggles
   ============================================ */
.gh-input {
  width: 100%;
  padding: 10px 14px;
  background: var(--gh-bg-input);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  color: var(--gh-text);
  font-size: 13px;
  transition: border-color 0.2s;
  outline: none;
  font-family: inherit;
}

.gh-input:focus {
  border-color: var(--gh-border-focus);
}

.gh-input::placeholder {
  color: var(--gh-text-muted);
}

.gh-select { cursor: pointer; }

.gh-textarea {
  resize: vertical;
  min-height: 60px;
}

.gh-form-group {
  margin-bottom: 16px;
}

.gh-form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--gh-text-secondary);
  margin-bottom: 6px;
}

.gh-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* Donate input */
.gh-donate-input-wrap {
  display: flex;
  align-items: center;
  background: var(--gh-bg-input);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  overflow: hidden;
}

.gh-donate-input-wrap:focus-within {
  border-color: var(--gh-border-focus);
}

.gh-donate-prefix {
  padding: 0 10px;
  font-size: 14px;
  font-weight: 700;
  color: var(--gh-green);
}

.gh-donate-input {
  flex: 1;
  padding: 10px 12px 10px 0;
  background: transparent;
  border: none;
  color: var(--gh-text);
  font-size: 14px;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  outline: none;
}

.gh-donate-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.gh-preset-btn {
  padding: 6px 14px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  background: rgba(255,255,255,0.02);
  color: var(--gh-text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.gh-preset-btn:hover {
  background: rgba(255,255,255,0.06);
  color: var(--gh-text);
}

.gh-preset-btn.active {
  border-color: var(--gh-green);
  color: var(--gh-green);
  background: var(--gh-green-dim);
}

/* Toggle */
.gh-toggle-group {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
}

.gh-toggle-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.gh-toggle-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--gh-text);
}

.gh-toggle-desc {
  font-size: 11.5px;
  color: var(--gh-text-muted);
}

.gh-toggle {
  width: 44px;
  height: 24px;
  border-radius: 12px;
  background: rgba(255,255,255,0.08);
  border: none;
  cursor: pointer;
  position: relative;
  transition: background 0.2s;
}

.gh-toggle.active {
  background: var(--gh-green);
}

.gh-toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s;
}

.gh-toggle.active .gh-toggle-thumb {
  transform: translateX(20px);
}

/* ============================================
   MODALS
   ============================================ */
.gh-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 24px;
}

.gh-modal {
  background: var(--gh-bg-elevated);
  border: 1px solid var(--gh-border-light);
  border-radius: var(--gh-radius-lg);
  width: 100%;
  max-width: 480px;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}

.gh-modal-lg {
  max-width: 600px;
}

.gh-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--gh-border);
}

.gh-modal-header h3 {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.gh-modal-header h3 svg {
  width: 20px;
  height: 20px;
  color: var(--gh-green);
}

.gh-modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  border: none;
  color: var(--gh-text-secondary);
  cursor: pointer;
  transition: all 0.15s;
}

.gh-modal-close:hover {
  background: rgba(255,255,255,0.1);
  color: var(--gh-text);
}

.gh-modal-close svg {
  width: 16px;
  height: 16px;
}

.gh-modal-body {
  padding: 24px;
}

.gh-modal-body p {
  font-size: 13px;
  color: var(--gh-text-secondary);
  line-height: 1.5;
  margin: 0 0 16px;
}

.gh-modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 24px;
  border-top: 1px solid var(--gh-border);
}

/* ============================================
   EMPTY STATES
   ============================================ */
.gh-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  text-align: center;
  color: var(--gh-text-muted);
}

.gh-empty-icon {
  width: 48px;
  height: 48px;
  margin-bottom: 12px;
  color: var(--gh-text-muted);
  opacity: 0.5;
}

.gh-empty-icon svg {
  width: 48px;
  height: 48px;
}

.gh-empty-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--gh-text-secondary);
  margin-bottom: 6px;
}

.gh-empty-text {
  font-size: 13px;
  color: var(--gh-text-muted);
  max-width: 320px;
}

.gh-empty-small {
  padding: 16px;
  text-align: center;
  color: var(--gh-text-muted);
  font-size: 13px;
}

/* ============================================
   ACTION MESSAGES
   ============================================ */
.gh-action-message {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--gh-radius-sm);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 16px;
}

.gh-action-message svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.gh-action-message.success {
  background: var(--gh-green-dim);
  color: var(--gh-green);
  border: 1px solid rgba(0, 255, 163, 0.15);
}

.gh-action-message.error {
  background: var(--gh-red-dim);
  color: var(--gh-red);
  border: 1px solid rgba(244, 63, 94, 0.15);
}

/* ============================================
   NO GUILD STATE
   ============================================ */
.gh-no-guild {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 200px);
  text-align: center;
  padding: 40px 24px;
}

.gh-no-guild-icon {
  width: 72px;
  height: 72px;
  color: var(--gh-purple);
  margin-bottom: 20px;
  opacity: 0.6;
}

.gh-no-guild-icon svg {
  width: 72px;
  height: 72px;
}

.gh-no-guild h2 {
  font-family: 'Sora', 'Inter', sans-serif;
  font-size: 28px;
  font-weight: 800;
  margin: 0 0 10px;
}

.gh-no-guild p {
  font-size: 14px;
  color: var(--gh-text-secondary);
  max-width: 420px;
  line-height: 1.5;
  margin-bottom: 24px;
}

.gh-no-guild-actions {
  display: flex;
  gap: 14px;
}

.gh-no-guild-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--gh-radius);
  font-size: 14px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}

.gh-no-guild-btn svg {
  width: 18px;
  height: 18px;
}

.gh-no-guild-btn.create {
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  color: #000;
}

.gh-no-guild-btn.create:hover {
  box-shadow: 0 6px 24px rgba(0, 255, 163, 0.25);
  transform: translateY(-2px);
}

.gh-no-guild-btn.browse {
  background: rgba(255,255,255,0.06);
  color: var(--gh-text);
  border: 1px solid var(--gh-border-light);
}

.gh-no-guild-btn.browse:hover {
  background: rgba(255,255,255,0.1);
}

/* ============================================
   SETTINGS — Sections
   ============================================ */
.gh-settings-section {
  margin-bottom: 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--gh-border);
}

.gh-settings-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.gh-settings-section h4 {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.gh-settings-section h4 svg {
  width: 16px;
  height: 16px;
  color: var(--gh-green);
}

.gh-settings-actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 16px;
}

/* Treasury info */
.gh-treasury-info { margin-bottom: 16px; }

.gh-treasury-balance {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
}

.gh-treasury-label {
  font-size: 12px;
  color: var(--gh-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gh-treasury-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  color: var(--gh-green);
}

.gh-treasury-actions {
  display: flex;
  gap: 10px;
}

/* ============================================
   MEMBERS — Grid + Search + Cards
   ============================================ */
.gh-members-controls {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.gh-members-search {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--gh-bg-input);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  padding: 0 12px;
}

.gh-members-search:focus-within {
  border-color: var(--gh-border-focus);
}

.gh-search-icon {
  color: var(--gh-text-muted);
}

.gh-search-icon svg {
  width: 16px;
  height: 16px;
}

.gh-members-search-input {
  flex: 1;
  padding: 9px 0;
  background: transparent;
  border: none;
  color: var(--gh-text);
  font-size: 13px;
  outline: none;
}

.gh-members-search-input::placeholder {
  color: var(--gh-text-muted);
}

.gh-members-filters {
  display: flex;
  gap: 6px;
}

.gh-filter-btn {
  padding: 7px 14px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  background: transparent;
  color: var(--gh-text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.gh-filter-btn.active {
  background: var(--gh-green-dim);
  border-color: rgba(0, 255, 163, 0.15);
  color: var(--gh-green);
}

.gh-filter-btn:hover:not(.active) {
  background: rgba(255,255,255,0.04);
}

.gh-members-online-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--gh-green);
}

.gh-online-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gh-green);
  box-shadow: 0 0 8px var(--gh-green-glow);
}

.gh-members-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}

.gh-member-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
  padding: 18px 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
}

.gh-member-card:hover {
  border-color: var(--gh-border-light);
  background: rgba(255,255,255,0.04);
}

.gh-member-card.leader {
  border-color: rgba(251, 191, 36, 0.15);
}

.gh-member-card-top {
  position: relative;
  display: flex;
  justify-content: center;
  margin-bottom: 10px;
}

.gh-member-avatar-lg {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  position: relative;
}

.gh-member-avatar-lg.leader { background: var(--gh-gold); color: #000; }
.gh-member-avatar-lg.officer { background: var(--gh-purple); }
.gh-member-avatar-lg.member { background: rgba(255,255,255,0.1); }

.gh-member-status-dot {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid var(--gh-bg-card);
}

.gh-member-status-dot.online {
  background: var(--gh-green);
}

.gh-member-status-dot.offline {
  background: var(--gh-text-muted);
}

.gh-member-role-icon {
  position: absolute;
  top: -4px;
  right: calc(50% - 30px);
  width: 18px;
  height: 18px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-member-role-icon svg {
  width: 12px;
  height: 12px;
}

.gh-member-role-icon.leader {
  background: var(--gh-gold-dim);
  color: var(--gh-gold);
}

.gh-member-role-icon.officer {
  background: var(--gh-purple-dim);
  color: var(--gh-purple);
}

.gh-member-card-info {
  margin-bottom: 12px;
}

.gh-member-card-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
  text-decoration: none;
  display: block;
}

.gh-member-card-name:hover {
  color: var(--gh-green);
}

.gh-member-card-role {
  font-size: 10.5px;
  font-weight: 600;
  text-transform: capitalize;
}

.gh-member-card-role.leader { color: var(--gh-gold); }
.gh-member-card-role.officer { color: var(--gh-purple); }
.gh-member-card-role.member { color: var(--gh-text-muted); }

.gh-member-card-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.gh-member-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.gh-member-stat-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-member-stat-label {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gh-text-muted);
  font-weight: 600;
}

.gh-member-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--gh-border);
}

.gh-member-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border-radius: var(--gh-radius-xs);
  font-size: 11px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}

.gh-member-action svg {
  width: 12px;
  height: 12px;
}

.gh-member-action.view {
  background: var(--gh-blue-dim);
  color: var(--gh-blue);
}

.gh-member-action.promote {
  background: var(--gh-green-dim);
  color: var(--gh-green);
}

.gh-member-action.demote {
  background: var(--gh-gold-dim);
  color: var(--gh-gold);
}

.gh-member-action.kick {
  background: var(--gh-red-dim);
  color: var(--gh-red);
}

/* ============================================
   RANKINGS — Leaderboard
   ============================================ */
.gh-ranking-categories {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.gh-ranking-cat {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  background: transparent;
  color: var(--gh-text-secondary);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.gh-ranking-cat svg {
  width: 14px;
  height: 14px;
}

.gh-ranking-cat.active {
  background: var(--gh-green-dim);
  border-color: rgba(0, 255, 163, 0.15);
  color: var(--gh-green);
}

.gh-leaderboard {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.gh-leaderboard-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: var(--gh-radius-sm);
  transition: background 0.15s;
}

.gh-leaderboard-item:hover {
  background: rgba(255,255,255,0.03);
}

.gh-leaderboard-item.gold {
  background: rgba(251, 191, 36, 0.04);
  border: 1px solid rgba(251, 191, 36, 0.1);
}

.gh-leaderboard-item.silver {
  background: rgba(229, 231, 235, 0.03);
}

.gh-leaderboard-item.bronze {
  background: rgba(251, 146, 60, 0.03);
}

.gh-leaderboard-rank {
  width: 28px;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text-muted);
}

.gh-medal {
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-medal svg {
  width: 18px;
  height: 18px;
}

.gh-medal.gold { color: var(--gh-gold); }
.gh-medal.silver { color: #e5e7eb; }
.gh-medal.bronze { color: var(--gh-orange); }

.gh-leaderboard-user {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex: 1;
  min-width: 0;
}

.gh-leaderboard-avatar {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.gh-leaderboard-info {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.gh-leaderboard-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--gh-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gh-leaderboard-role {
  font-size: 10px;
  font-weight: 700;
  text-transform: capitalize;
  padding: 2px 6px;
  border-radius: 4px;
}

.gh-leaderboard-role.leader {
  background: var(--gh-gold-dim);
  color: var(--gh-gold);
}

.gh-leaderboard-role.officer {
  background: var(--gh-purple-dim);
  color: var(--gh-purple);
}

.gh-leaderboard-role.member {
  display: none;
}

.gh-leaderboard-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
  white-space: nowrap;
}

.gh-leaderboard-trend {
  width: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-leaderboard-trend svg {
  width: 14px;
  height: 14px;
}

.gh-leaderboard-trend.up { color: var(--gh-green); }

/* ============================================
   CHAT
   ============================================ */
.gh-chat {
  display: flex;
  flex-direction: column;
  max-height: 600px;
}

.gh-chat .gh-card-body {
  display: none;
}

.gh-chat-online {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--gh-text-muted);
}

.gh-chat-online-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gh-green);
}

.gh-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
  min-height: 300px;
  max-height: 480px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gh-chat-message {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.gh-chat-avatar {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--gh-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.gh-chat-bubble {
  flex: 1;
  min-width: 0;
}

.gh-chat-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.gh-chat-username {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-chat-role {
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 1px 5px;
  border-radius: 3px;
}

.gh-chat-role.leader {
  background: var(--gh-gold-dim);
  color: var(--gh-gold);
}

.gh-chat-role.officer {
  background: var(--gh-purple-dim);
  color: var(--gh-purple);
}

.gh-chat-time {
  font-size: 10.5px;
  color: var(--gh-text-muted);
}

.gh-chat-text {
  font-size: 13px;
  color: var(--gh-text-secondary);
  line-height: 1.45;
  word-break: break-word;
}

.gh-chat-input-area {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  border-top: 1px solid var(--gh-border);
}

.gh-chat-input {
  flex: 1;
  padding: 10px 14px;
  background: var(--gh-bg-input);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  color: var(--gh-text);
  font-size: 13px;
  outline: none;
  font-family: inherit;
}

.gh-chat-input:focus {
  border-color: var(--gh-border-focus);
}

.gh-chat-input::placeholder {
  color: var(--gh-text-muted);
}

.gh-chat-send {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  color: #000;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  flex-shrink: 0;
}

.gh-chat-send:hover {
  transform: scale(1.05);
}

.gh-chat-send:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

.gh-chat-send svg {
  width: 16px;
  height: 16px;
}

/* ============================================
   GUILD WARS
   ============================================ */
.gh-war-card {
  border-radius: var(--gh-radius);
  padding: 20px;
}

.gh-war-card.active {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.06) 0%, rgba(0, 255, 163, 0.04) 100%);
  border: 1px solid rgba(168, 85, 247, 0.12);
}

.gh-war-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.gh-war-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
}

.gh-war-subtitle {
  font-size: 12px;
  color: var(--gh-text-secondary);
  margin: 2px 0 0;
}

.gh-war-vs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.gh-war-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.gh-war-team-emblem {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}

.gh-war-team-emblem svg {
  width: 22px;
  height: 22px;
}

.gh-war-team-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-war-team-score {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 800;
  color: var(--gh-green);
}

.gh-war-vs-badge {
  font-family: 'Sora', 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 900;
  color: var(--gh-text-muted);
  padding: 0 16px;
}

.gh-war-progress {
  margin-bottom: 16px;
}

.gh-war-progress-label {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 700;
  color: var(--gh-text-muted);
  margin-bottom: 6px;
}

.gh-war-progress-bar {
  height: 6px;
  border-radius: 3px;
  background: rgba(255,255,255,0.06);
  display: flex;
  overflow: hidden;
}

.gh-war-progress-fill.team1 {
  background: var(--gh-green);
  border-radius: 3px 0 0 3px;
}

.gh-war-progress-fill.team2 {
  background: var(--gh-purple);
  border-radius: 0 3px 3px 0;
}

.gh-war-timer {
  text-align: center;
  margin-bottom: 14px;
}

.gh-war-timer-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gh-text-muted);
  margin-bottom: 4px;
}

.gh-war-timer-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 24px;
  font-weight: 800;
  color: var(--gh-text);
  letter-spacing: 2px;
}

.gh-war-tip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.03);
  border-radius: var(--gh-radius-xs);
  font-size: 12px;
  color: var(--gh-text-secondary);
}

.gh-war-tip svg {
  width: 16px;
  height: 16px;
  color: var(--gh-green);
  flex-shrink: 0;
}

/* War pending */
.gh-war-pending {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 30px 20px;
}

.gh-war-pending-icon {
  position: relative;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  color: var(--gh-purple);
}

.gh-war-pending-icon svg {
  width: 28px;
  height: 28px;
}

.gh-war-pending-spinner {
  position: absolute;
  inset: -4px;
  border: 2px solid transparent;
  border-top-color: var(--gh-purple);
  border-radius: 50%;
  animation: gh-spin 1.5s linear infinite;
}

.gh-war-pending-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 800;
  color: var(--gh-gold);
  letter-spacing: 0.5px;
}

.gh-war-pending-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gh-gold);
  animation: gh-pulse-live 2s ease-in-out infinite;
}

.gh-war-pending-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 6px;
}

.gh-war-pending-text {
  font-size: 13px;
  color: var(--gh-text-secondary);
  margin: 0 0 4px;
}

.gh-war-pending-sub {
  font-size: 12px;
  color: var(--gh-text-muted);
  margin: 0 0 16px;
}

/* Available wars */
.gh-available-wars {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--gh-border);
}

.gh-available-wars-title {
  font-size: 13px;
  font-weight: 700;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.gh-available-wars-title svg {
  width: 14px;
  height: 14px;
  color: var(--gh-gold);
}

.gh-available-war {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
  margin-bottom: 8px;
}

.gh-available-war-guild {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
}

.gh-available-war-tag {
  color: var(--gh-green);
  font-weight: 700;
}

.gh-available-war-details {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--gh-text-muted);
  margin-top: 2px;
}

.gh-available-war-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--gh-text-muted);
}

/* War info & rules */
.gh-war-info {
  display: flex;
  gap: 14px;
  margin-bottom: 16px;
}

.gh-war-info-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  background: rgba(255,255,255,0.03);
  border-radius: var(--gh-radius-xs);
}

.gh-war-info-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gh-text-muted);
}

.gh-war-info-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-war-rules {
  background: rgba(255,255,255,0.02);
  border-radius: var(--gh-radius-xs);
  padding: 14px 16px;
  margin-top: 16px;
}

.gh-war-rules h5 {
  font-size: 12px;
  font-weight: 700;
  margin: 0 0 8px;
}

.gh-war-rules ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.gh-war-rules li {
  font-size: 12px;
  color: var(--gh-text-secondary);
  padding: 3px 0;
  padding-left: 16px;
  position: relative;
}

.gh-war-rules li::before {
  content: '•';
  position: absolute;
  left: 4px;
  color: var(--gh-green);
}

/* ============================================
   RAFFLES
   ============================================ */
.gh-raffles-section {
  margin-bottom: 24px;
}

.gh-raffles-section-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.gh-raffles-section-title svg {
  width: 16px;
  height: 16px;
}

.gh-raffles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}

.gh-raffle-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
  padding: 18px;
}

.gh-raffle-card.active {
  border-color: rgba(0, 255, 163, 0.12);
}

.gh-raffle-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.gh-raffle-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0;
}

.gh-raffle-time {
  font-size: 11px;
  font-weight: 700;
  color: var(--gh-gold);
  background: var(--gh-gold-dim);
  padding: 3px 8px;
  border-radius: 4px;
}

.gh-raffle-desc {
  font-size: 12px;
  color: var(--gh-text-secondary);
  margin: 0 0 12px;
}

.gh-raffle-prize {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: rgba(0, 255, 163, 0.04);
  border-radius: var(--gh-radius-xs);
  margin-bottom: 12px;
}

.gh-raffle-prize-label {
  font-size: 11px;
  color: var(--gh-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gh-raffle-prize-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 800;
  color: var(--gh-green);
}

.gh-raffle-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.gh-raffle-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-raffle-stat-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--gh-text-muted);
}

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

.gh-raffle-actions .gh-btn {
  flex: 1;
  justify-content: center;
}

/* Past raffles */
.gh-raffles-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.gh-raffle-past {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: rgba(255,255,255,0.02);
  border-radius: var(--gh-radius-xs);
}

.gh-raffle-past-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--gh-text);
}

.gh-raffle-past-prize {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  color: var(--gh-green);
  margin-left: 8px;
}

.gh-raffle-past-winner {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--gh-text-secondary);
}

.gh-raffle-past-winner-icon {
  color: var(--gh-gold);
}

.gh-raffle-past-winner-icon svg {
  width: 14px;
  height: 14px;
}

.gh-raffle-past-cancelled {
  color: var(--gh-text-muted);
  font-style: italic;
}

.gh-raffle-summary {
  padding: 12px;
  background: rgba(255,255,255,0.02);
  border-radius: var(--gh-radius-xs);
  font-size: 12px;
  color: var(--gh-text-secondary);
}

.gh-raffle-summary strong {
  color: var(--gh-green);
}

/* ============================================
   CHALLENGES
   ============================================ */
.gh-challenges {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.gh-challenge {
  padding: 14px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
}

.gh-challenge-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.gh-challenge-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text);
}

.gh-challenge-title svg {
  width: 16px;
  height: 16px;
  color: var(--gh-green);
}

.gh-challenge-reward {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--gh-gold);
}

.gh-challenge-progress {
  margin-bottom: 6px;
}

.gh-challenge-progress-bar {
  height: 4px;
  background: rgba(255,255,255,0.06);
  border-radius: 2px;
  overflow: hidden;
}

.gh-challenge-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gh-green), var(--gh-green-dark));
  border-radius: 2px;
  transition: width 0.3s;
}

.gh-challenge-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--gh-text-muted);
}

/* ============================================
   LCD — Leader Casino Dashboard overlay
   (Keeping all LCD styles since this is a modal)
   ============================================ */
.lcd-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.lcd-container {
  background: var(--gh-bg-elevated);
  border: 1px solid var(--gh-border-light);
  border-radius: var(--gh-radius-lg);
  width: 100%;
  max-width: 960px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 32px 100px rgba(0, 0, 0, 0.7);
}

.lcd-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--gh-border);
}

.lcd-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.lcd-header-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--gh-gold), #f59e0b);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
}

.lcd-header-icon svg {
  width: 20px;
  height: 20px;
}

.lcd-header-text h2 {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
}

.lcd-header-text span {
  font-size: 12px;
  color: var(--gh-text-secondary);
}

.lcd-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  border: none;
  color: var(--gh-text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lcd-close svg {
  width: 16px;
  height: 16px;
}

.lcd-close:hover {
  background: rgba(255,255,255,0.1);
  color: var(--gh-text);
}

.lcd-action-msg {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 24px 0;
  padding: 12px 16px;
  border-radius: var(--gh-radius-sm);
  font-size: 13px;
  font-weight: 600;
}

.lcd-action-msg svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.lcd-action-msg.success {
  background: var(--gh-green-dim);
  color: var(--gh-green);
  border: 1px solid rgba(0, 255, 163, 0.15);
}

.lcd-action-msg.error {
  background: var(--gh-red-dim);
  color: var(--gh-red);
  border: 1px solid rgba(244, 63, 94, 0.15);
}

.lcd-loading, .lcd-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px;
  gap: 16px;
  color: var(--gh-text-muted);
}

.lcd-body {
  padding: 20px 24px;
}

.lcd-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.lcd-stat-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
}

.lcd-stat-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lcd-stat-icon svg {
  width: 18px;
  height: 18px;
}

.lcd-stat-treasury .lcd-stat-icon { background: var(--gh-green-dim); color: var(--gh-green); }
.lcd-stat-personal .lcd-stat-icon { background: var(--gh-purple-dim); color: var(--gh-purple); }
.lcd-stat-wagered .lcd-stat-icon { background: var(--gh-gold-dim); color: var(--gh-gold); }
.lcd-stat-profit .lcd-stat-icon { background: var(--gh-blue-dim); color: var(--gh-blue); }

.lcd-stat-label {
  font-size: 10px;
  color: var(--gh-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.lcd-stat-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 15px;
  font-weight: 700;
  color: var(--gh-text);
}

.lcd-stat-value.positive { color: var(--gh-green); }
.lcd-stat-value.negative { color: var(--gh-red); }

.lcd-nav {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
  overflow-x: auto;
}

.lcd-nav-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  background: transparent;
  color: var(--gh-text-secondary);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.lcd-nav-pill svg {
  width: 14px;
  height: 14px;
}

.lcd-nav-pill.active {
  background: var(--gh-green-dim);
  border-color: rgba(0, 255, 163, 0.15);
  color: var(--gh-green);
}

.lcd-panel { padding: 4px 0; }

/* Fund grid */
.lcd-fund-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.lcd-fund-card {
  padding: 20px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
  background: rgba(255,255,255,0.02);
}

.lcd-fund-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.lcd-fund-card-header h3 {
  font-size: 14px;
  font-weight: 700;
  margin: 0;
}

.lcd-fund-card-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lcd-fund-card-icon svg {
  width: 16px;
  height: 16px;
}

.lcd-fund-card-icon.deposit {
  background: var(--gh-green-dim);
  color: var(--gh-green);
}

.lcd-fund-card-icon.withdraw {
  background: var(--gh-red-dim);
  color: var(--gh-red);
}

.lcd-fund-desc {
  font-size: 12px;
  color: var(--gh-text-muted);
  line-height: 1.4;
  margin-bottom: 14px;
}

.lcd-fund-input-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.lcd-fund-input-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  background: var(--gh-bg-input);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  overflow: hidden;
}

.lcd-fund-input-wrap:focus-within {
  border-color: var(--gh-border-focus);
}

.lcd-fund-prefix {
  padding: 0 10px;
  font-size: 14px;
  font-weight: 700;
  color: var(--gh-green);
}

.lcd-fund-input {
  flex: 1;
  padding: 10px 10px 10px 0;
  background: transparent;
  border: none;
  color: var(--gh-text);
  font-size: 14px;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  outline: none;
}

.lcd-fund-btn {
  padding: 10px 18px;
  border: none;
  border-radius: var(--gh-radius-xs);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.lcd-fund-btn.deposit {
  background: linear-gradient(135deg, var(--gh-green), var(--gh-green-dark));
  color: #000;
}

.lcd-fund-btn.withdraw {
  background: var(--gh-red);
  color: #fff;
}

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

.lcd-fund-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.lcd-preset {
  padding: 5px 12px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  background: rgba(255,255,255,0.02);
  color: var(--gh-text-secondary);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.lcd-preset:hover {
  background: rgba(255,255,255,0.06);
  color: var(--gh-text);
}

.lcd-fund-available {
  font-size: 11.5px;
  color: var(--gh-text-muted);
}

.lcd-fund-available strong {
  color: var(--gh-green);
}

.lcd-info-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
  font-size: 12px;
  color: var(--gh-text-secondary);
  line-height: 1.4;
}

.lcd-info-banner svg {
  width: 18px;
  height: 18px;
  color: var(--gh-green);
  flex-shrink: 0;
  margin-top: 1px;
}

.lcd-info-banner strong {
  color: var(--gh-text);
}

/* Performance grid */
.lcd-perf-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.lcd-perf-card {
  padding: 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-sm);
}

.lcd-perf-label {
  font-size: 11px;
  color: var(--gh-text-muted);
  margin-bottom: 6px;
}

.lcd-perf-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  font-weight: 800;
  color: var(--gh-text);
}

.lcd-perf-value.positive { color: var(--gh-green); }
.lcd-perf-value.negative { color: var(--gh-red); }
.lcd-perf-value.fee { color: var(--gh-orange); }

.lcd-perf-sub {
  font-size: 10.5px;
  color: var(--gh-text-muted);
  margin-top: 4px;
}

/* Transactions */
.lcd-transactions-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 400px;
  overflow-y: auto;
}

.lcd-tx-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--gh-radius-xs);
  transition: background 0.15s;
}

.lcd-tx-row:hover {
  background: rgba(255,255,255,0.03);
}

.lcd-tx-icon {
  font-size: 18px;
  flex-shrink: 0;
}

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

.lcd-tx-desc {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--gh-text);
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lcd-tx-time {
  font-size: 10.5px;
  color: var(--gh-text-muted);
  display: block;
}

.lcd-tx-amount {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.lcd-tx-balance {
  font-size: 11px;
  color: var(--gh-text-muted);
  white-space: nowrap;
}

.lcd-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px;
  color: var(--gh-text-muted);
}

/* Members in LCD */
.lcd-members-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.lcd-member-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--gh-radius-xs);
  transition: background 0.15s;
}

.lcd-member-row:hover {
  background: rgba(255,255,255,0.03);
}

.lcd-member-rank {
  font-size: 13px;
  font-weight: 700;
  color: var(--gh-text-muted);
  width: 28px;
  text-align: center;
}

.lcd-member-avatar {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

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

.lcd-member-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--gh-text);
  display: block;
}

.lcd-member-role {
  font-size: 10px;
  font-weight: 700;
  text-transform: capitalize;
}

.lcd-member-role.leader { color: var(--gh-gold); }
.lcd-member-role.officer { color: var(--gh-purple); }
.lcd-member-role.member { color: var(--gh-text-muted); }

.lcd-member-stats {
  display: flex;
  gap: 16px;
}

.lcd-member-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: right;
}

.lcd-member-stat-label {
  font-size: 9.5px;
  text-transform: uppercase;
  color: var(--gh-text-muted);
  letter-spacing: 0.5px;
}

.lcd-member-stat-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--gh-text);
}

/* ============================================
   CASINO — Game area styles
   ============================================ */
.gh-casino {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.gh-casino-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
}

.gh-casino-treasury-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gh-text-muted);
  display: block;
}

.gh-casino-treasury-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 20px;
  font-weight: 800;
  color: var(--gh-green);
}

.gh-casino-info-text {
  font-size: 12px;
  color: var(--gh-text-muted);
  max-width: 320px;
  text-align: right;
}

.gh-casino-games {
  display: flex;
  gap: 10px;
}

.gh-casino-game-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
  background: rgba(255,255,255,0.02);
  cursor: pointer;
  transition: all 0.2s;
  flex: 1;
  color: var(--gh-text);
}

.gh-casino-game-btn:hover {
  background: rgba(255,255,255,0.04);
  border-color: var(--gh-border-light);
}

.gh-casino-game-btn.active {
  background: var(--gh-green-dim);
  border-color: rgba(0, 255, 163, 0.2);
}

.gh-game-icon-bg {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.gh-game-icon-bg svg {
  width: 18px;
  height: 18px;
}

.gh-casino-game-btn.active .gh-game-icon-bg {
  background: var(--gh-green-dim);
  color: var(--gh-green);
}

.gh-game-name {
  font-size: 14px;
  font-weight: 700;
  display: block;
}

.gh-game-subtitle {
  font-size: 11px;
  color: var(--gh-text-muted);
  display: block;
}

.gh-casino-bet-section {
  padding: 16px 20px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
}

.gh-casino-bet-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gh-text-muted);
  font-weight: 600;
  margin-bottom: 8px;
}

.gh-casino-game-area {
  padding: 24px;
  background: var(--gh-bg-card);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius);
}

/* Dice */
.gh-dice-slider-container { margin-bottom: 20px; }

.gh-dice-slider-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--gh-text-muted);
  margin-bottom: 8px;
  padding: 0 2px;
}

.gh-dice-slider-track {
  position: relative;
  height: 8px;
  border-radius: 4px;
  background: rgba(255,255,255,0.06);
  margin-bottom: 8px;
}

.gh-dice-zone {
  position: absolute;
  top: 0;
  height: 100%;
  border-radius: 4px;
}

.gh-dice-zone.win {
  background: rgba(0, 255, 163, 0.3);
}

.gh-dice-zone.lose {
  background: rgba(244, 63, 94, 0.2);
}

.gh-dice-target-marker {
  position: absolute;
  top: -4px;
  width: 3px;
  height: 16px;
  background: #fff;
  border-radius: 2px;
  transform: translateX(-50%);
  z-index: 2;
}

.gh-dice-roll-indicator {
  position: absolute;
  top: -30px;
  transform: translateX(-50%);
  z-index: 3;
}

.gh-dice-roll-indicator span {
  display: inline-block;
  padding: 4px 8px;
  background: var(--gh-green);
  color: #000;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  border-radius: 4px;
}

.gh-dice-slider {
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 20px;
  background: transparent;
  outline: none;
  cursor: pointer;
}

.gh-dice-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.gh-dice-direction {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.gh-dice-direction-btn {
  flex: 1;
  padding: 10px;
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  background: transparent;
  color: var(--gh-text-secondary);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.gh-dice-direction-btn.active {
  background: var(--gh-green-dim);
  border-color: rgba(0, 255, 163, 0.2);
  color: var(--gh-green);
}

.gh-dice-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.gh-dice-stat {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-align: center;
}

.gh-dice-stat-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gh-text-muted);
  font-weight: 600;
}

.gh-dice-stat-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 800;
  color: var(--gh-text);
}

.gh-casino-result {
  text-align: center;
  padding: 16px;
  border-radius: var(--gh-radius-sm);
  margin-bottom: 16px;
}

.gh-casino-result.win {
  background: var(--gh-green-dim);
  border: 1px solid rgba(0, 255, 163, 0.15);
}

.gh-casino-result.loss {
  background: var(--gh-red-dim);
  border: 1px solid rgba(244, 63, 94, 0.15);
}

.gh-casino-result-text {
  font-size: 14px;
  font-weight: 800;
}

.gh-casino-result.win .gh-casino-result-text { color: var(--gh-green); }
.gh-casino-result.loss .gh-casino-result-text { color: var(--gh-red); }

.gh-casino-result-amount {
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  font-weight: 800;
  margin-top: 4px;
}

.gh-casino-result.win .gh-casino-result-amount { color: var(--gh-green); }
.gh-casino-result.loss .gh-casino-result-amount { color: var(--gh-red); }

.gh-casino-play-btn {
  width: 100%;
  padding: 14px;
  font-size: 15px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  justify-content: center;
}

.gh-casino-play-btn.stop {
  background: var(--gh-red);
}

.gh-casino-cashout-btn {
  width: 100%;
  padding: 12px;
  font-size: 14px;
  font-weight: 700;
  justify-content: center;
  margin-top: 12px;
}

/* Limbo */
.gh-limbo-display {
  text-align: center;
  padding: 40px 20px;
  margin-bottom: 20px;
}

.gh-limbo-result {
  font-family: 'JetBrains Mono', monospace;
  font-size: 48px;
  font-weight: 900;
  color: var(--gh-text-muted);
  transition: color 0.3s;
}

.gh-limbo-result.win { color: var(--gh-green); }
.gh-limbo-result.loss { color: var(--gh-red); }

.gh-limbo-target {
  margin-bottom: 16px;
}

.gh-limbo-target label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gh-text-muted);
  font-weight: 600;
  display: block;
  margin-bottom: 8px;
}

.gh-limbo-target-input {
  display: flex;
  align-items: center;
  gap: 6px;
}

.gh-limbo-target-input button {
  width: 36px;
  height: 36px;
  border-radius: var(--gh-radius-xs);
  border: 1px solid var(--gh-border);
  background: rgba(255,255,255,0.04);
  color: var(--gh-text);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-limbo-target-input input {
  flex: 1;
  padding: 8px 12px;
  background: var(--gh-bg-input);
  border: 1px solid var(--gh-border);
  border-radius: var(--gh-radius-xs);
  color: var(--gh-text);
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  outline: none;
}

.gh-limbo-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

/* Mines */
.gh-mines-setup label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gh-text-muted);
  font-weight: 600;
  display: block;
  margin-bottom: 10px;
}

.gh-mines-count-btns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.gh-mines-info {
  font-size: 12px;
  color: var(--gh-text-muted);
  margin-top: 12px;
  margin-bottom: 16px;
}

.gh-mines-info-bar {
  display: flex;
  justify-content: space-around;
  padding: 12px;
  background: rgba(255,255,255,0.02);
  border-radius: var(--gh-radius-xs);
  margin-bottom: 16px;
  font-size: 12px;
  color: var(--gh-text-secondary);
}

.gh-mines-info-bar strong {
  color: var(--gh-text);
}

.gh-mines-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  max-width: 320px;
  margin: 0 auto 16px;
}

.gh-mines-tile {
  aspect-ratio: 1;
  border-radius: var(--gh-radius-xs);
  border: 1px solid var(--gh-border);
  background: rgba(255,255,255,0.03);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.gh-mines-tile:hover:not(.safe):not(.mine):not(.mine-reveal) {
  background: rgba(255,255,255,0.08);
  border-color: var(--gh-border-light);
}

.gh-mines-tile.safe {
  background: var(--gh-green-dim);
  border-color: rgba(0, 255, 163, 0.2);
  color: var(--gh-green);
  cursor: default;
}

.gh-mines-tile.safe svg {
  width: 18px;
  height: 18px;
}

.gh-mines-tile.mine, .gh-mines-tile.mine-reveal {
  background: var(--gh-red-dim);
  border-color: rgba(244, 63, 94, 0.2);
  color: var(--gh-red);
  cursor: default;
}

.gh-mines-tile.mine svg, .gh-mines-tile.mine-reveal svg {
  width: 18px;
  height: 18px;
}

/* Auto mode */
.gh-mode-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 12px;
  background: rgba(255,255,255,0.03);
  border-radius: var(--gh-radius-xs);
  padding: 3px;
}

.gh-mode-tab {
  flex: 1;
  padding: 8px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: var(--gh-text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.gh-mode-tab.active {
  background: rgba(255,255,255,0.08);
  color: var(--gh-text);
}

.gh-auto-settings {
  padding: 14px;
  background: rgba(255,255,255,0.02);
  border-radius: var(--gh-radius-xs);
  margin-bottom: 12px;
}

.gh-auto-setting label {
  font-size: 11px;
  color: var(--gh-text-muted);
  font-weight: 600;
  display: block;
  margin-bottom: 8px;
}

.gh-auto-presets {
  display: flex;
  gap: 6px;
}

.gh-auto-remaining {
  margin-top: 10px;
  font-size: 12px;
  color: var(--gh-text-secondary);
}

.gh-auto-remaining strong {
  color: var(--gh-green);
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* ── Tablet: ≤ 900px ── */
@media (max-width: 900px) {
  .gh-sidebar-panel {
    display: none;
  }
  
  .gh-content {
    padding: 20px 16px;
  }

  .gh-overview-layout {
    grid-template-columns: 1fr;
  }

  .gh-casino-banner {
    flex-direction: column;
    text-align: center;
  }

  .gh-casino-banner-actions {
    justify-content: center;
  }

  .gh-quick-actions-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .gh-highlights-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .lcd-stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .lcd-fund-grid {
    grid-template-columns: 1fr;
  }

  .lcd-perf-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gh-raffle-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }

  .gh-dice-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .gh-page-title {
    font-size: 20px;
  }

  .gh-card-header {
    padding: 14px 16px;
  }

  .gh-card-body {
    padding: 14px 16px;
  }
}

/* ── Small tablet / large phone: ≤ 600px ── */
@media (max-width: 600px) {
  .gh-content {
    padding: 16px 12px;
  }

  .gh-quick-actions-grid {
    grid-template-columns: 1fr 1fr;
  }

  .gh-casino-games {
    flex-direction: column;
  }

  .gh-members-controls {
    flex-direction: column;
  }

  .gh-form-row {
    grid-template-columns: 1fr;
  }

  .gh-members-grid {
    grid-template-columns: 1fr 1fr;
  }

  .gh-raffles-grid {
    grid-template-columns: 1fr;
  }

  .lcd-perf-grid {
    grid-template-columns: 1fr;
  }

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

  .gh-casino-banner {
    padding: 16px;
    gap: 14px;
  }

  .gh-casino-banner-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
  }

  .gh-casino-banner-title {
    font-size: 15px;
  }

  .gh-leader-casino-btn-content {
    gap: 10px;
  }

  .gh-leader-casino-btn-balance-value {
    font-size: 12px;
  }

  .gh-mines-grid {
    max-width: 280px;
    gap: 5px;
  }

  .gh-mines-tile {
    border-radius: 6px;
  }
}

/* ── Phone: ≤ 480px ── */
@media (max-width: 480px) {
  .gh-shell {
    padding-top: 56px;
  }

  .gh-content {
    padding: 12px 10px;
  }

  .gh-page-title {
    font-size: 17px;
    gap: 8px;
  }

  .gh-page-title svg {
    width: 20px;
    height: 20px;
  }

  .gh-quick-actions-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .gh-action-btn {
    padding: 14px 10px;
    gap: 8px;
    font-size: 11.5px;
  }

  .gh-action-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }

  .gh-action-icon svg {
    width: 16px;
    height: 16px;
  }

  .gh-highlights-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .gh-highlight-item {
    padding: 10px 6px;
  }

  .lcd-stats-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .lcd-stat-card {
    padding: 10px 12px;
    gap: 10px;
  }

  .lcd-body {
    padding: 14px 12px;
  }

  .lcd-fund-card {
    padding: 14px;
  }

  .lcd-perf-card {
    padding: 12px;
  }

  .lcd-perf-value {
    font-size: 15px;
  }

  .gh-members-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .gh-member-card {
    padding: 14px 12px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    text-align: left;
  }

  .gh-member-card-stats {
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 4px;
  }

  .gh-raffle-card {
    padding: 14px;
  }

  .gh-raffle-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }

  .gh-raffle-stat {
    font-size: 12px;
  }

  .gh-dice-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }

  .gh-mines-grid {
    max-width: 260px;
    gap: 4px;
  }

  .gh-mines-info-bar {
    font-size: 11px;
    padding: 10px;
  }

  .gh-form-group label {
    font-size: 11px;
  }

  .gh-card-header {
    padding: 12px;
  }

  .gh-card-body {
    padding: 12px;
  }

  .gh-section-title {
    font-size: 13px;
  }

  /* Touch-friendly: ensure all tappable elements are ≥ 44px */
  .gh-action-btn,
  .gh-leader-casino-btn,
  .gh-mines-tile {
    min-height: 44px;
  }
}

/* ── Tiny phone: ≤ 360px ── */
@media (max-width: 360px) {
  .gh-content {
    padding: 10px 8px;
  }

  .gh-quick-actions-grid {
    grid-template-columns: 1fr;
  }

  .gh-highlights-grid {
    grid-template-columns: 1fr;
  }

  .gh-casino-banner-actions {
    flex-direction: column;
    width: 100%;
  }

  .gh-casino-banner-actions .gh-btn {
    width: 100%;
    justify-content: center;
  }

  .gh-leader-casino-btn-content {
    flex-wrap: wrap;
  }

  .gh-leader-casino-btn-balance {
    width: 100%;
    text-align: left;
    margin-top: 4px;
  }
}

/* ============================================
   MOBILE BOTTOM NAV (shown when sidebar is hidden)
   ============================================ */
.gh-mobile-nav {
  display: none;
}

@media (max-width: 900px) {
  .gh-mobile-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--gh-bg-sidebar);
    border-top: 1px solid var(--gh-border);
    z-index: 100;
    padding: 8px 12px;
    gap: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .gh-mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 600;
    color: var(--gh-text-muted);
    cursor: pointer;
    transition: all 0.15s;
    border: none;
    background: none;
    white-space: nowrap;
    flex-shrink: 0;
    min-height: 44px; /* touch target */
  }

  .gh-mobile-nav-item svg {
    width: 20px;
    height: 20px;
  }

  .gh-mobile-nav-item.active {
    color: var(--gh-green);
    background: var(--gh-bg-active);
  }

  .gh-shell {
    padding-bottom: 72px;
  }
}
