/* ============================================
   B.V. Larson - Author Website Style Sheet
   Dark cosmic theme: blue + green
   ============================================ */

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

:root {
  /* Colors */
  --bg-dark: #0a0a1a;
  --bg-darker: #060612;
  --bg-card: #12122a;
  --bg-card-hover: #1a1a3a;
  --primary: #3b82f6;
  --primary-dark: #2563eb;
  --accent: #10b981;
  --glow: #06b6d4;
  --blue: #3b82f6;
  --cyan: #06b6d4;
  --green: #10b981;
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --text-bright: #f8fafc;
  --border: rgba(59, 130, 246, 0.2);
  --border-hover: rgba(59, 130, 246, 0.4);

  /* Typography */
  --font-heading: 'Merriweather', serif;
  --font-body: 'Lato', sans-serif;
  --font-nav: 'Montserrat', sans-serif;

  /* Spacing */
  --nav-height: 70px;
  --section-padding: 100px 0;
  --container-width: 1200px;
  --gap: 24px;

  /* Effects */
  --glow-shadow: 0 0 20px rgba(6, 182, 212, 0.3), 0 0 60px rgba(16, 185, 129, 0.1);
  --card-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg-dark);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

a {
  color: var(--glow);
  text-decoration: none;
  transition: color var(--transition);
}

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

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

/* --- Skip Link (Accessibility) --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--primary);
  color: var(--text-bright);
  padding: 0.75rem 1.5rem;
  border-radius: 0 0 0.5rem 0.5rem;
  z-index: 2000;
  font-weight: 600;
  transition: top var(--transition);
}

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

/* --- Utility --- */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: var(--section-padding);
}

.text-center { text-align: center; }
.text-glow { text-shadow: var(--glow-shadow); }

/* Scroll-triggered animation */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--text-bright);
  line-height: 1.2;
  letter-spacing: 0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.5rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.5rem); }

.section-title {
  text-align: center;
  margin-bottom: 60px;
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 80px;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--green));
  margin: 16px auto 0;
  border-radius: 2px;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  background: transparent;
  z-index: 1000;
  display: flex;
  align-items: center;
  transition: background var(--transition), backdrop-filter var(--transition), box-shadow var(--transition);
}

.nav.scrolled {
  background: rgba(10, 10, 26, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

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

.nav-logo {
  font-family: var(--font-nav);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-bright);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 8px;
  align-items: center;
}

.nav-links a {
  font-family: var(--font-nav);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 8px;
  transition: all var(--transition);
  position: relative;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-bright);
  background: rgba(6, 182, 212, 0.1);
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
}

/* Social icon in nav */
.nav-social svg {
  width: 20px;
  height: 20px;
  fill: var(--text-muted);
  transition: fill var(--transition);
}

.nav-social:hover svg {
  fill: var(--text-bright);
}

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all var(--transition);
}

.nav-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bg-darker);
}

.hero-parallax {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-layer {
  position: absolute;
  inset: -50px;
  transition: transform 0.1s ease-out;
}

/* Layer 1: Starfield canvas */
.hero-layer--bg {
  z-index: 1;
}

.hero-layer--bg canvas {
  width: 100%;
  height: 100%;
}

/* Layer 2: Midground gradient */
.hero-layer--mid {
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-character-placeholder {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  background:
    radial-gradient(ellipse 40% 55% at 50% 35%,
      rgba(59, 130, 246, 0.25) 0%,
      rgba(6, 182, 212, 0.12) 30%,
      transparent 70%
    ),
    radial-gradient(ellipse 25% 40% at 50% 70%,
      rgba(16, 185, 129, 0.15) 0%,
      rgba(6, 182, 212, 0.08) 40%,
      transparent 70%
    );
}

/* Layer 3: Foreground particles */
.hero-layer--fg {
  z-index: 3;
  pointer-events: none;
}

/* Hero background video */
.hero-video-wrap {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 1;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-video-overlay {
  position: absolute;
  inset: 0;
  background: rgba(6, 6, 18, 0.5);
}

/* Hero content */
.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
  padding: 0 24px;
}

.hero-title {
  font-size: clamp(2.5rem, 7vw, 5rem);
  font-weight: 900;
  letter-spacing: 0.04em;
  background: linear-gradient(135deg, #3b82f6 0%, #06b6d4 40%, #10b981 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  -webkit-text-stroke: 2px #000;
  paint-order: stroke fill;
  margin-bottom: 16px;
}

.hero-subtitle {
  font-family: var(--font-nav);
  font-size: clamp(0.9rem, 2vw, 1.1rem);
  color: #fff;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 12px;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero-tagline {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  color: #fff;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 40px;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 12px;
  font-family: var(--font-nav);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  text-decoration: none;
}

.btn:focus-visible {
  outline: 3px solid var(--glow);
  outline-offset: 3px;
}

.btn-primary,
.btn-outline {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.7);
}

.btn-primary:hover,
.btn-outline:hover {
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--green));
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(6, 182, 212, 0.4);
  color: #fff;
}

