/*
 * FiveMLicense · 主样式
 * 布局 / 组件 / 响应式。颜色令牌见 dark.css 与 light.css，
 * 主色调 CSS 变量由 functions.php::fiveml_dynamic_css() 注入。
 *
 * 设计约束：低饱和冷蓝灰、克制留白、信息层级优先。
 * 毛玻璃：backdrop-filter: blur(12px) + 半透底色 + 1px 细边框 + 柔和浅阴影。
 */

/* ==========================================================================
   1. 基础
   ========================================================================== */

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

html { scroll-behavior: smooth; }

body.fml-site {
	margin: 0;
	min-height: 100vh;
	background: var(--fml-bg);
	color: var(--fml-text);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Roboto, sans-serif;
	font-size: 15px;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
	transition: background-color .3s ease, color .3s ease;
}

img, svg { max-width: 100%; }
img { height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4 { margin: 0; line-height: 1.3; font-weight: 650; letter-spacing: -.02em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--fml-accent); outline-offset: 3px; border-radius: 4px; }
::selection { background: rgba(var(--fml-accent-rgb), .30); }

.fml-skip-link {
	position: fixed; top: -60px; left: 16px; z-index: 999;
	padding: 10px 18px; border-radius: 10px;
	background: var(--fml-accent); color: var(--fml-accent-contrast);
	transition: top .2s ease;
}
.fml-skip-link:focus { top: 12px; }

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

.fml-container { width: min(1200px, calc(100% - 48px)); margin-inline: auto; }
.fml-container--narrow { width: min(820px, calc(100% - 48px)); }
.fml-main { position: relative; z-index: 1; min-height: 60vh; }
.fml-section { padding: 72px 0; }
.fml-section--muted { background: var(--fml-section-muted); border-block: 1px solid var(--fml-border); }
[hidden] { display: none !important; }

/* 环境光：低饱和冷蓝灰渐变 + 极淡网格，无立绘 / 无高饱和装饰 */
.fml-ambient { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.fml-ambient__blob { position: absolute; display: block; border-radius: 50%; filter: blur(110px); opacity: .5; }
.fml-ambient__blob--a { width: 620px; height: 620px; top: -260px; left: -180px; background: radial-gradient(circle, rgba(var(--fml-accent-rgb), .22), transparent 70%); }
.fml-ambient__blob--b { width: 520px; height: 520px; bottom: -240px; right: -160px; background: radial-gradient(circle, rgba(110, 145, 175, .16), transparent 70%); }
.fml-ambient__grid {
	position: absolute; inset: 0;
	background-image: linear-gradient(var(--fml-grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--fml-grid-line) 1px, transparent 1px);
	background-size: 64px 64px;
	mask-image: linear-gradient(to bottom, rgba(0,0,0,.6), transparent 65%);
	-webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,.6), transparent 65%);
}

/* ==========================================================================
   2. 毛玻璃基类 / 通用元件
   ========================================================================== */

.fml-glass {
	background: var(--fml-surface);
	-webkit-backdrop-filter: blur(12px);
	backdrop-filter: blur(12px);
	border: 1px solid var(--fml-border);
	box-shadow: var(--fml-shadow);
	border-radius: var(--fml-radius);
}
body.fml-no-glass .fml-glass {
	background: var(--fml-surface-solid);
	-webkit-backdrop-filter: none;
	backdrop-filter: none;
}

.fml-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	padding: 11px 20px; border-radius: 10px;
	border: 1px solid transparent; background: transparent;
	font-size: 14px; font-weight: 600; line-height: 1.4;
	white-space: nowrap; text-align: center;
	transition: transform .18s ease, background-color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.fml-btn:hover { transform: translateY(-1px); }
.fml-btn:active { transform: translateY(0); }
.fml-btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.fml-btn--primary {
	background: var(--fml-btn-bg); color: var(--fml-accent-contrast);
	box-shadow: 0 6px 20px rgba(var(--fml-accent-rgb), .22);
}
.fml-btn--primary:hover { background: var(--fml-btn-bg-hover); box-shadow: 0 8px 26px rgba(var(--fml-accent-rgb), .30); }
.fml-btn--ghost { border-color: var(--fml-border-strong); color: var(--fml-text); background: var(--fml-surface-2); }
.fml-btn--ghost:hover { border-color: var(--fml-accent); color: var(--fml-accent); }
.fml-btn--block { width: 100%; }
.fml-btn--sm { padding: 8px 14px; font-size: 13px; }
.fml-btn--lg { padding: 14px 28px; font-size: 15px; }
.fml-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.fml-icon-btn {
	display: inline-grid; place-items: center; width: 38px; height: 38px; padding: 0;
	border: 1px solid var(--fml-border); border-radius: 10px;
	background: var(--fml-surface-2); color: var(--fml-text-2);
	transition: color .18s ease, border-color .18s ease, background-color .18s ease;
}
.fml-icon-btn:hover { color: var(--fml-accent); border-color: var(--fml-accent); }
.fml-icon-btn svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
html[data-theme="dark"] .fml-icon-sun { display: none; }
html[data-theme="light"] .fml-icon-moon { display: none; }

