/* --------- Header (共通) --------- */
@import url('https://fonts.googleapis.com/css2?family=M+PLUS+Rounded+1c:wght@700&display=swap');


.header{
  position: relative;           /* sticky をやめる */
  z-index: 20;
  background: rgba(255,255,255,.97);
  border-bottom: 1px solid var(--line);
}
.header__inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
}
.brand{
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}
.brand__name{
  font-size: 1.2rem;  /* 予約サイトと同じくらいのサイズ感 */
  font-weight: 700;
  color: #333333;
  font-family: "M PLUS Rounded 1c", "Noto Sans JP", system-ui, -apple-system,
               BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

.custom-logo{
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

/* PC用グローバルナビ */
.nav{
  display: none;
  gap: 20px;
  align-items: center;
  font-size: 14px;
}
.nav a{
  opacity: .9;
}
.nav a:hover{
  opacity: 1;
}
.nav .btn{
  font-size: 14px;
}
@media (min-width: 768px){
  .nav{
    display: flex;
  }
}

/* スマホ用ヘッダーハンバーガー（左上） */
.sp-header-menu-btn{
  display: none;
  border: none;                /* 枠線なし */
  background: transparent;     /* 背景も透過 */
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.sp-header-menu-btn__icon{
  width: 18px;
  height: 18px;
  object-fit: contain;
}

/* --------- スマホ用ボトムナビ --------- */
.sp-bottom-nav{
  display: none;
}

@media (max-width: 767px){
  body{
    padding-bottom: 64px; /* 下ナビ分の余白を確保 */
  }

  /* ヘッダー内の通常ナビはスマホでは非表示 */
  .nav{
    display: none;
  }

  /* スマホ時はロゴ＋タイトルを中央に配置 */
  .header{
    position: relative;
  }
  .header__inner{
    justify-content: center;
    position: relative;
  }
  .brand{
    margin: 0 auto;
  }

  /* 左上ハンバーガーを表示 */
  .sp-header-menu-btn{
    display: flex;
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
  }

  .sp-bottom-nav{
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    display: flex;
    height: 80px;
    background: #6ebee9;   
    border-top: 1px solid var(--line);
  }

  .sp-bottom-nav__item{
    flex: 1;
    border-right: 1px solid rgba(148,163,184,.25);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    text-decoration: none;
    color: #ffffff;  
    background: transparent;
    padding-top: 4px;
    margin: 0;             /* 余計な余白を全てゼロに */
    border: 0;             /* デフォルトの枠を消す */
    border-right: 1px solid #ffffff;  /* 区切り線を白に */
    box-sizing: border-box;
  }
  .sp-bottom-nav__item:last-child{
    border-right: none;
  }

  /* PNGアイコン（枠なし） */
  .sp-bottom-nav__icon-img{
    width: 20px;
    height: 20px;
    object-fit: contain;
    display: block;
    margin-bottom: 6px;
  }

  .sp-bottom-nav__label{
    line-height: 1.2;
  }

  /* 予約だけシンプルに背景色で強調 */
  .sp-bottom-nav__item--primary{
    flex: 1.3;
    background: var(--brand);
    color: #ffffff;
    border-right: none;
  }
  .sp-bottom-nav__item--primary .sp-bottom-nav__label{
    font-weight: 700;
  }

  /* --------- メニューのドロワー --------- */
  .sp-menu-drawer{
    position: fixed;
    inset: 0;
    z-index: 40;
    display: none;
  }
  .sp-menu-drawer.is-open{
    display: block;
  }
  .sp-menu-drawer__backdrop{
    position: absolute;
    inset: 0;
    background: rgba(15,23,42,.45);
  }

  /* パネル本体は top/bottom をクラスで切り替え */
  .sp-menu-drawer__panel{
    position: absolute;
    left: 0;
    right: 0;
    max-height: 80vh;
    background: #ffffff;
    box-shadow: var(--shadow);
    padding: 20px 16px 24px;
    overflow-y: auto;
  }
  /* 下部ハンバーガーから：下から出る */
  .sp-menu-drawer.is-open-bottom .sp-menu-drawer__panel{
    bottom: 0;
    border-radius: 16px 16px 0 0;
  }
  /* 上部ハンバーガーから：上から出る */
  .sp-menu-drawer.is-open-top .sp-menu-drawer__panel{
    top: 0;
    border-radius: 0 0 16px 16px;
  }

  .sp-menu-drawer__header{
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
  }
  .sp-menu-drawer__title{
    font-weight: 700;
    font-size: 16px;
  }
  .sp-menu-drawer__close{
    border: none;
    background: transparent;
    font-size: 22px;
    line-height: 1;
    padding: 4px 8px;
  }

  .sp-menu-drawer__nav ul{
    list-style: none;
    margin: 0;
    padding: 0;
  }
  .sp-menu-drawer__nav li + li{
    border-top: 1px solid var(--line);
  }
  .sp-menu-drawer__nav a{
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 4px;
    font-size: 14px;
    text-decoration: none;
  }
}

/* メニューオープン時は背景スクロールを止める */
body.is-sp-menu-open{
  overflow: hidden;
}

/* --------- ページトップボタン --------- */
.page-top-btn{
  position: fixed;
  right: 16px;
  bottom: 110px;                       /* 下ナビの少し上に表示 */
  width: 50px;                        /* 少し大きめ（40→50px） */
  height: 50px;
  border-radius: 9999px;
  border: 1px solid #3b82f6;          /* やわらかめの水色枠 */
  background: rgba(255,255,255,0.5);  /* 半透明の白 */
  backdrop-filter: blur(4px);
  display: none;                      /* JSで表示切り替え */
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #1e293b;
  z-index: 50;
}
.page-top-btn.is-show{
  display: flex;
}
/* ★ PCでは常に非表示にする */
@media (min-width: 768px){
  .page-top-btn{
    display: none !important;
  }
}

/* --------- PC幅ではモバイルUIを全て非表示 --------- */
@media (min-width: 768px){
  .sp-bottom-nav,
  .sp-menu-drawer,
  .sp-header-menu-btn{
    display: none !important;
  }

  /* 万一 is-sp-menu-open が付いていてもスクロールを止めない */
  body.is-sp-menu-open{
    overflow: auto;
  }
}

@media (min-width: 768px){
  .sp-bottom-nav,
  .sp-menu-drawer,
  .sp-header-menu-btn{
    display: none !important;
  }

  body.is-sp-menu-open{
    overflow: auto;
  }

  /* ★ PC ではヘッダーを常に上部に固定 */
  .header{
    position: sticky;
    top: 0;
  }
}
