/* ==========================================================================
   «Блок Дня» — премиальный крипто-портал. Тёмный новостной журнал.
   Токены, сетка, компоненты. Светлая тема включается атрибутом
   data-theme="light" на <html>.
   ========================================================================== */

:root {
  --bg: #0b0f19;
  --bg-soft: #0e1322;
  --card: #121826;
  --card-hi: #182035;
  --line: rgba(230, 234, 242, 0.08);
  --line-strong: rgba(230, 234, 242, 0.16);
  --text: #e6eaf2;
  --muted: #8a94a7;
  --accent: #2f6bff;
  --accent-soft: rgba(47, 107, 255, 0.14);
  --accent2: #19d3c5;
  --accent2-soft: rgba(25, 211, 197, 0.14);
  --up: #19d3c5;
  --down: #ff5a6e;
  --shadow: 0 18px 48px rgba(3, 6, 16, 0.55);
  --radius: 18px;
  --radius-sm: 12px;
  --radius-pill: 999px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
    'Noto Sans', sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;
  --container: 1280px;
}

html[data-theme='light'] {
  --bg: #f4f6fb;
  --bg-soft: #eaeef7;
  --card: #ffffff;
  --card-hi: #f2f5fc;
  --line: rgba(14, 21, 38, 0.1);
  --line-strong: rgba(14, 21, 38, 0.18);
  --text: #0e1526;
  --muted: #5b6577;
  --accent: #1e56e0;
  --accent-soft: rgba(30, 86, 224, 0.1);
  --accent2: #0aa79b;
  --accent2-soft: rgba(10, 167, 155, 0.12);
  --up: #0aa79b;
  --down: #d92a45;
  --shadow: 0 16px 40px rgba(19, 33, 68, 0.12);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Атрибут hidden должен побеждать любой display из классов:
   иначе модальное окно и плавающий баннер перекрывают страницу. */
[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

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

a:hover {
  color: var(--accent2);
}

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

h1,
h2,
h3,
h4 {
  margin: 0 0 0.5em;
  line-height: 1.16;
  letter-spacing: -0.02em;
  font-weight: 800;
}

p {
  margin: 0 0 1em;
}

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 28px 0;
}

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

:focus-visible {
  outline: 2px solid var(--accent2);
  outline-offset: 2px;
  border-radius: 6px;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--accent);
  color: #fff;
  padding: 10px 16px;
  border-radius: 0 0 10px 0;
}

.skip-link:focus {
  left: 0;
  color: #fff;
}

/* ---------- Шапка ---------- */

.bd-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}

@supports not (background: color-mix(in srgb, red 50%, blue)) {
  .bd-header {
    background: var(--bg);
  }
}

.bd-header__top {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 72px;
  padding: 10px 0;
}

/* Длинные подписи не должны выдавливать поиск и кнопку из шапки. */
.bd-header__top > * {
  min-width: 0;
}

.bd-nav {
  flex: 0 0 auto;
}

.bd-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 22px;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.bd-logo__mark {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: 0 10px 26px rgba(47, 107, 255, 0.35);
  color: #fff;
  font-size: 17px;
}

.bd-logo__text em {
  font-style: normal;
  color: var(--accent2);
}

.bd-logo__tag {
  display: block;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.bd-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: 8px;
}

.bd-nav__link {
  padding: 9px 12px;
  border-radius: var(--radius-pill);
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.bd-nav__link:hover {
  background: var(--card-hi);
  color: var(--text);
}

.bd-nav__link.is-active {
  background: var(--accent-soft);
  color: var(--accent);
}

html[data-theme='light'] .bd-nav__link.is-active {
  color: var(--accent);
}

.bd-header__tools {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  flex: 0 1 auto;
}

.bd-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 7px 14px;
  flex: 0 1 220px;
  min-width: 118px;
}

.bd-search input {
  border: 0;
  background: transparent;
  outline: none;
  width: 100%;
  font-size: 15px;
}

.bd-search input::placeholder {
  color: var(--muted);
}