.fml-eyebrow {
	display: inline-flex; align-items: center; gap: 8px;
	font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
	color: var(--fml-accent);
}
.fml-eyebrow__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--fml-accent); box-shadow: 0 0 0 4px rgba(var(--fml-accent-rgb), .14); }

.fml-status {
	display: inline-flex; align-items: center; gap: 6px;
	padding: 4px 10px; border-radius: 999px;
	font-size: 12px; font-weight: 600; line-height: 1.4;
	border: 1px solid var(--fml-border);
	background: var(--fml-surface-2); color: var(--fml-text-2);
}
.fml-status__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.fml-status--ok { color: var(--fml-ok); border-color: var(--fml-ok-border); background: var(--fml-ok-bg); }
.fml-status--pending { color: var(--fml-warn); border-color: var(--fml-warn-border); background: var(--fml-warn-bg); }
.fml-status--warn { color: var(--fml-warn); border-color: var(--fml-warn-border); background: var(--fml-warn-bg); }
.fml-status--off { color: var(--fml-text-3); border-color: var(--fml-border); background: var(--fml-surface-2); }

.fml-tag { display: inline-block; padding: 4px 10px; border-radius: 8px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); font-size: 12px; color: var(--fml-text-3); }

.fml-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.fml-chip {
	display: inline-flex; align-items: center; gap: 8px;
	padding: 8px 14px; border-radius: 999px;
	border: 1px solid var(--fml-border); background: var(--fml-surface-2);
	color: var(--fml-text-2); font-size: 13px;
	transition: all .18s ease;
}
.fml-chip:hover { border-color: var(--fml-accent); color: var(--fml-accent); }
.fml-chip.is-active { background: rgba(var(--fml-accent-rgb), .16); border-color: rgba(var(--fml-accent-rgb), .45); color: var(--fml-accent); font-weight: 600; }
.fml-chip__count { font-size: 11px; color: var(--fml-text-3); }

.fml-link-more { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--fml-accent); }
.fml-link-more:hover { text-decoration: underline; text-underline-offset: 4px; }
.fml-empty-state, .fml-empty { grid-column: 1 / -1; padding: 40px; text-align: center; color: var(--fml-text-3); }
.fml-loading { padding: 32px; text-align: center; color: var(--fml-text-3); font-size: 14px; }

/* ==========================================================================
   3. 头部
   ========================================================================== */

.fml-header { position: sticky; top: 0; z-index: 60; border-radius: 0; border-width: 0 0 1px; box-shadow: var(--fml-shadow-soft); }
.fml-header__inner { display: flex; align-items: center; gap: 24px; min-height: 70px; }
.fml-brand { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.fml-brand__logo img { max-height: 40px; width: auto; }
.fml-brand__mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: rgba(var(--fml-accent-rgb), .14); border: 1px solid rgba(var(--fml-accent-rgb), .28); }
.fml-brand__name { font-size: 17px; font-weight: 700; letter-spacing: -.02em; color: var(--fml-text); }

.fml-nav { flex: 1 1 auto; min-width: 0; }
.fml-nav__list { display: flex; align-items: center; gap: 4px; list-style: none; }
.fml-nav__list li { position: relative; }
.fml-nav__list a { display: block; padding: 8px 14px; border-radius: 8px; font-size: 14px; font-weight: 500; color: var(--fml-text-2); transition: color .18s ease, background-color .18s ease; }
.fml-nav__list a:hover, .fml-nav__list .current-menu-item > a { color: var(--fml-accent); background: rgba(var(--fml-accent-rgb), .10); }
.fml-nav__list .sub-menu, .fml-nav__list .children { display: none; position: absolute; top: 100%; left: 0; min-width: 180px; padding: 8px; list-style: none; border-radius: 12px; background: var(--fml-surface-solid); border: 1px solid var(--fml-border); box-shadow: var(--fml-shadow); }
.fml-nav__list li:hover > .sub-menu, .fml-nav__list li:hover > .children { display: block; }
.fml-nav__list .sub-menu a, .fml-nav__list .children a { padding: 8px 12px; }

