@import url('https://googleapis.com');

:root {
    --brc-blue: #1677b8;
    --brc-red: #d84a3a;
    --brc-orange: #f28c28;
    --brc-dark: #10253a;
    --brc-gray: #5f7383;
    --brc-border: #e2e8f0;
    --brc-bg: #EDF5FD;
    --surface-page: #ffffff;
    --surface-card: #ffffff;
    --surface-muted: #f8fafc;
    --brc-font-main: 'Manrope', system-ui, -apple-system, sans-serif;
    --brc-font-title: 'Raleway', sans-serif;
    --brc-max-width: 1280px;
}

html.dark {
    --brc-dark: #f1f5f9;
    --brc-gray: #94a3b8;
    --brc-border: #334155;
    --brc-bg: #1e293b;
    --surface-page: #0b1120;
    --surface-card: #111827;
    --surface-muted: #1e293b;
}

*, *::before, *::after { box-sizing: border-box; }
body {
    margin: 0; padding-top: 72px; min-height: 100vh;
    display: flex; flex-direction: column;
    font-family: var(--brc-font-main);
    background: var(--surface-page); color: var(--brc-dark);
    line-height: 1.6; overflow-x: hidden;
}

/* Фирменная фиксированная шапка */
.brc-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 9990;
    background: var(--surface-card);
    border-bottom: 1px solid var(--brc-border);
    box-shadow: 0 2px 10px rgba(16, 37, 58, 0.06);
}
.brc-header-inner {
    max-width: var(--brc-max-width); margin: 0 auto;
    padding: 10px 24px; display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.brc-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.brc-logo__img { height: 38px; width: auto; border-radius: 6px; }
.brc-logo__title { display: block; font-family: var(--brc-font-title); font-weight: 800; font-size: 17px; color: var(--brc-blue); line-height: 1.15; }
.brc-logo__sub { display: block; font-size: 10px; font-weight: 700; letter-spacing: .06em; color: var(--brc-gray); }

.brc-header-right { display: flex; align-items: center; gap: 8px; }
.brc-nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.brc-nav-link {
    background: transparent; border: 0; font-family: inherit;
    font-size: 12.5px; font-weight: 600; color: var(--brc-dark); white-space: nowrap;
    text-decoration: none; padding: 6px 8px; border-radius: 8px;
    cursor: pointer; display: inline-flex; align-items: center; gap: 4px;
    transition: background .15s, color .15s;
}
.brc-nav-link:hover, .brc-nav-link.active { background: var(--brc-bg); color: var(--brc-blue); }
.brc-nav-link--logout { color: var(--brc-red) !important; }
/* Переключатель языков в капсуле с красной рамкой как на bharatrus.ru */
.brc-lang-switch {
    display: inline-flex; align-items: center;
    border: 1px solid var(--brc-red); border-radius: 999px; padding: 2px 6px; gap: 2px;
}
.brc-lang-btn {
    background: none; border: none; padding: 3px 8px;
    font-size: 11px; font-weight: 800; text-decoration: none;
    color: var(--brc-dark); text-transform: uppercase; letter-spacing: .04em; border-radius: 999px;
}
.brc-lang-btn--active { color: #fff; background: var(--brc-red); }
.brc-theme-toggle {
    background: var(--brc-bg); border: 1px solid var(--brc-border);
    border-radius: 999px; width: 30px; height: 30px;
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer; font-size: 13px; margin-left: 6px;
}

/* Бургер в фирменном красном квадрате */
.brc-burger {
    display: none; background: var(--brc-red); color: #fff;
    border: 0; border-radius: 6px; padding: 6px 10px; font-size: 18px; cursor: pointer;
}

/* Контейнер и капсульные подменю */
.container { max-width: var(--brc-max-width); width: 100%; margin: 28px auto; padding: 0 24px; flex: 1; }
.subnav-bar {
    display: flex; gap: 8px; overflow-x: auto;
    background: var(--surface-card); border: 1px solid var(--brc-border);
    border-radius: 14px; padding: 8px 12px; margin-bottom: 24px;
    box-shadow: 0 4px 14px rgba(16, 37, 58, 0.04);
}
.subnav-pill {
    white-space: nowrap; text-decoration: none; padding: 8px 16px;
    border-radius: 999px; font-size: 13px; font-weight: 700; color: var(--brc-dark);
    transition: .15s;
}
.subnav-pill:hover { background: var(--brc-bg); color: var(--brc-blue); }
.subnav-pill.active { background: var(--brc-blue); color: #fff; }

/* Фирменные карточки с жесткой оранжевой тенью как на bharatrus.ru */
.card {
    background: var(--surface-card);
    border: 1px solid var(--brc-border);
    border-radius: 14px;
    padding: 24px;
    margin-bottom: 22px;
    box-shadow: 6px 6px 0 var(--brc-orange);
    transition: transform .18s ease, box-shadow .18s ease;
}
.card h1, .card h2, .card h3 {
    font-family: var(--brc-font-title);
    font-weight: 800; color: var(--brc-blue); letter-spacing: -0.02em;
}

/* Фирменные кнопки-капсулы */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 11px 22px; border-radius: 999px;
    font-family: var(--brc-font-main); font-size: 12px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .06em;
    border: 0; cursor: pointer; text-decoration: none; transition: .18s;
}
.btn-red { background: var(--brc-red); color: #fff; box-shadow: 3px 3px 0 var(--brc-orange); }
.btn-red:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--brc-orange); }
.btn-blue { background: var(--brc-blue); color: #fff; }
.btn-blue:hover { background: #10253a; color: #fff; }
.btn-light { background: var(--brc-bg); color: var(--brc-blue); border: 1px solid var(--brc-border); }
/* Поля форм и уведомления */
input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
input[type="number"], select, textarea {
    background: var(--surface-card); color: var(--brc-dark);
    border: 1px solid var(--brc-border); border-radius: 10px;
    font-family: var(--brc-font-main); font-size: 14px;
}
input:focus, select:focus, textarea:focus {
    outline: none; border-color: var(--brc-blue);
    box-shadow: 0 0 0 3px rgba(22, 119, 184, 0.14);
}
.alert {
    padding: 14px 18px; border-radius: 12px;
    background: #e6f4ea; color: #155724; border: 1px solid #c3e6cb;
    font-size: 14px; font-weight: 600; margin-bottom: 18px;
}

/* Фирменный блок контактов и реквизитов в подвале как на bharatrus.ru */
.brc-footer {
    background: var(--surface-card);
    border-top: 2px solid var(--brc-blue);
    padding: 40px 24px 36px; margin-top: 48px;
}
.brc-footer-inner {
    max-width: var(--brc-max-width); margin: 0 auto;
    display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: start;
}
.brc-contact-pill {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 14px; border: 1px solid var(--brc-border); border-radius: 10px;
    text-decoration: none; color: var(--brc-dark); font-size: 13px; font-weight: 600;
    margin-bottom: 8px; background: var(--surface-card); transition: .15s;
}
.brc-contact-pill:hover { border-color: var(--brc-orange); box-shadow: 3px 3px 0 var(--brc-orange); }
.brc-code-tag {
    font-size: 10px; font-weight: 800; padding: 2px 7px;
    border: 1px solid var(--brc-border); border-radius: 999px; color: var(--brc-gray);
}
.brc-legal-box {
    border: 1px solid var(--brc-border); border-radius: 12px;
    padding: 18px; background: var(--surface-muted); font-size: 13px;
}

@media (max-width: 960px) {
    body { padding-top: 62px; }
    .brc-header-inner { padding: 10px 16px; }
    .brc-burger { display: inline-block; }
    .brc-nav {
        display: none; position: fixed; top: 60px; left: 0; right: 0;
        background: var(--surface-card); border-bottom: 1px solid var(--brc-border);
        flex-direction: column; align-items: stretch; padding: 14px 16px;
        box-shadow: 0 12px 24px rgba(16, 37, 58, 0.14);
    }
    .brc-nav.open { display: flex; }
    .container { padding: 0 14px; margin: 18px auto; }
    .card { box-shadow: 4px 4px 0 var(--brc-orange); padding: 18px; }
    .brc-footer-inner { grid-template-columns: 1fr; }
}

.brc-article-body img, .brc-article-body video, .brc-article-body iframe {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    max-height: 460px !important;
    height: auto !important;
    margin: 22px auto !important;
    border-radius: 14px;
    object-fit: contain;
}
.brc-article-body video { background: #0f172a; }
.brc-media-masonry { column-count: 2; column-gap: 14px; margin: 22px 0; width: 100%; }
.brc-media-masonry img, .brc-media-masonry video {
    width: 100% !important; max-height: 360px !important;
    margin: 0 0 14px 0 !important; break-inside: avoid; object-fit: cover;
}
@media (max-width: 640px) { .brc-media-masonry { column-count: 1; } }


/* --- STUDIO & DIALOG --- */
@import url('https://googleapis.com');

:root {
    --brc-blue: #1677b8;
    --brc-red: #d84a3a;
    --brc-orange: #f28c28;
    --brc-dark: #10253a;
    --brc-gray: #5f7383;
    --brc-border: #e2e8f0;
    --brc-bg: #EDF5FD;
    --surface-page: #ffffff;
    --surface-card: #ffffff;
    --surface-muted: #f8fafc;
    --brc-font-main: 'Manrope', system-ui, -apple-system, sans-serif;
    --brc-font-title: 'Raleway', sans-serif;
    --brc-max-width: 1280px;
}

html.dark {
    --brc-dark: #f1f5f9;
    --brc-gray: #94a3b8;
    --brc-border: #334155;
    --brc-bg: #1e293b;
    --surface-page: #0b1120;
    --surface-card: #111827;
    --surface-muted: #1e293b;
}

*, *::before, *::after { box-sizing: border-box; }
body {
    margin: 0; padding-top: 72px; min-height: 100vh;
    display: flex; flex-direction: column;
    font-family: var(--brc-font-main);
    background: var(--surface-page); color: var(--brc-dark);
    line-height: 1.6; overflow-x: hidden;
}

/* Фирменная фиксированная шапка */
.brc-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 9990;
    background: var(--surface-card);
    border-bottom: 1px solid var(--brc-border);
    box-shadow: 0 2px 10px rgba(16, 37, 58, 0.06);
}
.brc-header-inner {
    max-width: var(--brc-max-width); margin: 0 auto;
    padding: 10px 24px; display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.brc-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.brc-logo__img { height: 38px; width: auto; border-radius: 6px; }
.brc-logo__title { display: block; font-family: var(--brc-font-title); font-weight: 800; font-size: 17px; color: var(--brc-blue); line-height: 1.15; }
.brc-logo__sub { display: block; font-size: 10px; font-weight: 700; letter-spacing: .06em; color: var(--brc-gray); }

.brc-header-right { display: flex; align-items: center; gap: 8px; }
.brc-nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.brc-nav-link {
    background: transparent; border: 0; font-family: inherit;
    font-size: 12.5px; font-weight: 600; color: var(--brc-dark); white-space: nowrap;
    text-decoration: none; padding: 6px 8px; border-radius: 8px;
    cursor: pointer; display: inline-flex; align-items: center; gap: 4px;
    transition: background .15s, color .15s;
}
.brc-nav-link:hover, .brc-nav-link.active { background: var(--brc-bg); color: var(--brc-blue); }
.brc-nav-link--logout { color: var(--brc-red) !important; }
/* Переключатель языков в капсуле с красной рамкой как на bharatrus.ru */
.brc-lang-switch {
    display: inline-flex; align-items: center;
    border: 1px solid var(--brc-red); border-radius: 999px; padding: 2px 6px; gap: 2px;
}
.brc-lang-btn {
    background: none; border: none; padding: 3px 8px;
    font-size: 11px; font-weight: 800; text-decoration: none;
    color: var(--brc-dark); text-transform: uppercase; letter-spacing: .04em; border-radius: 999px;
}
.brc-lang-btn--active { color: #fff; background: var(--brc-red); }
.brc-theme-toggle {
    background: var(--brc-bg); border: 1px solid var(--brc-border);
    border-radius: 999px; width: 30px; height: 30px;
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer; font-size: 13px; margin-left: 6px;
}

/* Бургер в фирменном красном квадрате */
.brc-burger {
    display: none; background: var(--brc-red); color: #fff;
    border: 0; border-radius: 6px; padding: 6px 10px; font-size: 18px; cursor: pointer;
}

/* Контейнер и капсульные подменю */
.container { max-width: var(--brc-max-width); width: 100%; margin: 28px auto; padding: 0 24px; flex: 1; }
.subnav-bar {
    display: flex; gap: 8px; overflow-x: auto;
    background: var(--surface-card); border: 1px solid var(--brc-border);
    border-radius: 14px; padding: 8px 12px; margin-bottom: 24px;
    box-shadow: 0 4px 14px rgba(16, 37, 58, 0.04);
}
.subnav-pill {
    white-space: nowrap; text-decoration: none; padding: 8px 16px;
    border-radius: 999px; font-size: 13px; font-weight: 700; color: var(--brc-dark);
    transition: .15s;
}
.subnav-pill:hover { background: var(--brc-bg); color: var(--brc-blue); }
.subnav-pill.active { background: var(--brc-blue); color: #fff; }

/* Фирменные карточки с жесткой оранжевой тенью как на bharatrus.ru */
.card {
    background: var(--surface-card);
    border: 1px solid var(--brc-border);
    border-radius: 14px;
    padding: 24px;
    margin-bottom: 22px;
    box-shadow: 6px 6px 0 var(--brc-orange);
    transition: transform .18s ease, box-shadow .18s ease;
}
.card h1, .card h2, .card h3 {
    font-family: var(--brc-font-title);
    font-weight: 800; color: var(--brc-blue); letter-spacing: -0.02em;
}

/* Фирменные кнопки-капсулы */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 11px 22px; border-radius: 999px;
    font-family: var(--brc-font-main); font-size: 12px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .06em;
    border: 0; cursor: pointer; text-decoration: none; transition: .18s;
}
.btn-red { background: var(--brc-red); color: #fff; box-shadow: 3px 3px 0 var(--brc-orange); }
.btn-red:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--brc-orange); }
.btn-blue { background: var(--brc-blue); color: #fff; }
.btn-blue:hover { background: #10253a; color: #fff; }
.btn-light { background: var(--brc-bg); color: var(--brc-blue); border: 1px solid var(--brc-border); }
/* Поля форм и уведомления */
input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
input[type="number"], select, textarea {
    background: var(--surface-card); color: var(--brc-dark);
    border: 1px solid var(--brc-border); border-radius: 10px;
    font-family: var(--brc-font-main); font-size: 14px;
}
input:focus, select:focus, textarea:focus {
    outline: none; border-color: var(--brc-blue);
    box-shadow: 0 0 0 3px rgba(22, 119, 184, 0.14);
}
.alert {
    padding: 14px 18px; border-radius: 12px;
    background: #e6f4ea; color: #155724; border: 1px solid #c3e6cb;
    font-size: 14px; font-weight: 600; margin-bottom: 18px;
}

/* Фирменный блок контактов и реквизитов в подвале как на bharatrus.ru */
.brc-footer {
    background: var(--surface-card);
    border-top: 2px solid var(--brc-blue);
    padding: 40px 24px 36px; margin-top: 48px;
}
.brc-footer-inner {
    max-width: var(--brc-max-width); margin: 0 auto;
    display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: start;
}
.brc-contact-pill {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 14px; border: 1px solid var(--brc-border); border-radius: 10px;
    text-decoration: none; color: var(--brc-dark); font-size: 13px; font-weight: 600;
    margin-bottom: 8px; background: var(--surface-card); transition: .15s;
}
.brc-contact-pill:hover { border-color: var(--brc-orange); box-shadow: 3px 3px 0 var(--brc-orange); }
.brc-code-tag {
    font-size: 10px; font-weight: 800; padding: 2px 7px;
    border: 1px solid var(--brc-border); border-radius: 999px; color: var(--brc-gray);
}
.brc-legal-box {
    border: 1px solid var(--brc-border); border-radius: 12px;
    padding: 18px; background: var(--surface-muted); font-size: 13px;
}

@media (max-width: 960px) {
    body { padding-top: 62px; }
    .brc-header-inner { padding: 10px 16px; }
    .brc-burger { display: inline-block; }
    .brc-nav {
        display: none; position: fixed; top: 60px; left: 0; right: 0;
        background: var(--surface-card); border-bottom: 1px solid var(--brc-border);
        flex-direction: column; align-items: stretch; padding: 14px 16px;
        box-shadow: 0 12px 24px rgba(16, 37, 58, 0.14);
    }
    .brc-nav.open { display: flex; }
    .container { padding: 0 14px; margin: 18px auto; }
    .card { box-shadow: 4px 4px 0 var(--brc-orange); padding: 18px; }
    .brc-footer-inner { grid-template-columns: 1fr; }
}

.brc-article-body img, .brc-article-body video, .brc-article-body iframe {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    max-height: 460px !important;
    height: auto !important;
    margin: 22px auto !important;
    border-radius: 14px;
    object-fit: contain;
}
.brc-article-body video { background: #0f172a; }
.brc-media-masonry { column-count: 2; column-gap: 14px; margin: 22px 0; width: 100%; }
.brc-media-masonry img, .brc-media-masonry video {
    width: 100% !important; max-height: 360px !important;
    margin: 0 0 14px 0 !important; break-inside: avoid; object-fit: cover;
}
@media (max-width: 640px) { .brc-media-masonry { column-count: 1; } }


/* --- STUDIO & DIALOG --- */
@import url('https://googleapis.com');

:root {
  --brc-blue: #1677b8;
  --brc-dark: #10253a;
  --brc-orange: #f28c28;
  --brc-red: #d84a3a;
  --brc-bg: #edf5fd;
  --brc-border: #dbe6f2;
  --brc-radius: 12px;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: 'Manrope', system-ui, -apple-system, sans-serif;
  color: var(--brc-dark);
  background: #f7fafd;
  line-height: 1.5;
}
h1, h2, h3, h4 { font-family: 'Raleway', 'Manrope', sans-serif; }
.brc-input, .brc-select, .brc-textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid #c6d6e8;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  background: #fff;
}
dialog.brc-dialog {
  border: none;
  border-radius: var(--brc-radius);
  padding: 24px;
  max-width: 560px;
  width: calc(100% - 32px);
  box-shadow: 0 24px 60px rgba(16, 37, 58, 0.28);
}
dialog.brc-dialog::backdrop {
  background: rgba(16, 37, 58, 0.55);
  backdrop-filter: blur(2px);
}


/* --- FIX HTML5 GRAPHICS & TABLES IN INSIGHTS / WIKI --- */
.brc-insight-article, .brc-wiki-article { line-height: 1.65; color: #10253a; max-width: 100%; overflow-x: hidden; }
.brc-insight-article figure, .brc-wiki-article figure { margin: 20px 0; padding: 18px; background: #f8fbff; border: 1px solid #dbe6f2; border-radius: 12px; text-align: center; overflow-x: auto; }
.brc-insight-article figure svg, .brc-wiki-article figure svg { max-width: 100%; height: auto !important; display: block; margin: 0 auto 10px; }
.brc-insight-article figcaption, .brc-wiki-article figcaption { font-size: 13px; color: #52657a; font-style: italic; margin-top: 8px; }
.brc-insight-article img, .brc-wiki-article img, .brc-insight-article video { max-width: 100%; height: auto; border-radius: 10px; }
.brc-table { width: 100% !important; min-width: 0 !important; border-collapse: collapse; margin: 16px 0; font-size: 14px; display: block; overflow-x: auto; }
.brc-table th, .brc-table td { padding: 10px 12px; border: 1px solid #dbe6f2; text-align: left; }
.brc-table thead th { background: #10253a; color: #fff; font-weight: 600; }
.brc-wiki-article dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 16px; background: #f9fbfd; padding: 16px; border-radius: 10px; border: 1px solid #dbe6f2; }
.brc-wiki-article dt { font-weight: 700; color: #1677b8; }
.brc-wiki-article dd { margin: 0; color: #10253a; }
