/* ==============================================================================
   MATSUYA R&D VIETNAM - SECTION: CÂU HỎI THƯỜNG GẶP (FAQ) & FORM TƯ VẤN BÁO GIÁ
   Dark Tech Theme với Accordion tương tác & Form chuyển đổi cao cấp
   ============================================================================== */

.mrd-faq-wrapper {
  width: 100%;
  position: relative;
  background: linear-gradient(135deg, #061527 0%, #0a2540 55%, #003666 100%);
  padding: 85px 0 95px 0;
  color: #ffffff;
  overflow: hidden;
  border-top: 1px solid rgba(0, 229, 255, 0.22);
  border-bottom: 1px solid rgba(0, 229, 255, 0.15);
  box-sizing: border-box;
}

/* Hiệu ứng ánh sáng nền ambient glow công nghiệp giống hệt section CTA banner */
.mrd-faq-wrapper::before {
  content: '';
  position: absolute;
  top: -40%;
  left: -10%;
  width: 55%;
  height: 180%;
  background: radial-gradient(circle at center, rgba(0, 159, 227, 0.16) 0%, transparent 65%);
  pointer-events: none;
  z-index: 1;
}

.mrd-faq-wrapper::after {
  content: '';
  position: absolute;
  bottom: -40%;
  right: -5%;
  width: 50%;
  height: 180%;
  background: radial-gradient(circle at center, rgba(0, 229, 255, 0.12) 0%, transparent 65%);
  pointer-events: none;
  z-index: 1;
}

.mrd-faq-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 2;
}

/* 2-Column Grid Layout */
.mrd-faq-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: start;
}

/* --------------------------------------------------------------------------
   CỘT TRÁI: DANH SÁCH CÂU HỎI THƯỜNG GẶP (ACCORDION)
   -------------------------------------------------------------------------- */
.mrd-faq-left {
  display: flex;
  flex-direction: column;
}

.mrd-faq-header {
  margin-bottom: 28px;
}

.mrd-faq-title {
  font-size: 34px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin: 0 0 12px 0;
  line-height: 1.25;
}

.mrd-faq-subtitle {
  font-size: 15px;
  color: #94a3b8;
  line-height: 1.6;
  margin: 0 0 20px 0;
}

/* Thanh Gạch 2 Màu Đẳng Cấp (Cyan / Xám) */
.mrd-faq-divider {
  display: flex;
  align-items: center;
  width: 180px;
  height: 3px;
  border-radius: 2px;
  overflow: hidden;
}

.mrd-faq-divider-blue {
  width: 45%;
  height: 100%;
  background: #009fe3;
  box-shadow: 0 0 8px #009fe3;
}

.mrd-faq-divider-gray {
  width: 55%;
  height: 100%;
  background: rgba(255, 255, 255, 0.25);
}

/* Accordion Container */
.mrd-faq-list {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Accordion Item */
.mrd-faq-item {
  border-bottom: 1px solid #e2e8f0;
  transition: all 0.25s ease;
}

.mrd-faq-item:last-child {
  border-bottom: none;
}

/* Thanh Tiêu Đề Câu Hỏi */
.mrd-faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  background-color: #ffffff;
  color: #0f172a;
  border: none;
  cursor: pointer;
  text-align: left;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.45;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  outline: none;
  user-select: none;
}

.mrd-faq-question-text {
  flex: 1;
}

/* Biểu Tượng Vuông Icon +/- */
.mrd-faq-icon-box {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  background-color: #009fe3;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 2px;
  transition: all 0.2s ease;
}

.mrd-faq-icon-box svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  transition: transform 0.2s ease;
}

.mrd-faq-icon-minus {
  display: none;
}

.mrd-faq-icon-plus {
  display: block;
}

/* Trạng Thái Đang Mở (Active) */
.mrd-faq-item.is-open .mrd-faq-question {
  background-color: #009fe3;
  color: #ffffff;
}

.mrd-faq-item.is-open .mrd-faq-icon-box {
  background-color: transparent;
  color: #ffffff;
}

.mrd-faq-item.is-open .mrd-faq-icon-plus {
  display: none;
}

.mrd-faq-item.is-open .mrd-faq-icon-minus {
  display: block;
}

/* Khối Nội Dung Trả Lời */
.mrd-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
  opacity: 0;
  background-color: #ffffff;
}

.mrd-faq-item.is-open .mrd-faq-answer {
  opacity: 1;
}

.mrd-faq-answer-inner {
  padding: 16px 20px 22px 20px;
  font-size: 14.5px;
  color: #334155;
  line-height: 1.65;
  border-top: 1px solid rgba(0, 159, 227, 0.15);
}

.mrd-faq-answer-inner p {
  margin: 0 0 10px 0;
}

