/* ============================================
   Tengzhuo Packing - Global Stylesheet
   Based on Visual_Design_Execution_Tengzhuo.md
   ============================================ */

/* ---- 0. Font Import ---- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@600;700&family=Inter:wght@400;500;600&display=swap');

/* ---- 1. CSS Variables ---- */
:root {
  /* Brand Colors */
  --color-primary: #1A56A8;
  --color-primary-hover: #123E7A;
  --color-accent: #F05A28;
  --color-accent-hover: #D4471B;

  /* Background & Surface */
  --color-bg: #FFFFFF;
  --color-surface: #F8F9FA;
  --color-border: #E2E8F0;

  /* Text Colors */
  --color-text-primary: #2D3748;
  --color-text-secondary: #718096;
  --color-white: #FFFFFF;

  /* Typography */
  --font-heading: 'Montserrat', sans-serif;
  --font-body: 'Inter', -apple-system, sans-serif;

  /* Spacing (8pt grid) */
  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 24px;
  --space-lg: 32px;
  --space-xl: 48px;
  --space-2xl: 64px;
  --space-3xl: 96px;
  --space-4xl: 120px;

  /* Layout */
  --container-max: 1440px;
  --container-content: 1200px;
  --gutter: 24px;

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 6px;

  /* Transitions */
  --transition: 0.3s ease-in-out;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 14px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
}

/* ---- 2. Base Reset ---- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text-primary);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition);
}

body img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Smooth Scroll Behavior */
html {
  scroll-behavior: smooth;
}

/* ---- 3. Typography Scale ---- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--color-text-primary);
  font-weight: 600;
  text-wrap: balance;
}

h1 {
  font-size: 56px;
  line-height: 1.2;
  font-weight: 700;
}

h2 {
  font-size: 40px;
  line-height: 1.3;
  font-weight: 600;
}

h3 {
  font-size: 24px;
  line-height: 1.4;
  font-weight: 600;
}

h4 {
  font-size: 20px;
  line-height: 1.4;
  font-weight: 600;
}

p {
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
  color: var(--color-text-primary);
}

.caption {
  font-size: 14px;
  line-height: 1.5;
  font-weight: 400;
  color: var(--color-text-secondary);
}

/* Responsive Typography */
@media (max-width: 767px) {
  h1 { font-size: 40px; }
  h2 { font-size: 32px; }
  h3 { font-size: 20px; }
  h4 { font-size: 18px; }
}

/* ---- 4. Layout System ---- */

/* Container System */
.tzp-container {
  width: 100%;
  max-width: var(--container-content);
  margin: 0 auto;
  padding-left: var(--space-md);
  padding-right: var(--space-md);
}

.tzp-container--wide {
  max-width: var(--container-max);
}

/* Section Spacing */
.tzp-section {
  padding-top: var(--space-4xl);
  padding-bottom: var(--space-4xl);
}

@media (max-width: 767px) {
  .tzp-section {
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-2xl);
  }
}

/* Section Title (centered) */
.tzp-section-title {
  text-align: center;
  margin-bottom: var(--space-2xl);
}

.tzp-section-title h2 {
  margin-bottom: var(--space-sm);
}

/* ---- 5. Button System ---- */

/* Base Button */
.tzp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius-md);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

/* Primary Button - Orange CTA */
.tzp-btn--primary {
  background-color: var(--color-accent);
  color: var(--color-white);
}

.tzp-btn--primary:hover {
  background-color: var(--color-accent-hover);
  box-shadow: 0 4px 14px rgba(240, 90, 40, 0.3);
  transform: translateY(-1px);
}

/* Secondary Button - Blue Outlined */
.tzp-btn--secondary {
  background-color: transparent;
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
}

.tzp-btn--secondary:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* Mobile Full Width */
@media (max-width: 767px) {
  .tzp-btn {
    width: 100%;
  }
}

/* ---- 6. Form Inputs ---- */

/* Form Inputs */
.tzp-input,
.tzp-select {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--color-text-primary);
  background-color: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
}

.tzp-input:focus,
.tzp-select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(26, 86, 168, 0.2);
}

.tzp-input::placeholder,
.tzp-select::placeholder {
  color: var(--color-text-secondary);
}

/* Textarea */
.tzp-textarea {
  width: 100%;
  min-height: 120px;
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--color-text-primary);
  background-color: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color var(--transition), box-shadow var(--transition);
  resize: vertical;
}

.tzp-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(26, 86, 168, 0.2);
}

/* ---- 7. B2B Components ---- */

/* Specification Table (Zebra Striping) */
.tzp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
}

.tzp-table thead {
  background-color: var(--color-surface);
}

