/* ==============================================
   Earth Departure Authority — V2 Dark Premium
   ============================================== */

:root {
  --bg: #08080F;
  --bg-alt: #0E0E1A;
  --bg-card: #111120;
  --bg-elevated: #1A1A2E;

  --text: #E8E4DD;
  --text-secondary: #8A8A9E;
  --text-muted: #4E4E64;

  --accent: #C8A96E;
  --accent-hover: #DFC189;
  --red: #C94040;
  --green: #48BB78;

  --border: #1C1C30;
  --border-light: #25253A;

  --font-serif: 'Instrument Serif', Georgia, serif;
  --font-serif-cyr: 'Playfair Display', 'Instrument Serif', Georgia, serif;
  --font-sans: 'DM Sans', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --container: 860px;
  --container-narrow: 600px;
  --radius: 8px;
  --radius-sm: 4px;
}

/* --- Reset --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { cursor: pointer; font-family: inherit; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* --- Layout --- */
.container { max-width: var(--container); margin: 0 auto; padding: 0 1.5rem; }
.container-narrow { max-width: var(--container-narrow); }
.section { padding: clamp(3.5rem, 9vw, 5rem) 0; }

/* --- Typography --- */
h1, h2, h3 { font-family: var(--font-serif); font-weight: 400; line-height: 1.2; }
html[lang="ru"] h1,
html[lang="ru"] h2 { font-family: var(--font-serif-cyr); }
html[lang="ru"] .success-headline,
html[lang="ru"] .footer-org,
html[lang="ru"] .voice-quote { font-family: var(--font-serif-cyr); }
h1 { font-size: clamp(3rem, 8vw, 5.5rem); letter-spacing: -0.02em; }
html[lang="ru"] h1 { font-size: clamp(2.5rem, 6.5vw, 4.2rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); margin-bottom: 2rem; }
h3 { font-size: 1.15rem; font-family: var(--font-sans); font-weight: 700; margin-bottom: 0.4rem; }

.section-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  text-align: center;
  gap: 0.5rem; padding: 0.85rem 1.75rem;
  font-size: 0.95rem; font-weight: 700;
  text-decoration: none; border: none; border-radius: var(--radius);
  transition: all 0.2s ease;
}
.btn-accent {
  background: var(--accent);
  color: var(--bg);
}
.btn-accent:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 20px rgba(200, 169, 110, 0.3);
  transform: translateY(-1px);
}
.btn-accent:active { transform: translateY(0); }
.btn-sm { padding: 0.55rem 1.25rem; font-size: 0.85rem; }
.btn-submit .btn-loading { display: none; }
.btn-submit.is-loading .btn-text { display: none; }
.btn-submit.is-loading .btn-loading { display: inline; }

/* Form Errors */
.form-error {
  margin-top: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--red);
  letter-spacing: 0.02em;
  text-align: left;
  animation: errorIn 0.25s ease-out;
}
.form-suggestion {
  display: inline;
  background: none;
  border: none;
  border-bottom: 1px dashed var(--accent);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  padding: 0;
  cursor: pointer;
  transition: color 0.2s ease;
}
.form-suggestion:hover { color: var(--accent-hover); }
@keyframes errorIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== LANGUAGE PICKER ===== */
.lang-picker {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}
.lang-btn {
  background: none;
  border: none;
  padding: 0.2rem 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  transition: color 0.2s ease;
  border-bottom: 1px solid transparent;
}
.lang-btn:hover { color: var(--text-secondary); }
.lang-btn.is-active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}
.lang-sep {
  color: var(--text-muted);
  opacity: 0.3;
  font-size: 0.5rem;
  user-select: none;
}

.hero-lang {
  position: absolute;
  top: 1.25rem;
  right: 1.5rem;
  z-index: 10;
}

.footer-lang {
  margin-bottom: 1.25rem;
  justify-content: center;
}

