@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;700;900&family=Inter:wght@400;500;600;700;800&display=swap');

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #f5ede0;
  --bg2:       rgba(255,255,255,0.75);
  --bg3:       rgba(245,237,224,0.85);
  --bg4:       rgba(255,252,245,0.9);
  --border:    rgba(180,140,90,0.3);
  --border2:   rgba(180,100,60,0.4);
  --accent:    #b5231a;
  --accent2:   #d42a1f;
  --accent-glow: rgba(181,35,26,0.08);
  --gold:      #a07828;
  --gold-dim:  #7a5a1a;
  --gold-glow: rgba(160,120,40,0.08);
  --text:      #5a4a3a;
  --text-dim:  #8a7a6a;
  --text-main: #2a1a0a;
  --green:     #3a8a5a;
  --red:       #b5231a;
  --orange:    #c9a84c;
  --purple:    #7a5a9a;
  --radius:    6px;
  --radius-lg: 8px;
  --shadow:    0 2px 16px rgba(100,60,20,0.12);
  --card-shadow: 0 1px 8px rgba(100,60,20,0.08);
  --font-zh:   'Noto Serif SC', 'SimSun', 'STSong', serif;
  --font-body: 'Inter', 'Segoe UI', system-ui, sans-serif;
}

body {
  background: var(--bg);
  background-image: url('bg.jpg');
  background-size: cover;
  background-attachment: fixed;
  background-position: center;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.6;
  min-height: 100vh;
}

/* ornamental top line */
body::before {
  content: '';
  display: block;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--gold), var(--accent), transparent);
}

a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover { color: var(--gold); }

img { max-width: 100%; height: auto; }

.container { max-width: 1240px; margin: 0 auto; padding: 0 20px; }

/* ===== HEADER ===== */
.site-header {
  background: rgba(245,235,220,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 2px solid;
  border-image: linear-gradient(90deg, transparent, var(--accent), var(--gold), var(--accent), transparent) 1;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-top { background: rgba(42,26,10,0.9); padding: 10px 0; }
.header-top-inner { display: flex; justify-content: space-between; align-items: center; }

.logo {
  font-family: var(--font-zh);
  font-size: 22px;
  font-weight: 900;
  color: #f5ede0;
  letter-spacing: 3px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
}
.logo span { color: var(--accent2); }
.logo-deco { color: var(--gold); font-size: 18px; opacity: 0.7; }
.logo-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent), #8b1a10);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: #fff;
  font-family: var(--font-zh);
  font-weight: 900;
  border: 1px solid rgba(201,168,76,0.4);
  box-shadow: 0 0 10px rgba(181,35,26,0.4);
}

