/* page-specific styles (set B)
   Small additions for: contact, careers, faqs, 404 and shared empty states.
   Everything else reuses main.css. */

/* ------------------------------ shared */
.empty-note {
  text-align: center;
  color: var(--muted);
  max-width: 34rem;
  margin: 2rem auto 0;
}

/* ------------------------------ contact */
.contact__map { margin-top: 1rem; }
.form-card h2 { font-size: 1.45rem; margin-bottom: .35rem; }
.form-card__sub { color: var(--muted); font-size: .95rem; margin-bottom: 1.4rem; }
.form-foot { margin-top: 1.4rem; display: flex; align-items: center; gap: 1.1rem; flex-wrap: wrap; }
.form-foot .hint { font-size: .82rem; color: var(--muted); margin: 0; flex: 1; min-width: 14rem; }
.form-faq-link {
  margin: 1.5rem 0 0; padding-top: 1.2rem;
  border-top: 1px solid var(--line-cool); font-size: .93rem;
}
.form-faq-link a { font-weight: 600; }
.chan p a { color: var(--navy); }
.chan p a:hover { color: var(--teal-dark); }

/* ------------------------------ careers */
.careers__note {
  text-align: center; color: var(--muted); font-style: italic;
  max-width: 46rem; margin: 2.2rem auto 0;
}

/* ------------------------------ faqs */
.faq-filters { justify-content: center; }
.faq-more { text-align: center; margin: 2rem auto 0; color: var(--muted); max-width: 40rem; }

/* ------------------------------ 404 */
.nf-body { margin: 0; }
.nf {
  position: relative; overflow: hidden;
  min-height: 100svh;
  display: grid; place-items: center;
  padding-block: clamp(3rem, 8vh, 6rem);
  background: linear-gradient(170deg, var(--navy) 0%, var(--navy-deep) 68%, #0D1F3C 100%);
  isolation: isolate;
}
.nf__bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.nf__orb {
  position: absolute; border-radius: 50%; filter: blur(60px); opacity: .5;
  animation: nf-drift 18s ease-in-out infinite alternate;
}
.nf__orb--a {
  width: 34rem; height: 34rem; top: -12rem; right: -8rem;
  background: radial-gradient(circle, rgba(23, 128, 138, .55), transparent 68%);
}
.nf__orb--b {
  width: 30rem; height: 30rem; bottom: -12rem; left: -8rem;
  background: radial-gradient(circle, rgba(161, 203, 209, .38), transparent 68%);
  animation-duration: 24s; animation-delay: -6s;
}
@keyframes nf-drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(2.5rem, 2rem, 0) scale(1.12); }
}

/* The ECG line draws itself across the screen, over and over. */
.nf__ecg { position: absolute; left: 0; right: 0; top: 50%; width: 100%; height: 34vh; transform: translateY(-50%); }
.nf__ecg-line {
  fill: none; stroke: var(--powder); stroke-width: 2.5;
  stroke-linecap: round; stroke-linejoin: round;
  opacity: .55;
  stroke-dasharray: 1600; stroke-dashoffset: 1600;
  animation: nf-trace 6s linear infinite;
  filter: drop-shadow(0 0 10px rgba(161, 203, 209, .55));
}
@keyframes nf-trace {
  0%   { stroke-dashoffset: 1600; }
  70%  { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -1600; }
}


