/* ==========================================================================
   霓虹矩阵 · 明亮模式补丁
   自动令牌已处理大部分写死颜色，这里处理城市背景、英雄区、原生控件与弹层等
   需要按主题改变结构的细节，并统一减弱霓虹发光。
   ========================================================================== */

/* ---------- 全站背景与网格：亮色城市天际 ---------- */
[data-theme="light"] body {
	background-color: var(--nm-bg);
	background-image:
		radial-gradient(1100px 560px at 8% -8%, rgba(8, 126, 175, 0.08), transparent 60%),
		radial-gradient(900px 500px at 96% 0%, rgba(124, 58, 237, 0.07), transparent 62%),
		radial-gradient(760px 420px at 50% 110%, rgba(214, 31, 134, 0.05), transparent 70%);
}

[data-theme="light"] body::before {
	background-image:
		linear-gradient(rgba(23, 32, 51, 0.05) 1px, transparent 1px),
		linear-gradient(90deg, rgba(23, 32, 51, 0.05) 1px, transparent 1px);
}

[data-theme="light"] body::after {
	background:
		radial-gradient(60% 100% at 50% 100%, rgba(124, 58, 237, 0.08), transparent 70%),
		radial-gradient(40% 100% at 20% 100%, rgba(8, 126, 175, 0.07), transparent 70%),
		radial-gradient(40% 100% at 80% 100%, rgba(214, 31, 134, 0.05), transparent 70%);
}

[data-theme="light"] ::selection {
	background: rgba(8, 126, 175, 0.18);
	color: #172033;
}

[data-theme="light"] a:hover {
	color: #065f85;
}

/* ---------- 顶部导航 ---------- */
[data-theme="light"] .nm-header {
	box-shadow: 0 6px 20px rgba(23, 32, 51, 0.06);
}

[data-theme="light"] .nm-theme-toggle:hover {
	background: rgba(8, 126, 175, 0.1);
}

