/* /platform (js/pages/platform.js): the platform wallet's tools. A centered column of grey panels under four tabs;
   each tool shows what is set now, and a change goes through one line of review before the wallet opens. Inputs
   are white on the grey. All under .pf. */
.pf { max-width: 860px; margin: 0 auto; }
.pf .pf-intro { padding-block: var(--page-top) 28px; }
.pf .pf-wait { text-align: center; }
.pf .pf-tabs { display: flex; justify-content: center; margin: 0 0 28px; }
.pf .pf-pane { display: grid; gap: 18px; }
.pf .notice { justify-content: space-between; }
.pf h2 { margin: 0; font-size: var(--t-xl); letter-spacing: -.02em; line-height: 1.2; }
.pf .panel { gap: 18px; min-width: 0; }
.pf .panel input, .pf .panel select { background-color: var(--bg); }
.pf .muted { font-size: var(--t-m); margin: 0; }
.pf .bad { color: var(--error); }
.pf button.link { padding: 0; border-radius: 0; background: none; font-size: inherit; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.pf button.link:hover { background: none; color: var(--muted); }
.pf .row-btns { margin: 0; }
.pf .pf-label { display: block; margin: 0 0 8px; font-size: var(--t-s); font-weight: 400; color: var(--muted); }

/* A list of rows: what it is on the left, its button on the right, a line between rows. */
.pf .pf-list { list-style: none; margin: 0; padding: 0; }
.pf .pf-list > li { padding: 14px 0; border-top: 1px solid rgba(0, 0, 0, .08); display: grid; gap: 12px; min-width: 0; }
.pf .pf-list > li:first-child { border-top: 0; padding-top: 0; }
.pf .pf-list > li:last-child { padding-bottom: 0; }
.pf .pf-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; }
.pf .pf-row > button { flex: none; }
/* A grey button on a grey panel disappears: these are white, as app.css makes the panel's own buttons. */
.pf .pf-row > button, .pf .pf-send button, .pf .pf-confirm .row-btns > button:not(.primary) { background: var(--bg); }
.pf .pf-row > button:hover, .pf .pf-send button:hover { background: var(--tint-2); }
.pf .pf-confirm .row-btns > button:not(.primary) { background: var(--tint); }
.pf .pf-confirm .row-btns > button:not(.primary):hover { background: var(--tint-2); }
.pf .pf-row-text { display: grid; gap: 2px; min-width: 0; font-size: var(--t-m); overflow-wrap: anywhere; }
.pf .pf-row-text .muted { font-size: var(--t-s); }
.pf .pf-val { font-weight: 500; }
.pf .pf-val small { display: block; font-size: 13px; font-weight: 400; color: var(--muted); }
.pf .pf-money { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; }
.pf .pf-money b { font-weight: 600; }
.pf .pf-money span { font-size: var(--t-s); color: var(--muted); font-variant-numeric: tabular-nums; }

/* An address and its button side by side. */
.pf .pf-send { display: flex; gap: 10px; min-width: 0; }
.pf .pf-send input { flex: 1; font-family: var(--mono); font-size: 13px; }
.pf .pf-send button { flex: none; }

/* Review: one line, then Confirm and Cancel. */
.pf .pf-confirm { display: grid; gap: 10px; padding: 14px 16px; border-radius: var(--radius-s); background: var(--bg); }
.pf .pf-confirm .status, .pf .pf-confirm .alert { margin: 0; }
.pf .pf-confirm .status:empty, .pf .pf-confirm .alert:empty { display: none; }
.pf .pf-line { margin: 0; font-size: 15px; overflow-wrap: anywhere; }

/* Fix a drop. */
.pf .pf-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pf .pf-num { flex-direction: row; align-items: center; gap: 10px; font-size: var(--t-s); }
.pf .pf-num input { width: 120px; text-align: center; font-variant-numeric: tabular-nums; }
.pf .pf-fix-body { display: grid; gap: 22px; min-width: 0; }
.pf .pf-fix-body:empty { display: none; }
.pf .pf-state { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin: 0; font-size: var(--t-s); color: var(--muted); }
.pf .pf-state .chip:not(.live):not(.soon):not(.sold):not(.paused) { background: var(--bg); }
.pf .pf-fix { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 360px); gap: 28px; align-items: start; }
.pf .pf-form { display: grid; gap: 20px; min-width: 0; }
.pf .pf-field { min-width: 0; }
.pf .pf-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pf .pf-note { margin: 8px 0 0; font-size: 13px; color: var(--muted); }
.pf .pf-note:empty { display: none; }
.pf .pf-unit { flex-direction: row; align-items: center; gap: 0; background: var(--bg); border-radius: 12px; color: var(--muted); font-size: 15px; }
.pf .pf-unit input { flex: 1; padding-right: 4px; font-variant-numeric: tabular-nums; }
.pf .pf-unit span { padding-right: 14px; }
.pf .pf-swatches { display: grid; grid-template-columns: repeat(8, 28px); justify-content: space-between; row-gap: 12px; padding: 2px 4px; }
.pf .pf-swatch { width: 28px; height: 28px; padding: 0; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08); outline: 2px solid transparent; outline-offset: 2px; transition: outline-color .2s; }
.pf .pf-swatch[aria-checked=true], .pf .pf-swatch:focus-visible { outline-color: var(--ink); }

