/* Páginas públicas dos nodes dos membros (/members e /node/<pk>), 14/11/2026.
   Usa os tokens do styles.css (--bg, --surface, --text, --muted, --accent, --brand) e acrescenta os daqui. */
:root {
    --np-btc: #f7931a;
    --np-tor: #b494ff;
    --np-clear: #4ee0c1;
    --np-club: #ffcc48;
    --np-line: rgba(124, 154, 191, 0.16);
    --np-card: rgba(12, 22, 40, 0.86);
    --np-card-hi: rgba(18, 31, 55, 0.95);
    --np-mono: ui-monospace, 'SFMono-Regular', Consolas, 'Liberation Mono', monospace;
}

.np-ico { width: 1.05em; height: 1.05em; flex: none; vertical-align: -0.16em; }
.np-num { font-variant-numeric: tabular-nums; }

/* ---------- topo da /members ---------- */
.np-hero {
    position: relative; overflow: hidden;
    display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 18px 24px; align-items: center;
    padding: clamp(18px, 3vw, 28px) clamp(18px, 3.2vw, 32px);
    border: 1px solid var(--border); border-radius: var(--radius-xl);
    background:
        radial-gradient(120% 140% at 100% 0%, rgba(247, 147, 26, 0.16), transparent 55%),
        radial-gradient(90% 120% at 0% 100%, rgba(78, 224, 193, 0.10), transparent 60%),
        var(--surface-strong);
    box-shadow: var(--shadow-md);
}
.np-eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--np-btc); font-weight: 600;
}
.np-hero h1 {
    margin: 10px 0 10px; font-family: 'Space Grotesk', 'IBM Plex Sans', system-ui, sans-serif;
    font-size: clamp(1.7rem, 3.4vw, 2.4rem); line-height: 1.05; text-wrap: balance;
}
.np-hero h1 em { font-style: normal; color: var(--np-btc); }
.np-hero p { color: var(--muted); max-width: 52ch; margin: 0; line-height: 1.6; }
.np-orbs { width: 100%; height: auto; max-height: 170px; }
.np-orbs circle { transition: transform .25s ease, opacity .25s ease; transform-box: fill-box; transform-origin: center; }
.np-orbs a:hover circle, .np-orbs a:focus-visible circle { transform: scale(1.12); }
.np-orbs a:focus-visible { outline: none; }

.np-stats {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-top: 18px;
}
.np-stats-wide { grid-column: 1 / -1; margin-top: 0; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); }
.np-stat {
    display: flex; flex-direction: column; gap: 4px; padding: 12px 16px;
    border: 1px solid var(--np-line); border-radius: var(--radius-md); background: var(--np-card);
}
.np-stat .np-stat-k { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 0.82rem; }
.np-stat .np-stat-v {
    font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif; font-size: 1.55rem; font-weight: 700; line-height: 1.1;
}
.np-stat small { color: var(--muted); font-size: 0.78rem; }
.np-stat.is-btc .np-stat-k { color: var(--np-btc); }
.np-stat.is-tor .np-stat-k { color: var(--np-tor); }
.np-stat.is-clear .np-stat-k { color: var(--np-clear); }

/* ---------- barra de busca e filtros ---------- */
.np-toolbar {
    display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between;
    margin: 18px 0 14px;
}
.np-search {
    flex: 1 1 260px; display: flex; align-items: center; gap: 10px; padding: 0 14px; min-height: 44px;
    border: 1px solid var(--border); border-radius: 999px; background: var(--np-card); color: var(--muted);
}
.np-search input {
    flex: 1; min-width: 0; border: 0; background: transparent; color: var(--text); font: inherit; outline: none;
}
.np-search:focus-within { border-color: var(--np-btc); }
.np-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.np-chip {
    display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 0 14px;
    border: 1px solid var(--border); border-radius: 999px; background: transparent; color: var(--muted);
    font: inherit; font-size: 0.86rem; cursor: pointer;
}
.np-chip:hover { color: var(--text); border-color: var(--border-strong); }
.np-chip[aria-pressed="true"] { color: #10131a; background: var(--np-club); border-color: var(--np-club); font-weight: 600; }
.np-chip:focus-visible, .np-search input:focus-visible, .np-copy:focus-visible { outline: 2px solid var(--np-btc); outline-offset: 2px; }
.np-sort {
    min-height: 38px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--border);
    background: var(--np-card); color: var(--text); font: inherit; font-size: 0.86rem;
}