/* ===== STICKY CTA ===== */
.sticky-cta {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(8, 8, 15, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0.6rem 0;
  transform: translateY(-100%);
  transition: transform 0.35s ease;
}
.sticky-cta.visible { transform: translateY(0); }
.sticky-cta-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.sticky-cta-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
}
.sticky-cta-badge::before {
  content: '●';
  color: var(--green);
  margin-right: 0.5rem;
  font-size: 0.6rem;
}

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding: 2rem 1.5rem;
  background:
    radial-gradient(ellipse at 15% 80%, rgba(40, 20, 80, 0.18) 0%, transparent 50%),
    radial-gradient(ellipse at 85% 20%, rgba(20, 40, 100, 0.12) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 0%, rgba(200, 169, 110, 0.04) 0%, transparent 40%),
    var(--bg);
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1px 1px at 10% 20%, rgba(255,255,255,0.15) 1px, transparent 0),
    radial-gradient(1px 1px at 30% 65%, rgba(255,255,255,0.1) 1px, transparent 0),
    radial-gradient(1px 1px at 55% 15%, rgba(255,255,255,0.12) 1px, transparent 0),
    radial-gradient(1px 1px at 70% 75%, rgba(255,255,255,0.08) 1px, transparent 0),
    radial-gradient(1px 1px at 90% 40%, rgba(255,255,255,0.15) 1px, transparent 0);
  background-size: 180px 180px, 250px 250px, 200px 200px, 300px 300px, 220px 220px;
  animation: drift 90s linear infinite;
  pointer-events: none;
}

@keyframes drift {
  from { transform: translateY(0); }
  to { transform: translateY(-180px); }
}

.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; opacity: 0; z-index: 0;
  transition: opacity 1.5s ease;
}
.hero-video.is-active { opacity: 0.2; }

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 640px;
  width: 100%;
}

.hero-badge {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  position: relative;
}

.hero-badge-dot {
  width: 6px; height: 6px;
  background: var(--green);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* Hero Stamp */
.hero-stamp {
  position: absolute;
  top: 40%; /*calc(100% - 1.0rem);*/
  left: 90%;
  transform: translateX(-50%) rotate(-2deg);
  white-space: nowrap;
  padding: 4px 16px;
  border: 1.5px solid var(--accent);
  border-radius: 2px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  opacity: 0.6;
  pointer-events: none;
  animation: stampFade 0.5s ease-out 0.3s both;
}

@keyframes stampFade {
  from { opacity: 0; transform: translateX(-50%) rotate(-2deg) scale(1.3); }
  to { opacity: 0.6; transform: translateX(-50%) rotate(-2deg) scale(1); }
}

/* EDA Seal — Hero Overlay */
.eda-seal-hero {
  position: absolute;
  width: 150px;
  height: 150px;
  top: 50%;
  right: -80px;
  transform: translate(0, -20%) rotate(-20deg) scale(1);
  opacity: 0;
  pointer-events: none;
  filter: drop-shadow(0 0 12px rgba(200, 169, 110, 0.15));
  animation: sealStamp 0.5s cubic-bezier(0.22, 0.61, 0.36, 1) 0.8s both;
  z-index: 2;
}

@keyframes sealStamp {
  0%   { opacity: 0; transform: translate(0, -20%) rotate(-20deg) scale(2.2); }
  55%  { opacity: 0.5; transform: translate(0, -20%) rotate(-20deg) scale(0.72); }
  100% { opacity: 0.8; transform: translate(0, -20%) rotate(-20deg) scale(0.8); }
}

/* EDA Seal — Footer Emblem */
.eda-seal-footer {
  display: block;
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  opacity: 0.4;
  filter: grayscale(0.3);
  transition: opacity 0.3s ease, filter 0.3s ease;
}
.eda-seal-footer:hover {
  opacity: 0.6;
  filter: grayscale(0);
}

.hero h1 {
  display: inline-block;
  position: relative;
  margin-bottom: 1.25rem;
  color: var(--text);
  overflow: visible;
}

.hero-heading-group {
  display: inline-block;
  text-align: left;
  margin-bottom: 0.75rem;
}
.hero-heading-group h1 {
  margin-bottom: 0;
}
.hero-tagline {
  font-family: var(--font-mono);
  font-size: clamp(0.48rem, 1.1vw, 0.72rem);
  color: var(--text-secondary);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
  line-height: 1;
}

.h1-scribble {
  position: absolute;
  top: calc(-0.2em + 10px);
  left: 0.600em;
  font-family: 'Caveat', cursive;
  font-weight: 700;
  font-size: 0.38em;
  color: var(--red);
  letter-spacing: 0.02em;
  line-height: 1;
  transform: rotate(-4deg);
  transform-origin: left center;
  opacity: 0.85;
  white-space: nowrap;
}

/* h1-scribble per-language positioning
   top  — vertical offset above h1 baseline
   left — horizontal offset from h1 left edge */
html[lang="de"] .h1-scribble { top: calc(-0.30em + 6px); left: 1.22em; }
html[lang="es"] .h1-scribble { top: calc(-0.32em + 10px); left: 0.80em; font-size: 0.34em; }
html[lang="fr"] .h1-scribble { top: calc(-0.25em + 10px); left: 1em; font-size: 0.30em; }
html[lang="ru"] .h1-scribble { top: calc(-0.15em + 8px); left: 1.95em; }

.hero-motive {
  font-family: 'Instrument Serif', serif;
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.85);
  max-width: 520px;
  margin: 1rem auto 0.75rem;
  line-height: 1.6;
  letter-spacing: 0.01em;
}

