:root {
  /* Пастельная палитра: тёплая бумага + ледяные и мятные акценты. */
  --paper: #f6f3ee;
  --paper-2: #fbf9f5;
  --panel: #ffffff;
  --panel-2: #f0f5f8;
  --line: #e2dfd7;
  --line-soft: #ece9e2;

  --ink: #2c3a44;
  --ink-dim: #5f7180;
  --ink-faint: #93a2ad;

  --ice: #7cb3d4;
  --ice-deep: #4d8bb0;
  --ice-soft: #e2eff7;

  --mint: #8ecdb4;
  --mint-deep: #4f9e80;
  --mint-soft: #e3f3ec;

  --blush: #e6a6ae;
  --blush-deep: #c2707c;
  --blush-soft: #fae9eb;

  --lav: #b3a9d6;
  --lav-deep: #7f74a8;
  --lav-soft: #ece9f6;

  --sun: #dda85f;
  --sun-deep: #b57f36;
  --sun-soft: #fbeeda;

  --radius: 16px;
  --shadow-sm: 0 4px 14px -8px rgba(44, 58, 68, .35);
  --shadow: 0 16px 34px -24px rgba(44, 58, 68, .55);

  --font-display: "Roboto", "Roboto Condensed", Arial, system-ui, sans-serif;
  --font-body: "Roboto", Arial, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.65 var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.glow {
  position: fixed;
  inset: -20vh -10vw auto;
  height: 80vh;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(46% 42% at 18% 22%, rgba(124, 179, 212, .30), transparent 72%),
    radial-gradient(42% 38% at 80% 12%, rgba(179, 169, 214, .24), transparent 72%),
    radial-gradient(38% 34% at 52% 44%, rgba(142, 205, 180, .22), transparent 72%);
  filter: blur(28px);
}

.wrap { width: min(1180px, calc(100% - 32px)); margin-inline: auto; position: relative; z-index: 1; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 700; letter-spacing: -.02em; }

a { color: var(--ice-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Шапка ──────────────────────────────────────────── */

.site-head {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(251, 249, 245, .92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.head-top { display: flex; align-items: center; gap: 14px; padding: 14px 0 12px; flex-wrap: wrap; }

.brand { order: 1; display: flex; align-items: center; gap: 12px; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand-mark { font-size: 28px; line-height: 1; }
.brand-text { display: flex; flex-direction: column; font-family: var(--font-display); font-size: 19px; line-height: 1.2; }
.brand-text b { color: var(--ice-deep); font-weight: 700; }
.brand-text small {
  font-family: var(--font-body); color: var(--ink-faint);
  font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-top: 3px;
}

.head-tools { order: 3; margin-left: auto; display: flex; align-items: center; gap: 8px; }

.nav-toggle {
  display: none;
  background: var(--panel); color: var(--ink); border: 1px solid var(--line);
  border-radius: 10px; padding: 9px 13px; font-size: 17px; cursor: pointer;
}

.langpick {
  width: auto; min-width: 120px; padding: 8px 10px; font-size: 14px;
  background: var(--panel); border-color: var(--line); cursor: pointer;
}

#nav { order: 2; margin-left: auto; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
#nav a {
  color: var(--ink-dim); padding: 8px 14px; border-radius: 10px;
  font-size: 15px; font-weight: 500; white-space: nowrap; border: 1px solid transparent;
}
#nav a:hover { color: var(--ink); background: var(--panel); border-color: var(--line-soft); text-decoration: none; }
#nav a.active { color: var(--ice-deep); background: var(--ice-soft); border-color: #cbe1ef; font-weight: 600; }

/* ── Полоса дней ────────────────────────────────────── */

.daybar-outer { border-top: 1px solid var(--line-soft); background: rgba(255, 255, 255, .55); }
.daybar {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px;
  padding: 12px 0 14px;
}

.daybtn {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
  min-width: 0;
}
.daybtn:hover { text-decoration: none; transform: translateY(-2px); box-shadow: 0 12px 22px -16px rgba(44, 58, 68, .6); }
.daybtn .d-ico { font-size: 26px; line-height: 1; flex: none; }
.daybtn .d-txt { display: flex; flex-direction: column; min-width: 0; }
.daybtn .d-n { font-size: 11.5px; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-faint); }
.daybtn .d-title {
  font-family: var(--font-display); font-size: 17px; font-weight: 700; line-height: 1.25;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.daybtn[data-day="1"] { background: linear-gradient(180deg, #fff, var(--ice-soft)); border-color: #cfe3f0; }
.daybtn[data-day="2"] { background: linear-gradient(180deg, #fff, var(--lav-soft)); border-color: #ddd8ee; }
.daybtn[data-day="3"] { background: linear-gradient(180deg, #fff, var(--mint-soft)); border-color: #cfe8de; }
.daybtn[data-day="4"] { background: linear-gradient(180deg, #fff, var(--blush-soft)); border-color: #f0d5d9; }
.daybtn[data-day="5"] { background: linear-gradient(180deg, #fff, var(--sun-soft)); border-color: #f0dcbe; }

.daybtn[data-day="1"] .d-title { color: var(--ice-deep); }
.daybtn[data-day="2"] .d-title { color: var(--lav-deep); }
.daybtn[data-day="3"] .d-title { color: var(--mint-deep); }
.daybtn[data-day="4"] .d-title { color: var(--blush-deep); }
.daybtn[data-day="5"] .d-title { color: var(--sun-deep); }

.daybtn.active { transform: translateY(-1px); }
.daybtn[data-day="1"].active { border-color: var(--ice); box-shadow: 0 0 0 3px rgba(124, 179, 212, .22); }
.daybtn[data-day="2"].active { border-color: var(--lav); box-shadow: 0 0 0 3px rgba(179, 169, 214, .22); }
.daybtn[data-day="3"].active { border-color: var(--mint); box-shadow: 0 0 0 3px rgba(142, 205, 180, .24); }
.daybtn[data-day="4"].active { border-color: var(--blush); box-shadow: 0 0 0 3px rgba(230, 166, 174, .24); }
.daybtn[data-day="5"].active { border-color: var(--sun); box-shadow: 0 0 0 3px rgba(221, 168, 95, .24); }

/* ── Блоки ──────────────────────────────────────────── */

main { padding: 32px 0 60px; }

.hero {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(155deg, #ffffff 0%, var(--ice-soft) 58%, var(--lav-soft) 100%);
  padding: 38px 34px;
  box-shadow: var(--shadow);
  margin-bottom: 26px;
}
.hero h1 { margin: 0 0 12px; font-size: clamp(28px, 4.4vw, 44px); line-height: 1.12; }
.hero h1 span { color: var(--ice-deep); }
.hero p { margin: 0 0 10px; color: var(--ink-dim); max-width: 72ch; font-size: 16.5px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ice-deep); color: #fff; border: 1.5px solid var(--ice-deep);
  padding: 11px 20px; border-radius: 12px; font-weight: 600; font-size: 15px;
  cursor: pointer; box-shadow: var(--shadow-sm); font-family: var(--font-body);
}
.btn:hover { background: #3f7ba1; border-color: #3f7ba1; text-decoration: none; color: #fff; }
.btn.ghost { background: var(--panel); color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { background: var(--paper-2); color: var(--ice-deep); border-color: var(--ice); }
.btn:disabled { opacity: .5; cursor: default; }

.card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
}
.card > h2 { margin: 0 0 5px; font-size: 22px; }
.card > h2 + .sub { margin: 0 0 18px; color: var(--ink-faint); font-size: 14px; }

.grid { display: grid; gap: 18px; }
.grid.c2 { grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); }
.grid.c3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }

.muted { color: var(--ink-faint); font-size: 14px; }

/* ── Карточки дней на главной ───────────────────────── */

.daylink {
  display: block; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); padding: 20px; color: var(--ink);
  box-shadow: var(--shadow-sm);
  transition: transform .16s ease, border-color .16s ease;
}
.daylink:hover { border-color: var(--ice); transform: translateY(-3px); text-decoration: none; }
.daylink .n { color: var(--ink-faint); font-size: 11.5px; text-transform: uppercase; letter-spacing: .09em; }
.daylink h3 { margin: 7px 0 8px; font-size: 19px; }
.daylink .ico { font-size: 27px; }
.daylink p { margin: 0; color: var(--ink-dim); font-size: 14.5px; }

.daylink[data-day="1"] { background: linear-gradient(170deg, #fff 55%, var(--ice-soft)); }
.daylink[data-day="2"] { background: linear-gradient(170deg, #fff 55%, var(--lav-soft)); }
.daylink[data-day="3"] { background: linear-gradient(170deg, #fff 55%, var(--mint-soft)); }
.daylink[data-day="4"] { background: linear-gradient(170deg, #fff 55%, var(--blush-soft)); }
.daylink[data-day="5"] { background: linear-gradient(170deg, #fff 55%, var(--sun-soft)); }

/* ── Шапка дня ──────────────────────────────────────── */

.day-head {
  display: flex; align-items: flex-start; gap: 20px; flex-wrap: wrap;
  border: 1px solid var(--line); border-radius: 22px;
  background: linear-gradient(155deg, #ffffff 0%, var(--ice-soft) 100%);
  padding: 30px 32px; margin-bottom: 22px; box-shadow: var(--shadow);
}
.day-head[data-day="2"] { background: linear-gradient(155deg, #fff 0%, var(--lav-soft) 100%); }
.day-head[data-day="3"] { background: linear-gradient(155deg, #fff 0%, var(--mint-soft) 100%); }
.day-head[data-day="4"] { background: linear-gradient(155deg, #fff 0%, var(--blush-soft) 100%); }
.day-head[data-day="5"] { background: linear-gradient(155deg, #fff 0%, var(--sun-soft) 100%); }
.day-head .big { font-size: 52px; line-height: 1; }
.day-head h1 { margin: 2px 0 6px; font-size: clamp(25px, 3.6vw, 36px); }
.day-head .when { color: var(--sun-deep); font-size: 14px; font-weight: 600; }
.day-head p { margin: 14px 0 0; color: var(--ink-dim); max-width: 76ch; }

.pill {
  display: inline-block; padding: 4px 13px; border-radius: 999px; font-size: 13px;
  font-family: var(--font-body); font-weight: 600; letter-spacing: .01em;
  border: 1px solid var(--line); color: var(--ink-dim); background: var(--panel-2);
}
.pill.hi { color: var(--mint-deep); background: var(--mint-soft); border-color: #cfe8de; }
.pill.mid { color: var(--sun-deep); background: var(--sun-soft); border-color: #f0dcbe; }
.pill.lo { color: var(--ink-faint); background: var(--panel-2); }

.pts-list { list-style: none; margin: 0; padding: 0; }
.pts-list li {
  display: flex; align-items: baseline; gap: 14px; justify-content: space-between;
  padding: 10px 0; border-bottom: 1px solid var(--line-soft);
}
.pts-list li:last-child { border-bottom: 0; }
.pts-list .v {
  font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap;
  color: var(--sun-deep); background: var(--sun-soft);
  padding: 2px 10px; border-radius: 999px; font-size: 14px;
}
.pts-list .v.small { color: var(--ink-dim); background: var(--panel-2); font-weight: 600; }

ol.tips { margin: 0; padding-left: 22px; }
ol.tips li { margin-bottom: 11px; color: var(--ink-dim); padding-left: 4px; }
ol.tips li::marker { color: var(--ice-deep); font-weight: 700; }

ul.plain { margin: 0; padding-left: 22px; color: var(--ink-dim); }
ul.plain li { margin-bottom: 8px; }
ul.plain li::marker { color: var(--ice); }
ul.plain b { color: var(--ink); }

.note {
  border-left: 4px solid var(--ice);
  background: var(--ice-soft);
  border-radius: 0 12px 12px 0;
  padding: 14px 18px;
  color: var(--ink-dim);
  font-size: 15px;
  margin: 18px 0 0;
}
.note b { color: var(--ink); }
.note.alliance { border-left-color: var(--sun); background: var(--sun-soft); }

/* ── Таблицы ────────────────────────────────────────── */

.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
table { border-collapse: collapse; width: 100%; font-size: 14px; min-width: 560px; }
th, td { padding: 10px 13px; text-align: right; border-bottom: 1px solid var(--line-soft); white-space: nowrap; }
th:first-child, td:first-child { text-align: left; }
th {
  background: var(--panel-2); color: var(--ink-dim); font-weight: 600;
  position: sticky; top: 0; font-size: 13px;
}
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--paper-2); }
tfoot td { font-weight: 700; background: var(--panel-2); border-top: 1px solid var(--line); }
td.num, th.num { font-variant-numeric: tabular-nums; }
td.svs { color: var(--sun-deep); font-weight: 700; }

.matrix td, .matrix th { text-align: center; }
.matrix td:first-child, .matrix th:first-child { text-align: left; }
.mk {
  display: inline-block; min-width: 30px; padding: 3px 0; border-radius: 8px; font-size: 15px;
}
.mk.best { background: var(--mint-soft); }
.mk.ok { background: var(--sun-soft); }
.mk.no { background: var(--blush-soft); opacity: .8; }

/* ── Формы ──────────────────────────────────────────── */

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 13px; }
.field label { font-size: 13px; color: var(--ink-dim); font-weight: 500; }
input, select, textarea {
  background: var(--paper-2); color: var(--ink);
  border: 1.5px solid var(--line); border-radius: 10px;
  padding: 9px 11px; font: inherit; font-size: 15px; width: 100%;
  font-family: var(--font-body);
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--ice); background: #fff;
  box-shadow: 0 0 0 3px rgba(124, 179, 212, .22);
}

.rowfields { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.tabs { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.tabs button {
  background: var(--panel); color: var(--ink-dim); border: 1.5px solid var(--line);
  padding: 10px 18px; border-radius: 11px; cursor: pointer;
  font-family: var(--font-body); font-size: 15px; font-weight: 500;
}
.tabs button:hover { border-color: var(--ice); color: var(--ink); }
.tabs button.active { background: var(--ice-soft); color: var(--ice-deep); border-color: var(--ice); font-weight: 600; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 4px 0 20px; }
.stat { border: 1px solid var(--line); border-radius: 14px; background: var(--paper-2); padding: 14px 16px; }
.stat .k { color: var(--ink-faint); font-size: 11.5px; text-transform: uppercase; letter-spacing: .07em; }
.stat .v { font-family: var(--font-display); font-size: 23px; font-weight: 700; font-variant-numeric: tabular-nums; margin-top: 4px; }
.stat.gold { background: var(--sun-soft); border-color: #f0dcbe; }
.stat.gold .v { color: var(--sun-deep); }
.stat.ice { background: var(--ice-soft); border-color: #cfe3f0; }
.stat.ice .v { color: var(--ice-deep); }
.stat.neg { background: var(--blush-soft); border-color: #f0d5d9; }
.stat.neg .v { color: var(--blush-deep); }

.empty {
  color: var(--ink-faint); padding: 30px; text-align: center;
  border: 1.5px dashed var(--line); border-radius: 14px; background: var(--paper-2);
}

/* ── Обзор «было → стало» ───────────────────────────── */

.ba { margin: 6px 0 26px; }
.ba-title { margin: 26px 0 4px; font-size: 19px; }
.ba:first-child .ba-title { margin-top: 0; }
.ba-hint { margin: 0 0 14px; }
.ba-list { display: flex; flex-direction: column; gap: 10px; }

.ba-row {
  display: grid;
  grid-template-columns: minmax(140px, 1.1fr) auto minmax(120px, .7fr);
  gap: 16px; align-items: center;
  border: 1px solid var(--line); border-radius: 14px;
  background: linear-gradient(180deg, #fff, var(--paper-2));
  padding: 12px 18px;
}
.ba-name { font-weight: 500; }
.ba-pair { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: center; }
.ba-badges { display: inline-flex; gap: 6px; align-items: center; }
.ba-badges.was { opacity: .55; filter: saturate(.6); }
.ba-arrow { color: var(--ink-faint); font-size: 20px; }
.ba-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.ba-delta {
  font-size: 12.5px; font-weight: 600; white-space: nowrap;
  color: var(--mint-deep); background: var(--mint-soft);
  border: 1px solid #cfe8de; padding: 3px 11px; border-radius: 999px;
}
.ba-pts {
  font-size: 12.5px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums;
  color: var(--sun-deep); background: var(--sun-soft);
  border: 1px solid #f0dcbe; padding: 3px 11px; border-radius: 999px;
}

/* Плашка уровня здания — как на иконке постройки в игре. */
.lvl {
  display: inline-flex; flex-direction: column; align-items: center; gap: 1px;
  min-width: 66px; padding: 7px 12px; border-radius: 11px;
  border: 1.5px solid; line-height: 1.1;
}
.lvl-main { font-weight: 700; font-size: 15px; font-variant-numeric: tabular-nums; }
.lvl-stars { font-size: 9px; letter-spacing: 1.5px; }
.lvl .on { color: #e8a33c; }
.lvl .off { color: #ccd6de; }
.lvl.plain { background: linear-gradient(180deg, #f3f7fa, #e6edf3); border-color: #d3dee6; color: #4d616f; }
.lvl.star { background: linear-gradient(180deg, #f1f7fc, #dbeaf5); border-color: #bcd8e9; color: #326a8e; }
.lvl.fc { background: linear-gradient(180deg, #fff0e2, #ffd9bc); border-color: #f0b184; color: #a4501a; }

/* Плашка Chief Gear — цвет редкости, тир и звёзды. */
.gbadge {
  display: inline-flex; flex-direction: column; align-items: center; gap: 1px;
  min-width: 104px; padding: 7px 12px; border-radius: 11px;
  border: 1.5px solid; line-height: 1.15;
}
.gbadge-top { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: 14px; }
.gbadge-tier { font-size: 10.5px; font-weight: 700; padding: 1px 6px; border-radius: 6px; background: rgba(255, 255, 255, .75); }
.gbadge .lvl-stars { font-size: 9px; letter-spacing: 1.5px; }
.gbadge .on { color: #e8a33c; }
.gbadge .off { color: rgba(0, 0, 0, .18); }
.g-green { background: linear-gradient(180deg, #eff8ef, #dcf0dd); border-color: #b6ddb8; color: #3f7f45; }
.g-blue { background: linear-gradient(180deg, #eaf3fb, #d7e9f7); border-color: #a9cdea; color: #31688c; }
.g-purple { background: linear-gradient(180deg, #f2ecfa, #e5daf6); border-color: #c7b3e6; color: #6b4e9c; }
.g-gold { background: linear-gradient(180deg, #fdf3e0, #f8e6c4); border-color: #e6c684; color: #95701f; }
.g-pink { background: linear-gradient(180deg, #fdeaf3, #f9d8e8); border-color: #eeadcd; color: #a8447a; }

/* Плашка чарма — три слота на предмет, как в окне снаряжения. */
.cbadge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 10px;
  font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums;
  border: 1.5px solid #bcd8e9; color: #326a8e;
  background: linear-gradient(180deg, #f1f7fc, #dbeaf5);
}
.cbadge.max { border-color: #e6c684; color: #95701f; background: linear-gradient(180deg, #fdf3e0, #f8e6c4); }

@media (max-width: 720px) {
  .ba-row { grid-template-columns: 1fr; gap: 10px; }
  .ba-pair { justify-content: flex-start; }
  .ba-meta { flex-direction: row; align-items: center; }
}

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 200px 1fr; gap: 18px; padding: 15px 0; border-bottom: 1px solid var(--line-soft); }
.timeline li:last-child { border-bottom: 0; }
.timeline .st { font-family: var(--font-display); font-weight: 700; font-size: 17px; }
.timeline .wh { color: var(--ice-deep); font-size: 13.5px; font-weight: 600; }
.timeline p { margin: 0; color: var(--ink-dim); font-size: 15px; }

/* ── Герои по поколениям ────────────────────────────── */

.genbar {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 8px;
}
.genchip {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  padding: 9px 12px; border-radius: 11px; cursor: pointer;
  border: 1.5px solid var(--line); background: var(--paper-2); color: var(--ink);
  font-family: var(--font-body); text-align: left; min-width: 0;
}
.genchip:hover { border-color: var(--ice); background: var(--ice-soft); }
.genchip.active { border-color: var(--ice); background: var(--ice-soft); box-shadow: 0 0 0 3px rgba(124, 179, 212, .2); }
.genchip .gc-n { font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-faint); }
.genchip.active .gc-n { color: var(--ice-deep); }
.genchip .gc-h {
  font-weight: 700; font-size: 14px; max-width: 100%;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.gen-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.gen-head h2 { margin: 4px 0 0; font-size: 24px; }

.heropick {
  border: 1px solid var(--line); border-left-width: 4px; border-radius: 0 14px 14px 0;
  background: linear-gradient(180deg, #fff, var(--paper-2)); padding: 13px 18px;
}
.heropick.tier-free { border-left-color: var(--mint); }
.heropick.tier-easy { border-left-color: var(--sun); }
.heropick.tier-hard { border-left-color: var(--lav); }
.hp-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.hp-name { font-family: var(--font-display); font-weight: 700; font-size: 17px; }
.hp-cls { font-size: 12.5px; color: var(--ink-faint); }
.hp-tier {
  margin-left: auto; font-size: 12px; font-weight: 600; white-space: nowrap;
  padding: 3px 11px; border-radius: 999px; border: 1px solid;
}
.tier-free .hp-tier { color: var(--mint-deep); background: var(--mint-soft); border-color: #cfe8de; }
.tier-easy .hp-tier { color: var(--sun-deep); background: var(--sun-soft); border-color: #f0dcbe; }
.tier-hard .hp-tier { color: var(--lav-deep); background: var(--lav-soft); border-color: #ddd8ee; }
.hp-text { margin: 0; color: var(--ink-dim); font-size: 14.5px; }

/* ── Списки шагов и вердикты (Dawn Academy) ─────────── */

.steplist { list-style: none; counter-reset: step; margin: 0; padding: 0; }
.steplist li {
  counter-increment: step;
  position: relative; padding: 12px 0 12px 40px;
  border-top: 1px solid var(--line-soft); color: var(--ink-dim); font-size: 14.5px;
}
.steplist li:first-child { border-top: 0; }
.steplist li::before {
  content: counter(step);
  position: absolute; left: 0; top: 12px;
  width: 26px; height: 26px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  background: var(--ice-soft); border: 1px solid #cfe3f0; color: var(--ice-deep);
  font-weight: 700; font-size: 13px;
}
.steplist b { display: block; color: var(--ink); margin-bottom: 3px; }

.tier {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 7px; font-size: 12px; border: 1px solid;
}
.tier.t-top { background: var(--mint-soft); border-color: #cfe8de; color: var(--mint-deep); }
.tier.t-good { background: var(--ice-soft); border-color: #cfe3f0; color: var(--ice-deep); }
.tier.t-situational { background: var(--sun-soft); border-color: #f0dcbe; color: var(--sun-deep); }
.tier.t-skip { background: var(--blush-soft); border-color: #f0d5d9; color: var(--blush-deep); }
.tier.t-whale { background: var(--lav-soft); border-color: #ddd8ee; color: var(--lav-deep); }

td.wrap-cell { white-space: normal; min-width: 240px; }

/* ── Разделы дня (ветки исследований) ───────────────── */

.treeblock {
  border-left: 4px solid var(--ice);
  background: var(--paper-2);
  border-radius: 0 12px 12px 0;
  padding: 14px 18px;
  margin-top: 16px;
}
.treeblock:nth-of-type(2) { border-left-color: var(--mint); }
.treeblock:nth-of-type(3) { border-left-color: var(--blush); }
.treeblock h3 { margin: 0 0 4px; font-size: 18px; }
.treeblock > .muted { margin: 0 0 12px; }

.deflist { list-style: none; margin: 0; padding: 0; }
.deflist li {
  padding: 8px 0; border-top: 1px solid var(--line-soft);
  color: var(--ink-dim); font-size: 14.5px;
}
.deflist li:first-child { border-top: 0; padding-top: 0; }
.deflist b { color: var(--ink); }

/* ── Приоритет прокачки зданий ──────────────────────── */

.prio-col { width: 34px; text-align: center !important; padding-left: 8px; padding-right: 4px; }
.prio {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 8px;
  font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums;
  background: var(--ice-soft); border: 1px solid #cfe3f0; color: var(--ice-deep);
}
.prio.skip { background: var(--blush-soft); border-color: #f0d5d9; color: var(--blush-deep); cursor: help; }
.prio.none { background: var(--panel-2); border-color: var(--line); color: var(--ink-faint); }
tr.row-skip td { opacity: .72; }

.checkline {
  display: flex; align-items: center; gap: 9px;
  margin: 0 0 14px; font-size: 14.5px; color: var(--ink-dim); cursor: pointer;
}
.checkline input { width: auto; margin: 0; accent-color: var(--ice-deep); }

/* ── Модалка выбора языка ───────────────────────────── */

.modal-back {
  position: fixed; inset: 0; z-index: 80;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  background: rgba(44, 58, 68, .38); backdrop-filter: blur(6px);
}
.modal-back[hidden] { display: none; }
.modal {
  width: min(460px, 100%); background: var(--panel);
  border: 1px solid var(--line); border-radius: 22px;
  padding: 30px 28px; text-align: center;
  box-shadow: 0 30px 60px -30px rgba(44, 58, 68, .7);
}
.modal-mark { font-size: 42px; line-height: 1; }
.modal h2 { margin: 12px 0 6px; font-size: 24px; }
.modal .muted { margin: 0 0 22px; }
.langgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.langbtn {
  display: flex; align-items: center; gap: 10px; justify-content: flex-start;
  padding: 13px 16px; border-radius: 13px;
  border: 1.5px solid var(--line); background: var(--paper-2); color: var(--ink);
  font-family: var(--font-body); font-size: 15px; font-weight: 500; cursor: pointer;
}
.langbtn:hover { border-color: var(--ice); background: var(--ice-soft); }
.langflag { font-size: 22px; line-height: 1; }

/* ── Доска заметок ──────────────────────────────────── */

.notes-gate { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.notes-gate .btn { flex: none; }
.notes-as {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-bottom: 10px; color: var(--ink-dim); font-size: 14px;
}
.linkish {
  background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--ice-deep); font: inherit; text-decoration: underline;
}
.notes-err {
  margin-top: 12px; padding: 10px 14px; border-radius: 10px;
  background: var(--blush-soft); border: 1px solid #f0d5d9; color: var(--blush-deep); font-size: 14px;
}
.notes-list { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.note-item {
  border: 1px solid var(--line); border-radius: 14px;
  background: linear-gradient(180deg, #fff, var(--paper-2)); padding: 13px 17px;
}
.note-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 5px; }
.note-nick { font-weight: 700; color: var(--ice-deep); }
.note-date { color: var(--ink-faint); font-size: 12.5px; }
.note-del {
  margin-left: auto; background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--blush-deep); font: inherit; font-size: 13px; text-decoration: underline;
}
.note-text { white-space: pre-wrap; color: var(--ink); }

/* ── Подвал ─────────────────────────────────────────── */

.site-foot { border-top: 1px solid var(--line); background: var(--paper-2); padding: 28px 0 36px; margin-top: 34px; }
.foot-inner { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; align-items: center; }
.made {
  font-family: var(--font-display); font-size: 16px; font-weight: 500; color: var(--ink);
  border: 1px solid var(--line); border-radius: 999px; padding: 9px 22px;
  background: var(--panel); box-shadow: var(--shadow-sm);
}
.made b { color: var(--ice-deep); }

@media (max-width: 1000px) {
  .daybar { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(190px, 1fr); overflow-x: auto; scrollbar-width: thin; }
  .daybtn { scroll-snap-align: start; }
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .langpick { min-width: 0; max-width: 130px; }
  #nav {
    display: none; width: 100%; order: 4; flex-direction: column; align-items: stretch;
    gap: 4px; padding-top: 10px; border-top: 1px solid var(--line-soft); margin-top: 12px;
  }
  #nav.open { display: flex; }
  .timeline li { grid-template-columns: 1fr; gap: 4px; }
  .hero { padding: 28px 22px; }
  .day-head { padding: 24px 20px; }
}
