/* ===== SIDEBAR DESKTOP ===== */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 220px;
  height: 100vh;
  background: rgba(10, 15, 25, 0.55);
  border-right: 1px solid rgba(77, 166, 255, 0.15);
  display: flex;
  flex-direction: column;
  z-index: 1000;
  box-shadow: 0 0 40px rgba(77, 166, 255, 0.05);
}

nav {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 30px 20px;
}

.donut-container {
  position: absolute;
  bottom: 20px;
  right: 10px;
  opacity: 0.55;
  pointer-events: none;
  user-select: none;
}

/* LOGO */
.logo {
  color: #4da6ff;
  font-weight: bold;
  font-size: 1.3rem;
  margin-bottom: 40px;
}

/* LINKS */
.nav-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* LINKS STYLE */
.nav-links a {
  text-decoration: none;
  color: #8b949e;
  font-size: 0.95rem;
  transition: all 0.25s ease;
  position: relative;
  padding-left: 12px;
}

/* TERMINAL EFFECT */
.nav-links a::before {
  content: ">";
  position: absolute;
  left: 0;
  color: #4da6ff;
  opacity: 0;
  transition: 0.2s;
}

/* HOVER */
.nav-links a:hover {
  color: #e6edf3;
  transform: translateX(5px);
}

.nav-links a:hover::before {
  opacity: 1;
}

/* ACTIVE */
.nav-links a.active {
  color: #4da6ff;
}

/* ===== MOBILE ===== */
.menu-icon {
  display: none;
  font-size: 1.8rem;
  color: #e6edf3;
  cursor: pointer;
}

#menu-toggle {
  display: none;
}

/* OVERLAY */
.overlay {
  display: none;
}



/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {

   .donut-container {
    display: none;
  }

  /* HEADER pasa a TOP BAR */
  header {
    width: 100%;
    height: 60px;
    border-right: none;
    border-bottom: 1px solid #1c2535;
  }

  nav {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
  }

  .logo {
    margin: 0;
  }

  /* ICON */
  .menu-icon {
    display: block;
    z-index: 1002;
  }

  /* MENU PANEL (🔥 clave) */
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100vh;
    background: rgba(10, 15, 25, 0.75);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 80px 25px;
    gap: 25px;
    transition: right 0.3s ease;
    z-index: 1001;
    border-left: 1px solid #1c2535;
  }

  /* OPEN MENU */
  #menu-toggle:checked + .menu-icon + .nav-links {
    right: 0;
  }

  /* OVERLAY (🔥 UX PRO) */
  .overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(3px);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: 0.3s;
  }

  #menu-toggle:checked ~ .overlay {
    opacity: 1;
    pointer-events: all;
  }

  /* BODY FIX */
  body {
    margin-left: 0;
  }
}

header::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 1px;
  height: 100%;
  background: linear-gradient(
    transparent,
    rgba(77, 166, 255, 0.4),
    transparent
  );
}