/* Profile fields (Core/CustomFields): the inputs on /account/profile, the join page and a
   member's Manage page (Shared/_FieldInput), the answers on profiles, cards and the
   members list, and the owner's pages under /manage/profile-fields.

   Mobile first, every tap target at least 44 px, form text 16 px. Every color, font and
   radius is a custom property from site.css: no color is written here. */

/* ---- Inputs ---- */
.pf-entry { display: flex; flex-direction: column; gap: 4px; }
.pf-required { color: var(--muted); font-weight: 400; }
.pf-who { margin: 0; color: var(--muted); font-size: 14px; }

.pf-select, .pf-textarea {
  width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid var(--field-line); border-radius: var(--radius-small);
  background: var(--surface); color: var(--ink); font: inherit; font-size: 16px; transition: border-color var(--ease), box-shadow var(--ease);
}
.pf-textarea { min-height: 112px; line-height: 1.5; resize: vertical; }
.pf-select:focus, .pf-textarea:focus { border-color: var(--accent); box-shadow: var(--field-glow); }
.pf-select:focus-visible, .pf-textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pf-select[aria-invalid="true"], .pf-textarea[aria-invalid="true"] { border-color: var(--danger); border-width: 2px; }
.pf-field .pf-number, .pf-field .pf-date { max-width: 14rem; }

.pf-group { display: flex; flex-direction: column; gap: 6px; min-width: 0; margin: 0; padding: 0; border: 0; }
.pf-group legend { padding: 0; margin-bottom: 2px; }
.pf-choices { display: flex; flex-direction: column; gap: 0; }
.pf-inline { flex-direction: row; flex-wrap: wrap; gap: 0 20px; }

/* ---- Answers ---- */
.pf-verified-word { display: inline-flex; align-items: center; gap: 4px; margin-left: 8px; color: var(--muted); font-size: 14px; font-weight: 600; }
.pf-verified { vertical-align: -2px; margin-left: 4px; color: var(--muted); }
.pf-line a { overflow-wrap: anywhere; }

.pf-long { padding-top: 16px; margin-top: 16px; border-top: 1px solid var(--line-soft); }
.pf-long-title { margin: 0 0 4px; color: var(--muted); font-family: var(--font); font-size: 14px; font-weight: 400; }
.pf-long-text { margin: 0; white-space: pre-line; overflow-wrap: anywhere; }

/* The members list: the answers under the name, and the "Show" filter. */
.member-row-fields { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 0 16px; color: var(--ink); font-size: 14px; }
.member-row-fields .card-line { display: inline; }
.pf-filter { align-items: center; }
.pf-filter-label { font-weight: 600; }
.pf-filter .pf-select { flex: 1 1 14rem; width: auto; max-width: 26rem; }

/* ---- The owner's pages ---- */
.pf-kinds { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: minmax(0, 1fr); }
.pf-kinds li { border-top: 1px solid var(--line-soft); }
.pf-kinds li:first-child { border-top: 0; }
.pf-kind { display: flex; flex-direction: column; gap: 2px; min-height: 44px; padding: 12px 16px; color: var(--ink); text-decoration: none; transition: background-color var(--ease); }
.pf-kind strong { color: var(--accent); }
.pf-kind:hover { background: var(--surface-alt); }
.pf-kind:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.pf-range { display: flex; flex-wrap: wrap; gap: 12px 20px; }
.pf-new-choices { width: 100%; min-height: 96px; resize: vertical; line-height: 1.5; }
.pf-foot { padding: 10px 16px; font-size: 14px; }
.pf-row .m-role-name { flex-wrap: wrap; }

@media (min-width: 768px) {
  .pf-kinds { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pf-kinds li:nth-child(2) { border-top: 0; }
  .pf-kinds li:nth-child(even) { border-left: 1px solid var(--line-soft); }
}
