:root {
    --primary-color: #009688;
    --text-primary: #333;
    --text-secondary: #666;
    --bg-white: #ffffff;
    --bg-light: #f5f5f5;
    --border-color: #eee;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    color: var(--text-primary);
    line-height: 1.6;
    background-color: var(--bg-white);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-padding {
    padding: 60px 0;
}

.bg-light {
    background-color: var(--bg-light);
}

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
    color: var(--text-primary);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--primary-color);
    margin: 15px auto 0;
}

/* Navbar */
.navbar {
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 80px;
    display: flex;
    align-items: center;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo img {
    height: 60px;
}

.logo-divider {
    width: 1px;
    height: 40px;
    background: var(--border-color);
}

.company-name {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
}

.company-slogan {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links > li {
    position: relative;
}

.nav-links a {
    font-weight: 500;
    padding: 10px 0;
    display: block;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary-color);
}

.nav-links a.active::after {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
    position: absolute;
    bottom: 0;
}

.nav-icons {
    display: flex;
    gap: 15px;
    color: var(--text-secondary);
}

.nav-icons i {
    cursor: pointer;
    transition: var(--transition);
}

.nav-icons i:hover {
    color: var(--primary-color);
}

/* Mega Menu */
.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 1000px;
    background: var(--bg-white);
    box-shadow: var(--shadow-md);
    padding: 0;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    border-top: 2px solid var(--primary-color);
    z-index: 1001;
}

.dropdown-trigger:hover .mega-menu {
    opacity: 1;
    visibility: visible;
    top: 100%;
}

.mega-menu-container {
    display: flex;
    min-height: 400px;
}

.category-sidebar {
    width: 200px;
    background: var(--bg-light);
    border-right: 1px solid var(--border-color);
}

.category-sidebar li {
    padding: 15px 20px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
}

.category-sidebar li:hover,
.category-sidebar li.active {
    background: var(--bg-white);
    color: var(--primary-color);
    border-left: 3px solid var(--primary-color);
}

.category-content {
    flex: 1;
    padding: 30px;
}

