:root {
	color-scheme: light;
	--theme-color: #22b988;
	--background: #eef4f2;
	--surface: #fff;
	--panel: #f7faf9;
	--text: #182923;
	--muted: #50655c;
	--subtle: #52675d;
	--line: #d8e5df;
	--accent: color-mix(in oklab, var(--theme-color) 45%, #161616);
	--accent-wash: color-mix(in oklab, var(--theme-color) 16%, white);
	--accent-button: var(--accent);
	--accent-on: #fff;
	--danger: #a42c40;
	--danger-wash: #fceef0;
	--focus: color-mix(in oklab, var(--theme-color) 60%, #272727);
	--banner: #0d362d;
	--radius: 17px;
	--shadow: 0 8px 24px #142e2110;
	font-family:
		"Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui,
		sans-serif;
}
:root[data-theme="dark"] {
	color-scheme: dark;
	--background: #101c18;
	--surface: #192923;
	--panel: #20332b;
	--text: #eef6f1;
	--muted: #b1c5b9;
	--subtle: #a9bdb1;
	--line: #344a40;
	--accent: color-mix(in oklab, var(--theme-color) 37%, white);
	--accent-wash: color-mix(in oklab, var(--theme-color) 18%, #242424);
	--accent-button: var(--accent);
	--accent-on: #11231c;
	--danger: #ffadc0;
	--danger-wash: #4d2833;
	--focus: color-mix(in oklab, var(--theme-color) 34%, white);
	--shadow: 0 8px 24px #0003;
}
* {
	box-sizing: border-box;
}
.symbols {
	display: none;
}
body {
	margin: 0;
	background: var(--background);
	color: var(--text);
	font-size: 16px;
	line-height: 1.5;
}
a {
	color: var(--accent);
	text-decoration: none;
}
button,
input,
textarea,
select {
	color: inherit;
	font: inherit;
}
button,
select {
	cursor: pointer;
}
button:disabled {
	cursor: default;
	opacity: 0.55;
}
:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 3px;
}
button,
a,
input,
textarea,
select {
	-webkit-tap-highlight-color: transparent;
}
input:not([type="checkbox"]):not([type="file"]),
textarea,
select {
	width: 100%;
	min-height: 44px;
	border: 1px solid var(--line);
	border-radius: 10px;
	background: var(--panel);
	padding: 9px 12px;
	color: var(--text);
}
textarea {
	line-height: 1.65;
	resize: vertical;
}
label {
	display: block;
	font-size: 0.9rem;
	font-weight: 650;
}
p {
	margin: 0;
}
h1,
h2,
h3 {
	margin: 0;
	line-height: 1.24;
}
.icon {
	flex: 0 0 auto;
	width: 19px;
	height: 19px;
	stroke: currentColor;
	stroke-width: 1.7;
	stroke-linecap: round;
	stroke-linejoin: round;
	fill: none;
}
.icon-fill {
	stroke-width: 2.9;
}
.button,
.icon-button {
	display: inline-flex;
	justify-content: center;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	border-radius: 10px;
	border: 1px solid var(--line);
	background: var(--surface);
	padding: 8px 14px;
	font-size: 0.9rem;
	font-weight: 650;
	white-space: nowrap;
	transition:
		color 0.16s,
		background 0.16s,
		border-color 0.16s;
}
.button:hover:not(:disabled),
.icon-button:hover:not(:disabled) {
	border-color: var(--accent);
	color: var(--accent);
}
.primary {
	border-color: transparent;
	background: var(--accent-button);
	color: var(--accent-on);
}
.primary:hover:not(:disabled) {
	color: var(--accent-on);
	background: color-mix(in srgb, var(--accent-button), var(--accent-on) 12%);
	border-color: transparent;
}
.button.danger {
	color: var(--danger);
}
.icon-button {
	width: 44px;
	padding: 0;
}
.brand {
	display: inline-flex;
	align-items: center;
	color: inherit;
	gap: 10px;
	text-align: left;
}
.brand img {
	border-radius: 10px;
}
.brand strong,
.brand small {
	display: block;
}
.brand strong {
	font-size: 1.12rem;
	line-height: 1.25;
	letter-spacing: -0.02em;
	overflow-wrap: anywhere;
}
.brand small {
	color: var(--muted);
	font-size: 0.76rem;
}
.skip {
	position: fixed;
	top: 10px;
	left: 10px;
	background: var(--surface);
	padding: 8px 16px;
	z-index: 3;
	transform: translateY(-200%);
}
.skip:focus {
	transform: none;
}
.shell {
	min-height: 100vh;
	display: grid;
	grid-template-columns: 224px minmax(0, 1fr);
}
.sidebar {
	position: sticky;
	top: 0;
	height: 100vh;
	display: flex;
	flex-direction: column;
	gap: 24px;
	padding: 29px 16px 18px;
	background: var(--surface);
	border-right: 1px solid var(--line);
}
.sidebar-brand {
	margin: 0 9px;
}
.navigation,
.sidebar-end {
	display: grid;
	gap: 4px;
}
.sidebar-end {
	margin-top: auto;
}
.nav-item {
	display: flex;
	align-items: center;
	gap: 12px;
	min-height: 46px;
	padding: 8px 12px;
	text-align: left;
	border: 0;
	border-radius: 10px;
	color: var(--muted);
	background: transparent;
	font-size: 0.95rem;
	font-weight: 650;
}
.nav-item:hover {
	background: var(--panel);
	color: var(--text);
}
.nav-item[aria-current="page"] {
	background: var(--accent-wash);
	color: var(--accent);
}
.main {
	width: min(100%, 1300px);
	min-width: 0;
	margin-inline: auto;
	padding: 0 clamp(19px, 3.5vw, 55px) 44px;
}
.topbar {
	display: flex;
	justify-content: flex-end;
	align-items: center;
	gap: 8px;
	min-height: 76px;
	color: var(--muted);
	font-weight: 650;
}
.top-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.hero,
.login-art {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	color: #effaf6;
	background: var(--banner);
	background-image:
		linear-gradient(
			90deg,
			#102c27fa 0%,
			#102c27e3 27%,
			#102c2799 62%,
			#18352e45 100%
		),
		url("/banner.avif");
	background-position:
		center,
		center 49%;
	background-size: cover;
}
.hero::after,
.login-art::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: radial-gradient(ellipse at 76% 102%, #75edb545, transparent 60%);
	pointer-events: none;
}
.hero {
	min-height: 178px;
	display: flex;
	align-items: center;
	background-position:
		center,
		center 23%;
	border-radius: var(--radius);
	margin-bottom: 22px;
	box-shadow: var(--shadow);
}
.hero-content {
	padding: 24px clamp(19px, 4vw, 38px);
	max-width: 100%;
}
#hero-site {
	font-size: 0.83rem;
	color: #baf2d9;
	font-weight: 650;
	margin-bottom: 6px;
	overflow-wrap: anywhere;
}
.hero h1 {
	font-size: clamp(1.9rem, 3.6vw, 2.7rem);
	font-weight: 790;
	letter-spacing: -0.055em;
}
#page-description {
	color: #d6ede3;
	margin-top: 8px;
	font-size: 0.95rem;
}
.view {
	min-width: 0;
}
.card {
	min-width: 0;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--surface);
	box-shadow: var(--shadow);
}
.card-head,
.card-body,
.card-foot {
	padding: 20px clamp(15px, 2.6vw, 26px);
}
.card-head {
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	border-bottom: 1px solid var(--line);
}
.card-head h2 {
	font-size: 1.14rem;
}
.card-head p,
.help,
.empty,
.file-meta {
	color: var(--subtle);
	font-size: 0.87rem;
}
.card-head p {
	margin-top: 4px;
}
.card-foot {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	align-items: center;
	gap: 9px;
	border-top: 1px solid var(--line);
}
.tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
	padding: 7px;
	width: fit-content;
	max-width: 100%;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 13px;
	margin-bottom: 12px;
}
.tab {
	min-height: 44px;
	padding: 6px 13px;
	border: 0;
	border-radius: 8px;
	background: transparent;
	color: var(--muted);
	font-size: 0.9rem;
	font-weight: 650;
}
.tab[aria-pressed="true"] {
	background: var(--accent-wash);
	color: var(--accent);
}
.tab:hover {
	color: var(--accent);
}
.fields {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 19px 22px;
}
.field {
	min-width: 0;
	display: grid;
	gap: 6px;
	align-content: start;
}
.field.wide {
	grid-column: 1 / -1;
}
.field textarea {
	min-height: 82px;
}
.field .long {
	min-height: 140px;
}
.field .toggle {
	min-height: 44px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	border: 1px solid var(--line);
	background: var(--panel);
	border-radius: 10px;
	padding: 6px 11px;
	cursor: pointer;
}
.toggle input {
	width: 18px;
	height: 18px;
	accent-color: var(--accent-button);
}
.help {
	margin-top: 1px;
	overflow-wrap: anywhere;
}
.card-foot .help {
	margin-right: auto;
}
.config-tools {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 232px), 1fr));
	gap: 12px;
	margin-bottom: 12px;
}
.record-list {
	display: grid;
	gap: 14px;
}
.record {
	min-width: 0;
	margin: 0;
	padding: 12px clamp(12px, 2vw, 18px) 15px;
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: 12px;
}
.record legend {
	padding-inline: 6px;
	color: var(--accent);
	font-weight: 650;
	overflow-wrap: anywhere;
}
.record-actions {
	display: flex;
	justify-content: flex-end;
	margin-top: 10px;
}
.fields > .wide {
	grid-column: 1 / -1;
}
.rgb-input {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 48px;
	gap: 8px;
}
.rgb-input input[type="color"] {
	height: 44px;
	padding: 4px;
	cursor: pointer;
}
.actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}
.status {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	min-height: 32px;
	border-radius: 30px;
	padding: 4px 11px;
	color: var(--accent);
	background: var(--accent-wash);
	font-size: 0.82rem;
	font-weight: 650;
}
.status::before {
	content: "";
	background: currentColor;
	width: 7px;
	height: 7px;
	border-radius: 50%;
}
.status[data-phase="failure"] {
	color: var(--danger);
	background: var(--danger-wash);
}
.feedback,
.toast {
	padding: 10px 15px;
	border-radius: 10px;
	overflow-wrap: anywhere;
}
.feedback {
	color: var(--danger);
	background: var(--danger-wash);
	margin-bottom: 12px;
}
.toast {
	position: fixed;
	z-index: 2;
	right: 20px;
	bottom: 20px;
	max-width: min(85vw, 440px);
	background: var(--surface);
	border: 1px solid var(--line);
	box-shadow: var(--shadow);
}
.split {
	display: grid;
	grid-template-columns: minmax(220px, 0.63fr) minmax(0, 1.37fr);
	gap: 15px;
	align-items: start;
}
.search {
	padding: 13px 14px 2px;
}
.file-list {
	display: grid;
	gap: 3px;
	padding: 9px 9px 14px;
	max-height: 510px;
	overflow: auto;
}
.file {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 7px;
	min-height: 51px;
	width: 100%;
	text-align: left;
	padding: 7px 10px;
	border: 0;
	border-radius: 8px;
	background: transparent;
}
.file:hover,
.file[aria-pressed="true"] {
	background: var(--accent-wash);
	color: var(--accent);
}
.file span {
	min-width: 0;
	overflow-wrap: anywhere;
}
.file small {
	display: block;
	color: var(--subtle);
}
.editor-fields {
	display: grid;
	gap: 14px;
}
.source {
	min-height: clamp(240px, 42vh, 570px);
	font-family: "Cascadia Code", Consolas, "Noto Sans Mono CJK SC", monospace;
	font-size: 0.88rem;
	tab-size: 4;
}
.empty {
	padding: 24px 15px;
}
.card-body.empty {
	padding: 38px 24px;
	text-align: center;
}
.media-grid {
	display: grid;
	gap: 13px;
	grid-template-columns: repeat(auto-fit, minmax(min(211px, 100%), 1fr));
}
.media-card {
	border: 1px solid var(--line);
	border-radius: 12px;
	overflow: hidden;
}
.media-thumb {
	display: block;
	width: 100%;
	height: 145px;
	object-fit: contain;
	background: var(--panel);
}
.media-info {
	display: grid;
	gap: 7px;
	padding: 11px;
	min-width: 0;
}
.media-info strong {
	overflow-wrap: anywhere;
}
.media-info code {
	overflow-wrap: anywhere;
	color: var(--muted);
	font-size: 0.78rem;
}
.media-info .button {
	padding-inline: 9px;
	font-size: 0.8rem;
}
.publish-summary {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 24px;
	align-items: baseline;
}
.publish-log {
	white-space: pre-wrap;
	overflow: auto;
	overflow-wrap: anywhere;
	min-height: 185px;
	max-height: 420px;
	margin: 14px 0 0;
	padding: 14px;
	border-radius: 10px;
	background: #10241d;
	color: #d1f0df;
	font:
		0.82rem / 1.65 "Cascadia Code",
		Consolas,
		monospace;
}
.login-layout {
	min-height: 100vh;
	padding: 22px;
	display: grid;
	place-items: center;
}
.login-card {
	display: grid;
	grid-template-columns: 1fr 1fr;
	width: min(800px, 100%);
	border: 1px solid var(--line);
	border-radius: 22px;
	overflow: hidden;
	background: var(--surface);
	box-shadow: var(--shadow);
}
.login-art {
	min-height: 380px;
	display: flex;
	align-items: flex-end;
	padding: 31px;
}
.login-art-copy .brand {
	margin-bottom: 10px;
	color: #ddfff0;
	font-weight: 750;
}
.login-form {
	padding: 28px clamp(21px, 4vw, 46px);
	align-self: center;
}
.login-form h1 {
	font-size: 1.56rem;
	margin-bottom: 22px;
}
.login-form form {
	display: grid;
	gap: 8px;
}
.login-form .button {
	margin-top: 6px;
	justify-self: start;
}
.form-error {
	color: var(--danger);
	min-height: 1.35rem;
	font-size: 0.88rem;
}
@media (max-width: 900px) {
	.shell {
		grid-template-columns: 173px minmax(0, 1fr);
	}
	.sidebar {
		padding-inline: 11px;
	}
	.split {
		grid-template-columns: minmax(170px, 0.65fr) minmax(0, 1.35fr);
	}
}
@media (max-width: 690px) {
	.shell {
		display: block;
		padding-top: 0;
		padding-bottom: calc(66px + env(safe-area-inset-bottom));
	}
	.sidebar {
		position: static;
		height: auto;
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		padding: 9px 12px;
		border-right: 0;
		border-bottom: 1px solid var(--line);
		gap: 6px;
	}
	.sidebar-brand {
		margin: 0;
	}
	.sidebar-end {
		margin: 0;
		display: flex;
		gap: 0;
	}
	.sidebar-end .nav-item {
		gap: 4px;
		padding: 3px 6px;
		font-size: 0.78rem;
	}
	.sidebar-end .icon {
		width: 15px;
	}
	.navigation {
		position: fixed;
		z-index: 2;
		display: grid;
		grid-template-columns: repeat(5, 1fr);
		gap: 2px;
		bottom: 0;
		left: 0;
		right: 0;
		background: var(--surface);
		border-top: 1px solid var(--line);
		padding: 4px 4px calc(4px + env(safe-area-inset-bottom));
	}
	.navigation .nav-item {
		flex-direction: column;
		justify-content: center;
		text-align: center;
		gap: 2px;
		padding: 5px 2px;
		font-size: 0.75rem;
	}
	.navigation .icon {
		width: 18px;
		height: 18px;
	}
	.main {
		padding: 0 12px 20px;
	}
	.topbar {
		min-height: 61px;
		font-size: 0.86rem;
	}
	.hero {
		min-height: 147px;
		margin-bottom: 14px;
	}
	.hero-content {
		padding-block: 16px;
	}
	.toast {
		bottom: calc(70px + env(safe-area-inset-bottom));
		right: 10px;
	}
	.fields,
	.split {
		grid-template-columns: 1fr;
	}
	.file-list {
		max-height: 245px;
	}
	.login-card {
		grid-template-columns: 1fr;
	}
	.login-art {
		min-height: 220px;
		padding: 20px;
	}
}
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition: none;
		scroll-behavior: auto;
	}
}

:root [hidden] {
	display: none;
}
