/* ===== dbcx-theme.css — 北京得宝创鑫工程科技有限公司 ===== */
/* Modern Blue+White design system on top of Bootstrap 5 */

:root {
  --primary: #1a73e8;
  --primary-dark: #1557b0;
  --primary-light: #4a90d9;
  --primary-bg: #e8f0fe;
  --secondary: #34a853;
  --accent: #fbbc04;
  --neutral-100: #f8f9fa;
  --neutral-200: #e9ecef;
  --neutral-300: #dee2e6;
  --neutral-600: #6c757d;
  --neutral-800: #343a40;
  --neutral-900: #212529;
  --section-padding: 3rem 0;
  --card-radius: 12px;
  --btn-radius: 8px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --transition: 0.3s ease;
}

/* ===== GLOBAL ===== */
body {
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  color: var(--neutral-800);
  overflow-x: hidden;
}
a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; height: auto; }
.section-padding { padding: var(--section-padding); }
.section-title { margin-bottom: 2rem; }
.section-title h2 {
  font-size: 2rem; font-weight: 700; color: var(--neutral-900);
  position: relative; padding-bottom: 1rem;
}
.section-title h2::after {
  content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 60px; height: 3px; background: var(--primary); border-radius: 2px;
}
.section-title p { color: var(--neutral-600); font-size: 1.05rem; margin-top: 0.75rem; }
.bg-light-section { background: var(--neutral-100); }
.text-primary { color: var(--primary) !important; }
.bg-primary { background-color: var(--primary) !important; }

/* ===== TOP BAR ===== */
.top-bar {
  background: var(--neutral-900); color: rgba(255,255,255,0.85);
  font-size: 0.85rem; padding: 0.5rem 0;
}
.top-bar a { color: rgba(255,255,255,0.85); }
.top-bar i { margin-right: 0.35rem; color: var(--primary-light); }

/* ===== NAVBAR ===== */
.navbar { box-shadow: var(--shadow-sm); }
.navbar-brand img { height: 46px; }
.navbar .nav-link {
  font-size: 0.95rem; font-weight: 500; color: var(--neutral-800) !important;
  padding: 0.5rem 1rem !important; position: relative;
}
.navbar .nav-link:hover,
.navbar .nav-link.active { color: var(--primary) !important; }
.navbar .nav-link::after {
  content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%) scaleX(0);
  width: 60%; height: 2px; background: var(--primary); transition: transform var(--transition);
}
.navbar .nav-link:hover::after,
.navbar .nav-link.active::after { transform: translateX(-50%) scaleX(1); }

/* ===== SEARCH BOX (in navbar) ===== */
.search-toggle {
  background: none; border: none; color: var(--neutral-800);
  font-size: 1.1rem; cursor: pointer; padding: 0.5rem;
}
.search-toggle:hover { color: var(--primary); }
.search-dropdown {
  position: absolute; top: 100%; right: 0; width: 320px;
  background: white; border-radius: var(--card-radius);
  box-shadow: var(--shadow-lg); padding: 1rem; display: none; z-index: 1000;
}
.search-dropdown.show { display: block; }
.search-dropdown input {
  width: 100%; padding: 0.6rem 1rem; border: 2px solid var(--neutral-300);
  border-radius: var(--btn-radius); font-size: 0.95rem; outline: none;
  transition: border-color var(--transition);
}
.search-dropdown input:focus { border-color: var(--primary); }
.search-results-preview { max-height: 300px; overflow-y: auto; margin-top: 0.5rem; }
.search-results-preview a {
  display: block; padding: 0.5rem 0.75rem; border-radius: 6px;
  color: var(--neutral-800); font-size: 0.9rem;
}
.search-results-preview a:hover { background: var(--primary-bg); color: var(--primary); }
.search-results-preview .result-type {
  font-size: 0.75rem; color: var(--neutral-600);
  background: var(--neutral-200); padding: 1px 6px; border-radius: 3px; margin-left: 6px;
}

/* ===== HERO SECTION ===== */
.hero-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white; padding: 4rem 0 3rem;
}
.hero-section h1 { font-size: 2.6rem; font-weight: 800; }
.hero-section .lead { font-size: 1.2rem; opacity: 0.9; }
.hero-section .btn-light {
  background: white; color: var(--primary); font-weight: 600;
  padding: 0.75rem 2rem; border-radius: var(--btn-radius);
}
.hero-section .btn-outline-light {
  border: 2px solid rgba(255,255,255,0.6); color: white; font-weight: 600;
  padding: 0.75rem 2rem; border-radius: var(--btn-radius);
}
.hero-section .btn-outline-light:hover { background: rgba(255,255,255,0.15); border-color: white; }