.mrd-faq-answer-inner p:last-child {
  margin-bottom: 0;
}

.mrd-faq-answer-inner strong {
  color: #004b87;
}

/* --------------------------------------------------------------------------
   CỘT PHẢI: FORM ĐIỀN THÔNG TIN TƯ VẤN & BÁO GIÁ
   -------------------------------------------------------------------------- */
.mrd-faq-right {
  position: sticky;
  top: 100px;
}

.mrd-faq-form-card {
  background: linear-gradient(165deg, #0d1b2e 0%, #15253b 100%);
  border: 1.5px solid rgba(0, 159, 227, 0.35);
  border-radius: 16px;
  padding: 32px 28px;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.45);
  position: relative;
  overflow: hidden;
}

.mrd-form-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 12px;
  background: rgba(0, 159, 227, 0.18);
  border: 1px solid rgba(0, 159, 227, 0.4);
  border-radius: 4px;
  color: #38bdf8;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

.mrd-form-tag-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #38bdf8;
  box-shadow: 0 0 6px #38bdf8;
}

.mrd-form-title {
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 8px 0;
  line-height: 1.3;
}

.mrd-form-sub {
  font-size: 13.5px;
  color: #94a3b8;
  line-height: 1.5;
  margin: 0 0 22px 0;
}

/* Các trường nhập liệu */
.mrd-form-group {
  margin-bottom: 16px;
}

.mrd-form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #cbd5e1;
  margin-bottom: 6px;
}

.mrd-form-label span.req {
  color: #f43f5e;
}

.mrd-form-input,
.mrd-form-select,
.mrd-form-textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(203, 213, 225, 0.25);
  border-radius: 8px;
  color: #ffffff;
  font-size: 14px;
  font-family: inherit;
  transition: all 0.2s ease;
  outline: none;
}

.mrd-form-input::placeholder,
.mrd-form-textarea::placeholder {
  color: #64748b;
}

.mrd-form-input:focus,
.mrd-form-select:focus,
.mrd-form-textarea:focus {
  border-color: #009fe3;
  background: rgba(15, 23, 42, 0.9);
  box-shadow: 0 0 0 3px rgba(0, 159, 227, 0.25);
}

.mrd-form-select {
  cursor: pointer;
}

.mrd-form-select option {
  background: #0f172a;
  color: #ffffff;
}

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

/* Nút Submit */
.mrd-form-submit-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 20px;
  background: linear-gradient(135deg, #009fe3 0%, #0077b6 100%);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-size: 14.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 6px 20px rgba(0, 159, 227, 0.4);
  margin-top: 6px;
}

.mrd-form-submit-btn:hover {
  background: linear-gradient(135deg, #008cd0 0%, #006097 100%);
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 159, 227, 0.55);
}

.mrd-form-submit-btn:active {
  transform: translateY(0);
}

.mrd-form-submit-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  transition: transform 0.2s ease;
}

.mrd-form-submit-btn:hover svg {
  transform: translateX(3px);
}

/* Ghi chú bảo mật & hotline */
.mrd-form-footer-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 12px;
  color: #94a3b8;
  text-align: center;
}

.mrd-form-footer-note svg {
  width: 14px;
  height: 14px;
  fill: #38bdf8;
  flex-shrink: 0;
}

/* Trạng thái gửi thành công (Success state) */
.mrd-form-success-state {
  display: none;
  text-align: center;
  padding: 30px 10px;
}

.mrd-form-success-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.15);
  border: 2px solid #22c55e;
  color: #22c55e;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px auto;
}

.mrd-form-success-icon svg {
  width: 32px;
  height: 32px;
  fill: currentColor;
}

.mrd-form-success-title {
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 8px 0;
}

.mrd-form-success-desc {
  font-size: 14px;
  color: #94a3b8;
  line-height: 1.6;
  margin: 0 0 20px 0;
}

.mrd-form-reset-btn {
  padding: 8px 18px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.mrd-form-reset-btn:hover {
  background: rgba(0, 159, 227, 0.2);
  border-color: #009fe3;
  color: #38bdf8;
}

/* --------------------------------------------------------------------------
   RESPONSIVE DESIGN
   -------------------------------------------------------------------------- */
@media (max-width: 991px) {
  .mrd-faq-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .mrd-faq-right {
    position: static;
  }
}

@media (max-width: 640px) {
  .mrd-faq-wrapper {
    padding: 60px 0 70px 0;
  }

  .mrd-faq-title {
    font-size: 26px;
  }

  .mrd-faq-question {
    font-size: 14px;
    padding: 14px 16px;
  }

  .mrd-faq-answer-inner {
    padding: 14px 16px 18px 16px;
    font-size: 13.5px;
  }

  .mrd-faq-form-card {
    padding: 24px 18px;
  }
}