.nf__brand {
  display: inline-flex; align-items: center; gap: .7rem;
  margin-bottom: clamp(1.4rem, 4vh, 2.6rem);
  animation: nf-rise .7s var(--ease) both;
}
.nf__brand img { width: 56px; height: 56px; border-radius: 50%; background: #fff; }
.nf__brand span { display: flex; flex-direction: column; line-height: 1.1; text-align: left; }
.nf__brand strong { font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; color: #fff; }
.nf__brand small {
  font-family: var(--font-display); font-weight: 600; font-size: .58rem;
  letter-spacing: .2em; text-transform: uppercase; color: var(--powder);
}
.nf__inner { position: relative; z-index: 1; text-align: center; max-width: 46rem; }
.nf__code {
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(5rem, 17vw, 11rem); line-height: 1;
  color: #fff; letter-spacing: -.04em; margin-bottom: .35rem;
  display: flex; justify-content: center; gap: .02em;
}
.nf__digit { display: inline-block; animation: nf-rise .7s var(--ease) both; }
.nf__digit:nth-child(1) { animation-delay: .05s; }
.nf__digit:nth-child(2) { animation-delay: .15s; }
.nf__digit:nth-child(3) { animation-delay: .25s; }
.nf__digit--pulse {
  color: var(--powder);
  animation: nf-rise .7s var(--ease) .15s both, nf-beat 2.4s ease-in-out 1s infinite;
}
@keyframes nf-rise { from { opacity: 0; transform: translateY(28px) scale(.9); } to { opacity: 1; transform: none; } }
@keyframes nf-beat {
  0%, 62%, 100% { transform: scale(1); }
  70%  { transform: scale(1.09); }
  78%  { transform: scale(1); }
  86%  { transform: scale(1.05); }
}

.nf__title { color: #fff; animation: nf-rise .7s var(--ease) .32s both; }
.nf__lead {
  color: #CFDBEB; max-width: 34rem; margin-inline: auto;
  animation: nf-rise .7s var(--ease) .4s both;
}
.nf__actions {
  display: flex; gap: .9rem; justify-content: center; flex-wrap: wrap; margin-top: 1.9rem;
  animation: nf-rise .7s var(--ease) .48s both;
}
.nf .btn--outline { border-color: rgba(255, 255, 255, .6); color: #fff; }
.nf .btn--outline:hover { background: #fff; color: var(--navy); }
.nf__links {
  margin-top: 2.6rem; font-size: .92rem;
  display: flex; gap: .5rem 1.1rem; flex-wrap: wrap; justify-content: center;
  animation: nf-rise .7s var(--ease) .56s both;
}
.nf__links span { color: var(--powder); letter-spacing: .1em; text-transform: uppercase; font-size: .74rem; width: 100%; }
.nf__links a { color: #DCE7F5; border-bottom: 1px solid rgba(220, 231, 245, .3); }
.nf__links a:hover { color: #fff; border-bottom-color: #fff; }
.nf__call { margin-top: 2.2rem; font-size: .92rem; color: #A9BAD1; animation: nf-rise .7s var(--ease) .64s both; }
.nf__call a { color: #fff; font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
  .nf__orb, .nf__ecg-line, .nf__digit, .nf__digit--pulse,
  .nf__title, .nf__lead, .nf__actions, .nf__links, .nf__call { animation: none; }
  .nf__ecg-line { stroke-dashoffset: 0; }
  .nf__digit { opacity: 1; transform: none; }
}

/* ============================================================
   Scroll-scrubbed story hero (Stories page only)
   ============================================================ */
.scrub {
  position: relative;
  height: 460vh;              /* scroll runway for the scrub */
  background: var(--ink-surface-deep);
}
.scrub__sticky {
  position: sticky; top: 0;
  height: 100svh; min-height: 32rem;
  overflow: hidden;
  display: grid; place-items: center;
}
.scrub__video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  background: var(--ink-surface-deep) center/cover no-repeat;
}
.scrub__veil {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, rgba(10, 22, 42, .88) 0%, rgba(10, 22, 42, .34) 42%, rgba(10, 22, 42, .30) 100%),
    radial-gradient(120% 80% at 50% 100%, rgba(10, 22, 42, .55), transparent 70%);
}
.scrub__crumb {
  position: absolute; top: calc(76px + 1rem); left: 0; right: 0;
  width: min(1200px, 100% - 2.5rem); margin-inline: auto;
  font-size: .82rem; color: rgba(255, 255, 255, .78); z-index: 3;
}
.scrub__crumb a { color: rgba(255, 255, 255, .88); }
.scrub__crumb a:hover { color: #fff; }
.scrub__crumb span { margin: 0 .45rem; opacity: .6; }

.scrub__beats {
  position: relative; z-index: 2;
  width: min(1200px, 100% - 2.5rem);
  display: grid;
  place-items: end start;
  min-height: 60svh;
  padding-bottom: clamp(2rem, 6vh, 5rem);
}
.scrub__beat {
  grid-area: 1 / 1;
  max-width: 40rem;
  opacity: 0; transform: translateY(22px);
  transition: opacity .55s var(--ease), transform .55s var(--ease);
  pointer-events: none;
}
.scrub__beat.is-on { opacity: 1; transform: none; pointer-events: auto; }
.scrub__eyebrow {
  display: inline-block; font-family: var(--font-display); font-size: .76rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase; color: var(--powder); margin-bottom: .8rem;
}
.scrub__beat h1, .scrub__beat h2 {
  color: #fff; margin-bottom: .45em;
  font-size: clamp(1.9rem, 4.6vw, 3.3rem);
  text-shadow: 0 2px 24px rgba(6, 16, 32, .45);
}
.scrub__beat p {
  color: #E2EAF5; font-size: clamp(1rem, 1.6vw, 1.18rem);
  max-width: 34rem; margin-bottom: 1.2rem;
  text-shadow: 0 1px 12px rgba(6, 16, 32, .5);
}
.scrub__beat .btn { pointer-events: auto; }

.scrub__progress {
  position: absolute; left: 0; right: 0; bottom: 0; height: 3px; z-index: 3;
  background: rgba(255, 255, 255, .16);
}
.scrub__progress span {
  display: block; height: 100%; width: 100%;
  background: linear-gradient(90deg, var(--powder), var(--teal));
  transform: scaleX(0); transform-origin: 0 50%;
}

/* Static fallback: reduced motion, or video unavailable */
.scrub.is-static { height: auto; }
.scrub.is-static .scrub__sticky { position: relative; height: auto; min-height: 82svh; padding-block: 4rem; }
.scrub.is-static .scrub__beat { position: static; opacity: 1; transform: none; pointer-events: auto; }
.scrub.is-static .scrub__beat:not(:first-child) { display: none; }
.scrub.is-static .scrub__progress { display: none; }
.scrub.is-fallback .scrub__video { visibility: hidden; }
.scrub.is-fallback .scrub__sticky {
  background: var(--ink-surface-deep) url('../video/story-poster.jpg') center/cover no-repeat;
}

@media (max-width: 820px) {
  .scrub { height: 400vh; }
  .scrub__beats { place-items: end start; min-height: 66svh; }
  .scrub__beat p { font-size: 1rem; }
}
@media (max-width: 480px) {
  .scrub { height: 360vh; }
  .scrub__crumb { top: calc(76px + .6rem); font-size: .76rem; }
}
/* Short landscape phones: give the words room, shrink the runway */
@media (max-height: 460px) and (orientation: landscape) {
  .scrub { height: 300vh; }
  .scrub__sticky { min-height: 100svh; }
  .scrub__beats { min-height: 0; padding-bottom: 1.5rem; }
  .scrub__beat h1, .scrub__beat h2 { font-size: clamp(1.3rem, 4vw, 1.9rem); margin-bottom: .3em; }
  .scrub__beat p { font-size: .9rem; margin-bottom: .7rem; }
  .scrub__crumb { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .scrub__beat { transition: none; }
}
