:root {
  --msa-accent: #0d6efd;
  --msa-ink: #1b2430;
}

body {
  color: var(--msa-ink);
  background: #f7f8fa;
}

.site-navbar .navbar-brand {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
}

.site-navbar .brand-car {
  height: 42px;
  width: auto;
  display: block;
}

.site-navbar .brand-text {
  letter-spacing: -0.01em;
}

@media (max-width: 575px) {
  .site-navbar .brand-car {
    height: 34px;
  }
}

/* Галерея фотографий в статьях */
.photo-gallery img {
  width: 100%;
  height: 230px;
  object-fit: contain;
  background: #fff;
}

@media (max-width: 767px) {
  .photo-gallery img {
    height: auto;
  }
}

/* Схемы из мануала показываем во всю ширину и без обрезки высоты */
.photo-gallery .gallery-wide img {
  height: auto;
  max-height: none;
}

.site-navbar .nav-link {
  white-space: nowrap;
  font-size: .95rem;
}

.site-navbar .nav-search-input {
  min-width: 150px;
  max-width: 190px;
}

main {
  max-width: 1180px;
}

h1, h2, h3, h4 {
  letter-spacing: -0.01em;
}

.lead {
  font-size: 1.06rem;
  color: #38424f;
}

.content-article p,
.content-article li {
  line-height: 1.75;
}

.content-article h2 {
  margin-top: 2.2rem;
  font-size: 1.5rem;
}

.content-article h3 {
  margin-top: 1.7rem;
  font-size: 1.22rem;
}

.content-article img {
  height: auto;
}

/* Таблицы: главный носитель технической информации */
.table > :not(caption) > * > * {
  padding: .55rem .65rem;
}

.table thead th {
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #5a6472;
}

.spec-table th[scope="row"] {
  width: 34%;
  background: #f2f4f7;
  font-weight: 600;
}

.parts-table td.code,
.spec-table td.code,
.code,
code {
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", Menlo, monospace;
  font-size: .92em;
}

code {
  background: #eef1f5;
  padding: 1px 5px;
  border-radius: 4px;
}

/* Картинки в статьях */
figure {
  margin: 1.5rem 0;
}

figure img {
  max-width: 100%;
  height: auto;
}

figcaption {
  color: #6c757d;
  font-size: .88rem;
}

@media (min-width: 768px) {
  .figure-right {
    float: right;
    width: 45%;
    margin: .3rem 0 1rem 1.6rem;
  }

  .figure-left {
    float: left;
    width: 45%;
    margin: .3rem 1.6rem 1rem 0;
  }
}

.link-list li {
  padding: .28rem 0;
  border-bottom: 1px solid #eceff3;
}

.link-list li:last-child {
  border-bottom: 0;
}

.card {
  border-color: #e4e7ec;
}

.site-footer {
  background: #fff;
  border-top: 1px solid #e4e7ec;
}

.site-footer a {
  color: #465060;
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--msa-accent);
  text-decoration: underline;
}

.alert-warning {
  background: #fff8e6;
  border-color: #ffe1a1;
}

/* Расшифровка кода комплектации */
.code-decoder .code-chips {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.code-decoder .code-chip {
  flex: 1 1 10rem;
  min-width: 9.5rem;
  border: 1px solid #d8dde5;
  border-radius: .5rem;
  background: #fff;
  padding: .5rem .65rem;
}

.code-decoder .code-chip .caption {
  display: block;
  font-size: .72rem;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: #5a6472;
}

.code-decoder .code-chip .value {
  display: block;
  font-weight: 600;
  line-height: 1.3;
  margin: .15rem 0;
}

.code-decoder .code-chip .letter {
  display: block;
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", Menlo, monospace;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1;
  color: var(--msa-accent);
}

.code-decoder .code-chip.is-unknown {
  border-color: #f0c36d;
  background: #fff8e6;
}

.code-decoder .code-chip.is-unknown .letter {
  color: #b06a00;
}
