/**
 * 碎碎念 · 前台样式 v5.0.0
 * 配色贴合 diary / new-island 主题大色调：纸白 · 木棕 · 墨字 · 博客绿，不使用跳脱颜色。
 * 所有选择器均以 .suimo- 前缀，避免影响主题其它部分。
 */

.suimo-wrap { max-width: 760px; margin: 0 auto; padding: 8px 0 30px; }

/* ---------- 头部 ---------- */
.suimo-head { text-align: center; padding-bottom: 12px; border-bottom: 1px dashed rgba(160,145,110,.45); position: relative; }
.suimo-title { font-family: "KaiTi", "STKaiti", serif; font-size: 21px; color: #6B5B3E; letter-spacing: 6px; }
.suimo-sub { font-size: 11px; color: #A89878; margin-top: 4px; letter-spacing: 1px; }
.suimo-sub b { color: #6B7F55; font-weight: 600; }
.suimo-write-toggle { position: absolute; right: 0; top: 0; }

/* ---------- 记一句 ---------- */
.suimo-write {
	margin: 14px auto 4px; padding: 14px 16px 10px;
	background: rgba(252,250,243,.72); border: 1px solid rgba(178,163,128,.42);
	border-radius: 8px; box-shadow: 0 2px 8px rgba(90,75,45,.10);
}
.suimo-write-input {
	width: 100%; height: 70px; display: block; box-sizing: border-box;
	border: 1px solid rgba(178,163,128,.5); border-radius: 5px; background: #FFFDF6;
	padding: 9px 11px; font-family: inherit; font-size: 1em;
	color: #6B5B3E; line-height: 1.6; resize: vertical; outline: none;
}
.suimo-write-foot { display: flex; align-items: center; margin-top: 9px; }
.suimo-count { font-size: 11px; color: #B0A080; }
.suimo-write-foot .suimo-btn { margin-left: auto; }
.suimo-tip { font-size: 10.5px; color: #B8A87E; margin-top: 7px; }

/* ---------- 记一句：前台密码认证 ---------- */
.suimo-authbox {
	margin: 14px auto 4px; padding: 14px 16px 10px;
	background: rgba(252,250,243,.72); border: 1px solid rgba(178,163,128,.42);
	border-radius: 8px; box-shadow: 0 2px 8px rgba(90,75,45,.10);
	max-width: 380px;
}
.suimo-auth-hint { font-family: inherit; font-size: 1em; color: #6B5B3E; margin-bottom: 9px; }
.suimo-auth-input {
	width: 100%; display: block; box-sizing: border-box;
	border: 1px solid rgba(178,163,128,.5); border-radius: 5px; background: #FFFDF6;
	padding: 8px 11px; font-size: 14px; color: #6B5B3E; outline: none;
	letter-spacing: 2px;
}
.suimo-auth-note { font-size: 10.5px; color: #B8A87E; }

/* ---------- 条目 ---------- */
.suimo-list { margin-top: 16px; }
.suimo-item { margin: 0 0 16px; scroll-margin-top: 24px; }
.suimo-paper {
	position: relative;
	background: rgba(252,250,243,.72);
	border: 1px solid rgba(178,163,128,.42);
	border-radius: 6px;
	box-shadow: 0 2px 6px rgba(90,75,45,.10);
	padding: 14px 16px 10px;
}
.suimo-paper::before { /* 胶带：水平居中，不倾斜 */
	content: ""; position: absolute; top: -8px; left: 50%; transform: translateX(-50%);
	width: 64px; height: 15px;
	background: rgba(214,197,160,.45);
	border-left: 1px dashed rgba(255,255,255,.6);
	border-right: 1px dashed rgba(255,255,255,.6);
}
.suimo-text {
	/* 字体/字号跟随博客（不写具体字体名，继承主题正文）；
	   颜色也用 inherit，这样 new-island 的深色/白色皮肤会自动适配 */
	font-family: inherit; font-size: inherit; color: inherit;
	line-height: 1.8; word-break: break-word; overflow-wrap: anywhere;
}
/* 行高分别贴近两个主题的正文节奏：diary 17px/32px ≈ 1.88，new-island 15px/26.25px = 1.75 */
.suimo-diary .suimo-text { line-height: 1.88; }
.suimo-island .suimo-text { line-height: 1.75; }
.suimo-tag { color: #8FA37C; font-size: .92em; margin-left: 2px; }

/* 图片：直接显示在列表里（没有单条页面） */
.suimo-picbox { margin-top: 10px; }
.suimo-pic {
	display: block; width: 190px; height: auto; max-width: 100%;
	border: 3px solid #fff; border-radius: 4px;
	box-shadow: 0 1px 4px rgba(90,75,45,.22);
	cursor: zoom-in;
}

/* ---------- 图片灯箱（碎碎念自带；视觉参照主题那套） ---------- */
.suimo-lb {
	position: fixed; inset: 0; z-index: 99999;
	display: flex; align-items: center; justify-content: center;
	background: rgba(0,0,0,.85);
	opacity: 0; transition: opacity .2s ease;
	cursor: zoom-out; padding: 20px; box-sizing: border-box;
}
.suimo-lb-on { opacity: 1; }
.suimo-lb img {
	max-width: 90vw; max-height: 90vh; width: auto; height: auto;
	border-radius: 4px; box-shadow: 0 8px 40px rgba(0,0,0,.5);
	cursor: zoom-out;
}
body.suimo-lb-lock { overflow: hidden; }

/* meta 行 */
.suimo-meta {
	display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
	margin-top: 9px; padding-top: 7px; border-top: 1px dashed rgba(160,145,110,.36);
	font-size: 11px; color: #A89878;
}
.suimo-no { color: #5E8A50; font-weight: 700; letter-spacing: 1px; }
.suimo-ago { color: #B8A87E; }
.suimo-toggle {
	margin-left: auto; color: #5E8A50; font-size: 11px; cursor: pointer;
	border: 1px solid rgba(94,138,80,.5); border-radius: 999px;
	padding: 2px 10px; background: rgba(255,255,255,.55);
	font-family: inherit; line-height: 1.6;
}
.suimo-toggle:hover { background: rgba(94,138,80,.10); }

/* ---------- 评论 ---------- */
.suimo-cmts { margin-top: 9px; }
.suimo-cmt-list { background: rgba(250,248,240,.8); border-radius: 5px; padding: 4px 11px; }
.suimo-cmt-none { font-size: 11.5px; color: #B0A080; padding: 8px 0; text-align: center; }
.suimo-cmt { display: flex; gap: 8px; padding: 7px 0; }
.suimo-cmt + .suimo-cmt { border-top: 1px dashed rgba(160,145,110,.32); }
.suimo-av { width: 24px; height: 24px; border-radius: 50%; flex: none; object-fit: cover; box-shadow: 0 0 0 1px rgba(160,145,110,.35); }
.suimo-cmt-b { flex: 1; min-width: 0; }
.suimo-cmt-h { font-size: 11px; color: #A89878; }
.suimo-cmt-h b { color: #6B7F55; font-weight: 600; margin-right: 7px; }
.suimo-cmt-t { font-family: inherit; font-size: 13px; color: inherit; line-height: 1.7; margin-top: 2px; word-break: break-word; overflow-wrap: anywhere; }

.suimo-cmt-form { margin-top: 8px; }
.suimo-inp {
	width: 100%; box-sizing: border-box; display: block;
	border: 1px solid rgba(178,163,128,.5); border-radius: 5px; background: #FFFDF6;
	padding: 7px 10px; font-size: 13px; color: #6B5B3E; font-family: inherit; outline: none;
}
.suimo-inp.suimo-name, .suimo-inp.suimo-mail { width: 48%; display: inline-block; margin-bottom: 6px; }
.suimo-inp.suimo-mail { float: right; }
.suimo-inp.suimo-text { height: 46px; resize: vertical; }
.suimo-cmt-foot { display: flex; align-items: center; flex-wrap: nowrap; gap: 8px; margin-top: 8px; }
/* 「记住信息」：与博客评论表单同一语义，字号/配色跟随碎碎念的浅色小字口径；
   固定不换行，避免在窄容器里折成两行 */
.suimo-cmt-remember {
	display: inline-flex; align-items: center; gap: 4px;
	font-size: 11px; color: #A89878; cursor: pointer;
	font-family: inherit; line-height: 1.6; user-select: none;
	white-space: nowrap; flex: none;
}
.suimo-cmt-remember input { margin: 0; cursor: pointer; }
.suimo-cmt-foot .suimo-btn { margin-left: auto; flex: none; }

/* ---------- 评论滑块验证码（v4.0.0，与 diary 主题同一套交互） ---------- */
.suimo-captcha {
	margin: 0;
	flex: 1 1 auto;
	min-width: 0;
	max-width: 200px;
}
.suimo-slider {
	position: relative;
	display: block;
	width: 100%;
	height: 28px;
	background: linear-gradient(135deg, #efe4d2 0%, #d8c8a8 100%);
	border: 1px solid #c0a070;
	border-radius: 14px;
	box-shadow: inset 0 1px 2px rgba(0,0,0,.08);
	user-select: none;
	-webkit-user-select: none;
	touch-action: none;
	cursor: pointer;
	overflow: hidden;
	outline: none;
}
.suimo-slider:focus {
	border-color: #8b6b4a;
	box-shadow: inset 0 1px 2px rgba(0,0,0,.08), 0 0 0 2px rgba(139,107,74,.25);
}
.suimo-slider-text {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #6b4a28;
	font-size: 11px;
	letter-spacing: .5px;
	pointer-events: none;
	font-weight: 600;
	transition: color .3s;
}
.suimo-slider-thumb {
	position: absolute;
	left: 2px;
	top: 2px;
	bottom: 2px;
	width: 42px;
	background: linear-gradient(135deg, #c8a878 0%, #8b6b4a 100%);
	border: 1px solid #6b4a28;
	border-radius: 12px;
	box-shadow: 0 1px 3px rgba(0,0,0,.25);
	cursor: grab;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fffef9;
	font-size: 18px;
	font-weight: 700;
	line-height: 1;
	transition: background .2s, box-shadow .2s;
}
.suimo-slider-thumb::before {
	content: '\203A';
	font-size: 20px;
	line-height: 1;
}
.suimo-slider-thumb:active { cursor: grabbing; box-shadow: 0 2px 5px rgba(0,0,0,.35); }
.suimo-slider.passed {
	background: linear-gradient(135deg, #d5e8c8 0%, #b8d4a0 100%);
	border-color: #6b8e5a;
}
.suimo-slider.passed .suimo-slider-thumb {
	left: auto;
	right: 2px;
	background: linear-gradient(135deg, #88b878 0%, #6b8e5a 100%);
	border-color: #4a6b3a;
}
.suimo-slider.passed .suimo-slider-text { color: #4a6b3a; }

/* ---------- 按钮 ---------- */
.suimo-btn {
	background: #5E8A50; color: #fff; border: 0; border-radius: 999px;
	font-size: 12px; letter-spacing: 2px; padding: 6px 15px; cursor: pointer;
	font-family: inherit; line-height: 1.7;
}
.suimo-btn:hover { background: #527A46; }
.suimo-btn[disabled] { opacity: .6; cursor: default; }

/* ---------- 分页 ---------- */
.suimo-pager { margin-top: 20px; text-align: center; font-size: 12px; }
.suimo-pg {
	display: inline-block; min-width: 26px; padding: 3px 8px; margin: 0 2px;
	border: 1px solid rgba(160,145,110,.45); border-radius: 3px;
	color: #6B5B3E; text-decoration: none; background: rgba(255,255,255,.55);
}
.suimo-pg:hover { background: rgba(94,138,80,.12); }
.suimo-pg-cur { background: #5E8A50; color: #fff; border-color: #5E8A50; }
.suimo-dots { margin: 0 4px; color: #A89878; }

.suimo-empty { text-align: center; padding: 60px 0; color: #A89878; font-size: 14px; }

/* ---------- new-island：深色主题下铺一张纸 ---------- */
.suimo-island { padding: 20px 0 30px; }
.suimo-island .suimo-sheet {
	max-width: 860px; margin: 0 auto; padding: 26px 30px 30px;
	background: #F7F4E9; border-radius: 8px;
	box-shadow: 0 2px 14px rgba(0,0,0,.18);
}
.suimo-island .suimo-paper,
.suimo-island .suimo-write,
.suimo-island .suimo-authbox { background: rgba(255,255,255,.72); }

/* ---------- 侧栏短码 [suimo count="3"] ---------- */
.suimo-mini { list-style: none; margin: 0; padding: 0; }
.suimo-mini-item {
	position: relative; padding: 7px 0 7px 0;
	border-bottom: 1px dashed rgba(160,145,110,.3);
	font-size: 13px; line-height: 1.6; color: #6B5B3E;
}
.suimo-mini-item:last-child { border-bottom: 0; }
/* 整条可点：跳转列表页并定位到该条 */
.suimo-mini-link {
	display: block; color: inherit; text-decoration: none;
	padding: 2px 6px; margin: 0 -6px; border-radius: 4px;
	transition: background .15s ease;
}
.suimo-mini-link:hover { background: rgba(126,150,102,.10); }
.suimo-mini-link:hover .suimo-mini-text { color: #5E8A50; }
.suimo-mini-link:focus-visible { outline: 1px dashed #8FA37C; outline-offset: 1px; }
.suimo-mini-no { display: inline-block; color: #5E8A50; font-weight: 700; font-size: 11px; margin-right: 6px; }
.suimo-mini-text { font-family: inherit; }
.suimo-mini-time { display: block; font-size: 10.5px; color: #A89878; margin-top: 2px; }
.suimo-mini-empty { font-size: 12.5px; color: #A89878; }

/* 锚点定位：从侧栏点进来时把目标条顶到可视区并轻微高亮（scroll-margin 见 .suimo-item） */
.suimo-item:target > .suimo-paper,
.suimo-item.suimo-hit > .suimo-paper {
	box-shadow: 0 0 0 2px rgba(126,150,102,.8), 0 2px 8px rgba(90,75,45,.14);
}

/* ---------- 移动端 ---------- */
@media (max-width: 640px) {
	.suimo-wrap { padding: 4px 2px 20px; }
	.suimo-write-toggle { position: static; display: block; margin: 10px auto 0; }
	.suimo-head { padding-bottom: 10px; }
	.suimo-pic { width: 100%; }
	.suimo-inp.suimo-name, .suimo-inp.suimo-mail { width: 100%; float: none; }
	.suimo-island .suimo-sheet { padding: 18px 14px 22px; border-radius: 6px; }
	/* 评论区底部：手机端仍要求一行排下，滑块自适应收缩 */
	.suimo-cmt-foot { gap: 6px; }
	.suimo-captcha { max-width: none; min-width: 80px; }
	.suimo-slider { height: 26px; border-radius: 13px; }
	.suimo-slider-thumb { width: 36px; border-radius: 11px; }
	.suimo-slider-text { font-size: 10px; letter-spacing: 0; }
	.suimo-cmt-remember { font-size: 10px; }
	.suimo-btn { padding: 5px 11px; letter-spacing: 1px; }
}

/* ---------- 灯箱增强（v1.8.1：图集切换 + 缩放，统一四套灯箱视觉） ---------- */
.suimo-lb { flex-direction: column; gap: 10px; cursor: default; }
.suimo-lb img { cursor: pointer; will-change: transform; }
.suimo-lb-cap {
	color: rgba(255, 255, 255, .82);
	font-size: 13px;
	text-align: center;
	max-width: 80vw;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	font-family: inherit;
}
.suimo-lb-close,
.suimo-lb-prev,
.suimo-lb-next {
	position: fixed;
	background: rgba(30, 34, 40, .55);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, .35);
	border-radius: 50%;
	cursor: pointer;
	width: 56px;
	height: 56px;
	font-size: 30px;
	line-height: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background .15s;
	z-index: 2;
	padding: 0;
	font-family: Arial, sans-serif;
}
.suimo-lb-close { top: 18px; right: 18px; font-size: 24px; }
.suimo-lb-prev { left: 48px; top: 50%; transform: translateY(-50%); }
.suimo-lb-next { right: 48px; top: 50%; transform: translateY(-50%); }
.suimo-lb-close:hover,
.suimo-lb-prev:hover,
.suimo-lb-next:hover { background: rgba(30, 34, 40, .8); }
.suimo-lb-single .suimo-lb-prev,
.suimo-lb-single .suimo-lb-next { display: none; }

.lb-zoom-bar {
	position: fixed;
	left: 50%; bottom: 22px;
	transform: translateX(-50%);
	display: flex;
	align-items: center;
	gap: 8px;
	background: rgba(20, 18, 14, .74);
	border: 1px solid rgba(255, 255, 255, .22);
	border-radius: 999px;
	padding: 6px 14px;
	z-index: 10;
	box-shadow: 0 4px 14px rgba(0, 0, 0, .35);
}
.lb-zoom-bar button {
	background: none;
	border: 0;
	color: #fff;
	cursor: pointer;
	font-size: 17px;
	line-height: 1;
	padding: 2px 6px;
	font-family: inherit;
	transition: opacity .15s;
}
.lb-zoom-bar button:hover { opacity: .75; }
.lb-zoom-bar .lb-zoom-pct {
	color: rgba(255, 255, 255, .85);
	font-size: 12px;
	min-width: 42px;
	text-align: center;
	user-select: none;
}
.lb-zoom-bar .lb-zoom-reset { font-size: 12px; opacity: .85; }
@media (max-width: 768px) {
	.suimo-lb-prev, .suimo-lb-next { width: 46px; height: 46px; font-size: 26px; }
	.suimo-lb-prev { left: 12px; }
	.suimo-lb-next { right: 12px; }
	.lb-zoom-bar { bottom: 14px; padding: 5px 12px; gap: 6px; }
}
