/**
 * WPForms Dynamic Form Loader - CSS Styles
 */

.wpforms-child-form-container {
  margin-top: 20px;
  padding: 32px 24px;
  border: 2px solid #000;
  border-radius: 8px;
  background-color: #fff;
  transition: all 0.3s ease;
}

.wpforms-child-form-container:empty {
  display: none;
}

.wpforms-child-form-container.loading {
  opacity: 0.7;
  pointer-events: none;
}

.wpforms-child-form-container .wpforms-container {
  margin: 0;
}

/* 子フォームのフォントカスタマイズ */
.wpforms-child-form-container .wpforms-container {
  font-family: 'Helvetica Neue', Arial, sans-serif;
  color: #333333;
  background-color: transparent;
}

/* 子フォームのラベルスタイル */
.wpforms-child-form-container .wpforms-field-label {
  color: #2c3e50;
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 8px;
}

/* 子フォームの必須ラベル */
.wpforms-child-form-container .wpforms-required-label {
  color: #e74c3c;
  font-weight: bold;
}

/* 子フォームの入力フィールド */
.wpforms-child-form-container .wpforms-field input[type='text'],
.wpforms-child-form-container .wpforms-field input[type='email'],
.wpforms-child-form-container .wpforms-field input[type='tel'],
.wpforms-child-form-container .wpforms-field input[type='url'],
.wpforms-child-form-container .wpforms-field textarea,
.wpforms-child-form-container .wpforms-field select {
  color: #2c3e50;
  font-size: 14px;
  border: 2px solid #bdc3c7;
  border-radius: 4px;
  padding: 10px 12px;
  transition: border-color 0.3s ease;
}

/* 子フォームの入力フィールドフォーカス時 */
.wpforms-child-form-container .wpforms-field input[type='text']:focus,
.wpforms-child-form-container .wpforms-field input[type='email']:focus,
.wpforms-child-form-container .wpforms-field input[type='tel']:focus,
.wpforms-child-form-container .wpforms-field input[type='url']:focus,
.wpforms-child-form-container .wpforms-field textarea:focus,
.wpforms-child-form-container .wpforms-field select:focus {
  border-color: #3498db;
  outline: none;
  box-shadow: 0 0 5px rgba(52, 152, 219, 0.3);
}

/* 子フォームのプレースホルダーテキスト */
.wpforms-child-form-container .wpforms-field input::placeholder,
.wpforms-child-form-container .wpforms-field textarea::placeholder {
  color: #95a5a6;
  font-style: italic;
}

/* 子フォームの送信ボタン */
.wpforms-child-form-container .wpforms-submit-container button,
.wpforms-child-form-container .wpforms-submit-container input[type='submit'] {
  background-color: #3498db;
  color: #ffffff;
  font-weight: 600;
  font-size: 16px;
  padding: 12px 24px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.wpforms-child-form-container .wpforms-submit-container button:hover,
.wpforms-child-form-container .wpforms-submit-container input[type='submit']:hover {
  background-color: #2980b9;
}

/* 子フォームのエラーメッセージ */
.wpforms-child-form-container .wpforms-error {
  color: #e74c3c;
  font-size: 12px;
  font-weight: 500;
  margin-top: 5px;
}

/* 子フォームの成功メッセージ */
.wpforms-child-form-container .wpforms-confirmation-container {
  color: #27ae60;
  font-weight: 500;
  background-color: #d5f4e6;
  border: 1px solid #27ae60;
  border-radius: 4px;
  padding: 15px;
  margin-top: 15px;
}

/* 子フォームのチェックボックスとラジオボタン */
.wpforms-child-form-container .wpforms-field-checkbox label,
.wpforms-child-form-container .wpforms-field-radio label {
  color: #2c3e50;
  font-size: 14px;
  font-weight: 400;
}

/* 子フォームのセクションタイトル */
.wpforms-child-form-container .wpforms-field-container h3,
.wpforms-child-form-container .wpforms-field-container h4 {
  color: #2c3e50;
  font-weight: 600;
  margin-bottom: 15px;
}

/* ローディングアニメーション */
.wpforms-child-form-container .loading-spinner {
  text-align: center;
  padding: 20px;
}

.wpforms-child-form-container .loading-spinner::after {
  content: '';
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid #3498db;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-left: 10px;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* エラーメッセージ */
.wpforms-child-form-container .error-message {
  color: #d63638;
  text-align: center;
  padding: 20px;
  background-color: #fef7f1;
  border: 1px solid #d63638;
  border-radius: 4px;
}

/* 成功メッセージ */
.wpforms-child-form-container .success-message {
  color: #00a32a;
  text-align: center;
  padding: 20px;
  background-color: #f0f6fc;
  border: 1px solid #00a32a;
  border-radius: 4px;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .wpforms-child-form-container {
    padding: 15px;
    margin-top: 15px;
  }
}

/* アニメーション効果 */
.wpforms-child-form-container.fade-in {
  animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* フォーム切り替え時のスムーズな遷移 */
.wpforms-child-form-container .wpforms-container {
  transition: opacity 0.3s ease;
}

.wpforms-child-form-container .wpforms-container.fade-out {
  opacity: 0;
}

.wpforms-child-form-container .wpforms-container.fade-in {
  opacity: 1;
}

/* 親フォームの送信ボタンを非表示 */
#wpforms-form-10704 .wpforms-submit-container,
#wpforms-form-10704 .wpforms-submit-container button,
#wpforms-form-10704 .wpforms-submit-container input[type='submit'],
#wpforms-form-10704 button[type='submit'],
#wpforms-form-10704 input[type='submit'] {
  display: none !important;
}
