/* SavilTech — Quem Somos / Nossa História: amarelo #FFD60A */

.page-quem-somos {
  --gold: #ffd60a;
  --gold-light: #ffeb3b;
  --gold-dark: #e6b800;
}

.page-quem-somos .text-gold {
  color: #ffd60a !important;
  text-shadow: 0 0 32px rgba(255, 214, 10, 0.35);
}

/* —— Banner: largura total + animação Ken Burns —— */
.page-quem-somos .qs-banner--fullwidth {
  position: relative;
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  min-height: clamp(300px, 48vh, 520px) !important;
  display: block !important;
  overflow: hidden;
  background: #000;
}

.page-quem-somos .qs-banner--premium .qs-banner__media {
  position: absolute !important;
  inset: 0 !important;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
}

.page-quem-somos .qs-banner--premium .qs-banner__img {
  width: 100% !important;
  height: 100% !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center center;
  transform: scale(1.08);
  will-change: transform;
  animation:
    qsBannerReveal 1.4s cubic-bezier(0.22, 1, 0.36, 1) forwards,
    qsBannerKenBurns 22s ease-in-out 1.4s infinite alternate;
}

.page-quem-somos .qs-banner--premium:hover .qs-banner__img {
  animation-play-state: paused;
  filter: saturate(1.1) brightness(1.05);
}

@keyframes qsBannerReveal {
  0% {
    opacity: 0;
    transform: scale(1.18);
    filter: brightness(0.55) saturate(0.9);
  }
  100% {
    opacity: 1;
    transform: scale(1.08);
    filter: brightness(1) saturate(1);
  }
}

@keyframes qsBannerKenBurns {
  0% {
    transform: scale(1.08);
    object-position: center 42%;
  }
  100% {
    transform: scale(1.02);
    object-position: center 58%;
  }
}

.page-quem-somos .qs-banner__shine {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    105deg,
    transparent 38%,
    rgba(255, 214, 10, 0.12) 48%,
    rgba(255, 255, 255, 0.08) 52%,
    transparent 62%
  );
  transform: translateX(-120%) skewX(-12deg);
  animation: qsBannerShine 5s ease-in-out 2s infinite;
  pointer-events: none;
}

@keyframes qsBannerShine {
  0%, 72% { transform: translateX(-120%) skewX(-12deg); opacity: 0; }
  78% { opacity: 1; }
  100% { transform: translateX(130%) skewX(-12deg); opacity: 0; }
}

.page-quem-somos .qs-banner--premium .qs-banner__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.92) 0%,
    rgba(0, 0, 0, 0.5) 42%,
    rgba(0, 0, 0, 0.15) 78%,
    rgba(0, 0, 0, 0.05) 100%
  ) !important;
  pointer-events: none;
}

.page-quem-somos .qs-banner--premium .qs-banner__content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  margin-top: 0;
  padding-bottom: clamp(28px, 4vw, 44px);
}

.page-quem-somos .qs-banner__pulse {
  display: block;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 4;
  background: linear-gradient(90deg, transparent, #ffd60a, transparent);
  opacity: 0.85;
  animation: qsBannerPulseLine 2.8s ease-in-out infinite;
}

@keyframes qsBannerPulseLine {
  0%, 100% { opacity: 0.35; transform: scaleX(0.6); }
  50% { opacity: 1; transform: scaleX(1); }
}

.qs-banner--premium .section-tag {
  background: rgba(255, 214, 10, 0.12);
  border: 1px solid rgba(255, 214, 10, 0.35);
  color: #ffd60a;
}

.qs-banner--premium .qs-banner__title {
  background: linear-gradient(135deg, #fff 0%, #fff 55%, #ffd60a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}


/* —— História: texto justificado —— */
.qs-historia--premium {
  position: relative;
  padding: clamp(64px, 9vw, 100px) 0 clamp(48px, 6vw, 72px);
  background: var(--black);
  overflow: hidden;
}

.qs-historia__mesh {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 214, 10, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 214, 10, 0.025) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, #000 20%, transparent 75%);
  pointer-events: none;
}

.qs-historia--premium .history-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 56px);
  align-items: center;
  position: relative;
  z-index: 1;
}

.qs-historia--premium .history-text h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 24px;
  line-height: 1.2;
  background: linear-gradient(135deg, #ffffff 0%, #ffd60a 120%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.qs-historia--premium .history-text p {
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.02rem;
  line-height: 1.9;
  margin-bottom: 18px;
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
}

.qs-historia--premium .history-text p strong {
  color: #ffd60a;
}

/* Stat 6+ em destaque */
.qs-historia__stats {
  margin-top: 28px;
}

.qs-historia__stat--featured {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 200px;
  padding: 28px 36px;
  background: rgba(255, 214, 10, 0.08);
  border: 2px solid rgba(255, 214, 10, 0.35);
  border-radius: 20px;
  text-align: center;
  overflow: visible;
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.4s ease;
}

