/* 主要内容区域样式 */
.main-content {
    padding: 90px 0px 20px 0px;
    min-height: calc(100vh - 200px);
    background-color: #f5f5f5;
}

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

/* 订单容器样式 */
.order-container {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 30px;
}

.order-header {
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.order-header h2 {
    font-size: 20px;
    color: #333;
    margin: 0;
}

/* 课程信息样式 */
.course-info {
    display: flex;
    align-items: center;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 8px;
    margin-bottom: 30px;
}

.course-image {
    width: 120px;
    height: 80px;
    margin-right: 20px;
    border-radius: 4px;
    overflow: hidden;
}

.course-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.course-details h3 {
    font-size: 18px;
    color: #333;
    margin: 0 0 10px;
}

.price {
    font-size: 20px;
    color: #ff6b6b;
    font-weight: 500;
}

/* 订单部分样式 */
.order-section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.order-section h2 {
    font-size: 16px;
    color: #333;
    margin: 0 0 15px;
}

/* 优惠券部分样式 */
.coupon-section {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.coupon-input {
    display: flex;
    gap: 10px;
    align-items: center;
    width:300px ;
}

.coupon-input input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    height: 36px;
}

.coupon-input button {
    padding: 8px 15px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    height: 36px;
    white-space: nowrap;
}

.coupon-input button:hover {
    background: var(--primary-hover);
}

.coupon-list button {
    padding: 8px 15px;
    background: transparent;
    border: 1px solid #4a6bff;
    color: #4a6bff;
    border-radius: 4px;
    cursor: pointer;
}

/* 优惠券弹窗样式 */
.coupon-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.modal-content {
    position: relative;
    background: white;
    width: 90%;
    max-width: 500px;
    margin: 50px auto;
    padding: 20px;
    border-radius: 8px;
}

.close-modal {
    position: absolute;
    right: 10px;
    top: 10px;
    font-size: 24px;
    cursor: pointer;
}

.coupons-container {
    margin-top: 20px;
}

.coupon-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-bottom: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.coupon-info h4 {
    margin: 0 0 5px 0;
    color: #333;
}

.coupon-info p {
    margin: 5px 0;
    color: #666;
    font-size: 14px;
}

.select-coupon {
    padding: 8px 15px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.select-coupon:hover {
    background: var(--primary-hover);
}

/* 订单总价样式 */
.order-summary {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.price-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.total-price {
    font-weight: bold;
    font-size: 18px;
    color: var(--primary-color);
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

/* 支付方式样式 */
.payment-methods {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.payment-method {
    flex: 0 0 auto;
    position: relative;
    min-width: 150px;
    max-width: 200px;
}

.payment-method input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.payment-method label {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    border: 2px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
    width: 100%;
    box-sizing: border-box;
}

.payment-method input[type="radio"]:checked + label {
    border-color: var(--primary-color);
    background-color: #fff9f0;
}

.payment-method label i {
    font-size: 20px;
    margin-right: 8px;
}

.payment-method label i.fa-alipay {
    color: #00a0e9;
}

.payment-method label i.fa-weixin {
    color: #2aae67;
}

.payment-method label i.fa-coins {
    color: #ffd700;
}

/* 提交按钮样式 */
.order-actions {
    margin-top: 30px;
    text-align: right;
}

.btn-submit {
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    padding: 12px 30px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
}

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

/* 支付弹窗样式 */
.payment-modal {
    display: none;
    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;
}

.payment-modal.active {
    display: flex;
}

.payment-modal-content {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 90%;
    position: relative;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.payment-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.payment-modal-header h3 {
    margin: 0;
    font-size: 18px;
    color: #333;
}

.payment-modal-close {
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s;
}

.payment-modal-close:hover {
    color: #666;
}

.payment-qrcode-container {
    text-align: center;
    margin: 20px 0;
}

.payment-qrcode {
    width: 200px;
    height: 200px;
    margin: 0 auto;
}

.payment-qrcode img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.payment-info {
    text-align: center;
    margin-top: 20px;
}

.payment-amount {
    font-size: 24px;
    color: var(--primary-color);
    font-weight: 500;
    margin: 10px 0;
}

.payment-tips {
    color: #666;
    font-size: 14px;
    margin: 15px 0;
    text-align: center;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .main-content {
        padding: 60px 0 20px;
    }

    .container {
        padding: 20px 15px;
    }

    .order-container {
        padding: 20px;
        margin-bottom: 20px;
    }

    .order-header {
        margin-bottom: 15px;
        padding-bottom: 12px;
    }

    .order-header h2 {
        font-size: 18px;
    }

    .course-info {
        padding: 15px;
        margin-bottom: 20px;
    }

    .course-image {
        width: 100px;
        height: 70px;
        margin-right: 15px;
    }

    .course-details h3 {
        font-size: 16px;
        margin-bottom: 8px;
    }

    .price {
        font-size: 18px;
    }

    .order-section {
        margin-bottom: 20px;
        padding-bottom: 15px;
    }

    .order-section h2 {
        font-size: 15px;
        margin-bottom: 12px;
    }

    .coupon-section {
        margin: 15px 0;
        padding: 12px;
    }

    .coupon-input {
        width: 100%;
        flex-direction: column;
        gap: 10px;
    }

    .coupon-input input {
        width: 100%;
    }

    .coupon-input button {
        width: 100%;
    }

    .order-summary {
        padding: 12px;
    }

    .price-item {
        font-size: 13px;
    }

    .total-price {
        font-size: 16px;
    }

    .payment-methods {
        gap: 10px;
    }

    .payment-method {
        min-width: 100%;
        max-width: 100%;
    }

    .payment-method label {
        padding: 10px 15px;
    }

    .order-actions {
        margin-top: 20px;
    }

    .btn-submit {
        width: 100%;
        padding: 10px;
        font-size: 15px;
    }

    /* 支付弹窗适配 */
    .payment-modal-content {
        padding: 20px;
        width: 95%;
    }

    .payment-modal-header h3 {
        font-size: 16px;
    }

    .payment-qrcode {
        width: 180px;
        height: 180px;
    }

    .payment-amount {
        font-size: 20px;
    }

    .payment-tips {
        font-size: 13px;
    }
}

/* 小屏幕手机适配 */
@media screen and (max-width: 375px) {
    .main-content {
        padding: 50px 0 15px;
    }

    .container {
        padding: 0 12px;
    }

    .order-container {
        padding: 15px;
    }

    .order-header h2 {
        font-size: 16px;
    }

    .course-info {
        padding: 12px;
    }

    .course-image {
        width: 90px;
        height: 60px;
        margin-right: 12px;
    }

    .course-details h3 {
        font-size: 15px;
    }

    .price {
        font-size: 16px;
    }

    .order-section h2 {
        font-size: 14px;
    }

    .coupon-section {
        padding: 10px;
    }

    .payment-method label {
        padding: 8px 12px;
        font-size: 13px;
    }

    .payment-method label i {
        font-size: 18px;
    }

    .btn-submit {
        padding: 8px;
        font-size: 14px;
    }

    .payment-modal-content {
        padding: 15px;
    }

    .payment-qrcode {
        width: 160px;
        height: 160px;
    }

    .payment-amount {
        font-size: 18px;
    }

    .payment-tips {
        font-size: 12px;
    }
}