.fml-header__actions { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.fml-search { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); }
.fml-search:focus-within { border-color: var(--fml-accent); }
.fml-search__icon { width: 16px; height: 16px; flex: 0 0 auto; fill: none; stroke: var(--fml-text-3); stroke-width: 1.8; stroke-linecap: round; }
.fml-search__input { width: 150px; border: 0; outline: 0; background: transparent; font-size: 13px; color: var(--fml-text); }
.fml-search__input::placeholder { color: var(--fml-text-3); }
.fml-user-chip { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 999px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); font-size: 13px; font-weight: 600; }
.fml-user-chip:hover { border-color: var(--fml-accent); }
.fml-user-chip img { border-radius: 50%; }
.fml-menu-toggle { display: none; }

/* ==========================================================================
   4. 首页横幅
   ========================================================================== */

.fml-hero {
	position: relative; overflow: hidden;
	margin: 40px auto 0; width: min(1200px, calc(100% - 48px));
	background-size: cover; background-position: center;
}
.fml-hero::before {
	content: ""; position: absolute; inset: 0; pointer-events: none;
	background: radial-gradient(1000px 400px at 85% 10%, rgba(var(--fml-accent-rgb), .14), transparent 70%);
}
.fml-hero__inner { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; align-items: center; gap: 48px; padding: 64px 56px; width: 100%; }
.fml-hero__title { margin: 18px 0 14px; font-size: clamp(30px, 4vw, 46px); font-weight: 700; letter-spacing: -.035em; }
.fml-hero__desc { max-width: 560px; font-size: 16px; color: var(--fml-text-2); line-height: 1.8; }
.fml-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.fml-hero__facts { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 42px; padding-top: 26px; border-top: 1px solid var(--fml-border); list-style: none; }
.fml-hero__facts li { display: flex; flex-direction: column; gap: 2px; }
.fml-hero__facts strong { font-size: 14px; font-weight: 650; }
.fml-hero__facts span { font-size: 12px; color: var(--fml-text-3); }

.fml-hero__visual { display: grid; place-items: center; }
.fml-hero__panel { width: 100%; max-width: 380px; padding: 0; overflow: hidden; transform: rotate(-2deg); }
.fml-hero__panel-head { display: flex; gap: 6px; padding: 14px 16px; border-bottom: 1px solid var(--fml-border); }
.fml-hero__panel-head span { width: 8px; height: 8px; border-radius: 50%; background: var(--fml-border-strong); }
.fml-hero__panel-body { padding: 22px 20px 20px; display: grid; gap: 14px; }
.fml-hero__row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border: 1px solid var(--fml-border); border-radius: 10px; background: var(--fml-surface-2); }
.fml-hero__row i { display: block; width: 45%; height: 8px; border-radius: 4px; background: var(--fml-border-strong); }
.fml-hero__row em { display: block; width: 22%; height: 8px; border-radius: 4px; background: rgba(var(--fml-accent-rgb), .5); }
.fml-hero__row:nth-child(2) i { width: 62%; }
.fml-hero__row:nth-child(3) i { width: 36%; }
.fml-hero__badge { display: inline-flex; align-items: center; gap: 10px; justify-self: start; margin-top: 6px; font-size: 13px; color: var(--fml-text-2); }

/* ==========================================================================
   5. 区块 / 网格 / 商品卡片
   ========================================================================== */

