/* ========================================
   右上角選單按鈕
======================================== */
.menu{
  /* 只作為分類，不需要設定 */
}


.menu-button {
  position: fixed;
  top: 0;
  right: 50px;

  margin: 0;
  padding: 0;

  border: none;
  background: transparent;

  cursor: pointer;

  z-index: 20;
}

.menu-button-image {
  display: block;

  width: 80px;
  height: auto;
}


/* 右側滑出選單 */
.menu_box {
  position: fixed;
  top: 0;
  right: 0;

  /* 選單寬度依照畫面高度等比例縮放 */
  width: min(700px, 65vh, 100vw);
  height: 100vh;

  z-index: 11;

  /* 選單關閉時，不遮住下方按鈕 */
  pointer-events: none;
}


.side-menu {
  position: absolute;
  top: -3%;
  right: 0;

  width: 100%;
  height: 100%;

  /* 保留背景圖片 */
  background-image: url("../images/menu-background.png");
  background-repeat: no-repeat;
  background-position: left top;
  background-size: auto 100%;

  overflow: hidden;

  transform: translateX(100%);
  transition: transform 0.4s ease;

  /* 關閉時不能攔截點擊 */
  pointer-events: none;
}


.side-menu.is-open {
  transform: translateX(0);

  /* 打開後恢復點擊 */
  pointer-events: auto;
}

/* 選單項目 */
.menu-list {
  position: absolute;
  z-index: 1;

  top: 15%;
  bottom: 30%;
  left: 35%;
  right: 12%;

  display: flex;
  flex-direction: column;
  justify-content: space-between;

  width: auto;

  list-style: none;
}


.menu-list li {
  width: 100%;
  margin: 0;
}

.menu-list a {
  display: block;
  width: 100%;
  text-decoration: none;
}

.menu-title {
  margin: 0;

  font-size: 26px;
  font-weight: 550;

  color: #403b38;

  text-align: left;
	
  transition:
    color 0.25s ease,
    transform 0.25s ease;
}

.menu-list a:hover .menu-title {
  color: #c8a56a;
}

/* 黑色遮罩 */
.menu-overlay {
  position: fixed;
  inset: 0;

  /* 黃褐色半透明遮罩 */
  background-color: rgba(174, 143, 78, 0.7);

  opacity: 0;
  visibility: hidden;
  pointer-events: none;

  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;

  z-index:5;
}

.menu-overlay.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* ========================================
   OFFICIAL
======================================== */

.official-row {
  display: flex;
  align-items: center;
  gap: 20px;
}

.official-title {
  font-size:20px;
  font-weight: 600;
  color: #403b38;
}


/* FB + YouTube 外層 */
.official-links {
  display: flex;
  align-items: center;
  gap: 12px;
}


/* 強制蓋掉 .menu-list a 的設定 */
.official-links .official-button {
  position: relative;

  display: block;

  width: 70px;
  height: 70px;

  flex: 0 0 70px;
}


/* 強制圖片尺寸 */
.official-links .official-button img {
  display: block;

  width: 70px;
  height: 70px;

  max-width: none;

  object-fit: contain;
}


/* hover 圖疊在原圖上 */
.official-links .official-hover {
  position: absolute;
  top: 0;
  left: 0;

  opacity: 0;
}


/* 滑鼠移上去切換 */
.official-links .official-button:hover .official-normal {
  opacity: 0;
}

.official-links .official-button:hover .official-hover {
  opacity: 1;
}


/* ========================================
   手機/ipad
======================================== */

@media (max-width: 768px) {
	
/*手機板範圍 */
.menu-list {
left: 20%;
}

.side-menu {
left: 20%;
}
	
.menu-title {
  font-size: 20px;
 line-height: 15px;
}
	
.menu-button {
  right: 20px;
}
	
.menu-button-image {  
  width: 50px;
}
	
	
/* FB + YouTube 外層 */
.official-links {
  gap: 15px;
}
	
.official-links .official-button {
  width: 30px;
  height: 30px;

  flex: 0 0 30px;
}
	
	
/* 強制圖片尺寸*/ 
.official-links .official-button img {
  width: 40px;
  height: 40px;
}
	
.official-title {
  font-size:14px;
}

/*手機板範圍 */
  } 
