/* Commerce Lite — 布局与样式 */

:root {
	--cl-bg: #faf9f7;
	--cl-surface: #ffffff;
	--cl-text: #1a1a1a;
	--cl-muted: #5c5c5c;
	--cl-accent: #c45c26;
	--cl-accent-hover: #a34a1d;
	--cl-border: #e8e4df;
	--cl-radius: 10px;
	--cl-shadow: 0 8px 24px rgba(26, 26, 26, 0.06);
	--cl-max: 1120px;
	--cl-font: system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

body {
	margin: 0;
	font-family: var(--cl-font);
	font-size: 1rem;
	line-height: 1.6;
	color: var(--cl-text);
	background: var(--cl-bg);
}

a {
	color: var(--cl-accent);
	text-decoration: none;
}

a:hover {
	color: var(--cl-accent-hover);
	text-decoration: underline;
}

img {
	max-width: 100%;
	height: auto;
	vertical-align: middle;
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: fixed;
	top: 8px;
	left: 8px;
	z-index: 100000;
	padding: 0.5rem 1rem;
	background: var(--cl-surface);
	clip: auto;
	width: auto;
	height: auto;
}

/* Header */
.site-header {
	background: var(--cl-surface);
	border-bottom: 1px solid var(--cl-border);
	position: sticky;
	top: 0;
	z-index: 50;
}

.site-header__inner {
	max-width: var(--cl-max);
	margin: 0 auto;
	padding: 0.75rem 1.25rem;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 1rem;
	justify-content: space-between;
}

.site-branding .custom-logo-link {
	display: inline-block;
}

.site-title {
	font-size: 1.25rem;
	font-weight: 700;
	color: var(--cl-text);
	text-decoration: none;
}

.site-title:hover {
	text-decoration: none;
	color: var(--cl-accent);
}

.site-description {
	margin: 0.15rem 0 0;
	font-size: 0.85rem;
	color: var(--cl-muted);
}

.site-nav .menu {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.25rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.site-nav .menu a {
	color: var(--cl-text);
	font-weight: 500;
	text-decoration: none;
}

.site-nav .menu a:hover {
	color: var(--cl-accent);
}

.site-header__actions {
	margin-left: auto;
}

.wishlist-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	padding: 0.35rem 0.75rem;
	background: var(--cl-bg);
	border: 1px solid var(--cl-border);
	border-radius: 999px;
	color: var(--cl-text);
	font-size: 0.875rem;
	text-decoration: none;
}

.wishlist-badge:hover {
	border-color: var(--cl-accent);
	text-decoration: none;
}

.wishlist-badge__count {
	min-width: 1.25rem;
	height: 1.25rem;
	padding: 0 0.35rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: var(--cl-accent);
	color: #fff;
	border-radius: 999px;
	font-size: 0.75rem;
	font-weight: 700;
}

/* Main */
.site-main {
	min-height: 50vh;
}

.content-wrap {
	max-width: var(--cl-max);
	margin: 0 auto;
	padding: 2rem 1.25rem 3rem;
}

.content-wrap--front {
	padding-top: 1rem;
}

/* Hero */
.hero {
	background: linear-gradient(135deg, #2d2418 0%, #4a3728 50%, #2d2418 100%);
	color: #f5f0e8;
	padding: 3.5rem 1.25rem;
	text-align: center;
}

.hero__inner {
	max-width: 36rem;
	margin: 0 auto;
}

.hero__title {
	margin: 0 0 0.5rem;
	font-size: clamp(1.75rem, 4vw, 2.25rem);
	font-weight: 700;
	letter-spacing: -0.02em;
}

.hero__lead {
	margin: 0 0 1.5rem;
	opacity: 0.92;
	font-size: 1.05rem;
}

.hero__cta {
	margin: 0;
}

/* Typography blocks */
.page-header {
	margin-bottom: 1.75rem;
}

.page-title {
	margin: 0 0 0.5rem;
	font-size: clamp(1.5rem, 3vw, 2rem);
}

.archive-description {
	color: var(--cl-muted);
	max-width: 42rem;
}

.section-title {
	font-size: 1.35rem;
	margin: 0 0 1.25rem;
	padding-bottom: 0.5rem;
	border-bottom: 2px solid var(--cl-border);
}

.section-more,
.section-empty {
	text-align: center;
	margin-top: 2rem;
}

/* Buttons */
.button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.35rem;
	padding: 0.55rem 1.1rem;
	font-size: 0.95rem;
	font-weight: 600;
	font-family: inherit;
	line-height: 1.2;
	border-radius: var(--cl-radius);
	border: 1px solid var(--cl-border);
	background: var(--cl-surface);
	color: var(--cl-text);
	cursor: pointer;
	text-decoration: none;
	transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.button:hover {
	text-decoration: none;
	border-color: var(--cl-accent);
	color: var(--cl-accent);
}

.button--primary {
	background: var(--cl-accent);
	border-color: var(--cl-accent);
	color: #fff;
}

.button--primary:hover {
	background: var(--cl-accent-hover);
	border-color: var(--cl-accent-hover);
	color: #fff;
}

.button--ghost {
	background: transparent;
}

.button--small {
	padding: 0.4rem 0.75rem;
	font-size: 0.85rem;
}

/* Product grid */
.product-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 1.5rem;
}

.product-card {
	background: var(--cl-surface);
	border-radius: var(--cl-radius);
	overflow: hidden;
	border: 1px solid var(--cl-border);
	box-shadow: var(--cl-shadow);
	display: flex;
	flex-direction: column;
}

.product-card__thumb {
	display: block;
	aspect-ratio: 1;
	overflow: hidden;
	background: #eee;
}

.product-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.product-card__placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	color: var(--cl-muted);
	font-size: 0.9rem;
}

