/* ============================================================
   中国制造采购之家 - 主样式表
   Color Scheme: Deep Blue + Red Accent + Silver
   ============================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #0D3B8C;
    --primary-dark: #082659;
    --primary-light: #1a5276;
    --secondary: #E63946;
    --secondary-dark: #c1121f;
    --accent: #C0C0C0;
    --gold: #D4AF37;
    --text-dark: #1A1A2E;
    --text-gray: #666;
    --text-light: #999;
    --bg-light: #F8F9FA;
    --bg-white: #FFFFFF;
    --border-color: #E5E7EB;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.07);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 50px rgba(0,0,0,0.15);
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --transition: all 0.3s ease;
    --max-width: 1280px;
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--bg-light);
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--secondary);
}

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

ul, ol {
    list-style: none;
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
    outline: none;
    border: none;
    background: none;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================================
   Top Bar
   ============================================================ */
.top-bar {
    background: #f5f5f5;
    border-bottom: 1px solid var(--border-color);
    font-size: 12px;
    color: var(--text-gray);
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 36px;
}

.top-bar-left, .top-bar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.top-bar a:hover {
    color: var(--primary);
}

.top-bar .divider {
    color: var(--border-color);
}

/* ============================================================
   Header / Logo + Nav
   ============================================================ */
.header {
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 90px;
    gap: 30px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.logo img {
    height: 60px;
    width: auto;
}

.logo-h1 {
    margin: 0;
    line-height: 0;
}

/* Search Bar */
.search-box {
    flex: 1;
    max-width: 520px;
    display: flex;
    height: 44px;
    border: 2px solid var(--primary);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.search-box select {
    padding: 0 12px;
    background: #f8f9fa;
    border-right: 1px solid var(--border-color);
    color: var(--text-dark);
    cursor: pointer;
    font-size: 13px;
}

.search-box input {
    flex: 1;
    padding: 0 15px;
    font-size: 14px;
}

.search-box button {
    padding: 0 28px;
    background: var(--primary);
    color: white;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    transition: var(--transition);
}

.search-box button:hover {
    background: var(--primary-dark);
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
}

.action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    color: var(--text-gray);
    transition: var(--transition);
    font-size: 12px;
}

.action-item i {
    font-size: 22px;
    color: var(--primary);
}

.action-item:hover {
    color: var(--secondary);
}

.action-item:hover i {
    color: var(--secondary);
}

.action-item.cart {
    position: relative;
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -8px;
    background: var(--secondary);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    line-height: 1.4;
}

/* ============================================================
   Main Navigation
   ============================================================ */
.main-nav {
    background: var(--primary);
    color: white;
}

.main-nav .container {
    display: flex;
    align-items: center;
    height: 48px;
}

.nav-categories {
    width: 240px;
    background: var(--primary-dark);
    height: 48px;
    display: flex;
    align-items: center;
    padding: 0 20px;
    font-weight: 600;
    font-size: 15px;
    gap: 10px;
    cursor: pointer;
    position: relative;
}

.nav-categories i {
    font-size: 18px;
}

.nav-menu {
    display: flex;
    flex: 1;
    height: 100%;
}

.nav-menu li {
    height: 100%;
}

.nav-menu a {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 22px;
    color: white;
    font-size: 15px;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-menu a:hover,
.nav-menu a.active {
    background: var(--primary-dark);
    color: white;
}

.nav-menu a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: var(--secondary);
    border-radius: 2px;
}

.nav-hot {
    background: var(--secondary);
    color: white;
    font-size: 10px;
    padding: 2px 5px;
    border-radius: 3px;
    margin-left: 5px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ============================================================
   Category Sidebar (Dropdown)
   ============================================================ */
.category-sidebar {
    position: absolute;
    top: 100%;
    left: 0;
    width: 240px;
    background: white;
    border: 1px solid var(--border-color);
    border-top: none;
    box-shadow: var(--shadow-lg);
    z-index: 999;
    display: none;
}

.nav-categories:hover .category-sidebar {
    display: block;
}

.category-item {
    padding: 12px 20px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    color: var(--text-dark);
}

.category-item:hover {
    background: var(--bg-light);
    color: var(--primary);
    padding-left: 25px;
}

.category-item i {
    font-size: 12px;
    color: var(--text-light);
}

.category-item:hover i {
    color: var(--primary);
}

/* Category submenu */
.category-submenu {
    position: absolute;
    top: 0;
    left: 100%;
    width: 500px;
    background: white;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    padding: 20px;
    display: none;
    min-height: 100%;
}

.category-item:hover .category-submenu {
    display: block;
}

.submenu-group {
    margin-bottom: 15px;
}

.submenu-group-title {
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 8px;
    font-size: 14px;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--border-color);
}

.submenu-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 15px;
}

.submenu-links a {
    font-size: 13px;
    color: var(--text-gray);
    padding: 3px 0;
    white-space: nowrap;
}

.submenu-links a:hover {
    color: var(--secondary);
}

/* ============================================================
   Hero / Banner Section
   ============================================================ */
.hero-section {
    padding: 20px 0;
    background: var(--bg-light);
}

.hero-wrap {
    display: grid;
    grid-template-columns: 240px 1fr 260px;
    gap: 20px;
    height: 380px;
    align-items: stretch;
}

/* Hero categories panel */
.hero-categories {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
}

.hero-categories::-webkit-scrollbar {
    width: 6px;
}

.hero-categories::-webkit-scrollbar-thumb {
    background: #d5dbe5;
    border-radius: 3px;
}

.hero-categories::-webkit-scrollbar-thumb:hover {
    background: #b9c2d0;
}

.hero-categories .cat-item {
    padding: 14px 18px;
    border-bottom: 1px solid #f5f5f5;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
}

.hero-categories .cat-item:last-child {
    border-bottom: none;
}

.hero-categories .cat-item:hover {
    background: linear-gradient(90deg, rgba(13,59,140,0.05) 0%, transparent 100%);
    color: var(--primary);
}

.hero-categories .cat-item i {
    font-size: 18px;
    color: var(--primary);
    width: 24px;
    text-align: center;
}

.hero-categories .cat-item .arrow {
    margin-left: auto;
    font-size: 12px;
    color: var(--text-light);
}

/* Hero Slider */
.hero-slider {
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    height: 100%;
}

.slider-container {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide.active {
    opacity: 1;
}

.slide-bg-1 {
    background: linear-gradient(135deg, #0D3B8C 0%, #1a5276 50%, #0D3B8C 100%);
}

.slide-bg-2 {
    background: linear-gradient(135deg, #E63946 0%, #c1121f 50%, #E63946 100%);
}

.slide-bg-3 {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 50%, #2c3e50 100%);
}

.slide-content {
    color: white;
    text-align: center;
    padding: 40px;
    z-index: 2;
    position: relative;
}

.slide-content h2 {
    font-size: 42px;
    font-weight: bold;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.slide-content p {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 25px;
}

.slide-btn {
    display: inline-block;
    padding: 12px 36px;
    background: white;
    color: var(--primary);
    border-radius: 30px;
    font-weight: 600;
    font-size: 15px;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.slide-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 5;
}

.slider-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: var(--transition);
}

.slider-dots span.active {
    background: white;
    width: 30px;
    border-radius: 5px;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    background: rgba(0,0,0,0.3);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    transition: var(--transition);
    font-size: 18px;
}

.slider-arrow:hover {
    background: rgba(0,0,0,0.5);
}

.slider-prev { left: 15px; }
.slider-next { right: 15px; }

/* Hero Side Panel */
.hero-side {
    display: flex;
    flex-direction: column;
    gap: 15px;
    height: 100%;
    min-width: 0;
    /* 防止右侧内容把英雄区整行撑高，超出 380px */
    min-height: 0;
}

.side-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    flex: 1;
}

.side-card-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.side-card-title .more {
    font-size: 12px;
    color: var(--text-light);
    font-weight: normal;
}

.side-news li {
    padding: 5px 0;
    font-size: 13px;
    color: var(--text-gray);
    border-bottom: 1px dashed #f0f0f0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.side-news li:last-child {
    border-bottom: none;
}

.side-news li:hover {
    color: var(--primary);
    cursor: pointer;
}

.side-news .date {
    color: var(--text-light);
    font-size: 12px;
    margin-right: 8px;
}

/* Quick Actions */
.quick-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.quick-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 12px 10px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    border-radius: var(--radius-md);
    font-size: 12px;
    transition: var(--transition);
    cursor: pointer;
    gap: 6px;
}

.quick-btn:nth-child(2) {
    background: linear-gradient(135deg, var(--secondary) 0%, #f96167 100%);
}

.quick-btn:nth-child(3) {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
}

.quick-btn:nth-child(4) {
    background: linear-gradient(135deg, #f39c12 0%, #f1c40f 100%);
}

.quick-btn i {
    font-size: 24px;
}

.quick-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    color: white;
}

/* 窄屏：英雄区改为自适应高度，右侧栏不再占位 */
@media (max-width: 992px) {
    .hero-wrap { grid-template-columns: 200px 1fr; height: auto; }
    .hero-side { display: none; }
    .hero-categories { max-height: 320px; }
    .hero-slider { height: 320px; }
}

@media (max-width: 768px) {
    .hero-wrap { grid-template-columns: 1fr; height: auto; }
    .hero-categories { max-height: 260px; }
    .hero-slider { height: 220px; }
}

/* ============================================================
   Section Common
   ============================================================ */
.section {
    padding: 40px 0;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.section-title {
    font-size: 24px;
    font-weight: bold;
    color: var(--text-dark);
    position: relative;
    padding-left: 15px;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: linear-gradient(to bottom, var(--primary), var(--secondary));
    border-radius: 2px;
}

.section-more {
    font-size: 13px;
    color: var(--text-gray);
    display: flex;
    align-items: center;
    gap: 5px;
}

.section-more:hover {
    color: var(--primary);
}

/* ============================================================
   Category Grid
   ============================================================ */
.category-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 15px;
}

.category-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px 15px;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
}

.category-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.category-card .icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 12px;
    background: linear-gradient(135deg, rgba(13,59,140,0.1) 0%, rgba(230,57,70,0.1) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--primary);
    transition: var(--transition);
}

