/* Logos - dynamically generated elements */
.logos_logo {
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  width: 100%;
  height: 100%;
  transition: transform 0.5s ease-in-out;
  position: absolute;
  top: 0;
  left: 0;
}

.logos_item {
  position: relative;
}

/* Language selector popup - hidden by default, shown via JS */
.section_popup {
  display: none;
}

/* Close button inside Radix Dialog uses <button> instead of <a>;
   reset browser defaults so it matches the original anchor styling. */
button.popup_close {
  appearance: none;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

/* ── Dialog open/close animations (shadcn standard) ─────────────── */

@keyframes shadcn-enter {
  from {
    opacity: var(--shadcn-enter-opacity, 1);
    transform: scale(var(--shadcn-enter-scale, 1));
  }
}

@keyframes shadcn-exit {
  to {
    opacity: var(--shadcn-exit-opacity, 1);
    transform: scale(var(--shadcn-exit-scale, 1));
  }
}

.popup_bg[data-state="open"] {
  --shadcn-enter-opacity: 0;
  animation: shadcn-enter 200ms ease-out;
}

.popup_bg[data-state="closed"] {
  --shadcn-exit-opacity: 0;
  animation: shadcn-exit 200ms ease-out forwards;
}

.popup_component[data-state="open"] {
  --shadcn-enter-opacity: 0;
  --shadcn-enter-scale: 0.95;
  animation: shadcn-enter 200ms ease-out;
}

.popup_component[data-state="closed"] {
  --shadcn-exit-opacity: 0;
  --shadcn-exit-scale: 0.95;
  animation: shadcn-exit 200ms ease-out forwards;
}

/* Plus-to-minus animation for FAQ */
.faq_dropdown .faq_dropdown_line.rotate {
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
}

.faq_dropdown.w--open .faq_dropdown_line.rotate {
  transform: rotate(90deg);
  opacity: 0;
}

/* Keep the sticky animated text from showing through the AI features section. */
.section_features_column {
  background-color: var(--neutral--100);
}

/* Fix noscript GTM iframe */
noscript iframe {
  display: none !important;
}

/* Shared inner content frame for marketing pages.
   Pages can override the max width locally via the CSS variable. */
:root {
  --rally-page-content-max-width: 78rem;
}

.page-content-frame {
  width: 100%;
  max-width: var(--rally-page-content-max-width);
  margin-left: auto;
  margin-right: auto;
}

/* Blog listing — Webflow uses 7rem vertical padding here; tighten for a shorter hero. */
.blog_heading_component {
  padding-top: 3rem;
  padding-bottom: 2rem;
}

@media screen and (max-width: 767px) {
  .blog_heading_component {
    padding-top: 1.5rem;
    padding-bottom: 2rem;
  }
}

/* ── 404 Not Found Page ── */
.not-found-page {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background-color: #fafbff;
}

.not-found-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.not-found-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(26, 43, 195, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(26, 43, 195, 0.03) 1px, transparent 1px);
  background-size: 4rem 4rem;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 80%);
}

.not-found-glow {
  position: absolute;
  top: -10%;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 500px;
  background: radial-gradient(50% 50% at 50% 50%, rgba(26, 43, 195, 0.06) 0%, transparent 100%);
  filter: blur(40px);
}

/* Header — reuses .nav_component / .nav_logo_wrapper from Webflow;
   only override positioning so navbar sits in flow instead of fixed. */
.not-found-header {
  position: relative;
  z-index: 2;
  padding-top: 2.5rem;
}

.not-found-header .nav_component {
  height: auto;
}

.not-found-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(26, 43, 195, 0.12);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #2b313b;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1;
}

.not-found-back-btn:hover {
  background: #fff;
  border-color: rgba(26, 43, 195, 0.24);
  box-shadow: 0 1px 3px rgba(26, 43, 195, 0.08);
}

/* Main content */
.not-found-main {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem 0 4rem;
}

.not-found-content {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
}

/* Hero */
.not-found-hero {
  text-align: center;
  margin-bottom: 3rem;
}

.not-found-code {
  font-size: clamp(6rem, 15vw, 10rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(180deg, rgba(26, 43, 195, 0.16) 0%, rgba(26, 43, 195, 0.04) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  margin: 0 0 0.25rem;
  user-select: none;
  animation: not-found-fade-in 0.6s ease both;
}

.not-found-title {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 700;
  color: #0d0f1a;
  margin: 0 0 0.75rem;
  line-height: 1.2;
  animation: not-found-fade-up 0.6s ease 0.1s both;
}

.not-found-description {
  font-size: 1.0625rem;
  line-height: 1.65;
  color: #555d6e;
  margin: 0 auto 2rem;
  max-width: 480px;
  animation: not-found-fade-up 0.6s ease 0.2s both;
}

.not-found-actions {
  animation: not-found-fade-up 0.6s ease 0.3s both;
}

.not-found-cta {
  gap: 0.5rem;
}

.not-found-cta svg {
  flex-shrink: 0;
}

/* Suggested links */
.not-found-links-section {
  animation: not-found-fade-up 0.6s ease 0.4s both;
}

.not-found-links-heading {
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #9aa4b1;
  margin: 0 0 1rem;
  text-align: center;
}

.not-found-links-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.not-found-link-card {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 1rem 1.125rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(26, 43, 195, 0.08);
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  text-decoration: none;
  transition: all 0.25s ease;
  color: inherit;
}

.not-found-link-card:hover {
  background: #fff;
  border-color: rgba(26, 43, 195, 0.18);
  box-shadow:
    0 4px 16px rgba(26, 43, 195, 0.06),
    0 1px 3px rgba(0, 0, 0, 0.04);
  transform: translateY(-1px);
}

.not-found-link-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.5rem;
  flex-shrink: 0;
  background: rgba(26, 43, 195, 0.06);
  color: #1a2bc3;
  transition: all 0.25s ease;
}

.not-found-link-card:hover .not-found-link-icon {
  background: rgba(26, 43, 195, 0.1);
}

.not-found-link-text {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
  min-width: 0;
  flex: 1;
}

.not-found-link-label {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #0d0f1a;
  line-height: 1.3;
}

.not-found-link-description {
  font-size: 0.8125rem;
  color: #7a8291;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.not-found-link-arrow {
  flex-shrink: 0;
  color: #9aa4b1;
  transition: all 0.25s ease;
}

.not-found-link-card:hover .not-found-link-arrow {
  color: #1a2bc3;
  transform: translateX(2px);
}

/* Animations */
@keyframes not-found-fade-in {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes not-found-fade-up {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile responsive */
@media screen and (max-width: 767px) {
  .not-found-links-grid {
    grid-template-columns: 1fr;
  }

  .not-found-main {
    padding: 1rem 0 3rem;
  }

  .not-found-hero {
    margin-bottom: 2.5rem;
  }
}

@media screen and (max-width: 479px) {
  .not-found-code {
    font-size: 5rem;
  }

  .not-found-link-description {
    display: none;
  }

  .not-found-header {
    padding: 1rem 0;
  }
}
