﻿[hidden] { display: none !important; }
:root {
  --bg: #eef0f7;
  --panel: #ffffff;
  --panel-soft: #f7f8fb;
  --line: #d8dbe8;
  --line-strong: #c4c9da;
  --text: #252938;
  --muted: #667085;
  --faint: #99a1b6;
  --accent: #2a8560;
  --accent-strong: #1f6c4d;
  --accent-soft: #dff3eb;
  --blue: #2d66a8;
  --red: #b83a2c;
  --green: #10b981;
  --gold: #a87830;
  --shadow: 0 14px 34px rgba(22, 30, 46, .08);
}

html.dark {
  --bg: #14161e;
  --panel: #1c1f2b;
  --panel-soft: #242838;
  --line: #30364a;
  --line-strong: #3d445c;
  --text: #eef0f8;
  --muted: #a5abc0;
  --faint: #68708d;
  --accent: #3b9c74;
  --accent-strong: #54c694;
  --accent-soft: #173c2d;
  --blue: #5797d8;
  --red: #d95a4b;
  --green: #34d399;
  --gold: #d7a64a;
  --shadow: 0 14px 34px rgba(0, 0, 0, .28);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard Variable", Pretendard, Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
}

button, input, select, textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--panel) 92%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.header-inner {
  max-width: 1500px;
  height: 58px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 18px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  background:
    radial-gradient(circle at 30% 25%, #8ce6bd, transparent 32%),
    linear-gradient(145deg, var(--accent), #1b5a43);
  box-shadow: inset 0 -8px 16px rgba(0, 0, 0, .18);
}

.logo strong {
  display: block;
  font-size: 18px;
  letter-spacing: -.2px;
}

.logo small {
  display: block;
  color: var(--faint);
  font-size: 11px;
  margin-top: 1px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  flex: 1;
}

.main-nav::-webkit-scrollbar {
  display: none;
}

.nav-btn, .segmented button, .theme-btn {
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  border-radius: 6px;
  min-height: 34px;
  padding: 0 12px;
  font-weight: 700;
  font-size: 12px;
}

.nav-btn:hover, .nav-btn.active, .segmented button.active, .theme-btn:hover {
  color: var(--accent);
  background: var(--panel-soft);
  border-color: var(--line);
}

.price-strip {
  display: flex;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
}

.price-strip div {
  min-width: 90px;
  padding: 3px 12px;
  text-align: right;
}

.price-strip div + div {
  border-left: 1px solid var(--line);
}

.price-strip span {
  display: block;
  color: var(--faint);
  font-size: 10px;
  font-weight: 800;
}

.price-strip strong {
  color: var(--accent);
  font-size: 13px;
}

.primary, .secondary {
  border: 1px solid var(--accent);
  border-radius: 7px;
  min-height: 40px;
  padding: 0 16px;
  font-weight: 800;
}

.primary {
  background: var(--accent);
  color: #fff;
}

.primary:hover {
  background: var(--accent-strong);
}

.secondary {
  background: var(--panel);
  color: var(--accent);
}

.small {
  min-height: 34px;
  font-size: 12px;
  padding: 0 12px;
}

.shell {
  max-width: 1760px;
  margin: 0 auto;
  padding: 20px 18px 34px;
}

.notice-bar {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  color: var(--muted);
}

.notice-bar strong {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 22px;
  border-radius: 5px;
  background: color-mix(in srgb, var(--accent) 82%, #fff);
  color: #fff;
  font-size: 12px;
}

.notice-bar span {
  flex: 1;
  text-align: center;
  color: var(--text);
  font-weight: 800;
  transition: opacity .22s ease, transform .22s ease;
}

.notice-bar.rotating-out span {
  opacity: 0;
  transform: translateY(-4px);
}

.notice-bar.caution {
  margin-top: 16px;
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
  background: var(--accent-soft);
}

.notice-bar.caution strong {
  background: color-mix(in srgb, var(--accent) 70%, #111);
}

.content-page {
  display: grid;
  gap: 14px;
}

.content-page[hidden] {
  display: none;
}

body[data-page="noticePage"] .main-column > :not(.content-page),
body[data-page="howto"] .main-column > :not(.content-page) {
  display: none;
}

body[data-page="noticePage"] #noticePage,
body[data-page="howto"] #howto {
  display: grid;
}

.page-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
}

.page-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: var(--accent);
  font-weight: 900;
}

.page-title h2 {
  margin: 0;
  font-size: 21px;
}

.page-title p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.notice-article-list {
  display: grid;
  gap: 12px;
}

.notice-article {
  border: 1px solid color-mix(in srgb, var(--accent) 22%, var(--line));
  border-radius: 8px;
  background: var(--panel);
  padding: 16px;
}

.notice-article-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.notice-article-head span {
  min-width: 38px;
  min-height: 22px;
  display: inline-grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line));
  border-radius: 5px;
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 11px;
  font-weight: 900;
}

