/* ---------- System font everywhere; Elementor-friendly color inheritance ---------- */

/* Let Elementor control color via inheritance (Text Editor → Style → Text Color) */
.lg-wrap,
.lg-form--card,
.lg-actions,
.lg-btn,
.lg-primary,
.lg-emailbar,
.lg-emailrow,
.lg-email-input,
.lg-email-label,
.lg-card.lg-letter,
.lg-letter__body,
.lg-letter__meta {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: inherit;
}

.lg-center { text-align: center; }

/* ---- Form (card) ---- */
.lg-form--card {
  max-width: 760px;
  margin: 1.5rem auto;
  padding: 16px 18px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 10px 26px rgba(0,0,0,.06);
  display: grid;
  gap: 12px;
}
.lg-form--card label { display: grid; gap: 6px; font-weight: 600; }
.lg-form--card input, .lg-form--card select, .lg-form--card textarea {
  padding: .75rem .9rem; border: 1px solid #d1d5db; border-radius: 12px; font-size: 16px; background:#fff; color: inherit;
}

/* ---------------- Button THEMES (switched by wrapper class) ---------------- */

/* A) Default: Black/White buttons */
.lg-theme-bw .lg-primary,
.lg-theme-bw .lg-btn {
  padding: .9rem 1.2rem; border-radius: 12px;
  background: #111; color: #fff; border: 1px solid #111; cursor: pointer; font-weight: 700;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.lg-theme-bw .lg-primary:hover,
.lg-theme-bw .lg-btn:hover { background: #fff; color: #111; }
.lg-primary--small { padding: .6rem 1rem; }
.lg-primary--center { display: inline-block; }
.lg-ghost { background: #fff; }

/* B) Inherit Elementor color (uses currentColor) */
.lg-theme-inherit .lg-primary,
.lg-theme-inherit .lg-btn {
  padding: .9rem 1.2rem; border-radius: 12px;
  background: transparent; color: currentColor; border: 1px solid currentColor; cursor: pointer; font-weight: 700;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.lg-theme-inherit .lg-primary:hover,
.lg-theme-inherit .lg-btn:hover { background: currentColor; color: #fff; }

/* ---- Letter Card ---- */
.lg-card.lg-letter {
  max-width: 860px;
  margin: 18px auto;
  padding: 20px 22px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 14px 36px rgba(0,0,0,.08);
  font-size: 18px;
  line-height: 1.8;
}
.lg-letter__meta { text-align: right; color: #6b7280; font-size: 14px; }
.lg-letter__body p { margin: 0 0 12px; }

/* Optional decorative drop-cap on first paragraph */
.lg-letter__body p:first-of-type::first-letter {
  float: left; font-size: 2.4em; line-height: .85; padding-right: .14em; color: inherit; font-weight: 700;
}

/* ---- Actions ---- */
.lg-actions {
  max-width: 860px; margin: 10px auto; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;
}
.lg-btn { padding: .65rem .9rem; border-radius: 10px; }

/* ---- Email row ---- */
.lg-emailbar { max-width: 860px; margin: 12px auto 2rem; }
.lg-emailrow {
  display: inline-flex; gap: .6rem; align-items: center; justify-content: center; flex-wrap: wrap;
}
.lg-email-label { font-weight: 600; }
.lg-email-input {
  padding: .6rem .8rem; border: 1px solid #d1d5db; border-radius: 10px; background:#fff; color: inherit; min-width: 260px;
}

/* ---- Notices ---- */
.lg-error, .lg-success {
  max-width: 760px; margin: 1rem auto; padding: .85rem 1rem; border-radius: 10px;
}
.lg-error { background: #fee2e2; color: #991b1b; }
.lg-success { background: #ecfdf5; color: #065f46; }

/* ---- Print ---- */
@media print {
  body * { visibility: hidden; }
  .lg-letter, .lg-letter * { visibility: visible; }
  .lg-letter { position: absolute; left: 0; top: 0; width: 100%; }
}
