.fpg-modal[hidden] {
  display: none !important;
}

.fpg-modal {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.fpg-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
}

.fpg-dialog {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: #fff;
  border-radius: 14px;
  padding: 28px 24px 24px;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.25);
  border: 1px solid #e2e8f0;
}

.fpg-close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: 0;
  background: transparent;
  font-size: 1.5rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
}

.fpg-title {
  margin: 0 0 8px;
  font-size: 1.35rem;
  font-weight: 800;
  color: #0f3685;
}

.fpg-sub {
  margin: 0 0 18px;
  font-size: 0.9rem;
  color: #64748b;
  line-height: 1.45;
}

.fpg-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: #334155;
  margin: 0 0 6px;
}

.fpg-input {
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 14px;
  padding: 11px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
}

.fpg-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.85rem;
  color: #475569;
  margin: 0;
  cursor: pointer;
}

.fpg-opt-in {
  margin: 2px 0 16px;
  padding: 12px 14px;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #f8fbff;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.fpg-opt-in-heading {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 700;
  color: #334155;
}

.fpg-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 7px;
  border-radius: 999px;
  background: #dbeafe;
  color: #0f3685;
  font-size: 0.72rem;
  font-weight: 700;
  vertical-align: middle;
}

.fpg-check--recommended .fpg-check-title {
  color: #0f3685;
}

.fpg-check--opt-in {
  align-items: flex-start;
}

.fpg-check--opt-in input {
  margin-top: 4px;
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.fpg-check-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  line-height: 1.4;
}

.fpg-check-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #0f3685;
}

.fpg-check-detail {
  color: #475569;
}

.fpg-check-note {
  font-size: 0.8rem;
  color: #64748b;
}

.fpg-check-privacy {
  font-size: 0.78rem;
  margin-top: 2px;
}

.fpg-check-privacy a {
  color: #0f3685;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.fpg-check-privacy a:hover {
  color: #0c2d6e;
}

.fpg-check input {
  margin-top: 3px;
}

.fpg-error {
  color: #b91c1c;
  font-size: 0.85rem;
  margin: 0 0 12px;
}

.fpg-submit {
  width: 100%;
  border: 0;
  border-radius: 10px;
  padding: 13px 16px;
  background: #0f3685;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
}

.fpg-submit:disabled {
  opacity: 0.7;
  cursor: wait;
}

.fpg-submit:hover:not(:disabled) {
  background: #0c2d6e;
}
