/* form.css - 表单+按钮+交互（联络页/留言页加载） */

/* ===== 表单容器 ===== */
.form-wrapper {
  max-width: 800px;
  margin: 0 auto;
}

.form-row {
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-flex-wrap: wrap;
  flex-wrap: wrap;
  margin: 0 -10px;
}

.form-group {
  width: 50%;
  padding: 0 10px;
  margin-bottom: 20px;
}

.form-group.full {
  width: 100%;
}

.form-label {
  display: block;
  font-size: 15px;
  color: var(--primary);
  margin-bottom: 8px;
  font-weight: 500;
}

.form-label .required {
  color: var(--secondary);
  margin-left: 4px;
}

/* ===== 输入框 ===== */
.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-family: var(--font-family);
  font-size: 15px;
  color: var(--text-dark);
  background-color: #fff;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(27,58,75,0.1);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: #aaa;
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
}

.form-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23666' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14L2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

@media screen and (max-width: 767px) {
  .form-group {
    width: 100%;
  }
}

/* ===== 单选/复选 ===== */
.form-check {
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-align: center;
  -webkit-align-items: center;
  align-items: center;
  margin-bottom: 10px;
  cursor: pointer;
}

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

.form-check-label {
  font-size: 14px;
  color: var(--text-dark);
  cursor: pointer;
}

/* ===== 表单提示 ===== */
.form-hint {
  font-size: 13px;
  color: var(--text-gray);
  margin-top: 6px;
}

.form-error {
  font-size: 13px;
  color: var(--secondary);
  margin-top: 6px;
}

/* ===== 表单提交 ===== */
.form-submit {
  text-align: center;
  margin-top: 24px;
}

.form-submit .btn {
  padding: 14px 48px;
  font-size: 17px;
}

/* ===== 表单成功提示 ===== */
.form-success {
  background-color: rgba(27,58,75,0.05);
  border: 1px solid var(--primary);
  border-radius: 8px;
  padding: 32px;
  text-align: center;
}

.form-success-icon {
  width: 64px;
  height: 64px;
  background-color: var(--primary);
  border-radius: 50%;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-align: center;
  -webkit-align-items: center;
  align-items: center;
  -webkit-box-pack: center;
  -webkit-justify-content: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.form-success-icon svg {
  width: 32px;
  height: 32px;
  fill: var(--text-white);
}

.form-success-title {
  font-size: 22px;
  color: var(--primary);
  margin-bottom: 12px;
}

.form-success-text {
  font-size: 15px;
  color: var(--text-gray);
}

/* ===== 搜索框 ===== */
.search-box {
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  max-width: 600px;
  margin: 0 auto;
}

.search-input {
  -webkit-box-flex: 1;
  -webkit-flex: 1;
  flex: 1;
  padding: 14px 20px;
  border: 2px solid var(--border-color);
  border-right: none;
  border-radius: 6px 0 0 6px;
  font-family: var(--font-family);
  font-size: 15px;
  color: var(--text-dark);
  background-color: #fff;
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
}

.search-btn {
  padding: 14px 28px;
  background-color: var(--primary);
  color: var(--text-white);
  border: 2px solid var(--primary);
  border-radius: 0 6px 6px 0;
  cursor: pointer;
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.search-btn:hover {
  background-color: var(--secondary);
  border-color: var(--secondary);
}

/* ===== 搜索结果 ===== */
.search-results {
  margin-top: 32px;
}

.search-result-item {
  padding: 20px 0;
  border-bottom: 1px solid var(--border-color);
}

.search-result-title {
  font-size: 18px;
  color: var(--primary);
  margin-bottom: 6px;
  font-weight: 500;
}

.search-result-title:hover {
  color: var(--secondary);
}

.search-result-summary {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.7;
  margin-bottom: 6px;
}

.search-result-url {
  font-size: 13px;
  color: #0a6e31;
}

/* ===== 常见问题 ===== */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  margin-bottom: 16px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
}

.faq-question {
  padding: 16px 20px;
  background-color: #fff;
  font-size: 16px;
  color: var(--primary);
  font-weight: 500;
  cursor: pointer;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-pack: justify;
  -webkit-justify-content: space-between;
  justify-content: space-between;
  -webkit-box-align: center;
  -webkit-align-items: center;
  align-items: center;
  -webkit-transition: background-color 0.3s ease;
  transition: background-color 0.3s ease;
}

.faq-question:hover {
  background-color: rgba(27,58,75,0.03);
}

.faq-question svg {
  width: 20px;
  height: 20px;
  fill: var(--primary);
  -webkit-transition: transform 0.3s ease;
  transition: transform 0.3s ease;
  -webkit-flex-shrink: 0;
  flex-shrink: 0;
  margin-left: 12px;
}

.faq-item.active .faq-question svg {
  -webkit-transform: rotate(180deg);
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  -webkit-transition: max-height 0.3s ease;
  transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
  max-height: 500px;
}

.faq-answer-inner {
  padding: 0 20px 16px;
  font-size: 15px;
  color: var(--text-gray);
  line-height: 1.8;
}

/* ===== 地图容器 ===== */
.map-container {
  width: 100%;
  height: 400px;
  border-radius: 8px;
  overflow: hidden;
  background-color: var(--page-bg);
  border: 1px solid var(--border-color);
}

@media screen and (max-width: 767px) {
  .map-container {
    height: 280px;
  }
}

/* ===== 联系信息卡片 ===== */
.contact-info-grid {
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-flex-wrap: wrap;
  flex-wrap: wrap;
  margin: 0 -12px;
}

.contact-info-item {
  width: 50%;
  padding: 0 12px;
  margin-bottom: 20px;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-align: start;
  -webkit-align-items: flex-start;
  align-items: flex-start;
}

.contact-info-icon {
  width: 44px;
  height: 44px;
  background-color: rgba(27,58,75,0.08);
  border-radius: 8px;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-align: center;
  -webkit-align-items: center;
  align-items: center;
  -webkit-box-pack: center;
  -webkit-justify-content: center;
  justify-content: center;
  margin-right: 14px;
  -webkit-flex-shrink: 0;
  flex-shrink: 0;
}

.contact-info-icon svg {
  width: 20px;
  height: 20px;
  fill: var(--primary);
}

.contact-info-title {
  font-size: 14px;
  color: var(--text-gray);
  margin-bottom: 4px;
}

.contact-info-text {
  font-size: 16px;
  color: var(--primary);
  font-weight: 500;
}

@media screen and (max-width: 767px) {
  .contact-info-item {
    width: 100%;
  }
}
