:root {
  --primary: #1a73e8;
  --primary-dark: #1558b0;
  --secondary: #f4a62a;
  --text-dark: #1a1a2e;
  --text-gray: #666;
  --bg-light: #f5f7fa;
  --border: #e0e6ef;
  --white: #fff;
  --danger: #e74c3c;
  --success: #27ae60;
  --radius: 8px;
  --shadow: 0 2px 12px rgba(26,115,232,.10);
  --shadow-md: 0 4px 24px rgba(26,115,232,.14);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif; background: var(--bg-light); color: var(--text-dark); min-height: 100vh; display: flex; flex-direction: column; }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; }

/* ===== NAVBAR ===== */
.navbar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 1000;
  box-shadow: var(--shadow);
}
.navbar-inner {
  max-width: 1200px; margin: 0 auto;
  padding: 0 20px;
  display: flex; align-items: center; justify-content: space-between;
  height: 64px; gap: 24px;
}
.navbar-brand {
  display: flex; align-items: center; gap: 10px;
  font-size: 22px; font-weight: 700; color: var(--primary);
}
.navbar-brand .logo-icon {
  width: 38px; height: 38px; background: var(--primary);
  border-radius: 8px; display: flex; align-items: center; justify-content: center;
  color: white; font-size: 20px; font-weight: 800;
}
.navbar-nav {
  display: flex; align-items: center; gap: 4px; list-style: none; flex: 1;
}
.navbar-nav a {
  padding: 8px 14px; border-radius: 6px; font-size: 15px;
  color: var(--text-dark); transition: background .2s, color .2s;
}
.navbar-nav a:hover, .navbar-nav a.active {
  background: #e8f0fe; color: var(--primary);
}
.navbar-actions { display: flex; align-items: center; gap: 10px; }
.navbar-search {
  display: flex; align-items: center;
  background: var(--bg-light); border: 1px solid var(--border);
  border-radius: 20px; padding: 6px 14px; gap: 8px;
}
.navbar-search input { border: none; background: transparent; outline: none; font-size: 14px; width: 160px; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 9px 20px; border-radius: var(--radius);
  font-size: 14px; font-weight: 500; cursor: pointer;
  border: none; transition: all .2s; gap: 6px;
}
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); color: white; }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: white; }
.btn-secondary { background: var(--secondary); color: white; }
.btn-secondary:hover { background: #d4901f; color: white; }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { background: #c0392b; color: white; }
.btn-success { background: var(--success); color: white; }
.btn-success:hover { background: #219a52; color: white; }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-lg { padding: 12px 28px; font-size: 16px; }
.btn-block { width: 100%; }

/* ===== HERO BANNER ===== */
.hero {
  background: linear-gradient(135deg, #1a73e8 0%, #0d47a1 60%, #1a1a2e 100%);
  color: white; padding: 80px 20px; text-align: center;
  position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='25'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-inner { max-width: 800px; margin: 0 auto; position: relative; }
.hero h1 { font-size: 44px; font-weight: 800; margin-bottom: 16px; line-height: 1.2; }
.hero p { font-size: 18px; opacity: .85; margin-bottom: 32px; }
.hero-btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-btns .btn { padding: 13px 30px; font-size: 16px; }
.hero-btns .btn-white { background: white; color: var(--primary); }
.hero-btns .btn-white:hover { background: #f0f5ff; }
.hero-btns .btn-outline-white { border: 2px solid rgba(255,255,255,.6); color: white; }
.hero-btns .btn-outline-white:hover { background: rgba(255,255,255,.15); }

/* ===== SECTION ===== */
.section { padding: 60px 20px; }
.section-inner { max-width: 1200px; margin: 0 auto; }
.section-title { font-size: 28px; font-weight: 700; text-align: center; margin-bottom: 8px; }
.section-sub { font-size: 15px; color: var(--text-gray); text-align: center; margin-bottom: 40px; }
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.section-header h2 { font-size: 22px; font-weight: 700; }

/* ===== CARDS ===== */
.card {
  background: white; border-radius: var(--radius);
  border: 1px solid var(--border); overflow: hidden;
  transition: box-shadow .2s, transform .2s;
}
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.card-body { padding: 20px; }
.card-title { font-size: 16px; font-weight: 600; margin-bottom: 8px; }
.card-text { font-size: 14px; color: var(--text-gray); line-height: 1.6; }

/* ===== GRID ===== */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
@media(max-width:1024px){ .grid-5{grid-template-columns:repeat(3,1fr);} .grid-4{grid-template-columns:repeat(3,1fr);} }
@media(max-width:768px){ .grid-2,.grid-3,.grid-4,.grid-5{grid-template-columns:repeat(2,1fr);} }
@media(max-width:480px){ .grid-2,.grid-3,.grid-4,.grid-5{grid-template-columns:1fr;} }

/* ===== FEATURES ===== */
.feature-card {
  background: white; border-radius: var(--radius);
  padding: 28px; text-align: center; border: 1px solid var(--border);
  transition: all .2s;
}
.feature-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.feature-icon {
  width: 64px; height: 64px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; margin: 0 auto 16px;
}
.feature-card h3 { font-size: 18px; margin-bottom: 8px; }
.feature-card p { font-size: 14px; color: var(--text-gray); line-height: 1.6; }

/* ===== NEWS / INFO ===== */
.news-item {
  background: white; border-radius: var(--radius);
  border: 1px solid var(--border); padding: 20px;
  display: flex; gap: 16px; transition: box-shadow .2s;
}
.news-item:hover { box-shadow: var(--shadow); }
.news-thumb {
  width: 120px; height: 80px; border-radius: 6px;
  background: var(--bg-light); flex-shrink: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  font-size: 32px;
}
.news-content { flex: 1; }
.news-title { font-size: 16px; font-weight: 600; margin-bottom: 6px; color: var(--text-dark); }
.news-title:hover { color: var(--primary); }
.news-meta { font-size: 13px; color: #999; display: flex; gap: 12px; margin-bottom: 8px; }
.news-desc { font-size: 14px; color: var(--text-gray); line-height: 1.5; }
.badge {
  display: inline-block; padding: 2px 8px; border-radius: 4px;
  font-size: 12px; font-weight: 500;
}
.badge-primary { background: #e8f0fe; color: var(--primary); }
.badge-secondary { background: #fff3e0; color: #e65100; }
.badge-success { background: #e8f5e9; color: var(--success); }
.badge-danger { background: #fce4ec; color: var(--danger); }
.badge-vip { background: linear-gradient(90deg,#f4a62a,#e67e22); color: white; }
.badge-paid { background: #fff3e0; color: #e65100; }

/* ===== PRODUCT CARD ===== */
.product-card { cursor: pointer; }
.product-img {
  width: 100%; aspect-ratio: 1; background: #f0f4ff;
  display: flex; align-items: center; justify-content: center;
  font-size: 48px; overflow: hidden;
}
.product-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.product-info { padding: 14px; }
.product-name { font-size: 14px; font-weight: 500; margin-bottom: 6px; color: var(--text-dark); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.product-price { font-size: 20px; font-weight: 700; color: var(--danger); }
.product-price .original { font-size: 13px; color: #bbb; text-decoration: line-through; margin-left: 6px; font-weight: 400; }
.product-meta { font-size: 12px; color: #999; margin-top: 4px; display: flex; justify-content: space-between; }

/* ===== VIP PLANS ===== */
.vip-plans { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media(max-width:900px){ .vip-plans{grid-template-columns:repeat(2,1fr);} }
@media(max-width:540px){ .vip-plans{grid-template-columns:1fr;} }
.vip-plan {
  background: white; border-radius: 12px;
  border: 2px solid var(--border); padding: 28px 20px;
  text-align: center; position: relative; transition: all .2s;
}
.vip-plan:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.vip-plan.featured {
  border-color: var(--secondary);
  box-shadow: 0 4px 20px rgba(244,166,42,.25);
}
.vip-plan.featured::before {
  content: '推荐'; position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--secondary); color: white; padding: 2px 14px;
  border-radius: 20px; font-size: 12px; font-weight: 600;
}
.plan-name { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.plan-price { font-size: 40px; font-weight: 800; color: var(--primary); margin: 12px 0 4px; }
.plan-price span { font-size: 15px; color: var(--text-gray); font-weight: 400; }
.plan-desc { font-size: 13px; color: var(--text-gray); margin-bottom: 20px; }
.plan-features { list-style: none; text-align: left; margin-bottom: 24px; }
.plan-features li { padding: 6px 0; font-size: 14px; display: flex; gap: 8px; }
.plan-features li::before { content: '✓'; color: var(--success); font-weight: 700; flex-shrink: 0; }
.plan-features li.no::before { content: '✗'; color: #ccc; }

/* ===== MERCHANT ===== */
.step-item { text-align: center; padding: 20px; }
.step-num {
  width: 48px; height: 48px; background: var(--primary); color: white;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 700; margin: 0 auto 14px;
}
.step-item h3 { font-size: 16px; font-weight: 600; margin-bottom: 8px; }
.step-item p { font-size: 14px; color: var(--text-gray); }

/* ===== FORMS ===== */
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 6px; color: var(--text-dark); }
.form-control {
  width: 100%; padding: 10px 14px; border: 1.5px solid var(--border);
  border-radius: var(--radius); font-size: 15px; outline: none;
  transition: border-color .2s; background: white;
}
.form-control:focus { border-color: var(--primary); }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.form-hint { font-size: 12px; color: #999; margin-top: 4px; }
.form-error { font-size: 12px; color: var(--danger); margin-top: 4px; }
textarea.form-control { resize: vertical; min-height: 100px; }

/* ===== AUTH BOX ===== */
.auth-wrap { min-height: calc(100vh - 64px - 200px); display: flex; align-items: center; justify-content: center; padding: 40px 20px; }
.auth-box { background: white; border-radius: 12px; padding: 40px; width: 100%; max-width: 440px; border: 1px solid var(--border); box-shadow: var(--shadow-md); }
.auth-box h2 { font-size: 24px; font-weight: 700; margin-bottom: 4px; }
.auth-box .sub { font-size: 14px; color: var(--text-gray); margin-bottom: 28px; }
.tab-btns { display: flex; background: var(--bg-light); border-radius: 8px; padding: 4px; margin-bottom: 24px; }
.tab-btn { flex: 1; text-align: center; padding: 8px; border-radius: 6px; font-size: 15px; cursor: pointer; color: var(--text-gray); transition: all .2s; }
.tab-btn.active { background: white; color: var(--primary); font-weight: 600; box-shadow: 0 1px 4px rgba(0,0,0,.1); }
.divider { text-align: center; color: #bbb; font-size: 13px; margin: 16px 0; position: relative; }
.divider::before, .divider::after { content:''; position:absolute; top:50%; width: calc(50% - 30px); height: 1px; background: var(--border); }
.divider::before { left: 0; } .divider::after { right: 0; }

/* ===== PAGE HEADER ===== */
.page-header {
  background: linear-gradient(135deg, #1a73e8, #0d47a1);
  color: white; padding: 48px 20px;
}
.page-header-inner { max-width: 1200px; margin: 0 auto; }
.page-header h1 { font-size: 32px; font-weight: 700; margin-bottom: 8px; }
.page-header p { font-size: 16px; opacity: .85; }
.breadcrumb { display: flex; gap: 6px; font-size: 13px; opacity: .75; margin-bottom: 16px; }
.breadcrumb span { opacity: .5; }

/* ===== SIDEBAR LAYOUT ===== */
.layout-side { max-width: 1200px; margin: 0 auto; padding: 32px 20px; display: grid; grid-template-columns: 240px 1fr; gap: 24px; }
@media(max-width:768px){ .layout-side{grid-template-columns:1fr;} }
.sidebar { background: white; border-radius: var(--radius); border: 1px solid var(--border); padding: 16px; height: fit-content; }
.sidebar-menu { list-style: none; }
.sidebar-menu li a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 6px; font-size: 14px; color: var(--text-dark); transition: all .2s; }
.sidebar-menu li a:hover, .sidebar-menu li a.active { background: #e8f0fe; color: var(--primary); }
.sidebar-title { font-size: 12px; color: #999; padding: 8px 12px 4px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; }

/* ===== TABLE ===== */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: white; border-radius: var(--radius); overflow: hidden; }
table th { background: var(--bg-light); padding: 12px 16px; text-align: left; font-size: 13px; color: var(--text-gray); font-weight: 600; white-space: nowrap; }
table td { padding: 12px 16px; font-size: 14px; border-top: 1px solid var(--border); }
table tr:hover td { background: #fafbff; }

/* ===== FOOTER ===== */
footer {
  background: #1a1a2e; color: #aaa;
  margin-top: auto; font-size: 14px;
}
.footer-main {
  max-width: 1200px; margin: 0 auto;
  padding: 48px 20px 32px;
  display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 40px;
}
@media(max-width:768px){ .footer-main{grid-template-columns:1fr 1fr;} }
@media(max-width:480px){ .footer-main{grid-template-columns:1fr;} }
.footer-brand { color: white; font-size: 22px; font-weight: 700; margin-bottom: 12px; }
.footer-brand-desc { font-size: 13px; line-height: 1.7; margin-bottom: 16px; }
.footer-col h4 { color: white; font-size: 15px; font-weight: 600; margin-bottom: 14px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a { color: #aaa; font-size: 13px; }
.footer-col ul li a:hover { color: white; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  max-width: 1200px; margin: 0 auto;
  padding: 20px; text-align: center; font-size: 13px;
}
.footer-bottom a { color: #888; margin: 0 8px; }
.footer-bottom a:hover { color: #ccc; }
.icp-info { margin-top: 8px; font-size: 12px; color: #666; }
.icp-info a { color: #888; }

/* ===== MISC ===== */
.text-primary { color: var(--primary); }
.text-danger { color: var(--danger); }
.text-success { color: var(--success); }
.text-gray { color: var(--text-gray); }
.text-sm { font-size: 13px; }
.text-center { text-align: center; }
.mt-4 { margin-top: 16px; } .mt-8 { margin-top: 32px; } .mb-4 { margin-bottom: 16px; }
.p-4 { padding: 16px; } .py-8 { padding-top: 32px; padding-bottom: 32px; }
.flex { display: flex; } .flex-center { display: flex; align-items: center; justify-content: center; }
.gap-2 { gap: 8px; } .gap-4 { gap: 16px; }
.justify-between { justify-content: space-between; }
.items-center { align-items: center; }
.w-full { width: 100%; }
.rounded { border-radius: var(--radius); }
.shadow { box-shadow: var(--shadow); }
.bg-white { background: white; }
.border { border: 1px solid var(--border); }
.notice-bar { background: #fffbe6; border: 1px solid #ffe58f; border-radius: 6px; padding: 10px 16px; font-size: 13px; color: #7d5a00; display: flex; gap: 8px; align-items: center; }
.alert { padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 16px; }
.alert-info { background: #e8f0fe; color: #1a56c4; border: 1px solid #b3c8f8; }
.alert-success { background: #e8f5e9; color: #1b5e20; border: 1px solid #a5d6a7; }
.alert-warning { background: #fffde7; color: #7d5a00; border: 1px solid #fff176; }
.stat-card { background: white; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; text-align: center; }
.stat-num { font-size: 32px; font-weight: 700; color: var(--primary); }
.stat-label { font-size: 13px; color: var(--text-gray); margin-top: 4px; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--primary); color: white; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 16px; }
.tag { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 12px; background: var(--bg-light); color: var(--text-gray); margin-right: 4px; }
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 32px; }
.page-btn { width: 36px; height: 36px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 14px; background: white; border: 1px solid var(--border); cursor: pointer; color: var(--text-dark); }
.page-btn.active { background: var(--primary); color: white; border-color: var(--primary); }
.page-btn:hover:not(.active) { border-color: var(--primary); color: var(--primary); }
.filter-bar { background: white; border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; margin-bottom: 20px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.filter-btn { padding: 6px 14px; border-radius: 20px; font-size: 13px; background: var(--bg-light); border: 1px solid var(--border); cursor: pointer; color: var(--text-gray); transition: all .2s; }
.filter-btn.active, .filter-btn:hover { background: var(--primary); color: white; border-color: var(--primary); }
.empty { text-align: center; padding: 60px 20px; color: var(--text-gray); }
.empty-icon { font-size: 48px; margin-bottom: 16px; }
.cart-badge { position: relative; }
.cart-badge sup { position: absolute; top: -6px; right: -8px; background: var(--danger); color: white; border-radius: 50%; width: 18px; height: 18px; font-size: 11px; display: flex; align-items: center; justify-content: center; }
.sticky-footer { position: fixed; bottom: 0; left: 0; right: 0; background: white; border-top: 1px solid var(--border); padding: 12px 20px; z-index: 100; box-shadow: 0 -4px 12px rgba(0,0,0,.08); }
.sticky-footer-inner { max-width: 1200px; margin: 0 auto; display: flex; justify-content: flex-end; align-items: center; gap: 16px; }
