/* =========================================
   CORE VARIABLES & THEME ENGINE
   ========================================= */
:root {
  --bg-color: #ffffff;
  --navbar-bg: #1e1e24;
  --navbar-text: #ffffff;
  --accent-green: #2bbd0f;
  --text-main: #333333;
}

html.dark-mode {
  --bg-color: #121215;
  --navbar-bg: #0a0a0c;
  --accent-green: #39ff14;
  --text-main: #f4f4f4;
}

body {
  margin: 0;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  transition:
    background-color 0.3s ease,
    color 0.3s ease;
}

/* =========================================
   NAVBAR LAYOUT
   ========================================= */
.llama-header {
  background-color: var(--navbar-bg);
  padding: 16px 24px;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: background-color 0.3s ease;
}

.llama-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--accent-green);
  text-decoration: none;
  font-size: 1.5rem;
  font-weight: bold;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-links {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 40px;
  align-items: center;
}

.nav-links a {
  color: var(--navbar-text);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--accent-green);
}

/* =========================================
   THEME TOGGLE BUTTON
   ========================================= */
.theme-btn {
  background: transparent;
  color: var(--navbar-text);
  border: 1px solid var(--accent-green);
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 8px;
  transition: all 0.2s ease;
}

.theme-btn:hover {
  background-color: var(--accent-green);
  color: #1e1e24;
}

/* Icon Swapping Logic */
.sun-icon {
  display: none;
}
.moon-icon {
  display: block;
}

html.dark-mode .sun-icon {
  display: block;
}
html.dark-mode .moon-icon {
  display: none;
}

/* =========================================
   MOBILE HAMBURGER & OFF-CANVAS MENU
   ========================================= */
.hamburger {
  display: none;
  cursor: pointer;
  background: transparent;
  border: none;
  gap: 5px;
  flex-direction: column;
}

.hamburger .line {
  width: 25px;
  height: 3px;
  background-color: var(--navbar-text);
  border-radius: 2px;
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .nav-actions {
    gap: 16px;
  }

  .hamburger {
    display: flex;
    position: relative;
    z-index: 101;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 60%;
    background-color: var(--navbar-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 100px;
    transform: translateX(100%);
    transition: transform 0.3s ease-in;
    z-index: 100;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.2);
  }

  .nav-links.nav-active {
    transform: translateX(0%);
  }
}

/* Hamburger "X" Animation */
.hamburger.is-active .line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}
.hamburger.is-active .line:nth-child(2) {
  opacity: 0;
}
.hamburger.is-active .line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}
