/*
Theme Name: NBBLISS
Theme URI: https://www.nbbliss.com
Description: NBBLISS 家具外贸独立站子主题（基于 Twenty Twenty-Five）。支持英/西/阿三语与阿拉伯语 RTL。
Author: NBBLISS
Version: 1.0.0
Template: twentytwentyfive
Text Domain: nbbliss
*/

/* ===== 变量与基础 ===== */
:root {
	--nb-bg: #f7f3ec;
	--nb-bg-alt: #ffffff;
	--nb-text: #26221d;
	--nb-muted: #6f6a63;
	--nb-accent: #8a6a45;
	--nb-accent-dark: #6f5433;
	--nb-dark: #23201c;
	--nb-dark-2: #2e2a25;
	--nb-line: #e6dfd4;
	--nb-cream: #efe9dd;
	--nb-radius: 10px;
	--nb-shadow: 0 10px 30px rgba(35, 32, 28, .08);
	--nb-font-head: Georgia, 'Times New Roman', 'Noto Kufi Arabic', 'Amiri', serif;
	--nb-font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', 'Noto Sans Arabic', Arial, sans-serif;
}

html, body { margin: 0; padding: 0; }

body.nb-theme {
	background: var(--nb-bg);
	color: var(--nb-text);
	font-family: var(--nb-font-body);
	font-size: 16px;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
}

.nb-container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.nb-main { display: block; }

h1, h2, h3, h4, .nb-logo-name, .nb-hero-title, .nb-page-title {
	font-family: var(--nb-font-head);
	line-height: 1.2;
	margin: 0 0 .5em;
}

a { color: var(--nb-accent-dark); text-decoration: none; }
a:hover { color: var(--nb-accent); }

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