.header-links { display: flex; gap: 10px; align-items: center; }
.header-links a { font-size: 12px; color: rgba(245,237,224,0.7); padding: 5px 12px; border-radius: var(--radius); transition: all 0.15s; letter-spacing: 0.5px; }
.header-links a:hover { color: #fff; background: rgba(255,255,255,0.1); }
.btn-reg { background: var(--accent) !important; color: #fff !important; font-weight: 600; border: 1px solid rgba(201,168,76,0.3) !important; }
.btn-reg:hover { background: var(--accent2) !important; }

.main-nav { padding: 0; }
.main-nav ul { display: flex; list-style: none; gap: 0; }
.main-nav ul li a {
  display: block;
  padding: 10px 18px;
  color: var(--text-dim);
  font-size: 12px;
  font-weight: 600;
  transition: all 0.15s;
  border-bottom: 2px solid transparent;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.main-nav ul li a:hover, .main-nav ul li a.active {
  color: var(--accent);
  background: var(--accent-glow);
  border-bottom-color: var(--accent);
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), #9a1a12);
  color: #fff;
  padding: 9px 22px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 13px;
  transition: all 0.2s;
  border: 1px solid rgba(201,168,76,0.2);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 8px rgba(181,35,26,0.2);
}
.btn-primary:hover { background: linear-gradient(135deg, var(--accent2), var(--accent)); color: #fff; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(181,35,26,0.3); }
.btn-outline { display: inline-block; border: 2px solid var(--gold); color: var(--gold-dim); padding: 8px 22px; border-radius: var(--radius); font-weight: 600; font-size: 13px; transition: all 0.2s; letter-spacing: 0.5px; background: transparent; }
.btn-outline:hover { background: var(--gold); color: #fff; }
.btn-small { display: inline-block; background: var(--accent); color: #fff; padding: 5px 14px; border-radius: var(--radius); font-weight: 600; font-size: 11px; border: none; cursor: pointer; transition: all 0.15s; }
.btn-small:hover { background: var(--accent2); }
.btn-danger { display: inline-block; background: #c0392b; color: #fff; padding: 5px 14px; border-radius: var(--radius); font-weight: 600; font-size: 11px; border: none; cursor: pointer; }
.btn-danger:hover { background: #e04030; }
.btn-danger-sm { background: #c0392b; color: #fff; border: none; border-radius: 3px; padding: 2px 8px; font-size: 10px; cursor: pointer; line-height: 1.6; }
.btn-danger-sm:hover { background: #e04030; }

.admin-tag-item { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; background: var(--bg4); border: 1px solid var(--border); border-radius: 4px; font-size: 12px; color: var(--text-main); }
.admin-manage-section { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; backdrop-filter: blur(6px); }
.admin-manage-section h3 { font-size: 14px; color: var(--accent); margin-bottom: 14px; display: flex; align-items: center; gap: 8px; font-family: var(--font-zh); }
.admin-manage-grid { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.admin-top-panels { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 28px; }
@media (max-width: 700px) { .admin-top-panels { grid-template-columns: 1fr; } }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, rgba(42,26,10,0.88) 0%, rgba(90,30,20,0.82) 50%, rgba(42,26,10,0.88) 100%);
  padding: 56px 0 44px;
  position: relative;
  overflow: hidden;
  border-bottom: 2px solid;
  border-image: linear-gradient(90deg, transparent, var(--gold), transparent) 1;
}
.hero::before {
  content: '龍';
  position: absolute;
  top: 50%;
  right: 5%;
  transform: translateY(-50%);
  font-family: var(--font-zh);
  font-size: 280px;
  color: rgba(201,168,76,0.06);
  pointer-events: none;
  line-height: 1;
}
.hero .container { display: flex; flex-direction: column; gap: 28px; align-items: flex-start; position: relative; z-index: 1; }
.hero-content h1 {
  font-family: var(--font-zh);
  font-size: 34px;
  color: #f5ede0;
  font-weight: 900;
  margin-bottom: 10px;
  letter-spacing: 2px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.hero-content h1 span { color: var(--gold); }
.hero-content p { font-size: 14px; color: rgba(245,237,224,0.7); margin-bottom: 22px; max-width: 460px; }
.hero-content { display: flex; flex-direction: column; gap: 6px; }
.hero-buttons { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-stats {
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
  background: rgba(0,0,0,0.25);
  backdrop-filter: blur(8px);
  padding: 18px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(201,168,76,0.2);
}
.stat { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.stat-num { font-size: 24px; font-weight: 800; color: var(--gold); font-family: var(--font-zh); }
.stat-label { font-size: 10px; color: rgba(245,237,224,0.6); text-transform: uppercase; letter-spacing: 2px; }

/* ===== SECTIONS ===== */
.section { padding: 44px 0; }
.section + .section { border-top: 1px solid var(--border); }
.section-title {
  font-family: var(--font-zh);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 22px;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 1px;
}
.section-title::before { content: ''; width: 3px; height: 20px; background: var(--accent); border-radius: 1px; }
.section-title::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--border), transparent); margin-left: 12px; }
.section-footer { text-align: center; margin-top: 24px; }

/* ===== CATEGORIES ===== */
.categories-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; }
.cat-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
  cursor: pointer;
  position: relative;
  backdrop-filter: blur(6px);
}
.cat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.2s;
}
.cat-card:hover { border-color: var(--accent); background: rgba(181,35,26,0.06); box-shadow: var(--card-shadow); }
.cat-card:hover::before { opacity: 1; }
.cat-icon { font-size: 26px; }
.cat-name { font-size: 12px; font-weight: 600; color: var(--text-main); text-align: center; }
.cat-count { font-size: 10px; color: var(--text-dim); background: rgba(160,120,40,0.1); padding: 2px 8px; border-radius: 3px; }

/* ===== FILTER PILLS ===== */
.filter-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pill { background: var(--bg2); border: 1px solid var(--border); color: var(--text); padding: 6px 16px; border-radius: 3px; font-size: 12px; transition: all 0.15s; cursor: pointer; backdrop-filter: blur(4px); }
.pill:hover, .pill.active { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }

/* ===== PRODUCTS GRID ===== */
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.product-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.2s;
  position: relative;
  backdrop-filter: blur(6px);
}
.product-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--gold));
  opacity: 0;
  transition: opacity 0.2s;
}
.product-card:hover { border-color: var(--border2); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(100,60,20,0.15); }
.product-card:hover::after { opacity: 1; }
.product-img { background: rgba(230,220,200,0.5); height: 170px; display: flex; align-items: center; justify-content: center; font-size: 44px; overflow: hidden; position: relative; }
.product-img img { width: 100%; height: 100%; object-fit: cover; }
.product-img .no-img { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; color: var(--text-dim); font-size: 36px; }
.product-badge { position: absolute; top: 8px; left: 8px; background: var(--accent); color: #fff; font-size: 9px; font-weight: 700; padding: 3px 8px; border-radius: 2px; text-transform: uppercase; letter-spacing: 1px; }
.product-body { padding: 12px; }
.product-shop { font-size: 10px; color: var(--gold-dim); font-weight: 600; margin-bottom: 5px; display: flex; align-items: center; gap: 4px; letter-spacing: 0.5px; }
.product-name { font-size: 13px; color: var(--text-main); font-weight: 600; margin-bottom: 6px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-meta { display: flex; gap: 5px; font-size: 10px; color: var(--text-dim); margin-bottom: 8px; flex-wrap: wrap; }
.product-meta span { background: rgba(160,120,40,0.08); padding: 2px 7px; border-radius: 3px; }
.product-prices { margin-bottom: 10px; }
.product-price-main { font-size: 16px; font-weight: 800; color: var(--accent); }
.product-price-alt { font-size: 10px; color: var(--text-dim); margin-top: 2px; }
.product-actions { display: flex; gap: 6px; align-items: center; justify-content: space-between; }
.stock-badge { font-size: 10px; color: var(--green); font-weight: 500; }
.stock-badge.out { color: var(--red); }

/* ===== SHOPS ===== */
.shops-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.shop-card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; transition: all 0.2s; display: block; text-decoration: none; backdrop-filter: blur(6px); }
.shop-card:hover { border-color: var(--border2); transform: translateY(-2px); box-shadow: var(--shadow); }
.shop-card-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.shop-avatar-sm { width: 40px; height: 40px; background: rgba(230,220,200,0.5); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 20px; }
.shop-name { font-size: 14px; font-weight: 700; color: var(--text-main); }
.shop-city { font-size: 11px; color: var(--text-dim); margin-top: 2px; }
.shop-stats { display: flex; gap: 14px; font-size: 11px; color: var(--text-dim); }
.shop-stats strong { color: var(--text-main); }
.verified-badge { display: inline-flex; align-items: center; gap: 3px; font-size: 9px; background: rgba(58,138,90,0.1); color: var(--green); padding: 3px 8px; border-radius: 3px; font-weight: 600; margin-top: 6px; letter-spacing: 0.5px; }

/* ===== CHAT BAR ===== */
.chat-bar { background: rgba(42,26,10,0.06); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 18px 0; }
.chat-title { font-size: 13px; font-weight: 700; color: var(--accent); margin-bottom: 10px; display: flex; align-items: center; gap: 8px; font-family: var(--font-zh); }
.chat-messages { display: flex; flex-direction: column; gap: 4px; max-height: 140px; overflow-y: auto; }
.chat-msg { font-size: 12px; color: var(--text); padding: 6px 10px; background: var(--bg2); border-radius: var(--radius); border-left: 2px solid var(--accent); backdrop-filter: blur(4px); }
.chat-user { color: var(--accent); font-weight: 700; margin-right: 6px; }
.chat-input-row { display: flex; gap: 6px; margin-top: 8px; }
.chat-input-row input { flex: 1; background: var(--bg4); border: 1px solid var(--border); color: var(--text-main); padding: 7px 10px; border-radius: var(--radius); font-size: 12px; }
.chat-input-row input:focus { outline: none; border-color: var(--accent); }

/* ===== NEWS ===== */
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.news-card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; color: var(--text); transition: all 0.2s; display: block; backdrop-filter: blur(6px); }
.news-card:hover { border-color: var(--border2); transform: translateY(-2px); box-shadow: var(--shadow); }
.news-date { font-size: 10px; color: var(--text-dim); display: block; margin-bottom: 8px; letter-spacing: 1px; }
.news-card h4 { font-size: 14px; color: var(--text-main); margin-bottom: 6px; line-height: 1.4; font-family: var(--font-zh); }
.news-card p { font-size: 12px; color: var(--text-dim); line-height: 1.5; }

/* ===== FOOTER ===== */
.site-footer {
  background: rgba(42,26,10,0.92);
  padding: 40px 0 20px;
  position: relative;
  color: rgba(245,237,224,0.6);
}
.site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--gold), var(--accent), transparent);
}
.site-footer a { color: rgba(245,237,224,0.5); }
.site-footer a:hover { color: var(--gold); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 28px; margin-bottom: 28px; }
.footer-col h4 { font-size: 11px; font-weight: 700; color: var(--gold); margin-bottom: 12px; text-transform: uppercase; letter-spacing: 2px; font-family: var(--font-zh); }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.footer-col ul li a { font-size: 12px; color: rgba(245,237,224,0.5); transition: color 0.15s; }
.footer-col ul li a:hover { color: var(--gold); }
.footer-bottom { border-top: 1px solid rgba(245,237,224,0.1); padding-top: 18px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 11px; color: rgba(245,237,224,0.4); }

