/* ==========================================================================
   Home — direction A (2026-09-17). Template: templates_v2/core/index.html.
   Everything under .ui2 .hm; tokens and components come from ui-kit.css.
   ========================================================================== */

.ui2 .hm-messages { padding-top: 16px; }

/* ------------------------------------------------------------------ hero */
.ui2 .hm-hero { padding: 96px 0 64px; text-align: center; }
.ui2 .hm-title { margin-top: 12px; }
.ui2 .hm-lede { margin: 16px auto 0; max-width: 760px; }

.ui2 .hm-ask {
  position: relative;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  width: min(680px, 100%);
  min-height: 60px;
  margin: 36px auto 0;
  padding: 9px 9px 9px 22px;
  border: 1px solid var(--hair);
  border-radius: 30px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
  text-align: left;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.ui2 .hm-ask:hover { border-color: #b9b9bf; }
.ui2 .hm-ask:focus-within { border-color: rgba(139, 0, 0, 0.45); box-shadow: 0 0 0 4px rgba(139, 0, 0, 0.08), 0 10px 30px rgba(0, 0, 0, 0.06); }
.ui2 .hm-ask-ic { align-self: center; width: 20px; height: 20px; color: var(--brand); margin-bottom: 0; }
.ui2 .hm-ask-box { position: relative; flex: 1; min-width: 0; align-self: center; }
.ui2 .hm-ask-input {
  display: block;
  width: 100%;
  min-height: 26px;
  max-height: 240px;
  margin: 0;
  padding: 3px 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.2px;
  resize: none;
  overflow-y: auto;
  box-shadow: none;
}
/* The typed placeholder overlays the field; style.css positions it for the old
   hero, so every geometry property is restated here. */
.ui2 .hm .hm-ask-ph {
  position: absolute;
  top: 3px;
  left: 0;
  right: 0;
  color: var(--ink3);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
  pointer-events: none;
}
.ui2 .hm-ask-go { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border: 0; border-radius: 50%; background: var(--brand); color: #fff; cursor: pointer; transition: background-color 0.2s; }
.ui2 .hm-ask-go:hover { background: var(--brand-hover); }
.ui2 .hm-ask-go .ui-ic { width: 20px; height: 20px; stroke-width: 2.3; }

.ui2 .hm-hint { display: none; align-items: center; justify-content: center; gap: 10px; width: min(680px, 100%); margin: 10px auto 0; }
.ui2 .hm-hint.is-on { display: flex; }
.ui2 .hm-hint-bar { position: relative; flex: none; width: 72px; height: 4px; overflow: hidden; border-radius: 2px; background: var(--fill2); }
.ui2 .hm-hint-fill { width: 0; height: 100%; border-radius: 2px; background: var(--warn); transition: width 0.2s ease, background-color 0.2s ease; }
.ui2 .hm-hint-bar[data-level="mid"] .hm-hint-fill { background: var(--ink3); }
.ui2 .hm-hint-bar[data-level="good"] .hm-hint-fill { background: var(--ok); }
.ui2 .hm-hint-label { font-size: 13px; line-height: 1.35; color: var(--ink2); text-align: left; }
.ui2 .hm-hint-bar[data-level="good"] + .hm-hint-label { color: var(--ok-ink); }

.ui2 .hm-continue { margin-top: 14px; }
.ui2 .hm-continue[hidden] { display: none; }

.ui2 .hm-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 760px; margin: 22px auto 0; }
.ui2 .hm .ai-chat-scenario-btn { margin: 0; border: 0; box-shadow: none; font-weight: 400; }
.ui2 .hm-legal { margin-top: 18px; text-wrap: balance; }
.ui2 .hm-legal a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.ui2 .hm-legal a:hover { color: var(--ink2); }

/* ----------------------------------------------------------------- tiles */
.ui2 .hm-tiles { padding: 12px 0; }
.ui2 .hm-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.ui2 .hm-tile { display: flex; flex-direction: column; align-items: center; min-height: 440px; padding: 52px 40px 0; }
.ui2 .hm-wide { grid-column: 1 / -1; min-height: 420px; }
.ui2 .hm-tile-sub { margin: 8px auto 0; max-width: 480px; }
.ui2 .hm-wide .hm-tile-sub { max-width: 760px; }
.ui2 .hm-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 28px; margin: 14px 0 0; }

/* lawyers fan */
.ui2 .hm-fan { position: relative; display: flex; justify-content: center; align-items: flex-start; gap: 0; width: min(860px, 100%); margin: auto 0 48px; padding: 36px 0 0; list-style: none; }
.ui2 .hm-mc { width: 290px; flex: none; }
.ui2 .hm-mc:nth-child(1) { transform: translate(18px, 22px) rotate(-4deg); }
.ui2 .hm-mc:nth-child(2) { position: relative; z-index: 2; }
.ui2 .hm-mc:nth-child(3) { transform: translate(-18px, 22px) rotate(4deg); }
.ui2 .hm-mc-in { display: block; padding: 16px 18px; border-radius: 16px; background: #fff; color: var(--ink); text-align: left; text-decoration: none; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.05); transition: box-shadow 0.2s, transform 0.2s; }
.ui2 .hm-mc-in:hover { color: var(--ink); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.06); transform: translateY(-2px); }
.ui2 .hm-mc-top { display: flex; align-items: center; gap: 12px; }
.ui2 .hm-mc-who { min-width: 0; }
.ui2 .hm-mc-n { display: block; overflow: hidden; font-size: 15px; font-weight: 600; line-height: 1.3; letter-spacing: -0.2px; white-space: nowrap; text-overflow: ellipsis; }
.ui2 .hm-mc-m { display: block; font-size: 13px; line-height: 1.35; color: var(--ink2); }
.ui2 .hm-mc-b { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--fill2); font-size: 13px; }
.ui2 .hm-mc-rate { font-size: 13px; }
.ui2 .hm-mc-rate .ui-ic { width: 12px; height: 12px; }
.ui2 .hm-mc-price { font-size: 15px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* documents paper */
.ui2 .hm-paper { width: 280px; height: 230px; flex: none; margin: auto 0 0; padding: 28px 26px; border-radius: 12px 12px 0 0; background: #fff; text-align: left; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.05); }
.ui2 .hm-paper-t { margin: 0; font-size: 15px; font-weight: 600; text-align: center; }
.ui2 .hm-paper-r { display: flex; justify-content: space-between; margin: 16px 0 18px; }
.ui2 .hm-blank { padding: 2px 6px; border-radius: 5px; background: rgba(139, 0, 0, 0.1); color: var(--brand); font-size: 12px; white-space: nowrap; }
.ui2 .hm-bars { display: flex; flex-direction: column; gap: 9px; }
.ui2 .hm-bars i { display: block; height: 6px; border-radius: 3px; background: var(--fill2); }
.ui2 .hm-bars i:nth-child(3n) { width: 86%; }
.ui2 .hm-bars i:nth-child(4n) { width: 64%; }

/* counterparty example */
.ui2 .hm-report { width: min(480px, 100%); margin: auto 0 36px; padding: 12px 20px 8px; border-radius: 16px; background: #fff; text-align: left; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.05); }
.ui2 .hm-report figcaption { margin-bottom: 2px; }
.ui2 .hm-report dl { margin: 0; }
.ui2 .hm-report dl > div { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 46px; }
.ui2 .hm-report dl > div + div { border-top: 1px solid var(--fill2); }
.ui2 .hm-report dt { font-size: 14px; font-weight: 400; color: var(--ink); }
.ui2 .hm-report dd { margin: 0; flex: none; }

/* laws */
.ui2 .hm-laws { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; width: min(480px, 100%); margin: auto 0 64px; text-align: left; }
.ui2 .hm-laws dt { font-size: 28px; line-height: 1.15; font-weight: 600; letter-spacing: -0.022em; font-variant-numeric: tabular-nums; }
.ui2 .hm-laws dd { display: flex; align-items: center; gap: 6px; margin: 4px 0 0; font-size: 13px; color: var(--ink2); }
.ui2 .hm-dot { width: 8px; height: 8px; flex: none; border-radius: 50%; }
.ui2 .hm-dot.ok { background: var(--ok); }
.ui2 .hm-dot.void { background: #c7c7cc; }
.ui2 .hm-dot.pend { background: var(--warn); }

/* questions */
.ui2 .hm-qs { width: min(480px, 100%); margin: auto 0 44px; padding: 4px 20px; border-radius: 16px; background: #fff; text-align: left; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.05); }
.ui2 .hm-qs a { display: block; padding: 14px 0; color: var(--ink); text-decoration: none; }
.ui2 .hm-qs a:hover b { color: var(--brand); }
.ui2 .hm-qs b { display: block; font-size: 15px; font-weight: 600; line-height: 1.35; letter-spacing: -0.2px; }
.ui2 .hm-qs span { display: block; margin-top: 3px; font-size: 13px; color: var(--ink2); }

/* ------------------------------------------------------------ specialties */
.ui2 .hm-specs { padding: 88px 0 24px; }
.ui2 .hm-specs .ui-h3 { text-align: center; }
.ui2 .hm-spec-cols { columns: 3 260px; column-gap: 48px; margin-top: 40px; }
.ui2 .hm-spec { display: grid; grid-template-columns: 28px minmax(0, 1fr); column-gap: 12px; break-inside: avoid; padding: 0 0 22px; }
.ui2 .hm-spec-l { margin: 0; font-size: 17px; font-weight: 600; line-height: 1.6; color: var(--ink3); }
.ui2 .hm-spec-list { margin: 0; padding: 0; list-style: none; }
.ui2 .hm-spec-list li { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 3px 0; }
.ui2 .hm-spec-list a { color: var(--ink); font-size: 15px; line-height: 1.45; text-decoration: none; }
.ui2 .hm-spec-list a:hover { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.ui2 .hm-spec-n { flex: none; font-size: 13px; color: var(--ink3); font-variant-numeric: tabular-nums; }

/* -------------------------------------------------------------------- FAQ */
.ui2 .hm-faq { padding: 64px 0 88px; }
.ui2 .hm-faq-in { max-width: 820px; }
.ui2 .hm-faq .ui-h3 { text-align: center; }
.ui2 .hm-faq-list { margin-top: 32px; border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair); }
.ui2 .hm-faq details > summary { position: relative; display: block; padding: 20px 40px 20px 0; font-size: 17px; font-weight: 600; letter-spacing: -0.2px; cursor: pointer; list-style: none; }
.ui2 .hm-faq details > summary::-webkit-details-marker { display: none; }
.ui2 .hm-faq details > summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 9px; height: 9px; margin-top: -7px; border: solid var(--ink2); border-width: 0 1.8px 1.8px 0; transform: rotate(45deg); transition: transform 0.2s; }
.ui2 .hm-faq details[open] > summary::after { margin-top: -2px; transform: rotate(-135deg); }
.ui2 .hm-faq details > p { margin: -6px 0 22px; max-width: 700px; font-size: 17px; line-height: 1.47; color: var(--ink2); }

/* ------------------------------------------------------------ for lawyers */
.ui2 .hm-pro { padding: 96px 0; text-align: center; }
.ui2 .hm-pro-sub { margin: 12px auto 28px; max-width: 640px; }

/* ----------------------------------------------------------------- tablet */
@media (max-width: 1067.98px) {
  .ui2 .hm-fan { width: 100%; }
  .ui2 .hm-mc { width: 260px; }
}

/* ------------------------------------------------------------------ phone */
@media (max-width: 733.98px) {
  .ui2 .hm-hero { padding: 40px 0 36px; }
  .ui2 .hm-ask { margin-top: 24px; min-height: 52px; padding: 6px 6px 6px 16px; border-radius: 26px; }
  .ui2 .hm-ask-ic { display: none; }
  .ui2 .hm-ask-input, .ui2 .hm .hm-ask-ph { font-size: 17px; }
  .ui2 .hm-chips { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; scrollbar-width: none; margin: 18px calc(-1 * var(--ui-gutter)) 0; padding: 0 var(--ui-gutter); }
  .ui2 .hm-chips::-webkit-scrollbar { display: none; }
  .ui2 .hm-chips > * { flex: none; }

  .ui2 .hm-tiles { padding: 8px 0; }
  .ui2 .hm-grid { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .ui2 .hm-grid { width: calc(100% - 16px); }
  .ui2 .hm-tile, .ui2 .hm-wide { min-height: 0; padding: 36px 20px 0; }
  .ui2 .hm-links { gap: 6px 20px; }
  .ui2 .hm-fan { flex-direction: column; align-items: stretch; gap: 8px; margin: 24px 0 20px; padding: 0; }
  .ui2 .hm-mc { width: auto; transform: none !important; }
  .ui2 .hm-paper { width: 240px; height: 180px; margin-top: 28px; }
  .ui2 .hm-report, .ui2 .hm-qs { margin: 24px 0 20px; }
  .ui2 .hm-report dl > div { flex-direction: column; align-items: flex-start; gap: 4px; padding: 10px 0; }
  .ui2 .hm-laws { margin: 24px 0 36px; gap: 10px; }
  .ui2 .hm-laws dt { font-size: 22px; }
  .ui2 .hm-laws dd { align-items: flex-start; font-size: 12px; }
  .ui2 .hm-laws .hm-dot { margin-top: 4px; }

  .ui2 .hm-specs { padding: 48px 0 8px; }
  .ui2 .hm-specs .ui-h3, .ui2 .hm-faq .ui-h3 { text-align: left; }
  .ui2 .hm-spec-cols { columns: 1; margin-top: 24px; }
  .ui2 .hm-faq { padding: 40px 0 56px; }
  .ui2 .hm-faq-list { margin-top: 16px; }
  .ui2 .hm-pro { padding: 56px 0; }
}
