/* ===== 基本設定・ヘッダー・フッダー ===== */
body {
    margin: 0;
    font-family: sans-serif;
    background: #f6f8fb;
    color: #0b1220;
}
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}
nav ul {
    list-style: none;
    display: flex;
    gap: 12px;
    margin: 0;
    padding: 0;
}
nav a {
    text-decoration: none;
    padding: 8px 12px;
    color: #333;
    padding: 6px 10px;
    border-radius: 6px;
    display: inline-block;
}
nav a:hover {
    background: #e6f2fb;
    text-decoration: underline;
}
.btn {
    display: inline-block;
    background: #0b78d1;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    text-decoration: none;
    z-index: 2;
}
.school-logo {
    height: 12px;
    vertical-align: middle;
    margin-top: -3px;
    margin-right: 3px;
}
main {
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
}
.main-logo {
    height: 60px;
    vertical-align: middle;
    margin-top: -3px;
    margin-right: 3px;
}
footer {
    text-align: center;
    margin: 30px 0;
    color: #555;
    font-size: 14px;
}
.menu-toggle {
  display: none; /* デフォルトは非表示 */
  background: none;
  border: none;
  font-size: 26px;
  cursor: pointer;
}
/* ログイン・アカウント作成ボタンの調整 */
.nav-link-btn {
    display: inline-block;
    padding: 8px 12px;
    border-radius: 6px;
    text-decoration: none;
    z-index: 2;
    font-weight: bold; /* 少し強調 */
}

/* ログインボタン（アウトライン風のボタン） */
.nav-link-login {
    color: #0b78d1; /* メインカラー */
    background: white;
    border: 1px solid #0b78d1; /* 枠線 */
}

.nav-link-login:hover {
    background: #e6f2fb; /* ホバー時の背景色を既存のnav a:hoverと同じにする */
    text-decoration: none;
}

nav {
    display: flex;
    flex-direction: row; /* 横並びにする */
    justify-content: space-between; /* 左右に要素を広げる */
    align-items: center; /* 縦方向の中央揃え */
    width: 100%;
}
/* 1. メインリンクの配置: 中央寄せの調整 */
.nav-main-links {
    margin: 0 auto; 
}

/* 2. 右側のボタンを2段にするためのコンテナ */
.nav-right-container {
    display: flex;
    flex-direction: column; /* 縦に積み重ねる */
    align-items: flex-end; /* 自身を右端に寄せる */
}

/* 上段（ログイン/アカウント作成）の調整 */
.nav-utility-buttons {
    margin-bottom: 4px;
}

/* 下段（比較ボタン）の調整 */
.nav-compare-buttons {
  margin-bottom: 4px;
}
.btn-group-separator, .btn-group-separator-desktop {
    display: none;
}
.nav-link-logout {
    /* 必要に応じて、背景色、文字色、ボーダーなどを設定 */
    background-color: #e74c3c; /* 赤系の色を例として使用 */
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    transition: background-color 0.3s ease; /* ホバー効果を滑らかにする */
}
.nav-link-logout:hover {
    background-color: #efc9c5;
    text-decoration: underline;
}
.privacy {
    color: #0b78d1;
    text-decoration: none;
}
/* ===== スマホ対応 ===== */
@media (max-width: 700px) {
  .menu-toggle {
    display: block; /* スマホでのみ☰を表示 */
  }

  nav {
    display: none; /* デフォルトは非表示 */
    position: fixed;
    top: 78px;
    left: 0;
    width: 100%;
    background: white;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    border-top: 1px solid #eee;
    z-index: 100;
    padding: 0;
  }

  nav.open {
    display: block; /* JSで開いたときだけ表示 */
  }

  nav ul {
    flex-direction: column;
    margin: 0;
    padding: 0;
    gap: 0;
  }

  nav li {
    border-bottom: 1px solid #eee;
  }

  .btn-group-separator {
    margin-bottom: 6px;
    border-bottom: none;
  }

   nav li a.btn {
    width: 100%;
    width: auto;
    display: block;
    box-sizing: border-box;
    text-align: center;
    padding: 8px 16px;
    margin: 4px 16px;
    border-radius: 50px;
   }

  nav a {
    display: block;
    text-decoration: none;
    padding: 8px 16px;
    width: 100%;
  }
  nav li a.nav-link-btn {
    width: 100%;
    width: auto; /* 幅をコンテンツに合わせる */
    display: block; /* ブロック要素のままにする */
    box-sizing: border-box;
    text-align: center;
    padding: 8px 16px;
    margin: 4px 16px;
    border: 1px solid #0b78d1;
    border-radius: 50px;
  }
  .main-logo {
    height: 50px;
    vertical-align: middle;
    margin-top: -3px;
    margin-right: 3px;
  }
  .nav-right-container {
    width: 100%;
    flex-direction: column;
    align-items: center;
  }
  .nav-utility-buttons,
  .nav-compare-buttons {
    width: 100%;
    justify-content: center;
  }
  .nav-link-btn,
  .nav-link-logout {
    border: none;
  }
}