/* 全局样式 */
:root {
    --primary-color: #00BCD4;
    --secondary-color: #2196F3;
    --text-color: #e0e0e0;
    --light-gray: #333333;
    --medium-gray: #444444;
    --dark-gray: #888888;
    --white: #f5f5f5;
    --black: #121212;
    --success-color: #4CAF50;
    --error-color: #F44336;
    --error-light: #3c2a2a;
    --extra-light-gray: #222222;
    --extra-light-primary: rgba(0, 188, 212, 0.1);
    --shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--black);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

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

a:hover {
    color: var(--primary-color);
}

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

ul {
    list-style: none;
}

.section-title {
    font-size: 28px;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
}

/* 移动端菜单按钮 */
.mobile-nav-toggle {
    display: none;
}

.menu-toggle {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 24px;
    cursor: pointer;
    padding: 5px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.menu-toggle:hover {
    color: var(--primary-color);
}

.menu-toggle:focus {
    outline: none;
}

/* 页头样式 */
.site-header {
    background-color: #1a1a1a;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
}

.logo span {
    font-weight: 400;
    font-size: 22px;
    color: var(--text-color);
}

.header-actions {
    display: flex;
    align-items: center;
}

.search-form {
    position: relative;
    margin-right: 20px;
}

.search-form input {
    width: 250px;
    padding: 8px 15px;
    border: 1px solid var(--medium-gray);
    border-radius: 20px;
    font-size: 14px;
}

.search-form button {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--dark-gray);
    cursor: pointer;
}

.user-actions {
    display: flex;
    align-items: center;
}

.login-link, .cart-link {
    margin-left: 15px;
    font-size: 14px;
}

.cart-link {
    position: relative;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--primary-color);
    color: var(--white);
    font-size: 12px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-nav {
    border-top: 1px solid #333333;
}

/* 移動端菜單搜索欄 */
.mobile-search-form {
    display: none;
    padding: 15px;
    background-color: #252525;
    border-bottom: 1px solid #333333;
}

.mobile-search-form form {
    display: flex;
    position: relative;
    width: 100%;
}

.mobile-search-form input {
    width: 100%;
    padding: 12px 45px 12px 15px;
    border: 1px solid var(--medium-gray);
    border-radius: 20px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.mobile-search-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 188, 212, 0.2);
}

.mobile-search-form button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--primary-color);
    border: none;
    color: var(--white);
    cursor: pointer;
    font-size: 16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}

.mobile-search-form button:hover,
.mobile-search-form button:active {
    background-color: var(--secondary-color);
}

.main-nav ul {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.main-nav li {
    position: relative;
}

.main-nav a {
    display: block;
    padding: 15px 20px;
    font-size: 16px;
    font-weight: 500;
}

.main-nav a:hover {
    color: var(--primary-color);
}

/* 主横幅样式 */
.main-banner {
    background-color: #1e1e1e;
    padding: 50px 0;
    position: relative;
    overflow: hidden;
}

.main-banner::before,
.main-banner::after {
    content: "";
    position: absolute;
    top: 0;
    width: 20px;
    height: 100%;
    background-color: var(--primary-color);
    opacity: 0.7;
}

.main-banner::before {
    left: 0;
}

.main-banner::after {
    right: 0;
}

.banner-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.banner-left {
    flex: 1;
}

.banner-left h1 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-color);
}

.certification {
    display: flex;
}

.certification span {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
    margin-right: 10px;
}

.banner-right {
    flex: 1;
    text-align: center;
}

.banner-right img {
    max-width: 80%;
    margin: 0 auto;
}

