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

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
    color: #fafafa;
}

body {
    background-repeat: no-repeat;
    background: linear-gradient(180deg, #012e40 10%, #011c26 50%, #00080d 100%);
    min-height: 100vh;
    width: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
}

.background-layers {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.grid-overlay {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(
            rgba(255, 255, 255, 0.07) 1px,
            transparent 1px
        ),
        linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
    background-size: 164px 164px;
    width: 100%;
    height: 100%;
}

@keyframes pulse {
    0%,
    100% {
        opacity: 0.7;
    }
    50% {
        opacity: 1;
    }
}

header {
    padding: 20px 0;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo i {
    font-size: 24px;
}

.logo h1 {
    font-size: 24px;
    font-weight: bold;
    letter-spacing: 1px;
}

.logo a {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
}

.desktop-menu {
    display: flex;
    list-style: none;
    gap: 20px;
    align-items: center;
    position: relative;
    flex-wrap: wrap;
}

.desktop-menu li {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.desktop-menu li a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    padding: 0.5rem 0.8rem;
    display: block;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.desktop-menu li a:hover {
    opacity: 0.5;
}

.desktop-menu li .submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(20, 20, 40, 0.9);
    padding: 0.5rem 0;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    min-width: 160px;
    z-index: 100;
}

.desktop-menu li.has-submenu:hover .submenu {
    display: block;
}

.desktop-menu li .submenu li {
    display: block;
    width: 100%;
}

.desktop-menu li .submenu li a {
    padding: 0.5rem 1rem;
    color: white;
    white-space: nowrap;
}

desktop-menu li .submenu li a:hover {
    opacity: 0.5;
}

.burger-menu {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.burger-line {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 3px 0;
    transition: 0.3s;
}

.burger-menu.active .burger-line:nth-child(1) {
    transform: rotate(-45deg) translate(-6px, 6px);
}

.burger-menu.active .burger-line:nth-child(2) {
    opacity: 0;
}

.burger-menu.active .burger-line:nth-child(3) {
    transform: rotate(45deg) translate(-6px, -6px);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #011c26;
    backdrop-filter: blur(10px);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 80px 20px 20px;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-overlay .logo {
    position: absolute;
    top: 24px;
    left: 20px;
    z-index: 1001;
}

.mobile-menu-overlay.active .logo {
    opacity: 1;
}

.mobile-menu-overlay.active .logo a {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
}

.mobile-menu-overlay .logo i {
    font-size: 24px;
}

.mobile-menu-overlay .logo h1 {
    font-size: 24px;
}

.mobile-menu-content {
    margin: 0 auto;
}

.mobile-menu-section,
.mobile-menu-single {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-overlay.active .mobile-menu-section,
.mobile-menu-overlay.active .mobile-menu-single {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu-overlay.active .mobile-menu-section:nth-child(1),
.mobile-menu-overlay.active .mobile-menu-single:nth-child(1) {
    transition-delay: 0.05s;
}
.mobile-menu-overlay.active .mobile-menu-section:nth-child(2),
.mobile-menu-overlay.active .mobile-menu-single:nth-child(2) {
    transition-delay: 0.06s;
}
.mobile-menu-overlay.active .mobile-menu-section:nth-child(3),
.mobile-menu-overlay.active .mobile-menu-single:nth-child(3) {
    transition-delay: 0.07s;
}
.mobile-menu-overlay.active .mobile-menu-section:nth-child(4),
.mobile-menu-overlay.active .mobile-menu-single:nth-child(4) {
    transition-delay: 0.08s;
}

.mobile-menu-section h3 {
    color: white;
    font-size: 18px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: normal;
}

.mobile-menu-section h3 i {
    transition: transform 0.3s ease;
    padding: 10px;
}

.mobile-menu-section.expanded h3 i {
    transform: rotate(180deg);
}

.mobile-menu-items {
    display: none;
    padding-top: 10px;
    list-style: none;
}

.mobile-menu-section.expanded .mobile-menu-items {
    display: block;
}

.mobile-menu-items a {
    display: block;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    padding: 12px 0;
    font-size: 16px;
    transition: all 0.3s ease;
}

.mobile-menu-items a:hover,
.mobile-menu-section h3:hover {
    color: white;
    padding-left: 5px;
    opacity: 0.5;
}

.mobile-menu-single a {
    display: block;
    color: white;
    text-decoration: none;
    padding: 15px 0;
    font-size: 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.mobile-menu-single a:hover {
    padding-left: 5px;
    opacity: 0.5;
}

.profile {
    width: 160px;
    height: auto;
    display: block;
    background: transparent;
    color: #fff;
    border: 1px solid #ffffff61;
    border-radius: 15px;
    box-shadow: 0px 0px 7px #a5a8b496;
    padding: 10px 25px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    text-decoration: none;
    text-align: center;
}

.profile::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    transition: 0.6s;
}

.profile:hover {
    border: 1px solid #ffffff;
    box-shadow: 0px 0px 10px #a5a8b4cc;
}

.profile:hover::before {
    left: 100%;
}

.profile:active {
    transform: translateY(1px);
    box-shadow: 0px 0px 5px #a5a8b496;
}

.mobile-profile {
    margin-top: 40px;
    text-align: center;
}

.mobile-profile .profile {
    width: 100%;
    max-width: 300px;
}

main {
    display: flex;
    flex-direction: column;
    position: relative;
    padding: 0 20px;
    margin: auto auto;
}

.exercise {
    display: flex;
    flex-direction: column;
    padding: 20px;
    flex: 1;
    width: 100%;
    text-align: center;
}

.title {
    font-size: 56px;
    font-weight: bold;
    text-wrap: balance;
}

.options {
    display: flex;
    gap: 20px;
    justify-content: flex-start;
    margin: auto;
}

.option {
    width: 240px;
    background: rgba(1, 28, 38, 0.6);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 1rem 2rem;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.4s ease;
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2),
        inset 0 1px 1px rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    text-decoration: none;
}

.option::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    transition: 0.6s;
}

.option:hover {
    border-color: rgba(255, 255, 255, 0.6);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 1px rgba(255, 255, 255, 0.2);
}

.option:hover::before {
    left: 100%;
}

.option:active {
    transform: translateY(0);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.option a {
    text-decoration: none;
    width: 100%;
    height: 100%;
    color: #fafafa;
    font-weight: 500;
    letter-spacing: 0.5px;
}

@media (max-width: 768px) {
    .desktop-menu {
        display: none;
    }

    .burger-menu {
        display: flex;
    }

    .profile {
        display: none;
    }

    .mobile-profile > .profile {
        display: block;
        margin: auto;
    }

    nav {
        justify-content: space-between;
    }

    nav ul {
        justify-content: center;
        padding: 10px 0;
    }

    .options {
        flex-direction: column;
        gap: 15px;
        margin: auto;
    }

    .option {
        width: 200px;
        padding: 0.8rem 1.8rem;
        font-size: 0.9rem;
    }

    .title {
        font-size: 1.8rem;
        margin-bottom: 40px;
    }
}

@media (max-width: 576px) {
    nav ul {
        gap: 10px;
    }

    nav ul li a {
        font-size: 16px;
        padding: 0.5rem;
        text-align: center;
    }

    .profile {
        width: 120px;
        padding: 8px 15px;
        font-size: 14px;
    }
}

footer {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
    color: #615e5e44;
    font-size: 14px;
    position: relative;
    z-index: 10;
}

footer p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.603);
    text-align: center;
}

.alerta-sesion {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  font-family: "Poppins", sans-serif;
}

.alerta-contenido {
  background: #011c26;
  border: 1px solid #ffffff22;
  border-radius: 20px;
  padding: 40px 30px;
  text-align: center;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
  max-width: 400px;
  width: 90%;
  animation: fadeIn 0.3s ease;
}

.alerta-contenido h2 {
  color: #fff;
  font-size: 26px;
  margin-bottom: 15px;
  font-weight: 700;
}

.alerta-contenido p {
  color: #9ca3af;
  font-size: 16px;
  margin-bottom: 30px;
}

.btn {
    background: #0003;
    color: #fff;
    border: 1px solid #ffffff61;
    border-radius: 15px;
    box-shadow: 0 0 7px #a5a8b496;
    font-weight: 500;
    font-style: italic;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    height: 50px;
    width: 200px;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    transition: 0.6s;
}

.btn:hover {
    border-color: #fff;
    background-color: rgba(255, 255, 255, 0.05);
}

.btn:hover::before {
    left: 100%;
}

.btn:active {
    transform: translateY(1px);
    box-shadow: 0 0 5px #a5a8b496;
}

.btn-primary {
    color: white;
}

.btn-secondary {
    color: white;
    box-shadow: none;
}

.alerta-botones {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Ocultar inicialmente */
.oculto {
  display: none;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}


::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: linear-gradient(180deg, #011c26 0%, #00080d 100%);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background-color: #012e40;
    border-radius: 10px;
    border: 2px solid #00080d;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #01475f;
}

* {
    scrollbar-color: #012e40 #00080d;
}
