/* ============================================================================
   Arcanum Design System — Cosmic Theme
   ============================================================================ */

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

:root {
  /* Colors */
  --bg-deep: #0D1B3E;
  --bg-dark: #1A1040;
  --bg-card: rgba(255, 255, 255, 0.05);
  --bg-card-hover: rgba(255, 255, 255, 0.08);
  --gold: #D4A843;
  --gold-light: #E8B84D;
  --gold-dim: #A07830;
  --text-primary: #E8E0F0;
  --text-secondary: #B0A0C8;
  --text-muted: #7A6B8A;
  --accent-purple: #9B6DFF;
  --accent-blue: #4A90D9;
  --border: rgba(212, 168, 67, 0.15);
  --border-hover: rgba(212, 168, 67, 0.3);

  /* Fonts */
  --font-heading: 'Cinzel', 'Georgia', serif;
  --font-body: 'Montserrat', -apple-system, sans-serif;

  /* Spacing */
  --container-max: 1100px;
  --container-narrow: 800px;
}

/* ── RESET ── */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: linear-gradient(160deg, var(--bg-deep) 0%, var(--bg-dark) 100%);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.7;
  font-weight: 400;
}

/* ── ANIMATED STARS BACKGROUND ── */

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    radial-gradient(1px 1px at 10% 20%, rgba(255,255,255,0.4) 0%, transparent 100%),
    radial-gradient(1px 1px at 30% 65%, rgba(255,255,255,0.3) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 50% 15%, rgba(255,255,255,0.5) 0%, transparent 100%),
    radial-gradient(1px 1px at 70% 40%, rgba(255,255,255,0.3) 0%, transparent 100%),
    radial-gradient(1px 1px at 85% 75%, rgba(255,255,255,0.4) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 15% 80%, rgba(255,255,255,0.35) 0%, transparent 100%),
    radial-gradient(1px 1px at 60% 90%, rgba(255,255,255,0.25) 0%, transparent 100%),
    radial-gradient(1px 1px at 90% 10%, rgba(255,255,255,0.3) 0%, transparent 100%),
    radial-gradient(1px 1px at 40% 45%, rgba(255,255,255,0.2) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 25% 35%, rgba(255,255,255,0.4) 0%, transparent 100%);
  pointer-events: none;
  z-index: 0;
  animation: twinkle 8s ease-in-out infinite alternate;
}

@keyframes twinkle {
  0% { opacity: 0.6; }
  100% { opacity: 1; }
}

/* ── LAYOUT ── */

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

.container--narrow {
  max-width: var(--container-narrow);
}

/* ── TYPOGRAPHY ── */

h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.3;
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 50%, var(--gold-dim) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

h2 {
  font-size: 1.5rem;
  color: var(--gold);
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.15rem;
  color: var(--text-primary);
}

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--gold-light);
}

/* ── BUTTONS ── */

.btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.95rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  text-align: center;
}

.btn--gold {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--bg-deep);
}

.btn--gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 168, 67, 0.3);
  color: var(--bg-deep);
}

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

.btn--outline:hover {
  background: var(--bg-card-hover);
  border-color: var(--gold-dim);
  color: var(--gold-light);
}

/* ── CARDS ── */

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

/* ── HEADER / NAV ── */

.site-header {
  padding: 1.5rem 0;
  position: relative;
  z-index: 10;
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--gold);
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.site-nav a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
}

.site-nav a:hover {
  color: var(--gold);
}

/* ── FOOTER ── */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0;
  margin-top: 5rem;
  text-align: center;
  position: relative;
  z-index: 1;
}

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

.footer-links {
  display: flex;
  gap: 2rem;
  justify-content: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

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

.footer-links a:hover {
  color: var(--gold);
}

/* ── LEGAL PAGES ── */

.legal-page {
  padding: 3rem 0;
}

.legal-page .back-link {
  display: inline-block;
  margin-bottom: 2rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.legal-page .updated {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 2rem;
}

.legal-page h2 {
  margin-top: 2.5rem;
}

.legal-page ul {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.legal-page li {
  margin-bottom: 0.5rem;
}

.legal-warning {
  background: rgba(212, 168, 67, 0.1);
  border-left: 4px solid var(--gold);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  border-radius: 0 8px 8px 0;
}

/* ── FORMS ── */

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

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

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold-dim);
}

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

/* ── ACCORDION (FAQ) ── */

.accordion-item {
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.accordion-header {
  width: 100%;
  padding: 1rem 1.25rem;
  background: var(--bg-card);
  border: none;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background 0.2s;
}

.accordion-header:hover {
  background: var(--bg-card-hover);
}

.accordion-header::after {
  content: '+';
  font-size: 1.25rem;
  color: var(--gold);
  transition: transform 0.3s;
}

.accordion-item.open .accordion-header::after {
  transform: rotate(45deg);
}

.accordion-body {
  padding: 0 1.25rem;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.accordion-item.open .accordion-body {
  padding: 1rem 1.25rem;
  max-height: 500px;
}

/* ── ALERT ── */

.alert {
  padding: 1rem 1.25rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
}

.alert--success {
  background: rgba(76, 175, 80, 0.15);
  border: 1px solid rgba(76, 175, 80, 0.3);
  color: #81C784;
}

.alert--error {
  background: rgba(244, 67, 54, 0.15);
  border: 1px solid rgba(244, 67, 54, 0.3);
  color: #E57373;
}

/* ── RESPONSIVE ── */

@media (max-width: 768px) {
  .site-nav {
    gap: 1rem;
  }

  .card {
    padding: 1.5rem;
  }

  .footer-links {
    flex-direction: column;
    gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  .site-header .container {
    flex-direction: column;
    gap: 1rem;
  }

  .btn {
    padding: 0.75rem 1.5rem;
  }
}
