/* TAN Leads — Quote Modal (EXT-04) */

.tan-lead-modal-open { overflow: hidden; }

.tan-lead-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}
.tan-lead-modal[aria-hidden="false"] { display: flex; }

.tan-lead-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(13, 20, 38, .55);
  backdrop-filter: blur(2px);
}

.tan-lead-modal__panel {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(13, 20, 38, .35);
  animation: tanLeadIn .18s ease-out;
}
@keyframes tanLeadIn { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }

.tan-lead-modal__x {
  position: absolute;
  top: 12px; right: 12px;
  width: 34px; height: 34px;
  border: none;
  background: rgba(0,0,0,.05);
  border-radius: 50%;
  font-size: 22px;
  line-height: 1;
  color: #555;
  cursor: pointer;
}
.tan-lead-modal__x:hover { background: rgba(0,0,0,.1); }

.tan-lead-modal__head {
  padding: 24px 24px 8px;
}
.tan-lead-modal__head h3 { margin: 0; font-size: 22px; color: #1B2A4A; }
.tan-lead-modal__sub { margin: 4px 0 0; color: #667; font-size: 14px; }

.tan-lead-form { padding: 12px 24px 24px; }

.tan-lead-row { display: flex; gap: 12px; }
.tan-lead-row .tan-lead-field { flex: 1; }

.tan-lead-field { display: block; margin-bottom: 14px; }
.tan-lead-field > span { display: block; font-size: 13px; font-weight: 600; color: #344; margin-bottom: 5px; }
.tan-lead-field em { color: #C0392B; font-style: normal; }
.tan-lead-field small { color: #99a; font-weight: 400; }

.tan-lead-field input,
.tan-lead-field select,
.tan-lead-field textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 12px;
  border: 1px solid #d7dbe3;
  border-radius: 9px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
  transition: border-color .15s, box-shadow .15s;
}
.tan-lead-field input:focus,
.tan-lead-field select:focus,
.tan-lead-field textarea:focus {
  outline: none;
  border-color: #1B2A4A;
  box-shadow: 0 0 0 3px rgba(27, 42, 74, .12);
}
.tan-lead-field textarea { resize: vertical; }

/* Honeypot — kept in the DOM but hidden from humans + assistive tech focus */
.tan-lead-hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px; height: 1px;
  overflow: hidden;
}

.tan-lead-error {
  background: #fef2f2;
  color: #9b2c2c;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 13px;
  margin-bottom: 12px;
}

.tan-lead-submit {
  position: relative;
  width: 100%;
  padding: 13px;
  border: none;
  border-radius: 10px;
  background: #C0392B;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: background .15s;
}
.tan-lead-submit:hover { background: #a93226; }
.tan-lead-submit:disabled { opacity: .7; cursor: default; }
.tan-lead-submit.is-loading .tan-lead-submit__label { visibility: hidden; }
.tan-lead-submit__spin { display: none; }
.tan-lead-submit.is-loading .tan-lead-submit__spin {
  display: block;
  position: absolute;
  top: 50%; left: 50%;
  width: 18px; height: 18px;
  margin: -9px 0 0 -9px;
  border: 2px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: tanLeadSpin .7s linear infinite;
}
@keyframes tanLeadSpin { to { transform: rotate(360deg); } }

.tan-lead-privacy { margin: 10px 0 0; text-align: center; font-size: 12px; color: #99a; }

.tan-lead-success { padding: 40px 28px; text-align: center; }
.tan-lead-success__check {
  width: 64px; height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: #16a34a;
  color: #fff;
  font-size: 34px;
  line-height: 64px;
}
.tan-lead-success h3 { margin: 0 0 6px; color: #1B2A4A; font-size: 22px; }
.tan-lead-success p { margin: 0 0 20px; color: #667; }
.tan-lead-success .tan-lead-submit { background: #1B2A4A; }
.tan-lead-success .tan-lead-submit:hover { background: #14213d; }

@media (max-width: 480px) {
  .tan-lead-row { flex-direction: column; gap: 0; }
  .tan-lead-modal__panel { border-radius: 14px; }
}

/* Photo upload */
.tan-lead-photos { display: flex; flex-direction: column; gap: 10px; }
.tan-lead-photos__add {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: flex-start;
  padding: 9px 14px;
  border: 1px dashed #c3cad6;
  border-radius: 9px;
  background: #f7f8fb;
  font-size: 14px;
  font-weight: 600;
  color: #344;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.tan-lead-photos__add:hover { border-color: #1B2A4A; background: #eef1f6; }
.tan-lead-photos__previews { display: flex; flex-wrap: wrap; gap: 10px; }
.tan-lead-photo {
  position: relative;
  width: 72px; height: 72px;
  border-radius: 9px;
  overflow: hidden;
  border: 1px solid #e6e8ee;
}
.tan-lead-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tan-lead-photo__rm {
  position: absolute;
  top: 2px; right: 2px;
  width: 20px; height: 20px;
  border: none;
  border-radius: 50%;
  background: rgba(13,20,38,.72);
  color: #fff;
  font-size: 15px;
  line-height: 18px;
  cursor: pointer;
  padding: 0;
}
.tan-lead-photo__rm:hover { background: #C0392B; }
