/* ===================================
   RIFT ROLEPLAY — Design System v2
   Deep Blue Premium Theme
   =================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&family=Space+Grotesk:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* --- CSS Custom Properties --- */
:root {
  --color-bg-primary: #060a13;
  --color-bg-secondary: #0b1120;
  --color-bg-tertiary: #0f172a;
  --color-bg-card: rgba(15, 23, 42, 0.65);
  --color-bg-glass: rgba(255, 255, 255, 0.02);
  --color-bg-glass-hover: rgba(255, 255, 255, 0.04);

  --color-accent: #3b82f6;
  --color-accent-light: #60a5fa;
  --color-accent-dark: #2563eb;
  --color-accent-subtle: #1d4ed8;
  --color-accent-muted: rgba(59, 130, 246, 0.12);

  --color-text-primary: #e2e8f0;
  --color-text-secondary: #94a3b8;
  --color-text-muted: #475569;
  --color-text-white: #f8fafc;

  --color-border: rgba(59, 130, 246, 0.1);
  --color-border-hover: rgba(59, 130, 246, 0.25);
  --color-border-subtle: rgba(148, 163, 184, 0.08);

  --gradient-accent: linear-gradient(135deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%);
  --gradient-accent-subtle: linear-gradient(135deg, rgba(37, 99, 235, 0.15) 0%, rgba(59, 130, 246, 0.05) 100%);
  --gradient-surface: linear-gradient(180deg, rgba(15, 23, 42, 0.8) 0%, rgba(6, 10, 19, 0.9) 100%);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 40px rgba(59, 130, 246, 0.15);
  --shadow-glow-strong: 0 0 60px rgba(59, 130, 246, 0.25);

  --font-display: 'Outfit', sans-serif;
  --font-body: 'Space Grotesk', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  --transition-fast: 0.15s ease;
  --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  scrollbar-width: thin;
  scrollbar-color: var(--color-accent-dark) var(--color-bg-primary);
}

body {
  font-family: var(--font-body);
  background: var(--color-bg-primary);
  color: var(--color-text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--color-bg-primary); }
::-webkit-scrollbar-thumb { background: var(--color-accent-dark); border-radius: var(--radius-full); }

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul, ol { list-style: none; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* --- Section Shared --- */
.section-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--color-accent-light);
  margin-bottom: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}

.section-label::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--color-accent);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--color-text-white);
}

.section-title .highlight {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--color-text-secondary);
  max-width: 560px;
  line-height: 1.7;
  font-weight: 400;
}

/* --- Ambient Glow Orbs (replaces childish particles) --- */
.ambient-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.ambient-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.07;
  animation: orb-drift 20s ease-in-out infinite alternate;
}

.ambient-orb:nth-child(1) {
  width: 600px; height: 600px;
  background: #2563eb;
  top: -10%; left: -5%;
  animation-delay: 0s;
}

.ambient-orb:nth-child(2) {
  width: 500px; height: 500px;
  background: #3b82f6;
  bottom: -15%; right: -10%;
  animation-delay: -7s;
}

.ambient-orb:nth-child(3) {
  width: 400px; height: 400px;
  background: #1d4ed8;
  top: 40%; left: 50%;
  animation-delay: -14s;
}

@keyframes orb-drift {
  0% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -20px) scale(1.05); }
  66% { transform: translate(-20px, 15px) scale(0.95); }
  100% { transform: translate(10px, -10px) scale(1.02); }
}

/* --- Grid Lines (subtle background texture) --- */
.grid-lines {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.02;
  background-image:
    linear-gradient(var(--color-accent) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-accent) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* --- Navigation --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 1.25rem 0;
  transition: var(--transition-smooth);
}

.navbar.scrolled {
  padding: 0.6rem 0;
  background: rgba(6, 10, 19, 0.8);
  backdrop-filter: blur(24px) saturate(1.2);
  -webkit-backdrop-filter: blur(24px) saturate(1.2);
  border-bottom: 1px solid var(--color-border-subtle);
}

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

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.nav-brand img {
  height: 38px;
  width: 38px;
  filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.4));
  transition: var(--transition-smooth);
}

.nav-brand:hover img {
  filter: drop-shadow(0 0 20px rgba(59, 130, 246, 0.6));
}

.nav-brand-text {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--color-text-white);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.nav-link {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--color-text-secondary);
  position: relative;
  transition: var(--transition-fast);
  padding: 0.25rem 0;
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-text-white);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--color-accent);
  border-radius: var(--radius-full);
  transition: var(--transition-smooth);
}

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