.hero-note {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--accent);
  opacity: 0.75;
  margin-top: 0.75em;
  padding-top: 0.55em;
  border-top: 1px solid rgba(200, 169, 110, 0.15);
}

.hero-sub {
  font-size: 0.85rem;
  font-family: var(--font-sans);
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto 1.25rem;
  line-height: 1.7;
  letter-spacing: 0.01em;
}

/* Hero Form */
.hero-form { width: 100%; max-width: 480px; margin: 0 auto 1rem; }

.hero-form .form-row,
.bottom-form .form-row {
  display: flex;
  gap: 0.5rem;
}

.hero-form input[type="email"],
.bottom-form input[type="email"] {
  flex: 1;
  padding: 0.9rem 1.25rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.hero-form input::placeholder,
.bottom-form input::placeholder {
  color: var(--text-muted);
}

.hero-form input:focus,
.bottom-form input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(200, 169, 110, 0.12);
}

/* Hero Meta */
.hero-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.hero-counter { color: var(--text-secondary); }
.hero-meta-sep { opacity: 0.3; }

/* Same typographic treatment as .hero-note inside motive; full-width under optional counter */
.hero-meta > .hero-note {
  flex: 1 0 100%;
  text-align: center;
  margin-top: 0.5rem;
  color: var(--accent);
}

/* Capacity Bar */
.hero-capacity, .urgency-capacity {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.hero-capacity[hidden], .urgency-capacity[hidden] {
  display: none;
}

.capacity-bar {
  width: 100%;
  max-width: 280px;
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}
.capacity-bar-lg {
  max-width: 100%;
  height: 4px;
}
.capacity-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--red));
  border-radius: 2px;
  transition: width 2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.capacity-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

/* Hero Doc Meta */
.hero-doc-meta {
  margin-top: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  opacity: 0.5;
}

/* Success Classification */
.success-class {
  margin-top: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0.7;
}

/* Scroll Hint */
.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  animation: bobDown 2s ease-in-out infinite;
}
@keyframes bobDown {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* ===== SUCCESS STATE ===== */
.registration-success { text-align: center; padding: 0.5rem 0; }

.success-badge {
  display: inline-block;
  padding: 5px 16px;
  border: 2px solid var(--green);
  border-radius: var(--radius-sm);
  color: var(--green);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  transform: rotate(-2deg);
  margin-bottom: 1rem;
  animation: stampPop 0.35s ease-out both;
}

@keyframes stampPop {
  0% { opacity: 0; transform: rotate(-2deg) scale(1.5); }
  60% { opacity: 1; transform: rotate(-2deg) scale(0.95); }
  100% { opacity: 1; transform: rotate(-2deg) scale(1); }
}

.success-headline {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
  color: var(--text);
}
.success-email {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text);
  margin-bottom: 0.25rem;
}
.success-ref { margin-top: 0.25rem; color: var(--text-secondary); font-size: 0.85rem; }
.success-ref code {
  font-family: var(--font-mono);
  background: var(--bg-card);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
}
/* Signal Contributor Mark */
.signal-contributor-mark {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  background: var(--bg-card);
  display: inline-block;
  text-align: center;
}
.signal-role-badge {
  display: inline-block;
  padding: 3px 12px;
  border: 1px solid var(--accent);
  border-radius: var(--radius-sm);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}
