/* Contact Page Custom Layout CSS (Warm Tech Minimal) */

.contact-main {
  max-width: 860px;
  margin: 0 auto;
  padding: 32px 24px;
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: 28px;
  align-items: start;
}
@media (max-width: 768px) {
  .contact-main      { grid-template-columns: 1fr; padding: 24px 16px; gap: 20px; }
  .contact-form-col  { order: 1; }
  .contact-info-col  { order: 2; position: static !important; }
}

/* Hero */
.contact-hero {
  padding: 40px 24px 32px;
  text-align: center;
  border-bottom: 1px solid var(--border-light);
}
.contact-hero h1 {
  font-size: var(--text-3xl);
  font-weight: 700;
  color: var(--text-primary);
  font-family: var(--font-heading);
  margin-bottom: 10px;
}
.contact-hero p {
  font-size: var(--text-base);
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
  max-width: 440px;
  margin: 0 auto;
}
@media (max-width: 768px) {
  .contact-hero { padding: 32px 16px 24px; }
}

/* Channel Cards */
.contact-info-col {
  position: sticky;
  top: 72px;
}
.col-section-label {
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.channel-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  margin-bottom: 8px;
  text-decoration: none;
  transition: border-color 0.15s, transform 0.15s;
}
.channel-card:hover {
  border-color: var(--border-medium);
  transform: translateX(3px);
}
/* Border-left màu riêng từng kênh */
.channel-card.ch-zalo     { border-left: 3px solid #0068FF; }
.channel-card.ch-facebook { border-left: 3px solid #1877F2; }
.channel-card.ch-email    { border-left: 3px solid var(--accent-primary); }

/* Icon wrap */
.ch-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
}
.ch-zalo     .ch-icon-wrap { background: #EFF6FF; color: #0068FF; }
.ch-facebook .ch-icon-wrap { background: #EFF6FF; color: #1877F2; }
.ch-email    .ch-icon-wrap { background: var(--accent-primary-light); color: var(--accent-primary); }

.ch-body { flex: 1; min-width: 0; }
.ch-name {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}
.ch-handle {
  font-size: var(--text-xs);
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 4px;
}
.ch-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  padding: 1px 8px;
  border-radius: var(--radius-full);
}
.badge-fast   { background: var(--color-success-bg); color: var(--color-success); }
.badge-normal { background: var(--bg-elevated);      color: var(--text-muted); }
.ch-arrow { color: var(--text-muted); font-size: 14px; flex-shrink: 0; }

/* Giờ làm việc */
.hours-box {
  margin-top: 16px;
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}
.hours-header {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
}
.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-success);
  animation: pulse-blink 2s ease-in-out infinite;
}
@keyframes pulse-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.3; }
}
.hours-header span {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
}
.hours-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: var(--text-xs);
}
.hours-row:last-child { border-bottom: none; }
.hours-row .lbl { color: var(--text-muted); }
.hours-row .val { font-weight: 600; color: var(--text-primary); }
.hours-row .val.urgent { color: var(--accent-primary); }

/* Guide Collapse */
.response-guide {
  margin-top: 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.guide-toggle {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 14px;
  background: none;
  border: none;
  margin: 0 !important;
  min-height: 0 !important;
  box-shadow: none !important;
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
  text-align: left;
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  font-family: var(--font-body);
}
.guide-toggle:hover { background: var(--bg-elevated); }
.guide-chevron {
  font-size: 13px;
  color: var(--text-muted);
  transition: transform 0.2s;
}
.response-guide.is-open .guide-chevron { transform: rotate(180deg); }
.guide-body {
  max-height: 0;
  overflow: hidden;
  padding: 0 14px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.7;
}
.response-guide.is-open .guide-body {
  max-height: 360px;
  padding: 0 14px 14px;
}
.guide-body strong {
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  margin: 10px 0 4px;
}
.guide-body strong:first-child { margin-top: 0; }
.guide-body ol { padding-left: 16px; }
.guide-body li { margin-bottom: 3px; }

/* Contact Form Card */
.contact-form-col {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 28px 32px;
  box-shadow: var(--shadow-sm);
}
@media (max-width: 768px) {
  .contact-form-col { padding: 20px; }
}
.form-title {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.form-sub {
  font-size: var(--text-sm);
  color: var(--text-muted);
  margin-bottom: 22px;
}
.cf7-field { margin-bottom: 16px; }
.cf7-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 480px) {
  .cf7-row { grid-template-columns: 1fr; }
}

/* Fix CF7 Auto Paragraph & Line Break Spacing */
.wpcf7 p,
.wpcf7-form p {
  margin: 0 !important;
  padding: 0 !important;
}
.wpcf7 br,
.wpcf7-form br {
  display: none !important;
}
.wpcf7-form-control-wrap {
  display: block;
}

/* === CF7 Input Override === */
.wpcf7 label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 5px;
  font-family: var(--font-body);
}
.req { color: var(--color-error); margin-left: 2px; }
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 select,
.wpcf7 textarea {
  width: 100%;
  padding: 9px 13px;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-md);
  background: var(--bg-base);
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-family: var(--font-body);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  box-sizing: border-box;
  -webkit-appearance: none;
}
.wpcf7 input::placeholder,
.wpcf7 textarea::placeholder { color: var(--text-muted); }
.wpcf7 input:focus,
.wpcf7 select:focus,
.wpcf7 textarea:focus {
  border-color: var(--accent-primary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px rgba(224,90,43,0.1);
}
.wpcf7 select {
  height: auto !important;
  line-height: 1.4 !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%239A9A9A' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  padding-right: 34px;
  cursor: pointer;
}
.wpcf7 textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.6;
}