.product-group {
    display: none;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.product-group.active {
    display: grid;
}

.menu-product-item {
    text-align: center;
    display: block;
}

.menu-product-item img {
    width: 100%;
    height: 100px;
    object-fit: contain;
    margin-bottom: 10px;
}

.menu-product-item span {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.menu-product-item:hover span {
    color: var(--primary-color);
}

/* Hero Carousel */
.hero-carousel {
    height: 500px;
    position: relative;
    overflow: hidden;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.carousel-slide.active {
    opacity: 1;
}

.slide-bg {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: calc(50% + 50px) center;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.3);
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    z-index: 10;
}

.carousel-btn:hover {
    background: var(--primary-color);
}

.carousel-btn.prev { left: 20px; }
.carousel-btn.next { right: 20px; }

.carousel-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.dot {
    width: 10px;
    height: 10px;
    background: rgba(255,255,255,0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background: var(--primary-color);
    width: 25px;
    border-radius: 5px;
}

/* Home Product Showcase */
.category-tabs-container {
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
}

.category-tabs {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.category-tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding-bottom: 15px;
    cursor: pointer;
    color: var(--text-secondary);
    position: relative;
    transition: var(--transition);
}

.category-tab-item i {
    font-size: 1.5rem;
    background: #f0f0f0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.category-tab-item.active {
    color: var(--primary-color);
}

.category-tab-item.active i {
    background: var(--primary-color);
    color: #fff;
}

.category-tab-item.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary-color);
}

/* Product Slider */
.product-slider-wrapper {
    position: relative;
    padding: 0 50px;
}

.product-slider-track {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 10px 0;
}

.product-slider-track::-webkit-scrollbar {
    height: 0;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #fff;
    border: 1px solid var(--border-color);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    z-index: 5;
    transition: var(--transition);
}

.slider-btn:hover {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

.slider-btn.prev { left: 0; }
.slider-btn.next { right: 0; }

/* Product Card */
.product-card {
    /* Removed fixed width to allow fluid layout in grids */
    width: 100%;
    background: var(--bg-white);
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
    border: 1px solid transparent;
}

/* Specific styles for slider cards to maintain fixed width */
.product-slider-track .product-card {
    min-width: 280px;
    max-width: 280px;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.product-card img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    margin-bottom: 15px;
}

.product-card h3 {
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Honors */
.honors-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.honor-item {
    width: 300px;
    background: #fff;
    padding: 10px;
    box-shadow: var(--shadow-sm);
    border-radius: 4px;
}

/* Why Us */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.feature-item {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.feature-item i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.feature-item h3 {
    margin-bottom: 15px;
}

.feature-item p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Company Intro */
.intro-content {
    display: flex;
    gap: 40px;
    align-items: center;
}

.intro-image {
    flex: 1;
}

.intro-image img {
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}

.intro-text {
    flex: 1;
}

.intro-text p {
    margin-bottom: 20px;
    text-indent: 2em;
    color: var(--text-secondary);
}

/* Footer */
.footer {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 60px 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
}

.footer-logo h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.contact-info p {
    margin-bottom: 10px;
    opacity: 0.8;
}

.contact-info i {
    width: 20px;
    margin-right: 10px;
}

.footer-links h4 {
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.link-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.link-group a {
    opacity: 0.7;
}

.link-group a:hover {
    opacity: 1;
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.9rem;
    opacity: 0.6;
}

/* Detail Page Styles */
.detail-wrapper {
    display: flex;
    gap: 40px;
}

.detail-images {
    flex: 1;
    padding-top: 20px;
}

.detail-info {
    flex: 1;
}

.main-image {
    border: 1px solid var(--border-color);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.thumbnail-list {
    display: flex;
    gap: 10px;
}

.thumbnail-list img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border: 1px solid var(--border-color);
    cursor: pointer;
    opacity: 0.7;
    transition: var(--transition);
}

.thumbnail-list img:hover,
.thumbnail-list img.active {
    opacity: 1;
    border-color: var(--primary-color);
}

.detail-info h1 {
    font-size: 2rem;
    margin-bottom: 15px;
}

.sku {
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.description h3 {
    margin-bottom: 15px;
    border-left: 4px solid var(--primary-color);
    padding-left: 10px;
}

.description p {
    color: var(--text-secondary);
}

/* Breadcrumb */
.breadcrumb {
    padding: 20px 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--text-secondary);
}

.breadcrumb a:hover {
    color: var(--primary-color);
}

/* Product Center Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
    margin-left: 20px;
}

/* Mobile Responsive Styles */
@media (max-width: 991px) {
    .nav-container {
        padding: 0 15px;
    }
    
    /* Adjust Logo Area for Mobile */
    .logo-text {
        display: none; /* Hide text on smaller screens to prevent overflow */
    }
    
    .logo-divider {
        display: none;
    }
    
    .logo img {
        height: 50px;
    }

    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 80px; /* Height of navbar */
        left: 0;
        width: 100%;
        background-color: var(--bg-white);
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        gap: 0; /* Use padding on links instead */
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        display: none; /* Hidden by default */
        z-index: 999;
        border-top: 1px solid var(--border-color);
    }

    .nav-links.active {
        display: flex; /* Show when active */
    }
    
    .nav-links li {
        width: 100%;
        text-align: center;
    }
    
    .nav-links a {
        padding: 15px 0;
        width: 100%;
        display: block;
        border-bottom: 1px solid #f0f0f0;
    }
    
    .nav-links a.active::after {
        display: none; /* Remove underline effect on mobile */
    }
    
    .nav-links a.active {
        background-color: #f9f9f9;
        color: var(--primary-color);
    }
    
    /* Disable Mega Menu Hover on Mobile */
    .mega-menu {
        display: none !important;
    }
    
    /* Adjust Carousel Height for Mobile */
    .hero-carousel {
        height: 300px;
    }
    
    /* Adjust Product Grid for Mobile */
    .product-grid, .solution-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .features-grid {
        grid-template-columns: 1fr !important;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
    
    .product-slider-wrapper {
        padding: 0;
    }
    
    .slider-btn {
        display: none; /* Hide slider buttons on mobile, use touch scroll */
    }
    
    .detail-wrapper {
        flex-direction: column;
        gap: 20px !important;
    }
    
    .detail-images {
        padding-top: 0 !important;
    }
}

@media (max-width: 480px) {
    .product-grid, .solution-grid {
        grid-template-columns: 1fr !important;
    }
}