.signal-strength {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin: 0;
}
.signal-strength strong {
  color: var(--accent);
  font-size: 1.1rem;
}
.signal-impact {
  margin-top: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-secondary);
}
.signal-impact strong { color: var(--text); }
.queue-position-info {
  margin-top: 0.5rem;
}
.queue-position {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-secondary);
}
.queue-position strong { color: var(--green); }
.signal-hint {
  margin-top: 0.75rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.success-share { margin-top: 1.25rem; }
.share-label-inline {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}
.share-buttons-inline { display: flex; justify-content: center; gap: 0.5rem; }
.btn-share-sm {
  padding: 0.4rem 0.9rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}
.btn-share-sm:hover { color: var(--text); border-color: var(--accent); }
.btn-share-sm.copied { color: var(--green); border-color: var(--green); }

/* ===== COLLECTIVE ASSESSMENT (auxiliary module) ===== */
.aux-module {
  padding: 1.75rem 1.25rem 2.25rem;
  border-top: 1px solid var(--border);
}
.aux-module-shell {
  max-width: 40rem;
  margin: 0 auto;
  border: 1px dashed var(--border);
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.aux-module-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
  border-bottom: 1px solid transparent;
}
.aux-module-header:hover {
  background: rgba(255, 255, 255, 0.02);
}
.aux-module-header:focus {
  outline: none;
}
.aux-module-header:focus-visible {
  outline: 1px solid var(--accent);
  outline-offset: 2px;
}
.aux-module.is-open .aux-module-header {
  border-bottom-color: var(--border);
}
.aux-module-label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  text-align: left;
  min-width: 0;
}
.aux-module-tag {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.aux-module-title {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
}
.aux-module-subtitle {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.aux-module-desc {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  line-height: 1.45;
  letter-spacing: 0.02em;
  max-width: 36em;
}
.aux-module-cta {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: color 0.2s ease, opacity 0.2s ease;
}
.aux-module-header:hover .aux-module-cta {
  opacity: 0.92;
}
.aux-module-cta-arrow {
  display: inline-block;
  transition: transform 0.3s ease;
}
.aux-module.is-open .aux-module-cta-arrow {
  transform: rotate(90deg);
}
.aux-module-body {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.42s ease, opacity 0.32s ease;
}
.aux-module.is-open .aux-module-body {
  max-height: 42rem;
  opacity: 1;
}
.aux-module-inner {
  padding: 1.2rem 1.15rem 1.45rem;
  text-align: center;
}

.aux-module .doom-gauge-prompt {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
  line-height: 1.45;
  margin: 0 auto 1rem;
  max-width: 22rem;
  text-align: center;
}

.aux-module .doom-clock {
  max-width: 260px;
  margin: 0 auto 1.25rem;
}
.doom-gauge { width: 100%; height: auto; }
.doom-gauge-pulse { animation: doomPulse 0.6s ease-out; }
.doom-gauge-pulse-soft { animation: doomPulseSoft 0.15s ease-out; }
@keyframes doomPulse {
  0% { filter: drop-shadow(0 0 0 transparent); }
  50% { filter: drop-shadow(0 0 14px rgba(200, 169, 110, 0.5)); }
  100% { filter: drop-shadow(0 0 0 transparent); }
}
@keyframes doomPulseSoft {
  0% { filter: drop-shadow(0 0 0 transparent); }
  50% { filter: drop-shadow(0 0 7px rgba(200, 169, 110, 0.25)); }
  100% { filter: drop-shadow(0 0 0 transparent); }
}

.doom-needle {
  transform-origin: 100px 100px;
}
.doom-needle line {
  transition: stroke 0.8s ease;
}

.doom-labels {
  display: flex;
  justify-content: space-between;
  margin-top: -0.15rem;
}
.doom-label {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.doom-label-recover { color: var(--green); }
.doom-label-imminent { color: var(--red); }

.doom-stats {
  display: flex;
  justify-content: space-between;
  max-width: 260px;
  margin: 0 auto 1.5rem;
}
.doom-stat {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
}
.doom-stat-recover { color: var(--green); opacity: 0.75; }
.doom-stat-imminent { color: var(--red); opacity: 0.75; }

.doom-buttons {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}
.doom-btn {
  position: relative;
  padding: 0.7rem 1.4rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  background: var(--bg-card);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}
.aux-module .doom-btn:hover {
  color: var(--text);
  transform: none;
}
.aux-module .doom-btn:active { transform: none; }
.doom-btn-recover:hover {
  border-color: var(--green);
  box-shadow: 0 4px 20px rgba(72, 187, 120, 0.15);
}
.doom-btn-imminent:hover {
  border-color: var(--red);
  box-shadow: 0 4px 20px rgba(201, 64, 64, 0.15);
}

.doom-btn-ripple::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  animation: doomRipple 0.5s ease-out forwards;
  pointer-events: none;
}
.doom-btn-recover.doom-btn-ripple::after {
  background: radial-gradient(circle, rgba(72, 187, 120, 0.3), transparent 70%);
}
.doom-btn-imminent.doom-btn-ripple::after {
  background: radial-gradient(circle, rgba(201, 64, 64, 0.3), transparent 70%);
}
@keyframes doomRipple {
  from { opacity: 1; transform: scale(0.5); }
  to { opacity: 0; transform: scale(2.5); }
}

.doom-float {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  pointer-events: none;
  animation: doomFloatUp 0.7s ease-out forwards;
}
.doom-btn-recover .doom-float { color: var(--green); }
.doom-btn-imminent .doom-float { color: var(--red); }
@keyframes doomFloatUp {
  0% { opacity: 1; transform: translate(-50%, -50%) translateY(0); }
  100% { opacity: 0; transform: translate(-50%, -50%) translateY(-40px); }
}

.doom-message {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent);
  margin-top: 1.25rem;
  letter-spacing: 0.02em;
}
.doom-msg-in { animation: doomMsgIn 0.5s ease-out forwards; }
@keyframes doomMsgIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 520px) {
  .aux-module-header { flex-direction: column; align-items: stretch; }
  .aux-module-cta { align-self: flex-end; }
  .doom-buttons { flex-direction: column; align-items: center; }
  .doom-btn { width: 100%; max-width: 280px; }
}

