/**
 * フロント公開画面
 */

.kamon-wrap {
	font-family: "Noto Sans JP", "Hiragino Sans", "Yu Gothic UI", sans-serif;
	color: #1a1a1a;
	line-height: 1.7;
	max-width: 720px;
	margin: 0 auto;
	padding: clamp(1.5rem, 4vw, 3rem) 1rem;
}

.kamon-card {
	background: #fafaf8;
	border: 1px solid #e6e2d8;
	border-radius: 4px;
	padding: clamp(1.25rem, 3vw, 2rem);
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.04);
}

.kamon-heading {
	font-weight: 500;
	letter-spacing: 0.08em;
	font-size: clamp(1.25rem, 2.4vw, 1.5rem);
	margin: 0 0 0.5rem;
}

.kamon-lead {
	margin: 0 0 1.5rem;
	color: #3a3a3a;
	font-size: 0.95rem;
}

.kamon-suggest-bar {
	margin: 0 0 1.35rem;
	padding: 1rem 1.1rem;
	border: 1px dashed #cfc8bc;
	border-radius: 3px;
	background: #f7f5f0;
}

.kamon-suggest-bar__hint {
	margin: 0.65rem 0 0;
	font-size: 0.82rem;
	color: #5a534a;
	line-height: 1.65;
}

.kamon-field {
	margin-bottom: 1.25rem;
}

.kamon-field label {
	display: block;
	font-size: 0.85rem;
	margin-bottom: 0.35rem;
	letter-spacing: 0.04em;
}

.kamon-field input,
.kamon-field textarea {
	width: 100%;
	box-sizing: border-box;
	border: 1px solid #cfc8bc;
	border-radius: 3px;
	padding: 0.65rem 0.75rem;
	font: inherit;
	background: #fff;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.kamon-field input:focus,
.kamon-field textarea:focus {
	outline: none;
	border-color: #8a7f6b;
	box-shadow: 0 0 0 1px #8a7f6b33;
}

.kamon-actions {
	margin-top: 1.5rem;
}

.kamon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 0 1.5rem;
	border-radius: 3px;
	border: 1px solid #2c2824;
	background: #2c2824;
	color: #fafaf8;
	font: inherit;
	cursor: pointer;
	letter-spacing: 0.06em;
	transition: background 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}

.kamon-btn:hover {
	background: #1a1816;
	border-color: #1a1816;
}

.kamon-btn:disabled {
	opacity: 0.55;
	cursor: not-allowed;
}

.kamon-btn--ghost {
	background: transparent;
	color: #2c2824;
	border-color: #a69f93;
}

.kamon-btn--ghost:hover {
	background: #ebe6dc;
	border-color: #8a8072;
	color: #1a1816;
}

.kamon-fieldset {
	border: 1px solid #e0dbd3;
	padding: 1rem 1.1rem 1.15rem;
	margin: 0 0 1.35rem;
	background: #fdfcfa;
}

.kamon-fieldset--publish {
	margin-bottom: 1.5rem;
}

.kamon-fieldset__legend {
	font-size: 0.88rem;
	font-weight: 500;
	letter-spacing: 0.06em;
	padding: 0 0.25rem;
}

.kamon-fieldset__note {
	margin: 0 0 0.85rem;
	font-size: 0.82rem;
	color: #5a534a;
	line-height: 1.75;
}

.kamon-check,
.kamon-radio {
	display: flex;
	align-items: flex-start;
	gap: 0.55rem 0.75rem;
	margin: 0 0 0.65rem;
	font-size: 0.88rem;
	line-height: 1.65;
	cursor: pointer;
}

.kamon-check:last-child,
.kamon-radio:last-child {
	margin-bottom: 0;
}

.kamon-check input,
.kamon-radio input {
	margin-top: 0.2rem;
	flex-shrink: 0;
	width: 1rem;
	height: 1rem;
}

.kamon-check__text a,
.kamon-fieldset__note a {
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 0.15em;
}

.kamon-help {
	font-size: 0.85rem;
	color: #5a534a;
	margin-top: 1rem;
}

.kamon-message {
	margin-top: 1rem;
	padding: 0.75rem 1rem;
	border-radius: 3px;
	font-size: 0.9rem;
}

.kamon-message.is-error {
	background: #f8ecec;
	border: 1px solid #e0bcbc;
	color: #5a2a2a;
}

.kamon-message.is-success {
	background: #edf4ee;
	border: 1px solid #b8d4c4;
	color: #2a4a3a;
}

.kamon-notice {
	text-align: left;
}

.kamon-gallery__grid {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
	gap: 1.25rem;
}

.kamon-gallery__link {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-decoration: none;
	color: inherit;
	gap: 0.5rem;
}

.kamon-gallery__frame {
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	background: #f4f1ea;
	border: 1px solid #e0dbd3;
	border-radius: 50%;
	overflow: hidden;
}

.kamon-gallery__frame .kamon-public-thumb {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
}

.kamon-gallery__frame .kamon-public-thumb--pending {
	width: 100%;
	height: 100%;
	min-height: 100px;
	background: repeating-linear-gradient(
		-45deg,
		#e5e2dc,
		#e5e2dc 5px,
		#f4f1ea 5px,
		#f4f1ea 10px
	);
	border-radius: 50%;
}

.kamon-gallery__title {
	font-size: 0.9rem;
	text-align: center;
	letter-spacing: 0.04em;
}

.kamon-gallery .kamon-tier-notice--gallery {
	margin: 0 0 1.25rem;
	padding: 0 0.25rem;
	font-size: 0.82rem;
	line-height: 1.65;
	color: #5a534a;
}

.kamon-empty {
	text-align: center;
	color: #5a534a;
	padding: 2rem 0;
}

/* ── 生成中モーダル ── */
.kamon-modal-overlay {
	display: none;
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(10, 10, 8, 0.55);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
	align-items: center;
	justify-content: center;
}

.kamon-modal-overlay.is-active {
	display: flex;
}

.kamon-modal {
	background: #fafaf8;
	border: 1px solid #e0dbd3;
	border-radius: 8px;
	padding: clamp(2rem, 5vw, 3rem) clamp(1.5rem, 4vw, 2.5rem);
	max-width: 420px;
	width: 90%;
	text-align: center;
	box-shadow: 0 24px 64px rgba(0, 0, 0, 0.18);
}

.kamon-modal__spinner {
	display: block;
	width: 48px;
	height: 48px;
	margin: 0 auto 1.5rem;
	border: 3px solid #e0dbd3;
	border-top-color: #2c2824;
	border-radius: 50%;
	animation: kamon-spin 0.8s linear infinite;
}

@keyframes kamon-spin {
	to { transform: rotate(360deg); }
}

.kamon-modal__title {
	font-size: 1.1rem;
	font-weight: 500;
	letter-spacing: 0.06em;
	margin: 0 0 0.75rem;
	color: #1a1a1a;
}

.kamon-modal__text {
	font-size: 0.88rem;
	color: #5a534a;
	line-height: 1.75;
	margin: 0;
}
