/* 1. CONFIGURAÇÕES GERAIS E CORES */
:root {
  --primary: #80fff9; /* Ciano sutil */
  --primary-dim: rgba(128, 255, 249, 0.15);
  --bg-dark: #020611; /* Azul marinho profundo */
  --card-bg: rgba(255, 255, 255, 0.02);
  --border-light: rgba(255, 255, 255, 0.08);
  --font-main: "Plus Jakarta Sans", sans-serif;
  --text-dim: #94a3b8;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background: linear-gradient(120deg, #020617, #050b2c, #0b3b4a, #020617);
  color: #ffffff;
  line-height: 1.6;
  overflow-x: hidden;
  background-attachment: fixed;
  background-size: 400% 400%;
  animation: gradientMove 8s ease infinite;
}

@keyframes gradientMove {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* 2. ESPAÇAMENTO ENTRE SEÇÕES */

.section {
  padding: 0;
}

.section-header {
  text-align: center;
  margin-bottom: 50px;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 50px 30px; /* Removido o padding 50px vertical para não somar com o da section */
}

/* 3. HEADER NAVEGAÇÃO (ESTILIZAÇÃO CORRIGIDA)  */
#header {
  position: fixed;
  top: 25px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  width: 90%;
  max-width: 900px;
}

.nav-floating {
  background: rgba(10, 15, 30, 0.8);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--border-light);
  padding: 12px 20px;
  border-radius: 100px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* 4. LOGO J.DEV */
.logo {
  font-weight: 800;
  font-size: 1.2rem;
  color: #ffffff !important;
  text-decoration: none !important;
  transition: 0.3s;
  cursor: pointer;
  letter-spacing: -0.5px;
}

.logo:hover {
  color: var(--primary) !important;
}

/* 5. LINKS DO MENU (Habilidades, Projetos, Contato) */
.nav-links a {
  color: #fff;
  text-decoration: none;
  font-size: 0.85rem;
  margin: 0 15px;
  opacity: 0.7;
  transition: 0.3s;
  font-weight: 500;
}

.nav-links a:hover {
  opacity: 1;
  color: var(--primary);
}

/* 6. BOTÃO DE IDIOMA (EN/PT) */
#lang-switch {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  transition: 0.3s;
}

#lang-switch-mobile {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  transition: 0.3s;
  margin-top: 14px;
}

#lang-switch:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary);
}

/* 7. BOTÃO CONTRATAR */
.nav-cta {
  background: #ffffff !important;
  color: #000000 !important;
  padding: 8px 20px;
  border-radius: 50px;
  font-weight: 800;
  font-size: 0.8rem;
  text-decoration: none;
  transition: 0.3s ease;
  display: inline-block;
}

.nav-cta:hover {
  transform: scale(1.05);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

/* ============================================================
   FIM DA CORREÇÃO DO HEADER
   ============================================================ */

/* 8. BOTÕES HERO E RESTANTE DO CÓDIGO (ORIGINAL) */
.btn {
  padding: 12px 28px;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.4s ease;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.btn-primary {
  background: var(--primary);
  color: #000;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(128, 255, 249, 0.2);
}

.btn-secondary {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  margin-left: 15px;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: #fff;
}

/* 9. SEÇÃO HERO */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 60px;
  align-items: center;
}

.hero-title {
  font-size: 4rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 25px;
}

.highlight {
  color: var(--primary);
}

.hero-desc {
  color: var(--text-dim);
  font-size: 1.1rem;
  max-width: 500px;
  margin-bottom: 35px;
}

.hero-profile-img {
  width: 100%;
  border-radius: 40px;
  filter: grayscale(20%);
  border: 1px solid var(--border-light);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* 10. HABILIDADES (SKILLS) */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 25px;
}

.skill-card {
  background: var(--card-bg);
  border: 1px solid var(--border-light);
  padding: 35px;
  border-radius: 20px;
  transition: 0.4s;
}

.skill-card:hover {
  border-color: var(--primary);
  background: rgba(128, 255, 249, 0.02);
}

.skill-badge {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary);
  border: 1px solid var(--primary-dim);
  padding: 4px 10px;
  border-radius: 6px;
  font-weight: 800;
}

.skill-card h3 {
  margin: 20px 0 10px 0;
  font-size: 1.4rem;
}

.skill-card p {
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* 11. PROJETOS */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
}