.bd-search__icon {
  color: var(--muted);
}

.bd-icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--card);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.bd-icon-btn:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong);
}

.bd-burger {
  display: none;
}

.bd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 0;
  border-radius: var(--radius-pill);
  padding: 12px 20px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.bd-btn:hover {
  transform: translateY(-1px);
}

.bd-btn--tg {
  background: linear-gradient(135deg, #2aabee, #229ed9);
  color: #fff;
  box-shadow: 0 12px 28px rgba(34, 158, 217, 0.32);
}

.bd-btn--tg:hover {
  color: #fff;
}

.bd-btn--accent {
  background: linear-gradient(135deg, var(--accent), #5b8cff);
  color: #fff;
  box-shadow: 0 12px 28px rgba(47, 107, 255, 0.32);
}

.bd-btn--accent:hover {
  color: #fff;
}

.bd-btn--ghost {
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--text);
}

.bd-btn--block {
  width: 100%;
}

.bd-btn--sm {
  padding: 9px 15px;
  font-size: 14px;
}

.bd-btn[disabled] {
  opacity: 0.55;
  cursor: progress;
  transform: none;
}

.bd-nav-drawer {
  display: none;
  padding: 12px 0 18px;
  border-top: 1px solid var(--line);
}

.bd-nav-drawer__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.bd-nav-drawer__link {
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-weight: 600;
}

/* ---------- Рекламный слот под шапкой ---------- */

.bd-ad {
  margin: 18px 0;
}

.bd-ad__inner {
  position: relative;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--card), var(--bg-soft));
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
  min-height: 90px;
  padding: 12px;
  text-align: center;
  overflow: hidden;
}

.bd-ad__inner--banner {
  border-style: solid;
}

.bd-ad__label {
  position: absolute;
  top: 6px;
  left: 10px;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.bd-ad__hint {
  color: var(--muted);
  font-size: 13px;
  max-width: 560px;
}

.bd-ad--sidebar .bd-ad__inner {
  min-height: 260px;
}

.bd-ad--inline {
  margin: 26px 0;
}

.bd-ad--inline .bd-ad__inner {
  min-height: 110px;
}

/* ---------- Тренды и бегущая строка ---------- */

.bd-strip {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.bd-strip__row {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 52px;
  overflow: hidden;
}

.bd-trend {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1 1 auto;
}

.bd-trend__label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent2);
  white-space: nowrap;
}

.bd-trend__pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent2);
  box-shadow: 0 0 0 0 rgba(25, 211, 197, 0.7);
  animation: bd-pulse 2.2s infinite;
}

@keyframes bd-pulse {
  70% {
    box-shadow: 0 0 0 10px rgba(25, 211, 197, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(25, 211, 197, 0);
  }
}

.bd-trend__list {
  display: flex;
  align-items: center;
  gap: 18px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.bd-trend__list::-webkit-scrollbar {
  display: none;
}

.bd-trend__item {
  white-space: nowrap;
  font-size: 14px;
  color: var(--text);
  opacity: 0.86;
}

.bd-trend__item:hover {
  opacity: 1;
}

.bd-ticker {
  flex: 0 0 auto;
  width: min(520px, 42vw);
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}

.bd-ticker__track {
  display: flex;
  gap: 26px;
  width: max-content;
  animation: bd-marquee 42s linear infinite;
}

.bd-ticker:hover .bd-ticker__track {
  animation-play-state: paused;
}

@keyframes bd-marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.bd-coin {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  font-size: 13.5px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.bd-coin__sym {
  font-weight: 800;
  letter-spacing: 0.04em;
}

.bd-coin__price {
  color: var(--muted);
}

.bd-coin__chg {
  font-weight: 700;
  font-size: 12.5px;
}

.bd-coin__chg.is-up {
  color: var(--up);
}

.bd-coin__chg.is-down {
  color: var(--down);
}

/* ---------- Сетка страницы ---------- */

.bd-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 36px;
  align-items: start;
  padding: 28px 0 56px;
}

.bd-main {
  min-width: 0;
}

.bd-aside {
  display: grid;
  gap: 22px;
  position: sticky;
  top: 96px;
}

.bd-section {
  margin-bottom: 38px;
}

.bd-section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.bd-section__title {
  font-size: 22px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.bd-section__title::before {
  content: '';
  width: 4px;
  height: 22px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--accent), var(--accent2));
}

.bd-section__more {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}

.bd-panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}

