/* ========================================
   Reset & Base Styles
   ======================================== */

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

:root {
  /* RescueDesk Brand Gradient (Primary) */
  --rd-gradient-primary: linear-gradient(135deg,
      #7A3FF2 0%,
      #8F4FD8 25%,
      #C24AC7 45%,
      #2ED3C6 70%,
      #4DE3FF 100%);

  /* Purple System (Primary / Brand) */
  --rd-purple-primary: #7A3FF2;
  --rd-purple-deep: #5B2DBA;
  --rd-purple-soft: #BFAAF7;

  /* Teal System (Secondary / Data) */
  --rd-teal-primary: #2ED3C6;
  --rd-teal-deep: #1FA4A9;
  --rd-teal-soft: #A8F0E6;

  /* Accent Colors */
  --rd-accent-magenta: #C24AC7;
  --rd-accent-cyan: #4DE3FF;

  /* Neutral System - Dark UI */
  --rd-neutral-obsidian: #141421;
  --rd-neutral-charcoal: #1E1E2A;
  --rd-neutral-slate: #2C2F3A;
  --rd-neutral-muted: #6B6F85;

  /* Neutral System - Light UI */
  --rd-neutral-white: #F7F9FC;
  --rd-neutral-soft: #ECEFF4;
  --rd-neutral-divider: #D6DAE3;

  /* Semantic Colors */
  --rd-success: #2ECC9A;
  --rd-warning: #F4B740;
  --rd-error: #E5533D;
  --rd-info: #4D9DE0;

  /* Legacy aliases for compatibility */
  --primary: var(--rd-purple-primary);
  --primary-dark: var(--rd-purple-deep);
  --secondary: var(--rd-teal-primary);
  --accent: var(--rd-accent-cyan);

  /* Neutrals */
  --text-primary: var(--rd-neutral-obsidian);
  --text-secondary: var(--rd-neutral-muted);
  --text-light: var(--rd-neutral-muted);
  --bg-white: var(--rd-neutral-white);
  --bg-light: var(--rd-neutral-soft);
  --bg-dark: var(--rd-neutral-charcoal);

  /* Gradients */
  --gradient-primary: var(--rd-gradient-primary);
  --gradient-hero: var(--rd-gradient-primary);

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
  --spacing-xl: 6rem;

  /* Typography */
  --font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-size-base: 16px;
  --line-height-base: 1.6;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(20, 20, 33, 0.1);
  --shadow-md: 0 4px 6px rgba(20, 20, 33, 0.1);
  --shadow-lg: 0 10px 25px rgba(20, 20, 33, 0.15);
  --shadow-xl: 0 20px 40px rgba(20, 20, 33, 0.2);

  /* Transitions */
  --transition-base: all 0.3s ease;
  --transition-slow: all 0.5s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  color: var(--text-primary);
  background-color: var(--bg-white);
  overflow-x: hidden;
}

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

/* ========================================
   Hero Section
   ======================================== */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  color: white;
}

.hero-top-bar {
  width: 100%;
  background: var(--rd-neutral-charcoal);
  padding: 20px;
  z-index: 10;
  position: relative;
}

.hero-top-bar .container {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-gradient-section {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 120px);
  padding-top: var(--spacing-xs);
  padding-bottom: var(--spacing-xs);
}

/* Matches web-app LoginView.vue animated background */
@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

@keyframes heroGlowPulse {
  0% {
    opacity: 0.4;
    transform: translate(-50%, -50%) scale(0.8);
  }

  50% {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(1.1);
  }

  100% {
    opacity: 0.4;
    transform: translate(-50%, -50%) scale(0.8);
  }
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 0;
  overflow: hidden;
  background: linear-gradient(
    -45deg,
    var(--rd-teal-primary),
    var(--rd-teal-deep),
    var(--rd-accent-magenta),
    var(--rd-purple-deep)
  );
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
}

.hero-background::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 80vmax;
  height: 80vmax;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.2) 0%,
    transparent 70%
  );
  animation: heroGlowPulse 8s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

.gradient-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  background: radial-gradient(circle at 30% 50%, rgba(122, 63, 242, 0.2), transparent 50%),
    radial-gradient(circle at 70% 50%, rgba(46, 211, 198, 0.2), transparent 50%);
  animation: pulse 8s ease-in-out infinite;
}

