/* ===========================================
   RESET & VARIÁVEIS
=========================================== */
:root {
  --white:  #0a0a0a;
  --black:  #ffffff;
  --gray-50:  #111111;
  --gray-100: #1a1a1a;
  --gray-200: #2e2e2e;
  --gray-400: #888888;
  --gray-600: #cccccc;
  --gray-800: #eeeeee;

  --font-display: 'Instrument Serif', serif;
  --font-body: 'Geist', sans-serif;

  --max: 1080px;
  --radius: 12px;
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease: cubic-bezier(0.25, 1, 0.5, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--white);
  color: var(--black);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
ul { list-style: none; }

/* ===========================================
   NAVBAR
=========================================== */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  border-bottom: 1px solid transparent;
  transition: background 0.3s, border-color 0.3s;
}
.nav.scrolled {
  background: rgba(10,10,10,0.96);
  backdrop-filter: blur(12px);
  border-color: var(--gray-200);
}
.nav-wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 28px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}
.nav-links {
  display: flex;
  gap: 2px;
}
.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-600);
  padding: 6px 14px;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
}
.nav-links a:hover, .nav-links a.active {
  background: var(--gray-100);
  color: var(--black);
}
.nav-cta {
  flex-shrink: 0;
  font-size: 0.875rem;
  font-weight: 600;
  background: var(--black);
  color: var(--white);
  padding: 8px 20px;
  border-radius: 8px;
  transition: opacity 0.2s, transform 0.2s var(--spring);
}
.nav-cta:hover { opacity: 0.8; transform: scale(1.03); }

/* ===========================================
   BOTÃO PRIMÁRIO
=========================================== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--black);
  color: var(--white);
  padding: 12px 24px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.2s var(--spring);
  text-decoration: none;
}
.btn-primary:hover { opacity: 0.82; transform: translateY(-2px); }

/* ===========================================
   HERO
=========================================== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 100px 28px 60px;
  max-width: var(--max);
  margin: 0 auto;
}
.hero-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
  flex: 1;
}

/* Badge disponível */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--gray-600);
  border: 1px solid var(--gray-200);
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 28px;
  width: fit-content;
}
.badge-dot {
  width: 7px; height: 7px;
  background: #22c55e;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.2);
  flex-shrink: 0;
}

/* Título hero */
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 400;
  line-height: 1.0;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}
.hero-title em {
  font-style: italic;
  display: block;
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--gray-600);
  margin-bottom: 16px;
  min-height: 1.7em;
  font-weight: 400;
}
.typed { font-weight: 600; color: var(--black); }
.cursor-blink {
  display: inline-block;
  font-weight: 300;
  color: var(--gray-400);
  animation: blink 1s step-end infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }

.hero-desc {
  font-size: 1rem;
  color: var(--gray-600);
  max-width: 400px;
  line-height: 1.7;
  margin-bottom: 36px;
}

.hero-actions { display: flex; align-items: center; gap: 16px; }

.hero-socials { display: flex; gap: 8px; }
.icon-link {
  width: 42px; height: 42px;
  border: 1px solid var(--gray-200);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-600);
  transition: border-color 0.2s, color 0.2s, transform 0.2s var(--spring);
}
.icon-link:hover { border-color: var(--black); color: var(--black); transform: translateY(-2px); }

/* Foto */
.hero-right { flex-shrink: 0; }
.hero-photo-wrap {
  position: relative;
  width: 280px; height: 320px;
}
.hero-photo {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 20px;
  border: 1px solid var(--gray-200);
  display: block;
}
.float-tag {
  position: absolute;
  background: var(--white);
  border: 1px solid var(--gray-200);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 100px;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.tag-1 { top: -12px; right: -16px; animation: floatY 4s ease-in-out infinite; }
.tag-2 { bottom: 20px; left: -20px; animation: floatY 5s ease-in-out infinite 0.8s; }
@keyframes floatY {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* Stats */
.hero-stats {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 24px 36px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--gray-50);
  width: fit-content;
  margin-top: 40px;
}
.stat { text-align: center; }
.stat b {
  display: block;
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.03em;
}
.stat span {
  font-size: 0.75rem;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 500;
}
.stat-sep { width: 1px; height: 36px; background: var(--gray-200); }

/* ===========================================
   SEÇÕES GENÉRICAS
=========================================== */
.section {
  border-top: 1px solid var(--gray-200);
}
.section-wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 80px 28px;
}
.section-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 48px;
}
.section-num {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-style: italic;
  color: var(--gray-400);
}
.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