/* Now and after, side by side: the rarest artwork in each palette and the four settings, a change in ink. */
.pf .pf-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; min-width: 0; }
.pf .pf-col { min-width: 0; padding: 14px; border-radius: var(--radius-s); background: var(--bg); }
.pf .pf-art { width: 100%; aspect-ratio: 1; display: grid; place-items: center; overflow: hidden; border-radius: 10px; background: #fff; box-shadow: 0 0 0 1px var(--tint-2); margin-bottom: 12px; }
.pf .pf-dl { margin: 0; display: grid; gap: 10px; }
.pf .pf-dl dt { font-size: var(--t-xs); color: var(--muted); }
.pf .pf-dl dd { margin: 0; font-size: var(--t-s); color: var(--muted); overflow-wrap: anywhere; }
.pf .pf-dl dd b { font-weight: 600; }
.pf .pf-dl dd span { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pf [data-col=now] dd { color: var(--ink); }
.pf .pf-dl .pf-changed dd { color: var(--ink); font-weight: 500; }
.pf .pf-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08); }

/* Settings: a form opens under its row. */
.pf .pf-edit { display: grid; gap: 12px; }
.pf .pf-edit .alert { margin: 0; }
.pf .pf-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.pf .pf-fields label { min-width: 0; }
.pf .pf-fields [data-for] { display: contents; }
.pf .pf-fields .pf-src { grid-column: 1 / -1; justify-self: start; background: var(--bg); }
.pf .pf-fields .pf-src button[aria-pressed=true] { background: var(--tint-2); box-shadow: none; }
.pf .pf-fields input[name=to], .pf .pf-fields input[name=feed], .pf .pf-fields input[name=uri] { font-family: var(--mono); font-size: 13px; }
.pf .pf-sets [data-set=treasury] .pf-fields, .pf .pf-sets [data-set=royalty] .pf-fields,
.pf .pf-sets [data-set=base] .pf-fields, .pf .pf-sets [data-set=contract] .pf-fields { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 641px) { .pf .pf-sets [data-set=royalty] .pf-fields { grid-template-columns: minmax(0, 3fr) minmax(0, 1fr); } }

/* Code: the checks a new address passes before Upgrade shows. */
.pf .pf-upgrade { display: grid; gap: 12px; padding-top: 18px; border-top: 1px solid rgba(0, 0, 0, .08); }
.pf .pf-upgrade .pf-label { margin: 0; font-size: 15px; font-weight: 600; color: var(--ink); }
.pf .pf-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: var(--t-s); }
.pf .pf-checks li { display: grid; grid-template-columns: 20px minmax(0, 1fr); }
.pf .pf-checks li::before { content: ""; }
.pf .pf-checks li.ok::before { content: "✓"; }
.pf .pf-checks li.no { color: var(--error); }
.pf .pf-checks li.no::before { content: "×"; }

@media (max-width: 860px) {
  .pf .pf-fix { grid-template-columns: minmax(0, 1fr); }
}
/* An iPhone zooms in on a field under 16 px (app.css does the rest). */
@media (pointer: coarse) {
  .pf .pf-send input, .pf .pf-fields input[name=to], .pf .pf-fields input[name=feed], .pf .pf-fields input[name=uri] { font-size: 16px; }
}
@media (max-width: 640px) {
  .pf .pf-intro { padding-block: var(--page-top) 20px; }
  .pf .pf-tabs { margin-bottom: 20px; }
  .pf .panel { padding: 20px 16px; }
  .pf .pf-top { flex-wrap: wrap; }
  .pf .pf-num input { width: 104px; }
  .pf .pf-col { padding: 10px; }
  .pf .pf-swatches { grid-template-columns: repeat(8, 26px); padding: 2px 2px; }
  .pf .pf-swatch { width: 26px; height: 26px; }
  .pf .pf-row { align-items: flex-start; }
  .pf .pf-send { flex-direction: column; }
  .pf .pf-send button { align-self: flex-start; }
}
