/* Remvx — shared page visuals (animated brand scenes, governance cards) */

.page-hero--split {
  padding-bottom: 3rem;
}

.page-hero--split::before {
  opacity: 0.85;
}

.page-hero__grid {
  display: grid;
  gap: 2.5rem;
  align-items: center;
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1.25rem;
}

@media (min-width: 1024px) {
  .page-hero__grid {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 380px);
    gap: 3.5rem;
    padding: 0 1.5rem;
  }

  .page-hero--split.page-hero--center .page-hero__inner {
    text-align: left;
    margin: 0;
    max-width: none;
  }

  .page-hero--split.page-hero--center .page-hero__eyebrow::before {
    display: block;
  }

  .page-hero--split.page-hero--center .page-hero__lead {
    margin-left: 0;
    margin-right: 0;
  }

  .page-hero--split.page-hero--center .page-hero__meta {
    justify-content: flex-start;
  }
}

.page-hero__visual {
  position: relative;
  min-height: 280px;
  border-radius: 1.25rem;
  border: 1px solid rgba(239, 68, 68, 0.18);
  background: linear-gradient(165deg, #0c0c0c 0%, #050505 100%);
  overflow: hidden;
  box-shadow:
    0 24px 80px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.page-hero__visual .login-scene {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-hero__visual .infra-svg,
.page-hero__visual--infra .infra-svg {
  width: 100%;
  max-width: 360px;
  height: auto;
}

.page-hero__visual--infra {
  display: grid;
  place-items: center;
  min-height: 280px;
}

/* Animated brand mark — product / default page heroes */
.page-hero__visual--brand {
  display: grid;
  place-items: center;
  min-height: 300px;
  padding: 1.5rem;
}

.hero-brand-scene {
  position: relative;
  width: min(100%, 280px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}

.hero-brand-scene__grid {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 18px 18px;
  mask-image: radial-gradient(circle at center, #000 35%, transparent 72%);
  -webkit-mask-image: radial-gradient(circle at center, #000 35%, transparent 72%);
  opacity: 0.65;
}

.hero-brand-scene__glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(42px);
  pointer-events: none;
}

.hero-brand-scene__glow--red {
  width: 55%;
  height: 55%;
  background: rgba(239, 68, 68, 0.22);
  animation: hero-brand-glow-pulse 4s ease-in-out infinite;
}

.hero-brand-scene__glow--blue {
  width: 38%;
  height: 38%;
  background: rgba(59, 130, 246, 0.14);
  animation: hero-brand-glow-pulse 4s ease-in-out infinite 1.2s;
}

@keyframes hero-brand-glow-pulse {
  0%, 100% { opacity: 0.55; transform: scale(0.92); }
  50% { opacity: 1; transform: scale(1.08); }
}

.hero-brand-scene__orbit {
  position: absolute;
  width: 100%;
  height: 100%;
}

.hero-brand-scene__orbit--outer {
  animation: hero-brand-orbit-spin 22s linear infinite;
}

.hero-brand-scene__orbit--inner {
  width: 82%;
  height: 82%;
  animation: hero-brand-orbit-spin 14s linear infinite reverse;
}

@keyframes hero-brand-orbit-spin {
  to { transform: rotate(360deg); }
}

.hero-brand-scene__orbit-dot {
  filter: drop-shadow(0 0 6px rgba(239, 68, 68, 0.85));
}

.hero-brand-scene__orbit-dot--blue {
  filter: drop-shadow(0 0 6px rgba(59, 130, 246, 0.85));
}

.hero-brand-scene__core {
  position: relative;
  z-index: 2;
  width: 46%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 1.15rem;
  background: linear-gradient(155deg, #121212 0%, #060606 100%);
  border: 1px solid rgba(239, 68, 68, 0.38);
  box-shadow:
    0 0 48px rgba(239, 68, 68, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  animation: hero-brand-core-breathe 3.5s ease-in-out infinite;
}

@keyframes hero-brand-core-breathe {
  0%, 100% { transform: scale(1); box-shadow: 0 0 48px rgba(239, 68, 68, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.05); }
  50% { transform: scale(1.03); box-shadow: 0 0 64px rgba(239, 68, 68, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.07); }
}

.hero-brand-scene__logo {
  width: 72%;
  height: 72%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-brand-scene__logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transform: scale(0.9);
}

.page-hero__visual.is-visible .hero-brand-scene__logo img {
  animation: hero-brand-logo-in 0.85s cubic-bezier(0.34, 1.15, 0.64, 1) 0.1s forwards,
    hero-brand-logo-glow 3.2s ease-in-out 1.1s infinite;
}

@keyframes hero-brand-logo-in {
  to { opacity: 1; transform: scale(1); }
}

@keyframes hero-brand-logo-glow {
  0%, 100% { filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.06)); }
  50% { filter: drop-shadow(0 0 18px rgba(239, 68, 68, 0.22)); }
}

.hero-brand-scene__scan {
  position: absolute;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(239, 68, 68, 0.5), transparent);
  opacity: 0;
  pointer-events: none;
}

.page-hero__visual.is-visible .hero-brand-scene__scan {
  animation: hero-brand-scan 3.2s ease-in-out 1.8s infinite;
}

@keyframes hero-brand-scan {
  0% { top: 28%; opacity: 0; }
  15% { opacity: 0.7; }
  85% { opacity: 0.35; }
  100% { top: 72%; opacity: 0; }
}

/* Animated brand ring (section accents) */
.page-brand-ring {
  position: relative;
  width: 7.5rem;
  height: 7.5rem;
  margin: 0 auto 1.5rem;
  flex-shrink: 0;
}

.page-brand-ring__svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: page-ring-spin 24s linear infinite;
}

.page-brand-ring__svg--reverse {
  animation-direction: reverse;
  animation-duration: 18s;
}

@keyframes page-ring-spin {
  to { transform: rotate(360deg); }
}

.page-brand-ring__core {
  position: absolute;
  inset: 18%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 1rem;
  background: linear-gradient(145deg, #141414, #080808);
  border: 1px solid rgba(239, 68, 68, 0.35);
  box-shadow: 0 0 32px rgba(239, 68, 68, 0.15);
}

.page-brand-ring__core img {
  width: 62%;
  height: 62%;
  object-fit: contain;
}

/* Legal / prose page animated header */
.page-strip-hero {
  display: grid;
  gap: 2rem;
  align-items: center;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border, #222);
}

@media (min-width: 768px) {
  .page-strip-hero {
    grid-template-columns: auto 1fr;
    gap: 2.5rem;
  }
}

.page-strip-hero__copy h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  margin: 0;
}

.page-strip-hero__copy p {
  margin: 0.75rem 0 0;
  color: #a1a1aa;
  font-size: 1rem;
  line-height: 1.6;
  max-width: 36rem;
}

/* Trust & governance feature cards */
.gov-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 768px) {
  .gov-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem;
  }
}

.gov-card {
  position: relative;
  padding: 1.75rem 1.5rem 1.5rem;
  border-radius: 1rem;
  border: 1px solid rgba(239, 68, 68, 0.15);
  background:
    radial-gradient(ellipse 100% 80% at 50% 0%, rgba(239, 68, 68, 0.08), transparent 60%),
    linear-gradient(165deg, #0d0d0d 0%, #080808 100%);
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
  overflow: hidden;
}

.gov-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/remvx-mark.svg") 92% 8% / 3.5rem no-repeat;
  opacity: 0.04;
  pointer-events: none;
}

.gov-card:hover {
  border-color: rgba(239, 68, 68, 0.35);
  transform: translateY(-3px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45), 0 0 40px rgba(239, 68, 68, 0.08);
}

.gov-card__visual {
  position: relative;
  width: 4.25rem;
  height: 4.25rem;
  margin-bottom: 1.25rem;
}

.gov-card__ring {
  position: absolute;
  inset: -6px;
  border-radius: 1.1rem;
  border: 1px dashed rgba(239, 68, 68, 0.35);
  animation: gov-ring-pulse 3s ease-in-out infinite;
}

.gov-card__ring--fast {
  animation-duration: 2s;
}

.gov-card:nth-child(2) .gov-card__ring {
  animation-delay: 0.4s;
}

.gov-card:nth-child(3) .gov-card__ring {
  animation-delay: 0.8s;
}

@keyframes gov-ring-pulse {
  0%, 100% { transform: scale(1); opacity: 0.55; }
  50% { transform: scale(1.08); opacity: 1; }
}

.gov-card__icon {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.9rem;
  background: linear-gradient(145deg, rgba(239, 68, 68, 0.18) 0%, rgba(10, 10, 10, 0.95) 100%);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  box-shadow: 0 8px 28px rgba(239, 68, 68, 0.12);
}

.gov-card__icon svg,
.gov-card__icon i {
  width: 1.65rem;
  height: 1.65rem;
  stroke-width: 2;
}

.gov-card__icon--encrypt { color: #93c5fd; border-color: rgba(59, 130, 246, 0.4); background: linear-gradient(145deg, rgba(59, 130, 246, 0.15), rgba(10, 10, 10, 0.95)); }
.gov-card__icon--audit { color: #fcd34d; border-color: rgba(245, 158, 11, 0.4); background: linear-gradient(145deg, rgba(245, 158, 11, 0.12), rgba(10, 10, 10, 0.95)); }
.gov-card__icon--access { color: #86efac; border-color: rgba(34, 197, 94, 0.4); background: linear-gradient(145deg, rgba(34, 197, 94, 0.12), rgba(10, 10, 10, 0.95)); }

.gov-card__title {
  font-size: 1.0625rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
}

.gov-card__body {
  font-size: 0.875rem;
  line-height: 1.65;
  color: #a1a1aa;
  margin: 0;
}

/* Docs — fix mobile sidebar overlap */
@media (max-width: 1023px) {
  .docs-layout {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding-top: 1.5rem;
  }

  .docs-nav {
    position: static;
    top: auto;
    display: flex;
    flex-wrap: nowrap;
    gap: 0.35rem;
    overflow-x: auto;
    padding: 0.75rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    z-index: 1;
  }

  .docs-nav::-webkit-scrollbar {
    display: none;
  }

  .docs-nav__group {
    display: contents;
  }

  .docs-nav__heading {
    display: none;
  }

  .docs-nav a {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 0.45rem 0.85rem;
    border: 1px solid var(--border, #222);
    border-radius: 999px;
    font-size: 0.75rem;
    background: #0a0a0a;
  }

  .docs-nav a.is-active {
    background: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.35);
  }

  .docs-layout > main {
    min-width: 0;
    width: 100%;
  }
}

.doc-block {
  position: relative;
}

.doc-block__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.5rem;
  margin-bottom: 0.75rem;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #f87171;
}

.doc-block__icon svg,
.doc-block__icon i {
  width: 1.1rem;
  height: 1.1rem;
}

.doc-block h2 {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

/* Trust center hero enhancement */
.trust-hero-visual {
  margin-bottom: 3rem;
}

.trust-hero-logo {
  display: flex;
  justify-content: center;
  margin: 0 auto 1.5rem;
}

.trust-hero-logo__img {
  width: min(100%, 11rem);
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 18px rgba(255, 255, 255, 0.12));
}

@media (min-width: 640px) {
  .trust-hero-logo__img {
    width: min(100%, 13rem);
  }
}

.trust-hero-visual .page-brand-ring {
  margin-bottom: 2rem;
}

.trust-hero-visual h1 {
  margin-top: 0;
}

.page-animate,
.page-animate.is-visible {
  opacity: 1;
  transform: none;
  transition: none;
}

@media (prefers-reduced-motion: reduce) {
  .page-brand-ring__svg,
  .gov-card__ring,
  .page-animate,
  .hero-brand-scene__orbit,
  .hero-brand-scene__glow,
  .hero-brand-scene__core,
  .hero-brand-scene__scan,
  .hero-brand-scene__logo img {
    animation: none !important;
    transition: none !important;
  }

  .page-animate {
    opacity: 1;
    transform: none;
  }

  .hero-brand-scene__logo img {
    opacity: 1;
    transform: none;
  }
}
