:root {
  --bg: #ffffff;
  --ink: #222;
  --muted: #888;
  --line: #e8e8e8;
  --card: #ffffff;
  --panel: #f7f7f7;
  --accent: #e4393c;
  --accent-dark: #c62828;
  --teal: #0f766e;
  --ok: #047857;
  --danger: #b91c1c;
  --sans: "Segoe UI", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background: #ffffff;
  font-family: var(--sans);
  line-height: 1.5;
  min-height: 100vh;
}
a { color: #333; text-decoration: none; }
a:hover { color: var(--accent); }
.container { width: min(1440px, 100%); margin: 0 auto; padding: 0 20px; }
.narrow { width: min(780px, 100%); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.inline-form { display: inline; margin: 0; }

/* Header — Made-in-China style */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.header-top {
  display: grid;
  grid-template-columns: 220px 1fr auto;
  gap: 20px;
  align-items: center;
  min-height: 72px;
  padding: 10px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
}
.brand:hover { color: var(--ink); }
.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, #e4393c, #ff7a45);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 800;
}
.brand-text {
  font-size: 15px;
  line-height: 1.2;
  max-width: 160px;
}
.search-bar {
  display: flex;
  align-items: stretch;
  border: 2px solid var(--accent);
  border-radius: 4px;
  overflow: hidden;
  background: #fff;
  height: 40px;
}
.search-bar select {
  border: 0;
  border-right: 1px solid #eee;
  padding: 0 10px;
  background: #fafafa;
  color: #555;
  max-width: 120px;
  font: inherit;
}
.search-bar input {
  flex: 1;
  border: 0;
  padding: 0 12px;
  font: inherit;
  min-width: 0;
  outline: none;
}
.search-btn {
  width: 56px;
  border: 0;
  background: var(--accent);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.ha-item, .ha-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 64px;
  padding: 4px 6px;
  color: #555;
  font-size: 12px;
  background: none;
  border: 0;
  cursor: pointer;
  font-family: inherit;
}
.ha-item:hover, .ha-btn:hover { color: var(--accent); }
.ha-accent { color: var(--accent); font-weight: 600; }
.ha-icon { font-size: 16px; line-height: 1; }

.subnav {
  background: #f5f5f5;
  border-top: 1px solid #eee;
}
.subnav-inner {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  min-height: 40px;
  align-items: center;
  font-size: 13px;
}
.subnav-left, .subnav-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.subnav a { color: #444; }
.all-cats {
  font-weight: 700;
  color: #222 !important;
  padding-right: 12px;
  border-right: 1px solid #ddd;
}

/* Promo strip */
.promo-banner {
  background: linear-gradient(90deg, #fff4ec, #eef6ff 40%, #fff4ec);
  border-bottom: 1px solid #f0e6dc;
}
.promo-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 56px;
  padding: 10px 0;
  flex-wrap: wrap;
}
.promo-copy {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: #555;
}
.promo-copy strong {
  color: #222;
  font-size: 16px;
}
.promo-btn {
  background: #ff7a00;
  color: #fff !important;
  padding: 8px 18px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 13px;
}
.promo-btn:hover { filter: brightness(1.05); color: #fff; }

/* Home 3-column */
.home-main { padding: 16px 0 8px; background: #fff; }
.home-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 240px;
  gap: 12px;
  align-items: stretch;
}
.cat-panel, .like-panel {
  border: 1px solid var(--line);
  background: #fff;
  min-width: 0;
  overflow: hidden;
}
.cat-title, .like-title {
  padding: 12px 14px;
  font-weight: 700;
  border-bottom: 1px solid var(--line);
  background: #fafafa;
}
.cat-list {
  list-style: none;
  margin: 0;
  padding: 6px 0;
}
.cat-list li a {
  display: block;
  padding: 9px 14px;
  color: #333;
  font-size: 13px;
}
.cat-list li a:hover {
  background: #fff5f5;
  color: var(--accent);
}
.cat-more {
  display: block;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: #666;
}

.home-center { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.hero-banner {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  min-height: 280px;
  border-radius: 4px;
  overflow: hidden;
  background: linear-gradient(120deg, #5b2c8a 0%, #c2185b 55%, #f48fb1 100%);
  color: #fff;
}
.hero-banner-copy {
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero-kicker {
  margin: 0 0 8px;
  opacity: 0.85;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.hero-banner h1 {
  margin: 0 0 10px;
  font-size: clamp(1.4rem, 2.4vw, 2rem);
  line-height: 1.25;
  font-weight: 800;
}
.hero-banner-copy > p {
  margin: 0 0 18px;
  opacity: 0.92;
  max-width: 34rem;
  font-size: 14px;
}
.hero-banner-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-red, .btn, .btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 16px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 13px;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-red, .btn {
  background: var(--accent);
  color: #fff !important;
  border-color: var(--accent);
}
.btn-ghost {
  background: rgba(255,255,255,0.15);
  color: #fff !important;
  border-color: rgba(255,255,255,0.45);
}
.btn-outline {
  background: #fff;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 4px;
  padding: 9px 16px;
  font-weight: 700;
}
.btn-sm { padding: 6px 12px; font-size: 12px; }
.hero-banner-side {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  padding: 18px;
  background: rgba(0,0,0,0.12);
}
.hero-mini {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255,255,255,0.16);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 8px 10px;
  color: #fff !important;
  font-size: 13px;
}
.hero-mini-avatar {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: #fff;
  color: #c2185b;
  display: grid;
  place-items: center;
  font-weight: 800;
  flex-shrink: 0;
}

.feature-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.feature-card {
  border: 1px solid var(--line);
  background: #fff;
  padding: 14px 12px;
  min-height: 88px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.feature-card strong {
  font-size: 14px;
  color: #222;
}
.feature-card span {
  font-size: 12px;
  color: #888;
  line-height: 1.4;
}
.feature-card:hover {
  border-color: #f5b7b1;
  box-shadow: 0 2px 8px rgba(228, 57, 60, 0.08);
}

.like-list { padding: 8px 10px; display: grid; gap: 8px; min-width: 0; }
.like-item {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 6px;
  border-radius: 4px;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}
.like-item:hover { background: #fafafa; }
.like-thumb {
  width: 48px;
  height: 48px;
  border-radius: 4px;
  background: linear-gradient(135deg, #ffe8e8, #fff);
  border: 1px solid #f0f0f0;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: var(--accent);
  flex-shrink: 0;
}
.like-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}
.like-meta strong {
  display: block;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.like-meta em {
  display: block;
  font-style: normal;
  font-size: 12px;
  color: #999;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.like-empty { padding: 16px 8px; font-size: 13px; }
.like-cta {
  display: block;
  margin: 8px 12px 14px;
  text-align: center;
  border: 1px solid var(--accent);
  color: var(--accent) !important;
  border-radius: 4px;
  padding: 10px 12px;
  font-weight: 700;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.like-cta:hover { background: #fff5f5; }

/* Trending / companies */
.section { padding: 24px 0 40px; }
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 16px;
}
.section-head h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 800;
}
.company-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.company-card, .card, .list-item, .form-box {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 16px;
}
.company-card-top {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 10px;
}
.company-avatar {
  width: 44px;
  height: 44px;
  border-radius: 4px;
  background: #f5f5f5;
  border: 1px solid #eee;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: var(--accent);
  flex-shrink: 0;
}
.company-card h3 {
  margin: 0 0 4px;
  font-size: 15px;
  line-height: 1.3;
}
.company-excerpt {
  margin: 0;
  color: #666;
  font-size: 13px;
  line-height: 1.45;
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.list { display: grid; gap: 14px; }

/* Shared forms / inner pages */
.filters {
  display: grid;
  grid-template-columns: 1.5fr 1fr auto;
  gap: 10px;
  margin: 16px 0 20px;
}
.filters input, .filters select, .form input, .form select, .form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
}
.form { display: grid; gap: 14px; margin-top: 16px; }
.form label { display: grid; gap: 6px; font-weight: 600; font-size: 0.92rem; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}
.detail-grid .label {
  display: block;
  color: var(--muted);
  font-size: 0.85rem;
  margin-bottom: 4px;
}
.prose { margin-top: 24px; }
.prose p { white-space: pre-wrap; }
.breadcrumb { color: var(--muted); margin-bottom: 12px; }
.steps { padding-left: 1.2rem; }
.pager { display: flex; gap: 16px; align-items: center; margin-top: 24px; }
.row-between { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.row-actions { display: flex; gap: 14px; margin-top: 8px; }
.status {
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 999px;
  background: #e7e5e4;
}
.status-pending { background: #fef3c7; color: #92400e; }
.status-approved { background: #d1fae5; color: #065f46; }
.status-rejected { background: #fee2e2; color: #991b1b; }
.flash {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 4px;
}
.flash-error { background: #fee2e2; color: var(--danger); }
.flash-ok { background: #d1fae5; color: var(--ok); }
.flash-inline { color: var(--danger); }
.chip-row { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 14px;
  color: var(--ink);
}
.lead { font-size: 1.05rem; color: var(--muted); max-width: 40rem; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

.site-footer {
  border-top: 1px solid var(--line);
  padding: 32px 0 40px;
  color: var(--muted);
  background: #fafafa;
  margin-top: 24px;
  font-size: 13px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 24px;
}
.footer-grid strong {
  display: block;
  color: #333;
  margin-bottom: 8px;
}
.footer-grid p { margin: 0 0 6px; }

@media (max-width: 1024px) {
  .home-grid { grid-template-columns: 200px minmax(0, 1fr); }
  .like-panel { display: none; }
  .feature-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .company-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .header-top { grid-template-columns: 1fr; gap: 10px; }
  .header-actions { justify-content: flex-start; }
}
@media (max-width: 720px) {
  .home-grid { grid-template-columns: 1fr; }
  .cat-panel { display: none; }
  .hero-banner { grid-template-columns: 1fr; min-height: auto; }
  .hero-banner-side { display: none; }
  .feature-row, .company-grid, .form-grid, .detail-grid, .filters, .footer-grid { grid-template-columns: 1fr; }
  .subnav-right { display: none; }
}

/* Auth pages — Made-in-China login style */
.auth-body {
  background: #fff;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.auth-header {
  background: #fff;
  border-bottom: 1px solid #eee;
}
.auth-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 16px;
}
.auth-header .brand-text-wrap {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.auth-header .brand-text {
  max-width: none;
  font-size: 18px;
}
.brand-tagline {
  font-size: 12px;
  color: #888;
  font-weight: 400;
}
.auth-home-link {
  color: #666;
  font-size: 13px;
}
.auth-hero {
  flex: 1;
  background:
    linear-gradient(90deg, rgba(20, 40, 70, 0.55) 0%, rgba(20, 35, 60, 0.72) 42%, #1b2a44 70%, #16233a 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1600' height='900' viewBox='0 0 1600 900'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop stop-color='%234a6fa5'/%3E%3Cstop offset='1' stop-color='%232c3e5a'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect width='1600' height='900' fill='url(%23g)'/%3E%3Ccircle cx='420' cy='420' r='220' fill='%23ffffff' fill-opacity='0.06'/%3E%3Ccircle cx='980' cy='260' r='160' fill='%23ffffff' fill-opacity='0.05'/%3E%3C/svg%3E") center/cover no-repeat;
  padding: 48px 0 56px;
}
.auth-hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
  min-height: 480px;
}
.auth-about {
  color: #fff;
  max-width: 520px;
  padding: 12px 8px;
}
.auth-about h1 {
  margin: 0 0 22px;
  font-size: 34px;
  font-weight: 700;
}
.auth-about ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 16px;
}
.auth-about li {
  font-size: 16px;
  line-height: 1.55;
  opacity: 0.95;
}
.auth-about strong {
  color: #fff;
  font-size: 1.15em;
}
.auth-card {
  width: min(420px, 100%);
  margin-left: auto;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28);
  padding: 28px 32px 24px;
}
.auth-tabs {
  display: flex;
  gap: 28px;
  border-bottom: 1px solid #eee;
  margin-bottom: 22px;
}
.auth-tabs a {
  position: relative;
  padding: 0 0 12px;
  color: #666;
  font-size: 16px;
  font-weight: 600;
}
.auth-tabs a.active {
  color: #222;
}
.auth-tabs a.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  background: #e4393c;
  border-radius: 2px 2px 0 0;
}
.auth-form {
  display: grid;
  gap: 16px;
}
.auth-form label {
  display: grid;
  gap: 8px;
  font-size: 13px;
  color: #555;
  font-weight: 500;
}
.auth-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.auth-form input {
  width: 100%;
  height: 42px;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  padding: 0 12px;
  font: inherit;
  background: #fff;
}
.auth-form input:focus {
  outline: none;
  border-color: #e4393c;
  box-shadow: 0 0 0 2px rgba(228, 57, 60, 0.12);
}
.auth-btn-primary,
.auth-btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
}
.auth-btn-primary {
  border: 0;
  background: #e4393c;
  color: #fff !important;
  margin-top: 6px;
}
.auth-btn-primary:hover { filter: brightness(1.05); color: #fff; }
.auth-btn-secondary {
  border: 1px solid #d0d0d0;
  background: #fff;
  color: #333 !important;
}
.auth-btn-secondary:hover {
  border-color: #e4393c;
  color: #e4393c !important;
}
.auth-help {
  margin: 18px 0 0;
  text-align: center;
  font-size: 13px;
  color: #888;
}
.auth-help a { color: #1677ff; }
.auth-footer {
  background: #f7f7f7;
  border-top: 1px solid #eee;
  padding: 28px 0 20px;
  color: #666;
  font-size: 13px;
}
.auth-footer-inner {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 16px;
}
.auth-footer-inner strong {
  display: block;
  color: #333;
  margin-bottom: 8px;
}
.auth-footer-inner a {
  display: block;
  color: #666;
  margin-bottom: 6px;
}
.auth-copy {
  color: #999;
  font-size: 12px;
  padding-top: 8px;
  border-top: 1px solid #eaeaea;
}
@media (max-width: 900px) {
  .auth-hero-grid { grid-template-columns: 1fr; min-height: auto; gap: 24px; }
  .auth-about { max-width: none; }
  .auth-card { margin: 0 auto; }
  .auth-footer-inner { grid-template-columns: 1fr; }
}