.notice-article-head strong {
  font-size: 16px;
}

.notice-article-head time {
  color: var(--faint);
  font-size: 12px;
  font-weight: 900;
}

.notice-article p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.85;
}

.howto-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.howto-grid article,
.howto-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 16px;
}

.howto-grid b {
  color: var(--accent);
  font-size: 12px;
}

.howto-grid strong {
  display: block;
  margin-top: 7px;
  font-size: 16px;
}

.howto-grid p,
.howto-panel p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.howto-panel {
  display: grid;
  gap: 10px;
}

.howto-panel h3 {
  margin: 0;
  font-size: 17px;
}

.howto-panel label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.howto-panel input {
  width: 16px;
  min-height: 16px;
  accent-color: var(--accent);
}

.howto-panel.warning {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line));
  background: var(--accent-soft);
}

.hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, .92fr);
  gap: 22px;
  margin-top: 16px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, var(--panel), color-mix(in srgb, var(--accent-soft) 55%, var(--panel)));
  overflow: hidden;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-weight: 900;
  font-size: 12px;
  letter-spacing: .08em;
}

.hero-copy h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(30px, 4vw, 56px);
  line-height: 1.05;
  letter-spacing: 0;
}

.hero-copy p:not(.eyebrow) {
  max-width: 660px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.market-visual {
  position: relative;
  min-height: 280px;
  display: grid;
  place-items: center;
}

.coin-stack {
  width: min(48vw, 290px);
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 38% 26%, rgba(255,255,255,.9), transparent 25%),
    linear-gradient(145deg, #4cc393, #1d7052);
  box-shadow: 0 24px 50px rgba(27, 112, 82, .28), inset 0 -28px 50px rgba(0, 0, 0, .18);
  color: white;
}

.coin-stack span:first-child {
  font-size: 78px;
  font-weight: 900;
}

.coin-stack span:last-child {
  position: absolute;
  margin-top: 98px;
  font-weight: 900;
  letter-spacing: .12em;
}

.rate-card {
  position: absolute;
  width: 172px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  box-shadow: var(--shadow);
}

.rate-card.buy {
  left: 8px;
  bottom: 28px;
}

.rate-card.sell {
  right: 10px;
  top: 24px;
}

.rate-card small, .rate-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.rate-card strong {
  display: block;
  margin: 3px 0;
  color: var(--accent);
  font-size: 25px;
}

.layout-grid {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr) 330px;
  gap: 18px;
  margin-top: 14px;
  align-items: start;
}

.side-column {
  order: -1;
}

.main-column, .side-column, .right-column {
  display: grid;
  gap: 18px;
}

.section-block, .search-card, .side-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 1px 0 rgba(255,255,255,.3);
}

.right-column {
  min-width: 0;
}

.crypto-ranking {
  padding: 0;
  overflow: hidden;
}

.ranking-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}

.ranking-tabs button {
  min-height: 36px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--muted);
  font-weight: 900;
}

.ranking-tabs button.active {
  border-color: #ff7a1a;
  color: #f97316;
  background: #fff7ed;
}

.ranking-head,
.crypto-price-row {
  display: grid;
  grid-template-columns: 26px minmax(70px, 1fr) minmax(100px, 116px) 64px;
  align-items: center;
  gap: 6px;
}

.ranking-head {
  padding: 10px 14px;
  color: var(--muted);
  background: var(--panel-soft);
  border-bottom: 1px solid var(--line);
  font-size: 11px;
  font-weight: 900;
}

.ranking-head span {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-align: right;
}

.ranking-head span:first-child {
  grid-column: 2;
  text-align: left;
  padding-left: 27px;
}

