:root {
  --bg: #0a0a0c;
  --bg-elevated: #121216;
  --accent: #e85d2e;
  --accent-dim: #c44d22;
  --text: #e8e6e3;
  --text-muted: #8b8884;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(180, 80, 40, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse 100% 100% at 50% 100%, rgba(20, 15, 12, 0.9) 0%, transparent 60%),
    linear-gradient(180deg, #0f0e10 0%, #0a090b 100%);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

.noise {
  display: none;
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.25rem 2rem;
  background: linear-gradient(to bottom, var(--bg) 60%, transparent);
  transition: background 0.3s ease;
}

header.scrolled {
  background: rgba(10, 10, 12, 0.95);
  backdrop-filter: blur(12px);
}

nav {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  height: 48px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--accent);
}

/* Section divider line */
.section-line {
  height: 1px;
  max-width: 900px;
  margin: 2rem auto;
  padding: 0 2rem;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.06);
}

body > .section-line:last-of-type {
  margin-bottom: 0;
}

/* Hero */
.hero {
  min-height: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  padding: 4.25rem 2rem 1.5rem;
}

.hero-logo {
  max-width: 420px;
  width: 90%;
  height: auto;
  margin-bottom: 0.5rem;
  filter: drop-shadow(0 4px 24px rgba(232, 93, 46, 0.15));
}

.tagline {
  font-size: 1.25rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-bottom: 0.75rem;
  max-width: 340px;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 2rem;
  background: var(--accent);
  color: white;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  border-radius: 8px;
  transition: background 0.2s ease, transform 0.15s ease;
}

.cta:hover {
  background: var(--accent-dim);
  transform: translateY(-2px);
}

.hero-ctas {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

.hero-ctas .cta {
  min-width: 12rem;
  text-align: center;
}

.cta-secondary {
  background: #3a3836;
  border: 2px solid #c9a227;
  color: var(--text);
}

.cta-secondary:hover {
  background: #4a4846;
  border-color: #d4af37;
  color: var(--text);
  transform: translateY(-2px);
}

/* Features */
.features {
  padding: 1.5rem 2rem;
  max-width: 1100px;
  margin: 0 auto;
}

.features h2 {
  font-size: 1.75rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 1.25rem;
  color: var(--text);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.feature {
  background: var(--bg-elevated);
  padding: 1.25rem;
  border-radius: 12px;
  border: 1px solid rgba(232, 93, 46, 0.15);
  box-shadow: 0 0 20px rgba(232, 93, 46, 0.08), 0 0 40px rgba(232, 93, 46, 0.04);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.feature:hover {
  border-color: rgba(232, 93, 46, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 0 30px rgba(232, 93, 46, 0.15), 0 0 60px rgba(232, 93, 46, 0.08);
}

.feature-icon {
  font-size: 1.75rem;
  display: block;
  margin-bottom: 0.5rem;
}

.feature h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.feature p {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Donate */
.donate {
  padding: 1.5rem 2rem;
  text-align: center;
}

.donate h2 {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.donate > p {
  color: var(--text-muted);
  margin: 0 auto 1.25rem;
  max-width: 500px;
}

.cta-donate {
  text-decoration: none;
}

/* Download */
.download {
  padding: 1.5rem 2rem;
  text-align: center;
  background: linear-gradient(to top, var(--bg-elevated) 0%, transparent 100%);
}

.download h2 {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.375rem;
}

.download > p {
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.email-signup {
  display: flex;
  gap: 0.5rem;
  max-width: 400px;
  margin: 0 auto;
  flex-wrap: wrap;
  justify-content: center;
}

.email-signup input {
  flex: 1;
  min-width: 220px;
  padding: 0.9rem 1.25rem;
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
}

.email-signup input::placeholder {
  color: var(--text-muted);
}

.email-signup input:focus {
  outline: none;
  border-color: var(--accent);
}

.email-signup button {
  padding: 0.9rem 1.5rem;
  background: var(--accent);
  border: none;
  border-radius: 8px;
  color: white;
  font-family: inherit;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s ease;
}

.email-signup button:hover {
  background: var(--accent-dim);
}

/* TOS / Legal page */
.tos-main {
  padding: 5rem 2rem 3rem;
  max-width: 720px;
  margin: 0 auto;
}

.tos-content h1 {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.tos-updated {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.tos-content h2 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

.tos-content p,
.tos-content li {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  line-height: 1.65;
}

.tos-content ul {
  margin: 0.5rem 0 1rem 1.25rem;
}

.tos-content li {
  margin-bottom: 0.5rem;
}

.tos-content a {
  color: var(--accent);
  text-decoration: none;
}

.tos-content a:hover {
  text-decoration: underline;
}

.tos-footer-note {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.9rem;
}

/* Footer */
footer {
  margin-top: 4rem;
  padding: 1rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

footer .footer-legal {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  opacity: 0.8;
}

footer .footer-legal a {
  color: var(--accent);
  text-decoration: none;
}

footer .footer-legal a:hover {
  text-decoration: underline;
}

/* Communities page */
.communities-main {
  padding-top: 5rem;
  padding-bottom: 2rem;
}

.communities-hero {
  text-align: center;
  padding: 1.5rem 2rem;
  max-width: 600px;
  margin: 0 auto;
}

.communities-hero h1 {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.communities-hero p {
  font-size: 1rem;
  color: var(--text-muted);
}

.communities-grid-section {
  padding: 0 2rem 2rem;
  max-width: 1100px;
  margin: 0 auto;
}

.community-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.community-card {
  background: var(--bg-elevated);
  padding: 1.5rem;
  border-radius: 12px;
  border: 1px solid rgba(232, 93, 46, 0.15);
  box-shadow: 0 0 20px rgba(232, 93, 46, 0.08), 0 0 40px rgba(232, 93, 46, 0.04);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.community-card:hover {
  border-color: rgba(232, 93, 46, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 0 30px rgba(232, 93, 46, 0.15), 0 0 60px rgba(232, 93, 46, 0.08);
}

.community-logo-wrap {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1rem;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.community-logo-wrap-banner {
  width: 100%;
  max-width: 280px;
  height: 80px;
}

.community-logo-wrap-banner .community-logo {
  object-fit: contain;
}

.community-logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.community-name {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.community-description {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 1rem;
  flex-grow: 1;
}

.community-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.25rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.community-link-website {
  background: var(--accent);
  color: white;
}

.community-link-website:hover {
  background: var(--accent-dim);
  color: white;
  transform: translateY(-2px);
}

.community-link-discord {
  background: #5865f2;
  color: white;
}

.community-link-discord:hover {
  background: #4752c4;
  color: white;
  transform: translateY(-2px);
}

@media (max-width: 600px) {
  .hero-logo {
    max-width: 320px;
  }

  .nav-links {
    gap: 1.25rem;
  }
}