.category-card:hover .icon {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    transform: scale(1.1);
}

.category-card .name {
    font-size: 14px;
    color: var(--text-dark);
    font-weight: 500;
}

.category-card .count {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 4px;
}

/* ============================================================
   Product Grid
   ============================================================ */
.products-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.product-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
    border-color: transparent;
}

.product-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.product-image .emoji {
    font-size: 64px;
    opacity: 0.8;
    transition: var(--transition);
}

.product-card:hover .product-image .emoji {
    transform: scale(1.1);
}

.product-tag {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--secondary);
    color: white;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 3px;
    font-weight: 500;
}

.product-tag.hot {
    background: var(--secondary);
}

.product-tag.new {
    background: #27ae60;
}

.product-tag.sale {
    background: #f39c12;
}

.product-info {
    padding: 15px;
}

.product-title {
    font-size: 14px;
    color: var(--text-dark);
    margin-bottom: 8px;
    line-height: 1.4;
    height: 38px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-card:hover .product-title {
    color: var(--primary);
}

.product-price {
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin-bottom: 8px;
}

.price-current {
    font-size: 20px;
    font-weight: bold;
    color: var(--secondary);
}

.price-unit {
    font-size: 12px;
    color: var(--text-light);
}

.product-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-light);
}

.product-company {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
    margin-right: 10px;
}

/* ============================================================
   Brands Section
   ============================================================ */
.brands-section {
    background: white;
}

.brands-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
}

.brand-card {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 25px 15px;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
    background: var(--bg-light);
}

.brand-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    background: white;
}

.brand-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 12px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    font-weight: bold;
}

.brand-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.brand-location {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 4px;
}

/* ============================================================
   News Section
   ============================================================ */
.news-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 25px;
}

.news-card {
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    cursor: pointer;
}

.news-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.news-image {
    height: 160px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
}

.news-card:nth-child(2) .news-image {
    background: linear-gradient(135deg, var(--secondary) 0%, #f96167 100%);
}

.news-card:nth-child(3) .news-image {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
}

.news-content {
    padding: 18px;
}

.news-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
    line-height: 1.4;
}

.news-card:hover .news-title {
    color: var(--primary);
}

.news-desc {
    font-size: 13px;
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-light);
}

/* ============================================================
   Advantages Section
   ============================================================ */
.advantages-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 50px 0;
}

.advantages-section .section-title {
    color: white;
}

.advantages-section .section-title::before {
    background: linear-gradient(to bottom, white, var(--gold));
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 30px;
}

.advantage-item {
    text-align: center;
    padding: 30px 20px;
    background: rgba(255,255,255,0.05);
    border-radius: var(--radius-lg);
    transition: var(--transition);
    border: 1px solid rgba(255,255,255,0.1);
}

.advantage-item:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-5px);
}

.advantage-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 20px;
    background: rgba(255,255,255,0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.advantage-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

.advantage-desc {
    font-size: 13px;
    opacity: 0.8;
    line-height: 1.6;
}

/* ============================================================
   Footer
   ============================================================ */
.footer {
    background: #1a1a2e;
    color: rgba(255,255,255,0.7);
    padding: 50px 0 0;
}

.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-col h4 {
    color: white;
    font-size: 16px;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-col li {
    margin-bottom: 10px;
    font-size: 13px;
}

.footer-col a {
    color: rgba(255,255,255,0.6);
    transition: var(--transition);
}

.footer-col a:hover {
    color: white;
    padding-left: 5px;
}

.footer-about p {
    font-size: 13px;
    line-height: 1.8;
    margin-bottom: 15px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.footer-logo img {
    height: 40px;
    filter: brightness(0) invert(1);
}

.footer-logo-text {
    color: white;
    font-size: 18px;
    font-weight: bold;
}

.footer-contact p {
    margin-bottom: 8px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-contact i {
    color: var(--secondary);
    width: 16px;
}

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    font-size: 12px;
    color: rgba(255,255,255,0.4);
}

.footer-bottom a {
    color: rgba(255,255,255,0.4);
    margin: 0 10px;
}

.footer-bottom a:hover {
    color: white;
}

/* ============================================================
   Page Header (Internal Pages)
   ============================================================ */
.page-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 40px 0;
}

.page-header h1 {
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 10px;
}

.breadcrumb {
    font-size: 13px;
    opacity: 0.8;
}

.breadcrumb a {
    color: white;
    opacity: 0.8;
}

.breadcrumb a:hover {
    opacity: 1;
}

.breadcrumb .sep {
    margin: 0 8px;
    opacity: 0.5;
}

/* ============================================================
   Product List Page
   ============================================================ */
.list-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 20px;
    padding: 30px 0;
}

.sidebar-filter {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    height: fit-content;
    position: sticky;
    top: 150px;
}

.filter-group {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.filter-group:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.filter-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-dark);
}

.filter-list li {
    padding: 6px 0;
    font-size: 13px;
    color: var(--text-gray);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filter-list li:hover,
.filter-list li.active {
    color: var(--primary);
}

.filter-list .count {
    color: var(--text-light);
    font-size: 12px;
}

/* Products list area */
.list-main {
    min-width: 0;
}

.list-toolbar {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 15px 20px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sort-options {
    display: flex;
    gap: 5px;
}

.sort-btn {
    padding: 6px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-gray);
    cursor: pointer;
    transition: var(--transition);
    background: white;
}

.sort-btn:hover,
.sort-btn.active {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(13,59,140,0.05);
}

.list-info {
    font-size: 13px;
    color: var(--text-gray);
}

.list-info strong {
    color: var(--secondary);
    font-weight: 600;
}

/* ============================================================
   Pagination
   ============================================================ */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 30px;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-gray);
    transition: var(--transition);
    background: white;
}

.pagination a:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.pagination .current {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ============================================================
   About / Company Page
   ============================================================ */
.about-hero {
    background: white;
    padding: 40px 0;
    border-bottom: 1px solid var(--border-color);
}

.about-hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-text h2 {
    font-size: 28px;
    color: var(--text-dark);
    margin-bottom: 20px;
}

.about-text p {
    color: var(--text-gray);
    line-height: 1.8;
    margin-bottom: 15px;
    font-size: 14px;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.stat-item {
    text-align: center;
    padding: 20px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
}

.stat-number {
    font-size: 32px;
    font-weight: bold;
    color: var(--primary);
    line-height: 1;
}

.stat-label {
    font-size: 13px;
    color: var(--text-gray);
    margin-top: 8px;
}

.about-image {
    height: 350px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 120px;
}

/* ============================================================
   Contact Page
   ============================================================ */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 40px 0;
}

.contact-info-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 30px;
}

.contact-info-card h3 {
    font-size: 20px;
    margin-bottom: 25px;
    color: var(--text-dark);
}

.contact-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.contact-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
    flex-shrink: 0;
}

.contact-item-text h4 {
    font-size: 15px;
    margin-bottom: 5px;
    color: var(--text-dark);
}

.contact-item-text p {
    color: var(--text-gray);
    font-size: 13px;
}

.contact-form {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 30px;
}

.contact-form h3 {
    font-size: 20px;
    margin-bottom: 25px;
    color: var(--text-dark);
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--text-dark);
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: var(--transition);
    background: white;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(13,59,140,0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ============================================================
   Floating Sidebar (Right side)
   ============================================================ */
.floating-sidebar {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.float-item {
    width: 50px;
    height: 50px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 11px;
    color: var(--text-gray);
    gap: 2px;
}

.float-item i {
    font-size: 18px;
    color: var(--primary);
}

.float-item:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.float-item:hover i {
    color: white;
}

.float-item.back-top {
    display: none;
}

.float-item.back-top.show {
    display: flex;
}

/* ============================================================
   Mobile Menu Button
   ============================================================ */
.mobile-menu-btn {
    display: none;
    font-size: 24px;
    color: var(--primary);
    cursor: pointer;
    padding: 10px;
}

/* ============================================================
   Utility Classes
   ============================================================ */
.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }
.text-gray { color: var(--text-gray); }
.text-light { color: var(--text-light); }

.bg-white { background: white; }
.bg-light { background: var(--bg-light); }

.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }
.mb-10 { margin-bottom: 10px; }
.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }

.text-center { text-align: center; }
.text-right { text-align: right; }

.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-10 { gap: 10px; }
.gap-15 { gap: 15px; }
.gap-20 { gap: 20px; }

.hidden { display: none; }

/* ============================================================
   Multi-Store / Shop System
   ============================================================ */

