:root {
  --bg-primary: #08120c;
  --bg-secondary: #0e2016;
  --bg-card: rgba(16, 36, 24, 0.75);
  --bg-card-hover: rgba(22, 50, 33, 0.85);
  --bg-glass: rgba(14, 32, 22, 0.65);
  
  --primary: #10b981;
  --primary-hover: #059669;
  --primary-light: #34d399;
  --primary-dark: #047857;
  --emerald-glow: rgba(16, 185, 129, 0.35);
  --emerald-glow-strong: rgba(16, 185, 129, 0.6);
  
  --accent: #00f5d4;
  --accent-gold: #fbbf24;
  --accent-red: #ef4444;
  --accent-blue: #3b82f6;

  --text-main: #f0fdf4;
  --text-muted: #86efac;
  --text-dim: #6ee7b7;
  --text-sub: #94a3b8;

  --border-color: rgba(52, 211, 153, 0.18);
  --border-color-hover: rgba(52, 211, 153, 0.45);
  --border-glow: rgba(0, 245, 212, 0.3);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.5);
  --shadow-emerald: 0 0 25px rgba(16, 185, 129, 0.35);
  
  --font-main: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

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

html {
  scroll-behavior: smooth;
  font-family: var(--font-main);
  background-color: var(--bg-primary);
  color: var(--text-main);
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  background: 
    radial-gradient(circle at 20% 15%, rgba(16, 185, 129, 0.12) 0%, transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(4, 120, 87, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(6, 78, 59, 0.08) 0%, transparent 60%),
    var(--bg-primary);
  background-attachment: fixed;
  line-height: 1.6;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: #164e32;
  border-radius: 5px;
  border: 2px solid var(--bg-primary);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(8, 18, 12, 0.82);
  border-bottom: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.nav-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-logo {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, #10b981, #047857);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 0 15px var(--emerald-glow);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.brand-text {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #ffffff;
}

.brand-text span {
  color: var(--primary-light);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-link {
  color: #cbd5e1;
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  transition: all 0.2s ease;
  position: relative;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary-light);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--primary);
  transition: width 0.2s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Hero Section */
.hero-section {
  padding-top: 140px;
  padding-bottom: 80px;
  position: relative;
  overflow: hidden;
  text-align: center;
}

.hero-glow-blob {
  position: absolute;
  top: 10%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.18) 0%, rgba(0, 245, 212, 0.05) 50%, transparent 70%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 850px;
  margin: 0 auto;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.3);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  color: var(--primary-light);
  margin-bottom: 24px;
  backdrop-filter: blur(8px);
}

.badge-dot {
  width: 8px;
  height: 8px;
  background-color: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 10px #10b981;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

.hero-title {
  font-size: clamp(38px, 6vw, 64px);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 20px;
  letter-spacing: -1px;
}

.gradient-text {
  background: linear-gradient(135deg, #ffffff 20%, #a7f3d0 60%, #10b981 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 18px;
  color: #94a3b8;
  max-width: 650px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

/* IP Box Widget */
.server-ip-widget {
  display: inline-flex;
  align-items: center;
  background: rgba(14, 34, 23, 0.85);
  border: 1px solid var(--border-color);
  padding: 10px 18px;
  border-radius: var(--radius-md);
  margin-bottom: 40px;
  gap: 14px;
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
}

.server-ip-widget:hover {
  border-color: var(--primary);
  box-shadow: 0 0 20px var(--emerald-glow);
  transform: translateY(-2px);
}

.ip-text {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  color: #e2e8f0;
  letter-spacing: 0.5px;
}

.ip-copy-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--primary-light);
  border: 1px solid rgba(52, 211, 153, 0.3);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.server-ip-widget:hover .ip-copy-btn {
  background: var(--primary);
  color: #08120c;
}

/* TWO MAIN HERO BUTTONS */
.hero-cta-group {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 50px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px 36px;
  border-radius: var(--radius-md);
  font-size: 17px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  user-select: none;
}

/* 1. Primary Button: Подать заявку */
.btn-primary-emerald {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #042416;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.25);
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.2);
}

.btn-primary-emerald:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 35px rgba(16, 185, 129, 0.6);
  background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
}

.btn-primary-emerald:active {
  transform: translateY(0);
}

/* 2. Secondary Button: Пожертвования */
.btn-donate-emerald {
  background: rgba(16, 36, 24, 0.9);
  color: #a7f3d0;
  border: 1px solid rgba(52, 211, 153, 0.5);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
}

.btn-donate-emerald:hover {
  transform: translateY(-3px) scale(1.02);
  border-color: #00f5d4;
  color: #ffffff;
  background: rgba(22, 54, 36, 0.95);
  box-shadow: 0 0 30px rgba(0, 245, 212, 0.35);
}

.btn-icon {
  font-size: 20px;
}

/* Small Button variants */
.btn-sm {
  padding: 8px 18px;
  font-size: 14px;
  border-radius: var(--radius-sm);
}

.btn-outline {
  background: transparent;
  color: var(--text-main);
  border: 1px solid var(--border-color);
}
.btn-outline:hover {
  background: rgba(16, 185, 129, 0.1);
  border-color: var(--primary);
  color: var(--primary-light);
}

/* Server Live Stats Bar */
.stats-banner {
  max-width: 900px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow-md);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
}

.stat-item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -10px;
  top: 15%;
  height: 70%;
  width: 1px;
  background: rgba(255, 255, 255, 0.08);
}

