/**
 * とことこ湘南 イベント投稿フォーム
 *
 * 色は先頭の変数だけ差し替えれば全体に反映される。
 *
 * サイズは em で指定する。テーマの Bootstrap が html{font-size:10px} を
 * 当てているため、rem を使うと 10px 基準になって極端に小さくなる。
 */

.tkevf {
	--tkevf-text: #1f2328;
	--tkevf-muted: #646970;
	--tkevf-line: #d6dade;
	--tkevf-bg-soft: #f6f7f8;
	--tkevf-accent: #1f6feb;
	--tkevf-accent-dark: #1957b8;
	--tkevf-required-bg: #d63638;
	--tkevf-error: #b32d2e;
	--tkevf-error-bg: #fdf0f0;
	--tkevf-done-bg: #eef7f0;
	--tkevf-done-line: #a7d3b3;

	max-width: 780px;
	margin: 0 auto;
	color: var(--tkevf-text);
	font-size: 16px;
	line-height: 1.8;
}

.tkevf *,
.tkevf *::before,
.tkevf *::after {
	box-sizing: border-box;
}

/* ---------------------------------------------- セクション見出し */

.tkevf-section {
	margin: 2.5em 0 1.2em;
	padding: 0.6em 0.9em;
	background: var(--tkevf-bg-soft);
	border-radius: 6px;
	font-size: 1.05em;
	font-weight: 700;
	line-height: 1.5;
}

.tkevf-section:first-child {
	margin-top: 0;
}

/* ---------------------------------------------- 各項目 */

.tkevf-row {
	margin-bottom: 1.6em;
}

.tkevf-label {
	display: flex;
	align-items: center;
	gap: 0.6em;
	margin-bottom: 0.5em;
	font-size: 1.05em;
	font-weight: 700;
	line-height: 1.5;
}

.tkevf-required {
	flex: none;
	padding: 0.15em 0.55em;
	border-radius: 3px;
	background: var(--tkevf-required-bg);
	color: #fff;
	font-size: 0.72em;
	font-weight: 700;
	letter-spacing: 0.04em;
}

.tkevf-input input[type="text"],
.tkevf-input input[type="url"],
.tkevf-input input[type="tel"],
.tkevf-input textarea {
	display: block;
	width: 100%;
	padding: 0.65em 0.8em;
	border: 1px solid var(--tkevf-line);
	border-radius: 6px;
	background: #fff;
	color: inherit;
	font-family: inherit;
	font-size: 1em;
	line-height: 1.7;
}

.tkevf-input textarea {
	resize: vertical;
}

.tkevf-input input[type="text"]:focus,
.tkevf-input input[type="url"]:focus,
.tkevf-input input[type="tel"]:focus,
.tkevf-input textarea:focus,
.tkevf-input input[type="file"]:focus-visible {
	outline: 2px solid var(--tkevf-accent);
	outline-offset: 1px;
	border-color: var(--tkevf-accent);
}

.tkevf-input input[type="file"] {
	display: block;
	width: 100%;
	padding: 0.6em;
	border: 1px dashed var(--tkevf-line);
	border-radius: 6px;
	background: var(--tkevf-bg-soft);
	font-size: 0.95em;
}

/* ---------------------------------------------- カテゴリ */

.tkevf-checks {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5em 0.75em;
}

.tkevf-check {
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	padding: 0.35em 0.85em;
	border: 1px solid var(--tkevf-line);
	border-radius: 999px;
	background: #fff;
	cursor: pointer;
	font-size: 1em;
	line-height: 1.5;
}

.tkevf-check:hover {
	border-color: var(--tkevf-accent);
}

.tkevf-check input {
	margin: 0;
}

/* ---------------------------------------------- 補足・エラー */

.tkevf-help {
	margin: 0.45em 0 0;
	color: var(--tkevf-muted);
	font-size: 0.92em;
	line-height: 1.7;
}

.tkevf-error {
	margin: 0.45em 0 0;
	color: var(--tkevf-error);
	font-size: 0.9em;
	font-weight: 700;
	line-height: 1.6;
}

.tkevf-row.is-error input[type="text"],
.tkevf-row.is-error input[type="url"],
.tkevf-row.is-error input[type="tel"],
.tkevf-row.is-error textarea,
.tkevf-row.is-error input[type="file"] {
	border-color: var(--tkevf-error);
	background: var(--tkevf-error-bg);
}

.tkevf-alert {
	margin: 0 0 2em;
	padding: 1.1em 1.3em;
	border: 1px solid var(--tkevf-error);
	border-radius: 6px;
	background: var(--tkevf-error-bg);
}

.tkevf-alert__title {
	margin: 0 0 0.5em;
	color: var(--tkevf-error);
	font-weight: 700;
}

.tkevf-alert__list {
	margin: 0;
	padding-left: 1.3em;
	font-size: 0.95em;
}

.tkevf-alert__list li + li {
	margin-top: 0.25em;
}

/* ---------------------------------------------- 送信 */

