/*CSSカスタムプロパティ（サイト全体を一括管理する為の設定）
---------------------------------------------------------------------------*/
:root {

	--primary-color: #4476b9;			/*テンプレートのテーマカラー*/
	--primary-inverse-color: #fff;		/*上のprimary-colorの対となる色*/

	--secondary-color: #30363d;			/*テンプレートのサブカラー*/
	--secondary-inverse-color: #fff;	/*secondary-colorの対となる色*/
	
	--accent-color: #c43311;			/*テンプレートのアクセントカラー*/
	--accent-inverse-color: #fff;		/*accent-colorの対となる色*/

	/*余白の一括管理用。主に左右の余白に使っています。4rem＝4文字分。*/
	--content-space: 4rem;
	
}

/* ======= ベーススタイル ======= */
body {
  font-family: "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: #333;
  background-color: #f4f8fb;
  margin: 0;
  padding: 0;
  padding-top: 70px; /* ナビゲーションバーの高さ分の余白を確保（調整可能） */
}

h1, h2, h3, h4 {
  color: #005baa; /* 青系 */
  font-weight: bold;
  margin-bottom: 1rem;
}

a {
  color: #005baa;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* ======= レイアウト ======= */
.container {
  padding: 0rem 1rem;
}

/* ======= ボタン ======= */
.btn {
  display: inline-block;
  padding: 0.6rem 1.2rem;
  font-size: 1rem;
  border-radius: 6px;
  font-weight: bold;
  text-align: center;
  border: none;
  cursor: pointer;
}
.btn-primary {
  background-color: #005baa;
  color: #fff;
}
.btn-primary:hover {
  background-color: #004080;
}
.btn-secondary {
  background-color: #6c757d;
  color: #fff;
}

/* ======= スライドショー画像 ======= */
.carousel-item img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 8px;
}

/* ======= パンくずリスト ======= */
.breadcrumb {
  background: transparent;
  padding-left: 0;
  font-size: 0.95rem;
  color: #6c757d;
}

/* ======= 医療科目ブロック調整 ======= */
/* 医療科目表示（トップページ用） */
.subject-row {
  display: flex;
  flex-direction: column;
  margin-bottom: 2rem;
  gap: 1.5rem;
}

.subject-img-wrapper {
  flex: none;
  width: 100%;
}
.subject-text {
  flex: none;
  width: 100%;
}

/* 画像のスタイル */
.subject-img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

/* 768px以上（PC向け）の表示 */
@media (min-width: 768px) {
  .subject-row {
    flex-direction: row;
    align-items: flex-start;
  }

  .subject-row.reverse {
    flex-direction: row-reverse;
  }

  /* 画像：40%、テキスト：60% に設定 */
  .subject-img-wrapper {
    width: 40%;
  }
  .subject-text {
    width: 60%;
  }
}

/* ======= 当院について ======= */
/* 当院について：レイアウト調整 */
.about-row {
  display: flex;
  flex-direction: column; /* スマホ時は縦並び */
  gap: 1.5rem;
  align-items: center;
}

/* PC表示時：画像左・テキスト右に */
@media (min-width: 768px) {
  .about-row {
    flex-direction: row;
    align-items: flex-start;
  }
  .about-image {
    max-width: 33%;
  }
  .about-text {
    flex: 1;
    padding-left: 2rem;
  }
}

/* ======= ギャラリー画像 ======= */
.gallery-image {
  object-fit: cover;
  aspect-ratio: 4/3;
  border-radius: 8px;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.08);
}

/* ======= フォーム ======= */
form label {
  font-weight: bold;
}
input[type="text"],
input[type="email"],
textarea {
  width: 100%;
  padding: 0.6rem;
  margin-bottom: 1rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
}

/* ======= アコーディオン（FAQ） ======= */
.accordion-button {
  background-color: #e6f0fa;
  color: #005baa;
  font-weight: bold;
}

/* ======= スクロールトップボタン ======= */
#scrollTop {
  display: none;
  position: fixed;
  bottom: 2rem;
  right: 1rem;
  z-index: 999;
  font-size: 1.6rem;
  padding: 0.6rem 0.8rem;
  border-radius: 50%;
  background-color: #005baa;
  color: #fff;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* ======= フッター ======= */
#footer * {margin: 0;padding: 0;}
#footer ul {list-style: none;}
#footer a {color: #fff;}

