* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --serif: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #f4f4f4;
  --text: #111111;
  --muted: #6b6b6b;
  --accent: #111111;
  --on-accent: #ffffff;
  --btc: #f7931a;
  --xmr: #f26822;
  --border: #d9d9d9;
  --border-strong: #111111;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

:root.dark {
  color-scheme: dark;
  --bg: #000000;
  --surface: #0d0d0d;
  --surface-2: #161616;
  --text: #f5f5f5;
  --muted: #9a9a9a;
  --accent: #ffffff;
  --on-accent: #000000;
  --btc: #f7931a;
  --xmr: #f26822;
  --border: #2a2a2a;
  --border-strong: #4a4a4a;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

::selection {
  background: var(--accent);
  color: var(--on-accent);
}

a {
  color: var(--text);
  text-decoration: none;
}

a:hover {
  color: var(--accent);
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.rates-box {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.mode-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 36px;
  height: 36px;
  border-radius: 4px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 30;
  text-decoration: none;
}

.mode-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.mode-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.glyph {
  display: block;
}

.glyph-sun {
  display: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  box-shadow:
    0 -7px 0 -2.5px currentColor,
    0 7px 0 -2.5px currentColor,
    -7px 0 0 -2.5px currentColor,
    7px 0 0 -2.5px currentColor,
    -5px -5px 0 -3px currentColor,
    5px -5px 0 -3px currentColor,
    -5px 5px 0 -3px currentColor,
    5px 5px 0 -3px currentColor;
}

.glyph-moon {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 2px solid currentColor;
  background: linear-gradient(90deg, currentColor 50%, transparent 50%);
}

:root.dark .mode-btn .glyph-moon {
  display: none;
}

:root.dark .mode-btn .glyph-sun {
  display: block;
}

.page-header {
  background: var(--surface);
  border-bottom: 3px double var(--border-strong);
}

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 1.6rem 0;
  border-top: 3px solid var(--border-strong);
}

.masthead-date {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

.masthead-date-right {
  text-align: right;
}

.logo-container {
  text-align: center;
  padding: 0.5rem 1rem 1.1rem;
  border-bottom: 1px solid var(--border);
}

.logo {
  display: inline-block;
  color: var(--text);
  text-decoration: none;
}

.logo-text {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 7vw, 3.6rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.05;
}

.logo-accent {
  color: var(--accent);
}

.slogan {
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
  margin-top: 0.5rem;
}

nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  border-top: 1px solid var(--border);
  padding: 0 1rem;
}

.head-option {
  padding: 0.65rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

.head-option:hover {
  color: var(--text);
}

.head-selected {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.rates {
  position: relative;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-left: auto;
  padding: 0.35rem 0.4rem 0.35rem 0.8rem;
}

.com {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.8rem;
  text-decoration: none;
}

.com:hover {
  text-decoration: underline;
}

.coin {
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.62rem;
  font-weight: 800;
  color: #ffffff;
  flex-shrink: 0;
}

.coin.btc {
  background: var(--btc);
}

.coin.xmr {
  background: var(--xmr);
}

.rate {
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.rates-toggle {
  cursor: pointer;
  user-select: none;
  width: 1.35rem;
  height: 1.35rem;
  border: 1px solid var(--border-strong);
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.8rem;
  color: var(--muted);
  flex-shrink: 0;
}

.rates-toggle:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.rates-container {
  display: none;
  position: absolute;
  top: calc(100% + 0.45rem);
  right: 0;
  z-index: 20;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  box-shadow: var(--shadow);
  padding: 0.7rem 0.9rem;
  flex-direction: column;
  gap: 0.45rem;
  min-width: 13rem;
}

.rates-box:checked ~ .rates-container {
  display: flex;
}

.rates-container .date {
  font-size: 0.72rem;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.45rem;
}

.rates-container .coin {
  width: 1.2rem;
  height: 1.2rem;
  font-size: 0.55rem;
}

.rates-container .rate {
  font-size: 0.75rem;
}

.rate-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

main {
  flex: 1;
  width: min(1100px, 100% - 2rem);
  margin-inline: auto;
}

.ad-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.1rem;
  padding-top: 1.6rem;
}

a.ad-banner {
  flex: 1;
  min-width: 0;
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 3px;
  overflow: hidden;
  transition: border-color 0.15s ease;
}

a.ad-banner:hover {
  border-color: var(--accent);
}

a.ad-banner:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

a.ad-banner img {
  display: block;
  width: 100%;
  height: auto;
}

.home-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.1rem;
  padding: 1.1rem 0 0.4rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.home-post {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 3px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s ease;
}

.home-post:hover {
  border-color: var(--accent);
}

.post-link {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 1rem 1.05rem 0.9rem;
  text-decoration: none;
  flex: 1;
}

.post-kicker {
  font-size: 0.64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
}

.thumb {
  border-radius: 2px;
  overflow: hidden;
}

.thumb img {
  display: block;
  width: 100%;
  height: auto;
}

.home-post-title {
  font-family: var(--serif);
  font-size: 1.12rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.005em;
  color: var(--text);
  margin: 0;
}

.home-post:hover .home-post-title {
  color: var(--accent);
}

.home-post-description {
  color: var(--muted);
  font-size: 0.86rem;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-top: 1px solid var(--border);
  padding: 0.5rem 1.05rem;
  font-size: 0.72rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.page-navigation {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.8rem 0 2rem;
}

.page-navigation span {
  min-width: 2.1rem;
  text-align: center;
  padding: 0.3rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 3px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
}

.page-navigation .page-selected {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.foot {
  border-top: 3px double var(--border-strong);
  background: var(--surface);
  padding: 1.4rem 1rem 1.9rem;
  text-align: center;
}

.foot-options {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem;
}

.foot-option {
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  text-decoration: none;
  padding: 0.25rem 0.6rem;
}

a.foot-option:hover {
  color: var(--accent);
}

.disclaimer {
  max-width: 640px;
  margin: 0.9rem auto 0;
  font-size: 0.72rem;
  color: var(--muted);
}

@media (max-width: 640px) {
  .masthead {
    flex-wrap: wrap;
    justify-content: center;
    padding: 0.5rem 1rem 0;
  }

  .masthead-date {
    order: 2;
    font-size: 0.6rem;
  }

  .masthead-date-right {
    display: none;
  }

  .logo-container {
    order: 1;
    flex-basis: 100%;
    padding: 0.4rem 0.5rem 0.9rem;
  }

  .rates {
    margin-left: 0;
    width: 100%;
  }

  .rates-container {
    left: 0;
    right: auto;
  }

  .ad-row {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    animation: none !important;
    transition: none !important;
  }
}

.service-list { list-style: none; margin: 1rem 0 2rem; padding: 0; }
.service-row { border-bottom: 1px solid var(--border); }
.service-link { display: flex; align-items: center; gap: .75rem; padding: .7rem .25rem; text-decoration: none; color: var(--text); }
.service-link:hover { color: var(--accent); }
.service-name { font-weight: 600; flex: 1 1 auto; }
.service-badge { font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: .15rem .5rem; border-radius: 3px; color: #fff; background: var(--muted); }
.status-online { background: #15803d; }
.status-down { background: #b45309; }
.status-seized { background: #b91c1c; }
.status-exit { background: var(--muted); }
.status-unknown { background: var(--muted); }
.service-type { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.service-updated { font-size: .75rem; color: var(--muted); min-width: 6.5rem; text-align: right; }
.service-header { margin-top: 1.2rem; }
.service-title { font-family: var(--serif); font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 700; line-height: 1.15; letter-spacing: -0.01em; }
.service-history-title { font-family: var(--serif); font-size: 1.25rem; font-weight: 700; margin: 1.8rem 0 .4rem; padding-bottom: .35rem; border-bottom: 1px solid var(--border); }
.service-first-seen, .service-last-checked { color: var(--muted); }
.service-meta { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; color: var(--muted); font-size: .8rem; }
.service-description { margin: 1rem 0; }
.service-timeline { list-style: none; margin: 1rem 0; padding: 0; border-left: 2px solid var(--border); }
.service-event { position: relative; padding: 0 0 1.1rem 1.1rem; }
.service-event::before { content: ""; position: absolute; left: -6px; top: .35rem; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.event-date { font-weight: 600; margin-right: .5rem; }
.event-type { font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.event-summary { display: block; margin-top: .15rem; }
.event-detail { margin-top: .3rem; color: var(--muted); }
.event-sources { display: flex; flex-wrap: wrap; gap: .5rem .9rem; margin-top: .4rem; }
.event-sources a { font-size: .72rem; color: var(--muted); text-decoration: underline; text-underline-offset: 2px; word-break: break-all; }
.event-sources a:hover { color: var(--accent); }
.service-empty { color: var(--muted); }
.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-bottom: 2px solid var(--border-strong);
  margin: 0.4rem 0 1.2rem;
}
.filter-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
}
.filter-tab:hover { color: var(--text); }
.filter-tab-active {
  color: var(--text);
  border-bottom-color: var(--accent);
}
.filter-count {
  display: inline-block;
  min-width: 1.4rem;
  padding: 0.05rem 0.35rem;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.filter-tab-active .filter-count {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.section-list { padding: 1.4rem 0 1rem; }
.section-title {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 5vw, 2.8rem);
  font-weight: 700;
  line-height: 1.1;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding-bottom: 0.5rem;
  margin-bottom: 0.9rem;
  border-bottom: 3px double var(--border-strong);
}
.section-intro {
  font-size: 1.02rem;
  color: var(--muted);
  max-width: 46rem;
  margin-bottom: 1.4rem;
}

.story-list { list-style: none; margin: 0.4rem 0 2rem; padding: 0; }
.story-list-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--border);
}
.story-list-item a {
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
}
.story-list-item a:hover { color: var(--accent); }
.story-list-meta {
  color: var(--muted);
  font-size: 0.75rem;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.story {
  max-width: 46rem;
  margin: 1.6rem auto 2.4rem;
  padding: 0 0.25rem;
}
.story-title {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 5vw, 2.9rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.012em;
  margin: 0.35rem 0 0.6rem;
}
.story-meta {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  padding-bottom: 0.9rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1.3rem;
}
.story-thumb {
  margin: 0 0 1.3rem;
  border-radius: 3px;
  overflow: hidden;
}
.story-thumb img {
  display: block;
  width: 100%;
  height: auto;
}
.story-body {
  font-size: 1.06rem;
  line-height: 1.7;
}
.story-body p { margin: 0 0 1.1rem; }
.story-body h2, .story-body h3 {
  font-family: var(--serif);
  font-weight: 700;
  line-height: 1.2;
  margin: 1.8rem 0 0.7rem;
}
.story-body h2 { font-size: 1.5rem; }
.story-body h3 { font-size: 1.22rem; }
.story-body ul, .story-body ol { margin: 0 0 1.1rem 1.3rem; }
.story-body li { margin-bottom: 0.35rem; }
.story-body a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; }
.story-body a:hover { color: var(--accent); }
.story-body blockquote {
  margin: 1.2rem 0;
  padding: 0.2rem 0 0.2rem 1.1rem;
  border-left: 3px solid var(--border-strong);
  color: var(--muted);
  font-style: italic;
}
.story-body code {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 0.05em 0.35em;
}
.story-body pre {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.88rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.9rem 1rem;
  overflow-x: auto;
  margin: 0 0 1.1rem;
}
.story-body pre code { background: none; border: 0; padding: 0; }
.story-body img { max-width: 100%; height: auto; border-radius: 3px; }
.story-sources {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 3px double var(--border-strong);
}
.story-sources h2 {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.story-sources ul { list-style: none; margin: 0; padding: 0; }
.story-sources li { margin-bottom: 0.35rem; }
.story-sources a {
  color: var(--muted);
  font-size: 0.82rem;
  text-decoration: underline;
  text-underline-offset: 2px;
  word-break: break-all;
}
.story-sources a:hover { color: var(--accent); }

.contact-wrap {
  max-width: 40rem;
  margin: 1.6rem auto 2.4rem;
  padding: 0 0.25rem;
}
.static-page {
  max-width: 44rem;
  margin: 1.6rem auto 2.4rem;
  padding: 0 0.25rem;
}
.static-page .story-body {
  margin-top: 1.2rem;
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin-top: 1.2rem;
}
.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.contact-form input,
.contact-form select,
.contact-form textarea {
  font: inherit;
  font-size: 0.95rem;
  text-transform: none;
  letter-spacing: normal;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--border-strong);
  border-radius: 3px;
  background: var(--surface);
  color: var(--text);
}
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.contact-form textarea { resize: vertical; }
.contact-form button {
  align-self: flex-start;
  font: inherit;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.6rem 1.4rem;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--on-accent);
  border-radius: 3px;
  cursor: pointer;
}
.contact-form button:hover { opacity: 0.85; }
.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.notice {
  border: 1px solid var(--border-strong);
  border-left: 4px solid var(--accent);
  background: var(--surface-2);
  padding: 0.7rem 0.9rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}
.error {
  color: #b91c1c;
  font-weight: 600;
  margin-bottom: 1rem;
}
:root.dark .error { color: #f87171; }
