/* =====================================================
   聚龙网络科技 - 全新模板风样式
   设计参考：成都安惠汇朗商贸商城风格
   ===================================================== */

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

body {
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  background: #f5f5f5;
  color: #333;
  line-height: 1.5;
  min-height: 100vh;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { display: block; max-width: 100%; }

.container {
  width: 1200px;
  margin: 0 auto;
  padding: 0 10px;
}

/* ========== 顶部欢迎条 ========== */
.top-welcome {
  background: #f2f2f2;
  border-bottom: 1px solid #e6e6e6;
  height: 30px;
  line-height: 30px;
  font-size: 12px;
  color: #666;
}
.top-welcome .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.top-welcome .right a {
  margin-left: 18px;
  color: #666;
}
.top-welcome .right a:hover { color: #e53935; }
.top-welcome .right .sep { color: #ccc; margin-left: 0; margin-right: 0; }

/* ========== Logo + 搜索 + 购物车 ========== */
.header-main {
  background: #fff;
  padding: 18px 0;
}
.header-main .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-block {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 260px;
}
.logo-circle {
  width: 58px; height: 58px;
  background: linear-gradient(135deg, #1a3a6b, #2563eb);
  border-radius: 50%;
  color: #fff;
  font-weight: 900;
  font-size: 22px;
  display: flex; align-items: center; justify-content: center;
  letter-spacing: -1px;
}
.logo-block .name h1 {
  font-size: 22px;
  color: #1a3a6b;
  font-weight: 700;
  line-height: 1.15;
}
.logo-block .name p {
  font-size: 12px;
  color: #888;
  margin-top: 3px;
}

.search-wrap {
  display: flex;
  width: 540px;
  border: 2px solid #e53935;
  height: 40px;
}
.search-wrap select {
  border: none;
  border-right: 1px solid #ddd;
  padding: 0 10px;
  background: #fafafa;
  font-size: 13px;
  color: #555;
  outline: none;
  cursor: pointer;
}
.search-wrap input {
  flex: 1;
  border: none;
  padding: 0 14px;
  font-size: 13px;
  outline: none;
}
.search-wrap button {
  width: 90px;
  border: none;
  background: #e53935;
  color: #fff;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  letter-spacing: 4px;
}
.search-wrap button:hover { background: #d32f2f; }

.cart-wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 13px;
  color: #555;
  width: 260px;
  justify-content: flex-end;
}
.cart-wrap .user-info {
  display: flex; align-items: center; gap: 6px;
  cursor: pointer;
}
.cart-wrap .user-info:hover { color: #e53935; }
.cart-wrap .user-info .arrow { font-size: 10px; }
.cart-wrap .cart-btn {
  display: flex; align-items: center; gap: 6px;
  background: #fff8f8;
  border: 1px solid #ffd6d6;
  padding: 8px 16px;
  border-radius: 4px;
  color: #e53935;
  font-weight: 500;
  cursor: pointer;
}
.cart-wrap .cart-btn:hover {
  background: #ffe8e8;
}
.cart-wrap .cart-btn .cart-ic {
  font-size: 16px;
}

/* ========== 分类导航 Tab ========== */
.nav-tabs {
  background: #fff;
  border-bottom: 2px solid #e53935;
}
.nav-tabs .container {
  display: flex;
  gap: 28px;
}
.nav-tabs a {
  padding: 14px 4px 12px;
  font-size: 15px;
  color: #333;
  position: relative;
  cursor: pointer;
  font-weight: 500;
}
.nav-tabs a:hover { color: #e53935; }
.nav-tabs a.active {
  color: #e53935;
  font-weight: 600;
}
.nav-tabs a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 3px;
  background: #e53935;
}

/* ========== 全宽 Banner ========== */
.banner-full {
  width: 100%;
  height: 360px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #6b46c1 0%, #5b3aa1 50%, #4a2f8f 100%);
}
.banner-full::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 80%, rgba(255,255,255,0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(255,255,255,0.06) 0%, transparent 50%);
  pointer-events: none;
}
/* 漂浮金币/光晕 */
.banner-full .float {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
.banner-full .coin {
  width: 50px; height: 50px;
  background: radial-gradient(circle at 30% 30%, #ffd700, #f59e0b);
  box-shadow: 0 0 20px rgba(255,215,0,0.6);
  animation: coinFloat 4s ease-in-out infinite;
}
.banner-full .coin.c1 { top: 60px; left: 42%; animation-delay: 0s; }
.banner-full .coin.c2 { top: 180px; left: 10%; animation-delay: 1s; width: 36px; height: 36px; }
.banner-full .coin.c3 { top: 220px; left: 85%; animation-delay: 2s; }
.banner-full .coin.c4 { top: 120px; left: 92%; animation-delay: 0.5s; width: 30px; height: 30px; }

@keyframes coinFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-15px) rotate(20deg); }
}

.banner-full .lamp {
  position: absolute;
  width: 160px; height: 160px;
  background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}
.banner-full .lamp.l1 { top: 30px; left: 200px; }
.banner-full .lamp.l2 { bottom: 40px; right: 220px; width: 120px; height: 120px; }
.banner-full .lamp.l3 { top: 100px; right: 80px; width: 80px; height: 80px; }

.banner-content {
  position: relative;
  width: 1200px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  padding: 0 20px;
}
.banner-content .promo {
  flex: 1;
  color: #fff;
  text-align: center;
}
.banner-content .promo .tag {
  display: inline-block;
  background: #fff;
  color: #5b3aa1;
  padding: 6px 22px;
  border-radius: 30px;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 14px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}
.banner-content .promo h2 {
  font-size: 52px;
  font-weight: 900;
  margin-bottom: 10px;
  letter-spacing: 4px;
  text-shadow: 0 4px 20px rgba(0,0,0,0.25);
}
.banner-content .promo h2 span {
  color: #ffd700;
}
.banner-content .promo .desc {
  font-size: 16px;
  opacity: 0.92;
  margin-bottom: 22px;
}
.banner-content .promo .btn-act {
  background: linear-gradient(90deg, #ff8c00, #ff6347);
  color: #fff;
  border: none;
  padding: 14px 50px;
  font-size: 18px;
  font-weight: 700;
  border-radius: 40px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(255,99,71,0.45);
  transition: transform 0.2s;
}
.banner-content .promo .btn-act:hover { transform: translateY(-2px); }

/* Banner 产品浮窗 */
.banner-products {
  position: absolute;
  right: 60px;
  bottom: -20px;
  width: 580px;
  height: 300px;
}
.banner-products .bp-item {
  position: absolute;
  background: #fff;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  animation: bpFloat 4s ease-in-out infinite;
}
.banner-products .bp-item img {
  width: 70px; height: 70px; object-fit: cover;
  border-radius: 6px;
}
.banner-products .bp-item.bp1 {
  top: 0; left: 0; animation-delay: 0s;
}
.banner-products .bp-item.bp2 {
  top: 40px; left: 140px; animation-delay: 1s;
}
.banner-products .bp-item.bp3 {
  top: 120px; left: 0; animation-delay: 0.5s;
}
.banner-products .bp-item.bp4 {
  top: 140px; left: 180px; animation-delay: 1.5s;
  width: 180px; padding: 14px;
}
.banner-products .bp-item.bp4 img { width: 100%; height: 120px; }
@keyframes bpFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

/* Banner 小圆点指示器 */
.banner-dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}
.banner-dots span {
  width: 10px; height: 10px;
  background: rgba(255,255,255,0.5);
  border-radius: 50%;
  cursor: pointer;
}
.banner-dots span.active {
  width: 24px;
  border-radius: 5px;
  background: #fff;
}

/* ========== 主内容区 ========== */
.main-area {
  padding: 20px 0 30px;
}

/* 分类切换：左侧竖向小图标 */
.cat-nav-vertical {
  position: sticky;
  top: 20px;
  align-self: flex-start;
}
.cat-nav-vertical .inner {
  display: flex;
  flex-direction: column;
  width: 80px;
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 4px;
  overflow: hidden;
}
.cat-nav-vertical .inner a {
  padding: 14px 8px;
  text-align: center;
  font-size: 13px;
  color: #333;
  border-bottom: 1px solid #f0f0f0;
  position: relative;
  cursor: pointer;
}
.cat-nav-vertical .inner a:last-child { border-bottom: none; }
.cat-nav-vertical .inner a .ic {
  display: block;
  font-size: 22px;
  margin-bottom: 4px;
}
.cat-nav-vertical .inner a:hover { background: #fafafa; }
.cat-nav-vertical .inner a.active {
  background: #e53935;
  color: #fff;
}
.cat-nav-vertical .inner a.active::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: #c62828;
}

/* ========== 每个分类区块 ========== */
.cat-section {
  background: #fff;
  border: 1px solid #e6e6e6;
  border-top: none;
  padding: 20px;
  margin-bottom: 18px;
}
.cat-section .section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #eee;
  padding-bottom: 12px;
  margin-bottom: 16px;
}
.cat-section .section-head .cat-title {
  font-size: 17px;
  color: #333;
  font-weight: 600;
}
.cat-section .section-head .cat-tabs {
  display: flex;
  gap: 18px;
  font-size: 13px;
}
.cat-section .section-head .cat-tabs a {
  color: #888;
  cursor: pointer;
  position: relative;
}
.cat-section .section-head .cat-tabs a.active {
  color: #e53935;
  font-weight: 500;
}
.cat-section .section-head .cat-tabs a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -12px;
  height: 2px;
  background: #e53935;
}

/* 商品展示布局：左大图 + 右小网格 */
.product-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 16px;
}