.crypto-price-row {
  min-height: 42px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.crypto-price-row:last-child {
  border-bottom: 0;
}

.crypto-rank {
  color: var(--muted);
  font-weight: 900;
  text-align: center;
}

.crypto-symbol {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-weight: 900;
  overflow: hidden;
  white-space: nowrap;
}

.crypto-symbol b {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.crypto-icon {
  width: 21px;
  height: 21px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: 0 0 21px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
}

.crypto-price {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-align: right;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.crypto-change {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-align: right;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.crypto-change.up {
  color: var(--green);
}

.crypto-change.down {
  color: var(--red);
}

.right-mini-list > .mini-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 10px 12px;
  min-width: 0;
}

.right-mini-list > .mini-item > strong,
.right-mini-list > .mini-item > span {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.right-mini-list > .mini-item > strong {
  display: flex;
  align-items: center;
  gap: 7px;
}

.right-mini-list > .mini-item > span {
  margin-top: 0;
  text-align: right;
  font-weight: 800;
}

.right-mini-list .type-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 36px;
  height: 22px;
  margin: 0;
  padding: 0 8px;
  border-radius: 5px;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.right-mini-list .type-pill.buy {
  background: var(--blue);
}

.right-mini-list .type-pill.sell {
  background: var(--red);
}

.crypto-news-list {
  display: grid;
}

.crypto-news-item {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 10px;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.crypto-news-item:first-child {
  border-top: 0;
}

.crypto-news-item small {
  color: var(--muted);
  font-weight: 900;
}

.crypto-news-item strong {
  line-height: 1.45;
}

.section-block, .search-card {
  padding: 18px;
}

.section-title, .section-head, .side-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.section-head {
  flex-wrap: nowrap;
}

.section-copy {
  min-width: 0;
}

.section-title {
  justify-content: flex-start;
}

.section-title h2, .section-head h2, .side-card h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: 0;
  word-break: keep-all;
}

.section-title p, .section-head p {
  margin: 4px 0 0;
  color: var(--muted);
  line-height: 1.45;
  word-break: keep-all;
}

.dealer-section {
  padding: 16px 18px 18px;
}

.dealer-section-head {
  align-items: start;
}

.dealer-section-head h2 {
  font-size: 17px;
  white-space: nowrap;
}

.dealer-section-head p {
  font-size: 13px;
}

.compact-select {
  max-width: 220px;
  min-width: 170px;
  min-height: 38px;
  flex: 0 0 220px;
  font-size: 13px;
}

.premium-section {
  border-color: color-mix(in srgb, var(--gold) 48%, var(--line));
  background: linear-gradient(180deg, color-mix(in srgb, var(--gold) 8%, var(--panel)), var(--panel));
}

.section-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 900;
}

.danger .section-icon {
  color: var(--red);
  background: color-mix(in srgb, var(--red) 14%, transparent);
}

.search-row {
  display: grid;
  grid-template-columns: 1fr 150px auto;
  gap: 10px;
  margin-top: 16px;
}

input, select, textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-soft);
  color: var(--text);
  padding: 0 12px;
  outline: none;
}

textarea {
  min-height: 94px;
  padding: 12px;
  resize: vertical;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}

.dealer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.dealer-card {
  min-height: 188px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: var(--panel-soft);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dealer-card.premium {
  border-color: color-mix(in srgb, var(--gold) 65%, var(--line));
  background: linear-gradient(180deg, color-mix(in srgb, var(--gold) 11%, var(--panel)), var(--panel-soft));
}

.dealer-top {
  display: flex;
  gap: 10px;
  align-items: center;
}

.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
}

.dealer-name {
  min-width: 0;
}

.dealer-name strong {
  display: block;
  font-size: 15px;
  letter-spacing: 0;
  word-break: keep-all;
}

.dealer-name span {
  color: var(--muted);
  font-size: 12px;
}

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

.badge {
  border-radius: 999px;
  padding: 5px 8px;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dealer-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: auto;
}

.dealer-stats div {
  padding: 9px;
  border-radius: 7px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.dealer-stats span {
  display: block;
  color: var(--faint);
  font-size: 11px;
}

.dealer-stats strong {
  display: block;
  margin-top: 2px;
  font-size: 14px;
}

.dealer-wallet {
  margin-top: -2px;
  color: var(--muted);
  font-size: 12px;
}

.dealer-wallet strong {
  color: var(--text);
  font-size: 13px;
}

.dealer-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.dealer-actions .secondary.small,
.dealer-actions .primary.small {
  width: 100%;
  min-height: 34px;
  padding: 6px 9px;
}

.segmented {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.trade-table-wrap {
  margin-top: 14px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.trade-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.trade-table th, .trade-table td {
  padding: 13px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.trade-table th {
  color: var(--faint);
  font-size: 12px;
  background: var(--panel-soft);
}

.trade-table tr:last-child td {
  border-bottom: 0;
}

.trade-table tr.trade-row-completed td {
  position: relative;
  color: var(--faint);
  background: color-mix(in srgb, var(--panel-soft) 70%, transparent);
}

.trade-table tr.trade-row-completed td:not(:last-child) {
  filter: blur(.7px);
}

.trade-complete-mark {
  display: inline-flex;
  margin-left: 8px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--panel);
  color: var(--faint);
  border: 1px solid var(--line);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.type-pill {
  display: inline-flex;
  min-width: 54px;
  justify-content: center;
  border-radius: 999px;
  padding: 5px 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.type-pill.buy {
  background: var(--blue);
}

.type-pill.sell {
  background: var(--red);
}

.trade-actions {
  display: inline-flex;
  gap: 6px;
  align-items: center;
}

.trade-actions button {
  min-height: 30px;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  color: var(--muted);
  padding: 0 9px;
  font-size: 12px;
  font-weight: 900;
}

.trade-actions button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.trade-actions button:disabled {
  cursor: not-allowed;
  opacity: .65;
  border-color: var(--line);
  color: var(--faint);
  background: var(--panel-soft);
}

.trade-actions .contact-action {
  border-color: color-mix(in srgb, var(--accent) 34%, var(--line));
  background: color-mix(in srgb, var(--accent) 10%, var(--panel-soft));
  color: var(--accent);
}

.trade-actions button[data-trade-report] {
  color: var(--red);
}

.premium-grid, .board-pair {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.premium-grid article, .board-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: var(--panel-soft);
}

.premium-grid strong, .premium-grid span, .board-item strong, .board-item span {
  display: block;
}

.premium-grid span, .board-item span {
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.55;
}

.board-pair {
  grid-template-columns: 1fr 1fr;
  align-items: start;
}

.board-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.board-action {
  margin-top: 12px;
  width: 100%;
}

.side-card {
  padding: 16px;
}

.market-chat {
  position: relative;
  padding: 0;
  overflow: hidden;
}

.market-chat .side-head {
  min-height: 58px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
}

.market-chat h3 {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 15px;
}

.market-chat h3 em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
}

.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #a7e7d2;
}

.chat-tools {
  display: inline-flex;
  gap: 8px;
}

.chat-tools button {
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 6px;
  font-size: 16px;
}

.chat-tools button:hover {
  background: var(--panel-soft);
  color: var(--accent);
}

.chat-warning {
  padding: 9px 16px;
  border-bottom: 1px solid #fed7aa;
  background: #fff7ed;
  color: #b45309;
  font-size: 11px;
  line-height: 1.55;
}

html.dark .chat-warning {
  background: rgba(180, 83, 9, .16);
  border-color: rgba(251, 146, 60, .32);
  color: #fdba74;
}

.side-head span {
  color: var(--faint);
  font-size: 12px;
}

.chat-list, .mini-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.market-chat .chat-list {
  position: relative;
  align-content: start;
  height: 268px;
  margin: 0;
  padding: 10px 16px 18px;
  overflow-y: auto;
  scrollbar-width: thin;
}

.chat-item, .mini-item {
  border: 1px solid var(--line);
  background: var(--panel-soft);
  border-radius: 7px;
  padding: 10px;
}

.market-chat .chat-item {
  border: 0;
  background: transparent;
  border-radius: 0;
  padding: 0;
  position: relative;
}

.chat-item strong, .mini-item strong {
  display: block;
}

.market-chat .chat-item strong {
  color: #0f766e;
  font-size: 12px;
}

html.dark .market-chat .chat-item strong {
  color: #5ee0b2;
}

.chat-item span, .mini-item span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.chat-report-btn {
  position: absolute;
  right: 0;
  top: 0;
  min-height: 22px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--faint);
  font-size: 11px;
  font-weight: 800;
  padding: 0 5px;
}

.chat-report-btn:hover {
  background: var(--panel-soft);
  color: var(--red);
}

.chat-form {
  display: grid;
  grid-template-columns: 1fr 42px;
  gap: 8px;
  margin-top: 12px;
}

.market-chat .chat-form {
  grid-template-columns: 1fr 52px;
  margin: 0;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
}

.market-chat .chat-form input {
  min-height: 36px;
  background: var(--panel);
}

.chat-form button {
  border: 1px solid var(--accent);
  border-radius: 7px;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
}

.market-chat .chat-form button {
  min-height: 36px;
  padding: 0;
}

.point-toast {
  position: absolute;
  right: 14px;
  bottom: 58px;
  color: #e7c46d;
  font-size: 16px;
  font-weight: 900;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .25s, transform .25s;
  pointer-events: none;
}

.point-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.prediction-card {
  padding: 14px;
  max-width: 330px;
  width: 100%;
}

.prediction-head {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 9px;
  margin-bottom: 10px;
}

.prediction-head > div {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.prediction-head strong {
  white-space: nowrap;
}

.btc-badge {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #f7931a;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.exchange-badge {
  padding: 3px 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
}

.coin-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 10px;
}

.coin-tabs button {
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.coin-tabs button.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

#predictTimer {
  color: #ef4444;
  font-family: Consolas, "SFMono-Regular", monospace;
  font-size: 16px;
  font-weight: 900;
}

.candle-chart {
  height: 176px;
  position: relative;
  border: 1px solid var(--line);
  border-radius: 7px;
  background:
    linear-gradient(to bottom, transparent calc(25% - 1px), rgba(148, 163, 184, .14) 25%, transparent calc(25% + 1px)),
    linear-gradient(to bottom, transparent calc(50% - 1px), rgba(148, 163, 184, .14) 50%, transparent calc(50% + 1px)),
    linear-gradient(to bottom, transparent calc(75% - 1px), rgba(148, 163, 184, .14) 75%, transparent calc(75% + 1px)),
    var(--panel-soft);
  overflow: hidden;
}

.candle {
  position: absolute;
  width: 1px;
  border-radius: 1px;
  color: #10b981;
  background: currentColor;
}

.candle-body {
  position: absolute;
  left: -3px;
  width: 7px;
  min-height: 3px;
  display: block;
  border-radius: 1px;
  background: currentColor;
}

.candle.up {
  color: #10b981;
}

.candle.down {
  color: #ef4444;
}

.price-pair {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 9px;
  color: var(--muted);
  font-size: 11px;
}

.price-pair b {
  color: var(--text);
  font-size: 13px;
}

.prediction-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}

.prediction-actions button {
  min-height: 38px;
  border: 0;
  border-radius: 7px;
  color: #fff;
  font-size: 15px;
  font-weight: 900;
}

.long-btn {
  background: #10b981;
}

.short-btn {
  background: #ef2d2d;
}

.prediction-actions button:disabled {
  opacity: .58;
  cursor: not-allowed;
}

.bet-row {
  display: grid;
  grid-template-columns: 1fr 68px auto;
  gap: 6px;
  align-items: center;
  margin-top: 9px;
}

.bet-row input, .bet-row select {
  min-height: 38px;
  font-weight: 800;
}

.bet-row span {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.bet-row b {
  color: var(--text);
}

.prediction-note, .predict-state {
  margin-top: 8px;
  padding: 10px;
  border-radius: 7px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 11px;
  text-align: center;
}

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

.predict-state {
  color: #10b981;
  font-weight: 900;
}

.history-strip {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
}

.history-strip::before {
  content: "지난 결과";
  color: var(--muted);
  font-size: 11px;
  margin-right: 2px;
}

.history-item {
  width: 21px;
  height: 21px;
  border-radius: 4px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  font-size: 13px;
}

.history-item.long {
  background: #10b981;
}

.history-item.short {
  background: #ef4444;
}

.history-item.pending {
  background: #a7f3d0;
}

.prediction-log {
  margin-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}

.prediction-log summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-weight: 900;
}

.prediction-log summary::after {
  content: "⌃";
  color: var(--faint);
}

.prediction-log[open] summary::after {
  transform: rotate(180deg);
}

.prediction-log div {
  min-height: 54px;
  display: grid;
  gap: 6px;
  place-items: center;
  padding: 8px;
}

.prediction-log p {
  width: 100%;
  margin: 0;
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.leaderboard-box {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.leaderboard-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 12px;
}

.leaderboard-head span {
  color: var(--faint);
  font-size: 11px;
  font-weight: 800;
}

.leaderboard-list {
  display: grid;
  gap: 7px;
}

.leaderboard-row {
  display: grid;
  grid-template-columns: 24px 1fr auto;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-soft);
  padding: 6px 8px;
}

.leaderboard-rank {
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #f59e0b;
  color: white;
  font-size: 11px;
  font-weight: 900;
}

.leaderboard-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 900;
}

.leaderboard-profit {
  color: #10b981;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.guide {
  display: grid;
  gap: 12px;
}

.guide label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.guide input {
  width: 16px;
  min-height: 16px;
  accent-color: var(--accent);
}

.site-footer {
  max-width: 1500px;
  margin: 0 auto;
  padding: 22px 18px 34px;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 18px;
  border-top: 1px solid var(--line);
}

.site-footer p {
  margin: 5px 0 0;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

dialog {
  width: min(94vw, 520px);
  max-height: calc(100vh - 32px);
  border: 0;
  border-radius: 10px;
  padding: 0;
  color: var(--text);
  background: transparent;
  overflow: visible;
}

dialog::backdrop {
  background: rgba(8, 12, 24, .58);
}

.modal-card {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  box-shadow: var(--shadow);
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  overflow-x: hidden;
}

.modal-card.wide {
  width: auto;
}

#tradeDialog {
  width: min(94vw, 520px);
}

.trade-modal {
  gap: 14px;
  padding: 22px 22px 18px;
}

.modal-head {
  padding-right: 34px;
}

.modal-head h2 {
  margin: 0 0 5px;
  font-size: 20px;
}

.modal-head p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.trade-step {
  display: grid;
  gap: 9px;
  padding-top: 4px;
}

.field-title {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.trade-type-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.trade-type-picker button,
.chip-grid label {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-soft);
  color: var(--muted);
  font-weight: 900;
}

.trade-type-picker button.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

.trade-type-picker button[data-trade-type="sell"].active {
  border-color: var(--red);
  background: color-mix(in srgb, var(--red) 12%, var(--panel));
  color: var(--red);
}

.chip-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.chip-grid.two {
  grid-template-columns: 1fr 1fr;
}

.chip-grid label {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  font-size: 12px;
}

.chip-grid input {
  width: 15px;
  min-height: 15px;
  accent-color: var(--accent);
}

#tradeTotalOutput {
  min-height: 42px;
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-soft);
  color: var(--text);
  padding: 0 12px;
  font-weight: 900;
}

