/*
 * Contact Form — 専用スタイル
 *
 * プラグインなし独自フォーム（page-contact.php）のスタイル。
 * コンタクトページ（スラッグ "contact"）のみ読み込み。
 * 旧 .mw_wp_form セレクタから .sf-contact-form / .sf-* セレクタに移行。
 */

/* ─── ステップインジケーター ─────────────────────────────────── */
.sf-steps {
	display: flex;
	align-items: center;
	margin-bottom: 2.4rem;
}
.sf-step {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 4.4rem;
	height: 4.4rem;
	border-radius: 50%;
	background: #fff;
	border: 1px solid #222223;
	color: #222223;
	font-family: 'Economica', sans-serif;
	font-size: 1.2rem;
	letter-spacing: 0.05em;
	flex-shrink: 0;
}
.sf-step--active {
	background: #222223;
	color: #fff;
	border-color: #222223;
}
.sf-step--done {
	background: #fff;
	color: #222223;
	border-color: #222223;
}
.sf-step-sep {
	flex: 0 0 4rem;
	height: 1px;
	background: #ccc;
}

/* ─── フォームコンテナ ─────────────────────────────────────── */
.sf-contact-form {
	max-width: 100%;
}

/* 説明文・注記もフォームと幅を揃える */
.entry-content > p {
	max-width: 100%;
}

@media (max-width: 950px) {
	.sf-contact-form,
	.entry-content > p {
		max-width: 100%;
	}
}

/* ─── ハニーポット（完全非表示） ─────────────────────────── */
.sf-hp {
	position: absolute;
	left: -9999px;
	top: -9999px;
	width: 0;
	height: 0;
	overflow: hidden;
	opacity: 0;
	pointer-events: none;
}

/* ─── 段落ラッパー ────────────────────────────────────────── */
.sf-contact-form > p {
	margin-bottom: 1.4rem;
}

/* ─── label ───────────────────────────────────────────────── */
.sf-contact-form label {
	display: block;
	font-size: 1.5rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	margin-bottom: 0.6rem;
}

/* ─── 必須マーク ─────────────────────────────────────────── */
.sf-required {
	color: #b70000;
	margin-left: 0.2em;
}

/* ─── テキスト・メール・電話・テキストエリア ──────────────── */
.sf-contact-form input[type="text"],
.sf-contact-form input[type="email"],
.sf-contact-form input[type="tel"],
.sf-contact-form textarea {
	font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic Medium", "Yu Gothic", Meiryo, sans-serif;
	font-size: 1.6rem;
	font-weight: 300;
	width: 100%;
	border: 1px solid #222223;
	border-radius: 2px;
	color: #222223;
	padding: 1.5rem 1.5rem;
	margin-bottom: 0;
	background: #fff;
	letter-spacing: 0.05em;
	transition: border-color 0.2s ease;
	-webkit-appearance: none;
}
.sf-contact-form input[type="text"]:focus,
.sf-contact-form input[type="email"]:focus,
.sf-contact-form input[type="tel"]:focus,
.sf-contact-form textarea:focus {
	border-color: #646464;
	outline: none;
}
/* クリック・キーボード共通: inset box-shadow で全4辺に確実に表示
   outline は Chrome で左端がクリップされることがあるため使用しない */
