@charset "utf-8";
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;700&display=swap');

/* ======================================================
リソルグループ運営施設紹介（2026-10-08）
このページ専用の CSS。HP 共通の CSS は変更しない。
デジタル庁デザインシステム（v2.18.0）の基準を参考にしている。
- 文字：本文 16px、最小 14px。行間 本文 1.7、見出し 1.4
- 余白：8px 単位（8 / 16 / 24 / 32 / 64）
- 色：文字 4.5:1 以上、枠線・アイコン 3:1 以上（白背景）
- フォーカス：黒と黄色の二重
- 押せる部分：高さ 44px 以上
※ 1rem = 10px（common/css/base.css）
====================================================== */

#mainContents {
  /* 色は HP 共通の配色にそろえる（h1・サイドメニューの緑 #307246、選択中の黄緑 #d7eea3） */
  --fac-green: #307246;       /* リンク・強調（白に対して 5.9:1） */
  --fac-green-light: #d7eea3; /* サイドメニューの選択中と同じ黄緑 */
  --fac-green-bg: #f1f8e4;    /* ホバー・選択中の背景（黄緑を薄くしたもの） */
  --fac-text: #1a1a1a;
  --fac-sub: #595959;         /* 補足の文字（白に対して 7:1） */
  --fac-line: #8c8c8c;        /* 枠線（白に対して 3.4:1） */
  --fac-bg: #f2f2f2;
  --fac-focus: #ffd43d;
  font-family: 'Noto Sans JP', sans-serif;
  color: var(--fac-text);
}

/* フォーカス：黒と黄色の二重（このページの中だけ）
   HP 共通の base.css が a に outline: none !important を付けているので、ここも !important にする */
#mainContents a:focus-visible {
  outline: 4px solid #000 !important;
  outline-offset: 0;
  background-color: var(--fac-focus);
  box-shadow: 0 0 0 2px var(--fac-focus);
  color: var(--fac-text); /* 黄色の上の緑は 4.1:1 で足りないので、文字を黒にする */
}

.fac-lead {
  margin: 0 0 6.4rem;
  font-size: 1.6rem;
  line-height: 1.7;
}

/* 見出し（h2）：HP 共通の .heading02 と同じ見た目（左の黄緑の帯＋点線） */
.fac-h2 {
  position: relative;
  margin: 0 0 2.4rem;
  padding: 0.4rem 0 0.8rem 2rem;
  border-bottom: dotted 2px #979797;
  font-size: 2.4rem;
  font-weight: normal;
  line-height: 1.4;
  color: #000;
}
.fac-h2::before {
  content: "";
  position: absolute;
  top: 0.4rem;
  bottom: 1rem;
  left: 0;
  width: 5px;
  background: var(--fac-green-light);
}

/* 新しいタブで開くアイコン（リンクの末尾） */
.fac-newTab {
  display: inline-block;
  width: 1em;
  height: 1em;
  margin-left: 0.25em;
  vertical-align: -0.125em;
}

/* ---------- ブランド公式サイト（各カテゴリーの先頭に出す横長のバナー） ---------- */
.fac-brandBanner {
  margin: 0 0 2.4rem;
}
.fac-brandBanner a {
  display: flex;
  align-items: center;
  gap: 2.4rem;
  min-height: 88px;
  padding: 0 2.4rem 0 0;
  overflow: hidden;
  border: 1px solid var(--fac-line);
  border-left: 6px solid var(--fac-green);
  border-radius: 8px;
  background: #fff;
  color: var(--fac-green);
  text-decoration: none;
}
.fac-brandLogo {
  flex: 0 0 220px;
  align-self: stretch;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid #e0e0e0;
  background: #fff;
}
/* ロゴは SVG。横長のロゴは幅、縦に厚いロゴは高さで大きさをそろえる */
.fac-brandLogo img {
  display: block;
  width: 76%;
  height: 44px;
  object-fit: contain;
}
.fac-brandText {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.fac-brandName {
  font-size: 1.8rem;
  font-weight: bold;
  line-height: 1.4;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
.fac-brandDesc {
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--fac-sub);
}
.fac-brandBanner a:hover {
  background: var(--fac-green-bg);
}
.fac-brandBanner a:hover .fac-brandName {
  text-decoration-thickness: 3px;
}

/* ---------- 絞り込み ---------- */
.fac-filter {
  margin-bottom: 6.4rem;
}
.fac-filter[hidden] {
  display: none;
}
.fac-filterNote {
  margin: 0 0 1.6rem;
  font-size: 1.6rem;
  line-height: 1.7;
}
.fac-filterBox {
  margin: 0;
  padding: 2.4rem;
  border-radius: 8px;
  background: var(--fac-bg);
}
.fac-fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.fac-fieldset + .fac-fieldset {
  margin-top: 2.4rem;
}
.fac-legend {
  display: block; /* HP 共通の base.css が legend を非表示にしているので、このページでは出す */
  margin: 0 0 0.8rem;
  padding: 0;
  font-size: 1.6rem;
  font-weight: bold;
  line-height: 1.5;
}
/* ボタンの幅をそろえる（PC は4列、スマホは2列） */
.fac-options {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.8rem;
}
.fac-option {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  min-height: 44px;
  padding: 0 1.6rem 0 1.2rem;
  border: 1px solid var(--fac-line);
  border-radius: 22px;
  background: #fff;
  font-size: 1.6rem;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}
.fac-option input {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--fac-green);
  cursor: pointer;
}
.fac-option:hover {
  border-color: var(--fac-green);
  background: var(--fac-green-bg);
}
.fac-option:has(input:checked) {
  border: 2px solid var(--fac-green);
  padding: 0 1.5rem 0 1.1rem;
  background: var(--fac-green-light);
  font-weight: bold;
}
.fac-option:has(input:focus-visible) {
  outline: 4px solid #000;
  outline-offset: 2px;
  box-shadow: 0 0 0 2px var(--fac-focus);
}
.fac-result {
  margin: 1.6rem 0 0;
  font-size: 1.6rem;
  font-weight: bold;
  line-height: 1.5;
}