.nav-cta {
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.55rem 1.5rem;
  background: var(--color-accent);
  color: white;
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.nav-cta:hover {
  background: var(--color-accent-light);
  box-shadow: 0 0 24px rgba(59, 130, 246, 0.3);
  transform: translateY(-1px);
}

/* Mobile Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0.5rem;
  z-index: 1001;
}

.nav-toggle span {
  width: 24px;
  height: 1.5px;
  background: var(--color-text-primary);
  border-radius: var(--radius-full);
  transition: var(--transition-smooth);
  transform-origin: center;
}

.nav-toggle.active span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.active span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

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


.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  padding: 0 2rem;
}


.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.hero-title .word-rift {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-title .word-roleplay {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.2em;
  letter-spacing: 0.5em;
  color: var(--color-text-muted);
  -webkit-text-fill-color: var(--color-text-muted);
  margin-top: 0.75rem;
  font-weight: 400;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--color-text-secondary);
  max-width: 520px;
  margin: 1.5rem auto 2.5rem;
  font-weight: 400;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 2.5rem;
}

.btn-primary {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.75rem 2rem;
  background: var(--color-accent);
  color: white;
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition-smooth);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary:hover {
  background: var(--color-accent-light);
  box-shadow: 0 0 30px rgba(59, 130, 246, 0.25);
  transform: translateY(-2px);
}

.btn-secondary {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.75rem 2rem;
  background: transparent;
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border-hover);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition-smooth);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-secondary:hover {
  color: var(--color-text-white);
  border-color: var(--color-accent);
  background: var(--color-accent-muted);
  transform: translateY(-2px);
}





/* --- CTA --- */
.cta-section {
  padding: 6rem 0;
  position: relative;
  z-index: 1;
}

.cta-box {
  position: relative;
  padding: 4rem 2rem;
  text-align: center;
  background: var(--gradient-accent-subtle);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.cta-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
}

.cta-box::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
  opacity: 0.5;
}

.cta-box > * {
  position: relative;
  z-index: 1;
}

.cta-box .section-desc {
  margin: 0.75rem auto 2rem;
}

/* --- Divider --- */
.divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--color-accent) 50%, transparent 100%);
  opacity: 0.12;
}

/* --- Footer --- */
.footer {
  padding: 3.5rem 0 1.5rem;
  border-top: 1px solid var(--color-border-subtle);
  position: relative;
  z-index: 1;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand img {
  height: 36px;
  width: 36px;
  filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.3));
  margin-bottom: 0.75rem;
}

.footer-brand p {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  max-width: 260px;
  line-height: 1.65;
}

.footer-social {
  display: flex;
  gap: 0.6rem;
  margin-top: 1rem;
}

.footer-social a {
  width: 34px;
  height: 34px;
  background: var(--color-bg-glass);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}

.footer-social a svg {
  width: 16px;
  height: 16px;
  stroke: var(--color-text-muted);
  stroke-width: 2;
  fill: none;
}

.footer-social a:hover {
  border-color: var(--color-accent);
  background: var(--color-accent-muted);
}

.footer-social a:hover svg {
  stroke: var(--color-accent-light);
}

.footer-col h4 {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-white);
  margin-bottom: 1rem;
}

.footer-col a {
  display: block;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  padding: 0.2rem 0;
  transition: var(--transition-fast);
}

.footer-col a:hover {
  color: var(--color-accent-light);
  padding-left: 0.4rem;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border-subtle);
  font-size: 0.78rem;
  color: var(--color-text-muted);
  font-family: var(--font-mono);
}

/* --- Reveal Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }
.reveal-d4 { transition-delay: 0.32s; }

/* --- Responsive --- */
@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75%;
    max-width: 320px;
    height: 100vh;
    background: rgba(6, 10, 19, 0.96);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    flex-direction: column;
    justify-content: center;
    gap: 2rem;
    transition: var(--transition-smooth);
    border-left: 1px solid var(--color-border-subtle);
  }

  .nav-links.open { right: 0; }
  .nav-toggle { display: flex; }

  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 0.75rem; text-align: center; }
  .cta-box { padding: 3rem 1.5rem; }
}

@media (max-width: 480px) {
  .container { padding: 0 1.25rem; }
}
/* --- Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(6, 10, 19, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  max-width: 400px;
  width: 90%;
  text-align: center;
  position: relative;
  transform: translateY(20px);
  transition: transform 0.3s ease;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  color: var(--color-text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  transition: color 0.2s;
}

.modal-close:hover {
  color: var(--color-text-white);
}

.modal-content h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.modal-content p {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.btn-discord {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: #5865F2; /* Discord brand color */
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  transition: background 0.2s, transform 0.2s;
}

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

.btn-discord svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}
