/* ==========================================================
   Страница «О депутате» — в стилистике главной
   ========================================================== */

:root {
    --dp-bg:          #f3f4f6;   /* светло-серый фон страницы как на главной */
    --dp-card:        #ffffff;
    --dp-text:        #111418;
    --dp-muted:       #6b7280;
    --dp-muted-2:     #9aa0a6;
    --dp-red:         #d11a2a;
    --dp-red-dark:    #b1121f;
    --dp-red-soft:    #fdecee;
    --dp-border:      #eceef1;
    --dp-soft:        #f7f8fa;
    --dp-radius-xl:   28px;  /* как у карточек главной */
    --dp-radius-lg:   20px;
    --dp-radius-md:   14px;
    --dp-shadow:      0 1px 2px rgba(17,20,24,.04);
}

/* ===== Страница ===== */
.about-page {
    background: var(--dp-bg);
    color: var(--dp-text);
    padding: 20px 0 60px;
    font-family: inherit;
    -webkit-font-smoothing: antialiased;
}

.about-page__container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ===== Базовая карточка ===== */
.card {
    background: var(--dp-card);
    border-radius: var(--dp-radius-xl);
    padding: 44px;
    box-shadow: var(--dp-shadow);
}

.card__title {
    font-size: 30px;
    line-height: 1.15;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0 0 24px;
    color: var(--dp-text);
}

/* ==========================================================
   HERO
   ========================================================== */
.about-hero__inner {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 48px;
    align-items: center;
    min-height: 460px;
}

.about-hero__content {
    max-width: 560px;
}

.about-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--dp-red-soft);
    color: var(--dp-red);
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.01em;
    padding: 8px 14px;
    border-radius: 999px;
    margin-bottom: 22px;
}

.about-hero__title {
    font-size: 44px;
    line-height: 1.08;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0 0 22px;
    color: var(--dp-text);
}

.about-hero__lead {
    font-size: 17px;
    line-height: 1.6;
    color: var(--dp-muted);
    margin: 0 0 34px;
}

.about-hero__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.about-hero__photo {
    display: flex;
    justify-content: center;
    align-items: center;
}
.about-hero__photo img {
    width: 100%;
    max-width: 480px;
    height: auto;
    max-height: 520px;
    object-fit: cover;
    border-radius: var(--dp-radius-lg);
    display: block;
}

/* ==========================================================
   Кнопки
   ========================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 28px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s, color .2s, border-color .2s, transform .15s;
    border: 1px solid transparent;
    cursor: pointer;
    line-height: 1;
    white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn--primary {
    background: var(--dp-red);
    color: #fff;
}
.btn--primary:hover { background: var(--dp-red-dark); color: #fff; }

.btn--ghost {
    background: #fff;
    color: var(--dp-text);
    border-color: var(--dp-border);
}
.btn--ghost:hover { background: var(--dp-soft); }

.btn--ghost-dark {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,.25);
}
.btn--ghost-dark:hover { background: rgba(255,255,255,.08); color: #fff; }

.btn--block {
    display: flex;
    width: 100%;
    margin-top: 4px;
}

/* ==========================================================
   Биография + Контакты
   ========================================================== */
.about-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 20px;
}

.about-bio__text.wysiwyg {
    font-size: 16px;
    line-height: 1.7;
    color: #2b2f36;
}
.about-bio__text.wysiwyg p          { margin: 0 0 14px; }
.about-bio__text.wysiwyg p:last-child { margin-bottom: 0; }
.about-bio__text.wysiwyg h2,
.about-bio__text.wysiwyg h3 { margin: 28px 0 12px; font-weight: 700; letter-spacing: -0.01em; }
.about-bio__text.wysiwyg h2 { font-size: 22px; }
.about-bio__text.wysiwyg h3 { font-size: 18px; }
.about-bio__text.wysiwyg ul,
.about-bio__text.wysiwyg ol { padding-left: 22px; margin: 0 0 14px; }
.about-bio__text.wysiwyg li { margin-bottom: 6px; }
.about-bio__text.wysiwyg a  { color: var(--dp-red); text-decoration: underline; text-underline-offset: 3px; }
.about-bio__text.wysiwyg a:hover { color: var(--dp-red-dark); }
.about-bio__text.wysiwyg img {
    max-width: 100%;
    height: auto;
    border-radius: var(--dp-radius-md);
    margin: 12px 0;
}
.about-bio__text.wysiwyg blockquote {
    border-left: 3px solid var(--dp-red);
    padding: 10px 0 10px 20px;
    margin: 20px 0;
    color: #2b2f36;
    background: var(--dp-soft);
    border-radius: 0 12px 12px 0;
    font-style: italic;
}

