/* Import Font */
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600&display=swap");

/* Reset & base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

/* Body */
body {
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-image: url("../img/background.jpg");
}

/* Navbar */
nav {
  width: 100%;
  height: 10vh;
  position: sticky;
}

.nav-container {
  display: flex;
  justify-content: space-around;
  align-items: center;
  width: 100%;
  height: 100%;
}

.logo {
  color: white;
  font-size: 2rem;
  font-weight: bold;
}

.logo span {
  color: rgb(58, 211, 3);
  text-shadow: 0 0 10px rgb(58, 211, 3);
}

.hamburg,
.cancel {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: clamp(2.5rem, 0.5rem + 5vw, 3rem);
  color: white;
  cursor: pointer;
  display: none;
}

/* Mobile */
@media (max-width: 884px) {
  .hamburg { display: block; }
  .cancel { display: none; }
}

/* Menu open */
.menu-open .hamburg { display: none; }
.menu-open .cancel { display: block; }

/* Navbar links */
.nav-container .links {
  display: flex;
}

.nav-container .links a {
  margin: 0 20px;
  font-size: 1.2rem;
  color: white;
  text-decoration: none;
  font-weight: 550;
  transition: 0.3s linear;
}

.nav-container .links a:hover,
.nav-container .links .active {
  color: rgb(58, 211, 3);
  border-bottom: 2px solid rgb(58, 211, 3);
}

/* Dropdown (mobile) */
.dropdown {
  position: absolute;
  top: 60px;
  right: 10px;
  width: 220px;
  background: rgba(0, 0, 0, 0.9);
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
  transform: translateY(-500px);
  transition: transform 0.3s ease;
  z-index: 1000;
}

.dropdown .links {
  display: flex;
  flex-direction: column;
}

.dropdown .links a {
  display: block;
  padding: 12px 20px;
  color: white;
  text-decoration: none;
  font-size: 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  transition: background 0.2s linear;
}

.dropdown .links a:last-child {
  border-bottom: none;
}

.dropdown .links a:hover {
  background-color: rgb(58, 211, 3);
  color: black;
}

/* Dropdown submenu (desktop) */
.link.has-dropdown {
  position: relative;
}

.link.has-dropdown:hover .dropdown-content {
  display: block;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: rgba(0, 0, 0, 0.9);
  min-width: 150px;
  border-radius: 0 0 5px 5px;
  z-index: 500;
}

.dropdown-content a {
  display: block;
  color: white;
  padding: 10px;
  text-decoration: none;
  font-size: 0.9rem;
}

.dropdown-content a:hover {
  background-color: rgb(135, 151, 129);
}

/* Main section */
section {
  width: 100%;
  height: 90vh;
}

.main-container {
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  width: 100%;
  height: 100%;
}

.main-container .content {
  width: 40%;
  color: white;
  min-height: 100px;
}

/* Text & typewriter */
.content h1 {
  font-size: clamp(1rem, 1rem + 5vw, 1.8rem);
}

.content h1 span,
.typewriter span {
  color: rgb(58, 211, 3);
  text-shadow: 0 0 10px rgb(58, 211, 3);
  font-weight: 700;
}

.content .typewriter {
  font-size: clamp(1rem, 1rem + 5vw, 2.5rem);
  font-weight: 700;
}

.content p {
  font-size: clamp(0, 4rem, 0.2rem + 9vw, 1rem);
  margin: 10px 0;
}

/* Social icons */
.social-links i {
  flex: 0 0 auto;         /* biar ukuran tetap, tidak mengecil */
  width: 2.8rem;
  height: 2.8rem;
  border: 0.2rem solid rgb(58, 211, 3);
  border-radius: 50%;
  color: rgb(58, 211, 3);
  background-color: transparent;
  font-size: 1.4rem;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  transition: all 0.2s ease;
}

.social-links i:hover {
 transform: scale(1.3);
  color: black;
  background-color: rgb(58, 211, 3);
  filter: drop-shadow(0 0 8px rgb(58, 211, 3));
}

/* Button */
.content button {
  width: 50%;
  height: 6vh;
  margin: 30px;
  font-size: 120%;
  font-weight: 700;
  border-radius: 5px;
  background-color: rgb(18, 171, 0);
  color: white;
  border: none;
  outline: none;
  transition: 0.2s linear;
}

.content button:hover {
  scale: 1.1;
  color: rgb(58, 211, 3);
  background-color: transparent;
  border: 2px solid rgb(58, 211, 3);
  box-shadow: 0 0 40px 5px rgb(58, 211, 3);
}

/* Image */
.main-container .image {
  width: 50vh;
  height: 50vh;
  overflow: hidden;
  border-radius: 100%;
  box-shadow: 0 0 50px rgb(58, 211, 3);
}

.main-container .image img {
  width: 100%;
  height: 100%;
}

.main-container .image:hover {
  animation: animate 1.5s ease-in-out infinite;
}

@keyframes animate {
  0% { scale: 1; }
  50% { scale: 1.05; }
  100% { scale: 1; }
}

/* Responsive */
@media (max-width: 884px) {
  nav .logo {
    position: absolute;
    top: 16px;
    left: 15px;
    font-size: 1.5rem;
  }
  .nav-container .links { display: none; }
  .hamburg, .cancel { display: block; }
  .main-container {
    flex-direction: column-reverse;
  }
  .main-container .content { width: 80%; }
  .social-links i {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.5rem;
  }
  .main-container .image {
    width: 50%;
    height: 80%;
    z-index: -1;
  }
}

@media (max-width: 440px) {
  .main-container .image {
    width: 60%;
    height: 30%;
  }
  .main-container .content {
    width: 80%;
  }
  .main-container button {
    margin-top: 15px;
  }
}

/* Footer */
.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  padding: 8px 0;
  z-index: 100;
}

.footer-social {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
}

.footer-social a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 2.8rem;
  height: 2.8rem;
  border: 2px solid rgb(58, 211, 3);
  border-radius: 50%;
  color: rgb(58, 211, 3);
  background-color: transparent;
  font-size: 1.4rem;
  transition: all 0.2s ease;
}

.footer-social a:hover {
  transform: scale(1.3);
  color: black;
  background-color: rgb(58, 211, 3);
  filter: drop-shadow(0 0 8px rgb(58, 211, 3));
}


.social-links a {
  color: #000;
  text-decoration: none;
  margin: 0 5px;
  font-size: 1.5rem;
  transition: color 0.3s;
}

.social-links a:hover {
  color: #007bff;
}

@media (max-width: 480px) {
  .footer-content {
    gap: 10px;
  }
  .social-links a {
    font-size: 1.3rem;
    margin: 0 4px;
  }
}

/* Halaman arduino.html */
main {
  max-width: 1000px;
  margin: 80px auto 60px;
  padding: 0 20px;
}

.intro h1 {
  font-size: 28px;
  margin-bottom: 10px;
}

.intro p {
  font-size: 16px;
  color: #555;
}

.projects {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 20px;
}

.project-card {
  background: rgba(255,255,255,0.8);
  backdrop-filter: blur(3px);
  border: 1px solid #ccc;
  border-radius: 10px;
  padding: 15px;
  flex: 1 1 250px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  transition: transform 0.3s;
}

.project-card:hover {
  transform: translateY(-5px);
}

