/* Единая коллекция десяти знаков: метрики, иерархия и развитие. */
.rank-badge {
  display: block;
  width: 66px;
  height: 74px;
  object-fit: contain;
  flex: none;
  filter: drop-shadow(0 3px 3px #0005);
}
#topbar .rep-resource { gap: 7px; overflow: hidden; }
#topbar .rank-emblem { display: grid; place-items: center; flex: none; width: 38px; }
#topbar .rank-badge { width: 38px; height: 43px; }
#topbar .rep-copy { display: block; min-width: 0; }
#topbar .rep-copy > small { font-size: .6875rem; line-height: 1.15; margin-bottom: 2px; }
#topbar .rep-resource strong { display: block; font-size: 1.125rem; line-height: 1.15; }
#topbar .rep-title {
  display: block;
  max-width: 100%;
  margin-top: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .6875rem;
  line-height: 1.15;
  color: #c7b68b;
}
#topbar .rep-resource:hover .rep-title { color: #e9d2a0; }
@media (min-width: 851px) {
  #topbar .resources { grid-template-columns: minmax(0,1.45fr) minmax(0,1.2fr) repeat(3,minmax(0,1fr)) minmax(0,1.15fr); }
}
@media (min-width: 851px) and (max-width: 1100px) {
  #topbar .resources { grid-template-columns: minmax(0,1.35fr) minmax(0,1.3fr) repeat(3,minmax(0,1fr)) minmax(0,1.1fr); }
  #topbar .rank-emblem { width: 30px; }
  #topbar .rank-badge { width: 30px; height: 34px; }
  #topbar .rep-resource { gap: 5px; }
}
@media (max-width: 600px) {
  #topbar .rep-resource {
    display: grid;
    grid-template-columns: 24px minmax(0,1fr);
    grid-template-rows: auto 1fr;
    column-gap: 6px;
    row-gap: 2px;
    align-items: center;
    text-align: left;
  }
  #topbar .rep-copy { display: contents; }
  #topbar .rep-copy > small { grid-column: 1 / -1; grid-row: 1; margin: 0; }
  #topbar .rank-emblem { grid-column: 1; grid-row: 2; width: 24px; }
  #topbar .rank-badge { width: 24px; height: 27px; }
  #topbar .rep-resource strong { grid-column: 2; grid-row: 2; font-size: 1.1875rem; }
  #topbar .rep-resource .rep-title { display: none; }
}