/* Company List */
.company-list { padding: 30px 0; }
.company-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 25px;
    margin-bottom: 15px;
    display: flex;
    gap: 25px;
    transition: var(--transition);
    cursor: pointer;
}
.company-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}
.company-logo {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 36px;
    font-weight: bold;
    flex-shrink: 0;
}
.company-info { flex: 1; min-width: 0; }
.company-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.company-card:hover .company-name { color: var(--primary); }
.company-badge {
    display: inline-block;
    padding: 2px 8px;
    background: linear-gradient(135deg, var(--gold) 0%, #e6c200 100%);
    color: white;
    font-size: 11px;
    border-radius: 3px;
    font-weight: 500;
}
.company-badge.vip {
    background: linear-gradient(135deg, var(--secondary) 0%, #f96167 100%);
}
.company-desc {
    font-size: 13px;
    color: var(--text-gray);
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.company-meta {
    display: flex;
    gap: 20px;
    font-size: 12px;
    color: var(--text-light);
    flex-wrap: wrap;
}
.company-meta span { display: flex; align-items: center; gap: 5px; }
.company-side {
    text-align: center;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
}
.company-products-count {
    font-size: 24px;
    font-weight: bold;
    color: var(--secondary);
}
.company-products-label {
    font-size: 12px;
    color: var(--text-light);
}
.company-enter-btn {
    display: inline-block;
    padding: 8px 24px;
    background: var(--primary);
    color: white;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}
.company-enter-btn:hover {
    background: var(--primary-dark);
    color: white;
    transform: translateY(-1px);
}

/* Shop Page */
.shop-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 40px 0;
    position: relative;
    overflow: hidden;
}
.shop-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
}
.shop-header-content {
    display: flex;
    align-items: center;
    gap: 30px;
    position: relative;
    z-index: 2;
}
.shop-logo {
    width: 120px;
    height: 120px;
    border-radius: var(--radius-lg);
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: bold;
    color: var(--primary);
    box-shadow: var(--shadow-lg);
    flex-shrink: 0;
}
.shop-info { flex: 1; }
.shop-name {
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.shop-tags { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.shop-tag {
    padding: 4px 12px;
    background: rgba(255,255,255,0.2);
    border-radius: 20px;
    font-size: 12px;
}
.shop-desc {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 15px;
    max-width: 600px;
}
.shop-stats { display: flex; gap: 30px; }
.shop-stat { text-align: center; }
.shop-stat-num { font-size: 20px; font-weight: bold; }
.shop-stat-label { font-size: 12px; opacity: 0.8; }
.shop-actions { display: flex; flex-direction: column; gap: 10px; }
.shop-action-btn {
    padding: 10px 25px;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    min-width: 120px;
}
.shop-action-btn.primary {
    background: white;
    color: var(--primary);
    font-weight: 600;
}
.shop-action-btn.primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.shop-action-btn.outline {
    border: 1px solid rgba(255,255,255,0.5);
    color: white;
}
.shop-action-btn.outline:hover {
    background: rgba(255,255,255,0.1);
    color: white;
}

/* Shop Nav Tabs */
.shop-nav {
    background: white;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 138px;
    z-index: 100;
}
.shop-nav-list {
    display: flex;
    gap: 0;
}
.shop-nav-item {
    padding: 15px 30px;
    font-size: 15px;
    color: var(--text-gray);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    font-weight: 500;
}
.shop-nav-item:hover { color: var(--primary); }
.shop-nav-item.active { color: var(--primary); }
.shop-nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--primary);
    border-radius: 3px 3px 0 0;
}

/* Product Detail */
.product-detail-layout {
    display: grid;
    grid-template-columns: 450px 1fr;
    gap: 40px;
    padding: 30px 0;
}
.product-gallery {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
}
.product-main-image {
    width: 100%;
    height: 400px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    margin-bottom: 15px;
}
.product-thumbs {
    display: flex;
    gap: 10px;
}
.product-thumb {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    cursor: pointer;
    transition: var(--transition);
}
.product-thumb:hover,
.product-thumb.active {
    border-color: var(--primary);
}
.product-info-main { background: white; border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 30px; }
.product-detail-title { font-size: 22px; font-weight: 600; color: var(--text-dark); margin-bottom: 15px; line-height: 1.4; }
.product-detail-price {
    background: linear-gradient(135deg, #fff5f5 0%, #ffe8e8 100%);
    padding: 20px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    display: flex;
    align-items: baseline;
    gap: 15px;
}
.detail-price-label { font-size: 14px; color: var(--text-gray); }
.detail-price-current { font-size: 32px; font-weight: bold; color: var(--secondary); }
.detail-price-unit { font-size: 14px; color: var(--text-gray); }
.detail-price-range { font-size: 13px; color: var(--text-light); }
.product-specs { margin-bottom: 20px; }
.spec-group {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px dashed var(--border-color);
    align-items: flex-start;
}
.spec-group:last-child { border-bottom: none; }
.spec-label {
    width: 100px;
    color: var(--text-gray);
    font-size: 14px;
    flex-shrink: 0;
}
.spec-value { flex: 1; color: var(--text-dark); font-size: 14px; }
.spec-options { display: flex; gap: 10px; flex-wrap: wrap; }
.spec-option {
    padding: 6px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}
.spec-option:hover,
.spec-option.active {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(13,59,140,0.05);
}
.quantity-section {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
}
.quantity-label { font-size: 14px; color: var(--text-gray); width: 100px; flex-shrink: 0; }
.quantity-input {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    overflow: hidden;
}
.quantity-input button {
    width: 36px;
    height: 36px;
    background: var(--bg-light);
    color: var(--text-dark);
    cursor: pointer;
    font-size: 16px;
    transition: var(--transition);
}
.quantity-input button:hover { background: var(--border-color); }
.quantity-input input {
    width: 80px;
    height: 36px;
    text-align: center;
    border: none;
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    font-size: 14px;
}
.quantity-unit { font-size: 13px; color: var(--text-gray); }
.product-action-buttons { display: flex; gap: 15px; }
.action-btn {
    flex: 1;
    padding: 14px;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}
.action-btn.buy-now {
    background: linear-gradient(135deg, var(--secondary) 0%, #f96167 100%);
    color: white;
}
.action-btn.buy-now:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); color: white; }
.action-btn.add-cart {
    border: 2px solid var(--primary);
    color: var(--primary);
    background: white;
}
.action-btn.add-cart:hover { background: var(--primary); color: white; }
.action-btn.contact {
    border: 2px solid var(--border-color);
    color: var(--text-gray);
    background: white;
}
.action-btn.contact:hover { border-color: var(--primary); color: var(--primary); }

.product-shop-info {
    margin-top: 20px;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 15px;
}
.product-shop-logo {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    flex-shrink: 0;
}
.product-shop-name { font-size: 16px; font-weight: 600; margin-bottom: 5px; }
.product-shop-desc { font-size: 12px; color: var(--text-gray); margin-bottom: 8px; }
.product-shop-stats { display: flex; gap: 15px; font-size: 12px; color: var(--text-light); }
.product-shop-enter { margin-left: auto; }

/* Product detail tabs */
.detail-tabs-section { margin-top: 30px; }
.detail-tabs {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}
.detail-tab-headers {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-light);
}
.detail-tab-header {
    padding: 15px 30px;
    cursor: pointer;
    font-size: 15px;
    color: var(--text-gray);
    transition: var(--transition);
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    font-weight: 500;
}
.detail-tab-header:hover { color: var(--primary); }
.detail-tab-header.active {
    color: var(--primary);
    background: white;
    border-bottom-color: var(--primary);
}
.detail-tab-content { padding: 30px; }
.detail-tab-pane { display: none; }
.detail-tab-pane.active { display: block; }
.detail-desc { color: var(--text-gray); line-height: 1.8; font-size: 14px; }
.detail-desc h4 { color: var(--text-dark); font-size: 16px; margin: 20px 0 10px; }
.detail-desc p { margin-bottom: 12px; }
.detail-table { width: 100%; border-collapse: collapse; margin-top: 15px; }
.detail-table th, .detail-table td {
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    text-align: left;
    font-size: 13px;
}
.detail-table th {
    background: var(--bg-light);
    font-weight: 600;
    color: var(--text-dark);
    width: 150px;
}

/* Login / Register */
.auth-page {
    min-height: calc(100vh - 300px);
    background: linear-gradient(135deg, var(--bg-light) 0%, #e8ecf1 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}
.auth-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 450px;
    padding: 40px;
}
.auth-header { text-align: center; margin-bottom: 30px; }
.auth-logo {
    width: 70px;
    height: 70px;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    font-weight: bold;
}
.auth-title { font-size: 24px; font-weight: bold; color: var(--text-dark); margin-bottom: 5px; }
.auth-subtitle { font-size: 13px; color: var(--text-gray); }
.auth-form .form-group { margin-bottom: 18px; }
.auth-form label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--text-dark);
    font-weight: 500;
}
.auth-form input,
.auth-form select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    transition: var(--transition);
    background: white;
}
.auth-form input:focus,
.auth-form select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(13,59,140,0.1);
}
.auth-form-row { display: flex; gap: 12px; }
.auth-form-row .form-group { flex: 1; }
.auth-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 13px;
}
.auth-remember { display: flex; align-items: center; gap: 6px; color: var(--text-gray); cursor: pointer; }
.auth-forgot { color: var(--primary); }
.auth-forgot:hover { color: var(--primary-dark); }
.auth-submit {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.auth-submit:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.auth-footer {
    text-align: center;
    margin-top: 25px;
    font-size: 13px;
    color: var(--text-gray);
}
.auth-footer a { color: var(--primary); font-weight: 500; }
.auth-footer a:hover { color: var(--primary-dark); }
.auth-types {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}
.auth-type-btn {
    flex: 1;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    color: var(--text-gray);
}
.auth-type-btn:hover { border-color: var(--primary); color: var(--primary); }
.auth-type-btn.active {
    border-color: var(--primary);
    background: rgba(13,59,140,0.05);
    color: var(--primary);
    font-weight: 600;
}

/* Dashboard / Seller Center */
.dashboard-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    min-height: calc(100vh - 300px);
    padding: 20px 0;
    gap: 20px;
}
.dashboard-sidebar {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    height: fit-content;
    position: sticky;
    top: 150px;
    overflow: hidden;
}
.dashboard-user {
    padding: 25px 20px;
    text-align: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
}
.dashboard-avatar {
    width: 60px;
    height: 60px;
    margin: 0 auto 10px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}
.dashboard-username { font-size: 16px; font-weight: 600; margin-bottom: 3px; }
.dashboard-usertype { font-size: 12px; opacity: 0.8; }
.dashboard-menu { padding: 10px 0; }
.dashboard-menu-title {
    padding: 12px 20px 8px;
    font-size: 12px;
    color: var(--text-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.dashboard-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--text-gray);
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    border-left: 3px solid transparent;
}
.dashboard-menu-item:hover {
    background: var(--bg-light);
    color: var(--primary);
}
.dashboard-menu-item.active {
    background: rgba(13,59,140,0.05);
    color: var(--primary);
    border-left-color: var(--primary);
    font-weight: 500;
}
.dashboard-menu-item i { font-size: 18px; width: 20px; text-align: center; }
.dashboard-menu-badge {
    margin-left: auto;
    background: var(--secondary);
    color: white;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
}
.dashboard-main { min-width: 0; }
/* 个人中心主区域内的商品栅格：随可用宽度自适应，避免 5 列过窄 */
.dashboard-main .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}
.dashboard-header {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px 25px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.dashboard-page-title { font-size: 20px; font-weight: 600; color: var(--text-dark); }
.dashboard-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}
.dashboard-stat-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}
.dashboard-stat-icon {
    width: 50px;
    height: 50px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    flex-shrink: 0;
}
.dashboard-stat-icon.blue { background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%); }
.dashboard-stat-icon.red { background: linear-gradient(135deg, var(--secondary) 0%, #f96167 100%); }
.dashboard-stat-icon.green { background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%); }
.dashboard-stat-icon.orange { background: linear-gradient(135deg, #f39c12 0%, #f1c40f 100%); }
.dashboard-stat-info { flex: 1; min-width: 0; }
.dashboard-stat-num { font-size: 24px; font-weight: bold; color: var(--text-dark); }
.dashboard-stat-label { font-size: 12px; color: var(--text-gray); margin-top: 3px; }
.dashboard-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    margin-bottom: 20px;
}
.dashboard-card-header {
    padding: 18px 25px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.dashboard-card-title { font-size: 16px; font-weight: 600; color: var(--text-dark); }
.dashboard-card-body { padding: 20px 25px; }

/* Table */
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
    padding: 12px 15px;
    background: var(--bg-light);
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dark);
    border-bottom: 1px solid var(--border-color);
}
.data-table td {
    padding: 15px;
    font-size: 13px;
    color: var(--text-gray);
    border-bottom: 1px solid var(--border-color);
}
.data-table tbody tr:hover { background: var(--bg-light); }
.data-table .product-name {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-dark);
    font-weight: 500;
}
.data-table .product-thumb-img {
    width: 40px;
    height: 40px;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}
