/* 基础样式 */
:root {
    --primary: #4361ee;
    --primary-light: #4895ef;
    --secondary: #3f37c9;
    --dark: #1b263b;
    --light: #f8f9fa;
    --gray: #adb5bd;
    --success: #4cc9f0;
    --danger: #f72585;
    --warning: #f8961e;
}

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

body {
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background-color: #f5f7fa;
    color: var(--dark);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background-color: var(--secondary);
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: white;
}

/* 头部样式 */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo-container {
    display: flex;
    align-items: center;
}

.logo-circle img{
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
}

.logo-circle i {
    font-size: 24px;
    color: white;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
}

.logo-slogan {
    font-size: 12px;
    color: var(--gray);
    margin-top: 2px;
}

nav ul {
    display: flex;
}

nav ul li {
    margin-left: 25px;
}

nav ul li a {
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

nav ul li a:hover::after {
    width: 100%;
}

/* 主要内容区 */
.main-content {
    padding: 40px 0;
}

.page-header {
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.page-header {
    margin-bottom: 40px;
    position: relative;
    padding-bottom: 15px;
}

.page-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 90px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--success));
    border-radius: 2px;
}

.page-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--dark);
    position: relative;
    display: inline-block;
    margin-bottom: 10px;
}


/* 资源网格 */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.resource-card {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.card-image {
    height: 180px;
    position: relative;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    background-color: #f0f2f5;
}

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

.card-meta .price-tag {
    font-size: 18px;
    font-weight: 600;
    color: #ff5722;
}

.card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--dark);
}

.card-description {
    color: var(--gray);
    font-size: 14px;
    margin-bottom: 15px;
    line-height: 1.5;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--gray);
}

.card-meta span {
    display: flex;
    align-items: center;
}

.card-meta i {
    margin-right: 5px;
    font-size: 12px;
}

.card-footer {
    padding: 15px 20px;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: center;
}

.buy-now {
    padding: 12px 25px;
    font-size: 14px;
    font-weight: 600;
    width: 100%;
    border-radius: 6px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: 0 4px 15px rgba(67, 97, 238, 0.2);
    border: none;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
}

.buy-now:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(67, 97, 238, 0.3);
}

.buy-now::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.4s ease;
}

.buy-now:hover::before {
    left: 100%;
}

/* 订单模态框 */
.modal {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: white;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 30px;
    position: relative;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: var(--gray);
}

.close-modal:hover {
    color: var(--danger);
}

.modal-title {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
}

.order-summary {
    margin-bottom: 25px;
}

.order-item {
    display: flex;
    margin-bottom: 15px;
}

.order-item-img {
    width: 80px;
    height: 80px;
    border-radius: 6px;
    object-fit: cover;
    margin-right: 15px;
    background-color: #f0f2f5;
}

.order-item-details {
    flex: 1;
}

.order-item-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 5px;
}

.order-item-price {
    font-size: 15px;
    color: var(--primary);
    font-weight: 600;
}

.payment-form {
    margin-top: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
}

.payment-methods {
    display: flex;
    justify-content: space-between;
    margin: 20px 0;
}

.payment-method {
    flex: 1;
    text-align: center;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    margin: 0 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.payment-method:hover {
    border-color: var(--primary);
}

.payment-method.active {
    border-color: var(--primary);
    background-color: rgba(67, 97, 238, 0.1);
}

.payment-method i {
    font-size: 30px;
    margin-bottom: 10px;
    color: var(--primary);
}

.payment-method span {
    display: block;
    font-size: 14px;
}

.submit-order {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    margin-top: 15px;
}
.payQrcode img{
    width: 100%;
}
/* 页脚 */
footer {
    background-color: var(--dark);
    color: white;
    padding: 0px 0 20px;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--gray);
    font-size: 14px;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .header-container {
        flex-direction: column;
    }

    nav ul {
        margin: 15px 0;
    }

    .resource-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .payment-methods {
        flex-direction: column;
    }

    .payment-method {
        margin: 5px 0;
    }
}