.lcf-card,
.lcf-card * {
  box-sizing: border-box;
}

.lcf-card [hidden] {
  display: none !important;
}

.lcf-card {
  --lcf-pink: #f62d69;
  --lcf-pink-2: #ff6c9a;
  --lcf-ink: #26324a;
  --lcf-muted: #727d93;
  --lcf-line: #ffd2df;
  width: min(100%, 820px);
  margin: 14px auto;
  padding: 15px;
  border: 1px solid rgba(255, 190, 207, .7);
  border-radius: 20px;
  background: rgba(255, 255, 255, .94);

  
  color: var(--lcf-ink);
}

.lcf-card button,
.lcf-card input,
.lcf-card select,
.lcf-card textarea {
  font: inherit;
}

.lcf-card button {
  cursor: pointer;
}

.lcf-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.lcf-head-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 14px;
  background: linear-gradient(135deg, #ffe5ed, #fff);
  color: var(--lcf-pink);
  font-size: 30px;
  filter: drop-shadow(0 8px 10px rgba(246, 45, 105, .16));
}

.lcf-head h2 {
  margin: 0;
  color: var(--lcf-pink);
  font-size: clamp(24px, 2.4vw, 32px);
  line-height: 1.12;
  font-weight: 900;
}

.lcf-head p {
  margin: 4px 0 0;
  color: var(--lcf-muted);
  font-size: 15px;
}

.lcf-head-heart {
  margin-left: auto;
  font-size: 40px;
  filter: drop-shadow(0 10px 12px rgba(246, 45, 105, .18));
}

.lcf-field-block label,
.lcf-step-title {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 10px;
  color: var(--lcf-ink);
  font-size: 18px;
  font-weight: 900;
}

.lcf-step-title {
  margin-top: 14px;
}

.lcf-step-title:first-of-type {
  margin-top: 0;
}

.lcf-step-title span {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--lcf-pink);
  color: #fff;
  font-size: 14px;
  line-height: 1;
}

.lcf-step-title em {
  color: var(--lcf-muted);
  font-size: 14px;
  font-style: normal;
  font-weight: 500;
}

.lcf-inline-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 140px;
  gap: 10px;
}

.lcf-inline-form input,
.lcf-select-field select,
.lcf-custom-panel input {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid #d8dee9;
  border-radius: 11px;
  outline: 0;
  background: #fff;
  color: var(--lcf-ink);
  font-size: 16px;
}

.lcf-inline-form input::placeholder,
.lcf-custom-panel input::placeholder {
  color: #a4adbd;
}

.lcf-inline-form button,
.lcf-use-button {
  min-height: 50px;
  border: 0;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--lcf-pink), var(--lcf-pink-2));
  color: #fff;
  font-size: 17px;
  font-weight: 900;
  box-shadow: 0 10px 20px rgba(246, 45, 105, .22);
}

.lcf-inline-form button:hover,
.lcf-use-button:hover {
  filter: brightness(1.04);
  transform: translateY(-1px);
}

.lcf-try {
  margin: 12px 0 0;
  color: var(--lcf-muted);
  font-size: 15px;
}

.lcf-try button {
  padding: 0 4px;
  border: 0;
  background: transparent;
  color: var(--lcf-pink);
  font-size: 16px;
}

.lcf-result-box {
  min-height: 210px;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--lcf-line);
  border-radius: 14px;
  background: linear-gradient(180deg, #fff, #fff8fb);
}

.lcf-result-box h3,
.lcf-popular h3 {
  margin: 0 0 12px;
  color: var(--lcf-pink);
  font-size: 18px;
  font-weight: 900;
}

.lcf-empty-state {
  min-height: 145px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  text-align: center;
  color: var(--lcf-muted);
}

.lcf-envelope {
  font-size: 58px;
  line-height: 1;
}

.lcf-empty-state strong {
  color: var(--lcf-ink);
  font-size: 20px;
}

.lcf-empty-state span {
  font-size: 15px;
}

.lcf-result-content {
  display: grid;
  gap: 8px;
  justify-items: center;
  padding: 16px 6px 10px;
  text-align: center;
}