/* ===== Контактная карточка ===== */
.contacts-list {
    list-style: none;
    margin: 0 0 20px;
    padding: 0;
}
.contacts-list__item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 16px 0;
    border-bottom: 1px solid var(--dp-border);
}
.contacts-list__item:first-child { padding-top: 0; }
.contacts-list__item:last-child  { border-bottom: none; padding-bottom: 0; }

.contacts-list__label {
    font-size: 12px;
    color: var(--dp-muted-2);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}
.contacts-list__value {
    font-size: 16px;
    color: var(--dp-text);
    text-decoration: none;
    font-weight: 500;
    line-height: 1.45;
}
a.contacts-list__value:hover { color: var(--dp-red); }

/* ==========================================================
   Достижения
   ========================================================== */
.achievements-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}
.achievement {
    display: flex;
    gap: 16px;
    padding: 22px;
    background: var(--dp-soft);
    border-radius: var(--dp-radius-md);
    align-items: flex-start;
    transition: background .2s;
}
.achievement:hover { background: #eef0f3; }

.achievement__num {
    flex-shrink: 0;
    width: 36px; height: 36px;
    border-radius: 50%;
    background: var(--dp-red);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    display: grid;
    place-items: center;
    letter-spacing: 0.02em;
}
.achievement__text {
    font-size: 15px;
    line-height: 1.55;
    color: #2b2f36;
    padding-top: 6px;
}

/* ==========================================================
   Социальные сети
   ========================================================== */
.about-socials__desc {
    color: var(--dp-muted);
    margin: -14px 0 24px;
    font-size: 15px;
    max-width: 640px;
}

.socials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}
.social-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    background: var(--dp-soft);
    border-radius: var(--dp-radius-md);
    color: var(--dp-text);
    text-decoration: none;
    transition: background .2s, border-color .2s, transform .2s;
    border: 1px solid transparent;
}
.social-card:hover {
    background: #fff;
    border-color: var(--dp-border);
    transform: translateY(-2px);
    color: var(--dp-text);
}

.social-card__icon {
    width: 42px; height: 42px;
    border-radius: 12px;
    background: #fff;
    display: grid;
    place-items: center;
    color: var(--dp-red);
    flex-shrink: 0;
    box-shadow: var(--dp-shadow);
}
.social-card__label {
    font-weight: 600;
    font-size: 15px;
    flex: 1;
}
.social-card__arrow {
    color: var(--dp-muted-2);
    transition: transform .2s, color .2s;
    font-size: 18px;
}
.social-card:hover .social-card__arrow {
    transform: translateX(4px);
    color: var(--dp-red);
}

/* ==========================================================
   CTA (тёмная карточка в конце)
   ========================================================== */
.about-cta {
    background: var(--dp-text);
    color: #fff;
}
.about-cta__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
}
.about-cta__text { max-width: 620px; }
.about-cta__title {
    font-size: 30px;
    margin: 0 0 10px;
    font-weight: 800;
    letter-spacing: -0.01em;
    color: #fff;
}
.about-cta__desc {
    color: #c5c8cf;
    margin: 0;
    font-size: 16px;
    line-height: 1.55;
}
.about-cta__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ==========================================================
   Адаптив
   ========================================================== */
@media (max-width: 1024px) {
    .about-hero__inner {
        grid-template-columns: 1fr;
        gap: 32px;
        min-height: 0;
    }
    .about-hero__photo {
        order: -1;
    }
    .about-hero__photo img {
        max-width: 380px;
        max-height: 460px;
    }
    .about-hero__content { max-width: none; }
    .about-grid { grid-template-columns: 1fr; }

    .about-hero__title { font-size: 36px; }
    .card { padding: 34px; }
}

@media (max-width: 720px) {
    .about-page { padding: 12px 0 40px; }
    .about-page__container {
        padding: 0 12px;
        gap: 12px;
    }
    .card {
        padding: 26px 20px;
        border-radius: 22px;
    }
    .card__title {
        font-size: 22px;
        margin-bottom: 18px;
    }

    .about-hero__title { font-size: 28px; }
    .about-hero__lead  { font-size: 16px; margin-bottom: 26px; }
    .about-hero__actions { flex-direction: column; }
    .about-hero__actions .btn { width: 100%; }
    .about-hero__photo img { max-width: 100%; max-height: 380px; }

    .achievements-grid { grid-template-columns: 1fr; }
    .socials-grid { grid-template-columns: 1fr 1fr; }

    .about-cta__inner { flex-direction: column; align-items: flex-start; }
    .about-cta__title { font-size: 24px; }
    .about-cta__actions { width: 100%; }
    .about-cta__actions .btn { flex: 1; }

    .btn { padding: 14px 22px; font-size: 15px; }
}

@media (max-width: 420px) {
    .socials-grid { grid-template-columns: 1fr; }
    .about-hero__title { font-size: 24px; }
}