.sf-contact-form input[type="text"]:focus-visible,
.sf-contact-form input[type="email"]:focus-visible,
.sf-contact-form input[type="tel"]:focus-visible,
.sf-contact-form textarea:focus-visible {
	border-color: #222223;
	outline: none;
	box-shadow: inset 0 0 0 2px #222223;
}
.sf-contact-form textarea {
	min-height: 160px;
	resize: vertical;
}
.sf-contact-form ::-webkit-input-placeholder { color: #767676; }
.sf-contact-form :-moz-placeholder            { color: #767676; }
.sf-contact-form ::-moz-placeholder           { color: #767676; opacity: 1; }
.sf-contact-form :-ms-input-placeholder       { color: #767676; }

/* ─── セレクト ────────────────────────────────────────────── */
.sf-contact-form select {
	font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic Medium", "Yu Gothic", Meiryo, sans-serif;
	font-size: 1.6rem;
	font-weight: 300;
	width: 100%;
	border: 1px solid #222223;
	border-radius: 2px;
	color: #222223;
	padding: 1.5rem 3.6rem 1.5rem 1.5rem;
	margin-bottom: 0;
	background-color: #fff;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 9'%3E%3Cpath stroke='%23222223' stroke-width='1.5' fill='none' d='M1 1l7 7 7-7'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 1.4rem center;
	background-size: 1rem auto;
	letter-spacing: 0.05em;
	transition: border-color 0.2s ease;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
}
.sf-contact-form select:focus {
	border-color: #646464;
	outline: none;
}
.sf-contact-form select:focus-visible {
	border-color: #222223;
	outline: none;
	box-shadow: inset 0 0 0 2px #222223;
}

/* ─── チェックボックス ────────────────────────────────────── */
.sf-checkbox-wrap {
	margin-top: 1.4rem;
	margin-bottom: 1.4rem;
}
.sf-checkbox-wrap > label {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	cursor: pointer;
	font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic Medium", "Yu Gothic", Meiryo, sans-serif;
	font-size: 1.3rem;
	letter-spacing: 0.05em;
	margin-bottom: 0;
}
.sf-checkbox-wrap input[type="checkbox"] {
	width: auto;
	margin: 0;
	accent-color: #222223;
	cursor: pointer;
}

/* ─── プライバシーノート ──────────────────────────────────── */
.sf-privacy-note {
	font-size: 1.1rem !important;
	color: #c0392b;
	background: #fff0f0;
	border: 1px solid #f5c6cb;
	border-radius: 4px;
	padding: 1.5em;
	margin-top: 1em;
	margin-bottom: 1.4rem;
	line-height: 1.7;
}

/* ─── お知らせ注記 ───────────────────────────────────────── */
.sf-notice {
	font-size: 1.1rem;
	color: #888;
	margin-top: -0.6rem;
	margin-bottom: 1.4rem;
	line-height: 1.7;
}

/* ─── エラー表示 ─────────────────────────────────────────── */
.sf-error {
	font-size: 1.2rem;
	color: #b70000;
	display: block;
	margin-top: 0.3rem;
}
.sf-error-summary {
	font-size: 1.3rem;
	color: #b70000;
	margin-bottom: 1.4rem;
}

/* ─── 同意文 ─────────────────────────────────────────────── */
.sf-privacy-consent {
	font-size: 1.1rem;
	color: #646464;
	margin-top: 1.4rem;
	margin-bottom: 0;
}
.sf-privacy-consent a {
	color: #646464;
	text-underline-offset: 0.2em;
}

/* ─── ボタン ─────────────────────────────────────────────── */
.sf-btn-submit {
	font-family: 'Economica', sans-serif;
	font-size: 1.3rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	background-color: #444444;
	color: #fff;
	border: 0;
	border-radius: 100px;
	padding: 1rem 2.8rem;
	box-sizing: border-box;
	min-width: 16em;
	cursor: pointer;
	transition: background-color 0.2s ease;
}
.sf-btn-submit:hover,
.sf-btn-submit:focus {
	background-color: #666666;
	color: #fff;
	outline: 0;
}
.sf-btn-back {
	font-family: 'Economica', sans-serif;
	font-size: 1.3rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	background-color: transparent;
	color: #444444;
	border: 1px solid #444444;
	border-radius: 100px;
	padding: 1rem 2.8rem;
	box-sizing: border-box;
	min-width: 16em;
	cursor: pointer;
	transition: all 0.2s ease;
}
.sf-btn-back:hover,
.sf-btn-back:focus {
	background-color: #f5f5f5;
	color: #222223;
	outline: 0;
}

/* ─── SNS リンク ────────────────────────────────────────── */
.sf-social-links {
	display: flex;
	gap: 1.2rem;
	margin-top: 5rem;
}
.sf-social-links__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 1rem 2.8rem;
	background: #444444;
	color: #fff;
	font-family: 'Economica', sans-serif;
	font-size: 1.3rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-decoration: none;
	border-bottom: none !important;
	border-radius: 100px;
	transition: background 0.2s ease;
}
.sf-social-links__btn:hover {
	background: #666666;
	color: #fff;
}

/* ─── ボタン行（確認ステップで並ぶ） ─────────────────────── */
.sf-contact-buttons {
	display: flex;
	gap: 1em;
	align-items: center;
	margin-top: 2em;
	flex-wrap: wrap;
}
.sf-contact-buttons form {
	margin: 0;
}

/* ─── 確認ステップ ────────────────────────────────────────── */
.sf-step-label {
	font-size: 1.3rem;
	color: #444;
	margin-bottom: 1.4rem;
}
.sf-confirm-list {
	max-width: 100%;
	margin: 0 0 2em;
}
/* 入力画面と同じ縦並び（ラベルが上、値が下）でユーザビリティを揃える */
.sf-confirm-list > div {
	display: block;
	padding: 1em 0;
}
.sf-confirm-list dt {
	color: #888;
	letter-spacing: 0.05em;
	margin-bottom: 0.4rem;
}
.sf-confirm-list dd {
	word-break: break-all;
	margin: 0;
}
.sf-confirm-list .sf-confirm-message dd {
	white-space: pre-wrap;
}

/* ─── 完了メッセージ ─────────────────────────────────────── */
.sf-contact-done {
	max-width: 100%;
	font-size: 1.3rem;
	line-height: 2;
}
.sf-contact-done p + p {
	margin-top: 1.5em;
}

/* ─── モバイル最適化 (max-width: 950px) ─────────────────────── */
@media (max-width: 950px) {

	/* ① iOS Safari 自動ズーム防止（font-size < 16px でズームが発動する） */
	.sf-contact-form input[type="text"],
	.sf-contact-form input[type="email"],
	.sf-contact-form input[type="tel"],
	.sf-contact-form textarea,
	.sf-contact-form select {
		font-size: 16px;
		padding: 1.8rem 1.5rem; /* ④ タップ領域を少し広げる */
	}

	/* ② ボタンを44px以上のタップ領域に */
	.sf-btn-submit,
	.sf-btn-back {
		width: 100%;
		padding: 1.4rem 2.4rem;
		font-size: 1.4rem;
		min-height: 44px;
		box-sizing: border-box;
	}

	/* ③ 確認画面のボタンを縦並び・送信を上に */
	.sf-contact-buttons {
		flex-direction: column-reverse;
	}
	.sf-contact-buttons form {
		width: 100%;
	}
}
