/* リセットCSS */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

/* スプラッシュ画面 */
#splash-screen {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: #ffffff;
	display: flex;
	justify-content: center;
	align-items: center;
	z-index: 9999;
	opacity: 1;
	transition: opacity 0.8s ease-out;
}

#splash-screen.fade-out {
	opacity: 0;
	pointer-events: none;
}

.splash-content {
	text-align: center;
	animation: splash-fade-in 0.8s ease-out;
}

.splash-logo {
	width: 50px;
	height: auto;
}

@keyframes splash-fade-in {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

/* ベーススタイル */
body {
	font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "メイリオ", "Meiryo", "ＭＳ Ｐゴシック", "MS PGothic", sans-serif;
	font-size: 14px;
	line-height: 1.6;
	color: #333;
	background-color: #fff;
}

/* コンテナ */
#page {
	max-width: 980px;
	margin: 0 auto;
	padding: 0;
	min-height: 100vh;
}

/* ヘッダー */
.header {
	position: relative;
	margin-bottom: 6rem;
}

.header-content {
	display: flex;
	align-items: flex-start;
	gap: 60px;
	max-width: 980px;
	margin: 0 auto;
	padding: 0 20px;
}

.logo {
	flex-shrink: 0;
	margin-top: 27px;
}

.logo img {
	display: block;
}

/* デスクトップ表示の制御 */
.logo .desktop-logo {
	display: block;
}

.logo .mobile-logo {
	display: none;
}

.main-visual .desktop-main {
	display: block;
}

.main-visual .mobile-main {
	display: none;
}

.main-visual {
	flex: 1;
	position: relative;
}

.main-image {
	width: 100%;
	height: auto;
	display: block;
}

.site-title {
	position: absolute;
	top: 20px;
	right: 20px;
	color: #fff;
	font-size: 14px;
	line-height: 1.4;
	font-weight: normal;
	text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
	z-index: 10;
}

/* セクション共通スタイル */
section {
	margin-bottom: 53px;
}

.section-header {
	display: flex;
	align-items: flex-start;
	margin-bottom: 20px;
	position: relative;
	justify-content: flex-start;
}

.section-header img {
	display: block;
	flex-shrink: 0;
}

.section-header img:first-child {
	/* 左側のナビゲーション画像 */
	margin-right: 20px;
}

.section-header img:last-child {
	/* 右側の説明画像 */
	margin-left: 0;
}

/* ご案内セクション */
.guide-section {
	margin-bottom: 53px;
	display: flex;
	align-items: flex-start;
	gap: 20px;
}

.guide-section .section-header {
	margin-left: 0;
	flex-shrink: 0;
	display: flex;
	align-items: flex-start;
	gap: 20px;
}

.guide-section .section-header img:last-child {
	margin-left: 0;
	position: static;
	left: auto;
	top: auto;
	z-index: auto;
}

.content-grid {
	display: flex;
	gap: 20px;
	margin-left: 0;
	justify-content: flex-start;
	align-items: flex-start;
	flex: 1;
}

.content-item {
	flex: 1;
	max-width: 379px;
}

.content-link {
	display: block;
	margin-bottom: 10px;
}

.content-link img {
	display: block;
	width: 100%;
	height: auto;
}

.content-label {
	display: block;
	margin: 10px auto 0;
}

/* 善應院のご紹介セクション */
.introduction-section {
	margin-bottom: 42px;
	display: flex;
	align-items: flex-start;
	gap: 20px;
}

.introduction-section .section-header {
	margin-left: 0;
	flex-shrink: 0;
	display: flex;
	align-items: flex-start;
	gap: 20px;
}

.introduction-section .section-header img:last-child {
	margin-left: 0;
	position: static;
	left: auto;
	top: auto;
	z-index: auto;
}

.introduction-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	margin-left: 0;
	justify-content: flex-start;
	align-items: flex-start;
	flex: 1;
}


.intro-item {
	text-align: center;
}

.intro-link {
	display: block;
	margin-bottom: 13px;
}

.intro-link img {
	display: block;
	width: 100%;
	height: auto;
}

.intro-item h2 {
	font-family: "ヒラギノ明朝 Pro W3", "Hiragino Mincho Pro", "ＭＳ Ｐ明朝", "MS PMincho", serif;
	font-size: 14px;
	line-height: 25px;
	margin-bottom: 0;
}

.intro-item h2 a {
	color: inherit;
	text-decoration: none;
}