.lcf-result-code {
  color: var(--lcf-pink);
  font-size: 36px;
  font-weight: 900;
}

.lcf-result-content strong {
  color: var(--lcf-ink);
  font-size: 24px;
}

.lcf-result-content p {
  margin: 0;
  color: var(--lcf-muted);
  font-size: 16px;
}

.lcf-result-box .lcf-meaning {
  margin: 18px 0 0;
}

.lcf-decode-meaning {
  grid-template-columns: minmax(120px, .55fr) minmax(0, 1.45fr);
  margin-top: 16px;
}

.lcf-popular {
  margin-top: 18px;
}

.lcf-popular-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 5px;
}

.lcf-mini-code {
 
  display: grid;
  place-items: center;
  padding: 5px;
  border: 1px solid var(--lcf-line);
  border-radius: 11px;
  background: rgba(255, 255, 255, .88);
  color: var(--lcf-ink);
  text-align: center;
}

.lcf-mini-code strong {
  color: var(--lcf-pink);
  font-size: 14px;
}

.lcf-mode-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

.lcf-mode-card {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) 24px;
  align-items: center;
  justify-items: start;
  padding: 7px;
  border: 1px solid #d8dee9;
  border-radius: 12px;
  background: #fff;
  color: var(--lcf-ink);
  text-align: left;
}