.grid-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 50px 50px;
  opacity: 0.5;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.8;
  }
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 900px;
  padding: 0;
  animation: fadeInUp 1s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.logo-image {
  width: auto;
  height: auto;
  max-height: 100px;
  display: block;
  image-rendering: auto;
  -ms-interpolation-mode: bicubic;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@media (max-width: 768px) {
  .logo-image {
    max-width: 400px;
    max-height: 150px;
  }
}

@media (max-width: 480px) {
  .logo-image {
    max-width: 300px;
    max-height: 120px;
  }
}

.hero-title {
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: var(--spacing-md);
  letter-spacing: -0.02em;
}

.hero-title .title-line {
  display: block;
}

.hero-subtitle {
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  line-height: 1.6;
  margin-bottom: var(--spacing-lg);
  opacity: 0.95;
  font-weight: 400;
}

.hero-subtitle strong {
  font-weight: 600;
  color: white;
}

.hero-subtitle--stacked {
  font-size: clamp(1rem, 1.65vw, 1.25rem);
  max-width: 40rem;
  margin-left: auto;
  margin-right: auto;
}

.hero-subtitle--stacked p + p {
  margin-top: var(--spacing-sm);
}

.hero-subtitle--stacked p.hero-subtitle-closing {
  margin-top: var(--spacing-md);
}

.hero-subtitle-closing {
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.05rem, 1.8vw, 1.35rem);
  letter-spacing: 0.02em;
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.2);
}

.hero-cta {
  display: inline-block;
  margin-top: var(--spacing-lg);
  padding: 0.9rem 1.85rem;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: white;
  text-decoration: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  transition: var(--transition-base);
}

.hero-cta:hover {
  color: white;
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.45);
  transform: translateY(-2px);
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.hero-cta:focus-visible {
  outline: 2px solid white;
  outline-offset: 3px;
}

.scroll-indicator {
  position: absolute;
  bottom: var(--spacing-md);
  left: 50%;
  transform: translateX(-50%);
  color: white;
  opacity: 0.7;
  animation: bounce 2s infinite;
  z-index: 1;
}

@keyframes bounce {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  40% {
    transform: translateX(-50%) translateY(-10px);
  }

  60% {
    transform: translateX(-50%) translateY(-5px);
  }
}

/* ========================================
   Section atmosphere (Our Story, What We Built, What We Don't Do)
   ======================================== */

.story,
.features,
.scope,
.contact {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(165deg, var(--bg-white) 0%, var(--rd-neutral-soft) 42%, #eef2fb 100%);
}

.story::before,
.story::after,
.features::before,
.features::after,
.scope::before,
.scope::after,
.contact::before,
.contact::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

.story::before,
.features::before,
.scope::before,
.contact::before {
  top: -12%;
  right: -8%;
  width: min(520px, 70vw);
  height: min(520px, 70vw);
  background: radial-gradient(circle at center, rgba(122, 63, 242, 0.14) 0%, transparent 68%);
}

.story::after,
.features::after,
.scope::after,
.contact::after {
  bottom: 5%;
  left: -12%;
  width: min(440px, 65vw);
  height: min(440px, 65vw);
  background: radial-gradient(circle at center, rgba(46, 211, 198, 0.12) 0%, transparent 68%);
}

.story .container,
.features .container,
.scope .container,
.contact .container {
  position: relative;
  z-index: 1;
}

/* ========================================
   Our Story Section
   ======================================== */

.story {
  padding: var(--spacing-xl) 0 calc(var(--spacing-xl) + var(--spacing-md));
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-xl);
}

/* Gradient title + accent bar (Our Story, What We Built, Scope, etc.) */
.section-header--brand {
  margin-bottom: var(--spacing-lg);
}

.section-header h2 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: var(--spacing-sm);
  line-height: 1.2;
}

.section-header--brand h2 {
  color: var(--rd-purple-deep);
}

@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .section-header--brand h2 {
    background: var(--rd-gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
  }
}

.section-heading-accent {
  display: block;
  width: 88px;
  height: 5px;
  margin: 0 auto var(--spacing-sm);
  border-radius: 999px;
  background: var(--rd-gradient-primary);
  box-shadow: 0 4px 20px rgba(122, 63, 242, 0.35);
}

