@charset "UTF-8";
/* Compact member hub (2026-11-19). Loaded after style.css and workspace.css; reuses their tokens. */
:root { --radius: 14px; --shadow-sm: 0 1px 2px rgba(0,0,0,.06); --shadow-md: 0 6px 20px rgba(0,0,0,.08); }

.site-header { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 86%, transparent); backdrop-filter: saturate(1.4) blur(10px); }

/* Profile strip */
.hub-head { display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; align-items: center; gap: 20px; margin-top: 28px; padding: 20px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.hub-head .profile-avatar.hub-avatar { width: 72px; height: 72px; border-radius: 50%; }
.hub-who { min-width: 0; }
.hub-who h1 { font-size: 22px; line-height: 1.3; overflow-wrap: anywhere; }
.hub-who p { color: var(--muted); font-size: 14px; }
.hub-account { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.hub-account a { color: var(--accent); font-weight: 600; }
.hub-role { padding: 0 8px; border-radius: 999px; background: var(--surface-muted); border: 1px solid var(--line); font-size: 12px; }
.hub-coins { display: flex; flex-direction: column; align-items: flex-end; padding: 0 20px; border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
.hub-coins-label { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.hub-coins-label svg { width: 17px; height: 17px; }
.hub-coins strong { font-size: 30px; line-height: 1.2; font-variant-numeric: tabular-nums; }
.hub-coins strong.no-balance { font-size: 18px; color: var(--muted); }
.hub-coins-time { font-size: 12px; color: var(--muted); }
.hub-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.hub-actions .button { min-height: 42px; }

/* Two columns: activity first, profile extras on the side */
.hub-layout { display: grid; grid-template-columns: minmax(0,1fr) 320px; gap: 22px; align-items: start; margin-top: 22px; }
.hub-main .workspace-panel { margin-top: 0; padding: 22px 24px; border-radius: var(--radius); }
.hub-side { display: flex; flex-direction: column; gap: 16px; }
.hub-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.hub-card .panel-heading { margin-bottom: 12px; }
.hub-card .panel-heading h2, .hub-card h2 { font-size: 16px; }
.hub-card .namecard-frame { min-height: 0; border-radius: 10px; }
.hub-card .namecard-note { font-size: 12px; color: var(--muted); margin-top: 8px; }
.hub-sync summary { cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 8px; font-weight: 600; }
.hub-sync[open] summary { margin-bottom: 10px; }
.hub-sync .sync-list div { padding: 8px 0; }
.hub-sync .sync-note { font-size: 12.5px; }
.hub-rules ul { margin: 8px 0 0; padding-left: 18px; color: var(--muted); font-size: 13px; display: flex; flex-direction: column; gap: 6px; }

/* Workspace tweaks (tabs are links in the 2026-11-14 workspace) */
.submission-intro { align-items: center; padding: 14px 16px; border-radius: 12px; background: var(--surface-muted); }
.share-rules { margin: 18px 0 12px; padding: 14px 16px; border: 1px solid var(--warn-line); background: var(--warn-soft); border-radius: 12px; }
.share-rules h4 { margin: 0 0 6px; font-size: 14px; color: var(--amber); }
.share-rules ul { margin: 0; padding-left: 18px; font-size: 13px; color: var(--ink); display: flex; flex-direction: column; gap: 4px; }

@media (max-width: 980px) {
  .hub-head { grid-template-columns: auto minmax(0,1fr); }
  .hub-coins { grid-column: 1 / -1; flex-direction: row; align-items: baseline; gap: 10px; padding: 12px 0 0; border: 0; border-top: 1px solid var(--line); }
  .hub-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .hub-layout { grid-template-columns: minmax(0,1fr); }
}
@media (max-width: 600px) {
  .hub-head { padding: 16px; gap: 14px; }
  .hub-head .profile-avatar.hub-avatar { width: 56px; height: 56px; }
  .hub-coins { flex-wrap: wrap; }
  .hub-coins strong { font-size: 24px; }
  .hub-actions .button { flex: 1; justify-content: center; }
  .hub-main .workspace-panel { padding: 16px; }
        .record-row { flex-direction: column; align-items: stretch; gap: 8px; }
  .record-side { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 6px 12px; min-width: 0; max-width: none; }
  .record-side small { text-align: left; }
  .workspace-tabs { overflow-x: auto; }
  .workspace-tabs a { padding: 10px 12px; white-space: nowrap; }
}

/* Account security (2026-11-19) */
.hub-security summary { cursor: pointer; font-weight: 600; }
.hub-security[open] summary { margin-bottom: 12px; }
.hub-security form { display: flex; flex-direction: column; gap: 10px; }
.hub-security .form-field { display: flex; flex-direction: column; gap: 4px; margin: 0; font-size: 13.5px; }
.hub-security input { width: 100%; min-height: 40px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.hub-security .button { align-self: flex-start; }

/* Switch pairing */
.pair-box { border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin-bottom: 14px; background: var(--surface); }
.pair-box h3 { font-size: 17px; margin: 0 0 4px; }
.pair-box input[name="code"] { font-size: 20px; letter-spacing: .12em; text-transform: uppercase; font-family: ui-monospace, "SFMono-Regular", Menlo, monospace; }
.device-file { margin-bottom: 14px; }
.device-file summary { cursor: pointer; color: var(--muted); padding: 6px 0; }
.device-file[open] summary { margin-bottom: 8px; }

/* ---- Compact layout (2026-11-19) ---- */
.hub-head { margin-top: 4px; padding: 12px 18px; gap: 16px; }
.hub-head .profile-avatar.hub-avatar { width: 52px; height: 52px; }
.hub-who h1 { font-size: 19px; line-height: 1.25; }
.hub-who p { font-size: 13px; line-height: 1.5; }
.hub-coins { padding: 0 16px; }
.hub-coins strong { font-size: 22px; }
.hub-actions .button { min-height: 36px; padding-top: 4px; padding-bottom: 4px; }
.hub-layout { margin-top: 12px; gap: 16px; }
.hub-main .workspace-panel { padding: 12px 20px 18px; }
.hub-side { gap: 12px; }
.hub-card { padding: 14px 16px; }
/* Sharing a save uses the whole width; the side cards are on the other tabs. */
.hub-layout.is-wide { grid-template-columns: minmax(0, 1fr); }
.hub-layout.is-wide .hub-side { display: none; }
/* Side cards: short when the namecard has not synced yet. */
.hub-card .namecard-frame { min-height: 0; padding: 10px; }
.hub-card .namecard-frame img { max-height: 260px; }
.namecard-empty { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 12px; text-align: left; padding: 6px 4px; max-width: none; }
.namecard-empty > span { grid-row: span 2; width: 38px; height: 38px; margin: 0; border-radius: 10px; }
.namecard-empty svg { width: 20px; height: 20px; }
.namecard-empty h3 { font-size: 14px; line-height: 1.4; }
.namecard-empty p { font-size: 12px; line-height: 1.5; margin: 0; }
.namecard-note { margin-top: 6px; font-size: 12px; }
.hub-rules ul { gap: 3px; font-size: 12.5px; }
.hub-sync, .hub-security { padding-top: 10px; padding-bottom: 10px; }
.hub-rules { padding-top: 10px; padding-bottom: 10px; }
.hub-rules summary { cursor: pointer; font-weight: 600; }
