/* ------------------------------------------------------------
   お食事処ネタBBS - 共通スタイル（PC・スマホ共通のレスポンシブ実装）
   ------------------------------------------------------------ */

:root {
	--accent: #339999;
	--text: #222;
	--muted: #666;
	--border: #ddd;
	--bg: #f7f7f5;
	--card-bg: #fff;
	--danger: #c0392b;
	--radius: 8px;
	--max-width: 680px;
}

* { box-sizing: border-box; }

body {
	margin: 0;
	font-family: -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic ProN",
		"Hiragino Sans", Meiryo, sans-serif;
	font-size: 16px;
	line-height: 1.7;
	color: var(--text);
	background: var(--bg);
}

.page {
	max-width: var(--max-width);
	margin: 0 auto;
	padding: 0 12px 32px;
}

a { color: var(--accent); }

/* ---------- ヘッダー ---------- */
.site-header {
	padding: 16px 0;
	border-bottom: 2px solid var(--accent);
	margin-bottom: 20px;
}
.site-header__logo {
	display: inline-block;
	font-weight: bold;
	text-decoration: none;
	color: var(--accent);
	margin-bottom: 8px;
}
.site-header__title h1 {
	margin: 0 0 4px;
	font-size: 1.3em;
}
.site-header__title p {
	margin: 0;
	font-size: 0.85em;
	color: var(--muted);
}

/* ---------- カード共通 ---------- */
.card {
	background: var(--card-bg);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 16px;
	margin-bottom: 16px;
}

/* ---------- 投稿フォーム ---------- */
.post-form label {
	display: block;
	font-weight: bold;
	margin: 12px 0 4px;
}
.post-form .hint {
	font-size: 0.8em;
	color: var(--muted);
	font-weight: normal;
}
.post-form input[type="text"],
.post-form input[type="password"],
.post-form input[type="file"],
.post-form textarea {
	width: 100%;
	padding: 8px;
	border: 1px solid var(--border);
	border-radius: 4px;
	font-size: 16px; /* iOSでズームさせないため16px以上 */
	font-family: inherit;
}
.post-form textarea { resize: vertical; }

/* ハニーポット欄（人間には見せない） */
.hp-field {
	position: absolute;
	left: -9999px;
	top: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.btn {
	display: inline-block;
	background: var(--accent);
	color: #fff;
	border: none;
	border-radius: 4px;
	padding: 10px 24px;
	font-size: 16px;
	cursor: pointer;
	margin-top: 12px;
}
.btn:hover { opacity: 0.9; }

.error-box {
	background: #fdecea;
	border: 1px solid var(--danger);
	color: var(--danger);
	border-radius: var(--radius);
	padding: 12px 16px;
	margin-bottom: 16px;
}
.error-box ul { margin: 4px 0 0; padding-left: 1.2em; }

.notice-box {
	background: #eaf6f6;
	border: 1px solid var(--accent);
	border-radius: var(--radius);
	padding: 12px 16px;
	margin-bottom: 16px;
}

/* ---------- 投稿一覧 ---------- */
.post-count {
	color: var(--muted);
	font-size: 0.9em;
	margin-bottom: 12px;
}

.post {
	background: var(--card-bg);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 14px 16px;
	margin-bottom: 14px;
}
.post__meta {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 8px;
	font-size: 0.85em;
	color: var(--muted);
	margin-bottom: 6px;
}
.post__title {
	font-weight: bold;
	font-size: 1.1em;
	margin: 0 0 8px;
}
.post__image {
	margin: 8px 0;
}
.post__image img {
	max-width: 100%;
	height: auto;
	border-radius: 4px;
	display: block;
}
.post__body {
	white-space: pre-wrap;
	word-break: break-word;
}

/* ---------- ページネーション ---------- */
.pagination {
	display: flex;
	justify-content: center;
	gap: 16px;
	margin: 20px 0;
}

/* ---------- フッター ---------- */
.site-footer {
	margin-top: 24px;
	padding-top: 16px;
	border-top: 1px solid var(--border);
	font-size: 0.8em;
	color: var(--muted);
	text-align: center;
}

/* ---------- PC幅で少しゆったり ---------- */
@media (min-width: 700px) {
	body { font-size: 15px; }
	.page { padding: 0 16px 40px; }
}