.fml-section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.fml-section__title { margin: 10px 0 8px; font-size: clamp(24px, 3vw, 32px); }
.fml-section__desc { color: var(--fml-text-3); font-size: 14px; }
.fml-grid { display: grid; gap: 20px; }
.fml-grid--goods { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.fml-grid--docs { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }

.fml-goods-card { display: flex; flex-direction: column; overflow: hidden; transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease; }
.fml-goods-card:hover { transform: translateY(-4px); border-color: var(--fml-border-strong); box-shadow: var(--fml-shadow-hover); }
.fml-goods-card__media { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--fml-surface-2); border-bottom: 1px solid var(--fml-border); }
.fml-goods-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.fml-goods-card:hover .fml-goods-card__media img { transform: scale(1.04); }
.fml-goods-card__media .fml-status { position: absolute; top: 12px; left: 12px; background: var(--fml-surface-solid); }
.fml-goods-card__body { display: flex; flex-direction: column; gap: 8px; padding: 18px; flex: 1; }
.fml-goods-card__cate { font-size: 11px; font-weight: 600; letter-spacing: .08em; color: var(--fml-accent); text-transform: uppercase; }
.fml-goods-card__title { font-size: 17px; font-weight: 650; }
.fml-goods-card__title a:hover { color: var(--fml-accent); }
.fml-goods-card__excerpt { font-size: 13px; color: var(--fml-text-3); line-height: 1.65; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fml-goods-card__foot { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 12px; }
.fml-goods-card__price { font-size: 22px; font-weight: 700; letter-spacing: -.03em; color: var(--fml-accent); }
.fml-goods-card__sales { font-size: 12px; color: var(--fml-text-3); }
.fml-goods-card .fml-btn { margin-top: 10px; }

.fml-doc-card { position: relative; padding: 22px; transition: transform .22s ease, border-color .22s ease; }
.fml-doc-card:hover { transform: translateY(-3px); border-color: var(--fml-border-strong); }
.fml-doc-card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; font-size: 12px; color: var(--fml-text-3); }
.fml-doc-card__cat { color: var(--fml-accent); font-weight: 600; }
.fml-doc-card h2, .fml-doc-card h3 { font-size: 17px; margin-bottom: 10px; }
.fml-doc-card h2 a:hover, .fml-doc-card h3 a:hover { color: var(--fml-accent); }
.fml-doc-card p { font-size: 13px; color: var(--fml-text-3); line-height: 1.7; margin-bottom: 18px; }
.fml-doc-card__more { font-size: 13px; font-weight: 600; color: var(--fml-accent); }

.fml-cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 36px 40px; }
.fml-cta h2 { font-size: 24px; }
.fml-cta p { margin-top: 8px; color: var(--fml-text-3); }

/* ==========================================================================
   6. 页面头 / 商品筛选
   ========================================================================== */

.fml-page-head { padding: 56px 0 8px; }
.fml-page-title { margin: 12px 0 10px; font-size: clamp(28px, 4vw, 40px); }
.fml-page-lead { color: var(--fml-text-2); font-size: 15px; max-width: 680px; }

.fml-goods-search { display: flex; align-items: center; gap: 10px; max-width: 620px; margin-top: 28px; padding: 8px 8px 8px 16px; border-radius: 12px; }
.fml-goods-search svg { width: 18px; height: 18px; flex: 0 0 auto; fill: none; stroke: var(--fml-text-3); stroke-width: 1.8; stroke-linecap: round; }
.fml-goods-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 14px; }
.fml-goods-search input::placeholder { color: var(--fml-text-3); }
.fml-goods-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; font-size: 13px; color: var(--fml-text-3); }
.fml-goods-toolbar__count { color: var(--fml-text-2); font-weight: 600; }
.fml-goods-paging { margin-top: 28px; }
.fml-load-more { display: flex; margin: 20px auto 0; }

.fml-pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; }
.fml-page-btn { display: grid; place-items: center; min-width: 38px; height: 38px; padding: 0 10px; border-radius: 9px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); color: var(--fml-text-2); font-size: 13px; font-weight: 600; transition: all .18s ease; }
.fml-page-btn:hover { border-color: var(--fml-accent); color: var(--fml-accent); }
.fml-page-btn.is-current { background: rgba(var(--fml-accent-rgb), .18); border-color: rgba(var(--fml-accent-rgb), .5); color: var(--fml-accent); }
.fml-page-btn.is-disabled { opacity: .35; pointer-events: none; }
.fml-pagination--core { margin-top: 32px; }
.fml-pagination--core .nav-links { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.fml-pagination--core .page-numbers { display: grid; place-items: center; min-width: 38px; height: 38px; padding: 0 10px; border-radius: 9px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); font-size: 13px; color: var(--fml-text-2); }
.fml-pagination--core .page-numbers.current { background: rgba(var(--fml-accent-rgb), .18); border-color: rgba(var(--fml-accent-rgb), .5); color: var(--fml-accent); }
.fml-pagination.is-loading { opacity: .55; pointer-events: none; }

/* ==========================================================================
   7. 文档阅读页 / 代码块高亮
   ========================================================================== */

.fml-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 28px 0 8px; font-size: 13px; color: var(--fml-text-3); }
.fml-breadcrumb a:hover { color: var(--fml-accent); }
.fml-article-page .fml-breadcrumb { padding-top: 36px; }
.fml-article-head { padding-bottom: 28px; }
.fml-article-title { font-size: clamp(28px, 4vw, 40px); line-height: 1.25; }
.fml-article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; font-size: 13px; color: var(--fml-text-3); }
.fml-article-meta__dot { opacity: .5; }