.bd-panel__title {
  font-size: 17px;
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 9px;
}

/* ---------- Герой главной ---------- */

.bd-hero {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 18px;
  margin-bottom: 34px;
}

.bd-lead-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 460px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--card);
  isolation: isolate;
}

.bd-lead-card__media {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.bd-lead-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bd-lead-card__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11, 15, 25, 0.05) 20%, rgba(11, 15, 25, 0.92) 78%);
}

.bd-lead-card__body {
  padding: 26px 28px 28px;
}

.bd-lead-card__title {
  font-size: clamp(24px, 2.5vw, 36px);
  color: #fff;
  margin-bottom: 10px;
}

.bd-lead-card__lead {
  color: rgba(230, 234, 242, 0.82);
  margin-bottom: 14px;
  font-size: 16px;
}

.bd-lead-card .bd-meta {
  color: rgba(230, 234, 242, 0.7);
}

.bd-hero__side {
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.bd-card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  height: 100%;
}

.bd-card:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
}

.bd-card__media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(135deg, #1a2540, #0f1626);
}

.bd-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.bd-card:hover .bd-card__media img {
  transform: scale(1.04);
}

.bd-card__body {
  padding: 16px 18px 18px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  flex: 1;
}

.bd-card__title {
  font-size: 18px;
  line-height: 1.28;
  margin: 0;
}

.bd-card--sm .bd-card__title {
  font-size: 16px;
}

.bd-card--row {
  flex-direction: row;
  align-items: stretch;
}

.bd-card--row .bd-card__media {
  flex: 0 0 132px;
  aspect-ratio: auto;
  min-height: 96px;
}

.bd-card--row .bd-card__body {
  padding: 14px 16px;
}

.bd-card--flat {
  background: transparent;
  border: 0;
  border-radius: 0;
}

.bd-card--flat:hover {
  transform: none;
  box-shadow: none;
}

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

.bd-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent2);
  background: var(--accent2-soft);
  border-radius: var(--radius-pill);
  padding: 5px 10px;
}

.bd-chip--accent {
  color: var(--accent);
  background: var(--accent-soft);
}

.bd-chip--muted {
  color: var(--muted);
  background: var(--card-hi);
}

.bd-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}

.bd-meta__dot::before {
  content: '•';
  margin-right: 10px;
  opacity: 0.6;
}

.bd-grid {
  display: grid;
  gap: 18px;
}

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

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

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

.bd-list {
  display: grid;
  gap: 14px;
}

/* ---------- Лента ---------- */

.bd-feed__item {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 18px;
  padding: 18px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, transform 0.18s ease;
}

.bd-feed__item:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
}

.bd-feed__media {
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #1a2540, #0f1626);
}

.bd-feed__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bd-feed__title {
  font-size: 20px;
  margin: 8px 0 8px;
}

.bd-feed__lead {
  color: var(--muted);
  font-size: 15px;
  margin: 0;
}

.bd-feed__more {
  display: grid;
  place-items: center;
  padding: 22px 0 0;
}

.bd-loading {
  color: var(--muted);
  font-size: 14px;
}

/* ---------- Сайдбар ---------- */

.bd-top-list {
  display: grid;
  gap: 14px;
  counter-reset: bd-top;
}

.bd-top-list__item {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.bd-top-list__num {
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 9px;
  height: 28px;
  display: grid;
  place-items: center;
  font-variant-numeric: tabular-nums;
}

.bd-top-list__item:nth-child(n + 4) .bd-top-list__num {
  color: var(--muted);
  background: var(--card-hi);
}

.bd-top-list__title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  margin: 0 0 4px;
}

