/* ===== Custom Properties ===== */
:root {
  --bg: #0a1128;
  --surface: #1a2332;
  --accent: #c9a84c;
  --text: #e8e4dc;
  --muted: #8a9bb0;
  --highlight: #e8b94a;
  --surface-light: #243044;
  --border: rgba(201, 168, 76, 0.15);
  --font-heading: 'Cinzel', serif;
  --font-body: 'Inter', sans-serif;
  --max-width: 1140px;
  --nav-height: 64px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

img { max-width: 100%; display: block; }

ul { list-style: none; }

/* ===== Utility ===== */
.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.section {
  padding: 100px 0;
}

.section-label {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--text);
  margin-bottom: 20px;
  line-height: 1.3;
}

.section-desc {
  color: var(--muted);
  max-width: 600px;
  font-size: 1.05rem;
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Navigation ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  z-index: 1000;
  transition: background 0.3s, box-shadow 0.3s;
}
.nav.scrolled {
  background: rgba(10, 17, 40, 0.95);
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(12px);
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: var(--accent);
  letter-spacing: 2px;
  font-weight: 700;
}
.nav-logo span {
  color: var(--muted);
  font-weight: 400;
  font-size: 0.9rem;
  margin-left: 4px;
}

.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
}
.nav-links a {
  color: var(--muted);
  font-size: 0.88rem;
  letter-spacing: 0.5px;
  transition: color 0.2s;
}
.nav-links a:hover {
  color: var(--accent);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  margin: 5px 0;
  transition: transform 0.3s, opacity 0.3s;
}
.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

#star-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 8px 20px;
  border-radius: 30px;
  margin-bottom: 32px;
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  color: var(--text);
  line-height: 1.15;
  margin-bottom: 20px;
}
.hero h1 .gold {
  color: var(--accent);
  display: block;
}

.hero-tagline {
  color: var(--muted);
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  max-width: 520px;
  margin: 0 auto 40px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: var(--bg);
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 14px 36px;
  border-radius: 4px;
  transition: background 0.2s, transform 0.2s;
}
.hero-cta:hover {
  background: var(--highlight);
  color: var(--bg);
  transform: translateY(-2px);
}

.hero-scroll {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}
.hero-scroll span {
  display: block;
  width: 20px;
  height: 32px;
  border: 2px solid var(--muted);
  border-radius: 12px;
  position: relative;
}
.hero-scroll span::after {
  content: '';
  width: 3px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollDot 1.8s ease-in-out infinite;
}

@keyframes scrollDot {
  0%, 100% { opacity: 1; top: 6px; }
  50% { opacity: 0.3; top: 16px; }
}

/* Subtle radial glow behind hero */
.hero::before {
  content: '';
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(201, 168, 76, 0.06) 0%, transparent 70%);
  pointer-events: none;
  z-index: 1;
}

/* ===== About ===== */
.about {
  background: var(--surface);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  margin-top: 48px;
}

.about-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 36px;
}

.about-card .icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: rgba(201, 168, 76, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--accent);
  font-size: 1.3rem;
}

.about-card h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  margin-bottom: 12px;
  color: var(--text);
}

.about-card p {
  color: var(--muted);
  font-size: 0.95rem;
}

/* ===== Apps ===== */
.apps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 48px;
}

.app-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 40px 32px;
  text-align: center;
  position: relative;
  transition: transform 0.3s, border-color 0.3s;
}
.app-card:hover {
  transform: translateY(-4px);
  border-color: rgba(201, 168, 76, 0.35);
}

.app-card .badge {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  background: rgba(201, 168, 76, 0.12);
  color: var(--accent);
  padding: 4px 12px;
  border-radius: 20px;
}

.app-icon {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}

.app-card h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: var(--text);
}

.app-card p {
  color: var(--muted);
  font-size: 0.92rem;
}

/* ===== Contact ===== */
.contact {
  background: var(--surface);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-top: 48px;
}

.contact-info h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 8px;
  margin-top: 28px;
}
.contact-info h3:first-child {
  margin-top: 0;
}
.contact-info p {
  color: var(--muted);
  font-size: 0.95rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-form input,
.contact-form textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 14px 18px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
}
.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--muted);
  opacity: 0.5;
}
.contact-form textarea {
  resize: vertical;
  min-height: 120px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--accent);
  color: var(--bg);
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 14px 32px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  align-self: flex-start;
}
.btn:hover {
  background: var(--highlight);
  transform: translateY(-1px);
}

/* ===== Footer ===== */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
}

.footer-brand .nav-logo {
  margin-bottom: 12px;
  display: inline-block;
}
.footer-brand p {
  color: var(--muted);
  font-size: 0.88rem;
  max-width: 300px;
}

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

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text);
  margin-bottom: 16px;
}
.footer-col ul li {
  margin-bottom: 10px;
}
.footer-col ul li a {
  color: var(--muted);
  font-size: 0.88rem;
}
.footer-col ul li a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  margin-top: 40px;
  padding-top: 24px;
  text-align: center;
  color: var(--muted);
  font-size: 0.82rem;
}

/* ===== Legal Pages (Privacy, Terms, Support) ===== */
.legal-page {
  padding-top: calc(var(--nav-height) + 60px);
  padding-bottom: 80px;
  min-height: 100vh;
}

.legal-page .container {
  max-width: 800px;
}

.legal-page h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  color: var(--text);
  margin-bottom: 8px;
}

.legal-meta {
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 48px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.legal-page h2 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--accent);
  margin-top: 40px;
  margin-bottom: 14px;
}

.legal-page p,
.legal-page li {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 14px;
  line-height: 1.8;
}

.legal-page ul {
  padding-left: 20px;
  list-style: disc;
}
.legal-page ul li {
  margin-bottom: 8px;
}

/* Support page extras */
.support-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin: 32px 0;
}

.support-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
}

.support-card h3 {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 10px;
}

.support-card p {
  margin-bottom: 0;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px 28px;
  margin-bottom: 16px;
}

.faq-item h3 {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  color: var(--text);
  margin-bottom: 10px;
}

.faq-item p {
  margin-bottom: 0;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--surface);
    flex-direction: column;
    padding: 80px 32px 32px;
    gap: 20px;
    transition: right 0.3s ease;
    box-shadow: -4px 0 30px rgba(0, 0, 0, 0.5);
  }
  .nav-links.open {
    right: 0;
  }
  .nav-links a {
    font-size: 1rem;
  }
  .nav-toggle {
    display: block;
    z-index: 1001;
  }

  .about-grid,
  .contact-grid,
  .support-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .apps-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
  }

  .footer-links {
    flex-direction: column;
    gap: 32px;
  }

  .section {
    padding: 70px 0;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }
  .hero-cta {
    padding: 12px 28px;
    font-size: 0.78rem;
  }
}