.status-badge.online { background: #e8f5e9; color: #27ae60; }
.status-badge.offline { background: #f5f5f5; color: #999; }
.status-badge.pending { background: #fff3e0; color: #f39c12; }
.status-badge.rejected { background: #ffebee; color: #E63946; }
.table-actions { display: flex; gap: 10px; }
.table-action-btn {
    color: var(--primary);
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}
.table-action-btn:hover { color: var(--primary-dark); text-decoration: underline; }
.table-action-btn.danger { color: var(--secondary); }
.table-action-btn.danger:hover { color: var(--secondary-dark); }

/* Publish Form */
.publish-form {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 30px;
}
.form-section { margin-bottom: 30px; }
.form-section-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}
.form-grid .form-group { margin-bottom: 0; }
.form-group.full { grid-column: 1 / -1; }
.image-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: var(--bg-light);
}
.image-upload-area:hover {
    border-color: var(--primary);
    background: rgba(13,59,140,0.03);
}
.image-upload-icon {
    font-size: 48px;
    color: var(--text-light);
    margin-bottom: 10px;
}
.image-upload-text { color: var(--text-gray); font-size: 14px; margin-bottom: 5px; }
.image-upload-hint { color: var(--text-light); font-size: 12px; }
.uploaded-images {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}
.uploaded-image-item {
    width: 80px;
    height: 80px;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    position: relative;
    border: 1px solid var(--border-color);
}
.uploaded-image-item .remove {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 20px;
    height: 20px;
    background: var(--secondary);
    color: white;
    border-radius: 50%;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}
.form-btn {
    padding: 12px 40px;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.form-btn.primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
}
.form-btn.primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.form-btn.secondary {
    background: white;
    color: var(--text-gray);
    border: 1px solid var(--border-color);
}
.form-btn.secondary:hover { border-color: var(--primary); color: var(--primary); }

/* Register Benefits */
.register-benefits {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 50px 0;
    margin-bottom: 40px;
}
.register-benefits .section-title { color: white; }
.register-benefits .section-title::before { background: linear-gradient(to bottom, white, var(--gold)); }
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 30px;
}
.benefit-item {
    text-align: center;
    padding: 30px 20px;
    background: rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255,255,255,0.15);
    transition: var(--transition);
}
.benefit-item:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-5px);
}
.benefit-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}
.benefit-title { font-size: 16px; font-weight: 600; margin-bottom: 8px; }
.benefit-desc { font-size: 13px; opacity: 0.85; line-height: 1.6; }

/* Responsive for dashboard */
@media (max-width: 992px) {
    .product-detail-layout { grid-template-columns: 1fr; gap: 20px; padding: 20px 0; }
    .product-main-image { height: 300px; }
    .dashboard-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .company-card { flex-wrap: wrap; }
    .company-side { width: 100%; flex-direction: row; justify-content: space-between; align-items: center; }
}
@media (max-width: 768px) {
    .dashboard-layout { grid-template-columns: 1fr; }
    .dashboard-sidebar { position: static; }
    .dashboard-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .shop-header-content { flex-direction: column; text-align: center; }
    .shop-stats { justify-content: center; }
    .shop-actions { flex-direction: row; width: 100%; justify-content: center; }
    .shop-nav { top: 138px; overflow-x: auto; }
    .shop-nav-list { flex-wrap: nowrap; }
    .shop-nav-item { padding: 12px 20px; white-space: nowrap; }
    .form-grid { grid-template-columns: 1fr; }
    .benefits-grid { grid-template-columns: repeat(2, 1fr); gap: 15px; }
    .benefit-item { padding: 20px 15px; }
    .auth-card { padding: 30px 20px; }
    .product-action-buttons { flex-wrap: wrap; }
    .action-btn { flex: 1 1 45%; }
}
@media (max-width: 576px) {
    .dashboard-stats-grid { grid-template-columns: 1fr; }
    .company-logo { width: 70px; height: 70px; font-size: 28px; }
    .company-card { padding: 15px; gap: 15px; }
    .benefits-grid { grid-template-columns: 1fr; }
    .shop-logo { width: 80px; height: 80px; font-size: 32px; }
    .shop-name { font-size: 22px; }
    .product-detail-title { font-size: 18px; }
    .detail-price-current { font-size: 26px; }
    .product-action-buttons { flex-direction: column; }
    .action-btn { width: 100%; }
    .data-table { font-size: 12px; }
    .data-table th, .data-table td { padding: 10px 8px; }
}