/* ===== OBSERVATIONS CAROUSEL ===== */
.obs-carousel {
  padding: 3rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.obs-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.obs-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;
  user-select: none;
  -webkit-user-select: none;
  touch-action: pan-x;
}
/* Dragging with script: snap + smooth fight direct scrollLeft updates */
.obs-track.is-obs-pointer-down {
  scroll-snap-type: none;
  scroll-behavior: auto;
}
.obs-track::-webkit-scrollbar { display: none; }

.obs-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 0 2rem;
  min-height: 4rem;
}

.obs-slide::before,
.obs-slide::after {
  content: '';
  flex-shrink: 0;
  width: 32px;
  height: 1px;
  background: var(--text-muted);
}

.obs-slide p {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.85;
  letter-spacing: 0.02em;
  color: var(--text-secondary);
  max-width: 520px;
  font-style: italic;
}

.obs-accent {
  color: var(--text);
  font-style: normal;
  font-weight: 500;
}

.obs-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.obs-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border-light);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
}
.obs-dot:hover { background: var(--text-muted); }
.obs-dot.is-active {
  background: var(--accent);
  transform: scale(1.3);
}

/* ===== REGISTRY ACTIVITY LOG ===== */
.registry-log-section {
  padding: 3rem 0 4rem;
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.registry-log-section .section-label {
  margin-bottom: 0.5rem;
}

.registry-log-intro {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

.registry-log-wrap {
  position: relative;
}

.registry-log-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: var(--font-mono);
  font-size: 0.88rem;
  letter-spacing: 0.04em;
}

.registry-log-list li {
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border);
}

.registry-log-list li:last-child {
  border-bottom: none;
  position: relative;
}

.registry-log-list li:last-child::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    rgba(8, 8, 15, 0) 0%,
    rgba(8, 8, 15, 0.35) 40%,
    var(--bg) 100%
  );
}

.registry-log-ref {
  font-family: inherit;
  font-size: inherit;
  letter-spacing: inherit;
  color: var(--text);
  background: none;
  padding: 0;
}

.registry-log-list .registry-log-placeholder {
  color: var(--text-muted);
}

/* ===== SECTIONS ===== */
.section + .section { border-top: 1px solid var(--border); }

/* Steps Grid */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.step-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color 0.2s ease;
}
.step-card:hover { border-color: var(--accent); }

.step-num {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.step-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Benefits Grid */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.benefit-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color 0.2s ease;
}
.benefit-card:hover { border-color: var(--accent); }

.benefit-icon {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.benefit-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Archived Permit */
.archived-permit {
  padding: clamp(2rem, 5vw, 3rem) 0;
  border-top: 1px solid var(--border);
  text-align: center;
  margin: 0;
}
.archived-permit img {
  border: none;
  background: transparent;
}
.archived-permit figcaption {
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.75;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

/* Urgency */
.urgency-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--red);
  border-radius: var(--radius);
  padding: 2.5rem;
}
.urgency-card h2 { margin-bottom: 1.25rem; }
.urgency-lead {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}
.soft-highlight {
  color: var(--accent);
}