.stat-val {
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.stat-val.emerald {
  color: var(--primary-light);
}

.stat-lbl {
  font-size: 13px;
  color: #94a3b8;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Features Section */
.section {
  padding: 90px 0;
  position: relative;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 60px;
}

.section-subtitle {
  color: var(--primary-light);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 10px;
}

.section-title {
  font-size: 34px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 16px;
}

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

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  transition: all 0.3s ease;
  backdrop-filter: blur(12px);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-color-hover);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 0 0 20px var(--emerald-glow);
  background: var(--bg-card-hover);
}

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

.feature-icon {
  width: 56px;
  height: 56px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.3);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-bottom: 20px;
  color: var(--primary-light);
}

.feature-title {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 12px;
}

.feature-desc {
  font-size: 15px;
  color: #94a3b8;
  line-height: 1.6;
}

/* Rules Section */
.rules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.rule-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.rule-num {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  background: rgba(16, 185, 129, 0.15);
  color: var(--primary-light);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  border: 1px solid rgba(52, 211, 153, 0.3);
}

.rule-content h4 {
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 6px;
}

.rule-content p {
  font-size: 14px;
  color: #94a3b8;
}

/* Modals */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(4, 10, 6, 0.85);
  backdrop-filter: blur(12px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  background: #0d2217;
  border: 1px solid rgba(52, 211, 153, 0.3);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 580px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 35px var(--emerald-glow);
  transform: scale(0.92) translateY(20px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.modal-backdrop.active .modal-card {
  transform: scale(1) translateY(0);
}

.modal-header {
  padding: 24px 28px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  background: #0d2217;
  z-index: 10;
}

.modal-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-title-icon {
  width: 36px;
  height: 36px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--primary-light);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.modal-title {
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
}

.modal-close-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 24px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.modal-body {
  padding: 28px;
}

/* Forms */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #e2e8f0;
  margin-bottom: 8px;
}

.form-label .required {
  color: #ef4444;
  margin-left: 4px;
}

.form-label .optional {
  color: #64748b;
  font-size: 12px;
  font-weight: normal;
  margin-left: 6px;
}

.form-input-wrapper {
  position: relative;
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 13px 16px;
  background: rgba(8, 20, 13, 0.8);
  border: 1px solid rgba(52, 211, 153, 0.25);
  border-radius: var(--radius-sm);
  color: #ffffff;
  font-size: 15px;
  font-family: inherit;
  transition: all 0.2s ease;
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
  background: rgba(10, 26, 17, 0.95);
}

.form-textarea {
  resize: vertical;
  min-height: 90px;
}

.form-help {
  font-size: 12px;
  color: #64748b;
  margin-top: 6px;
}

/* Live Minecraft Skin Preview in Application Modal */
.skin-preview-box {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(6, 16, 10, 0.6);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  margin-bottom: 22px;
}

.skin-avatar {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  border: 2px solid var(--primary);
  background: #08140e;
  object-fit: cover;
  image-rendering: pixelated;
}

.skin-info h5 {
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
}

.skin-info p {
  font-size: 13px;
  color: #94a3b8;
}

/* Donation Preset Amount Chips */
.donation-chips {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.chip-btn {
  background: rgba(14, 34, 23, 0.8);
  border: 1px solid var(--border-color);
  color: #e2e8f0;
  padding: 10px 8px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.chip-btn:hover {
  border-color: var(--primary);
  color: #ffffff;
}

.chip-btn.active {
  background: var(--primary);
  color: #042416;
  border-color: var(--primary-light);
  box-shadow: 0 0 15px var(--emerald-glow);
}

/* Payment Methods Grid */
.payment-methods {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.payment-card {
  background: rgba(8, 20, 13, 0.7);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
  text-align: center;
}

.payment-card:hover {
  border-color: var(--primary-light);
  background: rgba(14, 36, 24, 0.9);
}

.payment-card.active {
  border-color: var(--primary);
  background: rgba(16, 185, 129, 0.15);
  box-shadow: 0 0 15px var(--emerald-glow);
}

.payment-card-icon {
  font-size: 22px;
}

.payment-card-name {
  font-size: 12px;
  font-weight: 700;
  color: #ffffff;
}

/* Submit Disabled State */
.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
  pointer-events: none;
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 400px;
}

.toast {
  background: #0e2417;
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  color: #ffffff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  gap: 14px;
  transform: translateX(120%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.toast.show {
  transform: translateX(0);
}

.toast.error {
  border-left-color: #ef4444;
}

.toast.info {
  border-left-color: #3b82f6;
}

.toast-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.toast-message {
  font-size: 14px;
  line-height: 1.4;
}

/* Footer */
.footer {
  border-top: 1px solid var(--border-color);
  background: rgba(6, 14, 9, 0.95);
  padding: 40px 0;
  margin-top: 80px;
}

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

.footer-copy {
  font-size: 14px;
  color: #64748b;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-link {
  color: #94a3b8;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}

.footer-link:hover {
  color: var(--primary-light);
}

/* Responsive */
@media (max-width: 900px) {
  .stats-banner {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
  .stat-item:nth-child(2)::after {
    display: none;
  }
  .nav-links {
    display: none;
  }
}

@media (max-width: 600px) {
  .hero-title {
    font-size: 34px;
  }
  .hero-cta-group {
    flex-direction: column;
    width: 100%;
  }
  .hero-cta-group .btn {
    width: 100%;
  }
  .stats-banner {
    grid-template-columns: 1fr;
  }
  .stat-item::after {
    display: none !important;
  }
  .donation-chips {
    grid-template-columns: repeat(2, 1fr);
  }
  .payment-methods {
    grid-template-columns: 1fr;
  }
}