/* ---------- cartões dos nodes ---------- */
.np-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 268px), 1fr)); gap: 14px; }
.np-card {
    --c: var(--np-btc);
    position: relative; display: flex; flex-direction: column; gap: 14px; padding: 18px 18px 16px;
    border: 1px solid var(--np-line); border-radius: var(--radius-lg); text-decoration: none; color: var(--text);
    background:
        radial-gradient(140% 90% at 100% 0%, color-mix(in srgb, var(--c) 18%, transparent), transparent 60%),
        var(--np-card);
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
    overflow: hidden;
}
.np-card::before {
    content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--c); opacity: .9;
}
.np-card:hover, .np-card:focus-visible {
    transform: translateY(-3px); border-color: color-mix(in srgb, var(--c) 55%, transparent);
    box-shadow: 0 18px 40px rgba(0, 0, 0, .35), 0 0 0 1px color-mix(in srgb, var(--c) 25%, transparent);
    outline: none;
}
.np-card-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.np-avatar {
    flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px;
    background: linear-gradient(140deg, var(--c), color-mix(in srgb, var(--c) 45%, #08111f));
    color: #08111f; font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 1.2rem;
    box-shadow: 0 6px 18px color-mix(in srgb, var(--c) 35%, transparent);
}
.np-card-name { min-width: 0; }
.np-card-name h3 {
    margin: 0; font-size: 1.02rem; line-height: 1.25; overflow-wrap: anywhere;
    font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
}
.np-card-name span { color: var(--muted); font-size: 0.76rem; font-family: var(--np-mono); }
.np-rank {
    margin-left: auto; align-self: flex-start; font-size: 0.72rem; font-weight: 700; color: var(--muted);
    padding: 3px 8px; border-radius: 999px; border: 1px solid var(--np-line);
}
.np-rank.is-top { color: #10131a; background: var(--np-club); border-color: var(--np-club); }
.np-cap { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 10px; }
.np-cap strong { font-family: 'Space Grotesk', sans-serif; font-size: 1.45rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.np-cap > span { color: var(--muted); font-size: 0.78rem; white-space: nowrap; }
.np-bar { height: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.06); overflow: hidden; }
.np-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, color-mix(in srgb, var(--c) 60%, #ffffff), var(--c)); }
.np-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.np-tag {
    display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 999px;
    font-size: 0.75rem; background: rgba(255, 255, 255, 0.05); color: var(--muted); border: 1px solid transparent;
}
.np-tag.is-channels { color: var(--text); }
.np-tag.is-tor { color: var(--np-tor); border-color: color-mix(in srgb, var(--np-tor) 35%, transparent); }
.np-tag.is-clear { color: var(--np-clear); border-color: color-mix(in srgb, var(--np-clear) 35%, transparent); }
.np-tag.is-club { color: var(--np-club); border-color: color-mix(in srgb, var(--np-club) 40%, transparent); }
.np-tag.is-member { color: var(--np-btc); border-color: color-mix(in srgb, var(--np-btc) 40%, transparent); }

.np-empty[hidden], .np-card[hidden] { display: none; }
.np-empty { padding: 28px; text-align: center; color: var(--muted); border: 1px dashed var(--border); border-radius: var(--radius-lg); }

.np-idle { margin-top: 18px; border: 1px solid var(--np-line); border-radius: var(--radius-lg); background: var(--np-card); }
.np-idle summary { cursor: pointer; padding: 16px 18px; color: var(--muted); list-style: none; display: flex; gap: 10px; align-items: center; }
.np-idle summary::-webkit-details-marker { display: none; }
.np-idle summary::after { content: "+"; margin-left: auto; font-size: 1.2rem; }
.np-idle[open] summary::after { content: "–"; }
.np-idle-list { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 18px 18px; }
.np-idle-list a { color: var(--text); text-decoration: none; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--np-line); font-size: 0.86rem; }
.np-idle-list a:hover { border-color: var(--np-btc); }

.np-note { margin-top: 14px; color: var(--muted); font-size: 0.82rem; }

/* ---------- página de um node ---------- */
.np-node-hero {
    --c: var(--np-btc);
    position: relative; overflow: hidden; padding: clamp(22px, 4vw, 38px);
    border: 1px solid color-mix(in srgb, var(--c) 35%, var(--border)); border-radius: var(--radius-xl);
    background:
        radial-gradient(90% 160% at 0% 0%, color-mix(in srgb, var(--c) 30%, transparent), transparent 55%),
        radial-gradient(80% 120% at 100% 100%, rgba(78, 224, 193, 0.08), transparent 60%),
        var(--surface-strong);
    box-shadow: var(--shadow-md);
}
.np-back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; font-size: 0.86rem; }
.np-back:hover { color: var(--text); }
.np-node-id { display: flex; align-items: center; gap: 18px; margin-top: 14px; flex-wrap: wrap; }
.np-node-id .np-avatar { width: 72px; height: 72px; border-radius: 22px; font-size: 2rem; }
.np-node-id h1 {
    margin: 0; font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif; font-size: clamp(1.8rem, 4vw, 2.7rem);
    line-height: 1.05; overflow-wrap: anywhere;
}
.np-node-id .np-tags { margin-top: 10px; }
.np-pubkey {
    display: flex; align-items: center; gap: 10px; margin-top: 18px; padding: 10px 12px;
    border-radius: var(--radius-sm); background: rgba(0, 0, 0, 0.25); border: 1px solid var(--np-line);
    font-family: var(--np-mono); font-size: 0.82rem; color: var(--muted); overflow-wrap: anywhere;
}
.np-pubkey code { flex: 1; min-width: 0; color: var(--text); }
.np-copy {
    flex: none; width: auto; display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 10px;
    border: 1px solid var(--border); background: var(--np-card-hi); color: var(--text); font: inherit; font-size: 0.8rem; cursor: pointer;
}
.np-copy:hover { border-color: var(--np-btc); color: var(--np-btc); }

.np-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-top: 18px; }
.np-kpi {
    --k: var(--np-btc);
    display: flex; flex-direction: column; gap: 8px; padding: 16px; border-radius: var(--radius-md);
    border: 1px solid var(--np-line); background: var(--np-card);
}
.np-kpi-ico {
    display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
    background: color-mix(in srgb, var(--k) 16%, transparent); color: var(--k);
}
.np-kpi-ico .np-ico { width: 18px; height: 18px; }
.np-kpi b { font-family: 'Space Grotesk', sans-serif; font-size: 1.35rem; font-variant-numeric: tabular-nums; line-height: 1.1; }
.np-kpi span { color: var(--muted); font-size: 0.8rem; }
.np-kpi.k-teal { --k: var(--np-clear); }
.np-kpi.k-violet { --k: var(--np-tor); }
.np-kpi.k-gold { --k: var(--np-club); }
.np-kpi.k-rose { --k: #ff8fab; }
.np-kpi.k-sky { --k: #7cc4ff; }

.np-cols { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 16px; margin-top: 16px; align-items: start; }
.np-panel {
    padding: 20px; border: 1px solid var(--np-line); border-radius: var(--radius-lg); background: var(--np-card);
}
.np-panel + .np-panel { margin-top: 16px; }
.np-panel h2 {
    display: flex; align-items: center; gap: 10px; margin: 0 0 14px; font-size: 1.05rem;
    font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
}
.np-panel h2 .np-ico { color: var(--np-btc); width: 20px; height: 20px; }
.np-panel h2 small { margin-left: auto; color: var(--muted); font-weight: 400; font-size: 0.76rem; font-family: 'IBM Plex Sans', sans-serif; }

.np-sockets { display: flex; flex-direction: column; gap: 8px; }
.np-socket {
    display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm);
    border: 1px solid var(--np-line); background: rgba(0, 0, 0, 0.18);
}
.np-socket code { flex: 1; min-width: 0; font-family: var(--np-mono); font-size: 0.8rem; overflow-wrap: anywhere; }

.np-fees { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.np-fee { padding: 12px; border-radius: var(--radius-sm); background: rgba(255, 255, 255, 0.03); border: 1px solid var(--np-line); }
.np-fee span { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 0.78rem; }
.np-fee b { display: block; margin-top: 6px; font-family: 'Space Grotesk', sans-serif; font-size: 1.25rem; font-variant-numeric: tabular-nums; }
.np-fee small { color: var(--muted); font-size: 0.76rem; }
.np-hist { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; align-items: end; height: 120px; padding-top: 6px; }
.np-hist div { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; height: 100%; min-width: 0; }
.np-hist i { display: block; width: 100%; border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, var(--np-btc), color-mix(in srgb, var(--np-btc) 40%, transparent)); min-height: 2px; }
.np-hist b { font-size: 0.7rem; color: var(--text); font-variant-numeric: tabular-nums; }
.np-hist-labels { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; margin-top: 6px; }
.np-hist-labels span { font-size: 0.62rem; color: var(--muted); text-align: center; overflow-wrap: anywhere; }

.np-peers { display: flex; flex-direction: column; gap: 10px; }
.np-peer { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; align-items: center; }
.np-peer-name { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 0.9rem; }
.np-peer-name a, .np-peer-name span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); text-decoration: none; }
.np-peer-name a:hover { color: var(--np-btc); }
.np-peer-val { color: var(--muted); font-size: 0.8rem; font-variant-numeric: tabular-nums; text-align: right; }
.np-peer .np-bar { grid-column: 1 / -1; height: 5px; }
.np-peer .np-bar i { background: linear-gradient(90deg, rgba(78, 224, 193, .5), var(--np-clear)); }
.np-peer.is-member .np-bar i { background: linear-gradient(90deg, rgba(247, 147, 26, .5), var(--np-btc)); }

