/* ============================================================
   CristaCore — cinematic layer (preloader, hero scroll, nav)
   Palette: navy / teal / black — no red
   ============================================================ */

:root {
  --black: #050a10;
  --gray-dark: #0a1520;
  --gray-mid: #dce8f2;
  --gray-section: #e8f0f6;
  --cinema-h: 100vh;
  --cinema-h-mobile: 100svh;
}

body.is-loading {
  overflow: hidden;
}

/* —— Hero sequence: vídeo → título → menu —— */
.hero-sequence {
  position: relative;
  height: 100svh;
  min-height: 100vh;
  background: var(--black);
}

.hero-sequence__stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.hero-sequence__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1s ease;
}

.hero-sequence.is-video-ready .hero-sequence__video {
  opacity: 1;
}

.hero-sequence__shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 10, 16, 0.45) 0%, transparent 35%, transparent 55%, rgba(5, 10, 16, 0.88) 100%);
  pointer-events: none;
  z-index: 1;
}

.hero-sequence__loader {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  width: min(200px, 50vw);
  height: 2px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 2px;
  overflow: hidden;
  z-index: 3;
  transition: opacity 0.4s ease;
}

.hero-sequence.is-video-ready .hero-sequence__loader {
  opacity: 0;
  pointer-events: none;
}

.hero-sequence__loader-bar {
  display: block;
  height: 100%;
  width: 30%;
  background: var(--teal-light);
  border-radius: 2px;
  animation: hero-loader-pulse 1.2s ease-in-out infinite;
}

@keyframes hero-loader-pulse {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(400%); }
}

.hero-sequence__brand {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 1.5rem;
  text-align: center;
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.hero-sequence.is-title-ready .hero-sequence__brand {
  opacity: 1;
  transform: translateY(0);
}

.hero-sequence__title {
  margin: 0;
  line-height: 0;
}

.hero-logo-reveal {
  display: inline-block;
  position: relative;
  overflow: hidden;
}

.hero-logo {
  display: block;
  width: min(94vw, 720px);
  height: auto;
  max-height: none;
  object-fit: contain;
  clip-path: inset(50% 50% 50% 50%);
  opacity: 0.35;
  transform: scale(0.94);
  filter: drop-shadow(0 10px 40px rgba(0, 0, 0, 0.55));
  transition:
    clip-path 1.4s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 1s ease,
    transform 1.4s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: clip-path, opacity, transform;
}

.hero-sequence.is-title-ready .hero-logo {
  clip-path: inset(0 0 0 0);
  opacity: 1;
  transform: scale(1);
}

.hero-logo-reveal::after {
  content: '';
  position: absolute;
  inset: -8% -15%;
  background: linear-gradient(
    105deg,
    transparent 38%,
    rgba(255, 255, 255, 0.28) 50%,
    transparent 62%
  );
  transform: translateX(-130%) skewX(-10deg);
  opacity: 0;
  pointer-events: none;
}

.hero-sequence.is-title-ready .hero-logo-reveal::after {
  animation: hero-logo-shine 1.15s ease 0.9s forwards;
}

@keyframes hero-logo-shine {
  0% {
    opacity: 0;
    transform: translateX(-130%) skewX(-10deg);
  }
  18% { opacity: 1; }
  100% {
    opacity: 0;
    transform: translateX(130%) skewX(-10deg);
  }
}

.brand-wordmark-font {
  font-family: 'Montserrat', var(--font-display), sans-serif;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.brand-crista {
  color: var(--brand-crista, #0a4a6e);
}

.brand-core {
  color: var(--brand-core, #2a9d8f);
}

.hero-sequence__subtitle {
  margin-top: 1.35rem;
  max-width: 22rem;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.85s ease 0.1s, transform 0.85s cubic-bezier(0.22, 1, 0.36, 1) 0.1s;
}

.hero-sequence.is-subtitle-ready .hero-sequence__subtitle {
  opacity: 1;
  transform: translateY(0);
}

.hero-sequence__eyebrow {
  margin: 0 0 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--teal-light);
}

.hero-sequence__tagline {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1rem, 3.8vw, 1.45rem);
  font-weight: 600;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.92);
}

.hero-sequence__highlight {
  color: var(--teal-light);
}

.hero-sequence__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

body.hero-ready .hero-sequence__scroll {
  bottom: calc(3.75rem + 52px);
}

.hero-sequence.is-scroll-ready .hero-sequence__scroll {
  opacity: 1;
  pointer-events: auto;
  animation: hero-scroll-bounce 2s ease-in-out infinite;
}

.hero-sequence__scroll svg {
  width: 18px;
  height: 18px;
  stroke: var(--teal-light);
}

@keyframes hero-scroll-bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* Conteúdo abaixo do hero só entra no fluxo após a sequência */
body.is-loading .site-main > :not(#cinema-hero) {
  visibility: hidden;
}

/* —— Progress rail —— */
#progress-rail {
  position: fixed;
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

#progress-rail.is-visible {
  opacity: 1;
}

