/* ==========================================================================
   Kuangcai Stationery — inner pages (products / product / about)
   Extends the design tokens declared in home-v2.css (deep navy #014099).
   Loaded AFTER home-v2.css, so it can refine .wrap / .btn / .hd / .ft.
   ========================================================================== */

/* ---------- page banner ---------- */
.pb { position: relative; background: #0b2c5c; color: #fff; overflow: hidden; }
.pb-bg { position: absolute; inset: 0; }
.pb-bg img { width: 100%; height: 100%; object-fit: cover; opacity: .3; }
.pb::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(4,24,50,.92) 0%, rgba(4,24,50,.68) 55%, rgba(4,24,50,.44) 100%);
}
.pb-in { position: relative; z-index: 2; max-width: var(--maxw); margin: 0 auto; padding: 60px 24px 56px; }
.pb-in h1 { font-size: 38px; font-weight: 700; letter-spacing: -.02em; }
.pb-in .lead { margin: 14px 0 0; max-width: 680px; color: rgba(255,255,255,.84); font-size: 16px; }
@media (max-width: 760px) {
  .pb-in { padding: 42px 24px 40px; }
  .pb-in h1 { font-size: 27px; }
  .pb-in .lead { font-size: 15px; }
}

/* ---------- breadcrumbs ---------- */
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; font-size: 13px; color: var(--ink-3); }
.crumbs a { color: var(--ink-3); }
.crumbs a:hover { color: var(--brand); }
.crumbs .sep { opacity: .45; }
.crumbs b { color: var(--ink); font-weight: 600; }
.crumbbar { border-bottom: 1px solid var(--line); background: #fff; }
.crumbbar .wrap { padding-top: 20px; padding-bottom: 20px; }
.pb .crumbs { color: rgba(255,255,255,.7); margin-bottom: 18px; }
.pb .crumbs a { color: rgba(255,255,255,.7); }
.pb .crumbs a:hover { color: #fff; }
.pb .crumbs b { color: #fff; }

/* ---------- page section shells ---------- */
.page { padding: 56px 0 88px; }
.page-tight { padding: 34px 0 0; }
.sec-head-l { margin-bottom: 34px; }
.sec-head-l h2 { font-size: 27px; letter-spacing: -.015em; }
.sec-head-l .rule { width: 44px; height: 3px; background: var(--brand); border-radius: 2px; margin: 16px 0 0; }

/* ---------- toolbar / filters ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 18px; }
.toolbar input[type="search"],
.toolbar select,
.field input,
.field select,
.field textarea {
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  font-family: inherit;
  background: #fff;
  color: var(--ink);
  transition: border-color .18s, box-shadow .18s;
}
.toolbar input[type="search"]:focus,
.toolbar select:focus,
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(1,64,153,.1);
}
.toolbar input[type="search"] { flex: 1; min-width: 240px; }
.toolbar select { min-width: 172px; cursor: pointer; }
.result-count { color: var(--ink-3); font-size: 14px; margin-bottom: 20px; }

/* ---------- product grid ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(238px, 1fr)); gap: 22px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column; position: relative;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 14px 34px rgba(1,64,153,.12); border-color: #d3ddec; }
.card .thumb { display: block; aspect-ratio: 1 / 1; background: var(--bg-soft); overflow: hidden; position: relative; }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.card:hover .thumb img { transform: scale(1.05); }
.card .ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 42px; color: #b9c4d2; }
.card .body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.card .cat { font-size: 11.5px; font-weight: 700; color: var(--brand); text-transform: uppercase; letter-spacing: .08em; }
.card h3 { font-size: 15px; font-weight: 600; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 43px; }
.card h3 a { color: var(--ink); }
.card h3 a:hover { color: var(--brand); }
.card .foot { margin-top: auto; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.price { font-size: 20px; font-weight: 700; color: var(--brand); letter-spacing: -.02em; }
.moq { font-size: 12px; color: var(--ink-3); }
.badge {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  background: var(--brand); color: #fff; font-size: 10.5px; font-weight: 700;
  padding: 4px 10px; border-radius: 999px; letter-spacing: .08em;
}
@media (max-width: 620px) { .grid { grid-template-columns: repeat(2, 1fr); gap: 13px; } .card .body { padding: 12px 13px 14px; } .card h3 { font-size: 13.5px; min-height: 39px; } .price { font-size: 17px; } }

/* ---------- pagination ---------- */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 44px; flex-wrap: wrap; }
.pagination button {
  min-width: 40px; padding: 9px 13px; border: 1px solid var(--line); background: #fff;
  border-radius: var(--radius-sm); cursor: pointer; font-weight: 600; font-size: 14px;
  color: var(--ink); font-family: inherit; transition: all .16s;
}
.pagination button:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
.pagination button.current { background: var(--brand); color: #fff; border-color: var(--brand); }
.pagination button:disabled { opacity: .4; cursor: not-allowed; }

/* ---------- empty / loading ---------- */
.empty { text-align: center; padding: 74px 24px; color: var(--ink-3); background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); }
.empty .big { font-size: 40px; margin-bottom: 12px; }
.empty h3 { color: var(--ink); margin-bottom: 8px; font-size: 18px; }
.empty a { color: var(--brand); font-weight: 600; }
.loading { text-align: center; color: var(--ink-3); padding: 64px 0; }
.spinner {
  display: inline-block; width: 18px; height: 18px; margin-right: 8px;
  border: 2.5px solid #cdd8e6; border-top-color: var(--brand); border-radius: 50%;
  animation: spin .7s linear infinite; vertical-align: -4px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- product detail ---------- */
.detail { display: grid; grid-template-columns: 460px 1fr; gap: 46px; margin-top: 40px; align-items: start; }
@media (max-width: 900px) { .detail { grid-template-columns: 1fr; gap: 30px; } }
.gallery .main-img { aspect-ratio: 1 / 1; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--bg-soft); }
.gallery .main-img img { width: 100%; height: 100%; object-fit: cover; }
.gallery .ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 70px; color: #b9c4d2; }
.thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.thumbs img { width: 74px; height: 74px; object-fit: cover; border: 2px solid var(--line); border-radius: 10px; cursor: pointer; background: var(--bg-soft); transition: border-color .16s; }
.thumbs img:hover { border-color: #b6c7de; }
.thumbs img.on { border-color: var(--brand); }
.detail h1 { font-size: 27px; line-height: 1.35; letter-spacing: -.015em; }
.price-box { background: var(--brand-soft); border-radius: var(--radius); padding: 20px 22px; margin: 20px 0; display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.price-box .price { font-size: 31px; }
.price-box .muted { color: var(--ink-2); font-size: 13px; }
.meta-row { display: flex; gap: 26px; flex-wrap: wrap; color: var(--ink-2); font-size: 14px; margin-bottom: 20px; }
.meta-row b { color: var(--ink); font-weight: 600; }
.detail h3 { font-size: 17px; margin: 24px 0 8px; }
.specs { width: 100%; border-collapse: collapse; margin: 10px 0 22px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.specs th, .specs td { border-bottom: 1px solid var(--line); padding: 10px 16px; font-size: 14px; text-align: left; }
.specs tr:last-child th, .specs tr:last-child td { border-bottom: none; }
.specs th { background: var(--bg-alt); width: 190px; color: var(--ink-2); font-weight: 600; }
.desc { color: var(--ink-2); white-space: pre-wrap; line-height: 1.75; }
.rel-sec { padding: 70px 0 0; }
.inq-sec { padding: 60px 0 0; }
.mt { margin-top: 16px; }

/* ---------- forms ---------- */
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px 32px; }
.form-card h2 { font-size: 21px; margin-bottom: 6px; }
.form-card .hint { color: var(--ink-3); font-size: 14px; margin-bottom: 20px; }
.field { margin-bottom: 15px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 7px; color: var(--ink); }
.field input, .field select, .field textarea { width: 100%; }
.field textarea { min-height: 118px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
@media (max-width: 620px) { .form-row { grid-template-columns: 1fr; } .form-card { padding: 24px 20px; } }
.msg { padding: 11px 15px; border-radius: var(--radius-sm); font-size: 14px; margin-top: 12px; display: none; }
.msg.ok { display: block; background: #ecfdf3; color: #15803d; border: 1px solid #b7ebc8; }
.msg.err { display: block; background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }

/* ---------- about / prose ---------- */
.prose { max-width: 780px; color: var(--ink-2); }
.prose h2 { color: var(--ink); font-size: 23px; margin: 36px 0 12px; letter-spacing: -.01em; }
.prose h2:first-child { margin-top: 0; }
.prose p { margin-bottom: 14px; line-height: 1.78; }
.prose a { color: var(--brand); font-weight: 600; }
.prose b { color: var(--ink); }
.about-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; margin-bottom: 26px; }
@media (max-width: 940px) { .about-pair { grid-template-columns: 1fr; gap: 32px; } }
.about-pair .collage { margin-top: 0; }
.about-pair h2 { font-size: 32px; letter-spacing: -.015em; }
.about-pair .sub { font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--brand); margin: 0 0 12px; }
.about-pair .rule { width: 44px; height: 3px; background: var(--brand); border-radius: 2px; margin: 16px 0 20px; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 42px; margin-top: 40px; align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; gap: 30px; } }
.info-list { list-style: none; padding: 0; margin: 0; }
.info-list li { display: flex; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.info-list .k { color: var(--ink-3); min-width: 118px; flex: none; }
.info-list li span:last-child { color: var(--ink); }

/* ---------- misc ---------- */
.muted { color: var(--ink-3); font-size: 13.5px; }
