:root {
  --left-w: 28%;
  --panel-w: 260px;
  --bg-left: #00293d;
  --bg-panel-2: #00344a;
  --bg-panel-3: #003a52;
  --line-yellow: #ffc107;
  --line-green: #00d46f;
}

/* OVERLAY */
.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 40, 60, 0.92);
  backdrop-filter: blur(3px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
  display: flex;
  z-index: 999;
}
.menu-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* LEFT COLUMN (nivel 1) */
.menu-left {
  width: var(--left-w);
  background: var(--bg-left);
  /* padding: 4rem 2.5rem; */
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: end;
  position: relative;
}

/* contenedor del nav interno (ancho fijo para items) */
.menu-left nav {
  width: calc(100% - 2rem);
  display: flex;
  justify-content: end;
}

.menu-level-1 {
  list-style: none;
  margin: 0;
  padding: 0;
}

.menu-level-1 li {
  margin: 1rem 3rem;
  position: relative;
  width: max-content;
  width: 100%;
  padding: 0rem 3rem;
}

.menu-level-1 a {
  color: #ffffff;
  text-decoration: none;
  display: inline-block;
  padding: 6px 10px;
  font-size: 0.95rem;
  transition: background 0.18s ease, color 0.18s ease;
  position: relative;
  width: 100%;
}

.menu-level-1 li:nth-child(odd) > a::after {
  background: var(--line-yellow);
}
.menu-level-1 li:nth-child(even) > a::after {
  background: var(--line-green);
}

/* hover: oscurece únicamente (no cambia la línea) */
.menu-level-1 a:hover {
  background: rgba(0, 0, 0, 0.18);
}

.menu-level-1 li.active > a {
  font-weight: 600;
  background: var(--line-yellow); /* imita el active de la captura (amarillo) */
  color: #002a3a;
}
.menu-level-1 li.active > a::after {
  /* cuando está activo, mantenemos línea visible */
  /* si querés que active tenga la misma alternancia, no tocamos */
}

/* RIGHT AREA (paneles centro + derecha) */
.menu-right {
  flex: 1;
  position: relative;
  overflow: hidden;
}

/* Nivel 2: panel central (aparece alineado a la izquierda de la zona derecha) */
.submenu-box {
  width: var(--panel-w);
  background: var(--bg-panel-2);
  padding: 1.5rem 0rem;
  box-sizing: border-box;
  position: absolute;
  top: 40%;
  transform: translateX(0);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
}

/* active */
.submenu-box.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.submenu-box h4 {
  color: var(--line-yellow);
  margin: 0 0 0.6rem;
  font-size: 0.95rem;
}

.submenu-box ul {
  list-style: none;
  padding: 0 2rem;
  margin: 0;
}

.submenu-box ul li {
  color: #fff;
  /* padding: 0.45rem 0;
  margin-bottom: 0.25rem; */
  font-size: 0.98rem;
  position: relative;
  cursor: pointer;
}

.submenu-box ul li a{
    display: block;
    margin-bottom: 0.25rem;
    padding: 0.45rem 0;
}

/* lineas intercaladas siempre visibles en nivel 2 */
.submenu-box ul li::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 30px;
  height: 3px;
}
.submenu-box ul li:nth-child(odd)::after {
  background: var(--line-yellow);
}
.submenu-box ul li:nth-child(even)::after {
  background: var(--line-green);
}

/* hover: oscurecer fondo del item (no tocar linea) */
.submenu-box ul li:hover {
  background: rgba(0, 0, 0, 0.18);
  padding-left: 6px;
  border-radius: 4px;
}

/* marcaremos active en li de level2 */
.submenu-box ul li.active {
  font-weight: 600;
}

/* Nivel 3: panel derecho (a la derecha del panel central) */
.subsubmenu-box {
  width: var(--panel-w);
  background: var(--bg-panel-3);
  padding: 1.2rem;
  box-sizing: border-box;
  position: absolute;
  top: 20%;
  left: calc(var(--panel-w)); /* a la derecha del panel central */
  transform: translateX(0);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}
.subsubmenu-box.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.subsubmenu-box ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.subsubmenu-box ul li {
  color: #fff;
  padding: 0.45rem 0;
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
  position: relative;
  cursor: pointer;
}

/* lineas intercaladas nivel 3 (amarillo/verde) */
.subsubmenu-box ul li::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 30px;
  height: 3px;
}
.subsubmenu-box ul li:nth-child(odd)::after {
  background: var(--line-yellow);
}
.subsubmenu-box ul li:nth-child(even)::after {
  background: var(--line-green);
}

.subsubmenu-box ul li:hover {
  background: rgba(0, 0, 0, 0.18);
  padding-left: 6px;
  border-radius: 4px;
}

/* Botón cerrar */
.menu-close {
  position: absolute;
  top: 2rem;
  right: 2.5rem;
  font-size: 1.4rem;
  color: #fff;
  cursor: pointer;
  z-index: 1001;
}

/* Responsive: en pantallas pequeñas los panels se apilan o se ajustan */
@media (max-width: 1000px) {
  :root {
    --left-w: 40%;
  }
  .submenu-box {
    left: calc(var(--left-w));
    top: 40%;
  }
  .subsubmenu-box {
    left: calc(var(--left-w) + var(--panel-w));
    top: 15%;
  }
}
@media (max-width: 700px) {
  .menu-left {
    /* width: 100%; */
    /* padding: 2rem; */
  }
  .submenu-box,
  .subsubmenu-box {
    /* display: none; */
    left: 0;
  } /* para mobile podés mostrar otro layout */

  .menu-level-1 li {
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    padding-right: 0;
  }

  .menu-left nav {
    justify-content: start;
  }
}
