/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px; line-height: 1.6; color: #455c6e; background: #fff;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
input, button, textarea { font-family: inherit; outline: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 15px; }

/* ===== Header Meta ===== */
.header-meta {
  background: #e5eff6; height: 36px; line-height: 36px; overflow: hidden;
}
.header-meta .container { display: flex; justify-content: space-between; }
.header-meta .top-left {
  font-size: 12px; color: #586c7d;
}
.header-meta .top-right {
  display: flex; align-items: center; gap: 5px;
}
.header-meta .top-right a {
  font-size: 14px; color: #586c7d; margin: 0 5px;
}
.header-meta .top-right a:hover { text-decoration: underline; }

/* ===== Logo ===== */
.site-logo-area {
  background: #fff; padding: 10px 0;
}
.site-logo-area .container {
  display: flex; justify-content: space-between; align-items: center; height: 70px;
}
.site-logo-area .logo-brand {
  font-size: 32px; font-weight: bold; color: #005da8;
}
.site-logo-area .logo-brand small {
  display: block; font-size: 12px; color: #999; font-weight: normal;
}

/* ===== Navbar ===== */
.main-navbar {
  background: #005da8; border-radius: 0; margin-bottom: 0; border: 0;
}
.main-navbar .container { display: flex; align-items: center; }
.nav-links {
  display: flex; line-height: 50px; height: auto;
}
.nav-links li a {
  display: block; padding: 15px 16px; color: #fff; font-size: 16px; font-weight: 400;
  transition: .3s; white-space: nowrap;
}
.nav-links li a:hover,
.nav-links li a.active {
  background: #e94d19; color: #fff;
}
.nav-toggle-btn {
  display: none; background: none; border: none; color: #fff; font-size: 24px; padding: 10px; cursor: pointer;
}
@media(max-width:1400px) {
  .nav-links li a { padding: 15px 10px; font-size: 16px; }
}
@media(max-width:1280px) {
  .nav-links li a { padding: 15px 10px; font-size: 14px; }
}
@media(max-width:768px) {
  .nav-links { display: none; flex-direction: column; width: 100%; }
  .nav-links.open { display: flex; }
  .nav-toggle-btn { display: block; }
}

