/* People: the list of saved charts and the add / edit form (people.js).
   Built on the page's own tokens: the panel colour for cards, hairline
   separators, Inter Tight for names and titles, the gold sign lettering. */
.people { position: fixed; inset: 0; z-index: 40; pointer-events: none; }
.people .pscreen { position: absolute; inset: 0; background: var(--page); display: flex; flex-direction: column;
  transform: translateX(100%); transition: transform .42s cubic-bezier(.2,.85,.2,1); pointer-events: auto; }
.people.open .pscreen { transform: none; }
@media (min-width: 900px) {
  .people { background: rgba(0,0,0,0); transition: background .42s; }
  .people.open { background: rgba(0,0,0,.18); pointer-events: auto; }
  .people .pscreen { left: auto; width: 480px; border-left: 1px solid var(--panel-border); }
  .people .gsheet { left: auto; width: 480px; }
}
@media (prefers-reduced-motion: reduce) { .people .pscreen { transition: none; } }
html.casting body::after { content: ""; position: fixed; inset: 0; background: var(--page); z-index: 50; }

.people .pbar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px;
  padding: calc(env(safe-area-inset-top, 0px) + 14px) 16px 10px; }
.people .pbar h2 { font-family: "Inter Tight", Inter, system-ui, sans-serif; font-weight: 600; font-size: 19px; letter-spacing: -0.01em; text-align: center; }
.people .pbar > :first-child { justify-self: start; }
.people .pbar > :last-child { justify-self: end; }
.people button { font: inherit; color: inherit; cursor: pointer; }
.people .round, .people .pill { border: 1px solid var(--panel-border); background: var(--panel); box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.people .round { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; padding: 0; }
.people .round svg, .people .glabel svg, .people .del svg, .people .grip svg, .people .cam svg, .people .gdel svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.people .round.done { background: var(--ink); color: var(--panel); border-color: var(--ink); }
.people .pill { height: 40px; padding: 0 16px; border-radius: 20px; font-size: 16px; font-weight: 500; }
.people .pill:disabled { opacity: .4; cursor: default; }
.people .pill.save:not(:disabled) { background: var(--ink); color: var(--panel); border-color: var(--ink); }
.people button:focus-visible, .people input:focus-visible, .people select:focus-visible { outline: 2px solid var(--muted); outline-offset: 2px; }

.people .pbody { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 4px 16px calc(env(safe-area-inset-bottom, 0px) + 32px); }
.people .glabel { font-family: "Inter Tight", Inter, system-ui, sans-serif; font-weight: 500; font-size: 18px; color: var(--muted); margin: 18px 6px 8px; }
.people .gtog { all: unset; display: flex; width: 100%; align-items: center; justify-content: space-between; cursor: pointer; }
.people .gtog span { display: grid; transition: transform .35s cubic-bezier(.2,.85,.2,1); }
.people .grp.shut .gtog span { transform: rotate(180deg); }
.people .grp.shut .plist { display: none; }
.people .plist { list-style: none; padding: 0; background: var(--panel); border: 1px solid var(--panel-border); border-radius: 18px; overflow: hidden; }
.people .prow { position: relative; display: flex; align-items: center; }
.people .prow + .prow .pick { border-top: 0; }
.people .prow + .prow::before { content: ""; position: absolute; top: 0; left: 84px; right: 16px; border-top: 1px solid var(--rule); }
.people .editing .prow + .prow::before { left: 110px; }
.people .pick { all: unset; flex: 1; min-width: 0; display: grid; grid-template-columns: 60px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px 12px 12px; cursor: pointer; }
.people .editing .pick { grid-template-columns: 48px minmax(0, 1fr) auto; padding-left: 10px; }
.people .editing .pick .av { width: 48px; height: 48px; }
.people .prow.cur .who b::after { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #a77b26; margin-left: 8px; vertical-align: middle; }
.people .av { position: relative; width: 60px; height: 60px; border-radius: 50%; overflow: hidden; display: block; background: color-mix(in srgb, var(--muted) 18%, var(--panel)); }
.people .av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; }
.people .av .sil { position: absolute; inset: 6px 6px 0; width: calc(100% - 12px); height: calc(100% - 6px); fill: color-mix(in srgb, var(--muted) 55%, var(--panel)); }
.people .who { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.people .who b { font-family: "Inter Tight", Inter, system-ui, sans-serif; font-weight: 600; font-size: 18px; letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.people .who span { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.people .sa { align-self: start; display: flex; align-items: flex-start; gap: 3px; margin-top: 2px; }
.people .sa img { width: 21px; height: auto; }
.people .sa img + i + img { width: 14px; }
.people .sa i { font-style: normal; font-size: 13px; color: var(--muted); }
[data-theme="light"] .people .sa img { filter: brightness(.86) saturate(1.35) contrast(1.1); }
.people .del { all: unset; margin-left: 10px; width: 28px; height: 28px; border-radius: 50%; background: #d8352f; color: #fff; display: grid; place-items: center; cursor: pointer; flex: none; }
.people .grip { padding: 0 14px 0 4px; color: var(--muted); cursor: grab; touch-action: none; flex: none; }
.people .prow.lift { background: color-mix(in srgb, var(--ink) 5%, var(--panel)); }
.people .really { position: absolute; right: 0; top: 0; bottom: 0; width: 0; padding: 0; overflow: hidden; white-space: nowrap; border: 0; background: #d8352f; color: #fff; font-weight: 600; transition: width .3s cubic-bezier(.2,.85,.2,1); }
.people .prow.armed .really { width: 96px; }
.people .empty { color: var(--muted); font-size: 15px; margin: 24px 6px; }

/* form */
.people .form .pbody { background: var(--panel); border-top: 1px solid var(--panel-border); padding-top: 18px; }
.people .fhead { display: grid; grid-template-columns: 96px 1fr; gap: 18px; align-items: center; }
.people .avpick { position: relative; cursor: pointer; }
.people .avpick .av { width: 96px; height: 96px; }
.people .cam { position: absolute; right: 0; bottom: 2px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--panel); border: 1px solid var(--panel-border); z-index: 2; }
.people .cam svg { width: 16px; height: 16px; }
.people .names { display: flex; flex-direction: column; }
.people .names input, .people .fld input, .people .fld select, .people .gcard input { font: inherit; color: inherit; background: none; border: 0; border-bottom: 1px solid var(--rule); border-radius: 0; padding: 8px 0; width: 100%; }
.people .names input { font-family: "Inter Tight", Inter, system-ui, sans-serif; font-size: 22px; font-weight: 500; }
.people .names input::placeholder, .people .fld input::placeholder { color: var(--muted); opacity: .8; }
.people .names.fixed b { font-family: "Inter Tight", Inter, system-ui, sans-serif; font-size: 22px; font-weight: 600; }
.people .names.fixed span { color: var(--muted); font-size: 15px; }
.people .gender { display: flex; justify-content: flex-start; gap: 28px; margin: 18px 0 6px 114px; }
.people .gender button { all: unset; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 15px; font-weight: 500; color: var(--muted); }
.people .gender button svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.people .gender button[aria-checked="true"] { color: #a77b26; }
.people .fld { display: block; margin-top: 22px; }
.people .flab { display: block; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.people .fld input, .people .fld select { font-size: 18px; }
.people .dt { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; }
.people .place { position: relative; }
.people .sugg { list-style: none; padding: 0; margin: 0; position: absolute; left: 0; right: 0; z-index: 3; background: var(--panel); border: 1px solid var(--panel-border); border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.12); overflow: hidden; }
.people .sugg:empty { display: none; }
.people .sugg li { padding: 11px 14px; font-size: 16px; cursor: pointer; }
.people .sugg li + li { border-top: 1px solid var(--rule); }
.people .sugg li span { color: var(--muted); }
.people .sugg li:hover { background: color-mix(in srgb, var(--ink) 4%, var(--panel)); }
.people .derived { font-size: 14px; color: var(--muted); margin-top: 8px; line-height: 1.5; }
.people .link { all: unset; cursor: pointer; color: #a77b26; font-weight: 500; white-space: nowrap; }
.people .derived .link { margin-left: 6px; }
.people .manual { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-top: 8px; }
.people .manual label { font-size: 12px; color: var(--muted); }
.people .manual input { font-size: 16px; }
.people .grow { display: flex; align-items: center; gap: 16px; }
.people .grow select { appearance: none; -webkit-appearance: none; flex: 1; }
.people .wipe { all: unset; display: block; margin: 40px auto 0; color: #d8352f; font-weight: 500; cursor: pointer; }

.people .gsheet { position: absolute; inset: 0; z-index: 5; background: rgba(0,0,0,.18); display: grid; align-items: end; pointer-events: auto; }
.people .gcard { background: var(--panel); border-radius: 18px 18px 0 0; padding: 16px 16px calc(env(safe-area-inset-bottom, 0px) + 24px); max-height: 80vh; overflow-y: auto; }
.people .gcard header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.people .gcard h2 { font-family: "Inter Tight", Inter, system-ui, sans-serif; font-size: 19px; font-weight: 600; }
.people .gcard ul { list-style: none; padding: 0; margin: 0 0 14px; }
.people .gcard li { display: flex; align-items: center; gap: 12px; }
.people .gdel { all: unset; cursor: pointer; width: 26px; height: 26px; border-radius: 50%; background: #d8352f; color: #fff; display: grid; place-items: center; flex: none; }
#panel[role="button"] { cursor: pointer; }