/* ---------- カテゴリーの区切り ---------- */
.fac-section {
  margin-bottom: 6.4rem;
}
.fac-section[hidden] {
  display: none;
}
.fac-sectionLead {
  margin: 0 0 2.4rem;
  font-size: 1.6rem;
  line-height: 1.7;
}

/* ---------- 施設カード ---------- */
.fac-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.facCard {
  position: relative;
  display: flex;
  flex-direction: column;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--fac-line);
  border-radius: 8px;
  background: #fff;
}
.facCard[hidden] {
  display: none;
}
.facCard:hover {
  background: var(--fac-green-bg);
}
.facCard-img {
  aspect-ratio: 12 / 7;
  overflow: hidden; /* 縦横比の違う写真でも枠の大きさをそろえる */
  background: var(--fac-bg);
}
.facCard-img img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.facCard-img--none {
  display: flex;
  align-items: center;
  justify-content: center;
  background: repeating-linear-gradient(45deg, #e6e6e6 0 10px, #f2f2f2 10px 20px);
}
.facCard-img--none p {
  margin: 0;
  font-size: 1.4rem;
  color: var(--fac-sub);
}
.facCard-body {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  flex: 1;
  padding: 1.6rem;
}
.facCard-body hgroup {
  margin: 0;
}
.facCard-pref {
  margin: 0 0 0.4rem;
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--fac-sub);
}
.facCard-name {
  margin: 0;
  font-size: 1.6rem;
  font-weight: bold;
  line-height: 1.5;
}
.facCard-name a {
  color: var(--fac-green);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
/* 施設名のリンクをカード全体に広げる（カードの中にほかのリンクを置かない） */
.facCard-name a::after {
  content: "";
  position: absolute;
  inset: 0;
}
/* 新しいタブのアイコンは、どのカードでも右下の同じ位置に出す（リンクの中にあるので押せる範囲に含まれる） */
.facCard .fac-newTab {
  position: absolute;
  right: 1.6rem;
  bottom: 1.6rem;
  width: 1.8rem;
  height: 1.8rem;
  margin: 0;
}
.facCard-body {
  padding-bottom: 4.8rem;
}
.facCard:hover .facCard-name a {
  text-decoration-thickness: 3px;
}
.facCard:has(a:focus-visible) {
  outline: 4px solid #000;
  outline-offset: 2px;
  box-shadow: 0 0 0 2px var(--fac-focus);
}
/* カードは外枠にフォーカスを出すので、施設名のリンクには枠を重ねない */
#mainContents .facCard-name a:focus-visible {
  outline: none !important;
}
.facCard-note,
.facCard-desc {
  margin: 0;
}
.facCard-desc {
  font-size: 1.4rem;
  line-height: 1.7;
  color: var(--fac-sub);
}

/* チップラベル（運営開始などの注記） */
.fac-chip {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--fac-green);
  border-radius: 4px;
  background: var(--fac-green-light);
  font-size: 1.4rem;
  line-height: 1.4;
  color: #1a1a1a;
}

/* ---------- リソルステイのエリア ---------- */
.fac-areaList {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.fac-areaList li {
  margin: 0;
}
.fac-areaList li[hidden] {
  display: none;
}
.fac-areaList a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0.8rem;
  border: 1px solid var(--fac-line);
  border-radius: 8px;
  background: #fff;
  color: var(--fac-green);
  font-size: 1.6rem;
  font-weight: bold;
  line-height: 1.4;
  text-align: center;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
.fac-areaList a:hover {
  background: var(--fac-green-bg);
  text-decoration-thickness: 3px;
}

/*===============
タブレット用調整
================*/
@media only screen and (max-width: 1121px) {
  .fac-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .fac-areaList {
    grid-template-columns: repeat(3, 1fr);
  }
}

/*===============
スマホ用調整
================*/
@media only screen and (max-width: 767px) {
  .fac-lead {
    margin-bottom: 4rem;
  }
  .fac-h2 {
    font-size: 2rem;
  }
  .fac-filter,
  .fac-section {
    margin-bottom: 4.8rem;
  }
  .fac-brandBanner {
    margin-bottom: 1.6rem;
  }
  .fac-brandBanner a {
    gap: 1.6rem;
    min-height: 72px;
    padding-right: 1.6rem;
  }
  .fac-brandLogo {
    flex-basis: 40%;
  }
  .fac-brandLogo img {
    height: 72px;
  }
  .fac-brandName {
    font-size: 1.6rem;
  }
  .fac-filterBox {
    padding: 1.6rem;
  }
  .fac-options {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.6rem;
  }
  .fac-option {
    gap: 0.6rem;
    padding: 0 0.8rem;
  }
  .fac-option:has(input:checked) {
    padding: 0 0.7rem;
  }
  .fac-cards {
    grid-template-columns: 1fr;
    gap: 1.6rem;
  }
  .facCard {
    flex-direction: row;
  }
  .facCard-img {
    flex: 0 0 36%;
    aspect-ratio: auto;
    min-height: 96px;
  }
  .facCard-body {
    padding: 1.2rem 4.4rem 1.2rem 1.6rem; /* 右下のアイコンと文字が重ならないよう、右に余白 */
  }
  .facCard .fac-newTab {
    right: 1.4rem;
    bottom: 1.2rem;
  }
  .fac-areaList {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.8rem;
  }
}