.field-help {
  margin: -2px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.modal-actions {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 8px;
}

.footer-link {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0;
  font: inherit;
  font-weight: 800;
}

.footer-link:hover {
  color: var(--accent);
}

#policyDialog {
  width: min(94vw, 640px);
}

.policy-card {
  gap: 16px;
}

.policy-body {
  display: grid;
  gap: 12px;
  color: var(--muted);
  line-height: 1.65;
}

.policy-body section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  padding: 13px;
}

.policy-body h3 {
  margin: 0 0 6px;
  color: var(--text);
  font-size: 14px;
}

.policy-body p,
.policy-body ul {
  margin: 0;
}

.policy-body ul {
  padding-left: 18px;
}

.policy-text {
  margin: 0;
  white-space: pre-wrap;
  word-break: keep-all;
  overflow-wrap: anywhere;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--text);
  padding: 16px;
  font-family: "Pretendard Variable", Pretendard, Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 13px;
  line-height: 1.7;
}

.detail-body {
  display: grid;
  gap: 10px;
}

.detail-row {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.detail-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.detail-row strong {
  color: var(--text);
  line-height: 1.45;
}

.detail-warning {
  border: 1px solid #fed7aa;
  border-radius: 8px;
  background: #fff7ed;
  color: #92400e;
  padding: 12px;
  font-size: 12px;
  line-height: 1.55;
}

.detail-actions {
  display: grid;
  gap: 8px;
}

.dealer-detail-hero {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.dealer-detail-hero strong,
.dealer-detail-hero span {
  display: block;
}

.dealer-detail-hero strong {
  color: var(--text);
  font-size: 18px;
}

.dealer-detail-hero span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dealer-review-box {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.dealer-review-box div {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.dealer-review-box b,
.dealer-review-box span {
  display: block;
}

.dealer-review-box b {
  color: var(--text);
  font-size: 16px;
}

.dealer-review-box span {
  margin-top: 4px;
  color: var(--faint);
  font-size: 12px;
  font-weight: 900;
}

.warning-card {
  width: min(620px, calc(100vw - 28px));
  gap: 0;
  overflow: hidden;
  border-color: #f59e0b;
  padding: 0;
}

.trade-warning-head {
  display: grid;
  gap: 6px;
  padding: 20px 24px;
  background: #fff7ed;
  color: #92400e;
  text-align: center;
  border-bottom: 1px solid #fbbf24;
}

.trade-warning-head strong {
  font-size: 16px;
}

.trade-warning-head span {
  font-size: 13px;
  font-weight: 800;
}

.warning-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.warning-actions button {
  border-radius: 0;
  border: 0;
  min-height: 48px;
  border-right: 1px solid #fbbf24;
}

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

.all-trades-card {
  width: min(1060px, calc(100vw - 28px));
}

.all-trades-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.all-trades-wrap {
  max-height: min(62vh, 680px);
  overflow: auto;
}

.table-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.table-pager button {
  min-width: 34px;
  min-height: 34px;
  border-radius: 7px;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  color: var(--muted);
  font-weight: 900;
}

.table-pager button.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.table-pager button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.table-pager span {
  color: var(--faint);
  font-size: 12px;
  font-weight: 800;
}

.pager-gap {
  padding: 0 3px;
  color: var(--faint);
}

.notification-list {
  display: grid;
  gap: 8px;
  max-height: 420px;
  overflow-y: auto;
}

.notification-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  padding: 12px;
}

.notification-item.unread {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.notification-item strong,
.notification-item span {
  display: block;
}

.notification-item span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.modal-card h2 {
  margin: 0 0 4px;
}

.modal-card label {
  display: grid;
  gap: 6px;
  font-weight: 800;
  color: var(--muted);
}

.modal-close {
  position: absolute;
  right: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 22px;
  line-height: 1;
}

.member-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.member-tabs button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-soft);
  color: var(--muted);
  font-weight: 900;
}

.member-tabs button.active {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
}


.member-tabs button span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.member-tabs button.active span {
  color: var(--accent);
}

#registerDialog {
  width: min(94vw, 560px);
}

#findAccountDialog,
#resetPwDialog {
  width: min(94vw, 480px);
}
.trade-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.full {
  width: 100%;
}

