/* CSS RESET  */

*,
*::before,
*::after {
  box-sizing: border-box;
}
* {
  margin: 0;
}
@media (prefers-reduced-motion: no-preference) {
  html {
    interpolate-size: allow-keywords;
    scroll-behavior: smooth;
  }
}
body {
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}
input,
button,
textarea,
select {
  font: inherit;
}
p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}
p {
  text-wrap: pretty;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
}
#root,
#__next {
  isolation: isolate;
}

/* END OF RESET */

/* GENERAL STYLES */
body {
  font-family: "Orbitron", sans-serif;
  color: #fff;
  background-color: #000;
}

section {
  background-color: #0d0d0d;
  padding: 4rem 2rem;
}

h2 {
  text-align: center;
  margin-bottom: 2rem;
  font-size: 2.5rem;
  color: #00ff00;
}

/* HEADER AND NAV */

header {
  background-color: #000;
  position: sticky;
  overflow: hidden;
  padding: 1rem;
  top: 0;
  z-index: 1000;
}

nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
}

nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 2rem;
  padding-left: 0;
}

nav a {
  color: #fff;
  text-decoration: none;
  transition: color 0.3s ease;
  font-weight: 600;
}

nav a:hover {
  color: #00ff00;
}

.flags {
  display: flex;
  gap: 0.5rem;
}

.flag-us,
.flag-br {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  border-radius: 50%;
  padding: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.flag-br img,
.flag-us img {
  min-width: 24px;
  min-height: 24px;
}

/* HERO SECTION  */

#hero {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.hero-content h1 {
  font-size: 4rem;
  margin-bottom: 1rem;
}

.hero-content p {
  font-size: 1.5rem;
  color: #00cc00;
}

.name {
  color: #00ff00;
  transition: all 0.3s ease-in-out;
}

.name:hover {
  text-shadow: 0 0 20px rgba(0, 255, 0, 0.7), 0 0 20px rgba(0, 255, 0, 0.5),
    0 0 30px rgba(0, 255, 0, 0.3);
}

/* ABOUT SECTION */
#about {
  max-width: 900px;
  margin: 1rem auto;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  text-align: center;
  scroll-margin-top: 6rem;
}

.tech-carousel-container h3 {
  margin-bottom: 2rem;
}

.about-container {
  margin-bottom: 3rem;
}

.bio {
  font-family: "Exo 2", sans-serif;
  max-width: 700px;
  margin: 0 auto;
  font-size: 1.2rem;
}

.profile-pic {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  margin: 0 auto 2rem;
  object-fit: cover;
  box-shadow: 0 2px 10px rgba(0, 255, 0, 0.4);
}

/* TECH CAROUSEL */

.tech-carousel-container {
  overflow: hidden;
  padding: 2rem 0;
  position: relative;
  width: 100%;
}
.tech-carousel-container:before,
.tech-carousel-container:after {
  content: "";
  position: absolute;
  top: 0;
  width: 100px;
  height: 100%;
  z-index: 2;
}
.tech-carousel-container:before {
  left: 0;
  background: linear-gradient(to right, #0d0d0d, transparent);
}
.tech-carousel-container:after {
  right: 0;
  background: linear-gradient(to left, #0d0d0d, transparent);
}
.tech-carousel {
  display: flex;
  width: fit-content;
  animation: scroll 30s linear infinite;
}
.tech-icons {
  display: flex;
  gap: 3rem;
  align-items: center;
}
.tech-icons i {
  font-size: 4rem;
  color: #cccccc;
  transition: transform 0.3s ease, color 0.3s ease;
}
.tech-icons i:hover {
  transform: scale(1.2);
  color: #00ff00;
}
@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* PROJECTS SECTION */
#projects {
  max-width: 1200px;
  margin: 0 auto;
  margin-bottom: 1rem;
  border-radius: 8px;
  scroll-margin-top: 5rem;
}

.project {
  background-color: #1a1a1a;
  padding: 1rem 2rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  align-items: stretch;
}

.project-title {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
}
.project-title h3 {
  font-size: 1.5rem;
}

.project-links-container {
  display: flex;
  gap: 0.5rem;
}

.project-title i {
  font-size: 2rem;
  color: #00ff00;
}

.project-description {
  flex-direction: column;
}

.project-description .more-text {
  font-family: "Exo 2", sans-serif;
}

.more-text {
  display: none;
}

.read-more-btn {
  background-color: #00ff00;
  color: #000000;
  border: none;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  margin-top: 1rem;
  border-radius: 5px;
  transition: background-color 0.3s ease, transform 0.3s ease;
}
.read-more-btn:hover {
  background-color: #00cc00;
  transform: translateY(-2px);
}

/* CAROUSEL */
.carousel {
  position: relative;
  width: 500px;
  max-width: 100%;
  height: fit-content;
  margin: auto;
  overflow: hidden;
  border-radius: 8px;
  transition: height 200ms ease;
  box-shadow: 0 2px 12px rgba(0, 255, 0, 0.15);
  grid-column: 2;
  grid-row: 1 / -1;
}

.carousel-inner {
  display: grid;
}

.carousel-item {
  grid-area: 1 / 1 / -1 / -1;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s ease-in-out, visibility 0.5s ease-in-out;
  width: 100%;
}

.carousel-item.active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

.carousel-item img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.carousel-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: 1px solid #00ff00;
  background: rgba(0, 0, 0, 0.6);
  color: #00ff00;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 2;
}

