/* ==========================================================================
   Lộc Phát — Trang Liên hệ (template-lien-he.php)

   MOBILE-FIRST. Base = mobile; @media (min-width:860px) = desktop.
   Chỉ nạp trên trang dùng template này (xem lp_enqueue trong functions.php).
   Tokens & .btn/.badge/.crumb-wrap lấy từ theme.css — không khai báo lại ở đây.
   ========================================================================== */

/* ---- Hero -------------------------------------------------------------- */
.ct-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(120deg, var(--gray-900) 0%, var(--blue-900) 100%);
}
.ct-hero__lines {
  position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(45deg, rgba(255,255,255,.035) 0 12px, transparent 12px 24px);
}
.ct-hero__inner {
  position: relative;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 28px 14px 30px;
}
.ct-hero h1 {
  color: #fff;
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-tight);
  margin-top: 12px;
}
.ct-hero p {
  color: rgba(255,255,255,.78);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  margin-top: 10px;
}
.ct-hero__chips { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 20px; }
.ct-hero__chips span {
  display: inline-flex; align-items: center; gap: 6px;
  color: rgba(255,255,255,.82); font-size: var(--text-xs); font-weight: var(--weight-medium);
}
.ct-hero__chips i { color: var(--red-400); }

/* ---- Khung section chung ----------------------------------------------- */
.ct-main { max-width: var(--container-max); margin: 0 auto; padding: 28px 14px; }

.ct-grid { display: grid; gap: 16px; }
/* Cột trái: thẻ thông tin rồi tới bản đồ, xếp dọc. Bản đồ nhận phần chiều cao
   còn thừa (flex:1) nên trên desktop cột trái luôn cao bằng cột form — không phải
   canh tay số, và vẫn đúng khi thêm/bớt dòng thông tin. */
.ct-info { display: flex; flex-direction: column; gap: 16px; height: 100%; }

/* ---- Thẻ thông tin ----------------------------------------------------- */
.ct-card {
  background: var(--surface-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 18px 16px;
}
/* Tên công ty — tiêu đề của thẻ thông tin. */
.ct-card__org {
  display: flex; align-items: center; gap: 11px;
  padding-bottom: 14px; margin-bottom: 16px;
  border-bottom: 1px solid var(--border-default);
  font-family: var(--font-display); font-size: var(--text-md);
  font-weight: var(--weight-bold); color: var(--text-primary);
  line-height: var(--leading-snug);
}
.ct-card__org-icon {
  flex: none; width: 36px; height: 36px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  background: var(--surface-primary-subtle); color: var(--color-primary); font-size: 15px;
}

/* Hai nút liên hệ đứng đầu thẻ — nơi DUY NHẤT hiện hotline/Zalo trên trang này. */
.ct-actions { display: grid; gap: 10px; padding-bottom: 16px; border-bottom: 1px solid var(--border-default); }
.ct-action {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: var(--radius-md);
  border: 1px solid var(--border-default); background: var(--surface-card);
  transition: border-color var(--duration-fast) var(--ease-standard),
              box-shadow var(--duration-fast) var(--ease-standard);
}
.ct-action:hover { box-shadow: var(--shadow-sm); }
.ct-action--phone { background: var(--surface-accent-subtle); border-color: var(--red-200); }
.ct-action--phone:hover { border-color: var(--color-accent); }
.ct-action--zalo { background: var(--surface-primary-subtle); border-color: var(--blue-200); }
.ct-action--zalo:hover { border-color: var(--color-primary); }
.ct-action__icon {
  flex: none; width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--color-accent); color: #fff; font-size: 16px;
}
.ct-action__icon--zalo {
  background: #0068ff; border-radius: var(--radius-md);
  font-size: 18px; font-weight: var(--weight-extrabold); font-style: italic;
}
.ct-action__meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ct-action__meta .k { font-size: var(--text-xs); color: var(--text-secondary); }
.ct-action__meta .v {
  font-family: var(--font-display); font-size: var(--text-lg);
  font-weight: var(--weight-bold); color: var(--text-primary); line-height: var(--leading-snug);
}
.ct-action--zalo .ct-action__meta .v { font-size: var(--text-md); }

.ct-row { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px dashed var(--border-default); }
.ct-row:last-child { border-bottom: 0; padding-bottom: 0; }
.ct-row__icon {
  flex: none; width: 36px; height: 36px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  background: var(--surface-primary-subtle); color: var(--color-primary); font-size: 15px;
}
.ct-row__body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ct-row__k {
  font-size: var(--text-xs); color: var(--text-tertiary);
  text-transform: uppercase; letter-spacing: var(--tracking-wide); font-weight: var(--weight-semibold);
}
.ct-row__v { font-size: var(--text-base); color: var(--text-primary); font-weight: var(--weight-semibold); line-height: var(--leading-snug); }
.ct-row__v--link { color: var(--color-accent); font-size: var(--text-lg); font-family: var(--font-display); }
.ct-row__v--link:hover { color: var(--color-accent-hover); }
.ct-row__sub { font-size: var(--text-xs); color: var(--text-secondary); }