/* ==========================================================
   Доступность
   ========================================================== */
.btn:focus-visible,
.social-card:focus-visible,
a.contacts-list__value:focus-visible {
    outline: 2px solid var(--dp-red);
    outline-offset: 3px;
    border-radius: 999px;
}
/* ==========================================================
   Фиксы hero — убираем пустое пространство слева от текста
   ========================================================== */

/* 1. Hero — контент прижимается к верху, а не центрируется */
.about-hero__inner {
    min-height: 0;
    align-items: start;           /* было center — из-за этого пустота сверху */
    gap: 40px;
}

/* 2. Уменьшаем внутренний padding самой hero-карточки */
.about-hero {
    padding: 40px 44px;           /* было 44px со всех сторон + ещё 56px сверху/снизу */
}

/* 3. Фото — фиксированная разумная высота + показываем лицо целиком */
.about-hero__photo {
    align-self: stretch;          /* фото растягивается на всю высоту блока */
}
.about-hero__photo img {
    width: 100%;
    height: 100%;
    max-height: 460px;            /* ограничиваем сверху */
    object-fit: cover;
    object-position: center top;  /* показываем лицо, а не ботинки */
    aspect-ratio: auto;
    border-radius: var(--dp-radius-lg);
    box-shadow: 0 10px 40px -15px rgba(17, 20, 24, 0.35);
}

/* 4. Текстовая колонка — плотнее */
.about-hero__content {
    max-width: 560px;
    padding-top: 8px;             /* лёгкий отступ сверху, чтобы badge не прилипал к краю */
}
.about-hero__badge {
    margin-bottom: 18px;
}
.about-hero__title {
    margin-bottom: 16px;
}
.about-hero__lead {
    margin-bottom: 24px;
}

/* 5. CTA — фикс цвета описания (браузер красит в синий автолинки) */
.about-cta__desc,
.about-cta__desc * {
    color: #c5c8cf !important;
    -webkit-text-fill-color: #c5c8cf;
}
.about-cta,
.about-cta a { color: #fff; }

.about-cta .btn--ghost-dark {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255,255,255,.35);
}
.about-cta .btn--ghost-dark:hover {
    background: rgba(255,255,255,.1);
    border-color: rgba(255,255,255,.6);
    color: #fff;
}
.about-cta .btn--primary {
    background: var(--dp-red);
    color: #fff;
    border-color: var(--dp-red);
}
.about-cta .btn--primary:hover {
    background: var(--dp-red-dark);
    border-color: var(--dp-red-dark);
}

/* 6. Мобильная адаптация hero */
@media (max-width: 1024px) {
    .about-hero { padding: 28px; }
    .about-hero__photo img { max-height: 420px; }
}
@media (max-width: 720px) {
    .about-hero { padding: 22px 18px; }
    .about-hero__photo img { max-height: 380px; }
}
/* ==========================================================
   Hero-счётчики (Шаг 2 — усиленные)
   ========================================================== */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin: 28px 0 32px;
    padding: 22px 0;
    border-top: 1px solid var(--dp-border);
    border-bottom: 1px solid var(--dp-border);
    position: relative;
}

/* Вертикальные разделители между счётчиками */
.hero-stat {
    position: relative;
    padding: 4px 20px;
    text-align: left;
    transition: transform 0.25s ease;
}
.hero-stat:not(:first-child)::before {
    content: '';
    position: absolute;
    top: 10%;
    bottom: 10%;
    left: 0;
    width: 1px;
    background: var(--dp-border);
}
.hero-stat:first-child {
    padding-left: 0;
}

/* Цифры — крупные, жирные, красные */
.hero-stat__num {
    font-size: 42px;
    font-weight: 800;
    color: var(--dp-red);
    line-height: 1;
    margin-bottom: 8px;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
}