@media (max-width: 1180px) {
  .layout-grid {
    grid-template-columns: 1fr;
  }

  .side-column {
    order: 0;
    grid-template-columns: repeat(3, 1fr);
  }

  .right-column {
    grid-template-columns: repeat(3, 1fr);
  }

  .dealer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .howto-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    padding-block: 10px;
  }

  .main-nav {
    order: 3;
    flex-basis: 100%;
  }

  .price-strip {
    display: none;
  }

  .hero-panel {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .market-visual {
    min-height: 220px;
  }

  .layout-grid, .side-column, .right-column, .dealer-grid, .premium-grid, .board-pair {
    grid-template-columns: 1fr;
  }

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

  .side-column, .right-column {
    max-width: 330px;
    width: 100%;
  }

  .search-row, .trade-form-grid, .chip-grid {
    grid-template-columns: 1fr;
  }

  .site-footer {
    display: grid;
  }
}

@media (max-width: 520px) {
  .shell {
    padding-inline: 12px;
  }

  .hero-copy h1 {
    font-size: 30px;
  }

  .hero-copy p:not(.eyebrow) {
    font-size: 15px;
  }

  .rate-card {
    position: static;
    width: 100%;
    margin-top: 10px;
  }

  .market-visual {
    display: block;
  }

  .coin-stack {
    margin: 0 auto;
  }
}

