/*
 * ════════════════════════════════════════════════════════════════
 *  CHOCO Technology — Header / Footer / CTA Band Shared Styles
 *  Scoped: .topbar / .nav / .mobile-menu / .cta-band / .footer / .float-wa / .back-top
 *  Source: 静态页面/index.html inline <style>
 *    §2  Topbar         (125-165)
 *    §3  Main Nav       (169-298)
 *    §4  Mobile Menu    (301-333)
 *    §6  Section Head   (589-614, partial)
 *    §12 CTA Band       (1134-1234)
 *    §13 Footer         (1237-1325)
 *    §14 Float buttons  (1328-1357)
 *    §RWD Responsive    (1486, 1494-1524)
 *  不污染全局 body/reset，可与旧 CSS 共存
 * ════════════════════════════════════════════════════════════════
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ── Design Tokens (additive) ───────────────────────────────────── */
:root {
  --choco-red:        #D42B2B;
  --choco-red-dark:   #B52020;
  --choco-red-light:  #FBF0F0;
  --choco-blue:       #1539A0;
  --choco-black:      #0B0B0B;
  --choco-dark:       #111111;
  --choco-dark2:      #1E1E1E;
  --choco-mid:        #5A5A5A;
  --choco-muted:      #8A8A8A;
  --choco-border:     #E4E4E4;
  --choco-light:      #F6F6F6;
  --choco-white:      #FFFFFF;
  --choco-font:       'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --choco-max:        1400px;
}

/* ── Scoped Reset (仅作用于容器内) ─────────────────────────────── */
.topbar, .topbar *,
.nav, .nav *,
.mobile-menu, .mobile-menu *,
.cta-band, .cta-band *,
.footer, .footer *,
.float-wa, .back-top {
  box-sizing: border-box;
  font-family: var(--choco-font);
  -webkit-font-smoothing: antialiased;
}
.topbar a, .nav a, .mobile-menu a,
.cta-band a, .footer a {
  text-decoration: none;
  color: inherit;
}
.topbar ul, .nav ul, .footer ul { list-style: none; margin: 0; padding: 0; }
.nav img, .footer img, .cta-band img { display: block; max-width: 100%; }
.cta-band button, .footer button {
  font-family: var(--choco-font);
  cursor: pointer;
  border: none;
  background: none;
}
.cta-band h2, .cta-band h3, .footer h4 { margin: 0; }
.cta-band p { margin: 0; }

/* ════════════════════════════════════════════════════════════════
   1. TOPBAR
   ════════════════════════════════════════════════════════════════ */
.topbar {
  background: var(--choco-dark2);
  height: 38px;
  font-size: 12.5px;
  color: rgba(255,255,255,.6);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.topbar-inner {
  max-width: var(--choco-max);
  margin: 0 auto;
  padding: 0 40px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.topbar-left { display: flex; align-items: center; gap: 24px; }
.topbar-left a {
  display: flex; align-items: center; gap: 5px;
  color: rgba(255,255,255,.6);
  transition: color .2s;
  font-size: 12px;
}
.topbar-left a:hover { color: #fff; }
.topbar-wa {
  display: flex; align-items: center; gap: 5px;
  color: #4ade80;
  font-weight: 500;
  font-size: 12px;
}
.topbar-right { display: flex; align-items: center; gap: 16px; }
.topbar-right a {
  font-size: 12px;
  color: rgba(255,255,255,.5);
  transition: color .2s;
}
.topbar-right a:hover { color: rgba(255,255,255,.9); }
.topbar-divider {
  width: 1px; height: 12px;
  background: rgba(255,255,255,.15);
}

/* ════════════════════════════════════════════════════════════════
   2. MAIN NAVIGATION
   ════════════════════════════════════════════════════════════════ */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--choco-white);
  color: var(--choco-dark); /* 兜底字色，防止 body{color:#fff} 沿 .nav a{color:inherit} 链路把 nav 链接染白 */
  border-bottom: 1px solid var(--choco-border);
  box-shadow: 0 1px 0 rgba(0,0,0,.04);
  transition: box-shadow .3s;
}
.nav.scrolled { box-shadow: 0 2px 20px rgba(0,0,0,.1); }
.nav-inner {
  max-width: var(--choco-max);
  margin: 0 auto;
  padding: 0 48px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.nav-logo { flex-shrink: 0; }
.nav-logo img { height: 56px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  flex: 1;
  margin-left: 16px;
}
.nav-item { position: relative; }
.nav-link {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 0 16px;
  height: 80px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--choco-dark);
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color .2s, border-color .2s;
}
.nav-link:hover,
.nav-item:hover > .nav-link,
.nav-link.active {
  color: var(--choco-red);
  border-bottom-color: var(--choco-red);
}
.nav-chevron { font-size: 8px; opacity: .5; margin-top: 1px; }

.nav-drop {
  display: none;
  position: absolute;
  top: calc(100% + 1px);
  left: 0;
  min-width: 210px;
  background: var(--choco-white);
  border: 1px solid var(--choco-border);
  border-top: 2px solid var(--choco-red);
  box-shadow: 0 8px 32px rgba(0,0,0,.1);
  z-index: 999;
  padding: 6px 0;
}
.nav-item:hover .nav-drop { display: block; }
.nav-drop a {
  display: block;
  padding: 9px 20px;
  font-size: 13px;
  color: var(--choco-mid);
  transition: color .15s, background .15s, padding-left .15s;
}
.nav-drop a:hover {
  color: var(--choco-red);
  background: var(--choco-red-light);
  padding-left: 26px;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.nav-icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  color: var(--choco-mid);
  font-size: 16px;
  transition: color .2s, background .2s;
}
.nav-icon-btn:hover { color: var(--choco-red); background: var(--choco-red-light); }
.nav-cta {
  padding: 9px 22px;
  background: var(--choco-red);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  border-radius: 3px;
  letter-spacing: .02em;
  transition: background .2s, transform .15s;
  white-space: nowrap;
}
.nav-cta:hover { background: var(--choco-red-dark); transform: translateY(-1px); }

.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
  cursor: pointer;
}
.nav-burger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--choco-dark);
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}