/* 产品区域样式 */
.products-section, .category-section {
    padding: 60px 0;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.product-card {
    background-color: #1e1e1e;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

.product-image {
    position: relative;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    overflow: hidden;
}

.product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.quick-view {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 10px 0;
    transform: translateY(100%);
    transition: var(--transition);
    text-align: center;
}

.product-card:hover .quick-view {
    transform: translateY(0);
}

.quick-view-btn {
    color: var(--white);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 1px;
}

.product-info {
    padding: 15px;
}

.product-category {
    font-size: 12px;
    color: var(--dark-gray);
    margin-bottom: 5px;
}

.product-name {
    font-size: 16px;
    margin-bottom: 10px;
    height: 60px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.product-name a {
    color: var(--white);
}

.product-name a:hover {
    color: var(--primary-color);
}

.product-price {
    display: flex;
    align-items: center;
}

.current-price {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
}

.old-price {
    font-size: 14px;
    color: var(--dark-gray);
    text-decoration: line-through;
    margin-left: 10px;
}

.view-more {
    text-align: center;
    margin-top: 30px;
}

.btn-view-more {
    display: inline-block;
    padding: 10px 25px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 4px;
    font-weight: 500;
    transition: var(--transition);
}

.btn-view-more:hover {
    background-color: var(--secondary-color);
    color: var(--white);
}

/* 页脚样式 */
.site-footer {
    background-color: #0c0c0c;
    color: var(--white);
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

.footer-column h3 {
    font-size: 18px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-column h3::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--primary-color);
}

.footer-column ul li {
    margin-bottom: 10px;
}

.footer-column ul li a {
    color: #ccc;
}

.footer-column ul li a:hover {
    color: var(--primary-color);
}

.company-info p {
    margin-bottom: 20px;
    color: #ccc;
}

.social-links {
    display: flex;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: #333;
    color: var(--white);
    border-radius: 50%;
    margin-right: 10px;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--primary-color);
}

.contact-info p {
    margin-bottom: 10px;
    color: #ccc;
}

.contact-info i {
    margin-right: 10px;
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid #333;
    padding-top: 20px;
    font-size: 14px;
    color: #888;
}

/* LINE聊天按钮 */
.line-chat-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background-color: #06C755;
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 99;
    transition: var(--transition);
}

.line-chat-btn:hover {
    transform: scale(1.1);
    color: var(--white);
}

/* 响应式设计 */
@media (max-width: 992px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .mobile-nav-toggle {
        display: block;
        margin-right: 15px;
    }

    .header-top {
        padding: 10px 0;
    }

    .logo h1 {
        font-size: 24px;
    }

    .logo span {
        font-size: 18px;
    }

    .search-form {
        display: none;
    }

    .action-text {
        display: none;
    }

    .user-actions {
        display: flex;
        align-items: center;
        gap: 15px;
    }

    /* 优化手机端banner高度 */
    .main-banner {
        padding: 25px 0;
    }

    .banner-left h1 {
        font-size: 32px;
        margin-bottom: 10px;
    }

    .certification span {
        padding: 3px 8px;
        font-size: 12px;
    }

    .banner-content {
        flex-direction: column;
    }

    .banner-left, .banner-right {
        text-align: center;
    }

    .banner-left {
        margin-bottom: 15px;
    }

    .banner-right img {
        max-width: 60%;
    }

    /* 产品区域手机端优化 */
    .products-section, .category-section {
        padding: 30px 0;
    }

    .section-title {
        font-size: 24px;
        margin-bottom: 20px;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .main-nav {
        position: fixed;
        top: 60px;
        left: -100%;
        width: 80%;
        height: calc(100vh - 60px);
        background-color: #1a1a1a;
        transition: left 0.3s ease;
        box-shadow: 2px 0 5px rgba(0, 0, 0, 0.3);
        overflow-y: auto;
        z-index: 999;
    }

    .main-nav.active {
        left: 0;
    }

    .main-nav ul {
        flex-direction: column;
        padding: 20px 0;
        justify-content: flex-start;
    }

    .main-nav li {
        width: 100%;
    }

    .main-nav a {
        padding: 12px 20px;
        border-bottom: 1px solid #2a2a2a;
    }

    .cart-link {
        position: relative;
        font-size: 20px;
    }

    .cart-count {
        position: absolute;
        top: -8px;
        right: -8px;
        width: 20px;
        height: 20px;
        font-size: 12px;
    }
    
    /* 添加遮罩层 */
    .menu-overlay {
        display: none;
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        height: calc(100vh - 60px);
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 998;
    }
    
    .main-nav.active + .menu-overlay {
        display: block;
    }

    .product-info {
        padding: 10px;
    }
    
    .product-category {
        font-size: 11px;
        margin-bottom: 3px;
    }
    
    .product-name {
        font-size: 14px;
        height: 50px;
        margin-bottom: 5px;
        -webkit-line-clamp: 2;
    }
    
    .current-price {
        font-size: 16px;
    }
    
    .old-price {
        font-size: 12px;
    }
    
    .quick-view {
        display: none;
    }

    .mobile-search-form {
        display: block;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 10px;
    }

    .logo h1 {
        font-size: 20px;
    }

    .logo span {
        font-size: 16px;
    }

    .main-banner {
        padding: 20px 0;
    }

    .banner-left h1 {
        font-size: 28px;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }

    .product-info {
        padding: 8px;
    }
    
    .product-name {
        font-size: 13px;
        height: 40px;
    }
    
    .current-price {
        font-size: 14px;
    }
    
    .old-price {
        font-size: 11px;
    }
}

.product-packages {
    margin-top: 20px;
    margin-bottom: 20px;
}

.product-packages h4 {
    font-size: 16px;
    margin-bottom: 10px;
}

.package-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.package-option {
    position: relative;
}

.package-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.package-option label {
    display: block;
    padding: 10px 15px;
    background-color: #2a2a2a;
    border: 2px solid #3a3a3a;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.package-option input[type="radio"]:checked + label {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.package-option label:hover {
    border-color: var(--primary-color);
}

.package-selector {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #3a3a3a;
    border-radius: 4px;
    font-size: 14px;
    background-color: #2a2a2a;
    color: var(--text-color);
    cursor: pointer;
    transition: var(--transition);
}

.package-selector:hover {
    border-color: var(--primary-color);
}

.product-package {
    font-size: 12px;
    color: var(--dark-gray);
    margin-top: 4px;
}

/* 消息提示样式 */
.message {
    position: fixed;
    top: 80px;
    right: 20px;
    padding: 15px 20px;
    background-color: #222222;
    color: #ffffff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    border-left: 4px solid var(--primary-color);
    border-radius: 4px;
    z-index: 1000;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
}

.message.error {
    border-left-color: var(--error-color);
}

.message.warning {
    border-left-color: #FFC107;
    color: #FFC107;
}

.message.show {
    opacity: 1;
    transform: translateX(0);
} 