.np-contacts { display: flex; flex-direction: column; gap: 8px; }
.np-contact {
    display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--radius-sm);
    border: 1px solid var(--np-line); background: rgba(0, 0, 0, 0.18); color: var(--text); text-decoration: none; min-width: 0;
}
a.np-contact:hover { border-color: var(--np-btc); }
.np-contact-ico { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; }
.np-contact-ico .np-ico { width: 18px; height: 18px; }
.np-contact.c-telegram .np-contact-ico { background: rgba(42, 171, 238, .16); color: #4cc0f5; }
.np-contact.c-x .np-contact-ico { background: rgba(255, 255, 255, .08); color: #fff; }
.np-contact.c-nostr .np-contact-ico { background: rgba(180, 148, 255, .16); color: var(--np-tor); }
.np-contact div { min-width: 0; }
.np-contact strong { display: block; font-size: 0.82rem; color: var(--muted); font-weight: 500; }
.np-contact p { margin: 2px 0 0; font-size: 0.9rem; overflow-wrap: anywhere; }

.np-facts { display: grid; grid-template-columns: auto 1fr; gap: 10px 14px; margin: 0; font-size: 0.88rem; }
.np-facts dt { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.np-facts dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
.np-services { font-size: 0.92rem; line-height: 1.6; overflow-wrap: anywhere; }
.np-services :first-child { margin-top: 0; }
.np-services a { color: var(--np-btc); }

.np-callout {
    margin: 22px 0 28px; padding: 16px 18px; border-radius: var(--radius-lg);
    border: 1px solid color-mix(in srgb, var(--np-club) 35%, transparent);
    background: linear-gradient(120deg, rgba(255, 204, 72, .10), rgba(247, 147, 26, .06));
    display: flex; gap: 14px; align-items: center; flex-wrap: wrap;
}
.np-callout p { margin: 0; flex: 1 1 260px; color: var(--text); font-size: 0.92rem; }
.np-callout a {
    display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px;
    background: var(--np-club); color: #10131a; font-weight: 700; text-decoration: none; font-size: 0.88rem;
}

.np-warn {
    margin-top: 14px; padding: 12px 14px; border-radius: var(--radius-sm); font-size: 0.86rem;
    border: 1px solid rgba(255, 125, 125, .35); background: rgba(255, 125, 125, .08); color: #ffc2c2;
}

@media (max-width: 900px) {
    .np-hero { grid-template-columns: 1fr; }
    .np-orbs { max-height: 150px; }
    .np-cols { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .np-fees { grid-template-columns: 1fr; }
    .np-pubkey { flex-wrap: wrap; }
    .np-pubkey code { flex: 1 1 100%; word-break: break-all; }
    .np-node-id { gap: 12px; }
    .np-node-id .np-avatar { width: 56px; height: 56px; font-size: 1.6rem; border-radius: 18px; }
    .np-chips .np-chip { width: auto; flex: 0 0 auto; }
    .np-stats, .np-stats-wide, .np-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
    .np-stat, .np-kpi { padding: 12px; }
    .np-stat .np-stat-v { font-size: 1.3rem; }
    .np-kpi b { font-size: 1.15rem; }
    .np-kpi-ico { width: 28px; height: 28px; }
    .np-socket { flex-wrap: wrap; }
    .np-socket code { flex: 1 1 100%; order: 3; word-break: break-all; }
    .np-socket .np-copy { margin-left: auto; }
    .np-hist-labels span { font-size: 0.55rem; }
}
@media (prefers-reduced-motion: reduce) {
    .np-card, .np-orbs circle { transition: none; }
    .np-card:hover { transform: none; }
}
