/* UNDER LAYERS — お問い合わせ(contact.html・assets/js/contact.js。docs/api.md §35)
   legal.css の見出しと kb.css の .field / .btn を使う。接頭辞は ct- */

.ct-main {
	margin-top: 18px;
}

.ct-form {
	display: grid;
	gap: 14px;
}

.ct-who {
	padding: 10px 12px;
	border: 1px solid var(--line);
	background: var(--bg-deep);
	font-size: var(--fs-s);
	line-height: 1.6;
}

.ct-who p {
	margin: 0;
}

.ct-who p + p {
	margin-top: 4px;
	font-size: var(--fs-xs);
}

.ct-group {
	margin: 0;
	padding: 10px 12px;
	border: 1px solid var(--line);
	min-width: 0;
}

.ct-group legend {
	padding: 0 4px;
	color: var(--fg-hi);
	font-size: var(--fs-s);
}

.ct-group[hidden] {
	display: none;
}

.ct-kind {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 8px;
	min-height: 36px;
	padding: 4px 0;
	font-size: var(--fs-m);
	cursor: pointer;
}

.ct-kind.is-off {
	color: var(--sub);
	cursor: default;
}

.ct-kind-note {
	font-size: var(--fs-xs);
}

.ct-items {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
	gap: 6px;
	max-height: 360px;
	overflow-y: auto;
	padding: 2px;
	overscroll-behavior: contain;
}

.ct-item {
	position: relative;
	display: grid;
	gap: 2px;
	padding: 8px 8px 8px 30px;
	border: 1px solid var(--line);
	background: var(--bg-deep);
	cursor: pointer;
	font-size: var(--fs-s);
	overflow-wrap: anywhere;
}

.ct-item input {
	position: absolute;
	left: 8px;
	top: 10px;
	margin: 0;
}

.ct-item:has(input:checked) {
	border-color: var(--warn);
	box-shadow: inset 0 0 0 1px var(--warn);
}

.ct-item[data-tier="t2"] .ct-item-tier { color: var(--fg); }
.ct-item[data-tier="t3"] .ct-item-tier { color: var(--cyan); }
.ct-item[data-tier="t4"] .ct-item-tier { color: var(--warn); }

.ct-item-name b {
	color: var(--fg-hi);
}

.ct-item-meta,
.ct-item-aff {
	font-size: var(--fs-xs);
}

.ct-field {
	display: grid;
	gap: 4px;
}

.ct-field label {
	display: flex;
	justify-content: space-between;
	gap: 8px;
	color: var(--fg-hi);
	font-size: var(--fs-s);
}

.ct-field .field {
	width: 100%;
	box-sizing: border-box;
	font-size: 16px; /* iOS で入力時に拡大されないように */
}

.ct-body {
	min-height: 10em;
	resize: vertical;
	line-height: 1.6;
}

.ct-count {
	font-size: var(--fs-xs);
}

.ct-hint {
	margin: 0;
	font-size: var(--fs-xs);
	line-height: 1.6;
}

.ct-hint:empty {
	display: none;
}

.ct-err:empty {
	display: none;
}

.ct-err {
	padding: 8px 12px;
	border: 1px solid var(--alert);
	background: var(--alert-bg);
	color: var(--alert-hi);
	font-size: var(--fs-s);
}

.ct-err p {
	margin: 0;
}

.ct-err p + p {
	margin-top: 4px;
}

.ct-actions {
	margin: 0;
}

.ct-actions .btn {
	min-width: 140px;
	min-height: 40px;
}

/* honeypot: 画面にもスクリーンリーダーにも出さない(display: none だと埋めない機械もあるので、画面の外に置く) */
.ct-trap {
	position: absolute;
	left: -10000px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.ct-done {
	padding: 14px 16px;
	border: 1px solid var(--fg);
	background: var(--bg-deep);
	line-height: 1.7;
}

.ct-h2 {
	margin: 0 0 8px;
	color: var(--fg-hi);
	font-size: var(--fs-l);
}

.ct-done p {
	margin: 6px 0;
	font-size: var(--fs-s);
}
