  *, *::before, *::after { box-sizing: border-box; }

  :root {
    --ink: #070809;
    --ink-raised: #101214;
    --panel: #141719;
    --row: #191d20;
    --row-alt: #111416;
    --paper: #e8e3d6;
    --paper-dim: #aaa79d;
    --paper-muted: #75746e;
    --gold: #d7c27d;
    --gold-soft: rgba(215, 194, 125, 0.18);
    --line: rgba(232, 227, 214, 0.13);
    --green: #80b796;
    --blue: #86a9c9;
    --red: #c78378;
  }

  html, body {
    margin: 0;
    min-height: 100%;
    background: var(--ink);
    color: var(--paper);
  }

  body {
    font-family: "JetBrains Mono", "SF Mono", Menlo, Consolas, monospace;
    font-size: 14px;
    line-height: 1.45;
    letter-spacing: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }

  button, input, select {
    font: inherit;
    letter-spacing: 0;
  }

  a { color: inherit; }

  .shell {
    width: min(100%, 1680px);
    min-height: 100svh;
    margin: 0 auto;
    padding: 22px 28px 34px;
  }

  .topbar {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) auto;
    align-items: center;
    gap: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
  }

  .brand {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 13px;
  }

  .brand img {
    width: 31px;
    height: 31px;
    flex: 0 0 auto;
  }

  .brand h1 {
    margin: 0;
    font-family: "EB Garamond", Georgia, serif;
    font-size: 33px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0;
  }

  .brand .sub {
    margin: 2px 0 0;
    color: var(--paper-dim);
    font-size: 12px;
    letter-spacing: 0;
  }

  .links {
    display: grid;
    grid-template-columns: repeat(2, max-content);
    align-items: center;
    justify-content: end;
    gap: 7px 10px;
  }

  .links a,
  .links button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 15px;
    border: 1px solid rgba(215, 194, 125, 0.58);
    border-radius: 4px;
    background: var(--gold-soft);
    color: var(--paper);
    cursor: pointer;
    text-decoration: none;
  }

  .links a:hover,
  .links a:focus-visible,
  .links button:hover,
  .links button:focus-visible {
    border-color: var(--gold);
    background: rgba(215, 194, 125, 0.27);
    outline: none;
  }

  .links button {
    background: transparent;
  }

  .subscribe-note {
    grid-column: 1 / -1;
    justify-self: end;
    color: var(--paper-muted);
    font-size: 11px;
    text-align: right;
  }

  .summary {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    margin-top: 14px;
  }

  .view-nav {
    display: inline-flex;
    height: 36px;
    margin-top: 14px;
    border: 1px solid var(--line);
    border-radius: 4px;
    overflow: hidden;
    background: var(--ink-raised);
  }

  .view-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 104px;
    padding: 0 14px;
    border-right: 1px solid var(--line);
    color: var(--paper-dim);
    text-decoration: none;
  }

  .view-nav a:last-child {
    border-right: 0;
  }

  .view-nav a[aria-current="page"] {
    background: var(--gold-soft);
    color: var(--gold);
  }

  .stat {
    min-width: 118px;
    min-height: 44px;
    padding: 8px 12px;
    border: 1px solid var(--line);
    margin-right: -1px;
    margin-bottom: -1px;
    background: rgba(20, 23, 25, 0.62);
  }

  .stat .label {
    color: var(--paper-muted);
    font-size: 10px;
    text-transform: uppercase;
  }

  .stat .value {
    margin-top: 3px;
    color: var(--paper);
    font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 20px;
    font-weight: 600;
    line-height: 1;
  }

  .toolbar {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) auto auto auto;
    gap: 10px;
    margin-top: 14px;
    align-items: center;
  }

  .search,
  .sort {
    min-height: 36px;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--ink-raised);
    color: var(--paper);
  }

  .search {
    padding: 0 13px;
  }

  .search::placeholder {
    color: var(--paper-muted);
    opacity: 1;
  }

  .sort {
    min-width: 170px;
    padding: 0 11px;
  }

  .segments {
    display: inline-flex;
    height: 36px;
    border: 1px solid var(--line);
    border-radius: 4px;
    overflow: hidden;
    background: var(--ink-raised);
  }

  .segments button {
    min-width: 86px;
    border: 0;
    border-right: 1px solid var(--line);
    background: transparent;
    color: var(--paper-dim);
    cursor: pointer;
  }

  .segments button:last-child {
    border-right: 0;
  }

  .segments button[aria-pressed="true"] {
    background: var(--gold-soft);
    color: var(--gold);
  }

  .board {
    margin-top: 18px;
  }

  .feed-list {
    border: 1px solid var(--line);
    background: var(--line);
  }

  .list-item,
  .profile-row,
  .intel-row {
    display: grid;
    grid-template-columns: minmax(170px, 0.8fr) minmax(280px, 1.5fr) minmax(180px, 220px) minmax(150px, 240px);
    gap: 13px;
    align-items: center;
    min-height: 72px;
    padding: 11px 13px;
    border-bottom: 1px solid var(--line);
    background: var(--ink-raised);
    cursor: pointer;
  }

  .list-header {
    display: grid;
    grid-template-columns: minmax(170px, 0.8fr) minmax(280px, 1.5fr) minmax(180px, 220px) minmax(150px, 240px);
    gap: 13px;
    align-items: center;
    min-height: 34px;
    padding: 0 13px;
    border-bottom: 1px solid var(--line);
    background: #0d0f10;
    color: var(--paper-muted);
    font-size: 10px;
    text-transform: uppercase;
  }

  .list-header span:last-child {
    text-align: right;
  }

  .intel-row {
    cursor: default;
  }

  .list-item:nth-child(even),
  .profile-row:nth-child(even),
  .intel-row:nth-child(even) {
    background: var(--row-alt);
  }

  .list-item:last-child,
  .profile-row:last-child,
  .intel-row:last-child {
    border-bottom: 0;
  }

  .list-item:hover,
  .profile-row:hover {
    background: #202428;
  }

  .list-item.is-selected,
  .profile-row.is-selected {
    outline: 1px solid var(--gold);
    outline-offset: -1px;
    background: #24251f;
  }

  .list-item:focus-visible,
  .profile-row:focus-visible {
    outline: 1px solid var(--gold);
    outline-offset: -1px;
    background: #202428;
  }

  .list-main,
  .list-metric,
  .profile-metric,
  .intel-main {
    display: grid;
    gap: 4px;
    min-width: 0;
  }

  .metric-label {
    display: none;
  }

  .list-actions,
  .profile-actions,
  .intel-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    align-items: center;
  }

  .list-actions .view,
  .profile-actions .view,
  .intel-actions .view {
    min-width: 64px;
  }

  .modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10;
    display: grid;
    place-items: center;
    padding: 22px;
    background: rgba(7, 8, 9, 0.78);
  }

  .modal-panel {
    width: min(960px, 100%);
    max-height: min(760px, calc(100svh - 44px));
    overflow: auto;
    border: 1px solid var(--gold);
    background: var(--ink-raised);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.44);
  }

  .modal-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: start;
    padding: 15px;
    border-bottom: 1px solid var(--line);
    background: #0d0f10;
  }

  .modal-close {
    min-height: 31px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: transparent;
    color: var(--paper-dim);
    cursor: pointer;
  }

  .modal-close:hover,
  .modal-close:focus-visible {
    border-color: var(--gold);
    color: var(--paper);
    outline: none;
  }

  .modal-body {
    display: grid;
    gap: 15px;
    padding: 15px;
  }

  .modal-summary {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 0.45fr);
    gap: 16px;
    align-items: start;
  }

  .modal-heading {
    display: grid;
    gap: 6px;
  }

  .modal-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }

  .modal-main {
    display: grid;
    gap: 12px;
    min-width: 0;
  }

  body.modal-open {
    overflow: hidden;
  }

  .detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    border: 1px solid var(--line);
    background: var(--line);
  }

  .detail {
    min-width: 0;
    padding: 10px;
    background: var(--row-alt);
  }

  .detail span {
    display: block;
    color: var(--paper-muted);
    font-size: 10px;
    text-transform: uppercase;
  }

  .detail strong {
    display: block;
    overflow: hidden;
    margin-top: 4px;
    color: var(--paper);
    font-size: 12px;
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .modal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }

  .feedback-form {
    display: grid;
    gap: 12px;
  }

  .feedback-form label {
    display: grid;
    gap: 5px;
    color: var(--paper-dim);
    font-size: 11px;
    text-transform: uppercase;
  }

  .feedback-form textarea,
  .feedback-form input {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: #0d0f10;
    color: var(--paper);
  }

  .feedback-form textarea {
    min-height: 132px;
    resize: vertical;
    padding: 10px;
  }

  .feedback-form input {
    min-height: 36px;
    padding: 0 10px;
  }

  .feedback-kind label {
    min-width: 110px;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--paper-dim);
    text-transform: none;
    cursor: pointer;
  }

  .feedback-kind input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
  }

  .feedback-kind label:has(input:checked) {
    background: var(--gold-soft);
    color: var(--gold);
  }

  .feedback-status {
    min-height: 18px;
    color: var(--paper-muted);
    font-size: 12px;
  }

  .honeypot {
    display: none;
  }

  .project {
    display: grid;
    gap: 3px;
  }

  .project strong,
  .proposal strong {
    display: block;
    color: var(--paper);
    font-weight: 600;
  }

  .muted,
  .proposal span,
  .time span,
  .activity span {
    color: var(--paper-muted);
    font-size: 12px;
  }

  .badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 25px;
    padding: 0 9px;
    border: 1px solid var(--line);
    border-radius: 4px;
    color: var(--paper);
    white-space: nowrap;
  }

  .badge.pending {
    border-color: rgba(134, 169, 201, 0.45);
    color: var(--blue);
  }

  .badge.stake {
    border-color: rgba(128, 183, 150, 0.45);
    color: var(--green);
  }

  .badge.ico {
    border-color: rgba(215, 194, 125, 0.48);
    color: var(--gold);
  }

  .status-pill {
    display: inline-flex;
    align-items: center;
    min-height: 21px;
    padding: 0 7px;
    border: 1px solid var(--line);
    border-radius: 4px;
    color: var(--paper-muted);
    font-size: 11px;
    white-space: nowrap;
  }

  .status-pill.pending {
    border-color: rgba(134, 169, 201, 0.35);
    color: var(--blue);
  }

  .status-pill.completed {
    border-color: rgba(232, 227, 214, 0.24);
    color: var(--paper-dim);
  }

  .time,
  .activity {
    display: grid;
    gap: 5px;
  }

  .bar {
    width: 150px;
    height: 7px;
    overflow: hidden;
    border-radius: 4px;
    background: rgba(232, 227, 214, 0.12);
  }

  .bar span {
    display: block;
    height: 100%;
    width: var(--fill);
    background: var(--green);
  }

  .view {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 31px;
    min-width: 58px;
    padding: 0 10px;
    border: 1px solid var(--gold);
    border-radius: 4px;
    color: var(--gold);
    text-decoration: none;
  }

  .view:hover,
  .view:focus-visible {
    background: var(--gold);
    color: var(--ink);
    outline: none;
  }

  .state-line {
    min-height: 54px;
    display: flex;
    align-items: center;
    padding: 0 14px;
    border-top: 1px solid var(--line);
    color: var(--paper-dim);
  }

  .state-line.error {
    color: var(--red);
  }

  .footerline {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    margin-top: 14px;
    color: var(--paper-muted);
    font-size: 11px;
  }

  .hidden {
    display: none;
  }

  @media (max-width: 980px) {
    .shell {
      padding: 18px 16px 28px;
    }

    .topbar,
    .toolbar {
      grid-template-columns: 1fr;
      align-items: stretch;
    }

    .links {
      justify-content: flex-start;
      justify-items: start;
    }

    .subscribe-note {
      text-align: left;
    }

    .view-nav {
      display: flex;
      width: 100%;
    }

    .view-nav a {
      flex: 1 1 0;
      min-width: 0;
    }

    .segments,
    .sort {
      width: 100%;
    }

    .segments button {
      flex: 1 1 0;
      min-width: 0;
    }

    .list-item,
    .profile-row,
    .intel-row,
    .modal-summary {
      grid-template-columns: 1fr;
    }

    .list-header {
      display: none;
    }

    .metric-label {
      display: block;
    }

    .list-actions,
    .profile-actions,
    .intel-actions {
      justify-content: flex-start;
    }
  }

  @media (max-width: 560px) {
    .brand h1 {
      font-size: 29px;
    }

    .detail-grid {
      grid-template-columns: 1fr;
    }
  }