.tkevf-note {
	margin: 2em 0 1.2em;
	padding: 1em 1.2em;
	border-radius: 6px;
	background: var(--tkevf-bg-soft);
	color: var(--tkevf-muted);
	font-size: 0.9em;
	line-height: 1.7;
}

.tkevf-actions {
	margin-top: 1.5em;
	text-align: center;
}

.tkevf-submit {
	display: inline-block;
	min-width: 16em;
	padding: 0.9em 2.4em;
	border: none;
	border-radius: 6px;
	background: var(--tkevf-accent);
	color: #fff;
	cursor: pointer;
	font-family: inherit;
	font-size: 1.05em;
	font-weight: 700;
	line-height: 1.5;
	transition: background-color 0.2s ease;
}

.tkevf-submit:hover {
	background: var(--tkevf-accent-dark);
}

.tkevf-submit:focus-visible {
	outline: 2px solid var(--tkevf-accent-dark);
	outline-offset: 2px;
}

.tkevf-submit[disabled] {
	opacity: 0.6;
	cursor: default;
}

/* ---------------------------------------------- 完了画面 */

.tkevf-done {
	padding: 2em 1.6em;
	border: 1px solid var(--tkevf-done-line);
	border-radius: 6px;
	background: var(--tkevf-done-bg);
	text-align: center;
}

.tkevf-done__title {
	margin: 0 0 0.6em;
	font-size: 1.15em;
	font-weight: 700;
}

.tkevf-done__text {
	margin: 0;
	font-size: 0.95em;
	line-height: 1.8;
}

/* ---------------------------------------------- 人には見せない欄 */

.tkevf-trap {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

/* ---------------------------------------------- スマートフォン */

@media screen and (max-width: 600px) {

	.tkevf {
		font-size: 15px;
	}

	.tkevf-section {
		margin: 2em 0 1em;
	}

	.tkevf-submit {
		width: 100%;
		min-width: 0;
		padding: 1em;
	}
}

/* ---------------------------------------------- 開催種別（ラジオ） */

.tkevf-radios {
	display: grid;
	gap: 0.6em;
}

.tkevf-radio {
	display: flex;
	align-items: flex-start;
	gap: 0.7em;
	padding: 0.85em 1em;
	border: 1px solid var(--tkevf-line);
	border-radius: 6px;
	background: #fff;
	cursor: pointer;
	line-height: 1.6;
}

.tkevf-radio:hover {
	border-color: var(--tkevf-accent);
}

.tkevf-radio input {
	flex: none;
	margin: 0.35em 0 0;
}

.tkevf-radio__body {
	display: block;
}

.tkevf-radio__label {
	display: block;
	font-weight: 700;
}

.tkevf-radio__note {
	display: block;
	margin-top: 0.15em;
	color: var(--tkevf-muted);
	font-size: 0.9em;
	line-height: 1.7;
}

/* ---------------------------------------------- 日付 */

.tkevf-date {
	display: block;
	width: 100%;
	max-width: 18em;
	padding: 0.65em 0.8em;
	border: 1px solid var(--tkevf-line);
	border-radius: 6px;
	background: #fff;
	color: inherit;
	font-family: inherit;
	font-size: 1em;
	line-height: 1.7;
}

.tkevf-date:focus {
	outline: 2px solid var(--tkevf-accent);
	outline-offset: 1px;
	border-color: var(--tkevf-accent);
}

.tkevf-row.is-error .tkevf-date {
	border-color: var(--tkevf-error);
	background: var(--tkevf-error-bg);
}

/* ---------------------------------------------- その他の開催日 */

.tkevf-dates__list {
	display: grid;
	gap: 0.5em;
}

.tkevf-dates__list:not(:empty) {
	margin-bottom: 0.7em;
}

.tkevf-dates__row {
	display: flex;
	align-items: center;
	gap: 0.5em;
}

.tkevf-dates__remove {
	flex: none;
	padding: 0.5em 1em;
	border: 1px solid var(--tkevf-line);
	border-radius: 6px;
	background: #fff;
	color: var(--tkevf-muted);
	cursor: pointer;
	font-family: inherit;
	font-size: 0.9em;
	line-height: 1.5;
}

.tkevf-dates__remove:hover {
	border-color: var(--tkevf-error);
	color: var(--tkevf-error);
}

.tkevf-dates__add {
	padding: 0.6em 1.2em;
	border: 1px dashed var(--tkevf-line);
	border-radius: 6px;
	background: var(--tkevf-bg-soft);
	color: inherit;
	cursor: pointer;
	font-family: inherit;
	font-size: 0.95em;
	font-weight: 700;
	line-height: 1.5;
}

.tkevf-dates__add:hover:not([disabled]) {
	border-color: var(--tkevf-accent);
	border-style: solid;
	color: var(--tkevf-accent);
}

.tkevf-dates__add[disabled] {
	opacity: 0.55;
	cursor: default;
}

/* 開催種別によって隠れる項目 */

.tkevf-row[hidden] {
	display: none;
}

@media screen and (max-width: 600px) {

	.tkevf-date {
		max-width: none;
	}

	.tkevf-dates__add {
		width: 100%;
	}
}