/* Подписи — чище, контрастнее */
.hero-stat__label {
    font-size: 13px;
    font-weight: 500;
    color: #4a4a4a;
    line-height: 1.4;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* Лёгкий эффект при наведении */
.hero-stat:hover .hero-stat__num {
    transform: scale(1.05);
}

/* Планшет */
@media (max-width: 900px) {
    .hero-stat__num { font-size: 34px; }
    .hero-stat { padding: 4px 14px; }
}

/* Мобильные — вертикальный стек без разделителей */
@media (max-width: 600px) {
    .hero-stats {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 18px 0;
    }
    .hero-stat {
        padding: 0;
        display: flex;
        align-items: baseline;
        gap: 14px;
    }
    .hero-stat:not(:first-child)::before {
        top: auto;
        bottom: auto;
        left: 0;
        right: 0;
        width: auto;
        height: 1px;
        top: -7px;
    }
    .hero-stat__num {
        font-size: 28px;
        margin-bottom: 0;
        min-width: 70px;
        flex-shrink: 0;
    }
    .hero-stat__label br { display: none; }
    .hero-stat__label {
        text-transform: none;
        letter-spacing: 0;
        font-size: 14px;
    }
    .hero-stat:hover .hero-stat__num {
        transform: none;
    }
}
/* ==========================================================
   About Hero Badge (Шаг 3 — усиленный)
   ========================================================== */
.about-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 9px 16px 9px 14px;
    background: #fff;
    border: 1.5px solid var(--dp-red, #e51e2c);
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    color: var(--dp-red, #e51e2c);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1;
    margin-bottom: 22px;
    box-shadow: 0 4px 14px rgba(229, 30, 44, 0.12);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    /* сбрасываем возможные старые стили span */
    text-decoration: none;
    white-space: normal;
}

.about-hero__badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(229, 30, 44, 0.18);
}

/* Пульсирующая точка слева */
.about-hero__badge-dot {
    width: 8px;
    height: 8px;
    background: var(--dp-red, #e51e2c);
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
}

.about-hero__badge-dot::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--dp-red, #e51e2c);
    animation: about-hero-badge-pulse 2s ease-out infinite;
}

@keyframes about-hero-badge-pulse {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }
    100% {
        transform: scale(2.8);
        opacity: 0;
    }
}

.about-hero__badge-text {
    position: relative;
    top: -1px; /* оптическая компенсация UPPERCASE */
}

/* Мобильная адаптация */
@media (max-width: 600px) {
    .about-hero__badge {
        font-size: 11px;
        padding: 8px 14px 8px 12px;
        letter-spacing: 0.04em;
        line-height: 1.3;
        align-items: flex-start;
    }
    .about-hero__badge-dot {
        margin-top: 4px; /* выравниваем точку по первой строке */
    }
    .about-hero__badge-text {
        top: 0;
    }
}
/* ==========================================================
   Шаг 4 — Sticky контакты (убираем пустоту справа)
   ========================================================== */

/* Сетка биография + контакты */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 30px;
    align-items: start; /* важно для sticky */
}

/* Карточка контактов "прилипает" при скролле */
.about-contacts {
    position: sticky;
    top: 100px; /* отступ от верха окна — подстройте под высоту вашего header */
    align-self: start;
}

/* На планшетах и мобильных — обычная колонка */
@media (max-width: 960px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
    .about-contacts {
        position: static;
    }
}
/* ==========================================================
   Шаг 4 — Прокачка блока "Биография"
   ========================================================== */

.about-bio__text {
    font-size: 16px;
    line-height: 1.75;
    color: #2c2c2c;
}

.about-bio__text p {
    margin: 0 0 18px;
}

/* Первый абзац — делаем лидом (если первая строка = имя) */
.about-bio__text > p:first-child {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
    letter-spacing: 0.02em;
}

/* Второй абзац — подзаголовок */
.about-bio__text > p:nth-child(2) {
    font-size: 15px;
    color: var(--dp-red, #e51e2c);
    font-weight: 600;
    margin-bottom: 26px;
    padding-bottom: 22px;
    border-bottom: 2px solid #f1f1f1;
}

/* Буквица на третьем абзаце (начало биографии) */
.about-bio__text > p:nth-child(3)::first-letter {
    float: left;
    font-size: 56px;
    line-height: 0.9;
    font-weight: 800;
    color: var(--dp-red, #e51e2c);
    margin: 6px 10px 0 0;
    padding: 0;
}

/* Выделяем названия кораблей/орденов в кавычках */
.about-bio__text p {
    font-variant-ligatures: common-ligatures;
}

@media (max-width: 600px) {
    .about-bio__text {
        font-size: 15px;
        line-height: 1.7;
    }
    .about-bio__text > p:first-child {
        font-size: 18px;
    }
    .about-bio__text > p:nth-child(3)::first-letter {
        font-size: 44px;
    }
}
/* ==========================================================
   Шаг 4 — Блок "Кратко обо мне" (факты)
   ========================================================== */
.about-facts {
    padding: 26px 28px;
}

.about-facts__title {
    font-size: 18px;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0 0 18px;
    padding-bottom: 14px;
    border-bottom: 2px solid #f1f1f1;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.about-facts__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.about-facts__item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 12px;
    background: #fafafa;
    border-left: 3px solid var(--dp-red, #e51e2c);
    border-radius: 6px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.about-facts__item:hover {
    background: #fff5f5;
    transform: translateX(2px);
}

.about-facts__icon {
    font-size: 20px;
    line-height: 1.3;
    flex-shrink: 0;
}

.about-facts__text {
    font-size: 14px;
    line-height: 1.5;
    color: #333;
    font-weight: 500;
}

@media (max-width: 600px) {
    .about-facts { padding: 22px 20px; }
    .about-facts__text { font-size: 13px; }
}