:root {
  --bg-primary: #0d1117;
  --bg-secondary: #161b22;
  --bg-card: rgba(22, 27, 34, 0.85);
  --bg-glass: rgba(30, 38, 50, 0.6);
  --border-color: rgba(139, 148, 158, 0.15);
  --text-primary: #e6edf3;
  --text-secondary: #8b949e;
  --text-muted: #484f58;
  --accent: #7c3aed;
  --accent-hover: #6d28d9;
  --accent-glow: rgba(124, 58, 237, 0.35);
  --success: #2ea043;
  --danger: #f85149;
  --warning: #d29922;
  --discord-blurple: #5865F2;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
}

/* ===== NAVBAR ===== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 64px;
  background: rgba(13, 17, 23, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 1.2rem;
}

.navbar-brand .logo-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.navbar-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.navbar-user img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--accent);
}

.navbar-user span {
  font-weight: 500;
  font-size: 0.9rem;
}

/* ===== HERO SECTION (Landing) ===== */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 64px);
  text-align: center;
  padding: 2rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 40%, var(--accent-glow), transparent 50%),
              radial-gradient(circle at 70% 60%, rgba(88, 101, 242, 0.15), transparent 50%);
  animation: aurora 15s ease-in-out infinite alternate;
  z-index: 0;
}

@keyframes aurora {
  0% { transform: translate(0, 0) rotate(0deg); }
  100% { transform: translate(-5%, 5%) rotate(3deg); }
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #e6edf3, #a78bfa, #7c3aed);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.15;
}

.hero p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  max-width: 550px;
  margin-left: auto;
  margin-right: auto;
}

.hero-features {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.hero-feature {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  background: var(--bg-glass);
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  backdrop-filter: blur(10px);
}

.hero-feature .icon {
  font-size: 1.1rem;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 999px;
  border: none;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  transition: var(--transition);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #6d28d9);
  color: white;
  box-shadow: 0 4px 24px var(--accent-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px var(--accent-glow);
}

.btn-discord {
  background: var(--discord-blurple);
  color: white;
}

.btn-discord:hover {
  background: #4752c4;
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-outline:hover {
  background: var(--bg-glass);
  border-color: var(--accent);
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.btn-success {
  background: var(--success);
  color: white;
}

.btn-sm {
  padding: 8px 18px;
  font-size: 0.85rem;
}

/* ===== DASHBOARD LAYOUT ===== */
.dashboard-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem;
}

.dashboard-header {
  margin-bottom: 2rem;
}

.dashboard-header h1 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.dashboard-header p {
  color: var(--text-secondary);
}

/* ===== GUILD GRID ===== */
.guild-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.2rem;
}

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

.guild-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 20px var(--accent-glow);
  transform: translateY(-3px);
}

.guild-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.guild-card-header img {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
}

.guild-card-header .guild-icon-placeholder {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
}

.guild-card-header h3 {
  font-size: 1rem;
  font-weight: 600;
}

.guild-card-header .guild-id {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: monospace;
}

.guild-card .badge {
  font-size: 0.7rem;
  padding: 3px 10px;
  border-radius: 999px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-active {
  background: rgba(46, 160, 67, 0.15);
  color: var(--success);
  border: 1px solid rgba(46, 160, 67, 0.3);
}

.badge-inactive {
  background: rgba(139, 148, 158, 0.1);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

.guild-card-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
}

/* ===== CONFIG PAGE ===== */
.config-container {
  max-width: 700px;
  margin: 0 auto;
  padding: 2rem;
}

.config-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  transition: var(--transition);
}

.config-back:hover {
  color: var(--accent);
}

.config-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 2rem;
}

.config-header img {
  width: 56px;
  height: 56px;
  border-radius: var(--radius);
}

.config-header h1 {
  font-size: 1.5rem;
}

.config-header p {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

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

.config-card h2 {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid var(--border-color);
}

.form-group {
  margin-bottom: 1.5rem;
}

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

.form-group input,
.form-group select {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: inherit;
  transition: var(--transition);
  outline: none;
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group .hint {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ===== ALERTS ===== */
.alert {
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.alert-success {
  background: rgba(46, 160, 67, 0.1);
  border: 1px solid rgba(46, 160, 67, 0.3);
  color: var(--success);
}

.alert-error {
  background: rgba(248, 81, 73, 0.1);
  border: 1px solid rgba(248, 81, 73, 0.3);
  color: var(--danger);
}

/* ===== STATS SECTION ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

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

.stat-card .stat-value {
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-card .stat-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hero h1 { font-size: 2.2rem; }
  .hero-features { flex-direction: column; align-items: center; }
  .guild-grid { grid-template-columns: 1fr; }
  .navbar { padding: 0 1rem; }
  .dashboard-container, .config-container { padding: 1rem; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
}

/* ===== LANDING PAGE SPECIFICS ===== */
.text-gradient {
  background: linear-gradient(135deg, #7c3aed, #a78bfa, #f472b6);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.badge-pill {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid rgba(124, 58, 237, 0.4);
  color: #a78bfa;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 2rem;
}

.glow-effect {
  box-shadow: 0 0 20px rgba(124, 58, 237, 0.2);
  animation: pulse-glow 2s infinite alternate;
}

@keyframes pulse-glow {
  0% { box-shadow: 0 0 15px rgba(124, 58, 237, 0.1); }
  100% { box-shadow: 0 0 25px rgba(124, 58, 237, 0.4); }
}

.hero-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 3rem;
  position: relative;
  z-index: 10;
}

.btn-lg {
  padding: 14px 32px;
  font-size: 1.05rem;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 20px;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.fw-bold {
  font-weight: 700;
  color: var(--text-primary);
}

.stat-divider {
  width: 4px;
  height: 4px;
  background: var(--text-muted);
  border-radius: 50%;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header h2 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.features-section {
  padding: 6rem 0;
  background: linear-gradient(180deg, var(--bg-primary) 0%, rgba(30, 38, 50, 0.2) 100%);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.feature-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0;
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(124, 58, 237, 0.4);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.feature-card:hover::after {
  opacity: 1;
}

.feature-icon {
  width: 54px;
  height: 54px;
  background: rgba(124, 58, 237, 0.15);
  color: #a78bfa;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

.feature-card h3 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

.how-it-works {
  padding: 6rem 0;
  border-top: 1px solid var(--border-color);
}

.steps-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
  position: relative;
}

.step-card {
  text-align: center;
  padding: 2rem;
}

.step-number {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--accent), #f472b6);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 800;
  margin: 0 auto 1.5rem auto;
  box-shadow: 0 10px 20px var(--accent-glow);
}

.step-card h3 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
}

.step-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

footer {
  padding: 3rem 0;
  border-top: 1px solid var(--border-color);
  background: var(--bg-secondary);
}

.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.2rem;
}

.footer-text {
  color: var(--text-muted);
  font-size: 0.9rem;
}

