﻿/* ========================================= */
/* === 全域與卡片佈局 (Global & Layout) === */
/* ========================================= */
/* 🌟 加上這段：強制把公版的底色統一代換成淺灰色 */
body, .page-wrapper {
    background-color: #f5f5f5 !important;
}

.register-body {
    background-color: #f5f5f5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    font-family: "微軟正黑體", sans-serif;
    margin: 0;
}

.register-main {
    width: 100%; /* 讓它佔滿左右空間 */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 20px;
    box-sizing: border-box; /* 確保 padding 不會把版面撐破 */
}

.register-card {
    background: white;
    width: 100%;
    max-width: 800px;
    padding: 50px;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.register-title {
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 40px;
}

.applicant-footer {
    background-color: #444;
    color: #ccc;
    text-align: center;
    padding: 12px 0;
    font-size: 0.85rem;
}

.page-wrapper {
    background-color: #f5f5f5 !important;
}
/* ========================================= */
/* === 表單排版系統 (Form Layout) === */
/* ========================================= */
.form-group {
    display: flex;
    margin-bottom: 20px;
    align-items: flex-start;
}

.form-label {
    width: 180px;
    text-align: right;
    padding-right: 15px;
    padding-top: 8px;
    color: #333;
}

.form-content {
    flex-grow: 1;
}

.form-input {
    width: 100%;
    max-width: 250px;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus {
    border-color: #ff8c00;
}

.form-input.wide {
    max-width: 450px;
}

.form-input:disabled {
    background-color: #e9ecef;
    cursor: not-allowed;
}

/* ========================================= */
/* === 表單特殊元件 (Components) === */
/* ========================================= */

/* --- 密碼與眼睛圖示 --- */
.password-wrapper {
    position: relative;
    width: 100%;
    max-width: 250px;
}

.password-wrapper .form-input {
    width: 100%;
    padding-right: 35px;
    box-sizing: border-box;
}

.eye-icon {
    position: absolute;
    right: 9px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #666;
}

/* --- 驗證碼區塊 --- */
.captcha-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.captcha-wrapper .form-input {
    max-width: 120px;
}

.captcha-img {
    border: 1px dashed #0056b3;
    padding: 5px 15px;
    font-size: 1.2rem;
    font-weight: bold;
    letter-spacing: 5px;
    background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFElEQVQIW2NkYGD4z8DAwMgAI0AMDA4BGw/8aHQAAAAASUVORK5CYII=') repeat;
}

.refresh-icon {
    color: #ff8c00;
    cursor: pointer;
    font-size: 1.2rem;
}

/* ========================================= */
/* === 表單操作與提示區 (Actions & Hints) === */
/* ========================================= */

.required-star {
    color: #d9534f;
    margin-right: 5px;
}

.hint-inline {
    color: #ff8c00;
    margin-left: 10px;
    font-size: 0.95rem;
}

.hint-block {
    color: #ff8c00;
    font-size: 0.85rem;
    margin-top: 5px;
}

.field-error {
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 5px;
    display: block;
    font-weight: bold;
}

.checkbox-group {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 40px 0 30px;
}

.checkbox-group input {
    margin-right: 10px;
    width: 18px;
    height: 18px;
}

.checkbox-group a {
    color: #ff8c00;
    text-decoration: none;
}

.checkbox-group a:hover {
    text-decoration: underline;
}

.submit-btn-wrapper {
    text-align: center;
}

.btn-submit {
    background-color: #ff8c00;
    color: white;
    border: none;
    padding: 12px 40px;
    font-size: 1.1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-submit:hover {
    background-color: #e67e00;
}

.btn-cancel {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 30px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
    border: 1px solid #ccc;
    background-color: #f8f9fa;
    color: #555;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-cancel:hover {
    background-color: #e2e6ea;
    border-color: #dae0e5;
    color: #333;
}

.login-links {
    margin-top: 25px;
    text-align: center;
    font-size: 0.95rem;
    font-weight: bold;
}

.login-links a {
    color: #333;
    text-decoration: none;
    padding: 0 10px;
    transition: color 0.2s;
}

.login-links a:hover {
    color: #ff8c00;
}

.login-links .separator {
    color: #ccc;
    font-weight: normal;
}

/* ========================================= */
/* === 隱私權同意書彈跳視窗 (Modal) === */
/* ========================================= */

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    background-color: #fff;
    width: 90%;
    max-width: 750px;
    border-radius: 4px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    max-height: 85vh;
}

.modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: center;
    position: relative;
    background-color: #f8f9fa;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #0056b3;
    font-weight: bold;
}

.close-btn {
    position: absolute;
    right: 15px;
    top: 10px;
    background: none;
    border: none;
    font-size: 1.8rem;
    color: #666;
    cursor: pointer;
}

.close-btn:hover {
    color: #333;
}

.modal-body {
    padding: 20px 30px;
    overflow-y: auto;
    flex-grow: 1;
    color: #444;
    font-size: 0.95rem;
}

.modal-body p {
    margin: 0 0 8px 0;
    line-height: 1.6;
    text-align: justify;
}

.modal-body h4 {
    font-weight: bold;
    color: #333;
    margin-top: 15px;
}

.indent-1 {
    padding-left: 2.2em;
    text-indent: -2.2em;
}

.indent-2 {
    padding-left: 4.5em;
    text-indent: -2.3em;
    margin-bottom: 4px !important;
}

.indent-note {
    padding-left: 4.5em;
    margin-top: 5px;
    color: #555;
}

.modal-footer {
    padding: 15px;
    border-top: 1px solid #ddd;
    background-color: #ffecd9;
    text-align: center;
}

.btn-agree-modal {
    background-color: #ff8c00;
    color: white;
    border: none;
    padding: 12px 30px;
    font-size: 1.05rem;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.2s;
}

.btn-agree-modal:hover {
    background-color: #e67e00;
}

/* ========================================= */
/* === 手機版響應式微調 (RWD) === */
/* ========================================= */

@media (max-width: 600px) {
    .form-group {
        flex-direction: column;
    }

    .form-label {
        width: 100%;
        text-align: left;
        margin-bottom: 5px;
    }
}