/* Recipe SNS — フォーム・ボタン・メッセージの共通スタイル（テーマ非依存の最小限） */

.rs-form { max-width: 640px; }
.rs-form p { margin: 0 0 1rem; }
.rs-form label { display: block; font-weight: 600; margin-bottom: .25rem; }
.rs-form input[type="text"],
.rs-form input[type="email"],
.rs-form input[type="password"],
.rs-form input[type="number"],
.rs-form select,
.rs-form textarea {
	width: 100%;
	padding: .55rem .7rem;
	border: 1px solid #ccc;
	border-radius: 8px;
	box-sizing: border-box;
	font-size: 1rem;
}
.rs-required {
	display: inline-block;
	font-size: .7rem;
	color: #fff;
	background: #1da1f2;
	border-radius: 4px;
	padding: .05rem .4rem;
	margin-left: .3rem;
	vertical-align: middle;
}
.rs-repeat {
	border: 1px solid #e3e3e3;
	border-radius: 10px;
	padding: 1rem;
	margin: 0 0 1rem;
}
.rs-repeat legend { font-weight: 700; padding: 0 .4rem; }
.rs-row {
	display: flex;
	gap: .5rem;
	margin-bottom: .5rem;
}
.rs-row textarea { flex: 1; }
.rs-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 0 1rem;
}
.rs-add-row {
	background: none;
	border: 1px dashed #1da1f2;
	color: #1da1f2;
	border-radius: 8px;
	padding: .4rem .8rem;
	cursor: pointer;
}
.rs-button {
	display: inline-block;
	border: none;
	border-radius: 999px;
	padding: .65rem 1.6rem;
	font-size: 1rem;
	cursor: pointer;
	text-decoration: none;
}
.rs-button-primary { background: #1da1f2; color: #fff; }
.rs-button-primary:hover { background: #1a91da; }

.rs-message {
	padding: .8rem 1rem;
	border-radius: 8px;
	margin-bottom: 1rem;
}
.rs-message-error { background: #fdecea; color: #b3261e; border: 1px solid #f5c2bd; }
.rs-message-success { background: #e7f6ec; color: #1b7a3d; border: 1px solid #b7e4c7; }
.rs-notice { padding: 1rem; background: #f6f6f6; border-radius: 8px; }

/* ===== DM（ダイレクトメッセージ）===== */
.rs-button-outline {
	display: inline-block;
	border: 1px solid #1da1f2;
	color: #1da1f2;
	background: #fff;
	border-radius: 999px;
	padding: .55rem 1.2rem;
	text-decoration: none;
	font-size: .95rem;
}
.rs-button-outline:hover { background: #eaf6fe; }

/* 受信箱 */
.rs-dm-inbox { list-style: none; margin: 0; padding: 0; }
.rs-dm-conv { border: 1px solid #ececec; border-radius: 12px; margin-bottom: .6rem; background: #fff; }
.rs-dm-conv.is-unread { background: #eaf6fe; border-color: #bcdffb; }
.rs-dm-conv a { display: flex; align-items: center; gap: .7rem; padding: .8rem 1rem; text-decoration: none; color: #2b2b2b; }
.rs-dm-av img { border-radius: 50%; display: block; }
.rs-dm-main { flex: 1; min-width: 0; }
.rs-dm-name { display: block; font-weight: 700; }
.rs-dm-snippet { display: block; color: #888; font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rs-dm-badge { background: #1da1f2; color: #fff; border-radius: 999px; font-size: .75rem; min-width: 20px; height: 20px; line-height: 20px; text-align: center; padding: 0 6px; }

/* スレッド */
.rs-dm-thread { border: 1px solid #ececec; border-radius: 14px; background: #fff; overflow: hidden; }
.rs-dm-thread-head { display: flex; align-items: center; gap: 1rem; padding: .7rem 1rem; border-bottom: 1px solid #ececec; }
.rs-dm-back { text-decoration: none; color: #777; font-size: .9rem; }
.rs-dm-partner { display: inline-flex; align-items: center; gap: .5rem; text-decoration: none; color: #2b2b2b; font-weight: 700; }
.rs-dm-partner img { border-radius: 50%; }
.rs-dm-messages { padding: 1rem; max-height: 60vh; overflow-y: auto; display: flex; flex-direction: column; gap: .5rem; }
.rs-dm-msg { display: flex; flex-direction: column; max-width: 75%; }
.rs-dm-msg.is-mine { align-self: flex-end; align-items: flex-end; }
.rs-dm-msg.is-theirs { align-self: flex-start; align-items: flex-start; }
.rs-dm-bubble { padding: .5rem .8rem; border-radius: 14px; line-height: 1.5; word-break: break-word; }
.rs-dm-msg.is-mine .rs-dm-bubble { background: #1da1f2; color: #fff; border-bottom-right-radius: 4px; }
.rs-dm-msg.is-theirs .rs-dm-bubble { background: #eef3f6; color: #2b2b2b; border-bottom-left-radius: 4px; }
.rs-dm-time { font-size: .7rem; color: #aaa; margin-top: .15rem; }
.rs-dm-form { display: flex; gap: .5rem; padding: .8rem 1rem; border-top: 1px solid #ececec; }
.rs-dm-form textarea { flex: 1; border: 1px solid #ccc; border-radius: 10px; padding: .5rem .7rem; resize: vertical; font-size: 1rem; }

/* プロフィール編集フォーム */
.rs-profile-form .rs-avatar-current { text-align: center; margin-bottom: 1rem; }
.rs-profile-form .rs-avatar-current img { border-radius: 50%; width: 96px; height: 96px; object-fit: cover; }
.rs-field-note { display: block; font-size: .78rem; color: #888; margin-top: .25rem; }
.rs-button-link {
	display: inline-block;
	margin-left: .8rem;
	padding: .65rem 1rem;
	color: #555;
	text-decoration: none;
}
.rs-button-link:hover { color: #1da1f2; }

/* ソーシャルログイン（Google一本化） */
.rs-social-auth {
	max-width: 420px;
	text-align: center;
	padding: 1.5rem;
	border: 1px solid #ececec;
	border-radius: 14px;
	background: #fff;
}
.rs-social-lead { font-size: 1.05rem; font-weight: 600; margin: 0 0 1.2rem; }
.rs-social-buttons { display: flex; justify-content: center; }
.rs-social-note { font-size: .82rem; color: #777; margin: 1.2rem 0 0; }

/* いいね / フォローボタン（カード・詳細共通） */
.rs-like-button,
.rs-follow-button {
	display: inline-flex;
	align-items: center;
	gap: .3rem;
	border: 1px solid #1da1f2;
	background: #fff;
	color: #1da1f2;
	border-radius: 999px;
	padding: .3rem .9rem;
	cursor: pointer;
	font-size: .9rem;
}
.rs-like-button.is-active { background: #1da1f2; color: #fff; }
.rs-follow-button.is-following { background: #555; border-color: #555; color: #fff; }
.rs-like-button[disabled],
.rs-follow-button[disabled] { opacity: .6; cursor: default; }

@media (max-width: 600px) {
	.rs-grid { grid-template-columns: 1fr; }
}