.qs-historia__stat--featured.is-animated {
  animation: qsStatPop 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes qsStatPop {
  0% { transform: scale(0.85); opacity: 0.5; }
  60% { transform: scale(1.06); }
  100% { transform: scale(1); opacity: 1; }
}

.qs-historia__stat-ring {
  position: absolute;
  inset: -8px;
  border: 1px solid rgba(255, 214, 10, 0.4);
  border-radius: 22px;
  animation: qsStatRing 2.5s ease-out infinite;
  pointer-events: none;
}

.qs-historia__stat-ring--2 {
  animation-delay: 1.2s;
}

@keyframes qsStatRing {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(1.25); opacity: 0; }
}

.qs-historia__stat-num {
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  font-weight: 900;
  line-height: 1;
  color: #ffd60a;
  text-shadow: 0 0 40px rgba(255, 214, 10, 0.5);
  animation: qsStatGlow 2s ease-in-out infinite alternate;
}

@keyframes qsStatGlow {
  from { filter: brightness(1); }
  to { filter: brightness(1.25); }
}

.qs-historia__stat--featured > span:not(.qs-historia__stat-ring) {
  margin-top: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #ffffff;
}

.qs-historia__stat--featured small {
  margin-top: 6px;
  font-size: 0.75rem;
  color: rgba(255, 214, 10, 0.75);
}

.qs-historia__stat--featured:hover {
  transform: translateY(-6px) scale(1.03);
  box-shadow: 0 20px 50px rgba(255, 214, 10, 0.2);
}

.qs-historia__visual {
  position: relative;
}

.qs-historia__frame {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 214, 10, 0.25);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(255, 214, 10, 0.08);
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.45s ease;
}

.qs-historia__frame:hover {
  transform: translateY(-8px);
  box-shadow: 0 32px 70px rgba(0, 0, 0, 0.55), 0 0 48px rgba(255, 214, 10, 0.18);
}

.qs-historia__frame img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
  transition: filter 0.45s ease;
}

.qs-historia__frame:hover img {
  filter: brightness(1.06);
}

.qs-historia__shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(125deg, rgba(255, 214, 10, 0.15), transparent 50%);
  pointer-events: none;
  opacity: 0;
}

.qs-historia__frame:hover .qs-historia__shine {
  animation: qsHistoriaShine 1.8s ease forwards;
}

@keyframes qsHistoriaShine {
  from { transform: translateX(-100%) skewX(-8deg); opacity: 0; }
  40% { opacity: 1; }
  to { transform: translateX(120%) skewX(-8deg); opacity: 0; }
}

/* —— Timeline scroll real —— */
.qs-timeline-section {
  position: relative;
  padding: 0 0 clamp(80px, 10vw, 120px);
  background: linear-gradient(180deg, var(--black) 0%, #050505 100%);
}

.qs-timeline-header {
  text-align: center;
  max-width: 780px;
  margin: 0 auto clamp(48px, 6vw, 72px);
  padding: 0 20px;
}

.qs-timeline-header .section-tag {
  background: rgba(255, 214, 10, 0.1);
  border: 1px solid rgba(255, 214, 10, 0.35);
  color: #ffd60a;
}

.qs-timeline-header h2 {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 800;
  margin: 12px 0 14px;
  color: #fff;
}

.qs-timeline-header p {
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.75;
  text-align: center;
}

.qs-timeline-header p strong {
  color: #ffd60a;
}

/* Container timeline */
.st-scroll-timeline {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px 40px;
}

.st-scroll-timeline__rail {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 4px;
  transform: translateX(-50%);
  z-index: 0;
  pointer-events: none;
}

.st-scroll-timeline__line-bg {
  position: absolute;
  inset: 0;
  background: rgba(255, 214, 10, 0.12);
  border-radius: 4px;
}

.st-scroll-timeline__line-fill {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 0%;
  background: linear-gradient(180deg, #ffeb3b, #ffd60a, #e6b800);
  border-radius: 4px;
  box-shadow: 0 0 16px rgba(255, 214, 10, 0.7);
  transition: height 0.12s ease-out;
}

.st-scroll-timeline__item {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 56px 1fr;
  gap: clamp(16px, 3vw, 32px);
  align-items: center;
  min-height: 140px;
  margin-bottom: clamp(28px, 4vw, 48px);
}

.st-scroll-timeline__panel {
  display: flex;
}

.st-scroll-timeline__item--left .st-scroll-timeline__panel {
  justify-content: flex-end;
}

.st-scroll-timeline__item--right .st-scroll-timeline__panel {
  justify-content: flex-start;
}

.st-scroll-timeline__axis {
  display: flex;
  justify-content: center;
  align-items: center;
}

.st-scroll-timeline__dot {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0a0a0a;
  border: 2px solid rgba(255, 214, 10, 0.35);
  border-radius: 50%;
  color: #ffd60a;
  font-size: 1.1rem;
  box-shadow: 0 0 0 8px rgba(255, 214, 10, 0.06);
  transition:
    transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1),
    background 0.35s ease,
    border-color 0.35s ease,
    box-shadow 0.35s ease;
}

.st-scroll-timeline__card {
  max-width: 420px;
  width: 100%;
  padding: 22px 24px;
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid rgba(255, 214, 10, 0.2);
  border-radius: 18px;
  position: relative;
  overflow: hidden;
  opacity: 0;
  transition:
    opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.65s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.35s ease,
    box-shadow 0.35s ease;
}

.st-scroll-timeline__item--left .st-scroll-timeline__card {
  transform: translateX(-72px);
}

.st-scroll-timeline__item--right .st-scroll-timeline__card {
  transform: translateX(72px);
}

.st-scroll-timeline__item.is-active .st-scroll-timeline__card {
  opacity: 1;
  transform: translateX(0);
  border-color: rgba(255, 214, 10, 0.45);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45), 0 0 28px rgba(255, 214, 10, 0.12);
}

