/* ESTILO GERAL */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Epilogue", sans-serif;
}

a {
  text-decoration: none;
}

html {
  scroll-behavior: smooth;
}

::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background-color: #040615;
}
::-webkit-scrollbar-thumb {
  background-color: #986dff;
  border-radius: 8px;
}

body {
  background-color: #040615;
  min-height: 100vh; /* era height: 100vh — causava corte em páginas longas */
}

button {
  -webkit-appearance: none;
  appearance: none;
  outline: none !important;
  box-shadow: none !important;
}

button:focus,
button:focus-visible,
button:active {
  outline: none !important;
  box-shadow: none !important;
  -webkit-tap-highlight-color: transparent;
}

.interface {
  max-width: 1280px;
  margin: 0 auto;
}

.flex {
  display: flex;
}

.btn-contato button {
  padding: 10px 40px;
  font-size: 18px;
  font-weight: 600;
  background-color: #986dff;
  border: 0;
  border-radius: 30px;
  cursor: pointer;
  transition: 0.2s;
}

h2.titulo {
  color: #fff;
  font-size: clamp(28px, 4vw, 38px); /* responsivo em vez de fixo */
  text-align: center;
}

h2.titulo span {
  color: #986dff;
}

button:hover,
form .btn-enviar input:hover {
  box-shadow: 0px 0px 8px #986dff;
  transform: scale(1.05);
}

/* MENU MOBILE LEGADO */
.btn-abrir-menu {
  display: none;
}

.btn-abrir-menu i {
  color: #986dff;
  font-size: 40px;
}

.menu-mobile {
  background-color: #000;
  height: 100vh;
  position: fixed;
  top: 0;
  right: 0;
  z-index: 99999;
  width: 0%;
  overflow: hidden;
  transition: 0.5s;
}

.menu-mobile.abrir-menu {
  width: 70%;
}

.menu-mobile.abrir-menu ~ .overlay-menu {
  display: block;
}

.menu-mobile .btn-fechar {
  padding: 20px 5%;
}

.menu-mobile .btn-fechar i {
  color: #986dff;
  font-size: 30px;
}

.menu-mobile nav ul {
  text-align: right;
}

.menu-mobile nav ul li a {
  color: #fff;
  font-size: 20px;
  font-weight: 300;
  padding: 20px 8%;
  display: block;
}

.menu-mobile nav ul li a:hover {
  background-color: #986dff;
  color: #000;
}

.overlay-menu {
  background-color: #000000df;
  width: 100%;
  height: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 88888;
  display: none;
}

/* ================================ */
/* TOPO DO SITE (HERO)              */
/* ================================ */
section.topo-do-site {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 100px 4% 60px;
}

section.topo-do-site .interface {
  width: 100%;
  /* z-index e will-change definidos em hero-2.css */
}

section.topo-do-site .flex {
  align-items: center;
  justify-content: center;
  gap: clamp(32px, 6vw, 90px);
}

/* REMOVIDO: margin-right: -13px — era ajuste visual frágil */

.typewriter::after {
  content: "|";
  color: #986dff;
  animation: blink 0.8s infinite;
  margin-left: 4px;
  font-weight: bold;
}

@keyframes blink {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

.topo-do-site h1 {
  color: #fff;
  font-size: clamp(28px, 3.5vw, 42px); /* era fixo 42px */
  line-height: 1.2;
}

.topo-do-site .txt-topo-site h1 span {
  color: #986dff;
}

.topo-do-site .txt-topo-site p {
  color: #fff;
  margin: 40px 0;
}

.topo-do-site .img-topo-site {
  flex-shrink: 0;
}

.topo-do-site .img-topo-site img {
  animation: flutuar 2s ease-in-out infinite alternate;
  width: clamp(220px, 30vw, 420px); /* era tamanho sem controle */
  height: auto;
  /* REMOVIDO: margin-top: -93px e margin-right: -90px — valores negativos frágeis */
}

@keyframes flutuar {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(30px);
  }
}