/* ════════════════════════════════════════════════════════════════
   3. MOBILE MENU
   ════════════════════════════════════════════════════════════════ */
.mobile-menu {
  display: none;
  position: fixed;
  top: 119px;
  left: 0; right: 0;
  z-index: 997;
  background: var(--choco-white);
  color: var(--choco-dark); /* 同 .nav，兜底字色防被 body{color:#fff} 继承覆盖 */
  border-bottom: 1px solid var(--choco-border);
  box-shadow: 0 8px 24px rgba(0,0,0,.1);
  padding: 8px 0 24px;
  flex-direction: column;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 500;
  color: var(--choco-dark);
  border-bottom: 1px solid var(--choco-border);
  transition: color .2s;
}
.mobile-menu a:hover { color: var(--choco-red); }
.mobile-menu .mobile-cta {
  margin: 16px 24px 0;
  display: block;
  padding: 12px;
  background: var(--choco-red);
  color: #fff;
  text-align: center;
  border-radius: 3px;
  font-weight: 600;
  font-size: 14px;
}

/* ════════════════════════════════════════════════════════════════
   4. CTA BAND (Section Head + CTA Band + Form)
   ════════════════════════════════════════════════════════════════ */
.sec-eyebrow {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--choco-red);
  margin-bottom: 10px;
}
.sec-h2 {
  font-size: clamp(24px, 2.8vw, 38px);
  font-weight: 800;
  line-height: 1.18;
  color: var(--choco-dark);
  letter-spacing: -.02em;
  margin-bottom: 14px;
}
.sec-h2-light { color: #fff; }

.cta-band {
  position: relative;
  overflow: hidden;
  background: var(--choco-black);
}
.cta-band-bg {
  position: absolute;
  inset: 0;
}
.cta-band-bg img {
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: .25;
  filter: grayscale(40%);
}
.cta-band-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(11,11,11,.85) 0%, rgba(11,11,11,.65) 100%);
}
.cta-band-inner {
  position: relative;
  z-index: 2;
  max-width: var(--choco-max);
  margin: 0 auto;
  padding: 80px 80px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.cta-text .sec-eyebrow { color: rgba(255,255,255,.5); }
.cta-text .sec-h2 { color: #fff; }
.cta-text p {
  font-size: 15px;
  color: rgba(255,255,255,.6);
  line-height: 1.8;
  margin-top: 14px;
}
.cta-form {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 6px;
  padding: 36px 32px;
  backdrop-filter: blur(12px);
}
.cta-form h3 {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 20px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
.form-field { display: flex; flex-direction: column; gap: 5px; }
.form-label {
  font-size: 11.5px;
  font-weight: 600;
  color: rgba(255,255,255,.55);
  letter-spacing: .05em;
  text-transform: uppercase;
}
.form-input,
.form-select,
.form-textarea {
  font-family: var(--choco-font);
  font-size: 13.5px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 3px;
  color: #fff;
  padding: 10px 13px;
  transition: border-color .2s;
  outline: none;
  width: 100%;
}
.form-input::placeholder,
.form-textarea::placeholder { color: rgba(255,255,255,.25); }
.form-input:focus,
.form-select:focus,
.form-textarea:focus { border-color: var(--choco-red); }
.form-select option { background: var(--choco-dark2); color: #fff; }
.form-textarea { resize: vertical; min-height: 80px; }
.form-full { grid-column: span 2; }
.form-submit {
  width: 100%;
  padding: 13px;
  background: var(--choco-red);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  border-radius: 3px;
  letter-spacing: .04em;
  transition: background .2s, transform .15s;
  margin-top: 4px;
}
.form-submit:hover { background: var(--choco-red-dark); transform: translateY(-1px); }

/* ════════════════════════════════════════════════════════════════
   5. FOOTER (正式版，替换之前占位)
   ════════════════════════════════════════════════════════════════ */
.footer {
  background: var(--choco-black);
  color: rgba(255,255,255,.55);
  padding: 56px 40px 0;
}
.footer-inner {
  max-width: var(--choco-max);
  margin: 0 auto;
}
.footer-top {
  display: grid;
  grid-template-columns: 260px 1fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.footer-brand { display: flex; flex-direction: column; gap: 16px; }
.footer-logo {
  display: inline-block;
  background: #fff;
  border-radius: 6px;
  padding: 8px 14px;
  line-height: 0;
  width: fit-content;
}
.footer-logo img { height: 34px; width: auto; filter: none; }
.footer-tagline {
  font-size: 13px;
  line-height: 1.7;
  color: rgba(255,255,255,.4);
}
.footer-contact { display: flex; flex-direction: column; gap: 8px; }
.footer-contact a {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: rgba(255,255,255,.45);
  transition: color .2s;
}
.footer-contact a:hover { color: #fff; }
.footer-social { display: flex; gap: 10px; margin-top: 4px; }
.social-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.12);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  color: rgba(255,255,255,.45);
  transition: all .2s;
}
.social-btn:hover { border-color: var(--choco-red); color: var(--choco-red); background: rgba(212,43,43,.1); }

.footer-col h4 {
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--choco-red);
}
.footer-col ul { display: flex; flex-direction: column; gap: 9px; }
.footer-col ul a {
  font-size: 13px;
  color: rgba(255,255,255,.45);
  transition: color .2s, padding-left .15s;
  display: block;
}
.footer-col ul a:hover { color: #fff; padding-left: 4px; }

.footer-bottom {
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: rgba(255,255,255,.25);
  flex-wrap: wrap;
  gap: 12px;
}
.footer-bottom a { color: rgba(255,255,255,.3); transition: color .2s; }
.footer-bottom a:hover { color: rgba(255,255,255,.7); }
.footer-bottom-links { display: flex; gap: 20px; }

/* ════════════════════════════════════════════════════════════════
   6. FLOATING BUTTONS
   ════════════════════════════════════════════════════════════════ */
.float-wa {
  position: fixed;
  right: 22px; bottom: 76px;
  z-index: 900;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px;
  box-shadow: 0 4px 20px rgba(37,211,102,.45);
  transition: transform .3s;
}
.float-wa:hover { transform: scale(1.1); }
.back-top {
  position: fixed;
  right: 22px; bottom: 18px;
  z-index: 900;
  width: 40px; height: 40px;
  border-radius: 3px;
  background: var(--choco-red);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  cursor: pointer;
  transition: opacity .3s, transform .2s;
}
.back-top:hover { transform: translateY(-2px); }

/* ════════════════════════════════════════════════════════════════
   7. RESPONSIVE
   ════════════════════════════════════════════════════════════════ */
@media (max-width: 1200px) {
  .footer-top { grid-template-columns: 220px repeat(4, 1fr); gap: 32px; }
}
@media (max-width: 1024px) {
  .cta-band-inner { padding: 64px 48px; gap: 48px; }
  .footer-top { grid-template-columns: repeat(3, 1fr); }
  .footer-brand { grid-column: span 3; }
}
@media (max-width: 768px) {
  .topbar { display: none; }
  .nav-links { display: none; }
  .nav-icon-btn { display: none; }
  .nav-burger { display: flex; }
  .nav-inner { padding: 0 20px; }
  .cta-band-inner { grid-template-columns: 1fr; padding: 48px 24px; gap: 32px; }
  .form-row { grid-template-columns: 1fr; }
  .form-full { grid-column: span 1; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-brand { grid-column: span 2; }
  .footer-bottom { flex-direction: column; gap: 8px; }
}