.fml-article { padding: 40px 44px; font-size: 15.5px; line-height: 1.9; color: var(--fml-text-2); }
.fml-article--flat { padding: 0; background: transparent; border: 0; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.fml-article > *:first-child { margin-top: 0; }
.fml-article h1, .fml-article h2, .fml-article h3, .fml-article h4 { margin: 2em 0 .8em; color: var(--fml-text); scroll-margin-top: 100px; }
.fml-article h1 { font-size: 30px; } .fml-article h2 { font-size: 24px; } .fml-article h3 { font-size: 19px; } .fml-article h4 { font-size: 16px; }
.fml-article p, .fml-article ul, .fml-article ol, .fml-article blockquote, .fml-article table { margin: 0 0 1.4em; }
.fml-article a { color: var(--fml-accent); text-decoration: underline; text-underline-offset: 3px; }
.fml-article ul, .fml-article ol { padding-left: 1.5em; }
.fml-article li { margin-bottom: .5em; }
.fml-article blockquote { padding: 14px 20px; border-left: 3px solid var(--fml-accent); border-radius: 0 10px 10px 0; background: var(--fml-surface-2); color: var(--fml-text-2); }
.fml-article blockquote p:last-child { margin-bottom: 0; }
.fml-article img { border-radius: 12px; border: 1px solid var(--fml-border); }
.fml-article table { width: 100%; border-collapse: collapse; font-size: 14px; }
.fml-article th, .fml-article td { padding: 10px 14px; border: 1px solid var(--fml-border); }
.fml-article th { background: var(--fml-surface-2); color: var(--fml-text); }
.fml-article hr { height: 1px; border: 0; background: var(--fml-border); margin: 2.5em 0; }
.fml-article code:not(pre code) { padding: 2px 6px; border-radius: 5px; background: var(--fml-code-bg); border: 1px solid var(--fml-border); font-size: .88em; color: var(--fml-accent); }

.fml-code-wrap { position: relative; margin: 0 0 1.6em; border: 1px solid var(--fml-border); border-radius: 12px; background: var(--fml-code-bg); overflow: hidden; }
.fml-code-wrap__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 14px; border-bottom: 1px solid var(--fml-border); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--fml-text-3); }
.fml-code-copy { padding: 3px 10px; border-radius: 6px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); font-size: 11px; letter-spacing: 0; text-transform: none; color: var(--fml-text-2); }
.fml-code-copy:hover { color: var(--fml-accent); border-color: var(--fml-accent); }
.fml-article pre { margin: 0; padding: 18px 20px; overflow-x: auto; background: transparent; font-size: 13.5px; line-height: 1.8; tab-size: 4; }
.fml-article pre code { display: block; font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace; color: var(--fml-text-2); white-space: pre; }
.tok-comment { color: var(--fml-tok-comment); font-style: italic; }
.tok-string  { color: var(--fml-tok-string); }
.tok-number  { color: var(--fml-tok-number); }
.tok-keyword { color: var(--fml-tok-keyword); font-weight: 600; }
.tok-func    { color: var(--fml-tok-func); }
.tok-tag     { color: var(--fml-tok-keyword); }
.tok-attr    { color: var(--fml-tok-func); }
.tok-punct   { color: var(--fml-text-3); }
.tok-var     { color: var(--fml-tok-number); }

.fml-article-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0; }
.fml-article-tags a { padding: 5px 12px; border-radius: 8px; border: 1px solid var(--fml-border); background: var(--fml-surface-2); font-size: 12px; color: var(--fml-text-2); }
.fml-article-tags a:hover { color: var(--fml-accent); border-color: var(--fml-accent); }
.fml-article-nav { display: flex; justify-content: space-between; gap: 20px; padding: 18px 24px; font-size: 13px; }
.fml-article-nav a { color: var(--fml-accent); }
.fml-article-nav__right { text-align: right; }
.fml-page-links { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--fml-border); }

/* ==========================================================================
   8. 商品详情页
   ========================================================================== */