/* Inner page hero (shorter) */
.page-hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: white; padding: 3rem 0;
}
.page-hero h1 { font-size: 2rem; font-weight: 700; }
.page-hero .breadcrumb { margin-bottom: 0; }
.page-hero .breadcrumb-item + .breadcrumb-item::before { color: rgba(255,255,255,0.5); }
.page-hero .breadcrumb-item a { color: rgba(255,255,255,0.8); }
.page-hero .breadcrumb-item.active { color: rgba(255,255,255,0.5); }

/* ===== CARDS ===== */
.card-product {
  border: none; border-radius: var(--card-radius); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform var(--transition), box-shadow var(--transition);
  background: white;
}
.card-product:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card-product .card-img-top { height: 220px; object-fit: cover; }
.card-product .card-body { padding: 1.25rem; }
.card-product .card-title {
  font-size: 1rem; font-weight: 600; margin-bottom: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.card-news {
  border: none; border-radius: var(--card-radius); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform var(--transition), box-shadow var(--transition);
  background: white; flex-direction: row;
}
.card-news:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card-news .card-img { width: 180px; min-height: 140px; object-fit: cover; }
.card-news .card-body { flex: 1; padding: 1.25rem; }
.card-news .card-date { font-size: 0.8rem; color: var(--neutral-600); margin-bottom: 0.5rem; }

.card-service {
  border: none; border-radius: var(--card-radius); padding: 2rem 1rem;
  text-align: center; box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
  background: white;
}
.card-service:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card-service .service-icon {
  width: 64px; height: 64px; margin: 0 auto 1rem;
  background: var(--primary-bg); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; color: var(--primary);
}
.card-service h4 { font-size: 1rem; font-weight: 600; margin-bottom: 0.25rem; }

.card-stat {
  border: none; border-radius: var(--card-radius); padding: 2rem 1rem;
  text-align: center; box-shadow: var(--shadow-sm); background: white;
}
.card-stat h2 { font-size: 2.5rem; font-weight: 800; color: var(--primary); margin-bottom: 0.25rem; }
.card-stat p { color: var(--neutral-600); margin-bottom: 0; }

.card-contact {
  border: none; border-radius: var(--card-radius); padding: 2rem;
  text-align: center; box-shadow: var(--shadow-sm); background: white;
  height: 100%;
}
.card-contact i { font-size: 2.5rem; color: var(--primary); margin-bottom: 1rem; }
.card-contact h5 { font-weight: 600; margin-bottom: 0.5rem; }

/* ===== PROCESS TIMELINE ===== */
.process-step {
  text-align: center; position: relative; padding: 1.5rem;
}
.process-step .step-number {
  width: 48px; height: 48px; margin: 0 auto 1rem;
  background: var(--primary); color: white; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; font-weight: 700;
}
.process-step h5 { font-weight: 600; margin-bottom: 0.5rem; }
.process-step p { font-size: 0.9rem; color: var(--neutral-600); }

/* ===== BUTTONS ===== */
.btn-primary {
  background: var(--primary); border-color: var(--primary);
  border-radius: var(--btn-radius); padding: 0.6rem 1.5rem;
  font-weight: 500;
}
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-outline-primary {
  color: var(--primary); border-color: var(--primary);
  border-radius: var(--btn-radius); padding: 0.6rem 1.5rem; font-weight: 500;
}
.btn-outline-primary:hover { background: var(--primary); border-color: var(--primary); color: white; }
.btn-light { border-radius: var(--btn-radius); padding: 0.6rem 1.5rem; font-weight: 500; }
.btn-lg { padding: 0.75rem 2rem; font-size: 1.05rem; }

/* ===== PRODUCT CATEGORY FILTER ===== */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem;
  justify-content: center;
}
.filter-btn {
  padding: 0.45rem 1.2rem; border: 1.5px solid var(--neutral-300);
  border-radius: 50px; background: white; color: var(--neutral-600);
  font-size: 0.9rem; cursor: pointer; transition: all var(--transition);
}
.filter-btn:hover { border-color: var(--primary); color: var(--primary); }
.filter-btn.active { background: var(--primary); color: white; border-color: var(--primary); }

/* ===== SIDEBAR ===== */
.sidebar .card { border: none; box-shadow: var(--shadow-sm); border-radius: var(--card-radius); margin-bottom: 1.5rem; }
.sidebar .card-header {
  background: var(--primary); color: white; font-weight: 600;
  border-radius: var(--card-radius) var(--card-radius) 0 0 !important;
  padding: 0.75rem 1.25rem;
}
.sidebar .list-group-item {
  border: none; border-left: 3px solid transparent; padding: 0.7rem 1.25rem;
  font-size: 0.95rem; color: var(--neutral-800); transition: all var(--transition);
}
.sidebar .list-group-item:hover,
.sidebar .list-group-item.active {
  border-left-color: var(--primary); background: var(--primary-bg); color: var(--primary);
}

/* ===== BREADCRUMB ===== */
.breadcrumb { background: transparent; padding: 0; margin-bottom: 0; }

