/* ratingpokerclubs.com - «тёмный редакционный справочник». Решения - tools/ДИЗАЙН.md.
   Шкала ниже единственная: новых размеров шрифта не заводить, инлайновых font-size не ставить. */

:root {
  --bg: #101820;
  --surface: #16242F;
  --raised: #1D303D;
  --line: #344856;
  --text: #F4F1EA;
  --text-2: #CBD3D8;
  --text-3: #AEBBC3;
  --accent: #D6A756;
  --on-accent: #101820;
  --star: #E0B35D;
  --tg: #286584;
  --wa: #256A4A;
  --on-btn: #FFFFFF;

  --radius: 8px;
  --maxw: 1120px;
  --pad: 16px;

  --h1: 30px;  --h1-l: 36px;
  --h2: 24px;  --h2-l: 30px;
  --h3: 19px;  --h3-l: 25px;
  --t: 17px;   --t-l: 27px;
  --s: 15px;   --s-l: 22px;

  --serif: "Literata", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Segoe UI", Roboto, Arial, sans-serif;
}

@media (min-width: 900px) {
  :root {
    --h1: 42px; --h1-l: 50px;
    --h2: 30px; --h2-l: 38px;
    --h3: 21px; --h3-l: 28px;
    --t-l: 28px;
    --pad: 24px;
  }
}

[hidden] { display: none !important; }
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 var(--t)/var(--t-l) var(--sans);
  overflow-x: hidden;
  padding-bottom: 76px; /* место под нижнюю панель на телефоне */
}
@media (min-width: 900px) { body { padding-bottom: 0; } }

img { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--text); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 700; margin: 0 0 12px; color: var(--text); }
h1 { font-size: var(--h1); line-height: var(--h1-l); margin-bottom: 10px; }
h2 { font-size: var(--h2); line-height: var(--h2-l); font-weight: 600; }
h3 { font-size: var(--h3); line-height: var(--h3-l); font-weight: 600; }
p { margin: 0 0 14px; }
ul, ol { margin: 0 0 14px; padding-left: 22px; }
li { margin-bottom: 6px; }
strong { font-weight: 700; }
.small { font-size: var(--s); line-height: var(--s-l); color: var(--text-3); }
.nw { white-space: nowrap; } /* «X-Poker» не рвётся на дефисе */

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad); }

/* Шапка */
.top {
  position: sticky; top: 0; z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 58px; gap: 12px; }
.logo { color: var(--text); text-decoration: none; display: flex; flex-direction: column; min-height: 44px; justify-content: center; }
.logo b { font-family: var(--serif); font-weight: 700; font-size: var(--h3); line-height: 24px; }
.logo span { font-size: var(--s); line-height: 18px; color: var(--text-3); }
.menu-btn {
  min-width: 44px; min-height: 44px; padding: 0 14px;
  background: var(--surface); color: var(--text);
  border: 1px solid var(--line); border-radius: var(--radius);
  font: 600 var(--s)/1 var(--sans); cursor: pointer;
}
.menu { border-top: 1px solid var(--line); background: var(--bg); }
.menu ul { list-style: none; margin: 0; padding: 8px var(--pad) 14px; }
.menu li { margin: 0; }
.menu a {
  display: flex; align-items: center; min-height: 48px;
  color: var(--text); text-decoration: none; border-bottom: 1px solid var(--line);
}
.menu a[aria-current="page"] { color: var(--accent); }

@media (min-width: 900px) {
  .menu-btn { display: none; }
  .menu { display: block !important; border: 0; }
  .menu[hidden] { display: block !important; }
  .top .wrap { flex-wrap: wrap; }
  .menu ul { display: flex; flex-wrap: wrap; gap: 4px 18px; padding: 0; }
  .menu a { border: 0; min-height: 44px; font-size: var(--s); color: var(--text-2); }
}

/* Хлебные крошки */
.crumbs { padding-top: 14px; font-size: var(--s); line-height: var(--s-l); color: var(--text-3); }
.crumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.crumbs li { margin: 0; }
.crumbs li + li::before { content: "/"; margin-right: 4px; color: var(--line); }
.crumbs a { color: var(--text-2); display: inline-flex; align-items: center; min-height: 44px; }