.fml-goods-hero { display: grid; grid-template-columns: .9fr 1.1fr; gap: 0; overflow: hidden; margin: 12px 0 32px; }
.fml-goods-hero__media { min-height: 380px; background: var(--fml-surface-2); }
.fml-goods-hero__media img { width: 100%; height: 100%; object-fit: cover; }
.fml-goods-hero__info { padding: 40px 44px; display: flex; flex-direction: column; align-items: flex-start; }
.fml-goods-hero__badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.fml-goods-hero__title { font-size: clamp(26px, 3.4vw, 36px); }
.fml-goods-hero__excerpt { margin-top: 14px; color: var(--fml-text-3); font-size: 14px; line-height: 1.8; }
.fml-goods-hero__price { display: flex; align-items: baseline; gap: 10px; margin: 28px 0 6px; padding: 18px 0; border-block: 1px solid var(--fml-border); width: 100%; }
.fml-goods-hero__price-label { font-size: 13px; color: var(--fml-text-3); }
.fml-goods-hero__price strong { font-size: 34px; font-weight: 700; letter-spacing: -.04em; color: var(--fml-accent); }
.fml-goods-hero__price-unit { font-size: 12px; color: var(--fml-text-3); }
.fml-goods-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.fml-goods-hero__stock { margin-top: 18px; font-size: 13px; color: var(--fml-text-2); }
.fml-goods-hero__note { margin-top: 8px; font-size: 12px; color: var(--fml-text-3); }

.fml-goods-body { display: grid; grid-template-columns: 1fr 320px; align-items: start; gap: 20px; }
.fml-goods-main { padding: 32px 36px; }
.fml-goods-main > h2 { font-size: 21px; margin-bottom: 20px; }
.fml-goods-aside { display: grid; gap: 20px; }
.fml-panel { padding: 24px; }
.fml-panel h3 { font-size: 16px; margin-bottom: 16px; }
.fml-rules { font-size: 13px; line-height: 2; color: var(--fml-text-2); }
.fml-steps { padding-left: 1.3em; font-size: 13px; color: var(--fml-text-2); line-height: 2; margin-bottom: 18px; }

/* ==========================================================================
   9. 用户中心 / 订单 / CDK
   ========================================================================== */

.fml-user-layout { display: grid; grid-template-columns: 260px 1fr; gap: 20px; align-items: start; }
.fml-user-side { padding: 24px; }
.fml-user-side__head { display: flex; align-items: center; gap: 14px; }
.fml-user-side__head img { border-radius: 12px; border: 1px solid var(--fml-border); }
.fml-user-side__head strong { display: block; font-size: 15px; }
.fml-user-side__head span { font-size: 12px; color: var(--fml-text-3); }
.fml-user-side__tip { margin: 20px 0 16px; padding-top: 16px; border-top: 1px solid var(--fml-border); font-size: 12px; color: var(--fml-text-3); line-height: 1.7; }
.fml-user-content { min-width: 0; }

.fml-tabs { display: flex; gap: 4px; padding: 6px; border-radius: 12px; border: 1px solid var(--fml-border); background: var(--fml-surface); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
body.fml-no-glass .fml-tabs { background: var(--fml-surface-solid); -webkit-backdrop-filter: none; backdrop-filter: none; }
.fml-tabs--auth { margin-bottom: 22px; }
.fml-tabs--user { margin-bottom: 20px; }
.fml-tab { flex: 1; padding: 10px 14px; border: 0; border-radius: 8px; background: transparent; font-size: 14px; font-weight: 600; color: var(--fml-text-3); transition: all .18s ease; }
.fml-tab:hover { color: var(--fml-text); }
.fml-tab.is-active { background: rgba(var(--fml-accent-rgb), .16); color: var(--fml-accent); }
.fml-tab-panel { min-height: 200px; }
.fml-card-list { display: grid; gap: 14px; }

.fml-info-list { margin: 0; }
.fml-info-list > div { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--fml-border); font-size: 14px; }
.fml-info-list > div:last-child { border-bottom: 0; }
.fml-info-list dt { color: var(--fml-text-3); font-size: 13px; }
.fml-info-list dd { margin: 0; font-weight: 600; text-align: right; word-break: break-all; }

.fml-order-card, .fml-cdk-card { padding: 20px 22px; }
.fml-order-card__head, .fml-cdk-card__head { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--fml-border); }
.fml-order-card__label { display: block; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--fml-text-3); }
.fml-order-card__no { font-family: "SFMono-Regular", Consolas, monospace; font-size: 14px; }
.fml-order-card__body { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; padding-top: 16px; }
.fml-order-card__body > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.fml-order-card__body span { font-size: 12px; color: var(--fml-text-3); }
.fml-order-card__body strong { font-size: 14px; font-weight: 600; word-break: break-word; }
.fml-order-card__amount { color: var(--fml-accent); font-size: 17px !important; }

