/* ===========================
   Aoniwa Facilities 専用スタイル
   =========================== */

body {
  background: #fafafa;
  font-family: "Noto Sans JP", system-ui, sans-serif;
  color: #222;
  margin: 0;
  line-height: 1.9;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 40px 20px 80px;
}

/* 見出し */
h1 {
  font-size: 28px;
  font-weight: 500;
  letter-spacing: 0.03em;
  border-bottom: 1px solid #ddd;
  padding-bottom: 8px;
  margin-bottom: 32px;
}
h1 span {
  font-size: 16px;
  color: #999;
  margin-left: 6px;
  font-weight: 400;
}

/* カード */
.card {
  background: #fff;
  border-radius: 12px;
  padding: 28px;
  margin: 40px 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.3s ease;
}
.card:hover {
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}
.card h2 {
  border-left: 4px solid #d0d6d9;
  padding-left: 10px;
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 18px;
}
.card p,
.card li {
  font-size: 15.5px;
  line-height: 1.9;
  color: #333;
}
.card a {
  color: #0073aa;
  text-decoration: none;
}
.card a:hover {
  text-decoration: underline;
}

/* メディア配置 */
.media {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  flex-wrap: wrap;
}
.media img {
  width: auto;
  max-width: 170px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  object-fit: cover;
  flex-shrink: 0;
  margin-left: 4px;
}
.media .body {
  flex: 1;
  min-width: 260px;
}

/* 注意ボックス */
.notice {
  background: #fff6e8;
  border: 1px solid #ffe2bd;
  border-radius: 8px;
  padding: 12px 14px;
  margin-top: 12px;
  color: #6b4c1f;
  font-size: 14px;
}

/* Wi-Fi ボックス */
.wifi-box {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 8px 10px;
  max-width: 480px;
  font-size: 15.5px;
}
.wifi-box code {
  background: #f5f7f8;
  border-radius: 6px;
  padding: 4px 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.02em;
  white-space: nowrap; /* ← 改行禁止 */
}