.urgency-list {
  list-style: none;
  display: grid;
  gap: 0.6rem;
  margin-bottom: 2rem;
}
.urgency-list li {
  position: relative;
  padding-left: 1.25rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}
.urgency-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--red);
}
.urgency-capacity {
  align-items: flex-start;
}
.urgency-capacity .capacity-bar { max-width: 100%; }

/* ===== DEPARTMENTS ===== */
.dept-status {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1.25rem;
  margin-bottom: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--red);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--text-secondary);
  line-height: 1.6;
}

.dept-status-dot {
  flex-shrink: 0;
  width: 6px;
  height: 6px;
  background: var(--red);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

.dept-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.dept-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color 0.2s ease;
}
.dept-card:hover { border-color: var(--accent); }

.dept-card h3 {
  font-size: 0.95rem;
  font-family: var(--font-sans);
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.dept-card p {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.7;
  letter-spacing: 0.01em;
  color: var(--text-muted);
}

.dept-partial {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.dept-partial-dot {
  flex-shrink: 0;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

.dept-notice {
  margin-top: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.8;
  letter-spacing: 0.02em;
  color: var(--text-secondary);
  opacity: 0.7;
  text-align: center;
  max-width: 580px;
  margin-left: auto;
  margin-right: auto;
}

@media (max-width: 768px) {
  .dept-grid { grid-template-columns: 1fr; }
}

/* FAQ */
.faq-list { max-width: 640px; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item summary {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem 0;
  font-weight: 500; font-size: 0.95rem;
  cursor: pointer; list-style: none;
  transition: color 0.2s ease;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-family: var(--font-mono);
  font-size: 1.1rem;
  color: var(--text-muted);
  flex-shrink: 0;
  margin-left: 1rem;
  transition: color 0.2s;
}
.faq-item[open] summary::after { content: '−'; color: var(--accent); }
.faq-item summary:hover { color: var(--accent); }
.faq-item p {
  padding: 0 0 1rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

@keyframes sectionUnavailableBlink {
  0%, 45% { opacity: 1; }
  50%, 95% { opacity: 0.25; }
  100% { opacity: 1; }
}
.section-unavailable-msg {
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: var(--text-muted);
  animation: sectionUnavailableBlink 1.4s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .section-unavailable-msg { animation: none; opacity: 1; }
}

/* Participant Voices */
.participant-voices {
  padding: clamp(2.5rem, 6vw, 3.5rem) 0 clamp(1.5rem, 4vw, 2rem);
  text-align: center;
}
.voice-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  color: var(--text-secondary);
  line-height: 1.65;
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.voice-quote:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}
.voice-quote p { margin-bottom: 0.4rem; }
.voice-quote cite {
  font-style: normal;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* Bottom CTA */
.section-bottom-cta {
  text-align: center;
  background: var(--bg-alt);
}
.section-bottom-cta h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); }
.bottom-cta-sub {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-size: 1rem;
}
.bottom-form {
  max-width: 480px;
  margin: 0 auto 1rem;
}
.form-consent {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  text-align: center;
}
.bottom-share { margin-top: 2.5rem; text-align: center; }
.share-label-small {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}
.share-buttons {
  display: flex; justify-content: center; gap: 0.6rem; flex-wrap: wrap;
}
.btn-share {
  display: inline-flex; align-items: center; gap: 0.35rem;
  padding: 0.45rem 0.9rem;
  font-size: 0.78rem; font-weight: 500;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}
.btn-share:hover { color: var(--text); border-color: var(--text-secondary); }
.btn-share.copied { color: var(--green); border-color: var(--green); }

/* Footer */
.site-footer {
  padding: 3rem 0 2rem;
  border-top: 1px solid var(--border);
  text-align: center;
}
.footer-org {
  font-family: var(--font-serif);
  font-size: 1rem;
  margin-bottom: 0.2rem;
}
.footer-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}
.footer-slogan {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: var(--accent);
  letter-spacing: 0.02em;
  margin-bottom: 1.25rem;
}
html[lang="ru"] .footer-slogan { font-family: var(--font-serif-cyr); }
.footer-mission {
  max-width: 520px;
  margin: 0 auto 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.8;
  letter-spacing: 0.02em;
  color: var(--text-secondary);
  opacity: 0.75;
}
.disclaimer {
  max-width: 460px;
  margin: 0 auto;
  font-size: 0.62rem;
  color: var(--text-muted);
  line-height: 1.6;
  opacity: 0.45;
  margin-bottom: 1.5rem;
}
.footer-origin {
  max-width: 460px;
  margin: 0 auto 1.5rem;
}
.footer-origin-title {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0.6;
  margin-bottom: 0.4rem;
}
.footer-origin p:last-child {
  font-size: 0.68rem;
  color: var(--text-muted);
  line-height: 1.7;
  opacity: 0.5;
}
.footer-contact {
  font-size: 0.72rem;
  color: var(--text-muted);
  opacity: 0.55;
  margin-bottom: 1.5rem;
}
.footer-contact a {
  color: var(--gold);
  text-decoration: none;
}
.footer-contact a:hover {
  text-decoration: underline;
}
.doc-footer {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  opacity: 0.35;
}

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

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .steps-grid { grid-template-columns: 1fr; gap: 1rem; }
  .benefits-grid { grid-template-columns: 1fr; }
  .urgency-card { padding: 1.5rem; }
}

@media (max-width: 768px) {
  .eda-seal-hero {
    width: 110px;
    height: 110px;
    right: -20px;
  }
}

@media (max-width: 520px) {
  .hero { padding: 1.5rem; }
  .hero h1 { font-size: clamp(2.5rem, 12vw, 3.5rem); }
  html[lang="ru"] .hero h1 { font-size: clamp(2rem, 9vw, 2.8rem); }
  .hero-motive { font-size: 1.1rem; }
  .hero-sub { font-size: 1rem; }
  .hero-lang { top: 0.75rem; right: 1rem; }
  .lang-btn { font-size: 0.58rem; padding: 0.15rem 0.25rem; }

  .eda-seal-hero {
    width: 80px;
    height: 80px;
    right: -10px;
    top: 45%;
  }

  .hero-form .form-row,
  .bottom-form .form-row {
    flex-direction: column;
  }
  .hero-form .btn-submit,
  .bottom-form .btn-submit {
    width: 100%;
  }

  .hero-meta { flex-direction: column; gap: 0.25rem; }
  .hero-meta-sep { display: none; }

  .capacity-bar { max-width: 200px; }

  .sticky-cta-badge { font-size: 0.6rem; }
  .sticky-cta .btn-sm { padding: 0.45rem 0.9rem; font-size: 0.78rem; }
}

/* ===== COOKIE CONSENT ===== */
.cookie-banner {
  position: fixed;
  left: 1.5rem;
  right: 1.5rem;
  bottom: 1.5rem;
  z-index: 9999;
  display: none;
  max-width: 480px;
  margin: 0 auto;
  padding: 1.25rem 1.5rem;
  background: rgba(17, 17, 32, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  animation: cookieIn 0.4s ease-out;
}
.cookie-banner-text {
  margin-bottom: 1rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  line-height: 1.7;
  color: var(--text-secondary);
}
.cookie-banner-actions {
  display: flex;
  gap: 0.75rem;
}
.cookie-banner-accept {
  padding: 0.55rem 1.25rem;
  background: var(--accent);
  color: var(--bg);
  border: none;
  border-radius: var(--radius);
  font-size: 0.8rem;
  font-weight: 700;
  transition: all 0.2s ease;
}
.cookie-banner-accept:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 20px rgba(200, 169, 110, 0.3);
}
.cookie-banner-reject {
  padding: 0.55rem 1.25rem;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  font-size: 0.8rem;
  font-weight: 500;
  transition: all 0.2s ease;
}
.cookie-banner-reject:hover {
  color: var(--text);
  border-color: var(--text-muted);
}
@keyframes cookieIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Referral / queue-benefit content is gated until registration is verified.
   Class is set on <html> by an inline anti-flicker script in each index.html
   (reads eda_reg cookie before render) and by app.js after showAllSuccess. */
html:not(.is-registered) .referral-gated { display: none; }
html:not(.is-registered) .sticky-cta-text-registered { display: none; }
html.is-registered .sticky-cta-text-default { display: none; }

@media print {
  body { background: white; color: black; }
  .hero::before, .sticky-cta, .btn, .share-buttons, .scroll-hint, .cookie-banner { display: none; }
  .hero { min-height: auto; background: white; }
  .reveal { opacity: 1; transform: none; }
}