/* ===== CATALOG PAGE ===== */
.page-layout { display: grid; grid-template-columns: 240px 1fr; gap: 20px; padding: 24px 0; }
.sidebar { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; align-self: start; position: sticky; top: 85px; backdrop-filter: blur(8px); }
.sidebar-section { margin-bottom: 20px; }
.sidebar-section:last-child { margin-bottom: 0; }
.sidebar-title { font-size: 10px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 8px; padding-bottom: 6px; border-bottom: 1px solid var(--border); font-family: var(--font-zh); }
.sidebar-list { list-style: none; display: flex; flex-direction: column; gap: 1px; }
.sidebar-list li a { display: flex; justify-content: space-between; padding: 6px 8px; border-radius: 3px; color: var(--text); font-size: 12px; transition: all 0.15s; }
.sidebar-list li a:hover, .sidebar-list li a.active { background: var(--accent-glow); color: var(--accent); }
.sidebar-list li a .cnt { color: var(--text-dim); font-size: 10px; background: rgba(160,120,40,0.1); padding: 1px 5px; border-radius: 3px; }

.catalog-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; flex-wrap: wrap; gap: 8px; }
.catalog-header h2 { font-size: 16px; font-weight: 700; color: var(--text-main); font-family: var(--font-zh); }
.sort-bar { display: flex; gap: 6px; align-items: center; font-size: 12px; color: var(--text-dim); }
.sort-bar select { background: var(--bg4); border: 1px solid var(--border); color: var(--text); padding: 5px 10px; border-radius: var(--radius); font-size: 12px; cursor: pointer; }
.sort-bar select:focus { outline: none; border-color: var(--accent); }
.filter-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 14px; }
.filter-tab { padding: 5px 14px; border-radius: 3px; border: 1px solid var(--border); font-size: 11px; color: var(--text); cursor: pointer; transition: all 0.15s; background: var(--bg2); backdrop-filter: blur(4px); }
.filter-tab:hover, .filter-tab.active { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }
.pagination { display: flex; gap: 4px; justify-content: center; margin-top: 24px; }
.pagination a { display: inline-block; padding: 6px 12px; background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); color: var(--text); font-size: 12px; transition: all 0.15s; backdrop-filter: blur(4px); }
.pagination a:hover, .pagination a.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.empty-state { text-align: center; padding: 50px 20px; color: var(--text-dim); }
.empty-state .empty-icon { font-size: 44px; margin-bottom: 14px; opacity: 0.4; }
.empty-state h3 { color: var(--text-main); font-size: 16px; margin-bottom: 6px; font-family: var(--font-zh); }