.bd-mini {
  display: grid;
  gap: 12px;
}

.bd-mini__item {
  display: grid;
  gap: 3px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.bd-mini__item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.bd-mini__time {
  font-size: 12px;
  color: var(--accent2);
  font-weight: 600;
}

.bd-mini__title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
}

/* ---------- Подписка на Телеграм ---------- */

.bd-tg {
  background: linear-gradient(160deg, rgba(42, 171, 238, 0.16), var(--card) 62%);
  border: 1px solid rgba(42, 171, 238, 0.32);
  border-radius: var(--radius);
  padding: 22px;
  text-align: center;
}

.bd-tg__icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
  background: linear-gradient(135deg, #2aabee, #229ed9);
  color: #fff;
  font-size: 24px;
  box-shadow: 0 14px 30px rgba(34, 158, 217, 0.32);
}

.bd-tg__title {
  font-size: 19px;
  margin: 0 0 8px;
}

.bd-tg__text {
  color: var(--muted);
  font-size: 14.5px;
  margin: 0 0 16px;
}

.bd-tg__note {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
}

.bd-tg--inline {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  text-align: left;
  margin: 26px 0;
  padding: 16px 18px;
  background: linear-gradient(120deg, rgba(42, 171, 238, 0.14), var(--card) 70%);
}

.bd-tg--inline .bd-tg__icon {
  margin: 0;
  width: 44px;
  height: 44px;
  font-size: 20px;
  border-radius: 13px;
}

.bd-tg--inline .bd-tg__title {
  font-size: 16px;
  margin: 0 0 2px;
}

.bd-tg--inline .bd-tg__text {
  margin: 0;
  font-size: 13.5px;
}

/* ---------- Статья ---------- */

.bd-breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
  margin: 22px 0 14px;
}

.bd-breadcrumbs a:hover {
  color: var(--accent2);
}

.bd-breadcrumbs__sep {
  opacity: 0.55;
}

.bd-article {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 34px 34px;
}

.bd-article__title {
  font-size: clamp(27px, 3.4vw, 42px);
  margin: 12px 0 14px;
}

.bd-article__lead {
  font-size: 19px;
  line-height: 1.55;
  color: var(--text);
  opacity: 0.92;
  font-weight: 500;
  margin: 0 0 18px;
}

.bd-article__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
  font-size: 13.5px;
  color: var(--muted);
}

.bd-article__cover {
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin: 0 0 24px;
  background: linear-gradient(135deg, #1a2540, #0f1626);
}

.bd-article__cover img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.bd-article__cover figcaption {
  font-size: 12.5px;
  color: var(--muted);
  padding: 10px 4px 0;
}

.bd-prose {
  font-size: 18px;
  line-height: 1.72;
}

.bd-prose > p:first-of-type::first-letter {
  float: left;
  font-size: 62px;
  line-height: 0.86;
  font-weight: 800;
  padding: 6px 12px 0 0;
  color: var(--accent2);
}

.bd-prose h2 {
  font-size: 26px;
  margin: 34px 0 12px;
  padding-left: 14px;
  border-left: 4px solid var(--accent);
}

.bd-prose h3 {
  font-size: 21px;
  margin: 26px 0 10px;
}

.bd-prose ul,
.bd-prose ol {
  margin: 0 0 1.2em;
  padding-left: 22px;
}

.bd-prose li {
  margin-bottom: 8px;
}

.bd-prose a {
  color: var(--accent2);
  border-bottom: 1px solid var(--accent2-soft);
}

.bd-prose blockquote {
  margin: 22px 0;
  padding: 14px 20px;
  border-left: 4px solid var(--accent2);
  background: var(--accent2-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
}

.bd-prose strong {
  color: var(--text);
  font-weight: 700;
}

.bd-source {
  margin: 26px 0 0;
  padding: 16px 18px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  color: var(--muted);
}

.bd-source a {
  color: var(--accent2);
}

.bd-note {
  margin: 22px 0 0;
  padding: 14px 18px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  color: var(--muted);
}

.bd-share {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.bd-share__label {
  font-size: 14px;
  color: var(--muted);
  margin-right: 4px;
}

.bd-share__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--card-hi);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.bd-share__btn:hover {
  border-color: var(--accent2);
  color: var(--accent2);
}

.bd-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.bd-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  border-radius: var(--radius-pill);
  background: var(--card-hi);
  border: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--muted);
}