.fml-cdk-card__key { display: flex; align-items: center; gap: 12px; margin: 16px 0; padding: 12px 14px; border: 1px dashed var(--fml-border-strong); border-radius: 10px; background: var(--fml-code-bg); }
.fml-cdk-card__key code { flex: 1; min-width: 0; font-family: "SFMono-Regular", Consolas, monospace; font-size: 14px; letter-spacing: .04em; color: var(--fml-text); word-break: break-all; }
.fml-cdk-card__meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 0; }
.fml-cdk-card__meta dt { font-size: 12px; color: var(--fml-text-3); }
.fml-cdk-card__meta dd { margin: 3px 0 0; font-size: 14px; font-weight: 600; word-break: break-all; }

.fml-locked { max-width: 520px; margin: 0 auto; padding: 48px 36px; text-align: center; }
.fml-locked__icon { display: grid; place-items: center; width: 60px; height: 60px; margin: 0 auto 20px; border-radius: 18px; background: rgba(var(--fml-accent-rgb), .12); border: 1px solid rgba(var(--fml-accent-rgb), .28); }
.fml-locked__icon svg { width: 28px; height: 28px; fill: none; stroke: var(--fml-accent); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.fml-locked h2 { font-size: 22px; }
.fml-locked p { margin: 12px 0 24px; color: var(--fml-text-3); font-size: 14px; }

/* ==========================================================================
   10. 弹窗 / 表单 / Toast
   ========================================================================== */

.fml-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 20px; }
.fml-modal__backdrop { position: absolute; inset: 0; background: var(--fml-backdrop); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.fml-modal__panel { position: relative; z-index: 1; width: min(440px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; padding: 32px; background: var(--fml-modal-bg); animation: fml-modal-in .2s ease both; }
@keyframes fml-modal-in { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.fml-modal__close { position: absolute; top: 14px; right: 16px; width: 32px; height: 32px; border: 1px solid var(--fml-border); border-radius: 8px; background: var(--fml-surface-2); font-size: 22px; line-height: 1; color: var(--fml-text-3); }
.fml-modal__close:hover { color: var(--fml-accent); border-color: var(--fml-accent); }
.fml-modal__title { font-size: 22px; }
.fml-modal__subtitle { margin-top: 8px; font-size: 13px; color: var(--fml-text-3); }
.fml-modal__hint { margin-top: 14px; font-size: 12px; line-height: 1.6; color: var(--fml-text-3); text-align: center; }
body.fml-modal-open { overflow: hidden; }

.fml-form { display: grid; gap: 14px; }
.fml-field { display: grid; gap: 7px; }
.fml-field > span { font-size: 13px; font-weight: 600; color: var(--fml-text-2); }
.fml-field input, .fml-field textarea { width: 100%; padding: 11px 14px; border: 1px solid var(--fml-border); border-radius: 10px; background: var(--fml-input-bg); color: var(--fml-text); font-size: 14px; outline: 0; resize: vertical; transition: border-color .18s ease, box-shadow .18s ease; }
.fml-field input:focus, .fml-field textarea:focus { border-color: var(--fml-accent); box-shadow: 0 0 0 3px rgba(var(--fml-accent-rgb), .14); }
.fml-field input::placeholder, .fml-field textarea::placeholder { color: var(--fml-text-3); }
.fml-field-row[hidden] { display: none; }
.fml-form__error { padding: 10px 12px; border-radius: 9px; border: 1px solid var(--fml-warn-border); background: var(--fml-warn-bg); color: var(--fml-warn); font-size: 13px; }
.fml-order-summary { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border: 1px solid var(--fml-border); border-radius: 10px; background: var(--fml-surface-2); font-size: 13px; color: var(--fml-text-2); }
.fml-order-summary strong { font-size: 20px; color: var(--fml-accent); }
.fml-form .fml-btn--block { margin-top: 4px; }

.fml-toast-stack { position: fixed; top: 86px; right: 20px; z-index: 300; display: grid; gap: 10px; width: min(320px, calc(100vw - 40px)); pointer-events: none; }
.fml-toast { display: flex; align-items: flex-start; gap: 10px; padding: 13px 16px; border-radius: 11px; border: 1px solid var(--fml-border-strong); background: var(--fml-modal-bg); box-shadow: var(--fml-shadow); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); font-size: 13px; line-height: 1.6; animation: fml-toast-in .22s ease both; }
.fml-toast::before { content: ""; flex: 0 0 auto; width: 7px; height: 7px; margin-top: 7px; border-radius: 50%; background: var(--fml-accent); }
.fml-toast--success::before { background: var(--fml-ok); }
.fml-toast--error::before { background: var(--fml-warn); }
.fml-toast.is-out { animation: fml-toast-out .2s ease both; }
@keyframes fml-toast-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
@keyframes fml-toast-out { to { opacity: 0; transform: translateX(16px); } }

/* ==========================================================================
   11. 页脚
   ========================================================================== */

.fml-footer { margin-top: 72px; border-radius: 0; border-width: 1px 0 0; box-shadow: none; }
.fml-footer__inner { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; padding: 44px 0 36px; }
.fml-footer__brand p { margin-top: 12px; max-width: 320px; font-size: 13px; color: var(--fml-text-3); line-height: 1.8; }
.fml-footer__links { list-style: none; display: grid; gap: 10px; font-size: 13px; color: var(--fml-text-2); }
.fml-footer__links a:hover { color: var(--fml-accent); }
.fml-footer__meta { font-size: 12px; color: var(--fml-text-3); line-height: 1.9; }
.fml-footer__meta a:hover { color: var(--fml-accent); }
.fml-footer__sep { margin: 0 6px; opacity: .5; }
.fml-footer__powered { margin-top: 10px; opacity: .7; }

/* ==========================================================================
   12. 响应式
   ========================================================================== */

@media (max-width: 1080px) {
	.fml-search__input { width: 110px; }
	.fml-hero__inner { padding: 48px 36px; gap: 28px; }
	.fml-goods-body { grid-template-columns: 1fr 280px; }
	.fml-goods-hero__info { padding: 32px; }
}

@media (max-width: 900px) {
	.fml-container, .fml-container--narrow, .fml-hero { width: calc(100% - 32px); }
	.fml-section { padding: 52px 0; }
	.fml-hero__inner { grid-template-columns: 1fr; padding: 40px 28px; }
	.fml-hero__visual { display: none; }
	.fml-hero__facts { gap: 18px; }
	.fml-goods-hero { grid-template-columns: 1fr; }
	.fml-goods-hero__media { min-height: 240px; max-height: 320px; }
	.fml-goods-body { grid-template-columns: 1fr; }
	.fml-user-layout { grid-template-columns: 1fr; }
	.fml-user-side__head { justify-content: flex-start; }
	.fml-footer__inner { grid-template-columns: 1fr 1fr; gap: 28px; }
	.fml-search { display: none; }
}

@media (max-width: 720px) {
	.fml-header__inner { flex-wrap: wrap; gap: 10px; min-height: 62px; padding-block: 10px; }
	.fml-brand { margin-right: auto; }
	.fml-menu-toggle { display: inline-grid; }
	.fml-nav { order: 3; flex: 1 0 100%; display: none; }
	.fml-nav.is-open { display: block; }
	.fml-nav__list { flex-direction: column; align-items: stretch; gap: 2px; padding: 8px 0; }
	.fml-nav__list a { padding: 10px 12px; }
	.fml-nav__list .sub-menu, .fml-nav__list .children { position: static; display: block; box-shadow: none; border: 0; background: transparent; padding: 0 0 0 14px; }
	.fml-header__actions { gap: 8px; }
	.fml-user-chip span { display: none; }
	.fml-section__head { flex-direction: column; align-items: flex-start; gap: 12px; }
	.fml-article { padding: 26px 22px; }
	.fml-article pre { padding: 14px 16px; }
	.fml-cta { flex-direction: column; align-items: flex-start; padding: 28px; }
	.fml-goods-hero__info { padding: 26px 22px; }
	.fml-goods-main { padding: 26px 22px; }
	.fml-order-card__body { grid-template-columns: 1fr 1fr; }
	.fml-footer__inner { grid-template-columns: 1fr; gap: 22px; padding: 32px 0; }
	.fml-modal__panel { padding: 26px 20px; }
	.fml-toast-stack { top: 76px; right: 12px; }
}

@media (max-width: 460px) {
	.fml-container, .fml-container--narrow, .fml-hero { width: calc(100% - 24px); }
	.fml-hero__inner { padding: 32px 20px; }
	.fml-hero__facts { flex-direction: column; gap: 12px; }
	.fml-grid--goods, .fml-grid--docs { grid-template-columns: 1fr; }
	.fml-brand__name { font-size: 15px; }
	.fml-order-card__body, .fml-cdk-card__meta { grid-template-columns: 1fr; }
	.fml-tabs--user { flex-direction: column; }
	.fml-cdk-card__key { flex-direction: column; align-items: stretch; }
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

@media print {
	.fml-header, .fml-footer, .fml-ambient, .fml-toast-stack, .fml-modal { display: none !important; }
	.fml-glass { background: #fff; border: 1px solid #ddd; box-shadow: none; backdrop-filter: none; }
	body.fml-site { background: #fff; color: #111; }
}