/* お墓のご案内セクション */
.grave-section {
	margin-bottom: 79px;
	display: flex;
	align-items: flex-start;
	gap: 20px;
	max-width: 980px;
	margin-left: auto;
	margin-right: auto;
}

.grave-section .section-header {
	margin-left: 0;
	flex-shrink: 0;
	display: flex;
	align-items: flex-start;
	gap: 20px;
}

.grave-section .section-header img:last-child {
	margin-left: 0;
	position: static;
	left: auto;
	top: auto;
	z-index: auto;
}

.grave-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	margin-left: 0;
	justify-content: flex-start;
	align-items: flex-start;
	flex: 1;
}

.grave-item {
	flex: 0 0 calc(50% - 10px);
	max-width: 379px;
	text-align: center;
}

.grave-link {
	display: block;
	margin-bottom: 10px;
}

.grave-link img {
	display: block;
	width: 100%;
	max-width: 379px;
	height: auto;
}

.grave-link:hover img {
	opacity: 0.8;
}

.grave-link:hover {
	text-decoration: none;
}

.grave-link:visited {
	color: inherit;
}

.grave-link:link {
	color: inherit;
}

.grave-link:focus {
	color: inherit;
	outline: none;
}

.grave-item h2 {
	font-family: "alice", serif;
	font-size: 18px;
	line-height: 32px;
	font-weight: 400;
	margin-bottom: 0;
}

.grave-item h2 a {
	color: inherit;
	text-decoration: none;
}

/* セルフ葬バナー */
.self-banner {
	margin: 40px 0;
	text-align: center;
}

.self-banner img {
	display: block;
	width: 100%;
	height: auto;
	margin-bottom: 32px;
}

.self-banner h2 {
	font-family: "alice", serif;
	font-size: 18px;
	line-height: 32px;
	font-weight: 400;
	margin: 0;
}

.self-banner h2 a {
	color: inherit;
	text-decoration: none;
}

/* 画像ギャラリー */
.gallery {
	margin: 20px auto;
}

.gallery-content {
	display: flex;
	gap: 20px;
	align-items: start;
	justify-content: space-between;
	width: 100%;
}

.gallery-content > div {
	flex: 1;
	display: flex;
	flex-direction: column;
}

.gallery-content > div h3 {
	font-size: 16px;
	font-weight: bold;
	margin-bottom: 10px;
	color: #333;
	text-align: center;
}

.gallery-content > div img,
.gallery-content > a img {
	display: block;
	width: 100%;
	height: 390px;
}

.gallery-content > a {
	flex: 1;
	display: block;
}

/* お知らせセクション */
.news-section {
	margin: 20px auto 60px;
	width: 100%;
	box-sizing: border-box;
	border: 1px solid #e8e8e8;
	border-radius: 1rem;
	padding: 20px;
}

.news-header {
	display: flex;
	gap: 20px;
	margin-bottom: 20px;
}

.news-header h2 {
	font-family: "ヒラギノ明朝 Pro W3", "Hiragino Mincho Pro", "ＭＳ Ｐ明朝", "MS PMincho", serif;
	font-size: 20px;
	line-height: 35px;
	margin: 0;
	color: #333;
}

.news-content {
	cursor: pointer;
	position: relative;
	width: 100%;
}

.news-text {
	width: 100%;
	max-width: none;
	position: relative;
}

.news-preview,
.news-full {
	transition: all 0.3s ease;
}

.news-preview {
	padding-bottom: 20px;
}

.news-text p {
	margin-bottom: 0;
	line-height: 25px;
	font-size: 14px;
	color: #333;
}

.news-text p:not(:last-child) {
	margin-bottom: 10px;
}

.news-text a {
	color: #900303;
	text-decoration: none;
	transition: all 0.3s ease;
	font-weight: 600;
}

.news-text a:hover {
	color: #666;
	text-decoration-color: #666;
}

.fade-overlay {
	position: absolute;
	bottom: 70px;
	left: 0;
	right: 0;
	height: 80px;
	background: linear-gradient(transparent, rgba(255, 255, 255, 0.3) 20%, rgba(255, 255, 255, 0.7) 60%, rgba(255, 255, 255, 0.95) 100%);
	pointer-events: none;
	z-index: 1;
}

.read-more {
	text-align: center;
	padding: 10px;
	font-size: 14px;
	color: #666;
	border-top: 1px solid #eee;
	margin-top: 40px;
	cursor: pointer;
	transition: color 0.3s ease;
	position: relative;
	z-index: 2;
	background-color: white;
}

.read-more:hover {
	color: #333;
}


.facebook-widget {
	flex: 1;
	width: 100%;
	text-align: center;
}

