/* --- Reset e base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #ffffff;
  font-family: "IBM Plex Mono", "Space Mono", "Consolas", monospace;
  color: #333333;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* --- Dark mode --- */
html[data-theme="dark"] body {
  background: #0d0d0d;
  color: #e0e0e0;
}

html[data-theme="dark"] .hero {
  background: linear-gradient(
    to bottom,
    rgba(13, 13, 13, 0.4) 0%,
    rgba(13, 13, 13, 0.6) 40%,
    rgba(13, 13, 13, 0.6) 60%,
    rgba(13, 13, 13, 0.4) 100%
  );
}

html[data-theme="dark"] .title {
  color: #f5f5f5;
}

html[data-theme="dark"] .description {
  color: #b0b0b0;
}

html[data-theme="dark"] .social-link {
  color: #c0c0c0;
}

html[data-theme="dark"] .social-link:hover {
  color: #ffffff;
}

/* --- Botão alternar tema --- */
.theme-toggle {
  position: fixed;
  top: 1.25rem;
  right: 1.25rem;
  z-index: 10;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.08);
  color: #222;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease;
}

.theme-toggle:hover {
  background: rgba(0, 0, 0, 0.12);
  transform: scale(1.05);
}

.theme-toggle .theme-icon {
  position: absolute;
  font-size: 1.2rem;
}

.theme-toggle .theme-icon-moon {
  opacity: 0;
}

.theme-toggle.is-dark .theme-icon-sun {
  opacity: 0;
}

.theme-toggle.is-dark .theme-icon-moon {
  opacity: 1;
}

html[data-theme="dark"] .theme-toggle {
  background: rgba(255, 255, 255, 0.12);
  color: #e0e0e0;
}

html[data-theme="dark"] .theme-toggle:hover {
  background: rgba(255, 255, 255, 0.18);
}

/* --- Canvas de partículas (fundo fixo) --- */
#particle-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* --- Conteúdo principal (acima do canvas) --- */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem;
  /* Leve fundo semi-transparente para legibilidade (deixa o canvas visível) */
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.35) 0%,
    rgba(255, 255, 255, 0.5) 40%,
    rgba(255, 255, 255, 0.5) 60%,
    rgba(255, 255, 255, 0.35) 100%
  );
  backdrop-filter: blur(3px);
}

.hero-content {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0;
  max-width: 720px;
  /* Ligeiramente abaixo do meio vertical */
  margin-top: 4vh;
}

/* --- Textos e ícones --- */
.hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
}

.title {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  color: #111111;
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.name {
  font-family: "IBM Plex Mono", "Space Mono", monospace;
  font-size: 0.95rem;
  font-weight: 500;
  color: #555555;
  margin: 0;
}

.description {
  font-family: "IBM Plex Mono", "Space Mono", monospace;
  font-size: 0.9rem;
  font-weight: 400;
  color: #666666;
  margin: 0 0 0.75rem 0;
  max-width: 32em;
  line-height: 1.5;
}

/* --- Ícones de redes sociais --- */
.social-links {
  display: flex;
  flex-direction: row;
  gap: 1rem;
  margin-top: 0.15rem;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: #222222;
  text-decoration: none;
  transition: transform 0.2s ease, color 0.2s ease;
}

.social-link:hover {
  transform: scale(1.15);
  color: #000000;
}

.social-link i {
  font-size: 1.25rem;
}

/* --- Responsivo: mobile --- */
@media (max-width: 640px) {
  .hero-content {
    flex-direction: column;
    text-align: center;
    margin-top: 2vh;
  }

  .hero-text {
    align-items: center;
  }

  .social-links {
    justify-content: center;
  }
}