/* ── Auth area & user dropdown ───────────────────────────────── */
.auth-area {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.user-area {
  position: relative;
  flex-shrink: 0;
}

.user-menu-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border-radius: 7px;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s;
}
.user-menu-btn:hover { background: var(--line); }

.dropdown-caret {
  font-size: 10px;
  color: var(--muted);
  line-height: 1;
}

.user-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 180px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(22, 30, 46, .12);
  z-index: 200;
  padding: 8px 0;
}

.dropdown-profile {
  padding: 10px 14px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dropdown-profile strong {
  font-size: 14px;
  color: var(--text);
}
.drop-grade {
  font-size: 11px;
  color: var(--muted);
}

.dropdown-divider {
  height: 1px;
  background: var(--line);
  margin: 4px 0;
}

.dropdown-item {
  display: block;
  width: 100%;
  padding: 9px 14px;
  text-align: left;
  font-size: 13px;
  color: var(--text);
  background: none;
  border: none;
  cursor: pointer;
  transition: background .12s;
}
.dropdown-item:hover { background: var(--panel-soft); }
.logout-item { color: var(--red); }
.logout-item:hover { background: color-mix(in srgb, var(--red) 8%, transparent); }

/* ── Auth modals ─────────────────────────────────────────────── */
#memberDialog,
#registerDialog {
  width: min(94vw, 380px);
}

