/* Critical CSS - Above-the-fold rendering path */

:root {
  /* Colors */
  --color-bg-primary: #0D0D0D;
  --color-bg-secondary: #1A1A2E;
  --color-bg-surface: #16213E;
  --color-primary: #F25672;
  --color-primary-hover: #FF7A8E;
  --color-secondary: #9B59B6;
  --color-secondary-hover: #B07CC6;
  --color-accent: #D4AF37;
  --color-accent-hover: #E8C84A;
  --color-text: #FAFAFA;
  --color-text-muted: #C0C0D0;
  --color-text-heading: #FFFFFF;
  --color-border: #3A3A5C;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #F25672 0%, #FF7A8E 100%);
  --gradient-secondary: linear-gradient(135deg, #9B59B6 0%, #B07CC6 100%);
  --gradient-dark-overlay: linear-gradient(135deg, rgba(242, 86, 114, 0.15) 0%, rgba(155, 89, 182, 0.15) 100%);

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(242, 86, 114, 0.3);

  /* Border radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  /* Spacing */
  --spacing-xs: 4px;
  --spacing-sm: 8px;
  --spacing-md: 16px;
  --spacing-lg: 24px;
  --spacing-xl: 32px;
  --spacing-2xl: 48px;
  --spacing-3xl: 64px;

  /* Typography */
  --font-display: 'Playfair Display', serif;
  --font-body: 'DM Sans', sans-serif;
  --font-mono: 'Space Grotesk', sans-serif;

  --line-height-tight: 1.2;
  --line-height-normal: 1.6;
  --line-height-relaxed: 1.8;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--color-bg-primary);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.75;
  letter-spacing: 0.01em;
  overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  color: var(--color-text-heading);
  line-height: var(--line-height-tight);
  margin-bottom: var(--spacing-md);
  font-weight: 700;
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h3 {
  font-size: clamp(1.25rem, 3vw, 1.75rem);
}

p {
  margin-bottom: var(--spacing-md);
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--color-primary-hover);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
  width: 100%;
}

/* Skip to content link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background-color: var(--color-primary);
  color: white;
  padding: var(--spacing-sm) var(--spacing-md);
  text-decoration: none;
  border-radius: var(--radius-md);
  z-index: 9999;
}

.skip-link:focus {
  top: 0;
}

/* Navbar */
nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(13, 13, 13, 0.7);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md) 0;
  max-width: 1200px;
  margin: 0 auto;
  padding-left: var(--spacing-md);
  padding-right: var(--spacing-md);
}

.logo {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-text-heading);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.logo:hover {
  color: var(--color-primary);
}

.nav-center {
  display: none;
  gap: var(--spacing-lg);
  flex: 1;
  margin: 0 var(--spacing-2xl);
}

@media (min-width: 768px) {
  .nav-center {
    display: flex;
  }
}

.nav-item {
  color: var(--color-text);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
}

.nav-item:hover {
  color: var(--color-primary);
}

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

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

.nav-right {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.nav-cta {
  display: none;
  background: var(--gradient-primary);
  color: white;
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
  color: white;
}

@media (min-width: 768px) {
  .nav-cta {
    display: inline-block;
  }
}

.nav-toggle {
  display: block;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text);
  font-size: 1.5rem;
  padding: var(--spacing-sm);
  margin: calc(var(--spacing-sm) * -1);
}

@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }
}

/* Hero section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-dark-overlay), linear-gradient(135deg, #0D0D0D 0%, #1A1A2E 100%);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(242, 86, 114, 0.1) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -5%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(155, 89, 182, 0.1) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
  max-width: 800px;
  padding: 0 var(--spacing-md);
}

/* Button base styles */
.btn {
  display: inline-block;
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: center;
  line-height: var(--line-height-tight);
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
  color: white;
}

.btn-secondary {
  background: var(--gradient-secondary);
  color: white;
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(155, 89, 182, 0.3);
  color: white;
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}

.btn-outline:hover {
  background: var(--color-primary);
  color: white;
}

/* Age gate modal */
.age-gate {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
  backdrop-filter: blur(5px);
}

.age-gate.hidden {
  display: none;
}

.age-gate-card {
  background: linear-gradient(135deg, #1A1A2E 0%, #16213E 100%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--spacing-3xl) var(--spacing-2xl);
  max-width: 450px;
  width: 90%;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.age-gate-card h1 {
  font-size: 2rem;
  margin-bottom: var(--spacing-lg);
  color: var(--color-primary);
}

.age-gate-card p {
  color: var(--color-text-muted);
  margin-bottom: var(--spacing-lg);
  line-height: var(--line-height-relaxed);
  font-size: 0.95rem;
}

.age-gate-warning {
  background: rgba(242, 86, 114, 0.1);
  border-left: 4px solid var(--color-primary);
  padding: var(--spacing-md);
  border-radius: var(--radius-md);
  margin-bottom: var(--spacing-2xl);
  text-align: left;
  font-size: 0.85rem;
  color: var(--color-text);
}

.age-gate-buttons {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
}

.age-gate-buttons button {
  flex: 1;
  padding: var(--spacing-md) var(--spacing-lg);
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}

.age-gate-accept {
  background: var(--gradient-primary);
  color: white;
}

.age-gate-accept:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.age-gate-reject {
  background: var(--color-border);
  color: var(--color-text);
}

.age-gate-reject:hover {
  background: #3D3D5C;
}

/* Reading progress bar */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--gradient-primary);
  z-index: 9997;
  width: 0%;
  transition: width 0.3s ease;
}