.project-card {
  background: var(--card-bg);
  border: 1px solid var(--border-light);
  border-radius: 24px;
  overflow: hidden;
  transition: 0.4s;
}

.project-img-box {
  width: 100%;
  height: 220px;
  background: #111;
  overflow: hidden;
}

.project-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.5s;
}

.project-info {
  padding: 30px;
}

.project-card:hover {
  transform: translateY(-10px);
  border-color: var(--primary);
}

/* 12. CONTATO */
.contact-wrapper {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-light);
  padding: 40px;
  border-radius: 30px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
}

.contact-info h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

.contact-list p {
  display: flex;
  gap: 10px;
  align-items: center;
}

input,
textarea {
  width: 100%;
  background: rgba(255, 255, 255, 0.03) !important;
  border: 1px solid var(--border-light) !important;
  padding: 16px;
  border-radius: 12px;
  color: #fff;
  margin-bottom: 15px;
  outline: none;
  font-family: inherit;
}

input:focus,
textarea:focus {
  border-color: var(--primary) !important;
}

/* 13. ANIMAÇÕES REVEAL */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: 0.8s ease;
}

.reveal.show {
  opacity: 1;
  transform: translateY(0);
}

/* 14. RESPONSIVIDADE */
@media (max-width: 900px) {
  .hero-grid,
  .contact-wrapper {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-title {
    font-size: 2.8rem;
  }
  .hero-desc {
    margin: 0 auto 30px auto;
  }
  .btn-secondary {
    margin: 15px 0 0 0;
  }
  .hero-text {
    padding-top: 50px;
  }
}

/* 15. MENU SANDUÍCHE MOBILE */

.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: #fff;
  margin: 4px 0;
}

.mobile-menu {
  position: fixed;
  inset: 0;
  backdrop-filter: blur(45px);
  z-index: 2000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transform: translateY(-100%);
  transition: 0.4s ease;
  opacity: 0;
  pointer-events: none;
}

.mobile-menu.active {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 25px;
  margin-bottom: 30px;
}

.mobile-nav-links a {
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  text-decoration: none;
}

.close-menu {
  position: absolute;
  top: 30px;
  right: 30px;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
}

@media (max-width: 900px) {
  .nav-links {
    display: none;
  }
  .hamburger {
    display: block;
  }
}

/* 16. SOCIAL LINKS */

.footer-content {
  display: flex;
  justify-content: space-between;
}

.social-links {
  display: flex;
  gap: 20px;
}

.social-links a {
  color: #ffffff;
}

textarea {
  resize: none;
}

/* 17. MODAL DE PROJETOS */
.project-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  z-index: 3000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.project-modal.active {
  display: flex;
}

.modal-content {
  background: #0a0f1e;
  border: 1px solid var(--border-light);
  max-width: 950px;
  width: 100%;
  max-height: 95vh;
  border-radius: 24px;
  position: relative;
  padding: 40px;
  overflow-y: auto;
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
}

.gallery-wrapper {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.modal-gallery {
  display: flex;
  flex-direction: row;
  gap: 0;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;

  scroll-snap-type: x mandatory;
  width: 100%;
}

.modal-gallery::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.modal-gallery img {
  min-width: 100%;
  width: 100%;
  scroll-snap-align: center;
  object-fit: contain;
  padding: 0 5px;
  box-sizing: border-box;
  border-radius: 20px;
}

/* 18. SETAS DE NAVEGAÇÃO */
.nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(128, 255, 249, 0.2);
  border: 1px solid var(--primary);
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: none;
  backdrop-filter: blur(5px);
}

.nav-arrow.left {
  left: -10px;
}
.nav-arrow.right {
  right: -10px;
}

#modalBody p {
  color: var(--text-dim);
  line-height: 1.6;
  font-size: 15px;
}

#modalBody a {
  color: #fff000;
  text-decoration: none;
}

@media (max-width: 768px) {
  .image-zoom-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    cursor: zoom-out;
  }

  .image-zoom-overlay img {
    max-width: 95%;
    max-height: 95%;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  }

  .modal-gallery img {
    cursor: zoom-in;
  }
}

.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  background-color: var(--primary);
  color: #000;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: none;
  z-index: 1000;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(128, 255, 249, 0.3);
  font-size: 1.2rem;
}

.back-to-top:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(128, 255, 249, 0.5);
}

body.modal-open .back-to-top {
  display: none !important;
}