/* ===== 采购信息页（原 buy.html 内联样式） ===== */
.buy-list { padding: 30px 0; }
.buy-item { background: white; border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 20px 25px; margin-bottom: 15px; transition: var(--transition); display: flex; align-items: center; gap: 20px; }
.buy-item:hover { box-shadow: var(--shadow-md); border-color: var(--primary); }
.buy-item-info { flex: 1; }
.buy-item-title { font-size: 16px; font-weight: 600; color: var(--text-dark); margin-bottom: 8px; }
.buy-item-title:hover { color: var(--primary); cursor: pointer; }
.buy-item-desc { font-size: 13px; color: var(--text-gray); margin-bottom: 10px; }
.buy-item-meta { display: flex; gap: 20px; font-size: 12px; color: var(--text-light); }
.buy-item-meta span { display: flex; align-items: center; gap: 5px; }
.buy-item-side { text-align: right; flex-shrink: 0; }
.buy-item-price { font-size: 20px; font-weight: bold; color: var(--secondary); margin-bottom: 5px; }
.buy-item-btn { display: inline-block; padding: 8px 20px; background: var(--primary); color: white; border-radius: 20px; font-size: 13px; cursor: pointer; transition: var(--transition); }
.buy-item-btn:hover { background: var(--primary-dark); color: white; }
.buy-status { display: inline-block; padding: 3px 10px; border-radius: 3px; font-size: 12px; margin-bottom: 8px; }
.status-active { background: #e8f5e9; color: #27ae60; }
.status-urgent { background: #ffebee; color: #E63946; }
.status-ended { background: #f5f5f5; color: #999; }
.publish-buy-box { background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%); color: white; border-radius: var(--radius-md); padding: 30px; text-align: center; margin-bottom: 25px; }
.publish-buy-box h3 { font-size: 22px; margin-bottom: 10px; }
.publish-buy-box p { opacity: 0.9; margin-bottom: 20px; }
.publish-btn { display: inline-block; padding: 12px 40px; background: white; color: var(--primary); border-radius: 30px; font-weight: 600; cursor: pointer; transition: var(--transition); }
.publish-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
@media (max-width: 768px) {
    .buy-item { flex-direction: column; align-items: flex-start; padding: 15px; gap: 12px; }
    .buy-item-side { width: 100%; text-align: left; display: flex; justify-content: space-between; align-items: center; }
}

/* ===== 行业资讯页（原 news.html 内联样式） ===== */
.news-page-grid { display: grid; grid-template-columns: 1fr 280px; gap: 30px; padding: 30px 0; }
.news-article { background: white; border: 1px solid var(--border-color); border-radius: var(--radius-md); margin-bottom: 20px; overflow: hidden; transition: var(--transition); cursor: pointer; display: flex; }
.news-article:hover { box-shadow: var(--shadow-md); }
.news-article-img { width: 220px; height: 160px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: white; font-size: 48px; }
.news-article-content { flex: 1; padding: 20px; display: flex; flex-direction: column; }
.news-article-title { font-size: 18px; font-weight: 600; color: var(--text-dark); margin-bottom: 10px; line-height: 1.4; }
.news-article:hover .news-article-title { color: var(--primary); }
.news-article-desc { font-size: 13px; color: var(--text-gray); line-height: 1.7; flex: 1; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.news-article-meta { display: flex; gap: 15px; font-size: 12px; color: var(--text-light); margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--border-color); }
.news-sidebar { position: sticky; top: 150px; }
.sidebar-card { background: white; border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 20px; margin-bottom: 20px; }
.sidebar-card-title { font-size: 16px; font-weight: 600; margin-bottom: 15px; padding-bottom: 10px; border-bottom: 2px solid var(--primary); display: inline-block; }
.hot-news li { padding: 10px 0; border-bottom: 1px dashed #f0f0f0; font-size: 13px; cursor: pointer; display: flex; gap: 10px; }
.hot-news li:last-child { border-bottom: none; }
.hot-news li:hover { color: var(--primary); }
.hot-news .rank { width: 20px; height: 20px; background: #ccc; color: white; border-radius: 3px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: bold; flex-shrink: 0; }
.hot-news li:nth-child(1) .rank { background: #E63946; }
.hot-news li:nth-child(2) .rank { background: #f39c12; }
.hot-news li:nth-child(3) .rank { background: #f1c40f; }
@media (max-width: 992px) { .news-page-grid { grid-template-columns: 1fr; } .news-sidebar { display: none; } }
@media (max-width: 768px) {
    .news-article { flex-direction: column; }
    .news-article-img { width: 100%; height: 180px; }
}

/* ===== 品牌页（原 brands.html 内联样式） ===== */
.brands-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding: 30px 0; }
.brand-item { background: white; border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 25px; text-align: center; transition: var(--transition); cursor: pointer; }
.brand-item:hover { box-shadow: var(--shadow-lg); transform: translateY(-5px); border-color: var(--primary); }
.brand-item-logo { width: 100px; height: 100px; margin: 0 auto 15px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: white; font-size: 36px; font-weight: bold; }
.brand-item-name { font-size: 18px; font-weight: 600; color: var(--text-dark); margin-bottom: 8px; }
.brand-item-location { font-size: 13px; color: var(--text-gray); margin-bottom: 10px; }
.brand-item-products { font-size: 12px; color: var(--text-light); margin-bottom: 15px; }
.brand-item-btn { display: inline-block; padding: 8px 24px; border: 1px solid var(--primary); color: var(--primary); border-radius: 20px; font-size: 13px; transition: var(--transition); }
.brand-item:hover .brand-item-btn { background: var(--primary); color: white; }
@media (max-width: 992px) { .brands-list { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 768px) { .brands-list { grid-template-columns: repeat(2, 1fr); gap: 15px; padding: 20px 0; } }
@media (max-width: 480px) { .brands-list { grid-template-columns: 1fr; } }

/* ===== 顶部栏退出按钮（保持链接外观） ===== */
.top-bar .link-btn {
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}
.top-bar .link-btn:hover { color: var(--primary); }

/* ===== 表单校验提示 ===== */
.text-danger,
.field-validation-error { color: var(--secondary); font-size: 12px; }
.validation-summary-errors ul { margin: 0; padding-left: 18px; }
.validation-summary-errors { color: var(--secondary); font-size: 13px; margin-bottom: 12px; }

/* ===== 商家后台：筛选工具栏 ===== */
.dashboard-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.dashboard-toolbar form { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.dashboard-toolbar input[type="text"],
.dashboard-toolbar select {
    padding: 9px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-dark);
}
.btn-primary-sm {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}
.btn-primary-sm:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); color: white; }
.btn-outline-sm {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: white;
    color: var(--text-gray);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}
.btn-outline-sm:hover { border-color: var(--primary); color: var(--primary); }

/* ===== 商家后台：订单/店铺信息展示 ===== */
.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 30px;
}
.info-grid .info-row { display: flex; font-size: 13px; line-height: 1.8; }
.info-grid .info-label { color: var(--text-light); width: 90px; flex-shrink: 0; }
.info-grid .info-value { color: var(--text-dark); flex: 1; word-break: break-all; }
.info-grid .full { grid-column: 1 / -1; }

/* ===== 商家后台：简易柱状趋势图 ===== */
.chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    height: 220px;
    padding: 20px 5px 0;
}
.chart-bar-item { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.chart-bar-value { font-size: 12px; color: var(--text-gray); margin-bottom: 6px; }
.chart-bar {
    width: 100%;
    max-width: 46px;
    background: linear-gradient(180deg, var(--primary-light) 0%, var(--primary) 100%);
    border-radius: 4px 4px 0 0;
    min-height: 3px;
    transition: var(--transition);
}
.chart-bar:hover { background: linear-gradient(180deg, var(--secondary) 0%, var(--secondary-dark) 100%); }
.chart-bar-label { font-size: 12px; color: var(--text-light); margin-top: 8px; }

/* ===== 上传预览 ===== */
.upload-preview {
    margin-top: 12px;
    width: 120px;
    height: 120px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    overflow: hidden;
    display: none;
}
.upload-preview img { width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 768px) {
    .info-grid { grid-template-columns: 1fr; }
    .dashboard-toolbar { flex-direction: column; align-items: stretch; }
    .dashboard-toolbar form { width: 100%; }
    .dashboard-toolbar input[type="text"],
    .dashboard-toolbar select { flex: 1; }
}

/* ===== 头部操作按钮（发布求购 / 采购信息 / 购物车） ===== */
.header-actions .btn-publish,
.header-actions .btn-buy,
.header-actions .btn-cart {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    transition: var(--transition);
}
.header-actions .btn-publish {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff;
}
.header-actions .btn-buy {
    background: #fff;
    color: var(--primary);
    border: 1px solid var(--primary);
}
.header-actions .btn-cart {
    position: relative;
    background: var(--secondary);
    color: #fff;
}
.header-actions .btn-publish:hover,
.header-actions .btn-cart:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
    color: #fff;
}
.header-actions .btn-buy:hover {
    background: var(--primary);
    color: #fff;
}
.header-actions .btn-cart .cart-count {
    position: absolute;
    top: -7px;
    right: -7px;
    min-width: 19px;
    height: 19px;
    padding: 0 5px;
    background: #fff;
    color: var(--secondary);
    border-radius: 10px;
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
    line-height: 19px;
    text-align: center;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

/* ===== 空状态 ===== */
.empty-state {
    text-align: center;
    padding: 70px 20px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}
.empty-state i {
    font-size: 56px;
    color: #d6dbe3;
    display: block;
    margin-bottom: 16px;
}
.empty-state p {
    color: var(--text-gray);
    font-size: 15px;
    margin-bottom: 20px;
}

/* ===== 购物车 ===== */
.cart-page { padding: 25px 0 50px; }
.cart-layout { display: grid; grid-template-columns: 1fr 320px; gap: 22px; align-items: start; }
.cart-panel {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}
.cart-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 22px;
    border-bottom: 1px solid var(--border-color);
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
}
.cart-panel-header .cart-clear {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 13px;
    cursor: pointer;
}
.cart-panel-header .cart-clear:hover { color: var(--secondary); }

.cart-shop-group { border-bottom: 1px solid #f2f4f7; }
.cart-shop-group:last-child { border-bottom: none; }
.cart-shop-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    background: #fafbfc;
    font-size: 13px;
    color: var(--text-dark);
    font-weight: 500;
}
.cart-shop-header i { color: var(--primary); }

.cart-row {
    display: grid;
    grid-template-columns: 84px 1fr 120px 130px 110px 50px;
    gap: 16px;
    align-items: center;
    padding: 16px 22px;
    border-top: 1px solid #f7f8fa;
    font-size: 13px;
}
.cart-row-img {
    width: 84px;
    height: 84px;
    border-radius: var(--radius-sm);
    background: #f5f7fa;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    font-size: 26px;
    color: #c8cfd8;
}
.cart-row-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-row-title {
    color: var(--text-dark);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.cart-row-title:hover { color: var(--primary); }
.cart-row-spec { color: var(--text-light); font-size: 12px; margin-top: 5px; }
.cart-row-price { color: var(--text-gray); }
.cart-row-price strong { color: var(--secondary); font-size: 15px; }

.qty-stepper {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    overflow: hidden;
}
.qty-stepper button {
    width: 30px;
    height: 32px;
    background: #fafbfc;
    border: none;
    color: var(--text-gray);
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
}
.qty-stepper button:hover { background: var(--primary); color: #fff; }
.qty-stepper input {
    width: 52px;
    height: 32px;
    border: none;
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    text-align: center;
    font-size: 13px;
    color: var(--text-dark);
}
.cart-row-remove {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
}
.cart-row-remove:hover { color: var(--secondary); }

.cart-summary {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 22px;
    position: sticky;
    top: 20px;
}
.cart-summary h3 { font-size: 16px; color: var(--text-dark); margin-bottom: 18px; }
.cart-summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-gray);
    padding: 9px 0;
}
.cart-summary-row strong { color: var(--text-dark); font-weight: 500; }
.cart-summary-total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 16px 0;
    margin-top: 8px;
    border-top: 1px dashed var(--border-color);
}
.cart-summary-total span { font-size: 14px; color: var(--text-dark); }
.cart-summary-total strong { font-size: 24px; color: var(--secondary); }
.cart-checkout-btn {
    display: block;
    width: 100%;
    padding: 14px;
    margin-top: 12px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}
.cart-checkout-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); color: #fff; }
.cart-continue {
    display: block;
    text-align: center;
    margin-top: 12px;
    font-size: 13px;
    color: var(--text-gray);
}
.cart-continue:hover { color: var(--primary); }

/* ===== 结算页 ===== */
.checkout-layout { display: grid; grid-template-columns: 1fr 340px; gap: 22px; align-items: start; padding: 25px 0 50px; }
.checkout-block {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 22px;
    margin-bottom: 20px;
}
.checkout-block h3 {
    font-size: 15px;
    color: var(--text-dark);
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}
.checkout-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.checkout-item {
    display: flex;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px dashed #eef0f3;
}
.checkout-item:last-child { border-bottom: none; }
.checkout-item-img {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-sm);
    background: #f5f7fa;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #c8cfd8;
}
.checkout-item-img img { width: 100%; height: 100%; object-fit: cover; }
.checkout-item-info { flex: 1; min-width: 0; }
.checkout-item-info .t { font-size: 13px; color: var(--text-dark); line-height: 1.5; }
.checkout-item-info .s { font-size: 12px; color: var(--text-light); margin-top: 4px; }
.checkout-item-price { text-align: right; font-size: 13px; color: var(--text-gray); white-space: nowrap; }
.checkout-item-price strong { display: block; color: var(--secondary); font-size: 15px; }

.pay-methods { display: flex; gap: 12px; flex-wrap: wrap; }
.pay-method {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 13px;
    color: var(--text-gray);
    transition: var(--transition);
}
.pay-method:hover { border-color: var(--primary); }
.pay-method.active { border-color: var(--secondary); color: var(--secondary); background: rgba(230, 57, 70, 0.04); }
.pay-method i { font-size: 18px; }

/* 结算页 · 优惠券选择 */
.coupon-pick { display: flex; flex-direction: column; gap: 10px; }
.coupon-pick-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}
.coupon-pick-item:hover { border-color: var(--primary); }
.coupon-pick-item.active { border-color: var(--secondary); background: rgba(230, 57, 70, 0.04); }
.coupon-pick-item input { margin: 0; accent-color: var(--secondary); }
.coupon-pick-none { font-size: 13px; color: var(--text-gray); }
.coupon-pick-value {
    flex: 0 0 auto;
    min-width: 64px;
    text-align: center;
    font-size: 16px;
    font-weight: 700;
    color: var(--secondary);
}
.coupon-pick-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.coupon-pick-name { font-size: 13px; font-weight: 600; color: var(--text-dark); }
.coupon-pick-cond { font-size: 12px; color: var(--text-light); }

