/* ===== 詢價表單樣式 ===== */

/* ===== 浮動詢價按鈕 ===== */
.inquiry-button {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: linear-gradient(135deg, #0066ff 0%, #00c6ff 100%);
    color: white;
    padding: 16px 24px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 102, 255, 0.4);
    transition: all 0.3s ease;
    z-index: 999;
    font-weight: 600;
    font-size: 16px;
}

.inquiry-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0, 102, 255, 0.5);
}

.inquiry-button svg {
    width: 20px;
    height: 20px;
}

/* 手機版調整 */
@media (max-width: 768px) {
    .inquiry-button {
        bottom: 20px;
        right: 20px;
        padding: 14px 20px;
        font-size: 14px;
    }
    
    .inquiry-button span {
        display: none;
    }
    
    .inquiry-button {
        width: 56px;
        height: 56px;
        justify-content: center;
        border-radius: 50%;
    }
}

/* ===== 彈出視窗遮罩 ===== */
.inquiry-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.inquiry-overlay.active {
    display: flex;
    opacity: 1;
}

/* ===== 表單容器 ===== */
.inquiry-modal {
    background: white;
    border-radius: 20px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.inquiry-overlay.active .inquiry-modal {
    transform: scale(1);
}

.close-button {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: #6b7280;
    transition: all 0.2s ease;
    border-radius: 8px;
}

.close-button:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.form-header {
    margin-bottom: 30px;
}

.form-header h2 {
    font-size: 28px;
    color: #1f2937;
    margin-bottom: 8px;
    font-weight: 700;
}

.form-header p {
    color: #6b7280;
    font-size: 14px;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #1f2937;
    font-weight: 500;
    font-size: 14px;
}

.required {
    color: #ef4444;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #0066ff;
    box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
}

.error-message {
    display: none;
    color: #ef4444;
    font-size: 13px;
    margin-top: 6px;
}

.error-message.show {
    display: block;
}

.form-group input.error,
.form-group textarea.error {
    border-color: #ef4444;
}

.submit-button {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #0066ff 0%, #00c6ff 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.submit-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 255, 0.4);
}

.submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.submit-button .button-loader {
    display: none;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-left: 10px;
}

.submit-button.loading .button-text {
    opacity: 0.7;
}

.submit-button.loading .button-loader {
    display: inline-block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.success-message {
    display: none;
    text-align: center;
    padding: 40px 20px;
}

.success-message.show {
    display: block;
}

.success-message svg {
    margin-bottom: 20px;
    animation: checkmark 0.5s ease;
}

@keyframes checkmark {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); opacity: 1; }
}

.success-message h3 {
    color: #10b981;
    font-size: 24px;
    margin-bottom: 10px;
}

.success-message p {
    color: #6b7280;
}

@media (max-width: 768px) {
    .inquiry-modal {
        padding: 30px 20px;
        border-radius: 20px 20px 0 0;
        max-height: 100vh;
        width: 100%;
        max-width: 100%;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
    }
    
    .form-header h2 {
        font-size: 24px;
    }
    
    .form-group input,
    .form-group textarea {
        font-size: 16px;
    }
}

.inquiry-modal::-webkit-scrollbar {
    width: 6px;
}

.inquiry-modal::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.inquiry-modal::-webkit-scrollbar-thumb {
    background: #0066ff;
    border-radius: 10px;
}

.inquiry-modal::-webkit-scrollbar-thumb:hover {
    background: #0052cc;
}