/* ===== PRODUCT PAGE ===== */
.product-page { padding: 24px 0; }
.breadcrumb { font-size: 11px; color: var(--text-dim); margin-bottom: 20px; display: flex; gap: 6px; align-items: center; }
.breadcrumb a { color: var(--text-dim); }
.breadcrumb a:hover { color: var(--accent); }
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-bottom: 28px; }
.product-gallery { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); height: 380px; display: flex; align-items: center; justify-content: center; font-size: 70px; overflow: hidden; backdrop-filter: blur(6px); }
.product-gallery img { width: 100%; height: 100%; object-fit: cover; }
.product-info { display: flex; flex-direction: column; gap: 14px; }
.product-info h1 { font-size: 22px; color: var(--text-main); font-weight: 700; font-family: var(--font-zh); }
.product-rating { display: flex; gap: 6px; align-items: center; font-size: 12px; }
.stars { color: var(--gold); }
.rating-count { color: var(--text-dim); }
.price-block { display: flex; flex-direction: column; gap: 4px; background: var(--bg2); padding: 14px; border-radius: var(--radius); border-left: 3px solid var(--accent); backdrop-filter: blur(6px); }
.price-main-row { display: flex; align-items: baseline; gap: 10px; }
.price-big { font-size: 28px; font-weight: 800; color: var(--accent); font-family: var(--font-zh); }
.price-old { font-size: 14px; color: var(--text-dim); text-decoration: line-through; }
.price-alts { display: flex; gap: 14px; font-size: 12px; color: var(--text-dim); }
.price-alts span { display: flex; align-items: center; gap: 4px; }
.product-stock { display: flex; gap: 10px; font-size: 12px; }
.in-stock { color: var(--green); font-weight: 600; }
.buy-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.seller-info { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; backdrop-filter: blur(6px); }
.seller-info h4 { font-size: 11px; color: var(--text-dim); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 1px; }
.seller-info .s-name { font-size: 14px; font-weight: 700; color: var(--accent); }
.seller-info .s-city { font-size: 11px; color: var(--text-dim); margin-top: 4px; }
.product-desc { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 20px; backdrop-filter: blur(6px); }
.product-desc h3 { font-size: 15px; color: var(--text-main); margin-bottom: 10px; font-family: var(--font-zh); }
.product-desc p { font-size: 13px; color: var(--text); line-height: 1.7; }