.bd-tag:hover {
  color: var(--accent2);
  border-color: var(--accent2);
}

.bd-next {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
  padding: 20px 22px;
  background: linear-gradient(120deg, var(--accent-soft), var(--card) 72%);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
}

.bd-next__label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.bd-next__title {
  font-size: 19px;
  margin: 4px 0 0;
}

.bd-next__arrow {
  font-size: 22px;
  color: var(--accent);
}

/* ---------- Комментарии ---------- */

.bd-comments {
  margin-top: 26px;
}

.bd-comment {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.bd-comment__head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.bd-comment__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #fff;
  font-weight: 800;
  font-size: 15px;
}

.bd-comment__name {
  font-weight: 700;
  font-size: 15px;
}

.bd-comment__text {
  margin: 0;
  font-size: 15.5px;
  color: var(--text);
  opacity: 0.94;
}

.bd-form {
  display: grid;
  gap: 12px;
}

.bd-field {
  display: grid;
  gap: 6px;
}

.bd-field label {
  font-size: 13px;
  color: var(--muted);
}

.bd-input,
.bd-textarea {
  width: 100%;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.15s ease;
}

.bd-input:focus,
.bd-textarea:focus {
  border-color: var(--accent);
}

.bd-textarea {
  min-height: 108px;
  resize: vertical;
}

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

.bd-alert {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  border: 1px solid var(--line-strong);
  background: var(--card-hi);
}

.bd-alert--ok {
  border-color: rgba(25, 211, 197, 0.4);
  background: var(--accent2-soft);
}

.bd-alert--error {
  border-color: rgba(255, 90, 110, 0.42);
  background: rgba(255, 90, 110, 0.12);
}

/* ---------- Страница рубрики ---------- */

.bd-page-head {
  padding: 26px 0 8px;
}

.bd-page-head__title {
  font-size: clamp(28px, 3.6vw, 44px);
  margin: 0 0 10px;
}

.bd-page-head__text {
  color: var(--muted);
  max-width: 780px;
  font-size: 16px;
}

.bd-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 28px;
}

.bd-pagination__link {
  min-width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  background: var(--card);
  border: 1px solid var(--line);
  font-weight: 600;
}

.bd-pagination__link.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

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

.bd-footer {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  padding: 40px 0 26px;
  margin-top: 20px;
}

.bd-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.bd-footer__text {
  color: var(--muted);
  font-size: 14.5px;
  max-width: 380px;
}

.bd-footer__title {
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 12px;
}

.bd-footer__links {
  display: grid;
  gap: 9px;
  font-size: 15px;
}

.bd-footer__bottom {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  font-size: 13px;
  color: var(--muted);
}

.bd-disclaimer {
  font-size: 12.5px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-top: 16px;
  background: var(--card);
}

/* ---------- Плавающий баннер и попап Телеграма ---------- */

.bd-float {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 120;
  display: none;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: linear-gradient(135deg, #229ed9, #1b7fb0);
  color: #fff;
  box-shadow: 0 18px 40px rgba(6, 12, 24, 0.5);
}

.bd-float__icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  display: grid;
  place-items: center;
  font-size: 18px;
  flex: 0 0 auto;
}

.bd-float__title {
  font-weight: 700;
  font-size: 15px;
  margin: 0;
}

.bd-float__text {
  font-size: 12.5px;
  opacity: 0.9;
  margin: 0;
}

.bd-float__cta {
  margin-left: auto;
  background: #fff;
  color: #14708f;
  font-weight: 800;
  padding: 9px 14px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  font-size: 14px;
}

.bd-float__cta:hover {
  color: #14708f;
}

