/* 全局样式 */
:root {
    --primary-color: #F75105;
    --secondary-color: #000000;
    --text-color: #FFFFFF;
    --accent-color: #f7f7f7;
    --font-primary: 'Unbounded', sans-serif;
    --font-secondary: 'Noto Sans TC', sans-serif;
}

.contact-container {
    background: linear-gradient(135deg, #F75105 50%, #FF9500 100%);
    padding: 40px;
    width: 100%;
    border-radius: 32px;
    color: var(--text-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 80px;
    margin-top: 40px;
}


.form-row {
    display: flex;
    margin-bottom: 20px;
    gap: 20px;
}

.form-group {
    flex: 1;
    position: relative;
}

.form-control {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--text-color);
    padding: 10px 0;
    outline: none;
    color: var(--text-color);
    font-family: var(--font-secondary);
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-bottom: 2px solid var(--secondary-color);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    font-family: var(--font-secondary);
    font-weight: 700;
}

.required {
    color: #FFF;
    margin-left: 3px;
}

.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-family: var(--font-secondary);
    font-size: 16px;
}

.checkbox-input {
    margin-right: 8px;
    cursor: pointer;
    accent-color: var(--secondary-color);
    width: 18px;
    height: 18px;
}

.textarea-group {
    margin-top: 25px;
}

.form-textarea {
    width: 100%;
    height: 120px;
    background: var(--text-color);
    border: none;
    border-radius: 10px;
    padding: 15px;
    resize: none;
    margin-top: 8px;
    font-family: var(--font-secondary);
    font-size: 16px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.submit-btn {
    background-color: var(--secondary-color);
    color: var(--text-color);
    border: none;
    padding: 16px 48px;
    border-radius: 32px;
    cursor: pointer;
    font-family: var(--font-secondary);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin-top: 24px;
    font-weight: 700;
    font-size: 16px;
    line-height: 24px;
    letter-spacing: 0%;
    width: 100%;
}

.submit-btn:hover {
    background-color: #222;
    transform: translateY(-2px);
}

.full-width {
    width: 100%;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 10px;
    font-family: var(--font-secondary);
}


.alert-danger {
    background-color: rgba(248, 215, 218, 0.9);
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* 加载动画样式 */
.loading-spinner {
    display: none;
    position: relative;
    width: 18px;
    height: 18px;
    margin-left: 10px;
    vertical-align: middle;
}

.loading-spinner:after {
    content: " ";
    display: block;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid #fff;
    border-color: #fff transparent #fff transparent;
    animation: loading-spinner 1.2s linear infinite;
}

@keyframes loading-spinner {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.btn-text {
    display: inline-block;
    vertical-align: middle;
}


/* 自定义类似Sweetalert2的弹窗样式 */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sweet-alert-kocok {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    width: 400px;
    background-color: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    padding: 30px;
    text-align: center;
    z-index: 1001;
    display: none;
    opacity: 0;
    transition: all 0.3s ease;
}

.sweet-alert-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pop-in 0.5s;
}

.checkmark {
    width: 40px;
    height: 40px;
    position: relative;
}

.checkmark:after {
    content: "";
    position: absolute;
    width: 25px;
    height: 50px;
    border-right: 6px solid white;
    border-bottom: 6px solid white;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -60%) rotate(45deg);
}

.sweet-alert-title {
    color: var(--secondary-color);
    font-family: var(--font-primary);
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 10px;
    animation: fade-in 0.5s 0.3s both;
}

.sweet-alert-message {
    color: #555;
    font-family: var(--font-secondary);
    font-size: 18px;
    margin-bottom: 25px;
    animation: fade-in 0.5s 0.5s both;
}

.sweet-alert-button {
    background-color: var(--primary-color);
    color: white;
    font-family: var(--font-primary);
    font-size: 16px;
    font-weight: 500;
    padding: 12px 30px;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    animation: fade-in 0.5s 0.7s both;
}

.sweet-alert-button:hover {
    background-color: #e84a00;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(247, 81, 5, 0.3);
}

/* 动画效果 */
@keyframes pop-in {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes fade-in {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes checkmark {
    0% {
        height: 0;
        width: 0;
        opacity: 0;
    }
    40% {
        height: 0;
        width: 25px;
        opacity: 1;
    }
    100% {
        height: 50px;
        width: 25px;
        opacity: 1;
    }
}

/* 显示弹窗的样式 */
.modal-backdrop.show {
    opacity: 1;
    display: block;
}

.sweet-alert-kocok.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    display: block;
}

.button-wrapper {
    width: 100%;
    display: flex;
    justify-content: flex-end;
}

/* 响应式设计 - 保持原有设计风格 */
@media (max-width: 1024px) {
    .contact-container {
        padding: 35px;
        margin: 60px auto;
    }

}

@media (max-width: 768px) {
    .contact-container {
        padding: 30px 20px;
        margin: 40px auto;
    }


    .form-row {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 15px;
    }

    .form-group {
        margin-bottom: 0;
    }

    .checkbox-group {
        flex-direction: column;
        gap: 10px;
    }

    .checkbox-label {
        margin-bottom: 5px;
    }

    .button-wrapper {
        justify-content: center;
        margin-top: 20px;
    }

    .submit-btn {
        width: 100%;
        padding: 12px 24px;
    }

    .textarea-group {
        margin-top: 20px;
    }

    .form-textarea {
        height: 100px;
        padding: 12px;
    }
}

@media (max-width: 480px) {
    .contact-container {
        padding: 25px 15px;
        margin: 20px auto;
        border-radius: 15px;
    }


    .form-control {
        font-size: 16px; /* 防止iOS缩放 */
        padding: 12px 0;
    }

    .form-textarea {
        font-size: 16px; /* 防止iOS缩放 */
        height: 90px;
        padding: 10px;
    }

    .checkbox-label {
        font-size: 15px;
        margin-bottom: 8px;
    }

    .submit-btn {
        font-size: 15px;
        padding: 10px 20px;
    }

    .sweet-alert-kocok {
        width: 90%;
        padding: 25px 20px;
    }

    .sweet-alert-title {
        font-size: 24px;
    }

    .sweet-alert-message {
        font-size: 16px;
    }

    .sweet-alert-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 15px;
    }
}

@media (max-width: 360px) {
    .contact-container {
        padding: 20px 12px;
    }


    .checkbox-label {
        font-size: 14px;
    }

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