.progress-rail__label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  min-height: 5rem;
  transition: color 0.3s;
}

.progress-rail__track {
  width: 2px;
  height: 120px;
  background: rgba(13, 33, 55, 0.15);
  border-radius: 2px;
  position: relative;
  overflow: hidden;
}

.progress-rail__fill {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 0%;
  background: linear-gradient(180deg, var(--teal-light), var(--teal));
  border-radius: 2px;
  transition: height 0.15s ease-out;
}


/* —— Intro (conteúdo após o hero) —— */
.intro-section {
  background: var(--gray-dark);
  color: var(--white);
  padding-block: clamp(4rem, 8vh, 6rem);
  border-bottom: 1px solid rgba(63, 196, 180, 0.12);
}

.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.intro-grid h2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1rem;
}

.intro-grid .highlight {
  color: var(--teal-light);
}

.intro-stats {
  display: flex;
  gap: 2rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.intro-stats .stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.75rem;
  color: var(--teal-light);
}

.intro-stats .stat span {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.55);
}

/* —— Sticky nav band —— */
#sticky-band {
  position: relative;
  z-index: 80;
  background: var(--black);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: box-shadow 0.3s, opacity 0.6s ease, transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  opacity: 0;
  transform: translateY(100%);
  pointer-events: none;
}

#sticky-band.is-nav-ready {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

#sticky-band.is-hero-bottom {
  position: fixed;
  bottom: 0;
  top: auto;
  left: 0;
  right: 0;
}

#sticky-band.is-fixed {
  position: fixed;
  top: 0;
  bottom: auto;
  left: 0;
  right: 0;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

.sticky-band__inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.85rem 1.5rem;
  max-width: var(--container);
  margin-inline: auto;
}

.sticky-band__nav {
  display: flex;
  gap: 1.5rem;
  flex: 1;
  flex-wrap: wrap;
}

.sticky-band__nav a {
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  transition: color 0.2s;
  white-space: nowrap;
}

.sticky-band__nav a:hover,
.sticky-band__nav a.is-active {
  color: var(--white);
}

.sticky-band__nav a.is-active {
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: var(--teal-light);
}

.sticky-band__spacer {
  height: 52px;
  display: none;
}

#sticky-band.is-fixed + .sticky-band__spacer {
  display: block;
}

/* —— Journey Microsoft accordion —— */
.journey-ms {
  margin-top: 1rem;
}

.journey-ms__stage {
  position: relative;
  background: var(--gray-dark);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 420px;
}

.journey-dots {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.journey-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(63, 196, 180, 0.25);
  transition: transform 0.3s, background 0.3s;
}

.journey-dot.is-accent {
  background: var(--teal-light);
  box-shadow: 0 0 12px rgba(63, 196, 180, 0.5);
}

.journey-ms__photo-wrap {
  position: absolute;
  right: 8%;
  top: 50%;
  transform: translateY(-50%);
  width: min(280px, 35%);
  aspect-ratio: 3/4;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 2;
  transition: opacity 0.4s ease;
}

.journey-ms__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: grayscale(15%) contrast(1.05);
}