/* ===== AUTH PAGES ===== */
.auth-page { min-height: 80vh; display: flex; align-items: center; justify-content: center; padding: 36px 16px; }
.auth-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow);
  position: relative;
  backdrop-filter: blur(10px);
}
.auth-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--gold), var(--accent), transparent);
}
.auth-card h2 { font-size: 22px; font-weight: 700; color: var(--text-main); margin-bottom: 4px; font-family: var(--font-zh); }
.auth-card .auth-sub { font-size: 12px; color: var(--text-dim); margin-bottom: 24px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 12px; color: var(--text-dim); margin-bottom: 5px; font-weight: 500; letter-spacing: 0.5px; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  background: var(--bg4);
  border: 1px solid var(--border);
  color: var(--text-main);
  padding: 10px 12px;
  border-radius: var(--radius);
  font-size: 13px;
  transition: border-color 0.2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-glow); }
.form-group textarea { resize: vertical; min-height: 70px; }
.pickup-checks { display: flex; flex-wrap: wrap; gap: 8px; }
.pickup-check { display: flex; align-items: center; gap: 5px; font-size: 13px; color: var(--text); background: rgba(255,255,255,0.5); border: 1px solid var(--border); border-radius: 8px; padding: 6px 12px; cursor: pointer; transition: background .2s, border-color .2s; user-select: none; }
.pickup-check:hover { border-color: var(--accent); }
.pickup-check input { width: auto; margin: 0; accent-color: var(--accent); cursor: pointer; }
.pickup-check:has(input:checked) { background: rgba(181,35,26,0.08); border-color: var(--accent); }
.form-footer { text-align: center; margin-top: 16px; font-size: 12px; color: var(--text-dim); }
.form-footer a { color: var(--accent); }
.form-check { display: flex; gap: 8px; align-items: flex-start; font-size: 12px; color: var(--text); }
.form-check input { width: auto; margin-top: 2px; accent-color: var(--accent); }