/* ===== 订单列表 / 详情 ===== */
.order-tabs {
    display: flex;
    gap: 4px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 6px;
    margin-bottom: 20px;
    overflow-x: auto;
}
.order-tab {
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--text-gray);
    white-space: nowrap;
    transition: var(--transition);
}
.order-tab:hover { color: var(--primary); }
.order-tab.active { background: var(--primary); color: #fff; }
.order-tab em {
    font-style: normal;
    font-size: 12px;
    margin-left: 4px;
    opacity: 0.85;
}

.order-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    margin-bottom: 16px;
    overflow: hidden;
}
.order-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 13px 20px;
    background: #fafbfc;
    border-bottom: 1px solid var(--border-color);
    font-size: 13px;
    color: var(--text-gray);
    flex-wrap: wrap;
}
.order-card-header .no { color: var(--text-dark); font-weight: 500; }
.order-card-header .shop { color: var(--primary); }
.order-card-body { padding: 6px 20px; }
.order-line {
    display: flex;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px dashed #eef0f3;
}
.order-line:last-child { border-bottom: none; }
.order-line-img {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-sm);
    background: #f5f7fa;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #c8cfd8;
}
.order-line-img img { width: 100%; height: 100%; object-fit: cover; }
.order-line-info { flex: 1; min-width: 0; }
.order-line-info .t { font-size: 13px; color: var(--text-dark); line-height: 1.5; }
.order-line-info .s { font-size: 12px; color: var(--text-light); margin-top: 4px; }
.order-line-price { text-align: right; font-size: 13px; color: var(--text-gray); white-space: nowrap; }
.order-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}
.order-card-total { font-size: 13px; color: var(--text-gray); }
.order-card-total strong { font-size: 19px; color: var(--secondary); margin-left: 4px; }
.order-card-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.order-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    border: 1px solid var(--border-color);
    background: #fff;
    color: var(--text-gray);
    cursor: pointer;
    transition: var(--transition);
}
.order-btn:hover { border-color: var(--primary); color: var(--primary); }
.order-btn.primary {
    background: var(--secondary);
    border-color: var(--secondary);
    color: #fff;
}
.order-btn.primary:hover { background: var(--secondary-dark); border-color: var(--secondary-dark); color: #fff; }

.order-status { font-weight: 600; }
.order-status.s10 { color: #e67e22; }
.order-status.s20 { color: #0d3b8c; }
.order-status.s30 { color: #2980b9; }
.order-status.s40 { color: #27ae60; }
.order-status.s50 { color: #95a5a6; }

.order-progress {
    display: flex;
    gap: 0;
    padding: 20px 0 6px;
    margin-bottom: 20px;
}
.order-progress-step {
    flex: 1;
    text-align: center;
    position: relative;
    font-size: 12px;
    color: var(--text-light);
}
.order-progress-step::before {
    content: '';
    position: absolute;
    top: 13px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e8ebef;
}
.order-progress-step:first-child::before { left: 50%; }
.order-progress-step:last-child::before { right: 50%; }
.order-progress-step i {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #e8ebef;
    color: #fff;
    font-size: 14px;
    margin-bottom: 8px;
}
.order-progress-step.done { color: var(--primary); }
.order-progress-step.done i { background: var(--primary); }

/* ===== 收藏页 ===== */
.favorite-card { position: relative; }
.favorite-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 3;
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    color: var(--text-gray);
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.12);
    transition: var(--transition);
}
.favorite-remove:hover { background: var(--secondary); color: #fff; }

/* 详情页收藏按钮 */
.favorite-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fff;
    color: var(--text-gray);
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
}
.favorite-toggle:hover { border-color: var(--secondary); color: var(--secondary); }
.favorite-toggle.active { border-color: var(--secondary); color: var(--secondary); background: rgba(230, 57, 70, 0.05); }

@media (max-width: 1100px) {
    .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
    .cart-summary { position: static; }
}
@media (max-width: 768px) {
    .cart-row {
        grid-template-columns: 70px 1fr;
        grid-template-areas:
            "img title"
            "img price"
            "qty subtotal"
            "rm rm";
        row-gap: 10px;
    }
    .cart-row-img { grid-area: img; width: 70px; height: 70px; }
    .cart-row-title { grid-area: title; }
    .cart-row-price { grid-area: price; }
    .cart-row .qty-stepper { grid-area: qty; }
    .cart-row-subtotal { grid-area: subtotal; text-align: right; }
    .cart-row-remove { grid-area: rm; justify-self: end; }
    .checkout-form-row { grid-template-columns: 1fr; }
    .header-actions .btn-publish span,
    .header-actions .btn-buy span { display: none; }
}

/* ============================================================
   交易提示：页面顶部提示条 + 轻提示 Toast
   ============================================================ */
.flash-message {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 16px 0 0;
    padding: 12px 18px;
    border-radius: var(--radius-md);
    font-size: 14px;
    transition: opacity .35s ease, transform .35s ease;
}
.flash-success {
    background: #eafaf1;
    color: #1e8449;
    border: 1px solid #b7e4c7;
}
.flash-error {
    background: #fdecea;
    color: #c0392b;
    border: 1px solid #f5c6cb;
}
.flash-message i { font-size: 18px; }

.cm-toast-wrap {
    position: fixed;
    top: 84px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    pointer-events: none;
}
.cm-toast {
    padding: 11px 22px;
    border-radius: 30px;
    font-size: 14px;
    color: #fff;
    background: rgba(30, 41, 59, .92);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
    opacity: 0;
    transform: translateY(-12px);
    transition: opacity .3s ease, transform .3s ease;
    white-space: nowrap;
}
.cm-toast.show { opacity: 1; transform: translateY(0); }
.cm-toast.success { background: rgba(39, 174, 96, .96); }
.cm-toast.error { background: rgba(214, 69, 69, .96); }

@media (max-width: 768px) {
    .header-actions .btn-cart span { display: none; }
    .cm-toast-wrap { top: 70px; width: 90%; }
    .cm-toast { white-space: normal; text-align: center; }
}

/* ============================================================
   布局骨架补全：顶栏 / 头部搜索 / 主导航 / 页脚 / 浮动工具栏
   （对应 _Layout.cshtml 中的结构类名）
   ============================================================ */

/* 顶栏内层容器 */
.top-bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 15px;
}

/* 头部主行：logo + 搜索（标签/输入/热搜）+ 操作按钮 */
.header-main {
    height: auto;
    min-height: 90px;
    padding: 10px 0;
}

.logo a {
    display: flex;
    align-items: center;
}

.logo-title i {
    font-size: 24px;
    margin-right: 6px;
}

/* 搜索区 */
.search-box {
    flex: 1;
    max-width: 560px;
    height: auto;
    border: none;
    border-radius: 0;
    overflow: visible;
    display: block;
}

.search-tabs {
    display: flex;
    gap: 2px;
}

.search-tabs a,
.search-tabs .search-tab {
    padding: 7px 18px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-gray);
    background: #eef1f5;
    border-radius: 8px 8px 0 0;
    cursor: pointer;
}

.search-tabs .search-tab {
    border: none;
    font-family: inherit;
    line-height: 1.4;
    transition: var(--transition);
}

.search-tabs .search-tab:hover {
    color: var(--primary);
}

.search-tabs a.active,
.search-tabs .search-tab.active {
    background: var(--primary);
    color: #fff;
}

.search-input-wrap {
    display: flex;
    height: 42px;
    border: 2px solid var(--primary);
    border-radius: 0 8px 8px 8px;
    overflow: hidden;
    background: #fff;
}

.search-input-wrap input {
    flex: 1;
    min-width: 0;
    padding: 0 15px;
    font-size: 14px;
}

.search-input-wrap select {
    padding: 0 12px;
    background: #f8f9fa;
    color: var(--text-dark);
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    cursor: pointer;
    font-size: 13px;
}

.search-input-wrap button {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 26px;
    background: var(--primary);
    color: #fff;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
}

.search-input-wrap button:hover {
    background: var(--primary-dark);
}

.hot-search {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
    margin-top: 8px;
    font-size: 12px;
    color: var(--text-light);
}

.hot-search a {
    color: var(--text-gray);
}

.hot-search a:hover {
    color: var(--secondary);
}

/* 移动端头部图标按钮（桌面隐藏） */
.search-toggle {
    display: none;
    font-size: 20px;
    color: var(--primary);
    cursor: pointer;
    padding: 8px;
}

/* 导航内层 */
.nav-inner {
    display: flex;
    align-items: center;
    width: 100%;
    height: 100%;
}

.nav-categories > i:last-of-type {
    margin-left: auto;
    font-size: 12px;
}

/* 分类下拉项（ul/li 结构） */
.category-sidebar li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    font-size: 14px;
    color: var(--text-dark);
    border-bottom: 1px solid #f0f0f0;
}

.category-sidebar li a i {
    width: 16px;
    font-size: 13px;
    color: var(--text-light);
}

.category-sidebar li a:hover {
    background: var(--bg-light);
    color: var(--primary);
    padding-left: 25px;
}

.category-sidebar li a:hover i {
    color: var(--primary);
}

.category-sidebar li:last-child a {
    border-bottom: none;
}

/* 页脚补充 */
.footer-about h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
}

.qrcode-placeholder {
    background: rgba(255, 255, 255, .06);
    border: 1px dashed rgba(255, 255, 255, .25);
    border-radius: var(--radius-md);
    padding: 16px 10px;
    text-align: center;
}

.qrcode-placeholder i {
    font-size: 44px;
    color: rgba(255, 255, 255, .55);
}

.qrcode-placeholder p {
    margin-top: 8px;
    font-size: 12px;
    color: rgba(255, 255, 255, .55);
}

.social-links {
    display: flex;
    gap: 10px;
    margin-top: 14px;
}

.social-links a {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .08);
    color: rgba(255, 255, 255, .7);
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-links a:hover {
    background: var(--secondary);
    color: #fff;
}