.btn-contato {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.btn-contato .btn-cv {
  padding: 10px 40px;
  font-size: 18px;
  font-weight: 600;
  background-color: transparent;
  border: 1px solid #986dff;
  color: #986dff;
  border-radius: 30px;
  cursor: pointer;
  transition: 0.3s ease;
}

.btn-contato .btn-cv:hover {
  background-color: #986dff;
  color: black;
  transform: scale(1.05);
}

/* ================================ */
/* ESPECIALIDADES                   */
/* ================================ */
section.especiliadades {
  padding: 60px 4%;
  padding-top: 100px;
  box-shadow: 0 0 40px 10px #ffffff1d;
}

section.especiliadades .flex {
  gap: 60px;
}

.especiliadades .especialidades-box {
  color: #fff;
  padding: 40px;
  border-radius: 20px;
  margin-top: 45px;
  transition: 0.2s;
}

.especiliadades .especialidades-box:hover {
  transform: scale(1.05);
  box-shadow: 0 0 20px #ffffff78;
}

.especiliadades .especialidades-box i {
  font-size: 70px;
  color: #986dff;
}

.especiliadades .especialidades-box h3 {
  font-size: 28px;
  margin: 15px 0;
}

/* ================================ */
/* PORTFÓLIO                        */
/* ================================ */
section.portfolio {
  padding: 80px 4%;
  box-shadow: 0 0 40px 10px #ffffff1d;
}

section.portfolio .flex {
  justify-content: space-around;
  margin-top: 60px;
  flex-wrap: wrap;
  gap: 40px;
}

.img-port {
  width: clamp(280px, 28vw, 360px);
  height: clamp(360px, 35vw, 460px);
  background-size: cover;
  background-position: 100% 0%;
  transition: background-position 8s ease-out; /* só o background-position, igual mobile */
  cursor: pointer;
  border-radius: 40px;
  position: relative;
  border: 1px solid #986fdd;
  box-shadow: 0 0 10px #986fdd80;
}

/* Controlado via JS — desktop (mouseenter) e mobile (touchstart) */
.img-port.touched {
  background-position: 100% 100%;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #000000b8;
  border-radius: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 600;
  color: #fff;
  opacity: 0;
  transition: 0.5s;
}

.overlay:hover {
  opacity: 1;
}

/* ================================ */
/* RODAPÉ                           */
/* ================================ */
footer {
  padding: 40px 4%;
  box-shadow: 0 0 40px 10px #ffffff1d;
}

footer .flex {
  justify-content: space-between;
}

footer .line-footer {
  padding: 20px 0;
}

.borda {
  border-top: 2px solid #986dff;
}

footer .line-footer p i {
  color: #986dff;
  font-size: 22px;
}

footer .line-footer p a {
  color: #fff;
}

/* ================================ */
/* RESPONSIVO GERAL                 */
/* ================================ */
@media screen and (max-width: 1020px) {
  .flex {
    flex-direction: column;
  }

  .topo-do-site .flex {
    flex-direction: column-reverse;
    align-items: center;
  }

  h2.titulo {
    font-size: 30px;
    line-height: 1.3;
  }

  section.topo-do-site .flex {
    gap: 40px;
  }

  section.topo-do-site {
    padding: 120px 6% 60px;
  }

  .topo-do-site h1 {
    font-size: 28px;
    text-align: center;
  }

  .topo-do-site .txt-topo-site {
    text-align: center;
  }

  .topo-do-site .img-topo-site img {
    width: min(340px, 80vw);
    margin: 0 auto;
    display: block;
  }

  .btn-contato {
    justify-content: center;
  }

  section.especiliadades {
    padding: 40px 6%;
  }

  section.sobre {
    padding: 80px 6%;
  }

  .sobre .txt-sobre h2 {
    font-size: 30px;
    line-height: 1.3;
    text-align: center;
  }

  .btn-social {
    text-align: center;
  }

  .img-sobre img {
    width: 100%;
  }

  section.portfolio {
    padding: 80px 6%;
  }

  .img-port {
    width: 100%;
    max-width: 360px;
    height: 420px;
    margin: 0 auto;
  }

  section.portfolio .flex {
    gap: 40px;
  }
}

@media screen and (max-width: 600px) {
  section.topo-do-site {
    padding: 110px 5% 50px;
  }

  .topo-do-site h1 {
    font-size: 24px;
  }

  .btn-contato button,
  .btn-contato .btn-cv {
    font-size: 16px;
    padding: 10px 28px;
  }

  .img-port {
    height: 360px;
  }
}

/* ================================ */
/* FOOTER                           */
/* ================================ */
.site-footer {
  padding: 32px 4%;
  background-color: #040615;
  box-shadow: 0 0 40px 10px #ffffff1d;
}

.site-footer .grid-layout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  flex-wrap: wrap;
  gap: 16px;
}

/* BRAND — logo + CNPJ */
.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer-logo {
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.footer-logo span {
  color: #986dff;
}

.footer-cnpj {
  font-size: 0.72rem;
  color: #444;
  letter-spacing: 0.04em;
}

/* COPYRIGHT */
.footer-copy {
  font-size: 0.85rem;
  color: #555;
  margin: 0;
}

.footer-copy a {
  font-weight: 500;
  color: #986dff;
  text-decoration: none;
}

/* POWERED BY */
.site-footer .footer-powered {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-footer .footer-powered p {
  font-size: 0.85rem;
  color: #555;
  margin: 0;
}

.site-footer .footer-powered p a {
  font-weight: 500;
  color: #986dff;
  text-decoration: none;
}

.site-footer img {
  width: 32px;
  height: auto;
}

/* MOBILE */
@media screen and (max-width: 768px) {
  .site-footer .grid-layout {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
  }

  .footer-brand {
    align-items: center;
  }

  .site-footer .footer-powered {
    justify-content: center;
  }
}

/* ================================ */
/* LINK REPOSITÓRIO                 */
/* ================================ */
.link-repositorio {
  position: relative;
  display: inline-flex;
  align-items: center;
  width: fit-content;
  font-size: 1.2rem;
  color: white;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s ease;
}

.link-repositorio::after {
  content: "";
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 1px;
  bottom: -7px;
  left: 0;
  background: linear-gradient(270deg, #986dff 0%, #17161d 100%);
  transform-origin: bottom right;
  transition: transform 0.5s cubic-bezier(0.86, 0, 0.07, 1);
}

.link-repositorio:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

@keyframes blinkColor {
  0%,
  100% {
    color: #986dff;
  }
  50% {
    color: #ffffff;
  }
}

.link-repositorio i {
  margin-left: 8px;
  font-size: 1.6rem;
  vertical-align: middle;
  animation: blinkColor 1.6s infinite ease-in-out;
  transform: rotate(-45deg);
  display: inline-block;
}

/* ================================ */
/* CANVAS / PARTÍCULAS HERO         */
/* ================================ */
#home > * {
  position: relative;
  z-index: 2;
}

/* .topo-do-site position/overflow já declarados em section.topo-do-site acima */

.topo-do-site canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

/* Esconde o texto do typewriter até o JS assumir */
.typewriter {
  visibility: hidden;
}
.typewriter.ready {
  visibility: visible;
}

/* ================================ */
/* FIX: Cor dos botões              */
/* ================================ */
.btn-contato button {
  color: #000;
}
.btn-contato .btn-cv {
  color: #986dff;
}
.btn-contato .btn-cv:hover {
  color: #000;
}