/* ===========================================
   SOBRE
=========================================== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.about-text p {
  font-size: 1rem;
  color: var(--gray-600);
  line-height: 1.8;
  margin-bottom: 16px;
}
.about-text strong { color: var(--black); font-weight: 600; }
.about-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.about-card {
  padding: 18px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  transition: border-color 0.2s, transform 0.2s var(--spring);
}
.about-card:hover { border-color: var(--black); transform: translateY(-2px); }
.about-card-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-400);
  margin-bottom: 6px;
}
.about-card p {
  font-size: 0.9rem;
  color: var(--gray-800);
  line-height: 1.5;
}
.year-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  background: var(--black);
  color: var(--white);
  padding: 1px 7px;
  border-radius: 20px;
  margin-left: 4px;
}

/* ===========================================
   PROJETOS — CARROSSEL
=========================================== */
/* A seção projetos usa padding diferente: wrap só no título */
#projetos .section-wrap {
  padding-bottom: 32px;
}

.carousel-outer {
  padding: 0 28px 80px;
  max-width: var(--max);
  margin: 0 auto;
}

.carousel-track {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-bottom: 8px;
  /* Permite ver próximo card pela borda */
  padding-right: 60px;
  cursor: grab;
}
.carousel-track:active { cursor: grabbing; }
.carousel-track::-webkit-scrollbar { display: none; }

.proj-card {
  flex: 0 0 360px;
  scroll-snap-align: start;
  border: 1px solid var(--gray-200);
  border-radius: 16px;
  overflow: hidden;
  background: var(--white);
  display: flex;
  flex-direction: column;
  transition: border-color 0.25s, transform 0.3s var(--spring);
}
.proj-card:hover {
  border-color: var(--black);
  transform: translateY(-4px);
}

.proj-img {
  position: relative;
  height: 210px;
  background: var(--gray-100);
  overflow: hidden;
  border-bottom: 1px solid var(--gray-200);
  flex-shrink: 0;
}
.proj-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}
.proj-card:hover .proj-img img { transform: scale(1.05); }
.proj-img.no-img {
  display: flex; align-items: center; justify-content: center;
  background: var(--gray-100);
}

.proj-img-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  transition: opacity 0.25s;
}
.proj-card:hover .proj-img-overlay { opacity: 1; }
.proj-overlay-btn {
  font-size: 0.88rem;
  font-weight: 600;
  background: #ffffff;
  color: #0a0a0a;
  padding: 10px 20px;
  border-radius: 8px;
  transition: background 0.2s;
}
.proj-overlay-btn:hover { background: #e2e2e2; }

.proj-body {
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}
.proj-tags {
  display: flex; gap: 6px; flex-wrap: wrap;
}
.proj-tags span {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid var(--gray-200);
  padding: 3px 10px;
  border-radius: 100px;
  color: var(--gray-600);
}
.proj-body h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  margin-top: 2px;
}
.proj-body p {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.6;
  flex: 1;
}
.proj-link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--black);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
  transition: gap 0.2s;
}
.proj-link:hover { gap: 8px; }
.proj-link span { transition: transform 0.2s; }

/* Card placeholder */
.proj-placeholder {
  border-style: dashed;
  min-height: 380px;
}
.proj-placeholder:hover { transform: none; border-color: var(--gray-400); }
.proj-placeholder-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 10px;
  padding: 40px 24px;
  height: 100%;
  color: var(--gray-400);
}
.placeholder-icon {
  width: 52px; height: 52px;
  border: 1px dashed var(--gray-200);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 4px;
}
.proj-placeholder h3 { font-size: 1rem; font-weight: 600; color: var(--gray-600); }
.proj-placeholder p { font-size: 0.875rem; }

/* Controles do carrossel */
.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 28px;
  padding: 0 4px;
}

.carousel-dots {
  display: flex;
  gap: 8px;
  align-items: center;
}
.carousel-dot {
  width: 10px; height: 10px;
  border-radius: 100px;
  background: var(--gray-100);
  border: 2px solid var(--gray-400);
  cursor: pointer;
  padding: 0;
  transition: background 0.25s, border-color 0.25s, width 0.35s var(--spring), transform 0.2s var(--spring);
}
.carousel-dot:hover {
  background: var(--gray-400);
  border-color: var(--gray-600);
  transform: scale(1.2);
}
.carousel-dot.active {
  background: var(--black);
  border-color: var(--black);
  width: 28px;
}

.carousel-arrows { display: flex; gap: 10px; }
.carr-btn {
  width: 48px; height: 48px;
  border: 2px solid var(--gray-600);
  border-radius: 12px;
  background: var(--white);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-600);
  transition: border-color 0.2s, color 0.2s, background 0.2s, transform 0.2s var(--spring);
}
.carr-btn:hover {
  border-color: var(--black);
  color: var(--white);
  background: var(--black);
  transform: scale(1.08);
}
.carr-btn:disabled { opacity: 0.25; pointer-events: none; }