/* ===== Hero Banner ===== */
.home-banner {
  overflow: hidden; position: relative; width: 100%;
}
.home-banner a, .home-banner img { display: block; width: 100%; }
.hero-slider { position: relative; width: 100%; }
.hero-slide {
  position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease;
}
.hero-slide.active { opacity: 1; position: relative; }
.hero-slide img { width: 100%; display: block; }
.hero-dots {
  position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 8px; z-index: 10;
}
.hero-dots .dot {
  width: 10px; height: 10px; border-radius: 50%; background: #e94d19;
  border: 1px solid #e94d19; cursor: pointer; opacity: 1; transition: .3s;
}
.hero-dots .dot.active { background: #fff; border-color: #e94d19; }

/* ===== Section Title ===== */
.section-title {
  text-align: center; margin-bottom: 20px;
}
.section-title h2 {
  font-size: 30px; color: #252525; font-family: "Microsoft YaHei";
}
.section-title h2 span { color: #e94d19; font-weight: bold; }
.section-title p {
  font-size: 20px; color: #919191; margin-top: 5px;
}

/* ===== Product Category ===== */
.product-cats {
  display: flex; justify-content: center; margin-top: 15px; flex-wrap: wrap; gap: 10px;
}
.product-cats a {
  display: block; padding: 10px 15px; font-size: 14px;
  border: 1px solid #bfbfbf; color: #555; transition: .5s;
}
.product-cats a:hover { border-color: #111212; color: #005da8; }

/* ===== Card Grid ===== */
.card-grid {
  display: grid; gap: 20px;
}
.card-grid.col-4 { grid-template-columns: repeat(4, 1fr); }
.card-grid.col-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid.col-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid #e5eff6; border-radius: 6px; overflow: hidden; transition: all .3s;
}
.card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.card-img {
  width: 100%; height: 200px; object-fit: contain; background: #f5f5f5;
}
.card-body { padding: 15px; }
.card-title {
  font-size: 16px; font-weight: 600; color: #455c6e; margin-bottom: 8px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.card-title a:hover { color: #005da8; }
.card-text {
  font-size: 13px; color: #586c7d; line-height: 1.6;
  overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.card-meta {
  margin-top: 10px; font-size: 12px; color: #999;
}

/* ===== Page Banner ===== */
.page-banner {
  width: 100%; position: relative;
}
.page-banner img { width: 100%; }
.page-banner .banner-text {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  display: flex; justify-content: center; align-items: center;
  background-color: rgba(0,0,0,.3);
}
.page-banner .banner-text h1 {
  font-size: 50px; color: #fff;
}

/* ===== Article Detail ===== */
.article-detail {
  padding: 30px 0; font-size: 16px; color: #455c6e; line-height: 2;
}
.article-detail h1 {
  font-size: 24px; color: #455c6e; text-align: center; margin-bottom: 15px;
}
.article-detail .article-content p { margin-bottom: 16px; }
.article-detail .article-content img {
  max-width: 100% !important; height: auto !important; display: block; margin: 16px 0;
}

/* ===== Footer Nav ===== */
.footer-nav {
  display: block; height: 55px; background: #005da8;
}
.footer-nav ul {
  display: block; text-align: center;
}
.footer-nav ul li {
  height: 55px; display: inline-block;
}
.footer-nav ul li a {
  display: block; height: 55px; line-height: 55px;
  text-align: center; color: #fff; font-size: 14px; padding: 0 20px;
}
.footer-nav ul li a:hover {
  background: #fff; color: #e94d19;
}

/* ===== Links ===== */
.links-section {
  padding: 15px 0; border-top: 1px solid #e5eff6;
}
.links-section .links-title {
  font-size: 14px; font-weight: 600; color: #586c7d; margin-bottom: 10px;
}
.links-section .links-list {
  display: flex; flex-wrap: wrap; gap: 12px 24px;
}
.links-section .links-list a {
  font-size: 13px; color: #586c7d;
}
.links-section .links-list a:hover { color: #005da8; }

/* ===== Footer ===== */
.site-footer {
  display: block; padding: 20px 0; background: #e5eff6;
}
.site-footer .container {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 20px;
}
.footer-brand {
  width: 25%; min-width: 200px; text-align: center; padding-top: 25px;
}
.footer-brand .brand-name {
  font-size: 28px; font-weight: bold; color: #005da8; margin-bottom: 10px;
}
.footer-brand .brand-phone {
  color: #e94d19; font-size: 22px; display: flex; align-items: center; justify-content: center; gap: 5px;
}
.footer-info {
  flex: 1; min-width: 300px; border-left: 1px solid #999; border-right: 1px solid #999;
  padding: 16px 45px 0;
}
.footer-info p {
  margin: 7px 0; font-size: 14px; color: #000;
}
.footer-info p b { font-weight: 600; }
.footer-qr {
  width: 20%; min-width: 150px; padding-top: 25px; text-align: center;
}
.footer-qr img { max-width: 120px; margin: 0 auto; }

/* ===== Pagination ===== */
.pagination {
  display: flex; justify-content: center; gap: 8px; margin-top: 30px;
}
.pagination a, .pagination span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 12px;
  border-radius: 4px; font-size: 14px; border: 1px solid #ddd;
  background: #fff; color: #455c6e;
}
.pagination a:hover { border-color: #005da8; color: #005da8; }
.pagination span.current { background: #005da8; color: #fff; border-color: #005da8; }

/* ===== Nav Dropdown ===== */
.nav-dropdown { position: relative; }
.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
  border-radius: 0 0 4px 4px;
  z-index: 1000;
}
.nav-dropdown:hover .nav-dropdown-menu { display: block; }

/* Mega Menu (3-column KROHNE style) */
.mega-menu-container {
  width: 860px;
  padding: 0;
  overflow: hidden;
  border-radius: 0 0 6px 6px;
}
.mega-menu {
  display: flex;
  min-height: 240px;
  max-height: 400px;
}
/* Left column: L1 */
.mega-sidebar {
  width: 190px;
  background: #fff;
  border-right: 1px solid #e5eff6;
  padding: 8px 0;
  flex-shrink: 0;
  overflow-y: auto;
}
.mega-sidebar h4 {
  font-size: 13px;
  color: #005da8;
  padding: 0 18px 3px;
  margin: 0 0 2px;
  border-bottom: 2px solid #005da8;
}
.mega-l1-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.mega-l1-item {
  padding: 2px 18px;
  font-size: 13px;
  color: #455c6e;
  cursor: pointer;
  transition: all 0.2s;
  border-left: 3px solid transparent;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.mega-l1-item::after {
  content: '›';
  color: #999;
  font-size: 16px;
}
.mega-l1-item:hover,
.mega-l1-item.active {
  background: #f0f6fb;
  color: #005da8;
  border-left-color: #005da8;
}
.mega-l1-item:hover::after,
.mega-l1-item.active::after {
  color: #005da8;
}
/* Middle column: L2 */
.mega-middle {
  width: 220px;
  background: #fff;
  border-right: 1px solid #e5eff6;
  flex-shrink: 0;
  overflow-y: auto;
}
.mega-l2-panel {
  display: none;
}
.mega-l2-panel.active {
  display: block;
}
.mega-l2-panel h4 {
  font-size: 13px;
  font-weight: 600;
  color: #333;
  margin: 0;
  padding: 7px 16px 5px;
  border-bottom: 1px solid #e0e0e0;
}
.mega-l2-item {
  padding: 2px 16px;
  font-size: 12px;
  color: #455c6e;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
  transition: all 0.2s;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.mega-l2-item::after {
  content: '›';
  color: #999;
  font-size: 14px;
}
.mega-l2-item:hover,
.mega-l2-item.active {
  background: #f0f6fb;
  color: #005da8;
}
.mega-l2-item:hover::after,
.mega-l2-item.active::after {
  color: #005da8;
}
/* Right column: L3 */
.mega-right {
  flex: 1;
  background: #f8f9fa;
  padding: 8px 20px;
  overflow-y: auto;
}
.mega-l3-panel {
  display: none;
}
.mega-l3-panel.active {
  display: block;
}
.mega-l3-panel h4 {
  font-size: 13px;
  font-weight: 600;
  color: #333;
  margin: 0 0 6px;
  padding-bottom: 4px;
  border-bottom: 1px solid #e0e0e0;
}
.mega-panel-empty {
  color: #999;
  font-size: 12px;
  padding: 20px 0;
  text-align: center;
}
.mega-l3-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mega-menu .mega-right .mega-l3-list a {
  font-size: 12px;
  color: #586c7d;
  transition: color 0.2s;
  line-height: 1.4;
  background: transparent !important;
}
.mega-menu .mega-right .mega-l3-list a:hover {
  color: #e94d19 !important;
  background: transparent !important;
}

/* Legacy single-column dropdown (fallback) */
.dropdown-cats h4 {
  font-size: 14px; color: #005da8; margin-bottom: 12px;
  border-bottom: 2px solid #005da8; padding-bottom: 6px;
}
.dropdown-cats a {
  display: block !important;
  padding: 7px 0 !important;
  color: #455c6e !important;
  font-size: 14px !important;
  border-bottom: 1px solid #f0f0f0;
  transition: color 0.2s;
  line-height: 1.4 !important;
  background: transparent !important;
}
.dropdown-cats a:hover {
  color: #e94d19 !important;
  background: transparent !important;
}
.dropdown-cats a:last-child { border-bottom: none; }
.dropdown-cats a.cat-l1 { font-weight: 600; padding-top: 10px !important; }
.dropdown-cats a.cat-l2 { padding-left: 14px !important; font-size: 13px !important; color: #586c7d !important; }
.dropdown-cats a.cat-l3 { padding-left: 28px !important; font-size: 12px !important; color: #6b7c8a !important; }

@media (max-width: 768px) {
  .mega-menu-container {
    width: auto;
    min-width: auto;
  }
  .mega-menu {
    flex-direction: column;
    min-height: auto;
    max-height: none;
  }
  .mega-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding: 10px 15px;
  }
  .mega-sidebar h4 { color: #fff; border-color: #fff; margin-bottom: 8px; }
  .mega-l1-list { display: flex; flex-wrap: wrap; gap: 4px; }
  .mega-l1-item {
    padding: 6px 10px;
    font-size: 13px;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 3px;
  }
  .mega-l1-item:hover,
  .mega-l1-item.active {
    background: rgba(255,255,255,0.15);
    color: #ffcc00;
    border-left-color: transparent;
    border-color: #ffcc00;
  }
  .mega-middle {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    background: transparent;
    padding: 10px 15px;
    overflow-y: visible;
  }
  .mega-l2-panel {
    display: block !important;
    margin-bottom: 12px;
  }
  .mega-l2-item {
    color: #fff;
    border-color: rgba(255,255,255,0.1);
  }
  .mega-l2-item:hover,
  .mega-l2-item.active {
    background: rgba(255,255,255,0.15);
    color: #ffcc00;
  }
  .mega-right {
    background: transparent;
    padding: 10px 15px;
    overflow-y: visible;
  }
  .mega-l3-panel {
    display: block !important;
    margin-bottom: 16px;
  }
  .mega-l3-panel h4 {
    color: #fff;
    border-color: rgba(255,255,255,0.2);
    font-size: 13px;
  }
  .mega-panel-empty { color: rgba(255,255,255,0.6); }
  .mega-l3-list a { color: rgba(255,255,255,0.8); }
  .mega-l3-list a:hover { color: #ffcc00; }

  .nav-dropdown-menu {
    position: static;
    box-shadow: none;
    min-width: auto;
    max-height: none;
    padding: 0;
    background: #004a85;
  }
  .dropdown-cats h4 { color: #fff; border-color: #fff; }
  .dropdown-cats a { color: #fff !important; border-color: rgba(255,255,255,0.1); }
  .dropdown-cats a:hover { color: #ffcc00 !important; }
}

/* ===== Empty ===== */
.empty-state { text-align: center; padding: 60px; color: #999; }

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .card-grid.col-4 { grid-template-columns: repeat(3, 1fr); }
  .footer-info { border: none; padding: 0; }
}
@media (max-width: 768px) {
  .card-grid.col-4, .card-grid.col-3 { grid-template-columns: repeat(2, 1fr); }
  .site-footer .container { flex-direction: column; }
  .footer-brand, .footer-info, .footer-qr { width: 100%; border: none; }
  .page-banner .banner-text h1 { font-size: 28px; }
  .section-title h2 { font-size: 22px; }
}
@media (max-width: 480px) {
  .card-grid.col-4, .card-grid.col-3 { grid-template-columns: 1fr; }
}


