:root {
  color-scheme: light;
  --navy: #050e19; --ink: #142635; --muted: #506475; --line: #cdd9db; --paper: #f4f6f4;
  --blue: #125b78; --cyan: #a3e4f6; --mono: "IBM Plex Mono", Consolas, "Liberation Mono", monospace;
  --sans: Inter, "Segoe UI", Arial, sans-serif; --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; min-width: 0; color: var(--ink); background: var(--paper); font: 1rem/1.5 var(--sans); }
[hidden] { display: none !important; }
button, input { font: inherit; }
button, summary { cursor: pointer; }
a { color: var(--blue); text-underline-offset: .22em; }
button { color: inherit; }
button:disabled { cursor: wait; }
:focus-visible { outline: 3px solid #b85a12; outline-offset: 3px; }
.mast :focus-visible, .hero :focus-visible { outline-color: var(--cyan); }
.skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.skip:focus { position: fixed; inset: .5rem auto auto .5rem; z-index: 5; padding: .6rem 1rem; background: white; }
.wrap { width: min(100% - clamp(2rem, 9vw, 9rem), 75rem); margin-inline: auto; }
.mast, .hero { color: #f7fafb; background: var(--navy); }
.top, .footer-inner, .section-head, .status-line, .dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.top { min-height: 4.1rem; border-bottom: 1px solid #293642; }
.brand, .footer-name { display: inline-flex; align-items: center; gap: .5rem; }
.brand { min-height: 44px; color: #f6fafe; font-size: 1.38rem; font-weight: 700; letter-spacing: -.055em; text-decoration: none; }
.brand i, .footer-name i { display: inline-block; width: 1.45rem; height: 1.35rem; background: var(--cyan); clip-path: polygon(0 0,24% 0,51% 65%,77% 0,100% 0,56% 100%,44% 100%); }
.brand span { margin-left: .36rem; border-left: 1px solid #476071; padding-left: .75rem; color: #b8cbd8; font-size: .88rem; letter-spacing: 0; font-weight: 500; }
nav { display: flex; align-self: stretch; gap: clamp(1rem, 3vw, 2.2rem); }
nav a { display: grid; align-items: center; border-bottom: 2px solid transparent; margin-top: 2px; color: #c6d5df; font-size: .92rem; text-decoration: none; }
nav a:hover, nav a[aria-current] { color: white; }
nav a[aria-current] { border-color: var(--cyan); }
.hero { overflow: hidden; }
.hero-inner { position: relative; isolation: isolate; }
.field { position: absolute; z-index: -1; right: -2%; top: 50%; width: min(60%, 47rem); height: 176%; object-fit: cover; object-position: center; transform: translateY(-50%); mask-image: linear-gradient(90deg, transparent, #000 22%, #000 90%, transparent); }
.hero-copy { position: relative; width: fit-content; max-width: 64%; padding: clamp(2rem, 3vw, 2.8rem) 0 2.5rem; }
.network { display: inline-flex; align-items: center; gap: .55rem; margin: 0 0 .65rem; color: #b9e7f5; font: 600 .78rem/1.5 var(--mono); letter-spacing: .035em; }
.network-mark { width: .58rem; height: .58rem; border: 1px solid #a7deef; transform: rotate(45deg); }
h1, h2, p, dl, dd { margin: 0; }
h1 { color: #f8fbfc; font: 400 clamp(3rem, 5.6vw, 5rem)/1.03 var(--serif); letter-spacing: -.055em; }
#intro { margin: .7rem 0 1.25rem; max-width: 42ch; color: #c3d0da; font-size: 1.04rem; }
.connect { display: inline-flex; align-items: center; justify-content: space-between; gap: 1.25rem; min-height: 44px; padding: .5rem .95rem; background: var(--cyan); border: 0; border-radius: 4px; color: #081c29; font-weight: 650; font-size: .92rem; }
.connect:hover { background: #d0f3fc; }
.connect span { font-size: 1.1rem; }
.content { min-height: 34vh; padding-bottom: 2.75rem; }
.status-line { min-height: 3.75rem; font-size: .86rem; flex-wrap: wrap; gap: .35rem .8rem; }
.status { display: inline-flex; align-items: center; gap: .5rem; font-weight: 650; }
.status i { width: .59rem; height: .59rem; background: #657786; border-radius: 50%; }
.status[data-state="ready"] i { background: #1b7c58; box-shadow: 0 0 0 3px #d4ebdd; }
.status[data-state="paused"] i, .status[data-state="waiting"] i { background: #ae7319; }
.muted, .metadata, .chart-caption, .card p, .dialog-note { color: var(--muted); }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: white; border: 1px solid var(--line); border-top: 3px solid #486d7f; border-radius: 4px; padding: 1.4rem 0; }
.metrics > div { min-width: 0; padding: 0 clamp(1rem, 2vw, 2rem); }
.metrics > div + div { border-left: 1px solid var(--line); }
.metrics dt { color: #344f61; font-size: .9rem; font-weight: 650; }
.metrics dd { margin: .3rem 0 .22rem; font: 500 clamp(1.7rem, 2.6vw, 2.65rem)/1.17 var(--sans); letter-spacing: -.055em; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.metrics .unit { margin-left: .35rem; font-size: .85rem; letter-spacing: 0; color: var(--muted); }
.metrics small { color: var(--muted); font-size: .79rem; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.85fr) minmax(16rem, 1fr); align-items: start; gap: 1.15rem; margin-top: 1.25rem; }
.side { display: grid; gap: 1.15rem; }
.card { min-width: 0; background: #fff; border: 1px solid var(--line); border-radius: 5px; padding: clamp(1rem, 2vw, 1.6rem); }
h2 { font: 400 clamp(1.55rem, 2.4vw, 2.1rem)/1.14 var(--serif); letter-spacing: -.045em; }
.card p { margin-top: .45rem; font-size: .91rem; }
.section-head { align-items: flex-start; }
.section-head > a { display: inline-flex; align-items: center; gap: .4rem; flex: none; min-height: 40px; font-size: .91rem; font-weight: 650; }
.switcher { display: inline-flex; flex: none; gap: .12rem; padding: .18rem; border: 1px solid #b7c9cf; border-radius: 5px; background: #f2f5f5; }
.switcher button { border: 0; background: transparent; min-height: 34px; padding: .3rem .68rem; border-radius: 3px; color: #324b59; font: 600 .83rem var(--mono); }
.switcher button[aria-pressed="true"] { background: #183947; color: white; }
.switcher button:hover:not([aria-pressed="true"]) { background: #dbe8ea; }
.plot { margin-top: 1.35rem; height: clamp(11.5rem, 19vw, 15rem); }
.plot canvas { display: block; width: 100%; height: 100%; }
.card .chart-caption { margin: .5rem 0 0; min-height: 1.5em; font-size: .8rem; }
.chart-data { border-top: 1px solid var(--line); margin-top: .8rem; }
.chart-data summary { display: list-item; width: fit-content; padding: .65rem 0 .15rem; color: var(--blue); font-weight: 600; font-size: .85rem; }
.chart-data .table-scroll { max-height: 17rem; }
.lookup-card { background: #eaf2f4; border-color: #beccd1; }
.lookup label { display: block; margin: 1rem 0 .35rem; color: #2c4350; font-size: .84rem; font-weight: 650; }
.lookup-field { display: flex; align-items: stretch; }
.lookup-field input { width: 0; flex: 1; min-width: 0; min-height: 45px; background: #fff; border: 1px solid #879da7; border-right: 0; border-radius: 3px 0 0 3px; padding: .55rem .75rem; color: var(--ink); font: .92rem var(--mono); }
.lookup-field input::placeholder { color: #657785; }
.lookup-field button { min-width: 46px; min-height: 45px; border: 0; padding: .45rem .85rem; border-radius: 0 3px 3px 0; background: #153748; color: #fff; font-weight: 600; }
.lookup-field button:hover { background: #25566b; }
.lookup-field button span { font-size: 1.15rem; }
.card .invalid { color: #8c341a; }
.terms dl { display: grid; margin-top: .65rem; }
.terms dl > div, .connection dd, .pager { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.terms dl > div { min-height: 2.05rem; padding: .22rem 0; font-size: .86rem; }
.terms dl > div + div { border-top: 1px solid #e1e7e8; }
.terms dt { color: var(--muted); }
.terms dd { font: 600 .83rem var(--mono); }
.history { margin-top: 1.2rem; }
.history .section-head { align-items: center; margin-bottom: .6rem; }
.table-scroll { overflow: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: .9rem; }
th, td { padding: .65rem .55rem; border-bottom: 1px solid #e0e7e8; vertical-align: top; }
th { background: #f3f6f6; color: #425965; font-size: .78rem; font-weight: 650; }
td { font-variant-numeric: tabular-nums; }
tbody tr:last-child td { border-bottom: 0; }
td code, .hash { font: .84rem/1.55 var(--mono); }
.hash { color: #385a6c; }
.hash summary { width: fit-content; white-space: nowrap; }
.hash code { display: block; margin: .4rem 0; max-width: 28ch; overflow-wrap: anywhere; white-space: normal; }
.amount { text-align: right; white-space: nowrap; }
.cell-label { display: none; }
.pill { display: inline-block; padding: .15rem .52rem; border-radius: 3px; color: #365365; background: #e9eff2; font-size: .78rem; font-weight: 650; }
.pill.credited { color: #176146; background: #e1f1e7; }
.pill.pending { color: #76551a; background: #faf0d9; }
.empty { padding: 1.2rem .2rem .55rem; border-top: 1px solid var(--line); }
.metadata, .pager { font-size: .84rem; }
.pager:not(:empty) { margin-top: .8rem; }
.pager a { display: inline-flex; align-items: center; min-height: 44px; }
.full-list, .miner-form, #miner-results { margin-top: 1.5rem; }
.miner-form { max-width: 45rem; }
.miner-form label { margin-top: 0; }
.notice { margin-top: 1rem; border-left: 3px solid #b07b2c; padding: .7rem 1rem; color: #644919; background: #fff3d9; }
footer { border-top: 1px solid #c8d3d5; }
.footer-inner { min-height: 5rem; color: #465d69; font-size: .9rem; }
.footer-name { font-weight: 650; }
.footer-name i { width: .95rem; height: .9rem; background: #406474; }
.footer-inner a { display: inline-flex; align-items: center; gap: .25rem; min-height: 44px; }
dialog { width: min(30rem, calc(100% - 2rem)); padding: clamp(1.25rem, 4vw, 2rem); border-radius: 6px; background: #fff; color: var(--ink); border: 1px solid #b3c3ca; box-shadow: 0 1rem 4rem #00101c33; }
dialog::backdrop { background: #03101dba; }
.dialog-head button { min-width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 4px; background: #fff; font-size: 1.5rem; line-height: 1; }
dialog p { margin-top: .8rem; }
.connection { margin-top: 1.2rem; }
.connection > div { padding: .7rem 0; border-top: 1px solid var(--line); }
.connection dt { color: var(--muted); font-size: .84rem; }
.connection dd { margin-top: .25rem; }
code { font-family: var(--mono); }
.connection code { overflow-wrap: anywhere; font-size: .92rem; }
#copy-endpoint { min-height: 40px; padding: .3rem .7rem; border: 1px solid #93a9b0; border-radius: 3px; background: #edf5f6; }
.dialog-note, #copy-status { font-size: .88rem; }
#copy-status:empty { margin: 0; }
@media (max-width: 52rem) {
  .workspace { grid-template-columns: minmax(0, 1.6fr) minmax(13.5rem, 1fr); }
  .chart-card .section-head { flex-wrap: wrap; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 1.15rem; }
  .metrics > div:nth-child(3) { border-left: 0; }
}
@media (max-width: 40rem) {
  .top { flex-wrap: wrap; gap: 0 .8rem; }
  .brand { min-height: 3.2rem; }
  nav { width: 100%; justify-content: space-between; gap: .55rem; }
  nav a { min-height: 44px; font-size: .86rem; }
  .field { width: 82%; right: -25%; height: 155%; opacity: .57; mask-image: linear-gradient(90deg,transparent,#000 55%); }
  .hero-copy { max-width: 88%; padding: 1.8rem 0; }
  #intro { max-width: 28ch; }
  .workspace { grid-template-columns: minmax(0, 1fr); }
  .status-line { padding: .65rem 0; }
  .metrics dd { font-size: 1.8rem; }
  .metrics small { font-size: .75rem; }
  .section-head { gap: .6rem; }
  .chart-card .section-head { align-items: center; }
  .switcher button { min-height: 38px; }
  .history table, .history tbody { display: block; }
  .history thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .history tbody tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem .75rem; border-top: 1px solid var(--line); padding: .75rem 0; }
  .history tbody tr:last-child { padding-bottom: 0; }
  .history td { min-width: 0; padding: 0; border: 0; text-align: left; overflow-wrap: anywhere; white-space: normal; }
  .history .hash summary { max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
  .cell-label { display: block; margin-bottom: .14rem; color: var(--muted); font-size: .76rem; }
  .miner-form .lookup-field button { font-size: .87rem; }
}