.footer-links {
    margin-top: 8px;
}

/* ============================================================
   平台管理后台（Admin）专属样式
   ============================================================ */

/* 后台顶栏：深蓝主题，与侧边栏用户卡呼应，区别于前台灰色工具条 */
.admin-top-bar {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    border-bottom: none;
    color: rgba(255, 255, 255, 0.92);
}
.admin-top-bar .top-bar-left {
    font-weight: 500;
}
.admin-top-bar .top-bar-left i {
    font-size: 15px;
}
.admin-top-bar a,
.admin-top-bar .link-btn {
    color: rgba(255, 255, 255, 0.92);
}
.admin-top-bar a:hover,
.admin-top-bar .link-btn:hover {
    color: #fff;
    text-decoration: none;
}
.admin-top-bar .top-bar-right {
    gap: 18px;
}

/* 宽表格在窄容器内横向滚动，避免撑破卡片 */
.dashboard-card-body {
    overflow-x: auto;
}

/* 单元格内「标签 + 文本」混排：标签不换行错位，文本可截断 */
.cell-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}
.cell-tags .product-tag {
    position: static;
    flex-shrink: 0;
    font-size: 11px;
    line-height: 1.5;
}
.cell-tags .cell-text {
    flex: 1;
    min-width: 0;
}
.cell-clamp {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-all;
}

/* 缩略图为空时的占位样式 */
.product-thumb-img.empty {
    color: var(--text-light);
    background: var(--bg-light);
}

/* 二级分类行：缩进 + 层级引导线 */
.data-table tr.row-sub td {
    background: var(--bg-light);
}
.data-table tr.row-sub td:first-child {
    padding-left: 40px;
}
.data-table .sub-indent {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-gray);
}
.data-table .sub-indent::before {
    content: "└";
    color: var(--text-light);
    font-family: monospace;
}

/* 后台总览：双栏卡片，窄屏自动堆叠 */
.admin-split-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
}
@media (max-width: 992px) {
    .admin-split-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== 元器件筛选：品牌 / 封装标签 ===== */
.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.filter-tag {
    display: inline-block;
    padding: 4px 10px;
    font-size: 12px;
    color: var(--text-gray);
    background: #f5f6f8;
    border: 1px solid var(--border-color);
    border-radius: 3px;
    transition: var(--transition);
    white-space: nowrap;
}

.filter-tag:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: #fff;
}

.filter-tag.active {
    color: #fff;
    background: var(--primary);
    border-color: var(--primary);
}

/* ===== 元器件商品卡片：型号 / 替代标签 ===== */
.product-model {
    font-size: 12px;
    color: var(--text-gray);
    font-family: monospace;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-model i {
    color: var(--primary);
}

.product-alt-tag {
    margin-top: 8px;
    font-size: 11px;
    color: #27ae60;
    background: #eafaf1;
    border: 1px solid #c8eeda;
    border-radius: 3px;
    padding: 2px 6px;
    display: inline-block;
}

/* ===== 元器件详情：阶梯价表 ===== */
.tier-price-table {
    width: 100%;
    border-collapse: collapse;
    margin: 8px 0;
    font-size: 13px;
}

.tier-price-table th,
.tier-price-table td {
    border: 1px solid var(--border-color);
    padding: 6px 10px;
    text-align: center;
}

.tier-price-table th {
    background: #f7f8fa;
    color: var(--text-gray);
    font-weight: 500;
}

.tier-price-table td.tier-price {
    color: var(--secondary);
    font-weight: 600;
}

/* ===== 元器件详情：参数分组 / 替代料 ===== */
.param-group-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    padding: 8px 0 6px;
    border-bottom: 1px dashed var(--border-color);
    margin-bottom: 4px;
}

.alt-solution {
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 12px 14px;
    margin-bottom: 10px;
    background: #fafbfc;
}

.alt-solution-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.alt-solution-model {
    font-family: monospace;
    font-weight: 600;
    color: var(--primary);
}

.alt-solution-remark {
    font-size: 13px;
    color: var(--text-gray);
}

.component-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 10px 0 4px;
}

.component-badge {
    font-size: 12px;
    padding: 3px 8px;
    border-radius: 3px;
    background: #eef3ff;
    color: var(--primary);
    border: 1px solid #d6e2ff;
}

.component-badge.green {
    background: #eafaf1;
    color: #27ae60;
    border-color: #c8eeda;
}

/* ===== 搜索联想下拉 ===== */
.search-suggest {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 0 0 4px 4px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
    z-index: 60;
    max-height: 360px;
    overflow-y: auto;
    display: none;
}

.search-suggest.open {
    display: block;
}

.search-suggest-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f2f3f5;
}

.search-suggest-item:last-child {
    border-bottom: none;
}

.search-suggest-item:hover {
    background: #f7f9ff;
}

.search-suggest-thumb {
    width: 36px;
    height: 36px;
    border-radius: 3px;
    background: #f2f3f5;
    object-fit: cover;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.search-suggest-body {
    min-width: 0;
    flex: 1;
}

.search-suggest-title {
    font-size: 13px;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-suggest-sub {
    font-size: 12px;
    color: var(--text-gray);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-suggest-sub .model {
    font-family: monospace;
    color: var(--primary);
}

.search-suggest-price {
    font-size: 13px;
    color: var(--secondary);
    font-weight: 600;
    flex-shrink: 0;
}

.search-suggest-empty {
    padding: 14px;
    text-align: center;
    color: var(--text-light);
    font-size: 13px;
}

.search-input-wrap {
    position: relative;
}


/* 后台详情页：迷你统计栅格 */
.admin-mini-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}
@media (max-width: 768px) {
    .admin-mini-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 移动端保留后台顶栏（覆盖 responsive.css 中对 .top-bar 的隐藏规则） */
@media (max-width: 992px) {
    .top-bar.admin-top-bar {
        display: block;
    }
    .admin-top-bar .container {
        height: auto;
        min-height: 40px;
        padding-top: 6px;
        padding-bottom: 6px;
    }
    .admin-top-bar .top-bar-inner {
        flex-wrap: wrap;
        row-gap: 4px;
    }
    .admin-top-bar .top-bar-left,
    .admin-top-bar .top-bar-right {
        gap: 12px;
    }
}

/* 窄屏：后台页头改为纵向排列，卡片内边距收紧 */
@media (max-width: 576px) {
    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 16px 18px;
    }
    .dashboard-card-body {
        padding: 14px 15px;
    }
}

/* ============================================================
   求购报价（供应商报价 / 采购方处理）
   ============================================================ */

/* 报价页顶部：被报价的求购摘要 */
.quote-summary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff;
    border-radius: var(--radius-md);
    padding: 20px 25px;
    margin-bottom: 24px;
}
.quote-summary-label {
    font-size: 12px;
    opacity: .8;
    margin-bottom: 6px;
}
.quote-summary-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}
.quote-summary-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 22px;
    font-size: 13px;
    opacity: .95;
}
.quote-summary-meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* 报价列表 */
.quote-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.quote-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--primary);
    border-radius: var(--radius-md);
    padding: 18px 22px;
    transition: var(--transition);
}
.quote-item:hover {
    box-shadow: var(--shadow-md);
}
.quote-item.accepted {
    border-left-color: #27ae60;
    background: #f6fdf8;
}
.quote-item.rejected {
    border-left-color: #d5d8dc;
    opacity: .75;
}
.quote-main {
    flex: 1;
    min-width: 0;
}
.quote-head {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 8px;
}
.quote-company {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
}
.quote-flag {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 10px;
    font-size: 12px;
    line-height: 1.6;
}
.quote-flag.pending {
    background: #fff4e5;
    color: #e67e22;
}
.quote-flag.accepted {
    background: #e8f5e9;
    color: #27ae60;
}
.quote-flag.rejected {
    background: #f0f1f2;
    color: var(--text-light);
}
.quote-price {
    font-size: 22px;
    font-weight: bold;
    color: var(--secondary);
    margin-bottom: 10px;
}
.quote-price-unit {
    font-size: 13px;
    font-weight: normal;
    color: var(--text-gray);
}
.quote-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 20px;
    font-size: 12px;
    color: var(--text-light);
}
.quote-meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.quote-remark {
    margin-top: 10px;
    padding: 10px 14px;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-gray);
    line-height: 1.7;
    word-break: break-word;
}
.quote-side {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
}
.quote-act {
    padding: 7px 18px;
    font-size: 13px;
}

@media (max-width: 768px) {
    .quote-item {
        flex-direction: column;
    }
    .quote-side {
        flex-direction: row;
        width: 100%;
    }
    .quote-side form {
        flex: 1;
    }
    .quote-act {
        width: 100%;
    }
}

/* ===== 结算页：收货地址选择 ===== */
.addr-list {
    display: grid;
    gap: 12px;
    margin-bottom: 14px;
}
.addr-card {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: #fff;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}
.addr-card:hover { border-color: var(--primary-light); box-shadow: var(--shadow-sm); }
.addr-card.active {
    border-color: var(--primary);
    background: rgba(13, 59, 140, 0.04);
    box-shadow: 0 0 0 1px var(--primary) inset;
}
.addr-card-check {
    font-size: 20px;
    line-height: 1.3;
    color: var(--border-color);
    flex-shrink: 0;
    transition: var(--transition);
}
.addr-card.active .addr-card-check { color: var(--primary); }
.addr-card-main { flex: 1; min-width: 0; }
.addr-card-top {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 5px;
}
.addr-name { font-size: 14px; font-weight: 600; color: var(--text-dark); }
.addr-phone { font-size: 13px; color: var(--text-gray); }
.addr-default {
    font-size: 11px;
    color: var(--secondary);
    border: 1px solid var(--secondary);
    border-radius: var(--radius-sm);
    padding: 0 6px;
    line-height: 18px;
}
.addr-full {
    font-size: 13px;
    color: var(--text-gray);
    line-height: 1.6;
    word-break: break-all;
}
.addr-edit {
    flex-shrink: 0;
    align-self: center;
    border: 1px solid var(--border-color);
    background: #fff;
    color: var(--text-gray);
    font-size: 12px;
    padding: 5px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}
.addr-edit:hover { border-color: var(--primary); color: var(--primary); }
.addr-new-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px dashed var(--primary);
    background: #fff;
    color: var(--primary);
    font-size: 13px;
    padding: 9px 18px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
}
.addr-new-btn:hover { background: rgba(13, 59, 140, 0.06); }

