/* ═══════════════════════════════════════════════════════════════
   ACSI Distributor Locator — styles
   Mirrors the ConveyorMatch dark-steel + amber aesthetic.
   ═══════════════════════════════════════════════════════════════ */

.locator-section {
  padding-top: 48px;
  padding-bottom: 64px;
}

/* ── Lookup card ─────────────────────────────────────────────── */
.locator-card {
  max-width: 720px;
  margin: 0 auto;
  background: linear-gradient(180deg, var(--steel-800) 0%, var(--steel-700) 100%);
  border: 1px solid var(--steel-600);
  border-radius: 8px;
  padding: 36px 36px 32px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.38);
}
.locator-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--amber);
}
.locator-card-head {
  margin-bottom: 26px;
}
.locator-step-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
  background: rgba(245, 166, 35, 0.08);
  border: 1px solid rgba(245, 166, 35, 0.3);
  padding: 4px 12px;
  border-radius: 12px;
  margin-bottom: 14px;
}
.locator-h2 {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.7rem;
  color: var(--white);
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 8px;
}
.locator-sub {
  color: var(--steel-200);
  font-size: 0.94rem;
  line-height: 1.6;
}

/* ── Form grid: ZIP / or / State ─────────────────────────────── */
.locator-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 16px;
  align-items: start;
}
.locator-field {
  display: flex;
  flex-direction: column;
}
.locator-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--steel-300);
  margin-bottom: 8px;
}
.locator-input {
  width: 100%;
  padding: 13px 14px;
  background: var(--steel-900);
  border: 1px solid var(--steel-600);
  border-radius: 4px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.locator-input:focus {
  outline: none;
  border-color: var(--amber);
  background: #0d0f12;
}
select.locator-input {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23718096' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
.locator-hint {
  font-size: 0.74rem;
  color: var(--steel-400);
  margin-top: 6px;
  font-style: italic;
}
.locator-or {
  align-items: center;
  justify-content: center;
  padding-top: 30px;
}
.locator-or span {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--steel-400);
}

/* ── Error ───────────────────────────────────────────────────── */
.locator-error {
  margin-top: 18px;
  padding: 12px 14px;
  background: rgba(239, 83, 80, 0.12);
  border: 1px solid rgba(239, 83, 80, 0.4);
  border-radius: 4px;
  color: #ffb3b0;
  font-size: 0.88rem;
}

/* ── Submit ──────────────────────────────────────────────────── */
.locator-submit {
  width: 100%;
  margin-top: 26px;
  justify-content: center;
}

/* ── Results ─────────────────────────────────────────────────── */
.locator-results {
  max-width: 720px;
  margin: 28px auto 0;
}
.locator-results-intro {
  text-align: center;
  color: var(--steel-200);
  font-size: 0.98rem;
  line-height: 1.6;
  margin-bottom: 22px;
}
.locator-results-intro strong { color: var(--white); }

/* Distributor result card */
.dist-card {
  background: var(--steel-800);
  border: 1px solid var(--steel-600);
  border-left: 4px solid var(--amber);
  border-radius: 0 6px 6px 0;
  padding: 22px 24px;
  margin-bottom: 16px;
  animation: distFadeIn 0.4s var(--ease) both;
}
.dist-card-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--white);
  margin-bottom: 4px;
}
.dist-card-loc {
  font-size: 0.86rem;
  color: var(--steel-300);
  margin-bottom: 16px;
}
.dist-card-loc::before { content: '📍 '; }
.dist-card-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ACSI fallback card */
.dist-fallback {
  background: linear-gradient(180deg, var(--steel-700) 0%, var(--steel-800) 100%);
  border: 1px solid var(--amber-dim);
  border-radius: 6px;
  padding: 30px 28px;
  text-align: center;
  position: relative;
  overflow: hidden;
  animation: distFadeIn 0.4s var(--ease) both;
}
.dist-fallback::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--amber);
}
.dist-fallback-icon { font-size: 2rem; margin-bottom: 12px; }
.dist-fallback h3 {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--white);
  margin-bottom: 12px;
}
.dist-fallback p {
  color: var(--steel-200);
  font-size: 0.95rem;
  line-height: 1.65;
  max-width: 520px;
  margin: 0 auto 22px;
}
.dist-fallback-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Result footer note — always offer ACSI directly */
.locator-results-note {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--steel-700);
  text-align: center;
  font-size: 0.84rem;
  color: var(--steel-400);
  line-height: 1.6;
}
.locator-results-note a { color: var(--amber); text-decoration: none; }
.locator-results-note a:hover { text-decoration: underline; }

/* Loading state */
.locator-loading {
  text-align: center;
  padding: 30px 0;
  color: var(--steel-300);
  font-family: var(--font-mono);
  font-size: 0.84rem;
  letter-spacing: 0.06em;
}
.locator-loading::after {
  content: '';
  display: inline-block;
  width: 14px; height: 14px;
  margin-left: 8px;
  border: 2px solid var(--steel-600);
  border-top-color: var(--amber);
  border-radius: 50%;
  vertical-align: middle;
  animation: distSpin 0.7s linear infinite;
}

@keyframes distSpin { to { transform: rotate(360deg); } }
@keyframes distFadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ── Mobile ──────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .locator-card { padding: 28px 22px 26px; }
  .locator-h2 { font-size: 1.4rem; }
  .locator-grid { grid-template-columns: 1fr; gap: 14px; }
  .locator-or { padding-top: 0; padding-bottom: 0; }
  .locator-or span { display: inline-block; padding: 2px 0; }
  .dist-card-actions .btn,
  .dist-fallback-actions .btn { flex: 1 1 auto; justify-content: center; }
}