.product-card__body {
	padding: 1rem 1rem 1.15rem;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	flex: 1;
}

.product-card__title {
	margin: 0;
	font-size: 1.05rem;
	line-height: 1.35;
}

.product-card__title a {
	color: var(--cl-text);
	text-decoration: none;
}

.product-card__title a:hover {
	color: var(--cl-accent);
}

.product-card__price-row {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.35rem 0.65rem;
}

.product-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-top: auto;
	padding-top: 0.35rem;
}

.price--compare {
	font-size: 0.85rem;
	color: var(--cl-muted);
	text-decoration: line-through;
}

.price--current {
	font-size: 1.1rem;
	font-weight: 700;
	color: var(--cl-accent);
}

.entry-content > *:first-child {
	margin-top: 0;
}

/* Pagination */
.pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: center;
	margin-top: 2rem;
	list-style: none;
	padding: 0;
}

.pagination a,
.pagination span {
	padding: 0.35rem 0.65rem;
	border: 1px solid var(--cl-border);
	border-radius: 6px;
	background: var(--cl-surface);
}

/* Footer */
.site-footer {
	background: #2a2520;
	color: #d4cfc7;
	margin-top: 3rem;
	padding: 2rem 1.25rem;
}

.site-footer a {
	color: #f0ebe3;
}

.site-footer__inner {
	max-width: var(--cl-max);
	margin: 0 auto;
	text-align: center;
}

.site-footer__widgets {
	margin-bottom: 1.5rem;
	text-align: left;
}

/* 页脚联系 / 社交 / 二维码 */
.footer-contact {
	border-top: 1px solid rgba(255, 255, 255, 0.12);
	padding-top: 1.5rem;
	margin-bottom: 1.5rem;
	text-align: left;
}

.footer-contact__inner {
	max-width: 42rem;
	margin: 0 auto;
}

.footer-contact__heading {
	margin: 0 0 0.75rem;
	font-size: 1rem;
	font-weight: 700;
	color: #f0ebe3;
	text-align: center;
}

.footer-contact__intro {
	margin: 0 0 1rem;
	font-size: 0.9rem;
	line-height: 1.55;
	color: #d4cfc7;
	text-align: center;
}

.footer-contact__grid {
	display: flex;
	flex-direction: column;
	flex-wrap: wrap;
	gap: 1.25rem 2rem;
	align-items: stretch;
}

@media (min-width: 640px) {
	.footer-contact__grid {
		flex-direction: row;
		flex-wrap: wrap;
		align-items: flex-start;
		justify-content: center;
	}

	.footer-contact__direct,
	.footer-contact__social-wrap {
		flex: 1 1 220px;
		max-width: 320px;
	}

	.footer-contact__qr {
		flex: 0 0 auto;
		width: 100%;
		text-align: center;
	}
}

@media (min-width: 900px) {
	.footer-contact__grid {
		flex-wrap: nowrap;
		justify-content: space-between;
		align-items: center;
	}

	.footer-contact__direct {
		flex: 0 1 200px;
		max-width: none;
	}

	.footer-contact__social-wrap {
		flex: 1 1 260px;
		max-width: none;
	}

	.footer-contact__qr {
		flex: 0 0 auto;
		width: auto;
		text-align: center;
	}

	.footer-contact__heading,
	.footer-contact__intro {
		text-align: left;
	}

	.footer-contact__inner {
		max-width: none;
	}
}

.footer-contact__sub {
	margin: 0 0 0.5rem;
	font-size: 0.75rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: rgba(240, 235, 227, 0.75);
}

.footer-contact__direct {
	font-size: 0.9rem;
}

.footer-contact__line {
	margin: 0 0 0.4rem;
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem 0.65rem;
	align-items: baseline;
}

.footer-contact__line:last-child {
	margin-bottom: 0;
}