/* --- Page Hero (non-home pages) --- */
.page-hero {
  padding: calc(var(--nav-height) + 60px) 0 60px;
  text-align: center;
  background: linear-gradient(180deg, var(--bg-darker) 0%, var(--bg-dark) 100%);
  position: relative;
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.page-hero h1 {
  margin-bottom: 12px;
}

.page-hero p {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* --- Cards --- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--gap);
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  transition: all var(--transition);
}

.card:hover {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
  transform: translateY(-4px);
  box-shadow: var(--card-shadow);
}

.card-image {
  width: 100%;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, var(--primary-dark), var(--cyan));
  position: relative;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-image.landscape {
  aspect-ratio: 16 / 9;
}

.card-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 3rem;
  color: rgba(255, 255, 255, 0.2);
}

.card-body {
  padding: 24px;
  text-align: center;
}

.card-body h3 {
  margin-bottom: 8px;
}

.card-body p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* Book Links */
.book-link {
  display: inline-block;
  margin-top: 16px;
  padding: 8px 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--green));
  border-radius: 6px;
  text-decoration: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.book-link:hover {
  opacity: 0.85;
  transform: translateY(-1px);
  color: #fff;
}

/* Tags */
.tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.tag-purple {
  background: rgba(99, 102, 241, 0.15);
  color: var(--glow);
  border: 1px solid rgba(99, 102, 241, 0.3);
}

.tag-blue {
  background: rgba(59, 130, 246, 0.15);
  color: var(--blue);
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.tag-cyan {
  background: rgba(6, 182, 212, 0.15);
  color: var(--cyan);
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.tag-green {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.tag-amber {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.tag-rose {
  background: rgba(244, 63, 94, 0.15);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.3);
}

/* --- Filter Buttons (Books page) --- */
.filter-bar {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.filter-btn {
  padding: 10px 24px;
  border-radius: 10px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--bg-card);
  color: var(--text-muted);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition);
}

.filter-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-bright);
}

.filter-btn:focus-visible {
  outline: 3px solid var(--glow);
  outline-offset: 3px;
}

.filter-btn.active {
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--green));
  color: var(--text-bright);
  border-color: transparent;
  box-shadow: 0 4px 16px rgba(6, 182, 212, 0.3);
}

/* --- Content Block (articles, about) --- */
.content-block {
  max-width: 800px;
  margin: 0 auto;
}

.content-block p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 20px;
}

.content-block h2 {
  margin-bottom: 24px;
}

.content-block h3 {
  margin-top: 32px;
  margin-bottom: 12px;
}

.content-block ul, .content-block ol {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 20px;
  padding-left: 24px;
}

/* --- Bio Section --- */
.bio-section {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 48px;
  align-items: start;
  max-width: 900px;
  margin: 0 auto;
}

.bio-image img {
  width: 100%;
  border-radius: 16px;
  border: 2px solid var(--border);
}

.bio-text p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 16px;
}

/* --- Timeline (Career History) --- */
.timeline-section {
  background: var(--bg-darker);
  padding: var(--section-padding);
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  padding-left: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(to bottom, var(--blue), var(--green));
  border-radius: 3px;
}