/* ===== NEWS PAGE ===== */
.page-header {
  background: rgba(42,26,10,0.85);
  padding: 24px 0;
  position: relative;
}
.page-header::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--accent), var(--gold), var(--accent), transparent); }
.page-header h1 { font-size: 24px; font-weight: 700; color: #f5ede0; font-family: var(--font-zh); }
.page-header p { font-size: 13px; color: rgba(245,237,224,0.6); margin-top: 4px; }
.news-full { display: grid; grid-template-columns: 1fr 300px; gap: 20px; padding: 24px 0 44px; }
.news-list { display: flex; flex-direction: column; gap: 12px; }
.news-item { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; backdrop-filter: blur(6px); }
.news-item .news-date { font-size: 10px; color: var(--text-dim); letter-spacing: 1px; }
.news-item h3 { font-size: 16px; font-weight: 600; color: var(--text-main); margin: 6px 0; font-family: var(--font-zh); }
.news-item p { font-size: 12px; color: var(--text-dim); line-height: 1.6; }
.news-item .read-more { color: var(--accent); font-size: 12px; font-weight: 600; margin-top: 8px; display: inline-block; }
.news-sidebar { display: flex; flex-direction: column; gap: 14px; }
.sidebar-widget { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; backdrop-filter: blur(6px); }
.widget-title { font-size: 11px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border); font-family: var(--font-zh); }

/* ===== SUPPORT PAGE ===== */
.support-grid { display: grid; grid-template-columns: 260px 1fr; gap: 20px; padding-bottom: 44px; }
.support-menu { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; align-self: start; position: sticky; top: 85px; backdrop-filter: blur(8px); }
.support-category { margin-bottom: 16px; }
.support-category h4 { font-size: 10px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 6px; padding-bottom: 5px; border-bottom: 1px solid var(--border); font-family: var(--font-zh); }
.support-category ul { list-style: none; display: flex; flex-direction: column; gap: 1px; }
.support-category ul li a { display: block; padding: 6px 8px; border-radius: 3px; color: var(--text); font-size: 12px; transition: all 0.15s; }
.support-category ul li a:hover, .support-category ul li a.active { background: var(--accent-glow); color: var(--accent); }
.article-content { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; backdrop-filter: blur(8px); }
.article-content h2 { font-size: 20px; color: var(--text-main); margin-bottom: 16px; font-family: var(--font-zh); }
.article-content h3 { font-size: 15px; color: var(--accent); margin: 20px 0 8px; font-family: var(--font-zh); }
.article-content p { font-size: 13px; color: var(--text); line-height: 1.7; margin-bottom: 10px; }
.article-content ul { padding-left: 18px; margin-bottom: 10px; }
.article-content ul li { font-size: 13px; color: var(--text); line-height: 1.7; margin-bottom: 5px; }

/* ===== SHOP PAGE ===== */
.shop-header-block { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 20px; display: flex; gap: 18px; align-items: center; border-top: 2px solid var(--accent); backdrop-filter: blur(6px); }
.shop-avatar { width: 72px; height: 72px; background: rgba(230,220,200,0.5); border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 32px; flex-shrink: 0; }
.shop-header-info h2 { font-size: 20px; color: var(--text-main); font-weight: 700; margin-bottom: 4px; font-family: var(--font-zh); }
.shop-header-meta { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-dim); }
.shop-header-meta span strong { color: var(--text-main); }

