/* Shared text-input pattern: underline style — no box, no border-radius.
   Label sits fixed above the field; gap between label and the line is a
   deliberate 30px and should not be adjusted ad hoc (see add-listing.html /
   catalog.html for usage). Depends on the --text-*/--border-subtle/
   --accent-lime custom properties already defined in each page's :root. */

.field-label,
.filter-field-label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.field input,
.field select,
.field textarea,
.filter-field input,
.filter-field select {
  display: block;
  margin-top: 30px;
  width: 100%;
  padding: 0 0 10px;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-subtle);
  border-radius: 0;
  color: var(--text-primary);
  font-size: 15px;
  outline: none;
  transition: border-bottom-color 0.15s ease;
}

.field textarea {
  resize: none;
  height: 96px;
  line-height: 140%;
}

.field select,
.filter-field select {
  padding-right: 20px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23C6A667' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right center;
  appearance: none;
  -webkit-appearance: none;
}

/* Button that opens a sheet but should look like the rest of the underline
   fields (e.g. the multi-select tag picker in add-listing.html). */
.field-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 30px;
  width: 100%;
  padding: 0 0 10px;
  background: none;
  border: none;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 15px;
  text-align: left;
  cursor: pointer;
}

.field-select-trigger svg { color: var(--accent-lime); flex-shrink: 0; }
.field-select-trigger.is-empty { color: var(--text-tertiary); }
.field-select-trigger:disabled { color: var(--text-tertiary); opacity: 0.6; cursor: default; }
.field-select-trigger:disabled svg { color: var(--text-tertiary); }

.field input::placeholder,
.field textarea::placeholder,
.filter-field input::placeholder {
  color: var(--text-secondary);
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.filter-field input:focus,
.filter-field select:focus {
  border-bottom-color: var(--accent-lime);
}

.field select:invalid,
.filter-field select:invalid {
  color: var(--text-tertiary);
}

.field select:disabled,
.filter-field select:disabled {
  color: var(--text-tertiary);
  border-bottom-color: var(--border-subtle);
  opacity: 0.6;
}

.field-col:has(select:disabled) .field-label,
.filter-field:has(select:disabled) .filter-field-label {
  opacity: 0.6;
}
