:root {
  /* Fondo base más oscuro y elegante */
  --bg-color: #050505;
  --text-color: #ffffff;
  --primary-color: #ffffff;
  --primary-text-color: #000000;
  --secondary-text-color: #cccccc;
  --logo-color: #ffffff;
  --glow-color: #fff;
  --main-font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
}

body.light-theme {
  --bg-color: #fcfcfc;
  --text-color: #1c1e21;
  --primary-color: #000000;
  --primary-text-color: #ffffff;
  --secondary-text-color: #65676b;
  --logo-color: #000000;
  --glow-color: #333;
}

/* Colores de temas degradados más oscuros y elegantes (menos saturados) 
   Se aplica :not(.light-theme) para asegurar que solo funcionen en modo oscuro */

body:not(.light-theme)[data-gradient-theme="void"] {
  --bg-color: #712e81a9; /* Morado/Negro muy profundo */
}

body:not(.light-theme)[data-gradient-theme="ember"] {
  --bg-color: #723f29; /* Rojizo/Negro muy profundo */
}

body:not(.light-theme)[data-gradient-theme="mono"] {
  --bg-color: #1f1b1b; /* Gris muy oscuro casi negro */
}

body:not(.light-theme)[data-gradient-theme="nebula"] {
  --bg-color: #0f0f0f; /* Azul/Negro muy profundo */
}

* {
  box-sizing: border-box !important;
  padding: 0;
  margin: 0;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

html,
body {
  height: 100%;
}

body {
  width: 100%;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  position: relative;
  font-family: var(--main-font);
  overflow-x: hidden;
  user-select: none;
  transition: background-color 0.4s ease-out, color 0.4s ease-out;
}

#root {
  position: relative;
  z-index: 1;
  background-color: transparent;
}

h1,
h2 {
  font-weight: 600;
}

a {
  text-decoration: none;
  color: var(--text-color);
}

ul {
  list-style: none;
}

::-webkit-scrollbar {
  width: 10px;
  height: 100%;
  cursor: pointer;
}

::-webkit-scrollbar-track {
  background: #181818;
}

::-webkit-scrollbar-thumb {
  background: #fefefe6e;
  border-radius: 4px;
  cursor: pointer;
}

::-webkit-scrollbar-thumb:hover {
  background: #ccc;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
}

.header__logo {
  font-family: "Dancing Script", cursive;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--logo-color);
  transition: color 0.4s ease-out;
}

.header__right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav__list {
  display: flex;
  gap: 1.5rem;
}

.nav__link {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-weight: 500;
}

.nav__link.active-link {
  background-color: var(--primary-color);
  color: var(--primary-text-color);
}

.theme-switcher {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-icon {
  font-size: 1.5rem;
  color: var(--text-color);
  transition: color 0.4s ease-out;
}

#theme-icon-sun {
  display: none;
}

body.light-theme #theme-icon-moon {
  display: none;
}

body.light-theme #theme-icon-sun {
  display: block;
}

.header__toggle {
  display: none;
  cursor: pointer;
}

.header__toggle .material-symbols-outlined {
  font-size: 1.8rem;
  color: var(--text-color);
  transition: color 0.4s ease-out;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color);
  z-index: 101;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: right 0.5s cubic-bezier(0.77, 0, 0.175, 1),
    background-color 0.4s ease-out, color 0.4s ease-out;
  padding: 2rem;
}

.mobile-menu.show-menu {
  right: 0;
}

.mobile-menu__close {
  position: absolute;
  top: 2rem;
  left: 2rem;
  width: 24px;
  height: 24px;
  cursor: pointer;
  z-index: 102;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: transform 0.3s ease;
}

.mobile-menu__close:hover {
  transform: rotate(90deg) scale(1.1);
}

.mobile-menu__close .bar {
  position: absolute;
  width: 100%;
  height: 3px;
  background-color: var(--text-color);
  border-radius: 2px;
  transition: background-color 0.4s ease-out;
}

.mobile-menu__close .bar:nth-child(1) {
  transform: rotate(45deg);
}

.mobile-menu__close .bar:nth-child(2) {
  transform: rotate(-45deg);
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.mobile-nav__list,
.mobile-nav__list--secondary {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.mobile-nav__list {
  flex-direction: row;
  gap: 1rem;
}

.mobile-nav__list--secondary {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--secondary-text-color);
  gap: 1rem;
}

.mobile-nav__link {
  font-size: 1.1rem;
  font-weight: 500;
  padding: 0.6rem 1.2rem;
  border-radius: 999px;
}

.mobile-nav__link.active-link-mobile {
  background-color: var(--primary-color);
  color: var(--primary-text-color);
}

.main {
  isolation: isolate;
}

section {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 6rem 2rem 2rem;
  position: relative;
  background-color: transparent;
}

section h2 {
  font-size: 2.5rem;
}

@media screen and (max-width: 768px) {
  .nav {
    display: none;
  }
  .header__toggle {
    display: block;
  }
}
