﻿body {
    background: #f8f9fc;
}

.rfq-page {
    max-width: 900px;
    margin: 48px auto 80px;
    padding: 0 24px;
}

.rfq-header {
    text-align: center;
    margin-bottom: 40px;
}

    .rfq-header h1 {
        font-size: 30px;
        font-weight: 900;
        color: #0f3460;
        margin-bottom: 10px;
    }

    .rfq-header p {
        color: #64748b;
        font-size: 15px;
    }

.rfq-card {
    background: #fff;
    border-radius: 14px;
    padding: 40px;
    box-shadow: 0 4px 24px rgba(15,52,96,.07);
}

.rfq-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.rfq-row-full {
    grid-column: 1 / -1;
}

.rfq-items {
    margin-top: 8px;
}

.rfq-header-row {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1.4fr 0.7fr 1.2fr auto;
    gap: 10px;
    align-items: center;
    border-bottom: 2px solid #eaeef2;
    padding-bottom: 12px;
    margin-bottom: 0;
    font-weight: 700;
    font-size: 12px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.rfq-item-row {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1.4fr 0.7fr 1.2fr auto;
    gap: 10px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #f0f2f5;
    transition: border-color 0.3s, box-shadow 0.3s;
}

/* 新增行红色边框动画 */
.rfq-item-row.row-new {
    border: 2px solid #e94560;
    border-radius: 6px;
    padding: 8px 4px;
    box-shadow: 0 0 0 2px rgba(233, 69, 96, 0.15);
    animation: newRowFade 3s ease forwards;
}
@keyframes newRowFade {
    0%, 70% { border-color: #e94560; box-shadow: 0 0 0 2px rgba(233, 69, 96, 0.15); }
    100% { border-color: transparent; border-width: 0; box-shadow: none; padding: 10px 0; border-bottom: 1px solid #f0f2f5; }
}

    .rfq-item-row .form-input,
    .rfq-item-row .form-select {
        margin: 0;
        font-size: 13px;
        padding: 9px 12px;
    }

        .rfq-item-row .form-input[readonly] {
            background: #f8f9fc;
            color: #64748b;
            cursor: default;
            font-weight: 600;
        }

.btn-remove-item {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 1.5px solid #f0f2f5;
    background: #fff;
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .15s;
    flex-shrink: 0;
}

    .btn-remove-item:hover {
        border-color: #e94560;
        color: #e94560;
        background: #fff1f3;
    }

.btn-add-row {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f8f9fc;
    border: 1.5px dashed #c8d6e8;
    color: #0f3460;
    font-size: 13px;
    font-weight: 600;
    padding: 9px 18px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 12px;
    transition: all .15s;
}

    .btn-add-row:hover {
        border-color: #0f3460;
        background: #eef2ff;
    }

.rfq-note {
    background: #f8fbff;
    border: 1px solid #dde6f5;
    border-radius: 8px;
    padding: 14px 16px;
    font-size: 13px;
    color: #64748b;
    margin-top: 20px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

    .rfq-note i {
        color: #0f3460;
        margin-top: 2px;
        flex-shrink: 0;
    }

.rfq-submit {
    margin-top: 32px;
    text-align: right;
}

.btn-submit-rfq {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #e94560;
    color: #fff;
    padding: 14px 36px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(233,69,96,.3);
    transition: all .2s;
}

    .btn-submit-rfq:hover {
        background: #c73652;
        transform: translateY(-2px);
        box-shadow: 0 8px 24px rgba(233,69,96,.35);
    }

    .btn-submit-rfq:disabled {
        opacity: .6;
        cursor: not-allowed;
        transform: none;
    }

.btn-clear-cart {
    background: transparent;
    border: 1.5px solid #e2e8f0;
    color: #64748b;
    padding: 11px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all .15s;
}

    .btn-clear-cart:hover {
        border-color: #e94560;
        color: #e94560;
    }
/* Success */
.rfq-success {
    display: none;
    text-align: center;
    padding: 60px 40px;
}

    .rfq-success.show {
        display: block;
    }

.rfq-success-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4ade80, #22c55e);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 28px;
    color: #fff;
}

.rfq-success h2 {
    font-size: 22px;
    font-weight: 900;
    color: #0f3460;
    margin-bottom: 8px;
}

.rfq-success p {
    color: #64748b;
    font-size: 15px;
}

.rfq-success .btn-goto {
    display: inline-block;
    margin-top: 24px;
    background: #0f3460;
    color: #fff;
    padding: 12px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}
/* Empty state */
.cart-empty {
    text-align: center;
    padding: 80px 40px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 24px rgba(15,52,96,.07);
}

    .cart-empty i {
        font-size: 56px;
        color: #dde6f5;
        margin-bottom: 16px;
    }

    .cart-empty h2 {
        font-size: 20px;
        color: #64748b;
        margin-bottom: 8px;
    }

    .cart-empty p {
        color: #94a3b8;
        font-size: 14px;
        margin-bottom: 24px;
    }

    .cart-empty .btn-goto {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        background: #e94560;
        color: #fff;
        padding: 12px 28px;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
        text-decoration: none;
        transition: background .2s;
    }

        .cart-empty .btn-goto:hover {
            background: #c73652;
        }

@media (max-width: 640px) {
    .rfq-row {
        grid-template-columns: 1fr;
    }

    .rfq-header-row,
    .rfq-item-row {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .rfq-item-row > span {
        grid-column: 1/-1;
    }
}
