/* 公共样式 - 筋斗云医药电子商务平台 */
:root {
    --primary-color: #2a8bf2;
    --secondary-color: #f08301;
    --dark-color: #333;
    --light-color: #f8f9fa;
    --gray-color: #6c757d;
    --border-radius: 8px;
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', sans-serif;
    color: var(--dark-color);
    line-height: 1.6;
    background-color: #f5f7fa;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

a:hover {
    color: var(--secondary-color);
}

img {
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 顶部导航栏 */
.top-bar {
    background-color: var(--dark-color);
    color: white;
    padding: 8px 0;
    font-size: 14px;
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.auth-links a {
    color: white;
    margin-left: 20px;
    padding: 4px 8px;
    border-radius: 4px;
}

.auth-links a:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* 主导航 */
.main-header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    align-items: center;
    padding: 20px 0;
}

.logo {
    display: flex;
    align-items: center;
    width: 189.438px!important;
    height: 56.594px!important;
}

.logo img {
    height: 50px;
}

.search-area {
    flex: 1;
    margin: 0 30px;
    position: relative;
}

.search-form {
    display: flex;
}

.search-input {
    flex: 1;
    padding: 12px 20px!important;
    border: 2px solid #e0e0e0!important;
    border-radius: var(--border-radius) 0 0 var(--border-radius)!important;
    font-size: 16px!important;
    outline: none!important;
    transition: var(--transition)!important;
}

.search-input:focus {
    border-color: var(--primary-color);
}

.search-btn {
    background-color: var(--secondary-color);
    color: white;
    border: none;
    padding: 0 20px;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.search-btn:hover {
    background-color: #e07601;
}

.post-link {
    background-color: var(--primary-color);
    color: white;
    padding: 12px 20px;
    border-radius: var(--border-radius);
    margin-left: 15px;
    font-weight: 500;
    display: inline-block;
}

.post-link:hover {
    background-color: #1a7bd9;
    color: white;
}

/* 主导航菜单 */
.main-nav {
    background-color: var(--primary-color);
}

.nav-list {
    display: flex;
}

.nav-list li {
    position: relative;
}

.nav-list li a {
    color: white;
    padding: 15px 20px;
    display: block;
    font-weight: 500;
}

.nav-list li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.nav-list li.active a {
    background-color: rgba(255, 255, 255, 0.2);
}

/* 面包屑导航 */
.breadcrumb {
    padding: 15px 0;
    font-size: 14px;
    color: var(--gray-color);
}

.breadcrumb a {
    color: var(--gray-color);
}

.breadcrumb a:hover {
    color: var(--secondary-color);
}

.breadcrumb code {
    margin: 0 8px;
    color: #ccc;
}

/* 产品列表 */
.products-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.product-item {
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.product-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.product-image {
    height: 200px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-item:hover .product-image img {
    transform: scale(1.05);
}

.product-info {
    padding: 15px;
}

.product-title {
    font-size: 16px;
    margin-bottom: 8px;
    font-weight: 500;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 3em;
}

.product-meta {
    color: var(--gray-color);
    font-size: 13px;
    margin-top: 10px;
}

.product-meta p {
    margin-bottom: 5px;
}

.view-detail {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 15px;
    background-color: var(--secondary-color);
    color: white;
    border-radius: var(--border-radius);
    font-size: 14px;
}

.view-detail:hover {
    background-color: #e07601;
    color: white;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    margin: 30px 0;
}

.pagination .current {
    background-color: var(--secondary-color);
    color: white;
    padding: 8px 15px;
    border-radius: var(--border-radius);
    margin: 0 5px;
}

.pagination a {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    margin: 0 5px;
}

.pagination a:hover {
    background-color: #f5f5f5;
}

/* 页脚 */
.footer {
    background-color: var(--dark-color);
    color: white;
    padding: 40px 0 20px;
    margin-top: 50px;
}

.footer-content {
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.footer-links a {
    color: white;
    margin: 0 15px;
    font-size: 16px;
}

.copyright {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}
.copyright a{
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}
.copyright a:hover{
    color: var(--secondary-color);
}

/* 响应式设计 */
@media (max-width: 992px) {
    .header-content {
        flex-direction: column;
    }

    .logo {
        margin-bottom: 15px;
    }

    .search-area {
        width: 100%;
        margin: 15px 0;
    }

    .products-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-list {
        flex-wrap: wrap;
    }

    .nav-list li {
        flex: 1 0 50%;
        text-align: center;
    }
}

@media (max-width: 576px) {
    .products-list {
        grid-template-columns: 1fr;
    }

    .nav-list li {
        flex: 1 0 100%;
    }
}

/* 产品描述样式 */
.product-description {
    color: var(--gray-color);
    font-size: 14px;
    margin: 10px 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 4.5em;
    line-height: 1.5;
    min-height: 63px;
}

/* 分页样式调整 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 30px 0;
    gap: 10px;
}

.pagination .current {
    background-color: var(--secondary-color);
    color: white;
    padding: 8px 15px;
    border-radius: var(--border-radius);
}

.pagination a {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    color: var(--dark-color);
}

.pagination a:hover {
    background-color: #f5f5f5;
}

.pagination .anum {
    margin-left: 15px;
    color: var(--gray-color);
    font-size: 14px;
}
