﻿.hidden {
  display: none;
}

.mobmenu {
  position: fixed;
  top: 0;
  right: -80%;
  width: 80%;
  height: 100dvh;
  background: #222;
  color: white;
  display: flex;
  flex-direction: column;
  padding: 60px 20px 20px;
  transition: right 0.3s ease-in-out;
  z-index: 999;
  overflow-y: auto;
}

.mobmenu.open {
  right: 0;
}

.closebtn {
  position: absolute;
  top: 10px;
  right: 15px;
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  z-index: 1000;
}

.mobmenu a {
  color: white;
  text-decoration: none;
  padding: 10px 0;
  border-bottom: 1px solid #444;
  font-size: 16px;
  display: block; /* ทำให้อยู่บรรทัดใหม่ */
}

.mob-submenu {
  padding-left: 15px;
  background-color: #2a2a2a;
  margin-bottom: 10px; /* เว้นช่องว่างใต้เมนูย่อย */
}

.mob-submenu.hidden {
  display: none;
}

.menu-link {
  cursor: pointer;
}

.menu-link.has-sub::after {
  content: " ▶";
  float: right;
  font-size: 12px;
  color: #aaa;
}

.mob-submenu.mob-submenu-level2 {
  background-color: #333; /* สีพื้นหลังที่ต่างจาก layer 2 */
  padding-left: 15px;      /* เพิ่ม indent ให้ดูเป็นชั้น */
  border-left: 2px solid #555; /* ถ้าต้องการให้ดูมีเส้นแบ่ง */
}

.mob-submenu.mob-submenu-level2 a{
	color:orange;
}

.mob-submenu..mob-submenu-level1 {
  padding-left: 15px;
  background-color: #2a2a2a;
}

.mob-submenu-level2 {
  padding-left: 30px;
  background-color: #333;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.4);
  z-index: 998;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

.overlay.hidden {
  display: none;
}