/*ブロック全体*/
#footer {
	background: var(--primary-color);		/*背景色。css冒頭のprimary-colorを読み込みます。*/
	color: var(--primary-inverse-color);	/*文字色。css冒頭のprimary-inverse-colorを読み込みます。*/
	padding: var(--content-space);	/*フッター内の余白。css冒頭のcontent-spaceを読み込みます。*/
}

#footer h3 {
	color: var(--primary-inverse-color);
}

#footer img {
	border: none;
	max-width: 100%;
	height: auto;
	vertical-align: middle;
}

/*ロゴやSNSアイコンが入ったブロック*/
#footer div.footer1 {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 1rem;	/*このブロック内のボックス同士の間に空ける余白。１文字分。*/
}

/*メニューブロック*/
#footer div.footer2 {
    flex: 1;
}

	/*画面700px以上の追加指定*/
	@media screen and (min-width:700px) {

	#footer {
		display: flex;
		gap: 2rem;		/*ロゴのブロックとメニューのブロックとの間の余白。2文字分。*/
	}

	/*ロゴやSNSアイコンが入ったブロック*/
	#footer div.footer1 {
		text-align: left;
		width: 40%;	/*幅。40%。*/
	}

	}/*追加指定ここまで*/


/*Copyright部分*/
#footer small {
	display: block;
	text-align: right;
	margin-top: 2rem;
}


/* ======= SNSアイコン ======= */
#footer .sns {
	list-style: none;
	margin: 0;padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;		/*アイコン同士のマージン的な要素。１文字分。*/
}

#footer .sns a {
	color: inherit;
}

#footer .sns i {
	font-size: 30px;	/*アイコンサイズ*/
}


/* ======= Google Map用 ======= */
#footer .iframe {
	width: 100%;
	height: 0;
	padding-top: 56.25% !important;	/*マップの高さを増やしたい場合は、ここの数値を上げてみて下さい。*/
	position: relative;
	overflow: hidden;
}
#footer .iframe iframe {
	position: absolute;
	left: 0px;
	top: 0px;
	width: 100%;
	height: 100%;
}


/* ======= フッター内の受付時間テーブル ======= */
.week {
	width: 100%;
	border-collapse: separate;
	border-spacing: 0;
	overflow: hidden;
	border-radius: 5px;	/*角を丸くする指定*/
	border: 1px solid #ccc;	/*テーブル外側の線の幅、線種、色*/
	table-layout: fixed;	/*幅を均等に*/
	background: #fff;		/*テーブル全体の背景色*/
	color: #555;			/*テーブル全体の文字色*/
}

/*受付時間の幅*/
.week th:first-child,
.week td:first-child {
	width: 25%;
}

/*各曜日の幅*/
.week th:not(:first-child),
.week td:not(:first-child) {
	width: calc(75% / 7);	/*受付時間で25%とっているので残りの75%を7で割る*/
}

/*th(曜日)とtd(時間)*/
.week th,
.week td {
	padding: 1rem 0;	/*ボックス内の余白。上下に１文字分、左右は0。*/
	text-align: center;	/*テキストをセンタリング*/
	border-bottom: 1px solid #ccc;	/*下の線の幅、線種、色*/
	border-right: 1px solid #ccc;	/*右の線の幅、線種、色*/
}

/*th(曜日)とtd(時間)のそれぞれ最後の右側の線を消す*/
.week th:last-child,
.week td:last-child {
	border-right: none;
}

/*最後の行の下線を消す*/
.week tr:last-child td {
	border-bottom: none;
}

/*th(曜日)の追加指定*/
.week th {
	background: #fafafa;	/*背景色*/
}
.week td {
	border-bottom: 1px solid #ccc;	/*下の線の幅、線種、色*/
}

/* お知らせ画像の枠とトリミング表示（トップページ用） */
.news-thumb-wrapper {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  width: 100%;
}

.news-thumb {
  width: 100%;
  
  height: 100%;
  object-fit: cover;
  object-position: top;
  border-radius: 8px;
}



/* ======= メディアクエリ（PC向け） ======= */
@media (min-width: 768px) {
  body {
    font-size: 1.05rem;
  }

  .container {
    max-width: 960px;
    margin: 0 auto;
  }
}

/* アニメーションキーフレーム */
@keyframes slideFadeIn {
  0% {
    opacity: 0;
    transform: translateY(20px); /* 下から */
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* h2 要素にアニメーションを適用 */
section h2 {
  animation: slideFadeIn 1s ease-out forwards;
  opacity: 0; /* 初期状態で非表示 */
  text-align: center; /* センター表示（中央揃え） */
	margin-top: 50px;
	margin-bottom: 30px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--primary-color);
}