.facebook-widget iframe {
	width: 100% !important;
	max-width: 100%;
}

/* フッター */
.footer {
margin:100px auto 20px;
padding:0 20px;
}

.footer-nav {
	display: flex;
	justify-content: center;
	gap: 20px;
	margin-bottom: 8px;
	flex-wrap: wrap;
}

.footer-nav a {
	color: #333;
	text-decoration: none;
	font-size: 14px;
	line-height: 25px;
}

.footer-nav a:hover {
    opacity: 0.8;
}

.copyright {
	margin-top: 8px;
	text-align: center;
}

.copyright p {
	font-size: 14px;
	line-height: 25px;
	margin: 0;
}

.copyright a {
	color: #333;
	text-decoration: none;
}

/* モバイル対応 */
@media (max-width: 768px) {
	/* ファーストビューのレスポンシブ対応 */
	.header-content {
		display: block;
		margin: 40px auto;
	}

	.logo {
		padding-top: 20px;
		order: 1;
	}

	.logo .desktop-logo {
		display: none;
	}

	.logo .mobile-logo {
		display: block;
		width: 200px;
		height: auto;
		margin-bottom: 20px;
	}

	.main-visual {
		flex: 1;
		order: 2;
		width: 100%;
	}

	.main-visual .desktop-main {
		display: none;
	}

	.main-visual .mobile-main {
		display: block;
		width: 100%;
		height: auto;
	}

	.site-title {
		position: static;
		order: 3;
		color: #333;
		font-size: 12px;
		text-shadow: none;
		margin-top: 10px;
	}

	/* 善應院のご紹介セクションを2カラムに */
	.introduction-grid {
		display: grid !important;
		grid-template-columns: 1fr 1fr !important;
		gap: 15px;
		margin-left: 0;
		max-width: 100%;
		width: 100%;
	}
	
	.footer-nav {
		gap: 10px;
	}
	
	.copyright p {
	font-size: 12px;
}

	.intro-item {
		width: 100%;
		text-align: center;
	}

	.intro-item img {
		width: 100%;
		height: auto;
		/* max-width: 112px; */
		margin: 0 auto;
	}

	.intro-item h2 {
		font-size: 12px;
		line-height: 1.4;
		margin-top: 8px;
	}

	.intro-item h2 a {
		text-decoration: none;
	}

	.intro-item h2 a:hover {
	}

	/* その他のセクションも調整 */
	.guide-section,
	.grave-section {
		flex-direction: column;
		align-items: center;
	}

	.section-header {
		flex-direction: column;
		align-items: center;
		margin-bottom: 20px;
	}

	.content-grid,
	.grave-grid {
		flex-direction: column;
		align-items: center;
		margin-left: 0;
	}

	.content-item,
	.grave-item {
		margin-bottom: 20px;
	}

	/* 善應院のご紹介セクションのレイアウト調整 */
	.introduction-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 20px;
	}

	.introduction-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.introduction-section .introduction-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	/* ご案内セクションのレイアウト調整 */
	.guide-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 20px;
	}

	.guide-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.guide-section .content-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	/* ギャラリーセクションのレイアウト調整 */
	.gallery-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 20px;
	}

	.gallery-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.gallery-section .content-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	/* お墓のご案内セクションのレイアウト調整 */
	.grave-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 20px;
	}

	.grave-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.grave-section .grave-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	/* 追加のレスポンシブスタイル */
	#page {
		max-width: 100%;
		padding: 0 20px;
	}

	.main-visual {
		margin-left: 0;
	}

	.side-image {
		position: static;
		margin-top: 20px;
	}

	.content-item,
	.intro-item,
	.grave-item {
		max-width: 100%;
		width: 100%;
	}

	.contact-info {
		flex-direction: column;
		margin-left: 0;
	}

	.gallery-content {
		flex-direction: column;
		gap: 25px;
	}
	
	.gallery-content > div img,
	.gallery-content > a img {
	height: auto;
	}
	
	.gallery-content > div h3 {
		font-size: 14px;
		margin-bottom: 8px;
	}

	.news-section {
		margin: 15px auto;
		padding: 15px;
	}
	
	.news-header {
		margin-bottom: 15px;
	}
	
	.news-header h2 {
		font-size: 18px;
	}
	
	.news-text p {
		font-size: 13px;
		line-height: 22px;
	}
	
	.read-more {
		font-size: 13px;
		padding: 8px;
	}
	
	/* スプラッシュ画面（モバイル） */
	.splash-logo {
		width: 40px;
	}

	.self-banner {
		margin: 0;
		text-align: center;
	}

	.footer {
	margin: 80px auto 20px;
	}

}