/* ===== 按钮 ===== */
.nb-btn {
	display: inline-block;
	padding: 13px 30px;
	border: 1px solid transparent;
	border-radius: 40px;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: .3px;
	text-align: center;
	cursor: pointer;
	transition: all .2s ease;
	line-height: 1.4;
}
.nb-btn-lg { padding: 15px 38px; font-size: 16px; }
.nb-btn-primary { background: var(--nb-accent); color: #fff; }
.nb-btn-primary:hover { background: var(--nb-accent-dark); color: #fff; }
.nb-btn-dark { background: var(--nb-dark); color: #fff; }
.nb-btn-dark:hover { background: #000; color: #fff; }
.nb-btn-light { background: #fff; color: var(--nb-dark); }
.nb-btn-light:hover { background: var(--nb-cream); color: var(--nb-dark); }
.nb-btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.7); }
.nb-btn-outline-light:hover { background: rgba(255,255,255,.15); color: #fff; }

/* ===== 顶栏 ===== */
.nb-topbar { background: var(--nb-dark); color: #d9d2c6; font-size: 13px; }
.nb-topbar-inner {
	display: flex; align-items: center; justify-content: space-between;
	gap: 16px; min-height: 40px; padding-top: 4px; padding-bottom: 4px;
}
.nb-topbar-contact { display: flex; gap: 10px; align-items: center; }
.nb-top-sep { opacity: .4; }

.nb-lang-dd { position: relative; display: inline-block; }
.nb-lang-dd-toggle {
	display: inline-flex; align-items: center; gap: 7px;
	background: transparent; border: 1px solid rgba(255,255,255,.25); color: #d9d2c6;
	font: inherit; font-size: 13px; padding: 5px 12px; border-radius: 20px; cursor: pointer;
	transition: all .2s;
}
.nb-lang-dd-toggle:hover { color: #fff; background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.4); }
.nb-lang-dd.is-open .nb-lang-dd-toggle { color: #fff; background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.4); }
.nb-lang-flag { width: 16px; height: 11px; object-fit: cover; border-radius: 2px; flex-shrink: 0; }
.nb-lang-dd-caret {
	width: 0; height: 0; border-left: 4px solid transparent; border-right: 4px solid transparent;
	border-top: 5px solid currentColor; margin-left: 2px;
}
.nb-lang-dd-list {
	position: absolute; top: calc(100% + 6px); right: 0; z-index: 200;
	min-width: 172px; background: #fff; border: 1px solid var(--nb-line); border-radius: var(--nb-radius);
	box-shadow: var(--nb-shadow); list-style: none; margin: 0; padding: 6px 0;
	opacity: 0; visibility: hidden; transform: translateY(6px); transition: all .18s ease;
}
.nb-lang-dd.is-open .nb-lang-dd-list { opacity: 1; visibility: visible; transform: translateY(0); }
.nb-lang-dd-list li { margin: 0; }
.nb-lang-dd-list a {
	display: flex; align-items: center; gap: 9px; padding: 9px 16px;
	color: var(--nb-text); font-size: 14px; text-decoration: none;
}
.nb-lang-dd-list a:hover { background: var(--nb-cream); color: var(--nb-accent); }

/* ===== 头部与导航 ===== */
.nb-header { background: var(--nb-bg); border-bottom: 1px solid var(--nb-line); position: sticky; top: 0; z-index: 100; }
.nb-header-inner {
	display: flex; align-items: center; justify-content: space-between;
	gap: 24px; min-height: 76px;
}
.nb-logo { display: flex; align-items: center; }
.nb-logo-link { display: inline-flex; align-items: center; gap: 12px; }
.nb-logo-mark { width: 9px; height: 9px; background: var(--nb-accent); transform: rotate(45deg); flex-shrink: 0; border-radius: 1px; }
.nb-logo-text { display: flex; flex-direction: column; line-height: 1.05; }
.nb-logo-name { font-size: 25px; font-weight: 700; letter-spacing: 5px; color: var(--nb-dark); line-height: 1.1; }
.nb-logo-tag { font-size: 10px; letter-spacing: 6px; text-transform: uppercase; color: var(--nb-accent); margin-top: 3px; }
.nb-logo a { color: inherit; }
.nb-logo a:hover .nb-logo-name { color: var(--nb-accent); }
.nb-logo a:hover .nb-logo-tag { color: var(--nb-accent-dark); }

.nb-menu { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; }
.nb-menu > li { position: relative; }
.nb-menu > li > a {
	display: block; padding: 10px 16px; color: var(--nb-text);
	font-weight: 500; font-size: 15px; border-radius: 30px; transition: all .2s;
}
.nb-menu > li > a:hover { color: var(--nb-accent); background: var(--nb-cream); }

.nb-submenu {
	position: absolute; top: 100%; right: auto; left: 0;
	min-width: 220px; background: #fff; border: 1px solid var(--nb-line);
	border-radius: var(--nb-radius); box-shadow: var(--nb-shadow);
	list-style: none; margin: 6px 0 0; padding: 8px 0;
	opacity: 0; visibility: hidden; transform: translateY(8px);
	transition: all .2s ease; z-index: 120;
}
.nb-menu > li.has-sub:hover .nb-submenu,
.nb-menu > li.has-sub:focus-within .nb-submenu { opacity: 1; visibility: visible; transform: translateY(0); }
.nb-submenu li a { display: block; padding: 9px 20px; color: var(--nb-text); font-size: 14px; }
.nb-submenu li a:hover { color: var(--nb-accent); background: var(--nb-bg); }

.nb-menu-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nb-menu-toggle span { display: block; width: 24px; height: 2px; background: var(--nb-dark); margin: 5px 0; border-radius: 2px; transition: all .2s; }

/* ===== Hero ===== */
.nb-hero {
	position: relative; color: #fff;
	background-color: var(--nb-dark);
	background-size: cover; background-position: center;
	min-height: 560px; display: flex; align-items: center;
}
.nb-hero-overlay { position: absolute; inset: 0; background: linear-gradient(100deg, rgba(20,17,14,.78) 0%, rgba(20,17,14,.45) 45%, rgba(20,17,14,.15) 100%); }
.nb-hero-content { position: relative; z-index: 2; max-width: 680px; padding-top: 60px; padding-bottom: 60px; }
.nb-hero-kicker {
	display: inline-block; font-size: 13px; letter-spacing: 3px; text-transform: uppercase;
	color: #d9c7a5; border: 1px solid rgba(217,199,165,.5); border-radius: 30px; padding: 6px 16px; margin-bottom: 22px;
}
.nb-hero-title { font-size: 54px; margin-bottom: 18px; color: #fff; }
.nb-hero-sub { font-size: 18px; color: rgba(255,255,255,.88); margin: 0 0 32px; }
.nb-hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ===== 区块 ===== */
.nb-section { padding: 88px 0; }
.nb-section-head { text-align: center; max-width: 640px; margin: 0 auto 48px; }
.nb-kicker {
	font-size: 13px; letter-spacing: 3px; text-transform: uppercase; color: var(--nb-accent);
	margin: 0 0 10px; font-weight: 600;
}
.nb-section-title { font-size: 40px; margin-bottom: 12px; }
.nb-section-sub { color: var(--nb-muted); margin: 0; }
.nb-section-actions { text-align: center; margin-top: 48px; }

/* ===== 分类卡片 ===== */
.nb-cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.nb-cat-card {
	background: var(--nb-bg-alt); border-radius: var(--nb-radius); overflow: hidden;
	box-shadow: 0 4px 18px rgba(35,32,28,.06); display: flex; flex-direction: column;
	transition: transform .25s ease, box-shadow .25s ease; color: var(--nb-text);
}
.nb-cat-card:hover { transform: translateY(-6px); box-shadow: var(--nb-shadow); color: var(--nb-text); }
.nb-cat-card-media { aspect-ratio: 4 / 3; overflow: hidden; }
.nb-cat-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.nb-cat-card:hover .nb-cat-card-media img { transform: scale(1.05); }
.nb-cat-card-placeholder { width: 100%; height: 100%; background: linear-gradient(135deg, var(--nb-cream), var(--nb-bg)); }
.nb-cat-card-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.nb-cat-card-title { font-size: 24px; margin: 0 0 10px; }
.nb-cat-card-subs { list-style: none; margin: 0 0 16px; padding: 0; }
.nb-cat-card-subs li { color: var(--nb-muted); font-size: 14px; padding: 3px 0; position: relative; padding-inline-start: 16px; }
.nb-cat-card-subs li::before { content: "·"; position: absolute; inset-inline-start: 4px; color: var(--nb-accent); font-weight: 700; }
.nb-cat-card-cta { margin-top: auto; color: var(--nb-accent); font-weight: 600; font-size: 14px; }

/* ===== 产品网格 ===== */
.nb-product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.nb-product-card {
	background: var(--nb-bg-alt); border-radius: var(--nb-radius); overflow: hidden;
	box-shadow: 0 4px 18px rgba(35,32,28,.05); transition: transform .25s ease, box-shadow .25s ease; color: var(--nb-text);
}
.nb-product-card:hover { transform: translateY(-6px); box-shadow: var(--nb-shadow); color: var(--nb-text); }
.nb-product-media { aspect-ratio: 1 / 1; overflow: hidden; background: var(--nb-bg); }
.nb-product-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.nb-product-card:hover .nb-product-media img { transform: scale(1.05); }
.nb-product-info { padding: 16px 18px 18px; }
.nb-product-title { font-size: 17px; margin: 0 0 6px; }
.nb-product-more { font-size: 13px; color: var(--nb-accent); font-weight: 600; }
.nb-product-placeholder { width: 100%; height: 100%; background: linear-gradient(135deg, var(--nb-cream), var(--nb-bg)); }

/* ===== 关于区块 ===== */
.nb-about { background: var(--nb-bg-alt); }
.nb-about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.nb-about-media { border-radius: var(--nb-radius); overflow: hidden; box-shadow: var(--nb-shadow); }
.nb-about-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nb-about-placeholder { aspect-ratio: 4 / 3; background: linear-gradient(135deg, var(--nb-cream), var(--nb-bg)); }
.nb-about-p { color: var(--nb-muted); margin: 0 0 24px; }
.nb-about-points { list-style: none; margin: 0 0 28px; padding: 0; }
.nb-about-points li { padding: 7px 0; padding-inline-start: 28px; position: relative; }
.nb-about-points li::before {
	content: "✓"; position: absolute; inset-inline-start: 0; top: 7px;
	color: var(--nb-accent); font-weight: 700;
}

/* ===== CTA ===== */
.nb-cta { background: var(--nb-dark); color: #fff; padding: 84px 0; text-align: center; }
.nb-cta-inner { max-width: 680px; }
.nb-cta-title { font-size: 38px; color: #fff; margin-bottom: 12px; }
.nb-cta-sub { color: rgba(255,255,255,.8); margin: 0 0 30px; }

/* ===== 页头/面包屑 ===== */
.nb-page-head { background: var(--nb-cream); border-bottom: 1px solid var(--nb-line); padding: 40px 0 36px; }
.nb-page-title { font-size: 40px; margin: 8px 0 0; }
.nb-page-desc { color: var(--nb-muted); margin: 10px 0 0; max-width: 720px; }
.nb-breadcrumb { font-size: 13px; color: var(--nb-muted); }
.nb-breadcrumb a { color: var(--nb-muted); }
.nb-breadcrumb a:hover { color: var(--nb-accent); }
.nb-breadcrumb .sep { margin: 0 6px; color: #b6ad9d; }

/* ===== 子分类胶囊 ===== */
.nb-subcat-pills { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 36px; }
.nb-pill {
	border: 1px solid var(--nb-line); background: #fff; color: var(--nb-text);
	border-radius: 30px; padding: 8px 20px; font-size: 14px; transition: all .2s;
}
.nb-pill:hover { border-color: var(--nb-accent); color: var(--nb-accent); }
.nb-pill.is-active { background: var(--nb-accent); border-color: var(--nb-accent); color: #fff; }
.nb-pill.is-active:hover { color: #fff; }

/* ===== 分页 ===== */
.nb-pagination { margin-top: 48px; text-align: center; }
.nb-pagination .page-numbers {
	display: inline-block; min-width: 42px; padding: 9px 12px; margin: 0 3px;
	border: 1px solid var(--nb-line); border-radius: 8px; background: #fff; color: var(--nb-text);
}
.nb-pagination .page-numbers.current { background: var(--nb-accent); color: #fff; border-color: var(--nb-accent); }
.nb-pagination .page-numbers:hover { border-color: var(--nb-accent); }

/* ===== 产品详情 ===== */
.nb-product-detail { display: grid; grid-template-columns: 1.1fr 1fr; gap: 52px; align-items: start; }
.nb-detail-media { position: sticky; top: 100px; }
.nb-detail-main { border-radius: var(--nb-radius); overflow: hidden; background: var(--nb-bg-alt); box-shadow: var(--nb-shadow); }
.nb-detail-main img { width: 100%; display: block; }
.nb-detail-thumbs { display: flex; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.nb-thumb {
	width: 84px; height: 84px; padding: 0; border: 2px solid var(--nb-line); border-radius: 8px;
	overflow: hidden; cursor: pointer; background: #fff; transition: all .2s;
}
.nb-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nb-thumb.is-active, .nb-thumb:hover { border-color: var(--nb-accent); }
.nb-detail-cat { color: var(--nb-accent); font-size: 13px; letter-spacing: 1px; text-transform: uppercase; font-weight: 600; }
.nb-detail-title { font-size: 38px; margin: 8px 0 18px; }
.nb-detail-info .wp-post-excerpt, .nb-detail-info .wp-block-post-excerpt__excerpt { color: var(--nb-muted); }
.nb-detail-specs-title { font-size: 18px; margin: 28px 0 12px; }
.nb-specs { list-style: none; margin: 0 0 8px; padding: 0; }
.nb-specs li {
	padding: 8px 14px; background: #fff; border: 1px solid var(--nb-line);
	border-radius: 8px; margin-bottom: 8px; font-size: 14px;
}
.nb-detail-actions { margin-top: 28px; }
.nb-detail-placeholder { aspect-ratio: 4 / 3; border-radius: var(--nb-radius); }
.nb-detail-desc { max-width: 820px; margin-top: 72px; }
.nb-prose { color: var(--nb-text); }
.nb-prose img { border-radius: var(--nb-radius); }

.nb-related { margin-top: 72px; }
.nb-related-title { font-size: 26px; margin-bottom: 24px; }

/* ===== 空状态/文章 ===== */
.nb-empty { color: var(--nb-muted); text-align: center; padding: 40px 0; }
.nb-article { padding: 24px 0; border-bottom: 1px solid var(--nb-line); }
.nb-article-title { font-size: 24px; }
.nb-article-title a { color: var(--nb-text); }
.nb-article-meta { font-size: 13px; color: var(--nb-muted); margin: 6px 0 12px; }
.nb-article-excerpt { color: var(--nb-muted); }
.nb-single .nb-article-title { font-size: 40px; }

/* ===== 联系表单 ===== */
.nb-contact-form { max-width: 760px; }
.nb-contact-form .nb-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.nb-form-field { margin-bottom: 18px; }
.nb-form-field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 7px; }
.nb-form-field input[type="text"], .nb-form-field input[type="email"],
.nb-form-field input[type="tel"], .nb-form-field textarea {
	width: 100%; padding: 12px 14px; border: 1px solid var(--nb-line); border-radius: 8px;
	background: #fff; font: inherit; color: var(--nb-text); box-sizing: border-box;
}
.nb-form-field input:focus, .nb-form-field textarea:focus { outline: none; border-color: var(--nb-accent); }
.nb-form-note { padding: 14px 18px; border-radius: 8px; margin-bottom: 20px; }
.nb-form-sent { background: #e8f2e8; color: #2f6b3a; border: 1px solid #cfe3cf; }
.nb-form-error { background: #fbe9e7; color: #a33; border: 1px solid #f0ccc9; }
.nb-hp-wrap { position: absolute; left: -9999px; top: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ===== 页脚 ===== */
.nb-footer { background: var(--nb-dark); color: #bdb6a9; }
.nb-footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 44px; padding-top: 72px; padding-bottom: 56px; }
.nb-footer .nb-logo-name { color: #fff; }
.nb-footer-about p { font-size: 14px; margin: 16px 0 0; }
.nb-footer-title { color: #fff; font-size: 17px; margin-bottom: 18px; }
.nb-footer-links, .nb-footer-contact { list-style: none; margin: 0; padding: 0; }
.nb-footer-links li, .nb-footer-contact li { margin-bottom: 10px; }
.nb-footer-links a { color: #bdb6a9; font-size: 14px; }
.nb-footer-links a:hover { color: #fff; }
.nb-footer-contact li { font-size: 14px; }
.nb-footer .nb-lang-dd { margin-top: 16px; }
.nb-footer .nb-lang-dd-toggle { color: #bdb6a9; border-color: rgba(255,255,255,.2); }
.nb-footer .nb-lang-dd-list { top: auto; bottom: calc(100% + 6px); }
.nb-footer-bottom { border-top: 1px solid rgba(255,255,255,.08); }
.nb-footer-bottom p { margin: 0; padding: 18px 0; font-size: 13px; color: #8f8879; }

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
	.nb-cat-grid { grid-template-columns: repeat(2, 1fr); }
	.nb-product-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
	.nb-menu-toggle { display: block; }
	.nb-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--nb-bg); border-bottom: 1px solid var(--nb-line); }
	.nb-nav.is-open { display: block; }
	.nb-menu { flex-direction: column; padding: 12px 24px 20px; gap: 0; }
	.nb-menu > li > a { padding: 12px 8px; border-radius: 8px; }
	.nb-submenu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 0 16px; margin: 0; }
	.nb-submenu li a { padding: 9px 8px; }
	.nb-product-detail { grid-template-columns: 1fr; gap: 32px; }
	.nb-detail-media { position: static; }
	.nb-about-grid { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 640px) {
	.nb-hero { min-height: 460px; }
	.nb-hero-title { font-size: 38px; }
	.nb-section-title, .nb-page-title { font-size: 30px; }
	.nb-cat-grid { grid-template-columns: 1fr; }
	.nb-product-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
	.nb-footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
	.nb-contact-form .nb-form-row { grid-template-columns: 1fr; }
	.nb-topbar-contact .nb-top-sep, .nb-topbar-contact .nb-top-email { display: none; }
	.nb-section { padding: 64px 0; }
}

/* ===== 阿拉伯语 RTL ===== */
html[dir="rtl"] .nb-hero-overlay { background: linear-gradient(-100deg, rgba(20,17,14,.78) 0%, rgba(20,17,14,.45) 45%, rgba(20,17,14,.15) 100%); }
html[dir="rtl"] .nb-menu, html[dir="rtl"] .nb-topbar .pll-switcher { direction: rtl; }
html[dir="rtl"] .nb-submenu { left: auto; right: 0; }
html[dir="rtl"] .nb-hero-content { text-align: right; }
html[dir="rtl"] .nb-section-head, html[dir="rtl"] .nb-cta-inner { text-align: center; }
html[dir="rtl"] .nb-detail-thumbs, html[dir="rtl"] .nb-subcat-pills { justify-content: flex-start; }
html[dir="rtl"] .nb-about-points li, html[dir="rtl"] .nb-cat-card-subs li { padding-right: 28px; padding-left: 0; }
html[dir="rtl"] .nb-about-points li::before, html[dir="rtl"] .nb-cat-card-subs li::before { right: 0; left: auto; }
html[dir="rtl"] .nb-cat-card-subs li { padding-inline-start: 16px; }
html[dir="rtl"] .nb-cat-card-subs li::before { inset-inline-start: 4px; }
html[dir="rtl"] body, html[dir="rtl"] .nb-container, html[dir="rtl"] .nb-prose { text-align: right; }
