/* ============================================================
   Xcode — Site Institucional
   Estética: tipografia ampla, espaço em branco, sobriedade.
   ============================================================ */

:root {
  /* Paleta derivada do gradiente da logo */
  --azul-profundo: #0b3fa0;
  --azul: #1e6fe0;
  --ciano: #3ba9f0;
  --gradiente: linear-gradient(135deg, #1e6fe0 0%, #0b3fa0 100%);

  /* Neutros (padrão institucional) */
  --tinta: #1d1d1f;
  --cinza: #6e6e73;
  --cinza-claro: #86868b;
  --linha: #d2d2d7;
  --fundo: #ffffff;
  --fundo-alt: #f5f5f7;

  /* Tipografia */
  --fonte: -apple-system, "SF Pro Display", BlinkMacSystemFont, "Inter",
    "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Layout */
  --largura: 1120px;
  --nav-altura: 56px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-altura);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--fonte);
  color: var(--tinta);
  background: var(--fundo);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: 100%;
  max-width: var(--largura);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------------------------------------------------------- Navegação */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-altura);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.3s ease;
}

.nav.is-scrolled {
  border-bottom-color: var(--linha);
}

.nav__inner {
  max-width: var(--largura);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav__logo {
  width: 28px;
  height: 28px;
  border-radius: 50%;
}

.nav__wordmark {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav__links a {
  font-size: 15px;
  font-weight: 500;
  color: var(--tinta);
  opacity: 0.85;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.nav__links a:hover {
  opacity: 1;
  color: var(--azul);
}

.nav__cta {
  padding: 6px 16px;
  border-radius: 980px;
  background: var(--azul);
  color: #fff !important;
  opacity: 1 !important;
}

.nav__cta:hover {
  background: var(--azul-profundo);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: 0;
  cursor: pointer;
}

.nav__toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--tinta);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav.is-open .nav__toggle span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.nav.is-open .nav__toggle span:nth-child(2) {
  opacity: 0;
}
.nav.is-open .nav__toggle span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ---------------------------------------------------------- Botões */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: 980px;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease,
    border-color 0.2s ease;
}

.btn--primary {
  background: var(--azul);
  color: #fff;
}
.btn--primary:hover {
  background: var(--azul-profundo);
}

.btn--ghost {
  border: 1px solid var(--linha);
  color: var(--tinta);
}
.btn--ghost:hover {
  border-color: var(--azul);
  color: var(--azul);
}

/* ---------------------------------------------------------- Hero */
.hero {
  padding: calc(var(--nav-altura) + 120px) 0 130px;
  background: radial-gradient(
    120% 120% at 50% 0%,
    rgba(59, 169, 240, 0.1) 0%,
    rgba(255, 255, 255, 0) 60%
  );
  text-align: center;
}

.hero__content {
  max-width: 880px;
}

.hero__eyebrow {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--azul);
  margin-bottom: 18px;
}

.hero__title {
  font-size: clamp(2.6rem, 6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.06;
  margin-bottom: 26px;
}

.hero__subtitle {
  font-size: clamp(1.1rem, 2.2vw, 1.4rem);
  font-weight: 400;
  color: var(--cinza);
  max-width: 640px;
  margin: 0 auto 40px;
  line-height: 1.45;
}

.hero__actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------------------------------------------------------- Seções */
.section {
  padding: 120px 0;
}

.section--alt {
  background: var(--fundo-alt);
}

.section__head {
  max-width: 720px;
  margin: 0 auto 64px;
  text-align: center;
}

.section__eyebrow {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--azul);
  margin-bottom: 16px;
}

.section__title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 20px;
}

.section__lead {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--cinza);
  line-height: 1.5;
}

/* ---------------------------------------------------------- Pilares */
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.pillar {
  background: var(--fundo);
  border: 1px solid var(--linha);
  border-radius: 22px;
  padding: 40px 34px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pillar:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 50px rgba(11, 63, 160, 0.1);
}

.pillar__title {
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.pillar__text {
  font-size: 1rem;
  color: var(--cinza);
  margin-bottom: 24px;
  line-height: 1.5;
}

.pillar__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pillar__list li {
  position: relative;
  padding-left: 22px;
  font-size: 0.96rem;
  color: var(--tinta);
  line-height: 1.4;
}

.pillar__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gradiente);
}

