/* ============================
   リセット & 共通設定
============================ */

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	padding: 40px 0 80px;
	font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "メイリオ", sans-serif;
	background:
		radial-gradient(circle at 0% 0%, #1f2937 0, transparent 55%),
		radial-gradient(circle at 100% 100%, #020617 0, transparent 55%),
		#020617;
	color: #e5e7eb;
	display: flex;
	flex-direction: column;
	align-items: center;
}

h1,
#slider,
section {
	width: 1120px;
	max-width: 1120px;
}

/* ============================
   タイトル
============================ */

h1 {
	margin: 0 0 24px;
	font-size: 42px;
	font-weight: 800;
	letter-spacing: 0.12em;
	color: #bbf7d0;
	text-shadow:
		0 0 18px rgba(34, 197, 94, 0.55),
		0 2px 0 #052e16;
	text-align: left;
}

/* ============================
   セクション共通
============================ */

section {
	margin-top: 40px;
	padding: 28px 32px;
	background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.94));
	border-radius: 18px;
	border: 1px solid rgba(148, 163, 184, 0.35);
	box-shadow:
		0 24px 60px rgba(0, 0, 0, 0.85),
		0 0 0 1px rgba(15, 23, 42, 0.9);
}

h2 {
	margin: 0 0 18px;
	font-size: 24px;
	font-weight: 700;
	color: #a3e635;
	text-shadow: 0 0 10px rgba(190, 242, 100, 0.5);
}

section p {
	margin: 0;
	font-size: 15px;
	line-height: 1.9;
	color: #cbd5f5;
}

/* ============================
   ★ スライダー（JS連動版）※これが最重要
============================ */

#slider {
	margin-bottom: 40px;
	border-radius: 22px;
	overflow: hidden;
	position: relative;
	background: #020617;
	height: 460px; /* ←重要：高さ指定しないと何も表示されない */
	box-shadow:
		0 34px 80px rgba(0, 0, 0, 0.9),
		0 0 0 1px rgba(15, 23, 42, 0.9);
}

/* スライドは重ねる＋透明からスタート */
#slider .slide {
	position: absolute;
	inset: 0;             /* top, left, right, bottom 全て0 */
	opacity: 0;
	transition: opacity 1s ease-in-out;
}

/* JSがis-activeをつけて表示する */
#slider .slide.is-active {
	opacity: 1;
}

/* 最初の一枚が表示されるよう保険 */
#slider .slide:first-child {
	opacity: 1;
}

#slider .slide img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* スライダー上に軽いグラデーションマスク */
#slider::after {
	content: "";
	position: absolute;
	inset: 0;
	background:
		linear-gradient(to top, rgba(15, 23, 42, 0.9), transparent 40%),
		radial-gradient(circle at 0 0, rgba(34, 197, 94, 0.35), transparent 55%);
	pointer-events: none;
}

/* ============================
   テラリアとは？
============================ */

#about {
	position: relative;
	overflow: hidden;
}

#about::before {
	content: "";
	position: absolute;
	inset: -40%;
	background:
		radial-gradient(circle at 0 0, rgba(56, 189, 248, 0.06), transparent 60%),
		radial-gradient(circle at 100% 100%, rgba(52, 211, 153, 0.12), transparent 60%);
	opacity: 0.9;
	pointer-events: none;
}

#about h2,
#about p {
	position: relative;
	z-index: 1;
}

/* ============================
   feature（魅力紹介）
============================ */

#favorite {
	margin-top: 50px;
}

.feature {
	display: flex;
	align-items: center;
	gap: 28px;
	padding: 22px 24px;
	margin-top: 18px;
	border-radius: 16px;
	background: radial-gradient(circle at 0 0, rgba(34, 197, 94, 0.18), transparent 60%),
				rgba(15, 23, 42, 0.95);
	border: 1px solid rgba(55, 65, 81, 0.9);
	box-shadow: 0 14px 40px rgba(0, 0, 0, 0.8);
}

.feature-img {
	flex: 0 0 260px;
	border-radius: 14px;
	overflow: hidden;
	box-shadow:
		0 18px 35px rgba(0, 0, 0, 0.9),
		0 0 0 1px rgba(15, 23, 42, 0.9);
}

.feature-img img {
	width: 100%;
	display: block;
	object-fit: cover;
}

.feature-text {
	flex: 1 1 auto;
}

.feature-text h3 {
	margin: 0 0 6px;
	font-size: 18px;
	font-weight: 700;
	color: #bef264;
}

.feature-text p {
	font-size: 14px;
	line-height: 1.9;
	color: #e5e7f5;
}

/* 画像が無い3番目と4番目のカード補正 */
#favorite .feature:nth-of-type(3),
#favorite .feature:nth-of-type(4) {
	justify-content: flex-start;
	padding-left: 30px;
}

/* ============================
   フォーム
============================ */

#formArea {
	margin-top: 60px;
	background:
		radial-gradient(circle at 0 0, rgba(96, 165, 250, 0.16), transparent 60%),
		radial-gradient(circle at 100% 100%, rgba(45, 212, 191, 0.18), transparent 60%),
		rgba(15, 23, 42, 0.98);
	border-radius: 20px;
	border: 1px solid rgba(148, 163, 184, 0.55);
	box-shadow:
		0 26px 70px rgba(0, 0, 0, 0.9),
		0 0 0 1px rgba(15, 23, 42, 1);
}

label {
	display: block;
	margin: 14px 0;
	font-size: 14px;
	color: #e5e7eb;
}

input,
textarea {
	width: 100%;
	margin-top: 6px;
	padding: 10px 12px;
	border-radius: 10px;
	border: 1px solid rgba(148, 163, 184, 0.7);
	background: rgba(15, 23, 42, 0.95);
	color: #e5e7eb;
	font-size: 14px;
	transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}

input:focus,
textarea:focus {
	border-color: #22c55e;
	box-shadow:
		0 0 0 1px rgba(34, 197, 94, 0.55),
		0 0 18px rgba(34, 197, 94, 0.45);
	background: #020617;
}

textarea {
	min-height: 140px;
	resize: vertical;
}

button {
	display: inline-block;
	margin-top: 10px;
	margin-right: 10px;
	padding: 9px 28px;
	border-radius: 999px;
	border: none;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	color: #022c22;
	background: radial-gradient(circle at 0 0, #4ade80, #22c55e);
	box-shadow:
		0 14px 30px rgba(34, 197, 94, 0.55),
		0 0 0 1px rgba(21, 128, 61, 0.8);
	transition: 0.12s;
}

button:hover {
	transform: translateY(-2px);
}

button:active {
	transform: translateY(0);
}

#formMessage {
	margin-top: 14px;
	font-size: 14px;
	font-weight: 500;
	color: #bef264;
}

/* =========================================================
   送信ボタンの光エフェクト付きデザイン
========================================================= */

#send {
    position: relative;
    overflow: hidden;
}

/* ボタンを横切る光（シャイン） */
#send::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255, 255, 255, 0.6),
        transparent
    );
    transform: skewX(-20deg);
}

/* クリック時に光が走るアニメーション */
#send.animate-shine::before {
    animation: shine 0.6s ease-out;
}

@keyframes shine {
    0% { left: -120%; }
    100% { left: 120%; }
}

/* ======================
   ローディング状態
====================== */

#send.loading {
    pointer-events: none;
    color: transparent; /* テキストを隠す（Loading表示にする） */
}

/* ローディングのクルクル */
#send.loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 22px;
    height: 22px;
    border: 3px solid rgba(255, 255, 255, 0.35);
    border-top-color: white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to   { transform: translate(-50%, -50%) rotate(360deg); }
}