/* ===== OPEN SHOP / WORK PAGE ===== */
.info-page { max-width: 680px; margin: 0 auto; padding: 44px 20px; }
.info-page h1 { font-size: 24px; color: var(--text-main); font-weight: 700; margin-bottom: 10px; font-family: var(--font-zh); }
.info-page .subtitle { font-size: 14px; color: var(--text-dim); margin-bottom: 32px; }
.steps-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 32px; }
.step-item { display: flex; gap: 14px; align-items: flex-start; background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; backdrop-filter: blur(6px); }
.step-num { width: 34px; height: 34px; background: linear-gradient(135deg, var(--accent), #9a1a12); color: #fff; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; flex-shrink: 0; font-family: var(--font-zh); }
.step-text h4 { font-size: 14px; color: var(--text-main); font-weight: 600; margin-bottom: 3px; }
.step-text p { font-size: 12px; color: var(--text-dim); line-height: 1.5; }

/* ===== ADMIN PANEL ===== */
.admin-page { padding: 24px 0 50px; }
.admin-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; flex-wrap: wrap; gap: 10px; }
.admin-header h1 { font-size: 22px; color: var(--text-main); font-weight: 700; font-family: var(--font-zh); }
.admin-grid { display: grid; grid-template-columns: 340px 1fr; gap: 20px; }
.admin-form { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; align-self: start; position: sticky; top: 85px; backdrop-filter: blur(8px); }
.admin-form h3 { font-size: 14px; color: var(--accent); margin-bottom: 16px; display: flex; align-items: center; gap: 8px; font-family: var(--font-zh); }
.admin-products { display: flex; flex-direction: column; gap: 10px; }
.admin-product-card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; display: flex; gap: 12px; align-items: flex-start; backdrop-filter: blur(6px); }
.admin-product-card .ap-img { width: 64px; height: 64px; background: rgba(230,220,200,0.5); border-radius: 4px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.admin-product-card .ap-img img { width: 100%; height: 100%; object-fit: cover; }
.admin-product-card .ap-info { flex: 1; min-width: 0; }
.admin-product-card .ap-name { font-size: 13px; font-weight: 600; color: var(--text-main); margin-bottom: 3px; }
.admin-product-card .ap-price { font-size: 12px; color: var(--accent); font-weight: 700; }
.admin-product-card .ap-cat { font-size: 10px; color: var(--text-dim); margin-top: 2px; }
.admin-product-card .ap-actions { display: flex; gap: 5px; flex-shrink: 0; }
.price-inputs { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
.img-preview { width: 100%; height: 130px; background: rgba(230,220,200,0.3); border: 1px dashed var(--border); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; margin-bottom: 8px; overflow: hidden; cursor: pointer; transition: border-color 0.15s; }
.img-preview:hover { border-color: var(--accent); }
.img-preview img { width: 100%; height: 100%; object-fit: cover; }
.img-preview .placeholder { color: var(--text-dim); font-size: 12px; text-align: center; }

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: rgba(245,237,224,0.5); }
::-webkit-scrollbar-thumb { background: rgba(180,140,90,0.4); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: rgba(180,140,90,0.6); }

/* ===== TOAST NOTIFICATIONS ===== */
.toast { position: fixed; bottom: 20px; right: 20px; background: var(--bg4); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 18px; color: var(--text-main); font-size: 13px; z-index: 9999; box-shadow: 0 8px 28px rgba(100,60,20,0.15); animation: slideUp 0.3s ease; backdrop-filter: blur(8px); }
.toast.success { border-left: 3px solid var(--green); }
.toast.error { border-left: 3px solid var(--red); }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(181,35,26,0.3); }
  50% { box-shadow: 0 0 0 8px rgba(181,35,26,0); }
}
.product-card, .cat-card, .news-card, .step-item {
  animation: fadeInUp 0.4s ease both;
}
.product-card:nth-child(2) { animation-delay: 0.05s; }
.product-card:nth-child(3) { animation-delay: 0.1s; }
.product-card:nth-child(4) { animation-delay: 0.15s; }
.product-card:nth-child(5) { animation-delay: 0.2s; }
.product-card:nth-child(6) { animation-delay: 0.25s; }
.btn-primary { animation: pulse 2s infinite; }
.btn-primary:hover { animation: none; }

/* ===== CITY SELECT PAGE ===== */
.city-select-section {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 0;
}
.city-select-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px 36px;
  max-width: 520px;
  margin: 0 auto;
  text-align: center;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  position: relative;
}
.city-select-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--gold), var(--accent), transparent);
  border-radius: 2px;
}
.city-select-icon { font-size: 48px; margin-bottom: 16px; }
.city-select-box h1 {
  font-family: var(--font-zh);
  font-size: 24px;
  color: var(--text-main);
  font-weight: 700;
  margin-bottom: 8px;
}
.city-select-box p {
  font-size: 14px;
  color: var(--text-dim);
  margin-bottom: 28px;
}
.city-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}
.city-btn {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), #9a1a12);
  color: #fff;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 14px;
  transition: all 0.2s;
  border: 1px solid rgba(201,168,76,0.2);
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 2px 8px rgba(181,35,26,0.2);
  min-width: 140px;
}
.city-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(181,35,26,0.3);
  color: #fff;
  background: linear-gradient(135deg, var(--accent2), var(--accent));
}

