/* Author `display: grid` on .locates-card-grid otherwise beats [hidden]. */
#miCards[hidden],
#miState[hidden],
#ftLocalFilters[hidden],
#ft-root .ft-filters[hidden] {
  display: none !important;
}

/* Header is already sticky. Drop its bottom margin so this bar can pin flush under it. */
body:has(#ft-root) .prod-page-header {
  margin-bottom: 0;
}

#ft-root .mi-toolbar {
  position: sticky;
  z-index: 40;
  background: var(--bg);
  margin-bottom: 8px;
  padding-top: 4px;
  padding-bottom: 10px;
  box-shadow: 0 1px 0 rgba(17, 17, 17, 0.06);
}

.ft-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.ft-local-filters {
  display: contents;
}

.ft-field {
  flex: 1 1 calc(50% - 8px);
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ft-field-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.ft-select {
  width: 100%;
  height: 44px;
  padding: 0 32px 0 12px;
  border-radius: 12px;
  border: 1.5px solid var(--border);
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23111111' stroke-opacity='0.55' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 16px;
  font-weight: 600;
  appearance: none;
  -webkit-appearance: none;
}

.ft-select.is-set {
  border-color: rgba(255, 90, 0, 0.28);
  background-color: rgba(255, 90, 0, 0.08);
  color: var(--accent);
}

.ft-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.ft-card-head .locates-card-title {
  min-width: 0;
}

.ft-job-card,
.ft-ticket-row {
  cursor: pointer;
}

.ft-job-card {
  gap: 8px;
  padding: 14px 14px 12px;
}

.ft-job-where,
.ft-ticket-where {
  font-size: 13px;
  line-height: 1.35;
  color: var(--text-primary);
}

.ft-expire-badge {
  flex: 0 0 auto;
  margin-top: 1px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  color: var(--muted);
}

.ft-expire-badge.is-hot {
  color: var(--accent);
}

.ft-pill-need {
  background: rgba(255, 90, 0, 0.1);
  border-color: rgba(255, 90, 0, 0.22);
  color: var(--accent);
}

.locates-card-grid.ft-ticket-list {
  gap: 6px;
}

.ft-ticket-row {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ft-ticket-row.is-clear {
  border-left: 3px solid #5fd585;
}

.ft-ticket-row .locates-card-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 15px;
}

.ft-type-pill {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text-primary);
}

.ft-clear-pill {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  padding: 2px 7px;
  border-radius: 999px;
  background: #5fd585;
  border: 1px solid #49c472;
  color: #102416;
}

.locates-pill-row .ft-clear-pill {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
}

.ft-ticket-need {
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--accent);
}

.ft-detail-grid {
  display: grid;
  gap: 12px;
}

.ft-detail-label {
  display: block;
  margin-bottom: 3px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.ft-detail-value {
  font-size: 15px;
  line-height: 1.4;
  word-break: break-word;
}

.ft-copy-hint {
  margin-left: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
}

.ft-section-label {
  margin: 4px 0 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