.timeline-item {
  position: relative;
  padding-bottom: 2.5rem;
  padding-left: 2rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -2rem;
  top: 0.25rem;
  width: 13px;
  height: 13px;
  background: var(--primary);
  border: 3px solid var(--bg-darker);
  border-radius: 50%;
  transform: translateX(-5px);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-content {
  background: var(--bg-card);
  padding: 1.5rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}

.timeline-content:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.timeline-date {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: linear-gradient(135deg, var(--blue), var(--green));
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 0.75rem;
}

.timeline-content h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.timeline-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- Featured Books (Homepage) --- */
.featured-books .card-grid {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

/* --- Series Spotlight (Homepage) --- */
.series-spotlight {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  min-height: 400px;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 48px;
  border: 1px solid var(--border);
  background: var(--bg-card);
}

.series-spotlight:nth-child(even) .spotlight-image {
  order: 2;
}

.series-spotlight:nth-child(even) .spotlight-content {
  order: 1;
}

.spotlight-image {
  background-size: cover;
  background-position: center;
  min-height: 300px;
}

.spotlight-content {
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.spotlight-content h3 {
  font-size: 1.5rem;
  margin-bottom: 12px;
}

.spotlight-content p {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 24px;
}

/* --- Scam Alert --- */
.scam-alert {
  background: rgba(218, 14, 43, 0.08);
  border: 1px solid rgba(218, 14, 43, 0.3);
  border-radius: 16px;
  padding: 32px;
  max-width: 800px;
  margin: 0 auto;
}

.scam-alert h3 {
  color: var(--accent);
  margin-bottom: 12px;
}

.scam-alert p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* --- Article Cards --- */
.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  transition: all var(--transition);
  margin-bottom: var(--gap);
}

.article-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: var(--card-shadow);
}

.article-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 8px;
}

.article-category {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(6, 182, 212, 0.15);
  color: var(--cyan);
  border: 1px solid rgba(6, 182, 212, 0.3);
  margin-bottom: 12px;
}

.article-card h3 {
  margin-bottom: 12px;
}

.article-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 16px;
}

.read-more {
  font-family: var(--font-nav);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--glow);
}

.read-more:hover {
  color: var(--accent);
}

/* --- Article Detail --- */
.article-meta {
  text-align: center;
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.article-meta .article-date {
  display: block;
  margin-bottom: 12px;
}

/* --- Contact Page --- */
.contact-info {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.contact-info p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 20px;
}

.contact-item {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin: 8px;
  transition: all var(--transition);
  color: var(--text);
  font-weight: 500;
}

.contact-item:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
  color: var(--text-bright);
}

.contact-item:focus-visible {
  outline: 3px solid var(--glow);
  outline-offset: 3px;
}

.contact-item svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

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

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 40px;
}

.footer-brand h4 {
  font-family: var(--font-nav);
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 300px;
}

.footer-links h4 {
  font-family: var(--font-nav);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
  color: var(--text-muted);
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin-bottom: 10px;
}

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

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

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

/* --- Responsive --- */
@media (max-width: 768px) {
  :root {
    --section-padding: 60px 0;
    --gap: 16px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: rgba(10, 10, 26, 0.95);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 16px;
    border-bottom: 1px solid var(--border);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 12px 16px;
  }

  .nav-toggle {
    display: flex;
  }

  .hero-character-placeholder {
    width: 100%;
    height: 100%;
  }

  .bio-section {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .bio-image {
    max-width: 250px;
    margin: 0 auto;
  }

  .series-spotlight {
    grid-template-columns: 1fr;
  }

  .series-spotlight:nth-child(even) .spotlight-image {
    order: 0;
  }

  .series-spotlight:nth-child(even) .spotlight-content {
    order: 0;
  }

  .spotlight-content {
    padding: 32px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }

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

  /* Timeline stays left-aligned on mobile */
}

@media (min-width: 1024px) {
  /* Alternating timeline on desktop */
  .timeline {
    padding-left: 0;
  }

  .timeline::before {
    left: 50%;
    transform: translateX(-50%);
  }

  .timeline-item {
    width: 50%;
    padding-left: 2.5rem;
  }

  .timeline-item:nth-child(odd) {
    margin-left: 0;
    padding-left: 0;
    padding-right: 2.5rem;
    text-align: right;
  }

  .timeline-item:nth-child(even) {
    margin-left: 50%;
  }

  .timeline-item::before {
    left: auto;
  }

  .timeline-item:nth-child(odd)::before {
    right: -2.5rem;
    left: auto;
    transform: translateX(5px);
  }

  .timeline-item:nth-child(even)::before {
    left: -2.5rem;
    transform: translateX(-5px);
  }
}

@media (max-width: 480px) {
  .hero-title {
    letter-spacing: 0.02em;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .btn {
    width: 100%;
    justify-content: center;
    max-width: 280px;
  }
}

/* --- Focus Visible --- */
*:focus-visible {
  outline: 3px solid var(--glow);
  outline-offset: 2px;
}

*:focus:not(:focus-visible) {
  outline: none;
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }

  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
