.coin-markets-section {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 24px 0;
  padding: 22px;
  overflow: hidden;
  border: 1px solid var(--market-v213-line-strong, #343941);
  border-radius: 12px;
  background: #1b1d22;
  scroll-margin-top: 20px;
}
.coin-markets-section *,
.coin-markets-section *::before,
.coin-markets-section *::after { box-sizing: border-box; }
.coin-markets-head,
.coin-markets-toolbar,
.coin-markets-update {
  min-width: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.coin-markets-head > div { min-width: 0; }
.coin-markets-head h2 { margin: 3px 0 0; overflow-wrap: anywhere; }
.coin-markets-narrative { max-width: 940px; margin: 12px 0 0; color: #c7d0dd; line-height: 1.6; overflow-wrap: anywhere; }
.coin-markets-update { flex: 0 0 auto; flex-direction: column; align-items: flex-end; gap: 6px; color: #9eb0c7; font-size: 12px; }
.coin-markets-status,
.coin-markets-coverage { max-width: 100%; overflow-wrap: anywhere; }
.coin-markets-coverage { color: #aebbd0; cursor: help; }
.coin-markets-refresh,
.coin-markets-tab,
.coin-markets-open,
.coin-markets-more summary,
.coin-markets-row-toggle {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #4a5260;
  border-radius: 8px;
  background: #252932;
  color: #f4f7fb;
  font: inherit;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}
.coin-markets-refresh { padding: 8px 13px; }
.coin-markets-refresh:disabled { opacity: .62; cursor: wait; }
.coin-markets-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0;
}
.coin-markets-summary article {
  min-width: 0;
  padding: 13px;
  border: 1px solid #343941;
  border-radius: 9px;
  background: #202329;
}
.coin-markets-summary article[hidden] { display: none; }
.coin-markets-summary span,
.coin-markets-summary small { display: block; color: #91a4bd; font-size: 11px; }
.coin-markets-summary b { display: block; margin-top: 6px; color: #f6f8fb; overflow-wrap: anywhere; }
.coin-markets-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.coin-markets-tab { padding: 8px 14px; }
.coin-markets-tab[aria-selected="true"] { border-color: #79b9f3; background: rgba(65, 132, 202, .2); }
.coin-markets-panel { min-width: 0; max-width: 100%; }
.coin-markets-panel[hidden] { display: none !important; }
.coin-markets-table-wrap { width: 100%; max-width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; }
.coin-markets-table { width: 100%; min-width: 1080px; border-collapse: collapse; }
.coin-markets-table th,
.coin-markets-table td { padding: 11px 9px; border-bottom: 1px solid #343941; text-align: left; vertical-align: middle; }
.coin-markets-table th { color: #91a4bd; font-size: 10px; text-transform: uppercase; letter-spacing: .03em; }
.coin-markets-table td { color: #dce4ee; font-size: 12px; }
.coin-markets-table td b { color: #fff; }
.coin-markets-exchange { min-width: 0; display: flex; align-items: center; gap: 8px; }
.coin-markets-exchange i { width: 8px; height: 8px; flex: 0 0 auto; border-radius: 50%; background: #49d7be; }
.coin-markets-open { min-width: 112px; max-width: 100%; padding: 7px 12px; text-align: center; white-space: normal; }
.coin-markets-row-toggle { display: none; padding: 7px 10px; }
.coin-markets-open:hover,
.coin-markets-open:focus-visible,
.coin-markets-refresh:hover,
.coin-markets-refresh:focus-visible,
.coin-markets-tab:hover,
.coin-markets-tab:focus-visible,
.coin-markets-more summary:hover,
.coin-markets-more summary:focus-visible,
.coin-markets-row-toggle:hover,
.coin-markets-row-toggle:focus-visible { border-color: #79b9f3; outline: none; }
.coin-markets-more { width: 100%; margin-top: 12px; }
.coin-markets-more[hidden] { display: none; }
.coin-markets-more summary { width: min(100%, 360px); margin-inline: auto; padding: 8px 12px; list-style: none; }
.coin-markets-more summary::after { content: "↓"; margin-left: 9px; color: #79b9f3; transition: transform .18s ease; }
.coin-markets-more[open] summary::after { transform: rotate(180deg); }
.coin-markets-more summary::-webkit-details-marker { display: none; }
.coin-markets-more[open] summary { margin-bottom: 10px; }
.coin-markets-note { margin: 13px 0 0; color: #91a4bd; font-size: 12px; line-height: 1.55; overflow-wrap: anywhere; }
.coin-markets-status[data-tone="stale"],
.coin-markets-status[data-tone="error"] { color: #f0c46d; }
.coin-markets-status[data-tone="loading"] { color: #9dc9ef; }
.coin-markets-empty { padding: 20px; border: 1px dashed #4a5260; border-radius: 9px; color: #b8c3d2; }
.coin-markets-empty[hidden],
[data-coin-markets-perpetual-table][hidden] { display: none; }

/* Компактная ссылка в существующей строке топ-500. Стили загружаются discovery-скриптом. */
.market-row-actions-v385 { min-width: 0; display: inline-flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 6px; }
html body[data-page="home"] .coin-markets-discovery-link {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 8px;
  border: 1px solid rgba(121, 185, 243, .56);
  border-radius: 6px;
  background: rgba(65, 132, 202, .16);
  color: #acd5fa;
  font-size: 10px;
  font-weight: 900;
  line-height: 1.15;
  text-align: center;
  text-decoration: none;
}
html body[data-page="home"] .coin-markets-discovery-link:hover,
html body[data-page="home"] .coin-markets-discovery-link:focus-visible { border-color: #79b9f3; color: #fff; outline: none; }

@media (max-width: 1120px) {
  .coin-markets-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .coin-markets-section { margin: 18px 0; padding: 16px; scroll-margin-top: 12px; }
  .coin-markets-head { flex-direction: column; }
  .coin-markets-update { width: 100%; align-items: stretch; }
  .coin-markets-refresh { width: 100%; }
  .coin-markets-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .coin-markets-tabs, .coin-markets-tab { width: 100%; }
  .coin-markets-table-wrap { overflow: visible; }
  .coin-markets-table { min-width: 0; table-layout: fixed; }
  .coin-markets-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); }
  .coin-markets-table tbody { display: grid; gap: 10px; }
  .coin-markets-table tr {
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    padding: 10px;
    border: 1px solid #343941;
    border-radius: 10px;
    background: #202329;
  }
  .coin-markets-table td { min-width: 0; padding: 8px; border: 0; overflow-wrap: anywhere; }
  .coin-markets-table td::before { content: attr(data-label); display: block; margin-bottom: 4px; color: #91a4bd; font-size: 9px; font-weight: 800; text-transform: uppercase; }
  .coin-markets-table td:last-child { grid-column: 1 / -1; }
  .coin-markets-mobile-secondary { display: none !important; }
  .coin-markets-table tr.is-mobile-expanded .coin-markets-mobile-secondary { display: block !important; }
  .coin-markets-exchange { align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
  .coin-markets-row-toggle { min-width: 44px; min-height: 44px; display: inline-flex; margin-left: auto; font-size: 11px; }
  .coin-markets-open { width: 100%; min-height: 44px; }
  html body[data-page="home"] .coin-markets-discovery-link { min-height: 44px; padding: 7px 9px; }
}
@media (max-width: 430px) {
  .coin-markets-summary, .coin-markets-table tr { grid-template-columns: 1fr; }
  .coin-markets-table td:last-child { grid-column: auto; }
  .market-row-actions-v385 { width: 100%; justify-content: stretch; }
  .market-row-actions-v385 > a { flex: 1 1 120px; }
}
@media (prefers-reduced-motion: reduce) {
  .coin-markets-section * { scroll-behavior: auto !important; transition-duration: .001ms !important; }
}