/* Submit button */
.wpcf7 input[type="submit"] {
  width: 100%;
  padding: 12px 24px;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  font-weight: 700;
  font-family: var(--font-body);
  cursor: pointer;
  transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
  margin-top: 6px;
}
.wpcf7 input[type="submit"]:hover {
  background: var(--accent-primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-accent);
}
.wpcf7 input[type="submit"]:active { transform: translateY(0); }
.wpcf7.submitting input[type="submit"] { opacity: 0.7; cursor: wait; }

/* Validation messages */
.wpcf7 .wpcf7-not-valid-tip {
  font-size: var(--text-xs);
  color: var(--color-error);
  margin-top: 4px;
  display: block;
}
.wpcf7 input.wpcf7-not-valid,
.wpcf7 textarea.wpcf7-not-valid,
.wpcf7 select.wpcf7-not-valid {
  border-color: var(--color-error);
  background: var(--color-error-bg);
}

/* Response output */
.wpcf7 .wpcf7-response-output {
  margin-top: 16px;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  border: none !important;
}
.wpcf7.sent .wpcf7-response-output {
  background: var(--color-success-bg);
  color: var(--color-success);
  border-left: 3px solid var(--color-success) !important;
}
.wpcf7.failed .wpcf7-response-output,
.wpcf7.spam  .wpcf7-response-output {
  background: var(--color-error-bg);
  color: var(--color-error);
  border-left: 3px solid var(--color-error) !important;
}

/* Note dưới form */
.form-note {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin-top: 14px;
  padding: 11px 14px;
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.6;
}

/* FAQ */
.contact-faq {
  max-width: 860px;
  margin: 0 auto;
  padding: 32px 24px 48px;
  border-top: 1px solid var(--border-light);
}
@media (max-width: 768px) {
  .contact-faq { padding: 24px 16px 40px; }
}
.contact-faq-label {
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.faq-item {
  border: 1px solid var(--border-medium);
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  margin-bottom: 8px;
  overflow: hidden;
}
.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 16px;
  background: none;
  border: none;
  margin: 0 !important;
  min-height: 0 !important;
  box-shadow: none !important;
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-primary);
  text-align: left;
  font-family: var(--font-body);
  gap: 12px;
}
.faq-question:hover { background: var(--bg-elevated); }
.faq-item.is-open .faq-question {
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-light);
}
.faq-icon {
  font-size: 13px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 0.2s;
}
.faq-item.is-open .faq-icon { transform: rotate(45deg); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 16px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
}
.faq-item.is-open .faq-answer { 
  max-height: 160px; 
  padding: 12px 16px 16px; 
  background: var(--bg-surface);
}

/* Service Pages CTA Grid Layout */
.cta-final {
  text-align: left !important;
}
.cta-final .cta-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}
.cta-final .cta-content-col {
  text-align: left;
}
.cta-final .cta-content-col h2 {
  margin-bottom: 16px !important;
}
.cta-final .cta-content-col p {
  margin: 0 0 28px 0 !important;
}
.cta-final .cta-btn-wrap {
  margin-bottom: 28px;
}
.cta-final .cta-contact-info {
  justify-content: flex-start;
  margin-top: 0;
}
.cta-final .contact-form-col {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 28px 32px;
  box-shadow: var(--shadow-lg);
  color: var(--text-primary);
  text-align: left;
}
.cta-final .contact-form-col h3.form-title {
  color: var(--text-primary);
  margin-top: 0;
  margin-bottom: 4px;
}
.cta-final .contact-form-col p.form-sub {
  color: var(--text-muted);
  margin-bottom: 22px;
}
@media (max-width: 991px) {
  .cta-final .cta-container {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .cta-final .cta-content-col {
    text-align: center;
  }
  .cta-final .cta-content-col p {
    margin: 0 auto 28px auto !important;
  }
  .cta-final .cta-contact-info {
    justify-content: center;
  }
}