/* スマートフォン対応 */
@media (max-width: 480px) {
	/* ファーストビューのスマートフォン対応 */
	.header-content {
		flex-direction: row;
		align-items: flex-start;
		gap: 15px;
		padding: 0 5px;
	}

	.logo {
		flex-shrink: 0;
		margin-top: 0;
		order: 1;
	}

	.logo img {
		width: 40px;
		height: auto;
	}

	.main-visual {
		flex: 1;
		order: 2;
		width: 100%;
	}

	.main-image {
		width: 100%;
		height: auto;
	}

	.site-title {
		position: static;
		order: 3;
		color: #333;
		font-size: 10px;
		text-shadow: none;
		margin-top: 5px;
	}

	/* 善應院のご紹介セクションを1カラムに */
	.introduction-grid {
		grid-template-columns: 1fr;
		gap: 10px;
	}

	/* 善應院のご紹介セクションのレイアウト調整（スマートフォン） */
	.introduction-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 15px;
	}

	.introduction-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.introduction-section .introduction-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	.intro-item {
		align-self: flex-start;
	}

	.intro-item img {
		width: 100%;
		height: auto;
		/* max-width: 120px; */
		margin: 0 auto;
	}

	/* ご案内セクションのレイアウト調整（スマートフォン） */
	.guide-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 15px;
	}

	.guide-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.guide-section .content-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	/* ギャラリーセクションのレイアウト調整（スマートフォン） */
	.gallery-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 15px;
	}

	.gallery-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.gallery-section .content-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	/* お墓のご案内セクションのレイアウト調整（スマートフォン） */
	.grave-section {
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		gap: 15px;
	}

	.grave-section .section-header {
		flex-shrink: 0;
		margin-bottom: 0;
		align-self: flex-start;
	}

	.grave-section .grave-grid {
		flex: 1;
		margin-left: 0;
		align-self: flex-start;
	}

	.intro-item {
		margin-bottom: 15px;
		align-self: flex-start;
	}

	.intro-item img {
		width: 100%;
		height: auto;
	}

	.intro-item h2 {
		font-size: 14px;
	}
}



@media (max-width: 480px) {
	.section-header {
		flex-direction: column;
		align-items: center;
	}

	.section-header img:last-child {
		margin-left: 0;
		margin-top: 10px;
		position: static;
		left: auto;
		top: auto;
	}


}

/* お問い合わせセクション */
.contact-section {
	margin: 40px 0;
}

.footer-contact {
	margin: 0 auto;
	border-radius: 8px;
	padding: 30px;
	background-color: #f0f0f0;
	max-width: 980px;
}

.contact-header {
	text-align: center;
	margin-bottom: 25px;
}

.contact-header h3 {
	font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "メイリオ", "Meiryo", "ＭＳ Ｐゴシック", "MS PGothic", sans-serif;
	font-size: 24px;
	font-weight: bold;
	color: #333;
	margin: 0 0 10px 0;
}

.contact-header p {
	font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "メイリオ", "Meiryo", "ＭＳ Ｐゴシック", "MS PGothic", sans-serif;
	font-size: 16px;
	color: #666;
	margin: 0;
}

.contact-info {
	display: flex;
	justify-content: center;
	gap: 20px;
	align-items: center;
	position: relative;
}

.phone-contact {
	display: flex;
	align-items: center;
	gap: 15px;
}

.phone-contact img {
	width: 35px;
	height: 35px;
}

.phone-contact p {
	font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "メイリオ", "Meiryo", "ＭＳ Ｐゴシック", "MS PGothic", sans-serif;
	font-size: 20px;
	font-weight: bold;
	color: #333;
	margin: 0;
	text-decoration: none;
}

.email-contact {
	display: flex;
	align-items: center;
	gap: 15px;
	background-color: #8b2b2b;
	color: #fff;
	padding: 15px 25px;
	border-radius: 8px;
	text-decoration: none;
	transition: all 0.3s ease;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.email-contact:hover {
	background-color: #9f2a2a;
	transform: translateY(-2px);
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.email-contact img {
	width: 35px;
	height: 35px;
	filter: brightness(0) invert(1);
}

.email-contact p {
	font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "メイリオ", "Meiryo", "ＭＳ Ｐゴシック", "MS PGothic", sans-serif;
	font-size: 18px;
	font-weight: bold;
	color: #fff;
	margin: 0;
}