.bd-float__close {
  background: transparent;
  border: 0;
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  padding: 6px;
}

.bd-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(5, 8, 16, 0.72);
  backdrop-filter: blur(4px);
}

.bd-modal__card {
  position: relative;
  width: min(520px, 100%);
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: 22px;
  padding: 30px 28px 26px;
  text-align: center;
  box-shadow: var(--shadow);
}

.bd-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--card-hi);
  cursor: pointer;
}

.bd-modal__title {
  font-size: 24px;
  margin: 10px 0 8px;
}

.bd-modal__text {
  color: var(--muted);
  font-size: 15px;
  margin: 0 0 20px;
}

.bd-modal__list {
  text-align: left;
  margin: 0 0 20px;
  padding-left: 20px;
  color: var(--muted);
  font-size: 14.5px;
}

/* ---------- Поиск / служебные страницы ---------- */

.bd-search-page {
  padding: 28px 0 60px;
}

.bd-prose--doc {
  font-size: 16.5px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 32px;
}

.bd-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  margin: 18px 0 26px;
}

.bd-stat {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.bd-stat__value {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.bd-stat__label {
  font-size: 12.5px;
  color: var(--muted);
}

/* ---------- Адаптив ---------- */

@media (max-width: 1360px) {
  .bd-header__top {
    gap: 12px;
  }
  .bd-search {
    flex-basis: 150px;
  }
  .bd-nav__link {
    padding: 8px 9px;
    font-size: 14.5px;
  }
  .bd-search {
    flex-basis: 160px;
  }
}

@media (max-width: 1239px) {
  .bd-nav {
    display: none;
  }
  .bd-burger {
    display: grid;
  }
}

@media (max-width: 1180px) {
  .bd-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 26px;
  }
  .bd-ticker {
    width: min(380px, 34vw);
  }
}

@media (max-width: 1024px) {
  .bd-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .bd-aside {
    position: static;
  }
  .bd-hero {
    grid-template-columns: minmax(0, 1fr);
  }
  .bd-lead-card {
    min-height: 380px;
  }
  .bd-hero__side {
    grid-template-rows: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .bd-grid--3,
  .bd-grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .bd-footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .bd-trend {
    display: none;
  }
  .bd-ticker {
    width: 100%;
  }
}

@media (max-width: 860px) {
  body {
    font-size: 16px;
  }
  .bd-nav,
  .bd-search--header {
    display: none;
  }
  .bd-burger {
    display: grid;
  }
  .bd-nav-drawer.is-open {
    display: block;
  }
  .bd-header__tools .bd-btn--tg span {
    display: none;
  }
  .bd-header__tools .bd-btn--tg {
    padding: 12px 14px;
  }
  .bd-float {
    display: flex;
  }
  .bd-layout {
    padding-bottom: 96px;
  }
  .bd-article {
    padding: 22px 18px 26px;
    border-radius: var(--radius-sm);
  }
  .bd-prose {
    font-size: 17px;
  }
  .bd-prose > p:first-of-type::first-letter {
    font-size: 50px;
  }
}

@media (max-width: 640px) {
  .container {
    padding: 0 16px;
  }
  .bd-logo {
    font-size: 19px;
  }
  .bd-logo__tag {
    display: none;
  }
  .bd-hero__side,
  .bd-grid--2,
  .bd-grid--3,
  .bd-grid--4 {
    grid-template-columns: minmax(0, 1fr);
  }
  .bd-feed__item {
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 14px;
    padding: 14px;
  }
  .bd-feed__title {
    font-size: 17px;
  }
  .bd-feed__lead {
    display: none;
  }
  .bd-card--row .bd-card__media {
    flex-basis: 104px;
  }
  .bd-tg--inline {
    grid-template-columns: auto minmax(0, 1fr);
    text-align: left;
  }
  .bd-tg--inline .bd-btn {
    grid-column: 1 / -1;
  }
  .bd-form__row {
    grid-template-columns: minmax(0, 1fr);
  }
  .bd-footer__grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .bd-next {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .bd-next .bd-next__label {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
