/* SAR下载功能样式 */

/* 责任条款弹窗 */
.terms-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 10000 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transition: all 0.3s ease !important;
}

.terms-modal.show {
    opacity: 1 !important;
    visibility: visible !important;
}

.terms-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
}

.terms-content {
    position: relative;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    transform: translateY(30px);
    transition: transform 0.3s ease;
}

.terms-modal.show .terms-content {
    transform: translateY(0);
}

.terms-header {
    padding: 30px;
    border-bottom: 2px solid #f0f0f0;
    position: relative;
}

.terms-header h2 {
    font-size: 28px;
    color: #2c3e50;
    margin-bottom: 10px;
    font-weight: 600;
    text-align: center;
}

.terms-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border: none;
    background: #f0f0f0;
    border-radius: 50%;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.terms-close:hover {
    background: #e0e0e0;
    transform: rotate(90deg);
}

.terms-body {
    padding: 30px;
    overflow-y: auto;
    flex: 1;
}

.terms-body::-webkit-scrollbar {
    width: 8px;
}

.terms-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.terms-body::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.terms-body::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.terms-section {
    margin-bottom: 30px;
}

.terms-section h3 {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
    font-weight: 600;
}

.terms-section p {
    line-height: 1.8;
    color: #555;
    margin-bottom: 12px;
    text-align: justify;
}

.terms-section ul {
    margin: 15px 0;
    padding-left: 20px;
}

.terms-section li {
    line-height: 1.8;
    color: #555;
    margin-bottom: 10px;
    list-style-type: none;
    position: relative;
    padding-left: 20px;
}

.terms-section li:before {
    content: "•";
    color: #3498db;
    font-weight: bold;
    position: absolute;
    left: 0;
}

.terms-section strong {
    color: #2c3e50;
    font-weight: 600;
}

.highlight {
    color: #e74c3c;
    font-weight: 600;
}

.terms-footer-org {
    text-align: right;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.terms-footer-org p {
    color: #2c3e50;
    font-size: 16px;
    font-weight: 600;
}

.terms-agreement {
    padding: 20px 30px;
    background: #f8f9fa;
    border-top: 2px solid #e0e0e0;
}

.agreement-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.agreement-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    cursor: pointer;
    accent-color: #3498db;
}

.agreement-checkbox span {
    color: #2c3e50;
    font-size: 15px;
    font-weight: 500;
}

.terms-actions {
    padding: 20px 30px;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    border-top: 1px solid #e0e0e0;
}

.btn-cancel {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    background: #ecf0f1;
    color: #7f8c8d;
    transition: all 0.3s ease;
}

.btn-cancel:hover {
    background: #d5dbdb;
}

.btn-agree {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: not-allowed;
    background: #95a5a6;
    color: white;
    transition: all 0.3s ease;
}

.btn-agree.enabled {
    background: #3b82f6;
    cursor: pointer;
}

.btn-agree.enabled:hover {
    background: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* 下载表单弹窗 */
.download-form-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.download-form-modal.show {
    opacity: 1;
    visibility: visible;
}

.download-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
}

.download-content {
    position: relative;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.download-form-modal.show .download-content {
    transform: scale(1);
}

.download-header {
    padding: 30px;
    border-bottom: 2px solid #f0f0f0;
    position: relative;
}

.download-header h2 {
    font-size: 24px;
    color: #2c3e50;
    margin-bottom: 10px;
    font-weight: 600;
}

.download-header .product-name {
    color: #3498db;
    font-size: 16px;
    font-weight: 500;
}

.download-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border: none;
    background: #f0f0f0;
    border-radius: 50%;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.download-close:hover {
    background: #e0e0e0;
    transform: rotate(90deg);
}

.download-form {
    padding: 30px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-size: 14px;
    color: #2c3e50;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group .required {
    color: #e74c3c;
}

.form-group input {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
}

.btn-submit {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    background: #3b82f6;
    color: white;
    transition: all 0.3s ease;
}

.btn-submit:hover {
    background: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-submit:disabled {
    background: #95a5a6;
    cursor: not-allowed;
    transform: none;
}

.form-note {
    padding: 20px 30px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}

.form-note p {
    color: #7f8c8d;
    font-size: 14px;
    margin: 0;
}

/* 成功消息 */
.success-message {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.success-message.show {
    opacity: 1;
    visibility: visible;
}

.success-content {
    background: white;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.success-message.show .success-content {
    transform: scale(1);
}

.success-icon {
    width: 70px;
    height: 70px;
    background: #10b981;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: white;
    margin: 0 auto 20px;
    font-weight: bold;
}

.success-content h3 {
    font-size: 22px;
    color: #2c3e50;
    margin: 0 0 15px 0;
    font-weight: 600;
}

.success-content p {
    color: #666;
    line-height: 1.6;
    margin: 0 0 25px 0;
    font-size: 15px;
}

.success-content button {
    padding: 12px 40px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    background: #10b981;
    color: white;
    transition: all 0.3s ease;
}

.success-content button:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .terms-content,
    .download-content {
        width: 95%;
        max-height: 95vh;
    }

    .terms-header,
    .download-header {
        padding: 20px;
    }

    .terms-header h2 {
        font-size: 22px;
    }

    .terms-body,
    .download-form {
        padding: 20px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .terms-actions,
    .form-actions {
        flex-direction: column;
    }

    .btn-cancel,
    .btn-agree,
    .btn-submit {
        width: 100%;
    }
}