.addr-form {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px dashed var(--border-color);
}
.addr-form-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 14px;
}
.region-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.region-row select { width: 100%; }
.field-error { display: block; margin-top: 6px; font-size: 12px; color: var(--secondary); }
.addr-options {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
    margin-top: 14px;
}
.addr-chk {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    color: var(--text-gray);
    cursor: pointer;
}
.addr-chk input { width: auto; margin: 0; }

@media (max-width: 768px) {
    .region-row { grid-template-columns: 1fr; }
    .addr-edit { align-self: flex-start; }
}

/* ============================================================
   会员中心 · 积分 / 优惠券 / 站内消息 / 积分商城
   ============================================================ */
.member-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff;
    border-radius: var(--radius-lg);
    padding: 24px 26px;
    box-shadow: var(--shadow-md);
}
.member-hero-left { display: flex; align-items: center; gap: 16px; }
.member-level-icon {
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 26px;
}
.member-level-name { font-size: 20px; font-weight: 700; letter-spacing: 0.5px; }
.member-level-tip { font-size: 13px; opacity: 0.88; margin-top: 4px; }
.member-hero-right { text-align: right; }
.member-points-num { font-size: 34px; font-weight: 700; line-height: 1.1; color: var(--gold); }
.member-points-label { font-size: 12px; opacity: 0.88; margin-top: 2px; }
.member-progress {
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.22);
    overflow: hidden;
    margin-top: 14px;
}
.member-progress-bar { height: 100%; width: 100%; }
.member-progress-bar > span {
    display: block;
    height: 100%;
    background: var(--gold);
    border-radius: 999px;
    transition: width 0.4s ease;
}

.member-stat-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}
.member-stat {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 18px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}
.member-stat .v { font-size: 24px; font-weight: 700; color: var(--primary); }
.member-stat .k { font-size: 12px; color: var(--text-gray); margin-top: 4px; }

/* 优惠券 */
.coupon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 14px;
}
.coupon-card {
    display: flex;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}
.coupon-card:hover { box-shadow: var(--shadow-md); }
.coupon-card.disabled { opacity: 0.62; filter: grayscale(0.35); }
.coupon-left {
    width: 118px;
    flex: 0 0 118px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 14px 8px;
}
.coupon-card.disabled .coupon-left { background: #b9bcc4; }
.coupon-value { font-size: 24px; font-weight: 700; line-height: 1.1; }
.coupon-scope { font-size: 11px; opacity: 0.9; margin-top: 6px; text-align: center; }
.coupon-right { flex: 1; min-width: 0; padding: 14px 16px; }
.coupon-name { font-size: 15px; font-weight: 600; color: var(--text-dark); }
.coupon-meta { font-size: 12px; color: var(--text-gray); margin-top: 4px; }
.coupon-state { margin-top: 10px; }

/* 站内消息 */
.msg-list { display: flex; flex-direction: column; }
.msg-item {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 16px 4px;
    border-bottom: 1px solid var(--border-color);
}
.msg-item:last-child { border-bottom: none; }
.msg-item.unread { background: rgba(13, 59, 140, 0.03); }
.msg-icon {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    background: rgba(13, 59, 140, 0.08);
    color: var(--primary);
}
.msg-icon.t1 { background: rgba(13, 59, 140, 0.08); color: var(--primary); }
.msg-icon.t2 { background: rgba(212, 175, 55, 0.16); color: #a8862a; }
.msg-icon.t3 { background: rgba(230, 57, 70, 0.1); color: var(--secondary); }
.msg-icon.t4 { background: rgba(26, 82, 118, 0.1); color: var(--primary-light); }
.msg-body { flex: 1; min-width: 0; }
.msg-title { font-size: 14px; font-weight: 600; color: var(--text-dark); display: flex; align-items: center; gap: 8px; }
.msg-dot {
    font-size: 11px;
    font-weight: 500;
    color: #fff;
    background: var(--secondary);
    padding: 1px 7px;
    border-radius: 999px;
}
.msg-content { font-size: 13px; color: var(--text-gray); margin-top: 5px; word-break: break-word; }
.msg-meta { font-size: 12px; color: var(--text-light); margin-top: 6px; }
.msg-action { flex: 0 0 auto; }

/* 积分商城 */
.point-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 16px;
}
.point-card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}
.point-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.point-card-img {
    height: 150px;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 44px;
    color: var(--text-light);
    overflow: hidden;
}
.point-card-img img { width: 100%; height: 100%; object-fit: cover; }
.point-card-body { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 14px; }
.point-card-name { font-size: 14px; font-weight: 600; color: var(--text-dark); }
.point-card-desc {
    font-size: 12px;
    color: var(--text-gray);
    min-height: 34px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.point-card-foot { display: flex; align-items: center; justify-content: space-between; margin-top: auto; }
.point-price { display: inline-flex; align-items: center; gap: 4px; color: var(--secondary); font-weight: 700; }

/* ============================================================
   在线支付
   ============================================================ */
.pay-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    box-shadow: var(--shadow-sm);
}
.pay-head-title { font-size: 16px; font-weight: 600; color: var(--text-dark); }
.pay-head-amount { text-align: right; }
.pay-head-amount span { display: block; font-size: 12px; color: var(--text-gray); }
.pay-head-amount strong { font-size: 26px; color: var(--secondary); }
.pay-fee-line { display: flex; gap: 20px; flex-wrap: wrap; padding: 12px 4px 0; font-size: 13px; color: var(--text-gray); }
.pay-result-block { text-align: center; padding: 34px 20px; }
.pay-result-ok { font-size: 54px; color: #22a06b; }
.pay-qr-wrap { display: flex; gap: 26px; flex-wrap: wrap; align-items: flex-start; margin-top: 6px; }
.pay-qr {
    width: 200px;
    height: 200px;
    flex: 0 0 200px;
    padding: 8px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
}
.pay-qr svg { display: block; width: 100%; height: 100%; }
.pay-qr-info { flex: 1; min-width: 240px; }
.pay-qr-amount { font-size: 28px; font-weight: 700; color: var(--secondary); margin-bottom: 10px; }
.pay-qr-line { font-size: 13px; color: var(--text-gray); margin-top: 6px; word-break: break-all; }
.pay-qr-line code {
    background: var(--bg-light);
    padding: 1px 6px;
    border-radius: var(--radius-sm);
    font-family: Consolas, Monaco, monospace;
    font-size: 12px;
    color: var(--text-dark);
}
.pay-qr-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 14px;
    padding: 7px 14px;
    font-size: 13px;
    border-radius: 999px;
    background: rgba(13, 59, 140, 0.07);
    color: var(--primary);
}
.pay-qr-status.ok { background: rgba(34, 160, 107, 0.12); color: #22a06b; }
.pay-sandbox-tip {
    margin-top: 14px;
    padding: 11px 14px;
    font-size: 12.5px;
    line-height: 1.7;
    color: #8a6d1f;
    background: rgba(212, 175, 55, 0.1);
    border: 1px dashed rgba(212, 175, 55, 0.5);
    border-radius: var(--radius-sm);
}

/* ============================================================
   售后处理进度时间轴
   ============================================================ */
.order-timeline { position: relative; padding-left: 6px; }
.timeline-item { position: relative; padding: 0 0 20px 22px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
    content: "";
    position: absolute;
    left: 5px;
    top: 14px;
    bottom: -6px;
    width: 1px;
    background: var(--border-color);
}
.timeline-item:last-child::before { display: none; }
.timeline-dot {
    position: absolute;
    left: 0;
    top: 5px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--primary);
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px var(--primary);
}
.timeline-remark { font-size: 13px; color: var(--text-dark); }
.timeline-meta { font-size: 12px; color: var(--text-light); margin-top: 3px; }

@media (max-width: 768px) {
    .member-stat-row { grid-template-columns: repeat(2, 1fr); }
    .member-hero-right { text-align: left; }
    .pay-qr { flex: 0 0 auto; margin: 0 auto; }
    .msg-item { flex-wrap: wrap; }
    .msg-action { margin-left: 56px; }
}

/* ============================================================
   支付配置（后台） / 对公转账收款账户 / 联系方式名片
   ============================================================ */
.pay-cfg-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: start;
}

.pay-cfg-form .form-group { margin-bottom: 14px; }

.pay-cfg-hint {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: var(--text-light);
    line-height: 1.6;
}

.pay-cfg-guide {
    background: #f7f9fc;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 18px;
    font-size: 13px;
    color: var(--text-gray);
    line-height: 1.9;
}

.pay-cfg-guide h4 {
    font-size: 14px;
    color: var(--text-dark);
    margin: 0 0 8px;
}

.pay-cfg-guide p { margin: 0 0 8px; }

.pay-cfg-guide ol {
    margin: 0 0 8px;
    padding-left: 18px;
}

.pay-cfg-guide li { margin-bottom: 4px; }

.pay-cfg-guide code {
    background: #eef2f8;
    border-radius: 3px;
    padding: 1px 5px;
    font-size: 12px;
    color: var(--primary);
    word-break: break-all;
}

.pay-cfg-note {
    background: #fff8e6;
    border: 1px solid #ffe0a3;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 12px;
    color: #8a6100;
    margin-top: 10px;
}

/* 对公转账收款账户 */
.pay-bank-box {
    margin-top: 14px;
    border: 1px dashed var(--primary);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    background: #f7fbff;
}

.pay-bank-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.pay-bank-note {
    margin-top: 10px;
    font-size: 12px;
    color: var(--text-gray);
    line-height: 1.7;
}

/* 联系方式名片图片 */
.contact-card-img {
    display: block;
    width: 100%;
    max-width: 420px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    margin-bottom: 18px;
}

.footer-contact-card { margin-top: 14px; }

.footer-contact-card img {
    display: block;
    width: 100%;
    max-width: 240px;
    border-radius: 6px;
}

@media (max-width: 768px) {
    .pay-cfg-grid { grid-template-columns: 1fr; }
}