/* ===== CONTACT FORM ===== */
.contact-form .form-control {
  border: 1.5px solid var(--neutral-300); border-radius: var(--btn-radius);
  padding: 0.75rem 1rem; font-size: 0.95rem; transition: border-color var(--transition);
}
.contact-form .form-control:focus {
  border-color: var(--primary); box-shadow: 0 0 0 0.2rem rgba(26,115,232,0.15);
}
.contact-form textarea.form-control { min-height: 120px; resize: vertical; }

/* ===== LIGHTBOX ===== */
.lightbox-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.9); z-index: 9999;
  display: flex; align-items: center; justify-content: center; cursor: zoom-out;
}
.lightbox-overlay img { max-width: 90vw; max-height: 90vh; border-radius: 4px; }
.lightbox-close {
  position: absolute; top: 20px; right: 30px; color: white;
  font-size: 2rem; cursor: pointer; background: none; border: none;
}

/* ===== PAGINATION ===== */
.pagination .page-link {
  color: var(--neutral-800); border: 1px solid var(--neutral-300);
  border-radius: 6px; margin: 0 3px; padding: 0.5rem 0.9rem;
  font-size: 0.9rem; transition: all var(--transition);
}
.pagination .page-link:hover { background: var(--primary-bg); border-color: var(--primary); }
.pagination .page-item.active .page-link {
  background: var(--primary); border-color: var(--primary); color: white;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--neutral-900); color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
}
.footer h5, .footer h6 { color: white; margin-bottom: 1rem; font-weight: 600; }
.footer a.footer-link { color: rgba(255,255,255,0.6); font-size: 0.88rem; transition: color var(--transition); }
.footer a.footer-link:hover { color: white; }
.footer ul li { margin-bottom: 0.4rem; }
.footer-bottom { background: #111; color: rgba(255,255,255,0.5); font-size: 0.8rem; }
.footer-bottom a { color: rgba(255,255,255,0.5); }

/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed; bottom: 30px; right: 30px; z-index: 999;
  width: 44px; height: 44px; background: var(--primary); color: white;
  border: none; border-radius: 50%; font-size: 1.2rem;
  display: none; align-items: center; justify-content: center;
  cursor: pointer; box-shadow: var(--shadow-md); transition: all var(--transition);
}
.back-to-top:hover { background: var(--primary-dark); transform: translateY(-2px); }
.back-to-top.show { display: flex; }

/* ===== SEARCH PAGE ===== */
.search-result-item {
  padding: 1rem 1.25rem; border: 1px solid var(--neutral-200);
  border-radius: var(--card-radius); margin-bottom: 0.75rem;
  transition: box-shadow var(--transition);
}
.search-result-item:hover { box-shadow: var(--shadow-sm); }
.search-result-item .result-title { font-weight: 600; font-size: 1.05rem; }
.search-result-item .result-desc { font-size: 0.9rem; color: var(--neutral-600); margin: 0.25rem 0; }
.search-result-item .result-type {
  font-size: 0.75rem; color: var(--primary); background: var(--primary-bg);
  padding: 2px 8px; border-radius: 3px; display: inline-block;
}

/* ===== 404 PAGE ===== */
.error-page { padding: 120px 0 80px; text-align: center; }
.error-page .error-code { font-size: 8rem; font-weight: 900; color: var(--primary); line-height: 1; }
.error-page h2 { font-size: 1.8rem; font-weight: 700; color: var(--neutral-900); margin: 1rem 0; }

/* ===== DETAIL PAGE ===== */
.detail-image {
  border-radius: var(--card-radius); cursor: zoom-in; width: 100%;
  object-fit: cover; max-height: 400px;
}
.detail-info h3 { font-weight: 700; margin-bottom: 1rem; }
.detail-info .meta { color: var(--neutral-600); font-size: 0.9rem; margin-bottom: 1.5rem; }
.pagination-nav { border-top: 1px solid var(--neutral-200); padding-top: 1.5rem; margin-top: 2rem; }

/* ===== RESPONSIVE ===== */
@media (max-width: 991.98px) {
  .hero-section { padding: 3rem 0 2rem; }
  .hero-section h1 { font-size: 2rem; }
  .card-news { flex-direction: column; }
  .card-news .card-img { width: 100%; height: 180px; }
  .search-dropdown { position: fixed; top: 60px; left: 10px; right: 10px; width: auto; }
}
@media (max-width: 767.98px) {
  .section-padding { padding: 2.5rem 0; }
  .section-title h2 { font-size: 1.6rem; }
  .hero-section h1 { font-size: 1.6rem; }
  .hero-section .lead { font-size: 1rem; }
  .page-hero h1 { font-size: 1.5rem; }
  .card-product .card-img-top { height: 180px; }
  .process-step { margin-bottom: 1.5rem; }
  .back-to-top { bottom: 15px; right: 15px; width: 38px; height: 38px; }
}