/* ギャラリー */
.gallery {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.gallery img {
  width: auto;
  max-width: 220px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

/* 公式LINE案内 */
.contact-line {
  text-align: center;
  background: #fff;
  border-radius: 12px;
  padding: 40px 20px;
  margin-top: 60px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}
.contact-line p {
  font-size: 16px;
  margin-bottom: 16px;
  color: #333;
}
.line-btn {
  display: inline-block;
  background: #06c755;
  color: #fff;
  font-size: 16px;
  padding: 12px 26px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
  letter-spacing: 0.05em;
}
.line-btn:hover {
  opacity: 0.9;
}

/* スマホ対応 */
@media (max-width: 700px) {
  .media {
    flex-direction: column;
    gap: 10px;
  }
  .media img,
  .gallery img {
    max-width: 100%;
  }
  .wifi-box {
    grid-template-columns: 1fr;
  }
  .card {
    padding: 20px;
  }
  h1 {
    font-size: 24px;
  }
}

/* Sauna Figure 画像調整 */
.figure {
  text-align: center;
  margin-top: 24px;
}
.figure img {
  max-width: 420px; /* ←ちょうど良いサイズ感 */
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}
.figure figcaption {
  font-size: 14px;
  color: #666;
  margin-top: 8px;
  letter-spacing: 0.03em;
}

/* ===== Wi-Fi セクションのレイアウト調整 ===== */

/* QRと本文の2カラムに（他カードより少し広めに） */
.media.media--wifi {
  display: grid;
  grid-template-columns: 220px 1fr; /* 左:QR幅 / 右:本文 */
  gap: 24px;
  align-items: start;
}
.media.media--wifi img {
  max-width: 220px;
}

/* SSID と パスワードを1行4セルで整列： [SSID][値][パスワード][値] */
.wifi-box {
  display: grid;
  grid-template-columns: auto 1fr auto 1fr;
  align-items: center;
  column-gap: 16px;
  row-gap: 6px;
  max-width: none;         /* 先の制限を解除して自由に並べる */
}
.wifi-box > div {          /* 子divを“素通し”にして中のspan/codeを直接グリッド化 */
  display: contents;
}
.wifi-box span {           /* ラベル */
  color: #666;
  letter-spacing: .06em;
  white-space: nowrap;
  font-weight: 500;
}
.wifi-box code {           /* 値 */
  background: #f1f3f5;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 16px;
  white-space: nowrap;     /* 途中改行しない */
}

/* スマホ：1カラムにしつつ [ラベル][値] の2列表示に切替 */
@media (max-width: 700px) {
  .media.media--wifi {
    grid-template-columns: 1fr;
  }
  .wifi-box {
    grid-template-columns: auto 1fr;
    row-gap: 8px;
  }
}

/* ===========================================
   サウナセクション（上品レイアウト）
=========================================== */
.media--sauna {
  display: grid;
  grid-template-columns: 240px 1fr;
  align-items: start;
  gap: 28px;
  margin-bottom: 8px;
}

.media--sauna img {
  max-width: 240px;
  border-radius: 14px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
  object-fit: cover;
  aspect-ratio: 4/3;
}

.media--sauna .body ul {
  margin: 0 0 14px;
  padding-left: 1.4em;
  font-size: 16px;
  line-height: 1.9;
  color: #222;
}

.media--sauna .body li {
  margin-bottom: 8px;
}

.media--sauna .notice {
  background: #fff8f2;
  border: 1px solid #ffe4c8;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 14px;
  color: #5c4633;
  line-height: 1.8;
}

/* ヒーター画像とキャプション */
.figure--sauna {
  margin: 20px 0 0 calc(240px + 28px);
}

.figure--sauna img {
  width: min(720px, 100%);
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  display: block;
}

.figure--sauna figcaption {
  text-align: center;
  font-size: 14px;
  color: #666;
  margin-top: 8px;
  letter-spacing: 0.02em;
}

/* スマホレイアウト調整 */
@media (max-width: 700px) {
  .media--sauna {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .media--sauna img {
    max-width: 100%;
    aspect-ratio: auto;
  }

  .figure--sauna {
    margin: 14px 0 0 0;
    text-align: center;
  }

  .figure--sauna img {
    width: 100%;
  }
}


/* --- Dog run gallery --- */
.gallery--dog{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.gallery--dog .shot img{
  width: 100%;
  height: auto !important;   /* ← 比率崩れの強制防止 */
  object-fit: contain;       /* 画像を切り抜かず表示 */
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0,0,0,.08);
  background: #fff;
}

.gallery--dog .shot figcaption{
  margin-top: 8px;
  font-size: 14px;
  color: #555;
  letter-spacing: .02em;
  line-height: 1.7;
}

/* スマホは1列表示に */
@media (max-width: 700px){
  .gallery--dog{
    grid-template-columns: 1fr;
    gap: 14px;
  }
}


/* ===== Dog run: balanced two-cards layout ===== */
.gallery--dog{
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr)); /* ←左右を同幅に */
  gap: 24px;
  align-items: start;
}

/* 同じ大きさの“枠”を作り、その中に画像を収める（トリミングしない） */
.gallery--dog .frame{
  width: 100%;
  aspect-ratio: 4 / 3;                /* 枠比率を統一 → 視覚バランス◎ */
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0,0,0,.08);
  overflow: hidden;
}
.gallery--dog .frame img{
  width: 100%;
  height: 100%;
  object-fit: contain;                 /* 赤丸が見切れないよう必ず等倍収まり */
  background: #fff;
}

/* キャプションのタイポ */
.gallery--dog .shot figcaption{
  margin-top: 8px;
  font-size: 14px;
  color: #555;
  line-height: 1.7;
  letter-spacing: .02em;
}

/* モバイルは1列で中央寄せ */
@media (max-width: 700px){
  .gallery--dog{
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* 左の画像だけ白枠の横幅いっぱいに拡大（上下トリミング） */
.gallery--dog .shot:first-child .frame img {
  object-fit: cover;       /* ← contain → cover に変更 */
  object-position: center; /* 中央トリミング */
}

/* ── Weber マニュアル画像 ── */
#bbq .figure {
  margin-top: 16px;
  text-align: center;
}

#bbq .figure img {
  max-width: 100%;
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0,0,0,.08);
}

#bbq .figure figcaption {
  font-size: 14px;
  color: #666;
  margin-top: 6px;
  line-height: 1.6;
}

/* ===== Aoniwa マニュアル共通ナビ ===== */
.aoniwa-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #ffffff;
  border-bottom: 1px solid #e3e6ea;
}

.aoniwa-nav-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  gap: 8px;
  padding: 8px 12px;
  overflow-x: auto;
}

.aoniwa-nav-link {
  flex: 1 0 auto;
  text-align: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 14px;
  text-decoration: none;
  color: #006d75;
  background: #f5f7fa;
  white-space: nowrap;
}

.aoniwa-nav-link.current {
  background: #006d75;
  color: #ffffff;
  font-weight: 600;
}

@media (min-width: 768px) {
  .aoniwa-nav-inner {
    padding: 10px 16px;
    gap: 10px;
  }
  .aoniwa-nav-link {
    font-size: 15px;
    padding: 8px 12px;
  }
}