/* Первый экран и секции */
.hero { padding: 22px 0 8px; }
.lead { color: var(--text-2); max-width: 700px; }
.chips { display: flex; flex-wrap: wrap; gap: 4px 16px; list-style: none; padding: 0; margin: 12px 0 0; }
.chips li { margin: 0; font-size: var(--s); line-height: var(--s-l); color: var(--text-3); }
.block { padding: 28px 0 12px; border-top: 1px solid var(--line); }
.hero + .block { border-top: 0; }
@media (min-width: 900px) { .block { padding: 40px 0 16px; } .hero { padding: 36px 0 8px; } }

/* Карточка клуба */
.cards { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.cards > li { margin: 0; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 14px 18px; min-width: 0; box-shadow: none;
}
.card-top { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
/* Телефон: кнопки менеджера сразу после фактов, разбор оценки и ссылка - в конце карточки */
@media (max-width: 899px) {
  .card { display: flex; flex-direction: column; }
  .card-main, .card-side { display: contents; }
  .card details.why { order: 2; margin: 12px 0 0; }
  .card > .card-side > .more { order: 3; }
}
.rank {
  min-width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius); background: var(--raised); border: 1px solid var(--line);
  font: 700 var(--s)/1 var(--sans); color: var(--accent);
}
.rank.top { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.badge { display: inline-flex; align-items: center; height: 32px; padding: 0 11px; font-size: var(--s); color: var(--text-2); border: 1px solid var(--line); border-radius: 10px; }
.card h3 { margin-bottom: 6px; }
.score { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; margin: 4px 0 12px; }
.score-num { font: 700 var(--h2)/var(--h2-l) var(--serif); color: var(--text); }
.stars { position: relative; display: inline-block; font-size: var(--h3); line-height: 1; letter-spacing: 2px; color: var(--line); }
.stars::before { content: "★★★★★"; }
.stars::after { content: "★★★★★"; position: absolute; left: 0; top: 0; width: var(--p); overflow: hidden; white-space: nowrap; color: var(--star); }
.trust { margin: 0 0 12px; padding: 10px 12px; background: var(--raised); border-radius: var(--radius); color: var(--text-2); font-size: var(--s); line-height: var(--s-l); }
.trust strong { color: var(--text); }
.trust .gold { color: var(--accent); }

.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; margin: 0 0 12px; }
.facts div { min-width: 0; }
.facts dt { font-size: var(--s); line-height: var(--s-l); color: var(--text-3); }
.facts dd { margin: 2px 0 0; font-weight: 600; line-height: 1.4; overflow-wrap: anywhere; }
.facts .wide { grid-column: 1 / -1; }
.id-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.copy {
  min-height: 44px; min-width: 44px; padding: 0 12px;
  background: transparent; color: var(--accent); border: 1px solid var(--line); border-radius: var(--radius);
  font: 600 var(--s)/1 var(--sans); cursor: pointer;
}
.rb { margin: 0 0 12px; }
.rb strong { color: var(--accent); }

details.why { border-top: 1px solid var(--line); margin: 4px 0 14px; }
details.why summary, .faq summary {
  cursor: pointer; list-style: none; min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  font-weight: 600; color: var(--text);
}
details.why summary::-webkit-details-marker, .faq summary::-webkit-details-marker { display: none; }
details.why summary::after, .faq summary::after { content: "+"; color: var(--accent); font: 700 var(--h3)/1 var(--sans); }
details[open].why summary::after, .faq details[open] summary::after { content: "-"; }
.crit { list-style: none; padding: 0; margin: 0 0 6px; }
.crit li { margin: 0 0 12px; }
.crit-head { display: flex; justify-content: space-between; gap: 10px; }
.crit-head b { font-weight: 600; }
.bar { display: block; height: 6px; background: var(--raised); border-radius: 3px; margin: 6px 0 4px; overflow: hidden; }
.bar i { display: block; height: 100%; width: var(--p); background: var(--star); }

.btns { display: grid; gap: 8px; }
.btns .small { margin: 2px 0 0; }
.btn {
  display: flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 16px;
  border-radius: var(--radius); text-decoration: none; font: 700 var(--t)/1.2 var(--sans); text-align: center;
  border: 1px solid transparent;
}
.btn-tg { background: #2D7393; color: var(--on-btn); min-height: 48px; }
.btn-wa { background: transparent; color: #7FC49C; border-color: #287A52; min-height: 44px; }
.btn-wa:hover { color: #A6DDBB; }
.btn-gold { background: var(--accent); color: var(--on-accent); }
.btn-line { background: transparent; color: var(--text); border-color: var(--line); }
.btn:hover { filter: brightness(1.1); color: var(--on-btn); }
.btn-gold:hover, .btn-line:hover { color: var(--text); }
.btn-gold:hover { color: var(--on-accent); }
.more { display: inline-flex; align-items: center; min-height: 44px; margin-top: 6px; }

@media (min-width: 900px) {
  .card { display: grid; grid-template-columns: minmax(0, 2fr) 300px; gap: 8px 32px; padding: 24px 28px; align-items: start; }
  .card-main { min-width: 0; }
  .card-side { display: flex; flex-direction: column; gap: 12px; }
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 28px; }
}

/* Сетки и списки */
.grid { display: grid; gap: 12px; list-style: none; padding: 0; margin: 0; }
.grid > li { margin: 0; }
@media (min-width: 700px) { .grid.two { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .grid.four { grid-template-columns: repeat(4, 1fr); } }
.tile {
  display: block; height: 100%; padding: 16px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); color: var(--text); text-decoration: none;
}
.tile b { display: block; font: 600 var(--h3)/var(--h3-l) var(--serif); margin-bottom: 4px; }
.tile span { color: var(--text-2); }
.tile:hover { border-color: var(--accent); color: var(--text); }

.steps { list-style: none; counter-reset: s; padding: 0; margin: 0 0 14px; }
.steps li { counter-increment: s; position: relative; padding: 0 0 16px 50px; margin: 0; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; background: var(--raised); border: 1px solid var(--line);
  font: 700 var(--s)/1 var(--sans); color: var(--accent);
}
.steps b { display: block; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 0 0 14px; }

/* Таблицы: на телефоне - карточки-строки */
.table-wrap { overflow-x: auto; }
table { width: 100%; min-width: 0; border-collapse: collapse; margin: 0 0 14px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: var(--s); line-height: var(--s-l); color: var(--text-3); font-weight: 600; }
@media (max-width: 899px) {
  table.cards-sm thead { display: none; }
  table.cards-sm, table.cards-sm tbody, table.cards-sm tr, table.cards-sm td { display: block; width: 100%; }
  table.cards-sm tr { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 12px; margin-bottom: 10px; }
  table.cards-sm td { border: 0; padding: 6px 0; display: flex; justify-content: space-between; gap: 12px; }
  table.cards-sm td::before { content: attr(data-l); color: var(--text-3); font-size: var(--s); }
}

/* FAQ */
.faq details { border-bottom: 1px solid var(--line); }
.faq details > div { padding: 0 0 12px; color: var(--text-2); }

/* Кнопки магазинов */
.stores { display: grid; gap: 10px; margin: 0 0 14px; }
@media (min-width: 700px) { .stores { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* Подвал */
.foot { border-top: 1px solid var(--line); margin-top: 20px; padding: 28px 0 24px; color: var(--text-3); }
.foot nav ul { list-style: none; padding: 0; margin: 0 0 16px; display: flex; flex-wrap: wrap; gap: 0 18px; }
.foot nav li { margin: 0; }
.foot nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text-2); }
.foot p { font-size: var(--s); line-height: var(--s-l); }
.age { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 32px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); font-weight: 700; margin-right: 8px; }

/* Нижняя панель на телефоне */
.sticky {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  background: var(--bg); border-top: 1px solid var(--line);
  padding: 8px 16px calc(8px + env(safe-area-inset-bottom));
  background: rgba(16, 24, 32, .96);
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
}
.sticky .btn { min-height: 48px; }
.sticky .btn-wa { background: var(--wa); color: var(--on-btn); border-color: transparent; }
@media (min-width: 900px) { .sticky { display: none; } }

.notfound { padding: 48px 0; }