.carousel-counter {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gray-400);
  letter-spacing: 0.04em;
  min-width: 40px;
  text-align: center;
}
.carousel-counter span { color: var(--black); }

/* ===========================================
   SKILLS
=========================================== */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  border: 1px solid var(--gray-200);
  border-radius: 16px;
  overflow: hidden;
  background: var(--gray-200);
}
.skill-col {
  background: var(--white);
  padding: 28px 24px;
}
.skill-col-title {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-400);
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--gray-200);
}
.skill-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.skill-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-800);
  transition: background 0.15s;
  cursor: default;
}
.skill-list li:hover { background: var(--gray-100); }
.skill-list li i { font-size: 1.2rem; width: 22px; text-align: center; }
.skill-icon-img { width: 22px; height: 22px; object-fit: contain; flex-shrink: 0; }
.dark-invert { filter: invert(1); }

/* Badge de ícone texto */
.icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  border-radius: 4px;
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--gray-600);
  flex-shrink: 0;
}

/* ===========================================
   CERTIFICADOS
=========================================== */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.cert-card {
  padding: 24px;
  border: 1px solid var(--gray-200);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.2s, transform 0.3s var(--spring);
}
.cert-card:hover { border-color: var(--black); transform: translateY(-4px); }
.cert-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.cert-hours {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--gray-600);
  border: 1px solid var(--gray-200);
  padding: 3px 10px;
  border-radius: 100px;
  background: var(--gray-50);
}
.cert-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}
.cert-school {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-400);
}
.cert-desc {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.5;
  flex: 1;
}
.cert-bar {
  height: 3px;
  background: var(--gray-200);
  border-radius: 10px;
  margin-top: 12px;
  overflow: hidden;
}
.cert-fill {
  height: 100%;
  background: var(--black);
  border-radius: 10px;
  transition: width 1.2s var(--ease);
}

/* ===========================================
   FOOTER
=========================================== */
.footer {
  border-top: 1px solid var(--gray-200);
  background: #050505;
  color: #ffffff;
}
.footer-wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 72px 28px 40px;
  display: flex;
  flex-direction: column;
  gap: 48px;
}
.footer-cta {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.footer-cta h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.footer-cta p {
  color: rgba(255,255,255,0.6);
  font-size: 1rem;
  margin-bottom: 8px;
}
.footer-cta .btn-primary {
  background: #ffffff;
  color: #0a0a0a;
}
.footer-cta .btn-primary:hover { opacity: 0.9; }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
}
.footer-links {
  display: flex;
  gap: 20px;
}
.footer-links a {
  color: rgba(255,255,255,0.6);
  transition: color 0.2s;
  font-size: 0.85rem;
}
.footer-links a:hover { color: var(--white); }

/* ===========================================
   SCROLL REVEAL
=========================================== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}
.revealed { opacity: 1; transform: none; }

/* ===========================================
   BOTÃO TOPO
=========================================== */
#btnTopo {
  display: none;
  position: fixed;
  bottom: 24px; right: 24px;
  width: 44px; height: 44px;
  background: var(--black);
  color: var(--white);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  z-index: 99;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s, transform 0.2s var(--spring);
}
#btnTopo:hover { opacity: 0.8; transform: translateY(-2px); }

/* ===========================================
   RESPONSIVO
=========================================== */
@media (max-width: 900px) {
  .hero-wrap { flex-direction: column-reverse; text-align: center; }
  .hero-badge { margin: 0 auto 28px; }
  .hero-desc { max-width: 100%; }
  .hero-actions { justify-content: center; }
  .hero-photo-wrap { width: 220px; height: 260px; }
  .hero-stats { flex-wrap: wrap; justify-content: center; gap: 20px; }
  .stat-sep { display: none; }
  .about-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: repeat(2, 1fr); }
  .certs-grid { grid-template-columns: 1fr; }
  .carousel-outer { padding-right: 28px; }
  .proj-card { flex: 0 0 300px; }
}

@media (max-width: 600px) {
  .nav-links { display: none; }
  .nav-wrap { padding: 0 20px; }
  .hero { padding: 90px 20px 48px; }
  .section-wrap { padding: 60px 20px; }
  .skills-grid { grid-template-columns: 1fr; }
  .about-cards { grid-template-columns: 1fr; }
  .carousel-outer { padding: 0 20px 60px; }
  .proj-card { flex: 0 0 280px; }
}