/* お問い合わせ・フッターセクション */
.footer {
  background: #f8f9fa;
  color: #333;
}

/* フォームコンテナ */
.contact-form {
  background: linear-gradient(145deg, #ffffff 0%, #fafbfc 100%);
  border-radius: 16px;
  padding: 3rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06), 0 2px 8px rgba(0, 0, 0, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(0, 159, 232, 0.08);
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.contact-form::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--primary-color) 0%,
    var(--primary-hover) 100%
  );
  border-radius: 16px 16px 0 0;
}

.contact-section {
  padding: 6rem 2rem;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 50%, #f8f9fa 100%);
  position: relative;
}

.contact-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--primary-color),
    transparent
  );
}

/* フォームラッパー */
.contact-form-wrapper {
  display: flex;
  justify-content: center;
  width: 100%;
}

/* フォーム内のビジュアルエンハンス */
.contact-form fieldset {
  position: relative;
}

.contact-form fieldset::before {
  content: "";
  position: absolute;
  top: -1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: linear-gradient(
    90deg,
    var(--primary-color),
    var(--primary-hover)
  );
  border-radius: 1px;
  opacity: 0.3;
}

.contact-content {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 1rem;
}

/* 古いform-groupスタイルは.groupに統一されました */

/* 旧contact-infoスタイルを削除 - フッターに統合されました */

.footer {
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  padding: 3rem 0 2rem;
  color: white;
  margin-top: 4rem;
  border-top: 1px solid rgba(0, 159, 232, 0.1);
}

.footer-content-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-logo h3 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, var(--primary-color), #00bcd4);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}

.footer-logo p {
  color: #cccccc;
  font-size: 0.9rem;
  margin-bottom: 0.3rem;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: #cccccc;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: #009fe8;
}

.footer-legal {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.legal-link {
  color: #999999;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.legal-link:hover {
  color: #009fe8;
}

.footer-copyright {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #999999;
  font-size: 0.9rem;
}

/* フォーム固有のスタイル */
.styles_fieldset__NZO8t {
  border: none;
  padding: 0;
}

.group {
  margin-bottom: 1.5rem;
}

.group:last-of-type {
  margin-bottom: 0;
}

/* 名前フィールドの横並びレイアウト */
.name-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.name-fields .group {
  margin-bottom: 0;
}

/* フォームグリッドレイアウト */
.form-grid {
  display: grid;
  gap: 1.5rem;
}

/* 大きなフィールド用 */
.field-full {
  grid-column: 1 / -1;
}

/* 中サイズフィールド用 */
.field-half {
  grid-column: span 1;
}

/* フォーム全体のスタイリング */
#contact-form {
  width: 100%;
}

.contact-form fieldset {
  width: 100%;
}

.styles_fieldset__NZO8t {
  border: none;
  padding: 0;
  margin: 0;
}

/* プレースホルダースタイル */
.group input::placeholder,
.group textarea::placeholder {
  color: #9ca3af;
  font-size: 0.9rem;
  font-style: italic;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.group input:focus::placeholder,
.group textarea:focus::placeholder {
  opacity: 0.5;
  transform: translateY(-2px);
}
.footer-contact-button {
  color: #cccccc;
  text-decoration: none;
  transition: color 0.3s ease;
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
  font-weight: inherit;
  cursor: pointer;
  display: inline-block;
  text-align: left;
}

.footer-contact-button:hover {
  color: #009fe8;
}

/* フォームレスポンシブデザイン */
@media (max-width: 768px) {
  .contact-form {
    margin: 0 1rem;
    padding: 2rem 1.5rem;
    border-radius: 12px;
    max-width: none;
  }

  .name-fields {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .form-grid {
    gap: 1rem;
  }

  .contact-content {
    flex-direction: column;
    align-items: center;
  }

  .contact-form-wrapper {
    width: 100%;
  }

  .group input[type="text"],
  .group input[type="email"],
  .group textarea {
    padding: 1rem 0.875rem;
    font-size: 16px; /* iOSズーム防止 */
  }

  .contact-content {
    padding: 0 0.5rem;
  }

  .contact-section {
    padding: 4rem 1rem;
  }

  .contact-submit {
    padding: 1rem 1.5rem;
    font-size: 1rem;
    max-width: none;
    width: 100%;
    margin: 1.5rem 0 0;
  }

  .footer-content-wrapper {
    padding: 0 1rem;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    text-align: center;
  }

  .footer {
    margin-top: 2rem;
    padding: 2rem 0 1.5rem;
  }
}

.form-label {
  display: block;
  margin-bottom: 0.75rem;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 1rem;
  letter-spacing: 0.3px;
  line-height: 1.4;
}

.form-label.require::after {
  content: " *";
  color: #e74c3c;
  font-weight: 700;
  margin-left: 2px;
}

/* フィールドグループのホバー効果 */
.group {
  position: relative;
  transition: all 0.3s ease;
}

.group:hover .form-label {
  color: var(--primary-color);
}

.group:hover input:not(:focus),
.group:hover textarea:not(:focus) {
  border-color: rgba(0, 159, 232, 0.3);
  background: white;
}

.group input[type="text"],
.group input[type="email"],
.group input[type="tel"],
.group textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 2px solid #e8eaed;
  border-radius: 8px;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #fafbfc;
  font-family: inherit;
  line-height: 1.5;
}

.group textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.6;
  font-family: inherit;
  border-radius: 8px;
  width: 100%;
}