/* 左主图 */
.featured-item {
  background: linear-gradient(135deg, #f8f9fb, #eef1f6);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: box-shadow 0.3s;
  position: relative;
  height: 100%;
}
.featured-item:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}
.featured-item .f-img {
  width: 100%;
  height: 250px;
  overflow: hidden;
}
.featured-item .f-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}
.featured-item:hover .f-img img { transform: scale(1.06); }
.featured-item .f-info {
  padding: 14px 16px 18px;
}
.featured-item .f-info .brand-badge {
  display: inline-block;
  background: #1a3a6b;
  color: #fff;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 3px;
  margin-bottom: 10px;
}
.featured-item .f-info h4 {
  font-size: 15px;
  color: #333;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.4;
}
.featured-item .f-info p {
  font-size: 12px;
  color: #888;
  margin-bottom: 12px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.featured-item .f-info .f-price {
  color: #e53935;
  font-size: 22px;
  font-weight: 700;
}
.featured-item .f-info .f-price::before {
  content: '¥';
  font-size: 13px;
  margin-right: 2px;
  font-weight: 500;
}

/* 右商品网格 */
.product-grid-new {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.p-card {
  cursor: pointer;
  transition: transform 0.2s;
  position: relative;
}
.p-card:hover { transform: translateY(-3px); }
.p-card .p-img {
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  background: #f8f8f8;
  border-radius: 4px;
}
.p-card .p-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.p-card:hover .p-img img { transform: scale(1.05); }
.p-card .p-img .hot-tag {
  position: absolute;
  top: 8px; left: 8px;
  background: #e53935;
  color: #fff;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 2px;
  z-index: 2;
}
.p-card .p-img .promo-tag {
  position: absolute;
  top: 8px; right: 8px;
  background: #ff8c00;
  color: #fff;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 2px;
  z-index: 2;
}
.p-card .p-info {
  padding: 10px 2px 4px;
}
.p-card .p-info .p-name {
  font-size: 13px;
  color: #333;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 36px;
}
.p-card .p-info .p-price-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 6px;
}
.p-card .p-info .p-price {
  color: #e53935;
  font-size: 16px;
  font-weight: 700;
}
.p-card .p-info .p-price::before {
  content: '¥';
  font-size: 12px;
  margin-right: 1px;
}
.p-card .p-info .p-origin {
  color: #aaa;
  font-size: 12px;
  text-decoration: line-through;
}

/* ========== 右侧悬浮工具栏 ========== */
.float-toolbar {
  position: fixed;
  right: 18px;
  bottom: 100px;
  z-index: 99;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.float-toolbar .ft-item {
  width: 44px; height: 44px;
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 4px;
  text-align: center;
  line-height: 44px;
  font-size: 18px;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
}
.float-toolbar .ft-item:hover {
  background: #e53935;
  color: #fff;
  border-color: #e53935;
}

/* ========== 页脚 ========== */
footer.main-foot {
  background: #2d3748;
  color: #cbd5e0;
  padding: 36px 0 20px;
}
footer.main-foot .container {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 30px;
}
footer.main-foot h4 {
  font-size: 14px;
  color: #fff;
  margin-bottom: 16px;
}
footer.main-foot p {
  font-size: 13px;
  line-height: 1.9;
  color: #a0aec0;
}
footer.main-foot ul li {
  font-size: 13px;
  margin-bottom: 8px;
  color: #a0aec0;
}
footer.main-foot ul li:hover { color: #fff; cursor: pointer; }
footer.main-foot ul li .lb {
  display: inline-block;
  width: 60px;
  color: #718096;
  font-size: 12px;
}
footer.main-foot .copy-bar {
  text-align: center;
  border-top: 1px solid #4a5568;
  margin-top: 30px;
  padding-top: 18px;
  font-size: 12px;
  color: #718096;
}

/* ========== 详情页 ========== */
.detail-wrap {
  background: #fff;
  border: 1px solid #e6e6e6;
  margin: 20px auto;
  padding: 30px;
  width: 1200px;
}
.breadcrumb {
  font-size: 13px;
  color: #888;
  margin-bottom: 20px;
}
.breadcrumb a { color: #666; }
.breadcrumb a:hover { color: #e53935; }

.p-detail {
  display: grid;
  grid-template-columns: 460px 1fr;
  gap: 40px;
}
.p-detail .image-box {
  background: #f8f8f8;
  aspect-ratio: 1;
  border-radius: 4px;
  overflow: hidden;
}
.p-detail .image-box img { width: 100%; height: 100%; object-fit: cover; }

.p-detail .info-box h2 {
  font-size: 22px;
  color: #333;
  margin-bottom: 14px;
  line-height: 1.4;
}
.p-detail .info-box .desc {
  font-size: 14px;
  color: #666;
  line-height: 1.9;
  margin-bottom: 20px;
}
.price-panel {
  background: #fff9f9;
  border: 1px solid #ffe0e0;
  padding: 18px 20px;
  margin-bottom: 22px;
}
.price-panel .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: #888;
}
.price-panel .big-price {
  color: #e53935;
  font-size: 36px;
  font-weight: 700;
}
.price-panel .big-price::before {
  content: '¥'; font-size: 18px; margin-right: 2px;
}
.price-panel .origin-row {
  text-decoration: line-through;
  color: #bbb;
}
.detail-buy-box {
  display: flex;
  gap: 16px;
  align-items: center;
}
.qty-ctrl {
  display: flex;
  border: 1px solid #ddd;
  height: 40px;
}
.qty-ctrl button {
  width: 36px; border: none; background: #f5f5f5;
  cursor: pointer; font-size: 18px; color: #666;
}
.qty-ctrl input {
  width: 60px; text-align: center;
  border: none; border-left: 1px solid #ddd; border-right: 1px solid #ddd;
  outline: none; font-size: 14px;
}
.btn-buy {
  background: #e53935;
  color: #fff;
  border: none;
  padding: 12px 42px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  letter-spacing: 2px;
}
.btn-buy:hover { background: #c62828; }
.btn-cart {
  background: #fff;
  color: #e53935;
  border: 1px solid #e53935;
  padding: 12px 32px;
  font-size: 15px;
  border-radius: 4px;
  cursor: pointer;
}
.btn-cart:hover { background: #fff5f5; }

/* ========== 结算页 ========== */
.checkout-body {
  background: #fff;
  width: 1200px;
  margin: 20px auto;
  padding: 30px;
  border: 1px solid #e6e6e6;
}
.checkout-card {
  margin-bottom: 26px;
}
.checkout-card h3 {
  font-size: 16px;
  color: #333;
  padding-bottom: 12px;
  border-bottom: 2px solid #e53935;
  margin-bottom: 18px;
  display: inline-block;
}
.addr-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
}
.addr-form .full { grid-column: 1 / -1; }
.addr-form label {
  display: block;
  font-size: 13px;
  color: #555;
  margin-bottom: 6px;
}
.addr-form label .red { color: #e53935; }
.addr-form input,
.addr-form textarea,
.addr-form select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  font-size: 13px;
  border-radius: 3px;
  outline: none;
  font-family: inherit;
}
.addr-form input:focus,
.addr-form textarea:focus,
.addr-form select:focus {
  border-color: #e53935;
}
.addr-form textarea { resize: vertical; min-height: 70px; }

.order-item {
  display: flex;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px dashed #eee;
}
.order-item:last-child { border-bottom: none; }
.order-item .thumb {
  width: 100px; height: 100px;
  border-radius: 4px;
  overflow: hidden;
  background: #f5f5f5;
  flex-shrink: 0;
}
.order-item .thumb img { width: 100%; height: 100%; object-fit: cover; }
.order-item .info { flex: 1; }
.order-item .info .name { font-size: 14px; color: #333; margin-bottom: 6px; }
.order-item .info .meta { font-size: 12px; color: #888; }
.order-item .price {
  text-align: right;
}
.order-item .price .c { color: #e53935; font-weight: 700; font-size: 16px; }
.order-item .price .o { color: #bbb; font-size: 12px; text-decoration: line-through; }

.summary-box {
  background: #fafafa;
  padding: 20px 24px;
  border-radius: 4px;
}
.summary-box .row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: #666;
  padding: 6px 0;
}
.summary-box .total-row {
  border-top: 1px dashed #ddd;
  margin-top: 12px;
  padding-top: 14px;
  font-size: 15px;
  font-weight: 600;
  color: #333;
}
.summary-box .total-row .val {
  color: #e53935;
  font-size: 26px;
}

.pay-methods {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.pay-methods label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  cursor: pointer;
}

.submit-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}
.submit-bar .total-text {
  font-size: 14px;
  color: #555;
}
.submit-bar .total-text span {
  color: #e53935;
  font-size: 28px;
  font-weight: 700;
  margin-left: 6px;
}

/* Toast */
.toast {
  position: fixed;
  top: 90px; left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 12px 24px;
  border-radius: 4px;
  font-size: 14px;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.25s;
}
.toast.show { opacity: 1; }

/* 成功弹窗 */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}
.modal-mask.show { display: flex; }
.modal-mask .box {
  background: #fff;
  border-radius: 8px;
  padding: 40px 50px;
  text-align: center;
  max-width: 440px;
}
.modal-mask .box .emoji { font-size: 56px; }
.modal-mask .box h3 {
  margin: 14px 0 10px;
  font-size: 20px;
  color: #333;
}
.modal-mask .box p {
  color: #666;
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 20px;
}
