/* The Network area (#/network, pages/network.js and pages/network/): sites, the site hub, security, discovery, VPN and domains. Layout only:
   every colour, size and radius is a token from next.css, and every component (buttons, status, chips, link cards, tables, sections, banners)
   is drawn by next.css. No inline styles (style-src 'self'). The site hub reuses the device hub's band (.dhub). */

/* (the bar, the table-row button, the warning word, the "nothing here" line, sub-headings, lists, steps, sub-lines, the form error and the
   banner on a phone are the shared parts in next.css) */
.nw-toolbar { align-items: center; }
.nw-toolbar .searchbox { flex: 1 1 220px; max-width: 380px; }
.nw-chips { display: flex; min-width: 0; max-width: 100%; overflow-x: auto; }
.nw-cellsite { display: inline-flex; align-items: center; gap: var(--s-2); min-width: 0; }
.nw-cellsite > span:last-child { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.nw-cellsite__name { font-weight: 500; }

/* one firewall (Security): its section, the addresses, the alert switch at the foot */
.nw-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: var(--s-5); align-items: start; }
.nw-cards .section__body { display: flex; flex-direction: column; gap: var(--s-4); }
.nw-cardtitle { overflow-wrap: anywhere; }
.nw-cardfoot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-2) var(--s-4); }
.nw-ips { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: var(--s-3); }
.nw-label { display: block; font-size: var(--t-13); color: var(--muted); margin-bottom: var(--s-1); }

/* panels: the paste blocks, long lists */
.nw-list { margin: var(--s-3) 0 0; padding-left: var(--s-5); display: flex; flex-direction: column; gap: 4px; font-size: var(--t-14); max-height: 40vh; overflow: auto; }
.nw-custs { list-style: none; padding: 0; }
.nw-custs li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-2); min-height: var(--h-sm); }
.nw-dialog-more { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-3); margin-top: var(--s-4); padding-top: var(--s-4); border-top: 1px solid var(--line-soft); }

/* forms in the one dialog and drawer: fields one under the other with air between them; the error and the status line */
.sheet__body form[data-nw-form], .sheet__body form[data-nw-cred] { display: flex; flex-direction: column; gap: var(--s-4); }
.nw-msg { margin: 0; font-size: var(--t-14); color: var(--ink-2); min-height: 1.4em; }
.nw-msg:empty { min-height: 0; }
.nw-msg--ok { color: var(--green); font-weight: 500; }
.nw-msg--warn { color: var(--amber); font-weight: 500; }
.nw-msg--crit { color: var(--red); font-weight: 500; }
.nw-credsteps { padding: var(--s-3) var(--s-4); border: 1px solid var(--line-soft); border-radius: var(--r); background: var(--surface-2); }

/* the internet provider */
.nw-isp { display: flex; align-items: center; gap: var(--s-3); }
.nw-isp__name { font-size: var(--t-15); font-weight: 600; }

/* a domain's checks: each finding, the record to add with Copy, the Fix guide */
.nw-finds { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--s-3); }
.nw-find { padding: var(--s-3) var(--s-4); border: 1px solid var(--line-soft); border-radius: var(--r); display: flex; flex-direction: column; gap: var(--s-2); }
.nw-find__head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2) var(--s-3); font-size: var(--t-14); }
.nw-find__text, .nw-find__fix { margin: 0; font-size: var(--t-14); color: var(--ink-2); overflow-wrap: anywhere; }
.nw-rec { display: flex; flex-direction: column; gap: var(--s-1); padding: var(--s-2) var(--s-3); border-radius: var(--r); background: var(--sunk); }
.nw-rec__row { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; align-items: center; gap: var(--s-2); font-size: var(--t-13); }
.nw-rec__row code { overflow-wrap: anywhere; white-space: normal; }
.nw-guide { display: flex; flex-direction: column; gap: var(--s-1); }

@media (max-width: 719px) {
  .nw-toolbar .searchbox { max-width: none; flex-basis: 100%; }
  .nw-cards { grid-template-columns: minmax(0, 1fr); }
  .nw-cards .section__head > .section__title { flex: 1 1 100%; }
  .nw-rec__row { grid-template-columns: minmax(0, 1fr) auto; }
  .nw-rec__row > .muted { grid-column: 1 / -1; }
}
