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

/* CSS Variables / Theme */

:root {
  --bg: #000;
  --text: #fff;
  --primary: #16e016;
  --primary-dark: #0ca00c; /* darker shade for hover states */
  --nav-bg: #121217;
  --cl-yellow: #f1c40f;
  --btn-bg: #16e016;
  --btn-text: #fff;
  --btn-hover-bg: #0ca00c;
  --btn-hover-text: #000;
  --shadow-color: rgba(255, 255, 255, 0.2);
}

body.light {
  --bg: hsl(0, 1%, 90%);
  --text: #111;
  --nav-bg: #ffffff;
  --btn-bg: #16e016;
  --btn-text: #111;
  --btn-hover-bg: #0ca00c;
  --btn-hover-text: #fff;
  --shadow-color: rgba(0, 0, 0, 0.2);
}

/* Global Reset & Base Styles */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
  scroll-behavior: smooth;
}

body {
  width: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "Poppins", sans-serif;
  padding-top: 80px;
  transition:
    background-color 0.3s ease,
    color 0.3s ease;
}

/* Header & Logo */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1rem 10%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--nav-bg);
  z-index: 1000;
  transition: background-color 0.3s ease;
}

.logo {
  font-size: 3rem;
  font-weight: 800;
  color: var(--primary);
  cursor: pointer;
  transition:
    transform 0.5s ease,
    opacity 0.3s ease;
}

.logo:hover {
  transform: scale(1.2);
}

/* Desktop Navigation */
.navbar ul {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 4rem;
}

.navbar a {
  color: var(--text);
  text-decoration: none;
  font-size: 1.6rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.navbar a:hover,
.navbar a.active {
  color: var(--primary);
  transform: scale(1.1);
}

/* Icons: Menu & Theme/ */
#theme-toggle {
  font-size: 2.5rem;
  color: var(--text);
  margin-left: 2rem;
  transition:
    transform 0.3s ease,
    color 0.3s ease;
  cursor: pointer;
}

#theme-toggle:hover {
  transform: rotate(20deg) scale(1.1);
  color: var(--primary);
}

#menu-btn {
  position: relative;
  width: 30px;
  height: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  color: var(--text);
}

#menu-btn span {
  display: block;
  height: 3px;
  background: currentColor;
  border-radius: 2px;
  transition: all 0.4s ease;
  transform-origin: center;
}

/* Mobile Navigation */
@media (max-width: 990px) {
  /* Hamburger → X */
  #menu-btn.open span:nth-child(1) {
    transform: rotate(45deg) translateY(9px);
  }
  #menu-btn.open span:nth-child(2) {
    opacity: 0;
  }
  #menu-btn.open span:nth-child(3) {
    transform: rotate(-45deg) translateY(-9px);
  }

  /* Mobile navbar */
  .navbar {
    position: absolute;
    top: 100%;
    right: 0;
    display: none;
    width: 250px;
    background: var(--nav-bg);
    border-left: 3px solid var(--primary);
    border-bottom: 3px solid var(--primary);
    border-radius: 0.8rem;
    padding: 1rem;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
  }

  .navbar.active {
    display: block;
  }

  .navbar ul {
    flex-direction: column;
    gap: 0;
  }

  .navbar li {
    margin: 1rem 0;
  }

  .navbar a {
    display: block;
    padding: 1rem;
    font-size: 2rem;
  }

  .navbar a:hover,
  .navbar a.active {
    border-radius: 0.5rem;
    border-bottom: 0.5rem solid var(--primary);
  }
}

/* Reveal Animations */
.reveal {
  opacity: 0;
  transform: translateY(60px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Sections & Layout */
section {
  min-height: 100vh;
  padding: 5rem 10%;
}

/* Profile layout */
.profile {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4rem;
}

@media (max-width: 1000px) {
  .profile {
    flex-direction: column;
    text-align: center;
  }
}

/* Headings */
.profile h1 {
  margin-top: 5rem;
  font-size: 6rem;
  font-weight: 700;
  line-height: 1.2;
}

/* Text blocks */
.profile-section {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.profile-section h3 {
  font-size: 1.8rem;
  margin-bottom: 4rem;
  font-weight: 700;
}

.profile-section p {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  word-spacing: 0.2rem;
  column-count: 2;
  column-width: 20rem;
  column-gap: 5rem;
}

@media (max-width: 500px) {
  .profile-section p {
    column-count: 1;
  }
}

/* Profile Images & Videos */
.profile img {
  width: 300px;
  max-width: 90%;
  border-radius: 70%;
  box-shadow: 0 0 0 1.5px var(--primary);
  transition:
    transform 0.2s linear,
    box-shadow 0.3s ease;
}

.profile img:hover {
  box-shadow: 0 0 0 3px var(--primary);
}

.htmlvideo {
  width: 300px;
  margin: 3rem;
  border: 1.2px solid var(--primary);
  border-radius: 8px;
}

@media (max-width: 900px) {
  .profile img {
    width: 70%;
    max-width: 70vw;
    margin-top: 4rem;
  }

  .htmlvideo {
    width: 90%;
  }
}

/* Social Icons*/
.social-icons {
  display: flex;
  justify-content: space-evenly;
  gap: 4rem;
  align-items: center;
  font-size: 3rem;
  margin: 8rem 0 4rem;
}

.social-icons a {
  color: var(--text);
  transition:
    transform 0.3s ease,
    color 0.3s ease;
}

.social-icons a:hover {
  color: var(--cl-yellow);
  transform: scale(1.5);
}

/*Buttons - FIXED COLOR CONFLICT*/
.btn {
  display: inline-block;
  padding: 2rem;
  background: var(--btn-bg);
  border-radius: 3rem;
  font-size: 2rem;
  letter-spacing: 0.3rem;
  font-weight: 900;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--btn-text);
  border: none;
  box-shadow: 0 2px 10px var(--shadow-color);
}

.btn:hover {
  transform: scale(1.03);
  background: var(--btn-hover-bg);
  color: var(--btn-hover-text);
  box-shadow: 0 4px 15px var(--shadow-color);
}

.btn:focus {
  outline: 2px solid var(--primary);
  outline-offset: 4px;
}

/*Typing Effect*/
.typing-text {
  font-size: 3rem;
  font-weight: 600;
  min-width: 250px;
}

.typing-text span {
  position: relative;
  color: var(--primary);
}

.typing-text span::after {
  content: "";
  position: absolute;
  right: -5px;
  width: 2px;
  height: 100%;
  background: var(--primary);
  animation: blink 1s infinite;
}

@keyframes blink {
  0%,
  50%,
  100% {
    opacity: 1;
  }
  25%,
  75% {
    opacity: 0;
  }
}

/*Additional Theme-Safe Elements*/
video {
  background: var(--nav-bg);
}

::selection {
  background: var(--primary);
  color: var(--bg);
}