/* ===== CATALOG SIMPLE ===== */
.catalog-simple { padding: 24px 0 44px; }
.catalog-city-bar {
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 2px solid;
  border-image: linear-gradient(90deg, var(--accent), var(--gold), transparent) 1;
}
.catalog-city-bar h2 {
  font-family: var(--font-zh);
  font-size: 22px;
  font-weight: 700;
  color: var(--text-main);
}

/* ===== BUY BUTTON ===== */
.btn-buy {
  padding: 8px 20px;
  font-size: 13px;
  text-align: center;
  white-space: nowrap;
}

/* ===== FOOTER LINKS ROW ===== */
.footer-links-row { display: flex; gap: 16px; }
.footer-links-row a { color: rgba(245,237,224,0.5); font-size: 12px; }
.footer-links-row a:hover { color: var(--gold); }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .admin-grid { grid-template-columns: 1fr; }
  .admin-form { position: static; }
  .admin-top-panels { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .page-layout { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .product-detail { grid-template-columns: 1fr; }
  .news-full { grid-template-columns: 1fr; }
  .support-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  body { font-size: 14px; }
  .container { padding: 0 14px; }

  /* Header */
  .header-top { padding: 8px 0; }
  .logo { font-size: 18px; gap: 6px; }
  .logo-icon { width: 28px; height: 28px; font-size: 13px; }
  .logo-deco { font-size: 14px; }
  .header-links a { font-size: 11px; padding: 5px 8px; }
  .main-nav ul { flex-wrap: wrap; }
  .main-nav ul li a { padding: 8px 10px; font-size: 10px; }

  /* City select */
  .city-select-section { min-height: 60vh; padding: 24px 0; }
  .city-select-box { padding: 32px 20px; }
  .city-select-box h1 { font-size: 20px; }
  .city-select-icon { font-size: 36px; }
  .city-buttons { gap: 8px; }
  .city-btn { padding: 10px 20px; font-size: 13px; min-width: 120px; flex: 1 1 calc(50% - 8px); }

  /* Catalog */
  .catalog-city-bar h2 { font-size: 18px; }
  .products-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .product-img { height: 130px; }
  .product-body { padding: 10px; }
  .product-name { font-size: 12px; }
  .product-price-main { font-size: 14px; }
  .product-price-alt { font-size: 9px; }
  .product-meta span { font-size: 9px; padding: 1px 5px; }
  .product-actions { flex-direction: column; gap: 6px; align-items: stretch; }
  .btn-buy { width: 100%; text-align: center; padding: 10px; font-size: 13px; }
  .stock-badge { text-align: center; }

  /* Hero */
  .hero { padding: 32px 0 28px; }
  .hero-content h1 { font-size: 22px; }
  .hero-stats { gap: 18px; padding: 14px 18px; }

  /* Categories */
  .categories-grid { grid-template-columns: repeat(2, 1fr); }

  /* Admin */
  .admin-grid { grid-template-columns: 1fr; }
  .admin-form { position: static; }
  .admin-top-panels { grid-template-columns: 1fr; }
  .price-inputs { grid-template-columns: 1fr; }
  .admin-product-card { flex-direction: column; }
  .admin-product-card .ap-img { width: 100%; height: 120px; }
  .admin-product-card .ap-actions { flex-direction: row; justify-content: flex-end; }

  /* Auth */
  .auth-card { padding: 24px 18px; }

  /* Support */
  .support-grid { grid-template-columns: 1fr; }
  .support-menu { position: static; }
  .article-content { padding: 16px; }

  /* Footer */
  .footer-bottom { flex-direction: column; text-align: center; gap: 8px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 18px; }
  .footer-links-row { justify-content: center; }
}

@media (max-width: 380px) {
  .products-grid { grid-template-columns: 1fr; }
  .city-btn { flex: 1 1 100%; }
  .footer-grid { grid-template-columns: 1fr; }
}
}