.st-scroll-timeline__item.is-active .st-scroll-timeline__dot {
  background: linear-gradient(135deg, #ffd60a, #e6b800);
  color: #0a0a0a;
  border-color: #ffd60a;
  transform: scale(1.12);
  box-shadow: 0 0 32px rgba(255, 214, 10, 0.45);
}

.st-scroll-timeline__card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ffd60a, transparent);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.st-scroll-timeline__item.is-active .st-scroll-timeline__card::before {
  opacity: 1;
}

.st-scroll-timeline__item--right.is-active .st-scroll-timeline__card::before {
  background: linear-gradient(270deg, #ffd60a, transparent);
}

.st-scroll-timeline__card:hover {
  border-color: rgba(255, 214, 10, 0.6);
  box-shadow: 0 20px 56px rgba(0, 0, 0, 0.5), 0 0 36px rgba(255, 214, 10, 0.18) !important;
}

.st-scroll-timeline__label {
  display: inline-block;
  padding: 4px 12px;
  margin-bottom: 10px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, #ffd60a, #e6b800);
  color: #0a0a0a;
  border-radius: 50px;
}

.st-scroll-timeline__card h3 {
  font-size: 1.65rem;
  font-weight: 800;
  color: #ffd60a;
  margin-bottom: 10px;
}

.st-scroll-timeline__tag {
  display: inline-block;
  margin-bottom: 12px;
  padding: 5px 10px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #ffd60a;
  background: rgba(255, 214, 10, 0.1);
  border: 1px solid rgba(255, 214, 10, 0.3);
  border-radius: 8px;
}

.st-scroll-timeline__card p {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.92rem;
  line-height: 1.7;
  margin-bottom: 8px;
}

.st-scroll-timeline__plus {
  color: rgba(255, 214, 10, 0.85) !important;
  font-weight: 600;
}

@media (max-width: 992px) {
  .qs-historia--premium .history-content {
    grid-template-columns: 1fr;
  }

  .qs-historia__visual {
    order: -1;
  }
}

@media (max-width: 768px) {
  .st-scroll-timeline__item {
    grid-template-columns: 48px 1fr;
    grid-template-areas:
      'axis panel'
      'axis spacer';
  }

  .st-scroll-timeline__item--left,
  .st-scroll-timeline__item--right {
    grid-template-areas: 'axis panel';
  }

  .st-scroll-timeline__spacer {
    display: none;
  }

  .st-scroll-timeline__axis {
    grid-area: axis;
  }

  .st-scroll-timeline__panel {
    grid-area: panel;
    justify-content: flex-start !important;
  }

  .st-scroll-timeline__rail {
    left: 24px;
    transform: none;
  }

  .st-scroll-timeline__item--left .st-scroll-timeline__card,
  .st-scroll-timeline__item--right .st-scroll-timeline__card {
    transform: translateX(40px);
  }

  .st-scroll-timeline__item.is-active .st-scroll-timeline__card {
    transform: translateX(0);
  }
}

/* Fallback: conteúdo visível se JS de animação global falhar */
.page-quem-somos .qs-banner--premium.qs-banner--fullwidth,
.page-quem-somos .qs-historia--premium,
.page-quem-somos .qs-timeline-section,
.page-quem-somos .qs-timeline-header {
  opacity: 1 !important;
  transform: none !important;
}

@media (prefers-reduced-motion: reduce) {
  .page-quem-somos .qs-banner--premium .qs-banner__img,
  .page-quem-somos .qs-banner__shine,
  .page-quem-somos .qs-banner__pulse {
    animation: none;
  }

  .page-quem-somos .qs-banner--premium .qs-banner__img {
    transform: scale(1);
    opacity: 1;
  }

  .qs-historia__stat-num,
  .qs-historia__stat-ring {
    animation: none;
  }

  .st-scroll-timeline__card {
    opacity: 1;
    transform: none !important;
  }

  .st-scroll-timeline__line-fill {
    transition: none;
  }
}