/* ---- Thẻ form ---------------------------------------------------------- */
.ct-form-card {
  background: var(--surface-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.ct-form-card__head {
  position: relative; overflow: hidden;
  display: flex; align-items: center; gap: 13px; padding: 16px;
  background: linear-gradient(120deg, var(--gray-900) 0%, var(--blue-900) 100%);
}
.ct-form-card__head::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(45deg, rgba(255,255,255,.04) 0 10px, transparent 10px 20px);
}
.ct-form-card__head > * { position: relative; }
.ct-form-card__icon {
  flex: none; width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--color-accent); color: #fff; font-size: 19px; box-shadow: var(--shadow-sm);
}
.ct-form-card__t {
  font-family: var(--font-display); font-size: var(--text-md); font-weight: var(--weight-extrabold);
  color: #fff; text-transform: uppercase; line-height: var(--leading-snug); letter-spacing: -.005em;
}
.ct-form-card__badges { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 6px; }
.ct-form-card__badges span { display: inline-flex; align-items: center; gap: 5px; font-size: var(--text-xs); font-weight: var(--weight-semibold); color: rgba(255,255,255,.9); }
.ct-form-card__badges .free i { color: var(--color-accent); }
.ct-form-card__badges .fast i { color: #fff; }
.ct-form-card__body { padding: 16px; }
.ct-form-fallback { font-size: var(--text-base); color: var(--text-secondary); line-height: var(--leading-relaxed); }

/* Nhãn field trong form CF7 ở trang này (markup .lp-cf7 nằm trong nội dung form). */
.ct-form-card .lp-cf7 { gap: 12px; }
.ct-form-card .lp-cf7 .field__label {
  display: block; margin-bottom: 5px;
  font-size: var(--text-xs); font-weight: var(--weight-semibold); color: var(--text-secondary);
  text-transform: uppercase; letter-spacing: var(--tracking-wide);
}
.ct-form-card .lp-cf7 .field__label .req { color: var(--color-accent); }
.ct-form-card .lp-cf7 .field--half { flex: 1; }
.ct-form-card .lp-cf7 .field-row { display: flex; flex-direction: column; gap: 12px; }
.ct-form-card .lp-cf7 textarea { min-height: 96px; }
.ct-form-card .lp-cf7 .form-note { font-size: var(--text-xs); color: var(--text-tertiary); line-height: var(--leading-normal); }

/* ---- Nội dung soạn thêm trong editor ----------------------------------- */
.ct-body { max-width: 820px; margin: 0 auto; padding: 0 14px 28px; }

/* ---- Bản đồ ------------------------------------------------------------ */
.ct-map {
  flex: 1;
  display: flex; flex-direction: column;
  background: var(--surface-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.ct-map__frame { position: relative; flex: 1; min-height: 240px; background: var(--surface-sunken); }
.ct-map__frame iframe { display: block; width: 100%; height: 100%; border: 0; }
.ct-map__load {
  width: 100%; height: 100%; border: 0; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  font-family: var(--font-body);
  background:
    linear-gradient(rgba(246,248,249,.86), rgba(246,248,249,.86)),
    repeating-linear-gradient(45deg, var(--gray-200) 0 14px, var(--gray-100) 14px 28px);
  transition: background-color var(--duration-fast) var(--ease-standard);
}
.ct-map__load:hover { background: linear-gradient(rgba(228,240,251,.9), rgba(228,240,251,.9)), repeating-linear-gradient(45deg, var(--gray-200) 0 14px, var(--gray-100) 14px 28px); }
.ct-map__load:focus-visible { outline: none; box-shadow: inset 0 0 0 3px rgba(28,116,199,.3); }
.ct-map__pin {
  width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--color-primary); color: #fff; font-size: 19px; box-shadow: var(--shadow-sm);
}
.ct-map__load-t { font-size: var(--text-base); font-weight: var(--weight-bold); color: var(--text-primary); }
.ct-map__load-s { font-size: var(--text-xs); color: var(--text-tertiary); }

.ct-map__dir {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  padding: 13px 16px; border-top: 1px solid var(--border-default);
  font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--color-primary);
}
.ct-map__dir:hover { background: var(--surface-primary-subtle); color: var(--color-primary-hover); }

/* ==========================================================================
   DESKTOP
   ========================================================================== */
@media (min-width: 860px) {
  .ct-hero__inner { padding: 44px 32px 48px; }
  .ct-hero h1 { font-size: var(--text-3xl); }
  .ct-hero p { font-size: var(--text-md); }
  .ct-hero__chips { gap: 10px 26px; margin-top: 26px; }
  .ct-hero__chips span { font-size: var(--text-sm); }

  .ct-main { padding: 44px 32px; }
  /* Thông tin bên trái, form bên phải — form hẹp hơn để dòng nhập không quá dài. */
  .ct-grid { grid-template-columns: 1fr 460px; gap: 28px; align-items: stretch; }
  .ct-info { gap: 20px; }

  .ct-card { padding: 24px 22px; }
  .ct-card__org { font-size: var(--text-lg); padding-bottom: 16px; margin-bottom: 18px; }
  .ct-row { padding: 16px 0; }
  .ct-row__icon { width: 40px; height: 40px; font-size: 16px; }
  .ct-row__v--link { font-size: var(--text-xl); }

  .ct-form-card__head { padding: 20px; }
  .ct-form-card__body { padding: 20px; }
  /* Họ tên + SĐT đứng cạnh nhau khi đủ rộng. */
  .ct-form-card .lp-cf7 .field-row { flex-direction: row; }

  .ct-body { padding-bottom: 40px; }

  /* Hai nút liên hệ nằm cạnh nhau khi đủ rộng. */
  .ct-actions { grid-template-columns: 1fr 1fr; gap: 12px; padding-bottom: 18px; }

  .ct-map__frame { min-height: 300px; }
}
