*,
*::before,
*::after {
  box-sizing: border-box;
}

.register-container,
input,
select,
textarea,
button {
  font-family: "MyIansui", serif;
}

.register-container {
  max-width: 1000px;
  margin: 20px auto;
  background-color: #e9eaeb;
  padding: 20px 35px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* 標題 */
.section-title {
  text-align: center;
  color: #2c3e50;
  margin: 0;
  font-size: 40px;
}

.form-notice {
  font-size: 18px;
  margin-bottom: 20px;
}

/* *標記 */
.required-mark {
  color: #d9534f;
  margin-right: 4px;
}

/* 表單大項 */
.section-subtitle {
  color: #597da1;
  border-left: 3px solid #597da1;
  padding-left: 10px;
  margin: 0 0 10px;
  font-size: 24px;
  line-height: 1.5;
}

.register-form {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.form-section {
  display: flex;
  flex-direction: column;
  gap: 20px; /* 上下行距 */
  margin-bottom: 10px;
}

/* 表單通用設定 */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group > label {
  font-size: 18px;
  font-weight: bold;
  color: #34495e;
}

.form-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form-block > label {
  font-size: 18px;
  font-weight: bold;
  color: #34495e;
}

/* 右側內容容器 */
.form-content {
  display: flex;
  flex-direction: column;
  width: 100%;
}

/* --- 輸入元件樣式 --- */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="url"],
input[type="tel"],
select,
textarea,
.file-upload-area {
  width: 100%;
  padding: 12px;
  border: 1px solid #cbd5e0;
  border-radius: 6px;
  font-size: 18px;
  background-color: #f8fafc;
  line-height: 1.5;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #5a67d8;
  box-shadow: 0 0 0 3px rgba(90, 103, 216, 0.2);
}

.hint {
  font-size: 16px;
  color: #718096;
  margin: 5px 0 0;
  line-height: 1.4;
}

/* 選項群組 */
.radio-group,
.checkbox-group,
.checkbox-group-special {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0;
}

.radio-group label,
.checkbox-group label,
.checkbox-group-special label {
  display: inline-flex;
  align-items: center;
  font-size: 16px;
  cursor: pointer;
  white-space: nowrap;
  color: #333;
  margin-right: 20px;
  font-weight: normal;
}

.radio-group input,
.checkbox-group input,
.checkbox-group-special input {
  margin: 0 8px 0 0;
  transform: scale(1.2);
  flex-shrink: 0;
  position: relative;
  top: 1px;
}

/* 服務條款連結樣式 */
.terms-link {
  display: inline-block;
  color: #597da1;
  text-decoration: underline;
  margin-bottom: 5px; /* 稍微拉開與 checkbox 的距離 */
  font-size: 16px;
  cursor: pointer;
  width: fit-content; /* 確保 hover 範圍正確 */
}

.terms-link:hover {
  color: #2c3e50;
}

.row-flex {
  flex-direction: row !important;
  gap: 30px !important;
}

.btn-register-submit {
  background-color: #2c3e50;
  color: white;
  padding: 18px;
  border-radius: 8px;
  border: none;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
  margin-top: 20px;
}

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

/* 電腦版排版 */
@media (min-width: 768px) {
  .form-group {
    flex-direction: row;
    align-items: flex-start;
  }

  .form-group > label {
    width: 180px;
    text-align: right;
    padding-right: 5px;
    margin-bottom: 0;
    flex-shrink: 0;
    padding-top: 13px;
  }

  .form-content {
    flex: 1;
  }

  .radio-group,
  .checkbox-group {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    padding-top: 13px;
  }
}