.section-heading-tagline {
  margin-top: 0;
  margin-bottom: 0;
  font-size: 1rem;
  font-weight: 500;
  color: var(--rd-purple-deep);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.section-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  font-weight: 400;
}

.story-content {
  max-width: 920px;
  margin: 0 auto;
}

.story-panel {
  position: relative;
  background: var(--bg-white);
  border-radius: 24px;
  padding: clamp(1.5rem, 4.5vw, 3rem);
  border: 1px solid rgba(122, 63, 242, 0.12);
  box-shadow:
    var(--shadow-xl),
    0 0 0 1px rgba(255, 255, 255, 0.8) inset;
}

.story-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg,
      rgba(122, 63, 242, 0.25) 0%,
      rgba(46, 211, 198, 0.2) 50%,
      rgba(77, 227, 255, 0.2) 100%);
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.story-prose .lead {
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
}

.story-prose-lead {
  position: relative;
  margin-bottom: var(--spacing-lg);
  padding: var(--spacing-md) var(--spacing-md) var(--spacing-md) calc(var(--spacing-md) + 14px);
  background: linear-gradient(125deg,
      rgba(122, 63, 242, 0.07) 0%,
      rgba(46, 211, 198, 0.06) 55%,
      rgba(77, 227, 255, 0.05) 100%);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(20, 20, 33, 0.06);
}

.story-prose-lead::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1rem;
  bottom: 1rem;
  width: 4px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--rd-purple-primary) 0%, var(--rd-teal-primary) 100%);
}

.story-prose .lead.story-prose-lead {
  margin-bottom: var(--spacing-lg);
}

.story-stat {
  display: inline-block;
  font-weight: 800;
  font-size: 1.08em;
  padding: 0.12em 0.45em;
  margin: 0 0.05em;
  border-radius: 10px;
  letter-spacing: -0.03em;
  color: var(--rd-purple-deep);
  background: linear-gradient(135deg, rgba(122, 63, 242, 0.14), rgba(194, 74, 199, 0.12));
  box-shadow: 0 2px 8px rgba(122, 63, 242, 0.12);
}

.story-prose p {
  font-size: 1.0625rem;
  line-height: 1.85;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-lg);
}

.story-prose p:last-child {
  margin-bottom: 0;
}

.story-prose p.story-verse {
  position: relative;
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  line-height: 1.7;
  font-weight: 500;
  color: #ffffff;
  margin: var(--spacing-lg) 0;
  padding: var(--spacing-lg) var(--spacing-lg) var(--spacing-lg) var(--spacing-xl);
  background: linear-gradient(145deg, #2a2a38 0%, #232330 55%, #1e1e2a 100%);
  border-radius: 18px;
  box-shadow:
    var(--shadow-lg),
    0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  overflow: hidden;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.story-prose p.story-verse::before {
  content: "\201C";
  position: absolute;
  top: 0.35rem;
  left: 0.65rem;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 4.5rem;
  line-height: 1;
  color: var(--rd-teal-primary);
  opacity: 0.28;
  pointer-events: none;
}

.story-prose p.story-verse::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: min(38%, 200px);
  height: 100%;
  background: linear-gradient(105deg, transparent 0%, rgba(122, 63, 242, 0.06) 100%);
  pointer-events: none;
}

.story-prose strong {
  color: var(--rd-purple-primary);
  font-weight: 600;
}

.story-prose cite {
  font-style: italic;
  color: var(--text-primary);
}

/* ========================================
   Features Section
   ======================================== */

.features {
  padding: var(--spacing-xl) 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

/* 2×2 layout: wider cards, less tall-and-skinny than four in one row */
.features-grid--four {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.feature-card {
  background: white;
  padding: var(--spacing-lg);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  transition: var(--transition-base);
  border: 1px solid var(--rd-neutral-divider);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--rd-purple-primary);
}

.feature-card-head {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-md);
}

.feature-icon {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  background: var(--rd-purple-primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.feature-card h3 {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--text-primary);
}

.feature-card p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

/* ========================================
   Scope Section
   ======================================== */

.scope {
  padding: var(--spacing-xl) 0;
}

.scope-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-lg);
}

.scope-content--single {
  grid-template-columns: 1fr;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.scope-column {
  background: white;
  padding: var(--spacing-lg);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
}

.scope-column h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
}