.tzp-table th {
  padding: 16px;
  text-align: left;
  font-weight: 600;
  color: var(--color-text-primary);
  border-bottom: 2px solid var(--color-border);
}

.tzp-table td {
  padding: 16px;
  border-bottom: 1px solid var(--color-border);
}

.tzp-table tbody tr:nth-child(even) {
  background-color: var(--color-surface);
}

/* Card with Hover Effect */
.tzp-card {
  background-color: var(--color-bg);
  border-radius: var(--radius-md);
  transition: transform var(--transition), box-shadow var(--transition);
}

.tzp-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* Trust Badge Container */
.tzp-trust-badges {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
  align-items: center;
}

/* ---- 8. Animation Utilities ---- */

/* Scroll Reveal Animation */
.tzp-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 600ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 600ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.tzp-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- 9. Utility Classes ---- */

/* Spacing Utilities - Margin Top */
.tzp-mt-xs { margin-top: var(--space-xs); }
.tzp-mt-sm { margin-top: var(--space-sm); }
.tzp-mt-md { margin-top: var(--space-md); }
.tzp-mt-lg { margin-top: var(--space-lg); }
.tzp-mt-xl { margin-top: var(--space-xl); }
.tzp-mt-2xl { margin-top: var(--space-2xl); }

/* Spacing Utilities - Margin Bottom */
.tzp-mb-xs { margin-bottom: var(--space-xs); }
.tzp-mb-sm { margin-bottom: var(--space-sm); }
.tzp-mb-md { margin-bottom: var(--space-md); }
.tzp-mb-lg { margin-bottom: var(--space-lg); }
.tzp-mb-xl { margin-bottom: var(--space-xl); }
.tzp-mb-2xl { margin-bottom: var(--space-2xl); }

/* Text Color Utilities */
.tzp-text-primary { color: var(--color-text-primary); }
.tzp-text-secondary { color: var(--color-text-secondary); }
.tzp-text-accent { color: var(--color-accent); }
.tzp-text-white { color: var(--color-white); }

/* Background Utilities */
.tzp-bg-surface { background-color: var(--color-surface); }
.tzp-bg-primary { background-color: var(--color-primary); }
.tzp-bg-white { background-color: var(--color-white); }

/* Text Alignment */
.tzp-text-left { text-align: left; }
.tzp-text-center { text-align: center; }
.tzp-text-right { text-align: right; }

/* Display Utilities */
.tzp-hidden { display: none; }
@media (max-width: 767px) {
  .tzp-hidden-mobile { display: none; }
}
@media (min-width: 768px) {
  .tzp-hidden-desktop { display: none; }
}

/* ========================================
   Top Bar Styles (Auxiliary Navigation)
   ======================================== */

.top-bar {
  background-color: #F8F9FA;
  border-bottom: 1px solid #E2E8F0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  position: relative;
  z-index: 100 !important;
  display: block !important;
  pointer-events: auto !important;
}

.top-bar.is-hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.top-bar-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 32px;
  min-height: 45px;
}

.top-bar-menu {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.top-bar-item {
  position: relative;
}

.top-bar-link {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #4A5568;
  text-decoration: none;
  transition: color 0.3s ease;
  display: block;
  padding: 12px 0;
}

.top-bar-link:hover,
.top-bar-link.is-active {
  color: #1A56A8;
}

/* Top Bar Dropdown */
.top-bar-dropdown {
  position: absolute !important;
  top: 100% !important;
  left: 0 !important;
  background: #FFFFFF !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
  border-radius: 4px !important;
  min-width: 220px !important;
  padding: 8px 0 !important;
  list-style: none !important;
  margin: 0 !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transform: translateY(-10px) !important;
  transition: all 0.3s ease !important;
  z-index: 1000 !important;
}

.top-bar-item:hover .top-bar-dropdown {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateY(0) !important;
}

.top-bar-dropdown li {
  margin: 0;
}

.top-bar-dropdown a {
  display: block;
  padding: 10px 20px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #2D3748;
  text-decoration: none;
  transition: all 0.2s ease;
}

.top-bar-dropdown a:hover {
  background-color: #F7FAFC;
  color: #1A56A8;
  padding-left: 24px;
}

/* Download Catalog Button */
.btn-top-bar-catalog {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #1A56A8;
  background: transparent;
  border: 1px solid #1A56A8;
  padding: 8px 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.btn-top-bar-catalog:hover {
  background-color: #1A56A8;
  color: #FFFFFF;
}

/* Header Wrapper */
.pl-header-wrapper {
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  background: #FFFFFF !important;
}

.navbar {
  position: relative;
  z-index: 10;
}

/* 防止导航链接文字换行 */
.nav-link {
  white-space: nowrap !important;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
  .top-bar {
    display: none !important;
  }
}
