/* Standalone licence-matcher styles. Every selector is scoped to lm- classes. */
.lm-shell {
  --lm-navy: #072b46;
  --lm-navy-deep: #031b2d;
  --lm-copper: #b9793f;
  --lm-copper-light: #e8c08d;
  --lm-ink: #132332;
  --lm-paper: #ffffff;
  --lm-mist: #eef3f5;
  --lm-line: #c7d4dc;
  --lm-danger: #9a3c2e;
  color: var(--lm-ink);
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  min-width: 0;
  overflow-wrap: anywhere;
}
.lm-shell *,
.lm-shell *::before,
.lm-shell *::after {
  box-sizing: border-box;
}
.lm-shell [hidden] {
  display: none !important;
}
.lm-shell a,
.lm-shell button,
.lm-shell input {
  font: inherit;
}
.lm-shell button,
.lm-shell input {
  font-size: 16px;
}
.lm-wrap {
  width: min(100% - 32px, 1080px);
  margin: 0 auto;
  min-width: 0;
}
.lm-hero {
  background: linear-gradient(
    125deg,
    var(--lm-navy-deep),
    var(--lm-navy) 68%,
    #154b6a
  );
  color: var(--lm-paper);
  padding: clamp(32px, 6vw, 70px) 0;
}
.lm-kicker {
  color: var(--lm-copper-light);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  margin: 0 0 12px;
  text-transform: uppercase;
}
.lm-hero h1,
.lm-tool-heading h2,
.lm-result-panel h2 {
  font-family: "Noto Serif SC", "Songti SC", serif;
  line-height: 1.25;
}
.lm-hero h1 {
  font-size: clamp(1.9rem, 5vw, 3.25rem);
  margin: 0;
  max-width: 15em;
}
.lm-hero-copy {
  color: #e8f0f4;
  font-size: clamp(1rem, 2vw, 1.12rem);
  margin: 18px 0 0;
  max-width: 58rem;
}
.lm-limit-strip {
  border-top: 1px solid rgba(232, 192, 141, 0.38);
  color: #e8edf0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  font-size: 0.9rem;
  margin-top: 22px;
  padding-top: 16px;
}
.lm-limit-strip span {
  min-width: 0;
}
.lm-tool {
  background: var(--lm-paper);
  border: 1px solid var(--lm-line);
  border-radius: 12px;
  box-shadow: 0 16px 42px rgba(3, 27, 45, 0.1);
  margin: clamp(24px, 5vw, 48px) auto;
  overflow: visible;
  padding: clamp(18px, 4vw, 38px);
}
.lm-tool-heading {
  border-bottom: 1px solid var(--lm-line);
  padding-bottom: 20px;
}
.lm-tool-heading h2 {
  color: var(--lm-navy);
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  margin: 0;
}
.lm-tool-heading p {
  margin: 10px 0 0;
  max-width: 65rem;
}
.lm-progress-shell {
  background: rgba(255, 255, 255, 0.97);
  margin: 18px -4px 20px;
  padding: 8px 4px;
  position: relative;
  top: auto;
  z-index: 2;
}
.lm-progress-track {
  background: #d9e2e7;
  border-radius: 99px;
  height: 4px;
  margin: 0 10px 10px;
  overflow: hidden;
}
.lm-progress-track span {
  background: linear-gradient(90deg, var(--lm-copper), #d9a366);
  border-radius: inherit;
  display: block;
  height: 100%;
  transform: scaleX(var(--lm-progress-value, 0));
  transform-origin: left center;
  transition: transform 0.22s ease;
}
.lm-progress {
  display: grid;
  gap: 6px;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}
.lm-progress li {
  align-items: center;
  color: #5f6d78;
  display: flex;
  font-size: 0.72rem;
  gap: 4px;
  justify-content: center;
  min-width: 0;
  text-align: center;
}
.lm-progress i {
  align-items: center;
  background: #d9e2e7;
  border-radius: 50%;
  color: var(--lm-navy);
  display: inline-flex;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 700;
  height: 25px;
  justify-content: center;
  line-height: 1;
  min-width: 25px;
}
.lm-progress b {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lm-progress .is-current {
  color: var(--lm-navy);
}
.lm-progress .is-current i {
  background: var(--lm-copper);
  color: #fff;
}
.lm-progress .is-complete i {
  background: var(--lm-navy);
  color: #fff;
}
.lm-step {
  border: 0;
  margin: 0;
  min-inline-size: 0;
  padding: 0;
}
.lm-step[data-lm-entering],
.lm-advanced-panel[data-lm-entering] {
  animation: lm-step-enter 0.2s ease-out both;
}
.lm-step legend {
  color: var(--lm-navy);
  font-size: clamp(1.22rem, 2.5vw, 1.65rem);
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 7px;
  max-width: 100%;
  padding: 0;
}
.lm-step-count {
  color: var(--lm-copper);
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 5px;
}
.lm-step-help {
  color: #52626f;
  font-size: 0.95rem;
  margin: 0 0 18px;
}
.lm-options {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.lm-choice {
  cursor: pointer;
  display: block;
  min-width: 0;
  position: relative;
}
.lm-choice input {
  block-size: 1px;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  inline-size: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
}
.lm-choice span {
  align-items: center;
  background: #fff;
  border: 1px solid var(--lm-line);
  border-radius: 9px;
  color: var(--lm-ink);
  display: flex;
  font-weight: 600;
  min-height: 54px;
  overflow: hidden;
  padding: 12px 14px 12px 42px;
  position: relative;
  transition:
    border-color 0.16s ease,
    background 0.16s ease,
    box-shadow 0.16s ease;
}
.lm-choice span::before {
  background: #fff;
  border: 2px solid #71808b;
  border-radius: 50%;
  content: "";
  height: 18px;
  left: 15px;
  position: absolute;
  top: calc(50% - 9px);
  width: 18px;
  z-index: 1;
}
.lm-choice span::after {
  background: rgba(185, 121, 63, 0.18);
  border-radius: 50%;
  content: "";
  height: 120px;
  left: 8px;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  top: calc(50% - 60px);
  transform: scale(0);
  width: 120px;
}
.lm-choice input:checked + span {
  background: #fff8ef;
  border-color: var(--lm-copper);
  box-shadow:
    inset 0 -3px 0 var(--lm-copper),
    inset 0 0 0 1px var(--lm-copper);
  color: var(--lm-navy);
}
.lm-choice input:checked + span::before {
  background: var(--lm-copper);
  border-color: var(--lm-copper);
  box-shadow: inset 0 0 0 4px #fff8ef;
}
.lm-choice input:checked + span::after {
  animation: lm-choice-ripple 0.22s ease-out both;
}
.lm-choice input:focus-visible + span {
  outline: 3px solid #d98b45;
  outline-offset: 3px;
}
.lm-advanced-panel {
  border-top: 1px solid var(--lm-line);
  margin-top: 12px;
  padding-top: 24px;
}
.lm-advanced-heading h3 {
  color: var(--lm-navy);
  font-family: "Noto Serif SC", "Songti SC", serif;
  font-size: clamp(1.22rem, 2.5vw, 1.65rem);
  line-height: 1.4;
  margin: 0;
}
.lm-advanced-heading p,
.lm-advanced-question > p {
  color: #52626f;
  font-size: 0.94rem;
  margin: 8px 0 14px;
}
.lm-advanced-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.lm-advanced-question {
  border: 1px solid var(--lm-line);
  border-radius: 9px;
  margin: 0;
  min-inline-size: 0;
  padding: 16px;
}
.lm-advanced-question legend {
  color: var(--lm-navy);
  font-size: 1rem;
  font-weight: 700;
  padding: 0 4px;
}
.lm-advanced-question .lm-options {
  grid-template-columns: 1fr;
}
.lm-advanced-question .lm-choice span {
  font-size: 0.92rem;
  min-height: 48px;
}
.lm-advanced-actions {
  align-items: center;
}
.lm-step-actions,
.lm-result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}
.lm-step-actions {
  justify-content: space-between;
}
.lm-button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  justify-content: center;
  line-height: 1.2;
  min-height: 44px;
  padding: 10px 16px;
  text-align: center;
  text-decoration: none;
}
.lm-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}
.lm-export-status {
  color: var(--lm-navy);
  font-size: 14px;
  line-height: 1.75;
  overflow-wrap: anywhere;
  margin: 16px 0 0;
}
.lm-export-status:empty {
  display: none;
}
.lm-button[aria-busy="true"] {
  cursor: progress;
}
.lm-button--primary {
  background: var(--lm-copper);
  color: #fff;
  font-weight: 700;
}
.lm-button--secondary {
  background: #fff;
  border-color: var(--lm-navy);
  color: var(--lm-navy);
  font-weight: 700;
}
.lm-button--text {
  background: transparent;
  color: var(--lm-navy);
  text-decoration: underline;
}
.lm-disclosure {
  background: var(--lm-mist);
  border-left: 4px solid var(--lm-copper);
  border-radius: 0 7px 7px 0;
  color: #334652;
  font-size: 0.92rem;
  margin-top: 22px;
  padding: 13px 16px;
}
.lm-result-panel {
  scroll-margin-top: 24px;
}
.lm-result-panel > h2 {
  color: var(--lm-navy);
  font-size: clamp(1.45rem, 3vw, 2rem);
  margin: 0 0 12px;
}
.lm-result-summary {
  background: var(--lm-navy);
  border-radius: 9px;
  color: #fff;
  font-weight: 600;
  margin: 0 0 18px;
  padding: 15px 17px;
}
.lm-answer-summary {
  border: 1px solid var(--lm-line);
  border-radius: 9px;
  margin: 18px 0;
  padding: 16px;
}
.lm-selected-conditions {
  border: 1px solid #d8b98f;
  border-radius: 9px;
  margin: 18px 0;
  padding: 16px;
}
.lm-selected-conditions h3 {
  color: var(--lm-navy);
  font-size: 1.08rem;
  margin: 0 0 10px;
}
.lm-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.lm-chip {
  align-items: center;
  background: #fff8ef;
  border: 1px solid #d8b98f;
  border-radius: 99px;
  color: var(--lm-ink);
  display: inline-flex;
  font-size: 0.88rem;
  gap: 6px;
  min-height: 36px;
  padding: 5px 11px;
}
.lm-chip-label {
  color: var(--lm-navy);
  font-weight: 700;
}
.lm-answer-summary h3,
.lm-alert h3,
.lm-next-steps h3,
.lm-candidate-heading {
  color: var(--lm-navy);
  font-size: 1.08rem;
  margin: 0 0 10px;
}
.lm-answer-grid {
  display: grid;
  gap: 6px 16px;
  grid-template-columns: minmax(8em, 0.8fr) minmax(0, 2fr);
  margin: 0;
}
.lm-answer-grid dt {
  color: #53636e;
  font-weight: 700;
}
.lm-answer-grid dd {
  margin: 0;
  min-width: 0;
}
.lm-alert {
  background: #f3f7f8;
  border: 1px solid var(--lm-line);
  border-radius: 9px;
  margin: 16px 0;
  padding: 16px;
}
.lm-alert--clarify {
  background: #fff7ed;
  border-color: #d89d61;
}
.lm-result-card {
  border: 1px solid #9fb2bf;
  border-left: 5px solid var(--lm-copper);
  border-radius: 9px;
  margin: 14px 0;
  padding: 18px;
}
.lm-result-panel[data-lm-results-entering] .lm-result-card,
.lm-result-panel[data-lm-results-entering] .lm-alert,
.lm-result-panel[data-lm-results-entering] .lm-next-steps {
  animation: lm-result-enter 0.24s ease-out both;
}
.lm-result-panel[data-lm-results-entering] .lm-result-card:nth-of-type(2) {
  animation-delay: 0.04s;
}
.lm-result-panel[data-lm-results-entering] .lm-result-card:nth-of-type(3) {
  animation-delay: 0.08s;
}
.lm-result-card h3 {
  color: var(--lm-navy);
  font-size: 1.15rem;
  margin: 0;
}
.lm-result-card h4 {
  color: var(--lm-navy);
  font-size: 0.98rem;
  margin: 17px 0 7px;
}
.lm-result-card p {
  margin: 10px 0;
}
.lm-result-meta {
  color: #3d5565;
  font-size: 0.91rem;
  font-weight: 700;
}
.lm-list {
  margin: 7px 0;
  padding-left: 1.25em;
}
.lm-list li + li {
  margin-top: 6px;
}
.lm-list--warn {
  color: #713329;
}
.lm-resource-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.lm-resource-link {
  align-items: center;
  border-bottom: 1px solid var(--lm-copper);
  color: var(--lm-navy);
  display: inline-flex;
  font-size: 0.9rem;
  font-weight: 700;
  min-height: 44px;
  text-decoration: none;
}
.lm-next-steps {
  background: var(--lm-mist);
  border-radius: 9px;
  margin-top: 18px;
  padding: 16px;
}
.lm-teaser {
  background: linear-gradient(135deg, #0a314c, #124b69);
  border-radius: 10px;
  color: #fff;
  display: flex;
  gap: 20px;
  justify-content: space-between;
  margin: 28px auto;
  padding: 24px;
}
.lm-teaser > div {
  min-width: 0;
}
.lm-teaser p {
  color: #dce9ef;
  margin: 7px 0 0;
  max-width: 52rem;
}
.lm-teaser h2 {
  font-family: "Noto Serif SC", "Songti SC", serif;
  font-size: 1.35rem;
  margin: 0;
}
.lm-teaser .lm-button {
  align-self: center;
  flex: 0 0 auto;
}
.lm-shell :focus-visible {
  outline: 3px solid #d98b45;
  outline-offset: 3px;
}
@media (max-width: 620px) {
  .lm-wrap {
    width: min(100% - 24px, 1080px);
  }
  .lm-hero {
    padding: 30px 0;
  }
  .lm-tool {
    border-radius: 9px;
    margin: 20px auto;
    padding: 16px;
  }
  .lm-progress-shell {
    margin-inline: -2px;
    top: auto;
  }
  .lm-progress {
    gap: 3px;
  }
  .lm-progress li {
    font-size: 0;
  }
  .lm-progress i {
    height: 28px;
    min-width: 28px;
  }
  .lm-options {
    grid-template-columns: 1fr;
  }
  .lm-advanced-grid {
    grid-template-columns: 1fr;
  }
  .lm-choice span {
    min-height: 52px;
  }
  .lm-step-actions .lm-button {
    flex: 1 1 130px;
  }
  .lm-result-actions .lm-button {
    flex: 1 1 100%;
  }
  .lm-answer-grid {
    grid-template-columns: 1fr;
    gap: 1px;
  }
  .lm-answer-grid dd {
    margin-bottom: 8px;
  }
  .lm-teaser {
    display: block;
    padding: 20px;
  }
  .lm-teaser .lm-button {
    margin-top: 16px;
    width: 100%;
  }
}
@media (max-width: 360px) {
  .lm-wrap {
    width: calc(100% - 16px);
  }
  .lm-tool {
    padding: 12px;
  }
  .lm-choice span {
    padding-left: 39px;
  }
  .lm-choice span::before {
    left: 13px;
  }
  .lm-button {
    width: 100%;
  }
}
@media (prefers-reduced-motion: reduce) {
  .lm-shell *,
  .lm-shell *::before,
  .lm-shell *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}

@keyframes lm-choice-ripple {
  0% {
    opacity: 0.42;
    transform: scale(0);
  }
  100% {
    opacity: 0;
    transform: scale(1);
  }
}

@keyframes lm-step-enter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes lm-result-enter {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lm-step,
.lm-result-panel {
  scroll-margin-top: calc(var(--lm-header-height, 210px) + 20px);
}

@media (max-width: 767px) {
  .lm-step,
  .lm-advanced-panel {
    padding-bottom: 82px;
  }
  .lm-step-actions {
    position: sticky;
    bottom: max(72px, calc(env(safe-area-inset-bottom) + 12px));
    z-index: 5;
    padding: 10px 6px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid var(--lm-line);
    border-radius: 9px;
    box-shadow: 0 -6px 20px rgba(3, 27, 45, 0.07);
  }
}