.modal.modal-reputation { width: min(100%,830px); max-width: 830px; padding: 30px; }
.modal-reputation > .eyebrow { color: #b6a16e; font-size: .6875rem; letter-spacing: 1.8px; }
.modal-reputation > h2 { font-size: 34px; margin-bottom: 0; }
.rank-profile {
  display: grid;
  grid-template-columns: 80px minmax(0,1fr) auto;
  align-items: center;
  gap: 18px;
  margin-top: 23px;
  padding: 17px 22px 17px 15px;
  border: 1px solid #b99e5e49;
  border-radius: 10px;
  background: radial-gradient(ellipse at 4% 50%, #d3b37214, transparent 64%), linear-gradient(110deg, #27332f, #1c292b);
  box-shadow: inset 0 1px #f4dfac09;
}
.rank-profile-badge { display: grid; place-items: center; }
.rank-profile-badge .rank-badge { width: 78px; height: 88px; }
.rank-profile-copy { min-width: 0; }
.rank-profile-copy > .eyebrow { font-size: .625rem; color: #aaae8d; letter-spacing: 1.4px; margin-bottom: 6px; }
.rank-profile-copy h3 { font: 500 29px/1.15 var(--display); color: #efddb6; }
.rank-profile-copy p { margin-top: 7px; font-size: .8125rem; color: #a8b7ab; line-height: 1.5; max-width: 360px; }
.rank-profile-rep { padding-left: 18px; border-left: 1px solid #b4c4a91c; text-align: center; }
.rank-profile-rep > strong { display: block; font: 500 35px/1.15 var(--display); color: #f0d09b; font-variant-numeric: tabular-nums; }
.rank-profile-rep > span { display: block; margin-top: 4px; font-size: .75rem; color: #a3b6a7; }
.rank-next { margin: 15px 0 24px; }
.rank-next > div:first-child { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 9px; }
.rank-next > div:first-child > span { font-size: .8125rem; color: #9fb1a7; }
.rank-next > div:first-child strong { font-weight: 500; color: #d9deca; }
.rank-next b { font-size: .75rem; color: #d9bb83; font-weight: 500; white-space: nowrap; }
.rank-next .progress { height: 4px; background: #b3b88917; }
.rank-next .progress > span { border-radius: inherit; background: linear-gradient(90deg, #95714a, #ecc58b); }
.rank-complete { font-size: .875rem; color: #d9bb83; }
.rank-shelf-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin-bottom: 14px; font: 500 23px/1.25 var(--display); color: #dbe2d5; }
.rank-shelf-heading > span { font: 400 .75rem/1.4 var(--font); color: #8fa297; }
.rank-grid { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.rank-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 29px 9px 13px;
  min-width: 0;
  text-align: center;
  border: 1px solid #839c881d;
  border-radius: 9px;
  background: radial-gradient(ellipse at 50% 35%, #a3b7a80b, transparent 75%), #1b292a;
}
.rank-tier { position: absolute; left: 11px; top: 8px; font: 500 14px/1.2 var(--display); color: #8c9b8a; }
.rank-card-state { position: absolute; right: 9px; top: 10px; font-size: .625rem; line-height: 1.1; color: #91a396; }
.rank-card > strong { display: flex; align-items: center; justify-content: center; min-height: 34px; margin-top: 6px; font-size: .8125rem; font-weight: 550; line-height: 1.3; color: #c7d1c3; }
.rank-card > small { margin-top: 5px; color: #9cafa0; font-size: .6875rem; line-height: 1.25; font-variant-numeric: tabular-nums; }
.rank-card.is-current {
  border-color: #c9ab6973;
  background: radial-gradient(ellipse at 50% 35%, #e3ba7421, transparent 80%), #29322a;
  box-shadow: inset 0 1px #f3d5921c, 0 0 18px #d2b06c07;
}
.rank-card.is-current > strong { color: #f0d4a2; }
.rank-card.is-current .rank-tier,
.rank-card.is-current .rank-card-state { color: #d9b77c; }
.rank-card.is-reached { border-color: #a6bd8c32; }
.rank-card.is-locked .rank-badge { opacity: .7; filter: saturate(.6) drop-shadow(0 3px 3px #0005); }
.rank-card.is-locked > strong { color: #acb9ac; }
.rank-card.is-locked .rank-card-state { color: #7b9285; }
.rank-modal-footer { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-top: 20px; }
.rank-modal-footer > span { font-size: .75rem; color: #8eaa98; }
.rank-modal-footer > .btn { min-height: 36px; font-size: .8125rem; padding: 9px 14px; }
.rank-road > h2 { margin-bottom: 20px; }
.rank-road .rank-card { padding-top: 32px; }
.rank-road .rank-badge { width: 76px; height: 85px; }

@media (max-width: 700px) {
  .modal.modal-reputation { padding: 25px 20px; }
  .rank-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .rank-profile { grid-template-columns: 67px minmax(0,1fr) auto; gap: 12px; padding: 16px 14px; }
  .rank-profile-badge .rank-badge { width: 64px; height: 72px; }
  .rank-profile-copy h3 { font-size: 25px; }
  .rank-profile-copy p { font-size: .75rem; }
  .rank-profile-rep { padding-left: 12px; }
  .rank-profile-rep > strong { font-size: 30px; }
  .rank-profile-rep > span { font-size: .6875rem; }
}
@media (max-width: 480px) {
  .modal.modal-reputation { padding: 25px 16px 20px; }
  .modal-reputation > h2 { font-size: 29px; padding-right: 17px; }
  .modal-reputation > .eyebrow { font-size: .625rem; }
  .rank-profile { grid-template-columns: 58px minmax(0,1fr); gap: 9px 12px; padding: 16px 12px; margin-top: 20px; }
  .rank-profile-badge { grid-row: 1 / span 2; }
  .rank-profile-badge .rank-badge { width: 58px; height: 66px; }
  .rank-profile-copy h3 { font-size: 25px; }
  .rank-profile-copy > .eyebrow { font-size: .5625rem; letter-spacing: 1px; }
  .rank-profile-copy p { font-size: .75rem; line-height: 1.5; }
  .rank-profile-rep { grid-column: 2; display: flex; align-items: baseline; gap: 7px; padding: 0; border: 0; text-align: left; }
  .rank-profile-rep > strong { font: 650 1.125rem/1.2 var(--font); }
  .rank-profile-rep > span { margin: 0; font-size: .6875rem; }
  .rank-next > div:first-child { flex-direction: column; gap: 5px; }
  .rank-next > div:first-child > span { font-size: .75rem; }
  .rank-next b { font-size: .6875rem; }
  .rank-shelf-heading { font-size: 23px; }
  .rank-shelf-heading > span { font-size: .625rem; }
  .rank-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
  .rank-card { padding: 29px 8px 13px; }
  .rank-card .rank-badge { width: 66px; height: 74px; }
  .rank-card > strong { font-size: .8125rem; }
  .rank-modal-footer { flex-direction: column; gap: 14px; align-items: stretch; }
  .rank-modal-footer > span { text-align: center; font-size: .6875rem; }
  .rank-road .rank-badge { width: 70px; height: 79px; }
}