/* テキストエリア特別スタイル */
textarea[name="inquiry"] {
  background: linear-gradient(145deg, #fafbfc 0%, #f8f9fa 100%);
  border: 2px solid #e8eaed;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  min-height: 160px;
  max-height: 300px;
}

textarea[name="inquiry"]:focus {
  background: white;
  outline: none;
  box-shadow: 0 0 0 4px rgba(0, 159, 232, 0.12), 0 4px 12px rgba(0, 0, 0, 0.08),
    inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

.group input:focus,
.group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  background: white;
  box-shadow: 0 0 0 4px rgba(0, 159, 232, 0.12), 0 2px 8px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.group input::placeholder,
.group textarea::placeholder {
  color: #999999;
  font-size: 0.9rem;
}

.group input[type="checkbox"] {
  margin-right: 0.75rem;
  width: 18px;
  height: 18px;
  accent-color: var(--primary-color);
  cursor: pointer;
}

.group label {
  display: flex;
  align-items: flex-start;
  font-size: 0.9rem;
  color: var(--text-secondary);
  cursor: pointer;
  line-height: 1.5;
  gap: 0.5rem;
}

.group label a {
  color: #009fe8;
  text-decoration: none;
  margin: 0 0.25rem;
  font-weight: 600;
}

.group label a:hover {
  text-decoration: underline;
}

.contact-submit {
  width: 100%;
  max-width: 200px;
  margin: 1rem auto 0;
  padding: 1.125rem 1.5rem;
  background: linear-gradient(
    135deg,
    var(--primary-color) 0%,
    var(--primary-hover) 100%
  );
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
  display: block;
}

.contact-submit:not(:disabled):hover {
  background: linear-gradient(135deg, var(--primary-hover) 0%, #005a91 100%);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 159, 232, 0.35), 0 4px 12px rgba(0, 0, 0, 0.15);
}

.contact-submit:not(:disabled):active {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 159, 232, 0.25);
}

.contact-submit:disabled {
  background: linear-gradient(135deg, #e0e0e0 0%, #cccccc 100%);
  cursor: not-allowed;
  opacity: 0.6;
  transform: none;
  box-shadow: none;
}

/* フォームヘッダースタイル */
/* フォームヘッダーの調整 */
.contact-section .section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.contact-section .section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--primary-hover)
  );
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}

.contact-section .section-header p {
  font-size: 1.1rem;
  color: var(--text-light);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ダイアログスタイル */
.dialog {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  animation: fadeIn 0.3s ease;
}

.dialog.show {
  display: flex;
  justify-content: center;
  align-items: center;
}

.dialog-content {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  width: 90%;
  max-width: 500px;
  position: relative;
  animation: slideUp 0.3s ease;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.dialog-content h3 {
  margin-bottom: 1.5rem;
  color: #333333;
  font-size: 1.2rem;
  text-align: center;
}

#confirm-details {
  background: #f8f9fa;
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  max-height: 300px;
  overflow-y: auto;
}

#confirm-details .detail-item {
  padding: 0.5rem 0;
  border-bottom: 1px solid #e0e0e0;
}

#confirm-details .detail-item:last-child {
  border-bottom: none;
}

#confirm-details .detail-label {
  font-weight: 600;
  color: #555555;
  margin-right: 0.5rem;
}

#confirm-details .detail-value {
  color: #333333;
}

.dialog-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.dialog-buttons button {
  padding: 0.75rem 2rem;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  font-size: 0.95rem;
}

#cancel-btn {
  background: #e0e0e0;
  color: #333333;
}

#cancel-btn:hover {
  background: #cccccc;
}

#final-submit-btn {
  background: linear-gradient(45deg, #009fe8, #0078c1);
  color: white;
}

#final-submit-btn:hover {
  background: linear-gradient(45deg, #0078c1, #005a91);
  transform: translateY(-1px);
}

.close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #999999;
  cursor: pointer;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.close-btn:hover {
  background: #f0f0f0;
  color: #333333;
}

/* アニメーション */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

/* エラーメッセージスタイル */
.error-message {
  color: #e74c3c;
  font-size: 0.85rem;
  margin-top: 0.25rem;
  display: none;
}

.group.error input {
  border-color: #e74c3c;
}

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

/* 成功メッセージ */
.success-message {
  background: #d4edda;
  color: #155724;
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  display: none;
}

.success-message.show {
  display: block;
  animation: slideDown 0.3s ease;
}

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