.footer-contact__key {
	color: rgba(240, 235, 227, 0.65);
	min-width: 2.5rem;
}

.footer-contact__val {
	color: #f0ebe3;
	font-weight: 500;
}

.footer-contact__val:hover {
	color: #fff;
}

.footer-social {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 0.65rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.footer-social__link {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.4rem 0.65rem;
	border-radius: 8px;
	border: 1px solid rgba(255, 255, 255, 0.2);
	color: #f0ebe3;
	font-size: 0.85rem;
	text-decoration: none;
	transition: background 0.15s ease, border-color 0.15s ease;
}

.footer-social__link:hover {
	background: rgba(255, 255, 255, 0.08);
	border-color: rgba(255, 255, 255, 0.35);
	color: #fff;
	text-decoration: none;
}

.footer-social__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0.95;
}

.footer-social__icon svg {
	display: block;
}

.footer-qr {
	margin: 0;
}

.footer-qr__img {
	display: block;
	width: 112px;
	height: auto;
	max-width: 100%;
	border-radius: 8px;
	border: 4px solid #fff;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
	background: #fff;
}

.footer-nav .menu {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.25rem;
	justify-content: center;
	list-style: none;
	margin: 0 0 1rem;
	padding: 0;
}

.site-footer__copy {
	margin: 0;
	font-size: 0.9rem;
	opacity: 0.85;
}

/* Wishlist page */
.commerce-wishlist-intro {
	color: var(--cl-muted);
	max-width: 40rem;
}

.commerce-wishlist-list {
	list-style: none;
	padding: 0;
	margin: 1rem 0;
}

.commerce-wishlist-list li {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.5rem 1rem;
	padding: 0.75rem 0;
	border-bottom: 1px solid var(--cl-border);
}

.commerce-wishlist-list a {
	font-weight: 600;
	color: var(--cl-text);
}

.commerce-wishlist-actions {
	margin-top: 1.5rem;
}

/* Toast */
.commerce-toast {
	position: fixed;
	bottom: 1.25rem;
	left: 50%;
	transform: translateX(-50%) translateY(120%);
	background: #2a2520;
	color: #fff;
	padding: 0.65rem 1.25rem;
	border-radius: 999px;
	font-size: 0.9rem;
	z-index: 200;
	opacity: 0;
	transition: transform 0.25s ease, opacity 0.25s ease;
	pointer-events: none;
}

.commerce-toast.is-visible {
	transform: translateX(-50%) translateY(0);
	opacity: 1;
}

/* Post list (blog fallback) */
.post-list {
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
}

.post-card {
	padding: 1.25rem;
	background: var(--cl-surface);
	border: 1px solid var(--cl-border);
	border-radius: var(--cl-radius);
}

.post-card__title {
	margin: 0 0 0.35rem;
	font-size: 1.2rem;
}

.page-article .entry-content {
	max-width: 42rem;
}

/* Inquiry form（短代码独立页等） */
.commerce-inquiry {
	margin-top: 2rem;
	padding: 1.5rem 1.25rem 1.75rem;
	background: var(--cl-surface);
	border: 1px solid var(--cl-border);
	border-radius: var(--cl-radius);
	box-shadow: var(--cl-shadow);
}

.commerce-inquiry__title {
	margin: 0 0 0.5rem;
	font-size: 1.25rem;
}

.commerce-inquiry__hint {
	margin: 0 0 1.25rem;
	font-size: 0.9rem;
	color: var(--cl-muted);
}

.commerce-inquiry__form .commerce-field-wrap {
	margin: 0 0 1rem;
}

.commerce-inquiry__form label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.35rem;
}

.commerce-inquiry__form .required {
	color: var(--cl-accent);
}

.commerce-field {
	width: 100%;
	max-width: 32rem;
	padding: 0.5rem 0.65rem;
	font: inherit;
	border: 1px solid var(--cl-border);
	border-radius: 8px;
	background: #fff;
}

textarea.commerce-field {
	resize: vertical;
	min-height: 120px;
}

.commerce-inquiry__honeypot {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.commerce-inquiry__submit {
	margin: 1.25rem 0 0;
}

/* Notices */
.commerce-notice {
	max-width: var(--cl-max);
	margin: 0 auto 1rem;
	padding: 0.85rem 1rem;
	border-radius: var(--cl-radius);
	border: 1px solid var(--cl-border);
	font-weight: 500;
}

.commerce-notice--sent {
	background: #ecf9f0;
	border-color: #b8e0c8;
	color: #1e5c33;
}

.commerce-notice--fail,
.commerce-notice--error,
.commerce-notice--invalid {
	background: #fdf2f2;
	border-color: #f0c4c4;
	color: #7a2424;
}

.commerce-notice--slow {
	background: #fff8e6;
	border-color: #f0d9a6;
	color: #6a4a00;
}