/* ---------------------------------------------------------- Sobre */
.about {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 64px;
  align-items: start;
}

.about__text p {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--cinza);
  line-height: 1.6;
  margin-bottom: 22px;
}

.about__text p:last-child {
  margin-bottom: 0;
}

.about__principles {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.about__principles li {
  padding-left: 22px;
  border-left: 2px solid var(--azul);
}

.about__principles h3 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 8px;
}

.about__principles p {
  font-size: 0.98rem;
  color: var(--cinza);
  line-height: 1.5;
}

/* ---------------------------------------------------------- Abordagem */
.approach {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}

.approach__item {
  padding-top: 24px;
  border-top: 1px solid var(--linha);
}

.approach__num {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--azul);
  margin-bottom: 16px;
}

.approach__title {
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 10px;
}

.approach__item p {
  font-size: 0.96rem;
  color: var(--cinza);
  line-height: 1.5;
}

/* ---------------------------------------------------------- Tecnologias */
.tech {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 18px;
  max-width: 920px;
  margin: 0 auto;
}

.tech li {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 28px 16px;
  border: 1px solid var(--linha);
  border-radius: 18px;
  background: var(--fundo);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.tech li:hover {
  border-color: var(--azul);
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(11, 63, 160, 0.08);
}

.tech img {
  width: 46px;
  height: 46px;
  max-width: 46px;
  max-height: 46px;
  object-fit: contain;
  flex-shrink: 0;
}

.tech span {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--tinta);
  text-align: center;
}

/* ---------------------------------------------------------- Contato */
.contato__inner {
  max-width: 720px;
  text-align: center;
}

.contato__title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 18px;
}

.contato__lead {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--cinza);
  margin-bottom: 36px;
  line-height: 1.5;
}

.contato__actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------------------------------------------------------- Footer */
.footer {
  background: var(--fundo-alt);
  border-top: 1px solid var(--linha);
  padding: 48px 0;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.footer__logo {
  width: 26px;
  height: 26px;
  border-radius: 50%;
}

.footer__links {
  display: flex;
  gap: 28px;
}

.footer__links a {
  font-size: 14px;
  color: var(--cinza);
  transition: color 0.2s ease;
}

.footer__links a:hover {
  color: var(--azul);
}

.footer__legal {
  font-size: 13px;
  color: var(--cinza-claro);
}

/* ---------------------------------------------------------- Reveal */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------------------------------------------------------- Responsivo */
@media (max-width: 900px) {
  .pillars {
    grid-template-columns: 1fr;
    max-width: 560px;
    margin: 0 auto;
  }
  .approach {
    grid-template-columns: repeat(2, 1fr);
  }
  .about {
    grid-template-columns: 1fr;
    gap: 44px;
  }
}

@media (max-width: 768px) {
  .nav__links {
    position: fixed;
    top: var(--nav-altura);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--linha);
    padding: 8px 24px 20px;
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
  }
  .nav.is-open .nav__links {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  .nav__links a {
    padding: 14px 0;
    font-size: 17px;
    border-bottom: 1px solid var(--linha);
  }
  .nav__cta {
    margin-top: 14px;
    text-align: center;
    border-bottom: 0 !important;
  }
  .nav__toggle {
    display: flex;
  }
  .section {
    padding: 84px 0;
  }
  .hero {
    padding: calc(var(--nav-altura) + 80px) 0 90px;
  }

  /* Conteúdo centralizado no mobile */
  .approach__item {
    text-align: center;
  }
  .pillar {
    text-align: center;
  }
  .pillar__list {
    display: inline-block;
    text-align: left;
  }
  .about__text {
    text-align: center;
  }
  .about__principles li {
    border-left: 0;
    padding-left: 0;
    text-align: center;
  }
}

@media (max-width: 540px) {
  .approach {
    grid-template-columns: 1fr;
  }
  .hero__actions,
  .contato__actions {
    flex-direction: column;
  }
  .btn {
    width: 100%;
  }
}

/* ---------------------------------------------------------- Movimento reduzido */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  * {
    transition-duration: 0.01ms !important;
  }
}