.carousel-control:hover {
  background: rgba(0, 0, 0, 0.85);
}

.carousel-control.prev {
  left: 8px;
}

.carousel-control.next {
  right: 8px;
}

/* CONTACT SECTION */

#contact {
  max-width: 1200px;
  margin: 0 auto;
  border-radius: 8px;
  scroll-margin-top: 5rem;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.contact-card {
  background-color: #111;
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid rgba(0, 255, 0, 0.15);
  box-shadow: 0 0 20px rgba(0, 255, 0, 0.05);
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  background: #0d0d0d;
  border: 1px solid #333333;
  border-radius: 6px;
  color: #ffffff;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.1s;
  font-family: "Exo 2", sans-serif;
}

input::placeholder,
textarea::placeholder {
  font-family: "Orbitron", sans-serif;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: #00ff00;
  box-shadow: 0 0 0 3px rgba(0, 255, 0, 0.15);
}

.submit-btn {
  background-color: #00ff00;
  color: #000;
  padding: 0.8rem 1.4rem;
  cursor: pointer;
  border: none;
  border-radius: 6px;
  margin-top: 1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  transition: background-color 0.3s, transform 0.2s;
}

.submit-btn:hover {
  background-color: #00cc00;
  transform: translateY(-2px);
}

.form-note {
  color: #aaa;
  margin-top: 0.75rem;
}

.mail-link {
  color: #00ff00;
  text-decoration: none;
}

.social-link {
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: #111111;
  padding: 1.25rem 1.5rem;
  border-radius: 10px;
  border: 1px solid rgba(0, 255, 0, 0.15);
  text-decoration: none;
  transition: transform 0.2s, border-color 0.2s;
}

.social-link:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 255, 0, 0.5);
}

.contact-socials {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.contact-socials i {
  font-size: 2rem;
  color: #00ff00;
}

/* FOOTER SECTION  */

footer {
  background-color: #0d0d0d;
  margin-top: 2rem;
  padding: 1rem;
  text-align: center;
}

/* RESPONSIVE STYLES */
@media (max-width: 1024px) {
  .project {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    gap: 2rem;
    overflow: hidden;
  }
  .project .carousel {
    grid-column: auto;
    grid-row: auto;
    width: 100%;
    max-width: 500px;
  }

  .project-title,
  .project-description {
    margin: 0 auto;
    display: flex;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .hero-content h1 {
    font-size: 3rem;
  }
  .hero-content p {
    font-size: 1.2rem;
  }
  nav ul {
    gap: 1.5rem;
  }
  section {
    padding: 3rem 1rem;
  }
}

@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 2.5rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
  nav ul {
    gap: 0.5rem;
  }
  nav {
    gap: 0.5rem;
  }
  nav a {
    font-size: 0.9rem;
  }
  .flags {
    gap: 0;
  }
  .bio {
    font-size: 1rem;
  }
  .tech-icons i {
    font-size: 3rem;
  }
  .contact-card {
    padding: 1.5rem;
    overflow: hidden;
  }
}

/* ANIMACAO HERO SECTION  */
#hero {
  position: relative;
  overflow: hidden;
}

#hero::before,
#hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

#hero::before {
  opacity: 0.8;
  background-image: radial-gradient(
      rgba(255, 255, 255, 0.45) 1px,
      transparent 1px
    ),
    radial-gradient(rgba(0, 255, 0, 0.25) 2px, transparent 2px),
    radial-gradient(rgba(255, 255, 255, 0.25) 4px, transparent 4px);
  background-size: 140px 140px, 220px 220px, 320px 320px;
  background-position: 0 0, 50px 80px, 100px 20px;
  animation: dust-shift-a 120s linear infinite;
}

#hero::after {
  opacity: 0.25;
  background-image: radial-gradient(
      rgba(255, 255, 255, 0.25) 2px,
      transparent 2px
    ),
    radial-gradient(rgba(0, 255, 0, 0.15) 3px, transparent 3px);
  background-size: 180px 180px, 260px 260px;
  background-position: 20px 40px, 60px 0;
  animation: dust-shift-b 180s linear infinite;
}

.hero-content {
  position: relative;
  z-index: 1;
}

@keyframes dust-shift-a {
  from {
    background-position: 0 0, 50px 80px, 100px 20px;
  }
  to {
    background-position: 1000px 600px, -800px 700px, 600px -900px;
  }
}

@keyframes dust-shift-b {
  from {
    background-position: 20px 40px, 60px 0;
  }
  to {
    background-position: -900px 700px, 800px -600px;
  }
}