.lcf-mode-card.is-active {
  border-color: var(--lcf-pink);
  background: linear-gradient(135deg, #fff7fa, #fff);
}

.lcf-mode-card > span {
  grid-row: 1 / 3;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: #ffeaf1;
  color: var(--lcf-pink);
  font-size: 23px;
}

.lcf-mode-card strong {
  grid-column: 2;
  grid-row: 1;
  font-size: 17px;
  line-height: 1.2;
}

.lcf-mode-card em {
  grid-column: 2;
  grid-row: 2;
  color: var(--lcf-muted);
  font-size: 13px;
  font-style: normal;
  line-height: 1.35;
}

.lcf-mode-card b {
  grid-column: 3;
  grid-row: 1 / 3;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  justify-self: end;
  border: 2px solid #d8dee9;
  border-radius: 50%;
  color: #fff;
  font-size: 14px;
}

.lcf-mode-card.is-active b {
  border-color: var(--lcf-pink);
  background: var(--lcf-pink);
}

.lcf-select-field,
.lcf-custom-panel label {
  display: grid;
  gap: 6px;
  margin-bottom: 10px;
  color: var(--lcf-ink);
  font-size: 14px;
  font-weight: 800;
}

.lcf-custom-row {
  display: grid;
  grid-template-columns: minmax(150px, .42fr) minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  margin-bottom: 10px;
}

.lcf-custom-meaning-field {
  position: relative;
}

.lcf-custom-panel small {
  position: absolute;
  right: 10px;
  bottom: -18px;
  color: var(--lcf-muted);
  font-size: 12px;
  font-weight: 500;
}

.lcf-custom-panel input.is-locked,
.lcf-custom-panel input[readonly] {
  border-color: #bde8cd;
  background: #f4fff8;
  color: #14804a;
}

.lcf-meaning {
  display: grid;
  grid-template-columns: minmax(150px, .75fr) minmax(0, 1.25fr);
  gap: 10px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid var(--lcf-line);
  border-radius: 12px;
  background: linear-gradient(90deg, #fff5f8, #fff);
}

.lcf-meaning div {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 10px;
}

.lcf-meaning div > span {
  grid-row: 1 / 3;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: #ffe8f0;
  color: var(--lcf-pink);
  font-size: 21px;
  font-weight: 900;
}

.lcf-meaning small {
  color: var(--lcf-muted);
  font-size: 12px;
}

.lcf-meaning strong {
  color: var(--lcf-pink);
  font-size: 16px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.lcf-meaning strong.is-existing-code {
  color: #14804a;
}

.lcf-edit-code {
  grid-column: 2;
  width: max-content;
  min-height: 26px;
  margin-top: 6px;
  padding: 0 9px;
  border: 1px solid #9bd7b5;
  border-radius: 999px;
  background: #f0fff6;
  color: #14804a;
  font-size: 12px;
  font-weight: 900;
}

.lcf-edit-code span {
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  margin-right: 4px;
}

.lcf-edit-code em {
  font-style: normal;
}

.lcf-edit-code:hover {
  border-color: #14804a;
  background: #e4ffef;
}

.lcf-use-button {
  width: 100%;
}

.lcf-copy-toast {
  width: 100%;
  margin-top: 10px;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 3px 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #ffc1d3;
  border-radius: 14px;
  background: rgba(255, 247, 250, .98);
  box-shadow: 0 10px 24px rgba(246, 45, 105, .12);
  color: var(--lcf-ink);
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity .18s ease, transform .18s ease;
}

.lcf-copy-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.lcf-copy-toast > span {
  grid-row: 1 / 3;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: linear-gradient(135deg, #ffe3ec, #fff);
  font-size: 22px;
}

.lcf-copy-toast strong {
  color: var(--lcf-pink);
  font-size: 16px;
  line-height: 1.15;
}

.lcf-copy-toast em {
  color: var(--lcf-muted);
  font-size: 13px;
  font-style: normal;
}

.lcf-use-button.is-copied {
  background: linear-gradient(135deg, #10b981, #22c55e) !important;
  color: #fff !important;
  box-shadow: 0 18px 36px rgba(16, 185, 129, .28);
  transform: translateY(-1px);
}

.lcf-modal[hidden] {
  display: none;
}

.lcf-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: 18px;
}

.lcf-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(45, 24, 38, .36);
  backdrop-filter: blur(4px);
}

.lcf-modal-card {
  position: relative;
  width: min(100%, 440px);
  padding: 24px;
  border: 1px solid #ffc1d3;
  border-radius: 22px;
  background: linear-gradient(180deg, #fff, #fff7fa);
  box-shadow: 0 28px 80px rgba(246, 45, 105, .24);
  text-align: center;
}

.lcf-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  color: var(--lcf-pink);
  font-size: 24px;
  line-height: 1;
  box-shadow: 0 8px 20px rgba(246, 45, 105, .12);
}

.lcf-modal-icon {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
  border-radius: 20px;
  background: #ffe7ef;
  font-size: 34px;
}

.lcf-modal-card h3 {
  margin: 0 0 8px;
  color: var(--lcf-pink);
  font-size: 24px;
  font-weight: 900;
}

.lcf-modal-card p {
  margin: 0;
  color: var(--lcf-muted);
  font-size: 15px;
}

.lcf-modal-code {
  margin: 16px 0;
  padding: 11px 12px;
  border: 1px dashed #ff9fba;
  border-radius: 12px;
  background: #fff;
  color: var(--lcf-ink);
  font-weight: 900;
}

.lcf-modal-actions {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr) auto;
  gap: 8px;
  align-items: stretch;
}

.lcf-modal-actions a,
.lcf-modal-actions button {
  min-height: 42px;
  display: inline-grid;
  place-items: center;
  padding: 0 12px;
  border-radius: 11px;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.lcf-modal-primary {
  background: linear-gradient(135deg, var(--lcf-pink), var(--lcf-pink-2));
  color: #fff;
}

.lcf-modal-secondary,
.lcf-modal-ghost {
  border: 1px solid var(--lcf-line);
  background: #fff;
  color: var(--lcf-ink);
}

.lcf-modal-ghost {
  min-width: 66px;
}

@media (max-width: 720px) {
  .lcf-card {
    margin: 10px auto;

    border-radius: 18px;
  }

  .lcf-head {
    align-items: flex-start;
    margin-bottom: 16px;
  }

  .lcf-head-icon {
    width: 42px;
    height: 42px;
    font-size: 26px;
  }

  .lcf-head h2 {
    font-size: 24px;
  }

  .lcf-head-heart {
    display: none;
  }

  .lcf-inline-form,
  .lcf-mode-grid,
  .lcf-meaning,
  .lcf-custom-row {
    grid-template-columns: 1fr;
  }

  .lcf-popular-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .lcf-mode-card {
    min-height: 78px;
  }

  .lcf-modal-actions {
    grid-template-columns: 1fr;
  }

  .lcf-modal-actions a,
  .lcf-modal-actions button {
    font-size: 14px;
  }
}