/* 品牌字标：白字渐变在白底下不可见，改为深色渐变 */
[data-theme="light"] .nm-brand__name {
	background: linear-gradient(100deg, #172033, #087eaf);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

/* ---------- 英雄区：白底深色文字，保留品牌渐变标题 ---------- */
[data-theme="light"] .nm-hero__title,
[data-theme="light"] .nm-hot__title,
[data-theme="light"] .nm-front-head__title,
[data-theme="light"] .nm-quickcat__name,
[data-theme="light"] .nm-tcard__title,
[data-theme="light"] .nm-gcard__game,
[data-theme="light"] .nm-focus-card__title {
	color: #172033;
	text-shadow: none;
}

[data-theme="light"] .nm-front-head__more:hover {
	color: var(--nm-cyan);
}

[data-theme="light"] .nm-hero__main {
	border-color: rgba(8, 126, 175, 0.18);
}

/* 首页首屏：亮色下弱化暗色城市插画，保留未来城市轮廓但不压暗文字 */
[data-theme="light"] .nm-front .nm-hero {
	border-color: #dce3ef;
	box-shadow: 0 16px 40px rgba(23, 32, 51, 0.08);
}

[data-theme="light"] .nm-front .nm-hero__art {
	filter: saturate(0.8) brightness(1.06);
	opacity: 0.12;
}

[data-theme="light"] .nm-front .nm-hero__city {
	opacity: 0.5;
}

[data-theme="light"] .nm-front .nm-hero__bg::after {
	background:
		linear-gradient(0deg, rgba(248, 250, 254, 0.92) 0%, rgba(248, 250, 254, 0) 58%),
		linear-gradient(90deg, rgba(248, 250, 254, 0.98) 0%, rgba(248, 250, 254, 0.95) 26%, rgba(248, 250, 254, 0.8) 56%, rgba(248, 250, 254, 0.93) 100%),
		linear-gradient(180deg, rgba(248, 250, 254, 0.6) 30%, rgba(246, 248, 252, 0.94) 100%);
}

[data-theme="light"] .nm-hero__subtitle {
	text-shadow: none;
}

/* ---------- 减弱霓虹发光 ---------- */
[data-theme="light"] .nm-brand__mark svg,
[data-theme="light"] .nm-brand__mark {
	filter: none;
}

/* ---------- 表单与原生控件 ---------- */
[data-theme="light"] input::placeholder,
[data-theme="light"] textarea::placeholder {
	color: #7a8698;
	opacity: 1;
}

[data-theme="light"] select option {
	background: #ffffff;
	color: #172033;
}

/* ---------- 表格、代码块 ---------- */
[data-theme="light"] .nm-prose table th {
	background: #eef2f9;
}

/* ---------- 浅色品牌文字：白底下统一加深，保证 AA 对比度 ---------- */
[data-theme="light"] code,
[data-theme="light"] .nm-search-item mark,
[data-theme="light"] .nm-game-btn--cyan,
[data-theme="light"] .nm-game-card__media-tags i,
[data-theme="light"] .nm-game-card__tags span,
[data-theme="light"] .nm-online-btn--cyan,
[data-theme="light"] .nm-online-hero__features li,
[data-theme="light"] .nm-online-card h3 a:hover,
[data-theme="light"] .nm-btn--cyber,
[data-theme="light"] .nm-trade-hero__security h2 svg {
	color: #046a87;
}

[data-theme="light"] .nm-badge--pink,
[data-theme="light"] .nm-fav.is-active,
[data-theme="light"] .nm-game-card__stats b,
[data-theme="light"] .nm-pcard__price,
[data-theme="light"] .nm-pcard__buy,
[data-theme="light"] .nm-trade-resultbar strong,
[data-theme="light"] .nm-trade .nm-product-card__price,
[data-theme="light"] .nm-trade ul.products li.product .price {
	color: #b0176f;
}

[data-theme="light"] .nm-tag,
[data-theme="light"] .nm-ai-summary__label,
[data-theme="light"] .nm-article__meta-actions .nm-btn:hover,
[data-theme="light"] .nm-article__meta-actions .nm-fav.is-active,
[data-theme="light"] .nm-article-widget__head > a:hover,
[data-theme="light"] .nm-article-related__body h3 a:hover,
[data-theme="light"] .nm-article-focus h2 > svg,
[data-theme="light"] .nm-article-focus li svg,
[data-theme="light"] .nm-article-hot li > a:hover,
[data-theme="light"] .nm-tools-sectionhead > a:hover,
[data-theme="light"] .nm-tools-category header > span,
[data-theme="light"] .nm-topics-hero__values h2 svg,
[data-theme="light"] .nm-topics-hot-card h3 a:hover,
[data-theme="light"] .nm-trade-panel h2 svg,
[data-theme="light"] .nm-trade-assurance > h2 svg,
[data-theme="light"] .nm-trade-navigation nav a.is-active svg,
[data-theme="light"] .nm-trade-navigation nav a:hover svg,
[data-theme="light"] .nm-product-related-card__body > strong,
[data-theme="light"] .nm-product-related-card__body > strong .price {
	color: #6d28d9;
}

[data-theme="light"] .nm-trade-warning > svg {
	color: #b91c1c;
}

[data-theme="light"] .nm-article .nm-prose li::marker,
[data-theme="light"] .nm-topics-article-col li::before {
	color: #7c3aed;
}

/* 商品卡购买按钮：白底改用浅品牌底 + 深色文字 */
[data-theme="light"] .nm-pcard__buy {
	background: linear-gradient(100deg, rgba(214, 31, 134, 0.1), rgba(124, 58, 237, 0.1));
	border-color: rgba(214, 31, 134, 0.35);
	box-shadow: none;
}

/* ---------- 图片上的白色标题：明亮模式保留下方深色蒙版，避免与照片冲突 ---------- */
[data-theme="light"] .nm-game-card__media {
	background: #101a2e;
}

[data-theme="light"] .nm-game-card__media::after {
	background: linear-gradient(180deg, rgba(10, 16, 30, 0.06) 30%, rgba(7, 11, 24, 0.82) 100%);
}

[data-theme="light"] .nm-game-card__game {
	color: #ffffff;
	text-shadow: 0 2px 10px rgba(0, 0, 0, 0.85);
}

/* ---------- 深色底按钮内的浅色文字必须保持浅色 ---------- */
[data-theme="light"] .nm-product-page .product-type-simple form.cart .nm-product-buy-now {
	color: #ffe3f8;
	box-shadow: none;
}

[data-theme="light"] .nm-product-page .product-type-simple form.cart .single_add_to_cart_button {
	border-color: rgba(32, 197, 229, 0.55);
	box-shadow: none;
	color: #eafcff;
}

/* ---------- 商品价格面板保留深紫底，内部文字必须为浅色 ---------- */
[data-theme="light"] .nm-product-price-panel {
	color: #f4e9ff;
}

[data-theme="light"] .nm-product-price-panel__label,
[data-theme="light"] .nm-product-price-panel__note,
[data-theme="light"] .nm-product-price-panel__price del {
	color: #dcc4f5;
}

[data-theme="light"] .nm-product-page div.product .nm-product-price-panel__price .price {
	color: #ffb5ed;
	text-shadow: none;
}

[data-theme="light"] .nm-product-price-panel__save {
	color: #ffd0f0;
}

[data-theme="light"] .nm-trade-filter__compliance {
	color: #0b6f63;
}

[data-theme="light"] .nm-stock--in,
[data-theme="light"] .nm-product-stock--in {
	color: #0d7a5b;
}

/* ---------- 深色品牌底标签：文字必须保持浅色 ---------- */
[data-theme="light"] .nm-product-card__tag--type {
	color: #ffe2ff;
}

[data-theme="light"] .nm-topics-series-card em {
	color: #f2ddf9;
}

[data-theme="light"] .nm-topics-article-col h3 small {
	color: #eccdf2;
}

[data-theme="light"] .nm-hero__title span:nth-child(2) {
	background-image: linear-gradient(92deg, #d61f86 0%, #7c3aed 52%, #046a87 100%);
	filter: none;
}

/* ---------- 专题合集首屏：深色渐变 + 城市插画改为浅色 ---------- */
[data-theme="light"] .nm-topics-hero {
	background: linear-gradient(105deg, #eef2fb, #f7f9fd 50%, #eef2fb);
	border-bottom-color: #dce3ef;
}

[data-theme="light"] .nm-topics-hero::before {
	background: linear-gradient(90deg, rgba(250, 252, 255, 0.97) 0%, rgba(250, 252, 255, 0.92) 36%, rgba(250, 252, 255, 0.55) 66%, rgba(246, 248, 252, 0.8) 100%);
}

[data-theme="light"] .nm-topics-hero__title {
	color: #172033;
	text-shadow: none;
}

[data-theme="light"] .nm-topics-hero__eyebrow {
	background: rgba(124, 58, 237, 0.1);
	border-color: rgba(124, 58, 237, 0.4);
	color: #6d28d9;
}

[data-theme="light"] .nm-topics-hero__content > p {
	color: #596579;
}

/* ---------- 品牌渐变按钮：保留青/蓝/紫渐变，文字改用深色 ---------- */
[data-theme="light"] .nm-btn--primary,
[data-theme="light"] button[type="submit"]:not(.nm-btn--ghost),
[data-theme="light"] input[type="submit"] {
	background: linear-gradient(100deg, #22d3ee, #60a5fa 55%, #a78bfa);
	box-shadow: 0 8px 18px rgba(8, 126, 175, 0.18);
	color: #05121f;
}

[data-theme="light"] .nm-btn--primary:hover,
[data-theme="light"] button[type="submit"]:not(.nm-btn--ghost):hover,
[data-theme="light"] input[type="submit"]:hover {
	box-shadow: 0 10px 22px rgba(8, 126, 175, 0.24);
	color: #05121f;
}

/* ---------- 仍为深色品牌底的组件：文字与图标保持浅色 ---------- */
[data-theme="light"] .nm-topics-enter,
[data-theme="light"] .nm-topics-plan__button,
[data-theme="light"] .nm-tools-category__button,
[data-theme="light"] .nm-tools-kit em,
[data-theme="light"] .nm-product-type-badge,
[data-theme="light"] .nm-product-section-tabs a.is-active,
[data-theme="light"] .nm-product-reviews #commentform input#submit,
[data-theme="light"] .nm-product-related-card__cart {
	color: #f8eaff;
}

[data-theme="light"] .nm-tools-latest__logo {
	color: #d7f6ff;
}

[data-theme="light"] .nm-product-gallery__badges span {
	background: rgba(61, 30, 84, 0.88);
	border-color: rgba(180, 120, 220, 0.45);
	color: #f6e6ff;
}

/* 青色/粉色渐变按钮在浅色底上改为实色品牌渐变，避免渐变被令牌提亮 */
[data-theme="light"] .nm-tools-btn--pink {
	background: linear-gradient(110deg, #db2777, #7c3aed);
	border-color: rgba(219, 39, 119, 0.5);
	color: #ffffff;
}

[data-theme="light"] .nm-tools-btn--cyan {
	background: linear-gradient(110deg, rgba(8, 126, 175, 0.14), rgba(8, 126, 175, 0.06));
	border-color: rgba(8, 126, 175, 0.45);
	color: #046a87;
}

[data-theme="light"] .nm-topics-hero__actions a:last-child {
	background: linear-gradient(110deg, #0e7490, #155e75);
	border-color: rgba(14, 116, 144, 0.5);
	color: #ecfeff;
}


/* ---------- 主题切换过渡（仅切换瞬间生效，避免首屏动画） ---------- */
html.nm-theme-anim body,
html.nm-theme-anim .nm-header,
html.nm-theme-anim .nm-footer,
html.nm-theme-anim .nm-card,
html.nm-theme-anim .nm-panel,
html.nm-theme-anim .nm-btn,
html.nm-theme-anim input,
html.nm-theme-anim textarea,
html.nm-theme-anim select,
html.nm-theme-anim .nm-theme-toggle {
	transition: background-color 0.28s var(--nm-ease), border-color 0.28s var(--nm-ease), color 0.28s var(--nm-ease), box-shadow 0.28s var(--nm-ease);
}
