/* ===== koishi 内容短代码样式 ===== */
.sc-box {
	margin: 1.4em 0;
	padding: 14px 18px;
	border: 1px solid var(--line);
	border-left: 4px solid var(--accent);
	border-radius: var(--radius-sm);
	background: var(--bg-soft);
}

.sc-box-title {
	margin: 0 0 6px;
	font-weight: 600;
	color: var(--ink);
}

.sc-box-body > :last-child {
	margin-bottom: 0;
}

.sc-box-warning {
	border-left-color: #d99a2b;
}

.sc-box-danger,
.sc-box-error {
	border-left-color: #d9534f;
}

.sc-box-success {
	border-left-color: #3aa675;
}

.sc-collapse {
	margin: 1.4em 0;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	background: var(--paper-2);
}

.sc-collapse > summary {
	padding: 10px 16px;
	cursor: pointer;
	font-weight: 600;
	color: var(--ink);
	list-style: none;
}

.sc-collapse > summary::-webkit-details-marker {
	display: none;
}

.sc-collapse > summary::before {
	content: '▸';
	display: inline-block;
	margin-right: 8px;
	color: var(--accent);
	transition: transform 0.2s var(--ease);
}

.sc-collapse[open] > summary::before {
	transform: rotate(90deg);
}

.sc-collapse-body {
	padding: 0 16px 14px;
	border-top: 1px dashed var(--line);
	padding-top: 12px;
}

.sc-progress {
	position: relative;
	margin: 1.2em 0;
	height: 20px;
	border-radius: 999px;
	background: var(--bg-soft);
	overflow: hidden;
}

.sc-progress-bar {
	display: block;
	height: 100%;
	background: var(--accent);
	transition: width 0.4s var(--ease);
}

.sc-progress-text {
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0 8px;
	white-space: nowrap;
	border-radius: 999px;
	background: var(--paper-2);
	font-size: 12px;
	line-height: 16px;
	color: var(--ink);
}

.sc-label {
	display: inline-block;
	margin: 0 3px;
	padding: 1px 8px;
	border-radius: 999px;
	font-size: 12px;
	line-height: 1.7;
	background: var(--bg-soft);
	color: var(--ink-soft);
}

.sc-label-blue {
	background: var(--accent-soft);
	color: var(--accent);
}

.sc-label-red {
	background: #fbe9e8;
	color: #c0392b;
}

.sc-label-green {
	background: #e6f5ee;
	color: #2d7a55;
}

.sc-checkbox::before {
	content: '☐';
	margin-right: 6px;
	color: var(--faint);
}

.sc-checkbox.is-checked::before {
	content: '☑';
	color: var(--accent);
}

.sc-spoiler {
	padding: 0 4px;
	border-radius: 3px;
	background: var(--ink-soft);
	color: transparent;
	cursor: pointer;
	transition: background 0.2s var(--ease), color 0.2s var(--ease);
}

.sc-spoiler:hover,
.sc-spoiler:focus {
	background: var(--bg-soft);
	color: var(--ink);
}

.sc-ref {
	color: var(--accent);
	font-size: 0.75em;
	cursor: help;
}

.sc-video,
.sc-video-embed iframe {
	display: block;
	width: 100%;
	margin: 1.4em 0;
	border: 0;
	border-radius: var(--radius-sm);
	background: #000;
}

.sc-video-embed {
	position: relative;
	padding-top: 56.25%;
	margin: 1.4em 0;
	border-radius: var(--radius-sm);
	overflow: hidden;
	background: #000;
}

.sc-video-embed iframe {
	position: absolute;
	inset: 0;
	height: 100%;
	margin: 0;
}

.sc-github {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: 0 3px;
	padding: 2px 10px;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	background: var(--paper-2);
	color: var(--ink);
	font-family: var(--mono);
	font-size: 0.9em;
	text-decoration: none;
}

.sc-github:hover {
	color: var(--accent);
	border-color: var(--accent);
}

.sc-friends {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 12px;
	margin: 1.4em 0;
}

.sc-friend {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 14px;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	background: var(--paper-2);
	color: var(--ink);
	text-decoration: none;
	transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}

.sc-friend:hover {
	border-color: var(--accent);
	transform: translateY(-2px);
}

.sc-friend-face {
	flex: 0 0 40px;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	overflow: hidden;
	background: var(--accent-soft);
	color: var(--accent);
	font-weight: 600;
}

.sc-friend-face img {
	width: 40px;
	height: 40px;
	object-fit: cover;
	border-radius: 50%;
	margin: 0;
}

.sc-friend-meta {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.sc-friend-name {
	font-weight: 600;
	font-size: 14px;
}

.sc-friend-desc {
	font-size: 12px;
	color: var(--ink-soft);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.sc-timeline {
	position: relative;
	margin: 1.6em 0;
	padding: 0 0 0 18px;
	list-style: none;
}

.sc-timeline::before {
	content: '';
	position: absolute;
	top: 6px;
	bottom: 6px;
	left: 5px;
	width: 2px;
	background: var(--line);
}

.sc-timeline-item {
	position: relative;
	margin: 0 0 16px;
}

.sc-timeline-time {
	display: block;
	margin-bottom: 2px;
	font-family: var(--mono);
	font-size: 12px;
	color: var(--ink-soft);
}

.sc-timeline-dot {
	position: absolute;
	top: 6px;
	left: -17px;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--accent);
}

.sc-timeline-body {
	padding: 8px 12px;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	background: var(--paper-2);
}

.sc-timeline-title {
	margin: 0;
	font-weight: 600;
	color: var(--ink);
}

.sc-timeline-text {
	margin: 4px 0 0;
	font-size: 14px;
	color: var(--ink-soft);
}

@media (prefers-reduced-motion: reduce) {
	.sc-collapse > summary::before,
	.sc-progress-bar,
	.sc-spoiler,
	.sc-friend {
		transition: none;
	}
}