.journey-ms__accordion {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  z-index: 3;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.journey-acc {
  background: rgba(10, 21, 32, 0.92);
  border: none;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  padding: 1.25rem 1rem 1rem;
  text-align: left;
  cursor: pointer;
  color: var(--white);
  font-family: var(--font-body);
  transition: background 0.3s, flex 0.3s;
  min-height: 88px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.5rem;
}

.journey-acc:last-child {
  border-right: none;
}

.journey-acc:hover {
  background: rgba(22, 51, 82, 0.85);
}

.journey-acc.is-open {
  background: rgba(13, 33, 55, 0.98);
  min-height: 140px;
}

.journey-acc__toggle {
  width: 22px;
  height: 22px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: var(--white);
  color: var(--navy);
  font-size: 1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.journey-acc__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1.3;
}

.journey-acc__summary {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.5;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.35s ease, opacity 0.35s ease, margin 0.35s;
}

.journey-acc.is-open .journey-acc__summary {
  max-height: 80px;
  opacity: 1;
  margin-top: 0.25rem;
}

.journey-ms__detail {
  margin-top: 2rem;
}

.journey-ms__detail .journey-stage {
  background: var(--white);
}

/* —— Como funciona: trilha de etapas —— */
.method-intro {
  color: var(--muted);
  line-height: 1.75;
  max-width: 40rem;
  margin: 0 auto 2.5rem;
  text-align: center;
}

.method-track {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.method-step {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.35rem 1.25rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
}

.method-step:hover {
  border-color: rgba(42, 157, 143, 0.35);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.method-step.is-lit {
  border-color: var(--teal);
  box-shadow: 0 8px 28px rgba(42, 157, 143, 0.15);
}

.method-step__num {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--navy) 0%, #163352 100%);
  color: var(--teal-light);
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.04em;
}

.method-step__title {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
}

.method-step__desc {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.55;
  color: var(--muted);
}

/* —— Executive insight —— */
.insight-section {
  padding-block: clamp(4rem, 10vh, 7rem);
  background: var(--gray-section);
  text-align: center;
}

.insight-quote {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 3vw, 2rem);
  font-weight: 600;
  line-height: 1.5;
  color: var(--navy);
  max-width: 48rem;
  margin: 0 auto 1.5rem;
}

.insight-sign {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
}

/* —— Darker sections override —— */
.section--alt {
  background: var(--gray-section) !important;
}

.section--darker {
  background: #d4e2ed !important;
}

/* —— Responsive —— */
@media (max-width: 900px) {
  #progress-rail { display: none; }

  .intro-grid,
  .method-track {
    grid-template-columns: 1fr;
  }

  .hero-sequence__title {
    max-width: 96vw;
  }

  .hero-logo {
    width: min(94vw, 620px);
    max-height: none;
  }

  .hero-sequence__tagline {
    font-size: clamp(0.95rem, 4vw, 1.2rem);
  }

  .hero-sequence__scroll {
    bottom: 5rem;
  }

  /* Jornada — tablet/mobile: coluna, foto no topo, sem bolinhas/fantasma */
  .journey-ms__stage {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
  }

  .journey-dots {
    display: none !important;
  }

  .journey-ms__photo-wrap {
    position: relative;
    right: auto;
    top: auto;
    transform: none;
    width: 100%;
    max-width: none;
    aspect-ratio: 16 / 9;
    max-height: 200px;
    opacity: 1;
    flex-shrink: 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    z-index: 1;
  }

  .journey-ms__photo {
    filter: none;
  }

  .journey-ms__accordion {
    position: relative;
    bottom: auto;
    left: auto;
    right: auto;
    display: flex;
    flex-direction: column;
    grid-template-columns: unset;
    border-top: none;
    z-index: 2;
  }

  .journey-acc {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 0.65rem 0.75rem;
    min-height: 0;
    padding: 0.85rem 1rem;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    background: var(--gray-dark);
  }

  .journey-acc:last-child {
    border-bottom: none;
  }

  .journey-acc:hover {
    background: #0f1e2c;
  }

  .journey-acc.is-open {
    min-height: 0;
    padding-bottom: 1rem;
    align-items: flex-start;
    flex-direction: row;
    flex-wrap: wrap;
    background: #0d2137;
  }

  .journey-acc__toggle {
    order: -1;
    flex-shrink: 0;
  }

  .journey-acc__title {
    flex: 1;
    font-size: 0.9rem;
    line-height: 1.35;
    min-width: 0;
  }

  .journey-acc__summary {
    width: 100%;
    flex-basis: 100%;
    max-height: none;
    opacity: 1;
    margin-top: 0;
    padding-left: calc(22px + 0.75rem);
    font-size: 0.8rem;
    line-height: 1.55;
  }

  .journey-acc:not(.is-open) .journey-acc__summary {
    display: none;
  }

  .journey-ms__detail {
    margin-top: 1.25rem;
  }

  .journey-ms__detail .journey-stage {
    padding: 1.25rem 1rem;
  }
}

@media (max-width: 640px) {
  .journey-ms__photo-wrap {
    max-height: 180px;
    aspect-ratio: 16 / 10;
  }

  .journey-acc {
    padding: 0.75rem 0.85rem;
  }

  .journey-acc__title {
    font-size: 0.84rem;
  }

  .journey-acc__summary {
    font-size: 0.78rem;
    padding-left: calc(22px + 0.65rem);
  }

  .sticky-band__nav { display: none; }
  .sticky-band__inner .menu-button { display: flex; margin-left: auto; }

  .hero-logo {
    width: min(96vw, 520px);
    max-height: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-sequence__video,
  .hero-sequence__scroll,
  #sticky-band {
    transition: none;
  }

  .hero-logo {
    clip-path: inset(0 0 0 0);
    opacity: 1;
    transform: none;
    transition: none;
  }

  .hero-logo-reveal::after {
    animation: none;
  }

  .hero-sequence.is-title-ready .hero-sequence__brand,
  .hero-sequence.is-subtitle-ready .hero-sequence__subtitle {
    opacity: 1;
    transform: none;
  }

  .hero-sequence__scroll {
    animation: none;
  }

  .hero-sequence__loader {
    display: none;
  }
}

/* —— Mobile sticky nav + intro cards —— */
.menu-button--dark span {
  background: var(--white);
}

@media (max-width: 640px) {
  .sticky-band__nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--black);
    padding: 1rem 1.5rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    gap: 0.75rem;
  }

  .sticky-band__nav.is-open {
    display: flex;
  }

  #sticky-band { position: relative; }
  #sticky-band.is-fixed { position: fixed; }
}

.intro-section .mock-card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
}

.intro-section .mock-title { color: var(--white); }
.intro-section .mock-sub { color: rgba(255, 255, 255, 0.55); }

.journey-ms__photo { transition: opacity 0.35s ease; }