.scope-list {
  list-style: none;
}

.scope-list li {
  padding: var(--spacing-sm) 0;
  padding-left: var(--spacing-md);
  position: relative;
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--text-primary);
}

.scope-list li:before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--rd-purple-primary);
  font-weight: bold;
  font-size: 1.25rem;
}

.scope-list.dont li:before {
  content: "×";
  color: var(--text-light);
}

.scope-note {
  margin-top: var(--spacing-lg);
  padding: var(--spacing-md);
  background: white;
  border-radius: 12px;
  border-left: 4px solid var(--rd-purple-primary);
}

.scope-note p {
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.scope-note strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* ========================================
   Contact Us
   ======================================== */

.contact {
  padding: var(--spacing-xl) 0 calc(var(--spacing-xl) + var(--spacing-sm));
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--spacing-lg);
  max-width: 880px;
  margin: var(--spacing-lg) auto 0;
}

.contact-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(1.75rem, 4vw, 2.75rem) var(--spacing-lg);
  border-radius: 20px;
  text-decoration: none;
  color: inherit;
  background: linear-gradient(180deg, #ffffff 0%, var(--rd-neutral-white) 100%);
  border: 1px solid rgba(122, 63, 242, 0.1);
  box-shadow:
    var(--shadow-lg),
    0 0 0 1px rgba(255, 255, 255, 0.85) inset;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  overflow: hidden;
}

.contact-tile::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  border-radius: 20px 20px 0 0;
}

.contact-tile--sales::before {
  background: linear-gradient(90deg, var(--rd-purple-primary), var(--rd-accent-magenta));
}

.contact-tile--support::before {
  background: linear-gradient(90deg, var(--rd-teal-primary), var(--rd-accent-cyan));
}

.contact-tile:hover {
  transform: translateY(-6px);
  box-shadow:
    var(--shadow-xl),
    0 0 0 1px rgba(255, 255, 255, 0.9) inset;
  border-color: rgba(122, 63, 242, 0.22);
}

.contact-tile:focus-visible {
  outline: 2px solid var(--rd-purple-primary);
  outline-offset: 3px;
}

.contact-tile-icon {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--spacing-md);
}

.contact-tile--sales .contact-tile-icon {
  background: linear-gradient(145deg, rgba(122, 63, 242, 0.16) 0%, rgba(194, 74, 199, 0.1) 100%);
  color: var(--rd-purple-deep);
  box-shadow: 0 8px 24px rgba(122, 63, 242, 0.15);
}

.contact-tile--support .contact-tile-icon {
  background: linear-gradient(145deg, rgba(46, 211, 198, 0.22) 0%, rgba(77, 227, 255, 0.12) 100%);
  color: var(--rd-teal-deep);
  box-shadow: 0 8px 24px rgba(46, 211, 198, 0.14);
}

.contact-tile h3 {
  font-size: clamp(1.35rem, 3vw, 1.6rem);
  font-weight: 700;
  margin: 0 0 var(--spacing-sm);
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.contact-tile-email {
  font-size: 1.0625rem;
  font-weight: 600;
  word-break: break-word;
  max-width: 100%;
}

.contact-tile--sales .contact-tile-email {
  color: var(--rd-purple-primary);
}

.contact-tile--support .contact-tile-email {
  color: var(--rd-teal-deep);
}

.contact-tile:hover .contact-tile-email {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ========================================
   Footer
   ======================================== */

.footer {
  padding: var(--spacing-xl) 0;
  background: var(--rd-neutral-charcoal);
  color: white;
  text-align: center;
}

.footer-content {
  max-width: 600px;
  margin: 0 auto;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--spacing-md);
}

.footer-logo-image {
  height: 40px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  display: block;
  filter: brightness(0) invert(1);
}

@media (max-width: 768px) {
  .footer-logo-image {
    height: 32px;
  }
}

.footer-tagline {
  font-size: 1.125rem;
  margin-bottom: var(--spacing-md);
  opacity: 0.9;
}

.footer-links {
  margin-bottom: var(--spacing-md);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  flex-wrap: wrap;
}

.footer-links a {
  color: white;
  text-decoration: none;
  opacity: 0.8;
  transition: var(--transition-base);
  font-size: 0.875rem;
}

.footer-links a:hover {
  opacity: 1;
  text-decoration: underline;
}

.footer-separator {
  opacity: 0.5;
  color: white;
}

.footer-copyright {
  font-size: 0.875rem;
  opacity: 0.7;
  margin-bottom: var(--spacing-xs);
}

.footer-mission {
  font-size: 1rem;
  opacity: 0.8;
  font-style: italic;
}

/* ========================================
   Responsive Design
   ======================================== */

@media (max-width: 768px) {
  .container {
    padding: 0 var(--spacing-sm);
  }

  .hero {
    min-height: 90vh;
  }

  .hero-content {
    padding: var(--spacing-lg) 0;
  }

  .section-header h2 {
    font-size: 2rem;
  }

  .features-grid,
  .scope-content,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .story-panel {
    padding: var(--spacing-md);
    border-radius: 20px;
  }

  .story-prose p.story-verse {
    padding: var(--spacing-md) var(--spacing-md) var(--spacing-md) var(--spacing-lg);
  }

  .story-prose p.story-verse::before {
    font-size: 3.5rem;
    left: 0.4rem;
  }

}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-subtitle--stacked {
    font-size: 0.9375rem;
  }

  .hero-subtitle-closing {
    font-size: 1rem;
  }

  .feature-card,
  .scope-column,
  .contact-tile {
    padding: var(--spacing-md);
  }
}