.modal-sub {
  margin: -6px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.form-error {
  font-size: 12px;
  color: var(--red);
  background: color-mix(in srgb, var(--red) 8%, transparent);
  border-radius: 6px;
  padding: 7px 10px;
  margin: 0;
}

.modal-footer-text {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  margin: 0;
}

.link-btn {
  background: none;
  border: none;
  color: var(--accent);
  font-size: inherit;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}
.link-btn:hover { color: var(--accent-strong); }

/* ── My inquiries dialog ─────────────────────────────────────── */
.my-inquiries-list {
  display: grid;
  gap: 8px;
  max-height: 60vh;
  overflow-y: auto;
}

.inquiry-row {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
}

.inquiry-row-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.inquiry-row-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--muted);
}

.inq-status {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
}
.inq-status.open { background: var(--accent-soft); color: var(--accent-strong); }
.inq-status.closed { background: var(--line); color: var(--muted); }

.empty-msg {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  padding: 20px 0;
}

/* Mobile production responsive refinements */
@media (max-width: 900px) {
  body {
    overflow-x: hidden;
  }

  .site-header {
    position: sticky;
  }

  .header-inner {
    max-width: none;
    width: 100%;
    gap: 10px;
    padding: 10px 12px;
  }

  .logo {
    flex: 1 1 auto;
    min-width: 160px;
  }

  .logo strong {
    font-size: 17px;
  }

  .auth-area,
  .user-area {
    margin-left: auto;
  }

  .main-nav {
    width: 100%;
    flex: 0 0 100%;
    order: 10;
    padding-bottom: 2px;
    gap: 6px;
    overflow-x: auto;
  }

  .nav-btn {
    flex: 0 0 auto;
    min-width: max-content;
    padding-inline: 11px;
  }

  .shell {
    width: 100%;
    max-width: none;
    padding: 12px 10px 28px;
  }

  .layout-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .main-column,
  .side-column,
  .right-column {
    width: 100%;
    max-width: none;
    min-width: 0;
    gap: 12px;
  }

  .side-column {
    order: 2;
  }

  .main-column {
    order: 1;
  }

  .right-column {
    order: 3;
  }

  .side-card,
  .section-block,
  .search-card {
    width: 100%;
    min-width: 0;
  }

  .prediction-card {
    max-width: none;
  }

  .trade-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .trade-table {
    min-width: 720px;
  }

  .crypto-ranking {
    overflow-x: auto;
  }

  .ranking-tabs,
  .ranking-head,
  .crypto-price-row {
    min-width: 300px;
  }

  .crypto-price-row {
    grid-template-columns: 26px minmax(72px, 1fr) minmax(86px, auto) 64px;
    padding-inline: 12px;
  }

  .ranking-head {
    grid-template-columns: 26px minmax(72px, 1fr) minmax(86px, auto) 64px;
    padding-inline: 12px;
  }

  .right-mini-list > .mini-item {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .modal-card {
    max-width: calc(100vw - 20px);
  }
}

@media (max-width: 560px) {
  body {
    font-size: 13px;
  }

  .header-inner {
    padding-inline: 10px;
  }

  .logo small,
  .price-strip {
    display: none;
  }

  .theme-btn,
  .secondary.small,
  .primary.small,
  .user-menu-btn {
    min-height: 32px;
    padding-inline: 9px;
    font-size: 12px;
  }

  .notice-bar {
    align-items: flex-start;
    padding: 10px;
  }

  .notice-bar span {
    text-align: left;
    line-height: 1.55;
  }

  .section-title,
  .section-head,
  .side-head,
  .dealer-section-head,
  .page-title {
    align-items: flex-start;
    gap: 9px;
  }

  .section-head,
  .dealer-section-head {
    display: grid;
  }

  .compact-select {
    max-width: none;
    width: 100%;
    min-width: 0;
    flex-basis: auto;
  }

  .dealer-grid,
  .premium-grid,
  .board-pair,
  .howto-grid,
  .search-row,
  .trade-form-grid,
  .chip-grid,
  .chip-grid.two,
  .bet-row,
  .prediction-actions {
    grid-template-columns: 1fr;
  }

  .dealer-card {
    min-height: 0;
  }

  .dealer-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  .dealer-stats div {
    padding: 8px 6px;
  }

  .dealer-actions,
  .dealer-review-box {
    grid-template-columns: 1fr;
  }

  .market-chat .chat-list {
    height: 230px;
  }

  .candle-chart {
    height: 156px;
  }

  .coin-tabs {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .history-strip {
    flex-wrap: wrap;
  }

  .leaderboard-row {
    grid-template-columns: 22px minmax(0, 1fr);
  }

  .leaderboard-profit {
    grid-column: 2;
    justify-self: start;
  }

  .notice-article,
  .howto-grid article,
  .howto-panel {
    padding: 13px;
  }

  .notice-article-head {
    grid-template-columns: auto 1fr;
  }

  .notice-article-head time {
    grid-column: 2;
    justify-self: start;
  }

  dialog {
    width: calc(100vw - 18px);
  }

  .modal-card {
    padding: 18px;
  }

  .modal-actions {
    grid-template-columns: 1fr;
  }

  .site-footer {
    padding-inline: 12px;
  }
}

@media (max-width: 380px) {
  .crypto-price-row,
  .ranking-head {
    grid-template-columns: 22px minmax(62px, 1fr) 80px 58px;
    gap: 5px;
    font-size: 12px;
  }

  .crypto-icon {
    width: 19px;
    height: 19px;
    flex-basis: 19px;
  }

  .right-mini-list > .mini-item {
    grid-template-columns: 1fr;
  }

  .right-mini-list > .mini-item > span {
    text-align: left;
  }
}

.empty-state {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 72px;
  width: 100%;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-align: center;
}