/* ========================================
   Accessibility
   ======================================== */

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .story-reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* Focus styles for keyboard navigation */
:focus-visible {
  outline: 2px solid var(--rd-purple-primary);
  outline-offset: 2px;
}

/* ========================================
   Legal Pages (Terms, Privacy)
   ======================================== */

.legal-page {
  min-height: 100vh;
  background: var(--bg-light);
  padding: var(--spacing-xl) 0;
}

.legal-header {
  text-align: center;
  margin-bottom: var(--spacing-xl);
  padding-bottom: var(--spacing-md);
  border-bottom: 2px solid var(--rd-purple-primary);
}

.legal-header .logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--spacing-md);
}

.legal-header .logo-image {
  height: 50px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  display: block;
}

@media (max-width: 768px) {
  .legal-header .logo-image {
    height: 40px;
  }
}

.legal-header h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: var(--spacing-sm);
}

.last-updated {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-style: italic;
}

.legal-content {
  max-width: 900px;
  margin: 0 auto;
  background: white;
  padding: var(--spacing-xl);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
}

.legal-content section {
  margin-bottom: var(--spacing-xl);
}

.legal-content section:last-child {
  margin-bottom: 0;
}

.legal-content h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: var(--spacing-md);
  margin-bottom: var(--spacing-sm);
}

.legal-content p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
}

.legal-content p strong {
  color: var(--text-primary);
  font-weight: 600;
}

.legal-content ul {
  margin-left: var(--spacing-md);
  margin-bottom: var(--spacing-md);
}

.legal-content li {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-xs);
}

.legal-table-wrap {
  width: 100%;
  overflow-x: auto;
  margin-bottom: var(--spacing-md);
  -webkit-overflow-scrolling: touch;
}

.legal-content table {
  width: 100%;
  min-width: 36rem;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.legal-content th,
.legal-content td {
  border: 1px solid var(--rd-neutral-divider);
  padding: 0.5rem 0.65rem;
  vertical-align: top;
  text-align: left;
}

.legal-content th {
  background: var(--rd-neutral-soft, #f8fafc);
  color: var(--text-primary);
  font-weight: 600;
}

.legal-content a {
  color: var(--rd-purple-primary);
  text-decoration: underline;
  transition: var(--transition-base);
}

.legal-content a:hover {
  color: var(--rd-purple-deep);
}

.legal-footer {
  max-width: 900px;
  margin: var(--spacing-xl) auto 0;
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-md) 0;
}

.legal-footer a {
  color: var(--rd-purple-primary);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition-base);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: 8px;
}

.legal-footer a:hover {
  background: var(--rd-neutral-soft);
  color: var(--rd-purple-deep);
}

@media (max-width: 768px) {
  .legal-content {
    padding: var(--spacing-md);
  }

  .legal-content h2 {
    font-size: 1.5rem;
  }

  .legal-footer {
    flex-direction: column;
    gap: var(--spacing-sm);
  }
}