/* =========================
   ЛИЧНЫЙ КАБИНЕТ
   ========================= */

.profile-page {
    margin-top: 42px;
    margin-bottom: 72px;
}

.profile-page__header {
    margin-bottom: 26px;
    text-align: left;
}

.profile-page__subtitle {
    margin-top: 10px;
    max-width: 720px;
    color: #cdb9aa;
    font-size: 15px;
    line-height: 1.6;
}

.profile-page__layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}

.profile-nav {
    background: linear-gradient(180deg, rgba(24, 17, 27, 0.98), rgba(18, 12, 20, 0.98));
    border-radius: 18px;
    border: 1px solid rgba(120, 90, 70, 0.55);
    padding: 20px 18px;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.7);
    position: sticky;
    top: 92px;
}

.profile-nav__group + .profile-nav__group {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid rgba(120, 90, 70, 0.28);
}

.profile-nav__group-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: #9f8778;
    margin-bottom: 10px;
}

.profile-nav__group-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.profile-nav__link {
    display: block;
    padding: 11px 13px;
    border-radius: 12px;
    font-size: 14px;
    color: #dbc9bc;
    text-decoration: none;
    transition:
        background 0.18s ease,
        color 0.18s ease,
        transform 0.12s ease,
        border-color 0.18s ease;
    border: 1px solid transparent;
}

.profile-nav__link:hover {
    background: rgba(240, 210, 164, 0.08);
    color: #f6e0b8;
    border-color: rgba(240, 210, 164, 0.16);
    transform: translateY(-1px);
}

.profile-nav__link--active {
    background: linear-gradient(135deg, rgba(107, 62, 35, 0.32), rgba(159, 104, 52, 0.2));
    color: #ffe7c2;
    border-color: rgba(240, 210, 164, 0.28);
}

.profile-content {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Бокс пользователя сделан ниже и компактнее */
.profile-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 230px;
    gap: 18px;
    align-items: stretch;
    padding: 18px;
    border-radius: 20px;
    background:
        radial-gradient(circle at top left, rgba(246, 224, 184, 0.07), transparent 28%),
        linear-gradient(180deg, rgba(24, 17, 27, 0.98), rgba(16, 11, 18, 0.98));
    border: 1px solid rgba(120, 90, 70, 0.55);
    box-shadow: 0 22px 56px rgba(0, 0, 0, 0.72);
}

.profile-hero__left {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.profile-avatar {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-avatar__preview {
    width: 104px;
    height: 104px;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(240, 210, 164, 0.6);
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.8),
        0 14px 34px rgba(0, 0, 0, 0.5);
    background: radial-gradient(circle at 50% 15%, rgba(246, 224, 184, 0.35), transparent 58%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.profile-avatar__preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-hero__user {
    min-width: 0;
}

.profile-hero__name {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.1;
    color: #fff1d9;
    word-break: break-word;
}

.profile-hero__email {
    margin-top: 7px;
    font-size: 14px;
    color: #cdb9aa;
    word-break: break-word;
}

.profile-hero__right {
    display: flex;
    align-items: stretch;
}

.profile-balance {
    width: 100%;
    padding: 14px;
    border-radius: 16px;
    background: rgba(11, 8, 13, 0.88);
    border: 1px solid rgba(120, 90, 70, 0.55);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
}

.profile-balance__label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: #9f8778;
}

.profile-balance__value {
    font-size: 24px;
    font-weight: 700;
    color: #ffe0ae;
    line-height: 1;
}

.profile-balance__btn {
    align-self: flex-start;
    margin-top: 2px;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 24px;
}

.profile-card {
    background: linear-gradient(180deg, rgba(23, 16, 24, 0.98), rgba(18, 12, 20, 0.98));
    border-radius: 20px;
    border: 1px solid rgba(120, 90, 70, 0.55);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.72);
    padding: 20px;
}

.profile-card__title {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: #bda89a;
    margin-bottom: 14px;
}

.profile-card__body {
    border-radius: 16px;
    background: rgba(13, 9, 15, 0.72);
    border: 1px solid rgba(120, 90, 70, 0.28);
    padding: 18px;
}

.profile-fields {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.profile-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.profile-field__label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #a99182;
}

.profile-field__control input {
    width: 100%;
    min-height: 48px;
    border-radius: 12px;
    border: 1px solid #3a2930;
    background: #0c080d;
    color: #f8f1e6;
    padding: 0 14px;
    font-size: 15px;
    outline: none;
    box-sizing: border-box;
}

.profile-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.profile-action {
    display: block;
    padding: 16px;
    border-radius: 14px;
    text-decoration: none;
    background: rgba(231, 198, 148, 0.035);
    border: 1px solid rgba(120, 90, 70, 0.25);
    transition:
        transform 0.14s ease,
        border-color 0.16s ease,
        background 0.16s ease;
}

.profile-action:hover {
    transform: translateY(-2px);
    border-color: rgba(240, 210, 164, 0.3);
    background: rgba(240, 210, 164, 0.04);
}

.profile-action__title {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: #f8f1e6;
}

.profile-action__text {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    line-height: 1.5;
    color: #b9a79b;
}

.site-header__logout-btn {
    margin-left: 0;
    padding-inline: 10px;
    min-width: auto;
}

.site-header__logout-btn img {
    width: 16px;
    height: 16px;
    display: block;
}

/* =========================
   ПЕРЕКЛЮЧЕНИЕ БЛОКОВ ПРОФИЛЯ
   ========================= */

.profile-tab-panel {
    display: none;
    grid-column: 1 / -1;
}

.profile-tab-panel--active {
    display: block;
}

#profile-info,
#change-password {
    scroll-margin-top: 110px;
}

/* =========================
   СМЕНА ПАРОЛЯ В ПРОФИЛЕ
   ========================= */

.password-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.password-form__intro {
    padding: 16px;
    border-radius: 14px;
    background:
        radial-gradient(circle at top left, rgba(246, 224, 184, 0.08), transparent 34%),
        rgba(231, 198, 148, 0.035);
    border: 1px solid rgba(120, 90, 70, 0.25);
}

.password-form__intro-title {
    font-size: 17px;
    font-weight: 700;
    color: #fff1d9;
    line-height: 1.25;
}

.password-form__intro-text {
    margin-top: 8px;
    color: #b9a79b;
    font-size: 14px;
    line-height: 1.5;
}

.password-form__fields {
    gap: 14px;
}

.password-form__footer {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 2px;
}

.password-form__btn {
    cursor: pointer;
}

.password-form__btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.password-form__cancel {
    min-height: 42px;
    padding: 0 16px;
    border-radius: 12px;
    border: 1px solid rgba(120, 90, 70, 0.45);
    background: rgba(231, 198, 148, 0.035);
    color: #dbc9bc;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition:
        background 0.16s ease,
        border-color 0.16s ease,
        color 0.16s ease,
        transform 0.12s ease;
}

.password-form__cancel:hover {
    background: rgba(240, 210, 164, 0.06);
    border-color: rgba(240, 210, 164, 0.24);
    color: #f6e0b8;
    transform: translateY(-1px);
}

.password-form__message {
    display: none;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.5;
}

.password-form__message--success,
.password-form__message--error {
    display: block;
}

.password-form__message--success {
    color: #f1d7aa;
    background: rgba(214, 168, 79, 0.14);
    border: 1px solid rgba(214, 168, 79, 0.34);
}

.password-form__message--error {
    color: #f1d7aa;
    background: rgba(136, 96, 48, 0.16);
    border: 1px solid rgba(214, 168, 79, 0.28);
}

/* =========================
   АДАПТИВ ПРОФИЛЯ
   ========================= */

@media (max-width: 1100px) {
    .profile-page__layout {
        grid-template-columns: 1fr;
    }

    .profile-nav {
        position: static;
        top: auto;
    }

    .profile-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .profile-hero {
        grid-template-columns: 1fr;
    }

    .profile-hero__left {
        align-items: flex-start;
    }
}

@media (max-width: 640px) {
    .profile-page {
        margin-top: 26px;
        margin-bottom: 44px;
    }

    .profile-hero {
        padding: 16px;
        border-radius: 18px;
    }

    .profile-card {
        padding: 14px;
        border-radius: 16px;
    }

    .profile-card__body {
        padding: 14px;
        border-radius: 14px;
    }

    .profile-hero__left {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-avatar__preview {
        width: 88px;
        height: 88px;
        border-radius: 16px;
    }

    .profile-hero__name {
        font-size: 22px;
    }

    .profile-hero__email {
        font-size: 14px;
    }

    .profile-field__control input {
        min-height: 44px;
        font-size: 14px;
    }

    .password-form__intro {
        padding: 14px;
        border-radius: 14px;
    }

    .password-form__intro-title {
        font-size: 16px;
    }

    .password-form__footer {
        flex-direction: column;
        align-items: stretch;
    }

    .password-form__btn,
    .password-form__cancel {
        width: 100%;
    }
}

/* ==========================================================
   STRICT MINIMAL BLACK-GOLD — вариант 3
   Строгий, менее округлый, без лишнего glow. Карта осад сохранена.
   ========================================================== */
:root {
    --royal-radius: 6px !important;
    --royal-shadow: 0 14px 34px rgba(0,0,0,.42) !important;
    --royal-line: rgba(191, 148, 72, .26) !important;
    --royal-line-strong: rgba(218, 180, 104, .44) !important;
    --royal-gold: #c99a45 !important;
    --royal-gold-2: #ead09a !important;
    --royal-cream: #f4ead7 !important;
    --royal-beige: #c7b79e !important;
    --royal-muted: #8f806f !important;

    --vh-radius-pill: 4px !important;
    --vh-radius-md: 4px !important;
    --vh-radius-lg: 6px !important;
    --vh-lux-shadow: 0 14px 34px rgba(0,0,0,.46) !important;
}

html, body {
    background:
        linear-gradient(180deg, #060506 0%, #0a0809 52%, #050405 100%) !important;
    color: #f4ead7 !important;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgba(201,154,69,.035), transparent 18%, transparent 82%, rgba(201,154,69,.025)),
        radial-gradient(circle at 50% -10%, rgba(201,154,69,.09), transparent 34%);
    z-index: -1;
}

a { text-decoration-thickness: 1px; text-underline-offset: 3px; }

.title,
.main-title,
.legal-page__title,
.news-detail__title {
    color: #f0d7a5 !important;
    letter-spacing: .075em !important;
    text-transform: uppercase;
    text-shadow: none !important;
}

.btn,
.btn--primary,
.btn--secondary,
.btn--link,
.btn--royal,
.site-header__account-btn,
.site-header__logout-btn,
.site-header__burger,
.modal__tab,
.mobile-menu__close {
    border-radius: 4px !important;
    box-shadow: none !important;
    text-transform: uppercase;
    letter-spacing: .055em;
}

.btn:hover,
.site-header__nav-link:hover,
.site-header__account-btn:hover,
.site-header__burger:hover,
.mobile-menu__link:hover,
.profile-nav__link:hover,
.profile-nav__link--active {
    transform: none !important;
    box-shadow: none !important;
}

.btn--primary,
.btn--royal.btn--primary,
.siege-top__tab--active,
.modal__tab--active {
    background: linear-gradient(180deg, #dfbf76 0%, #b9852f 100%) !important;
    color: #120d08 !important;
    border-color: rgba(238, 206, 143, .62) !important;
}

.btn--secondary,
.btn--royal.btn--secondary {
    background: rgba(10, 8, 9, .72) !important;
    color: #ead09a !important;
    border-color: rgba(201, 154, 69, .34) !important;
}

.btn:hover,
.btn--secondary:hover {
    background: rgba(201,154,69,.10) !important;
    color: #f4ead7 !important;
    border-color: rgba(234,208,154,.48) !important;
}

/* Header: строгая панель вместо овальных/слишком мягких форм */
.site-header {
    padding: 0 !important;
    background: rgba(5, 4, 5, .86) !important;
    border-bottom: 1px solid rgba(201,154,69,.18) !important;
    backdrop-filter: blur(10px) !important;
}

.site-header__inner {
    max-width: 1240px !important;
    min-height: 68px !important;
    margin-top: 0 !important;
    padding: 10px 18px !important;
    border-radius: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
}

.site-header__inner::before,
.site-header__logo-glow,
.site-header__logo-img::after {
    display: none !important;
}

.site-header__logo-mark,
.site-header__logo-img {
    border-radius: 4px !important;
}

.site-header__logo-img {
    width: 42px !important;
    height: 42px !important;
    background: #0c0909 !important;
    border: 1px solid rgba(201,154,69,.42) !important;
    box-shadow: none !important;
}

.site-header__logo:hover .site-header__logo-img {
    transform: none !important;
    border-color: rgba(234,208,154,.58) !important;
    box-shadow: none !important;
}

.site-header__logo-title {
    color: #f4ead7 !important;
    text-shadow: none !important;
    letter-spacing: .095em !important;
}

.site-header__logo-sub,
.site-header__logo-kicker,
.site-header__nav-num {
    color: #9d8b71 !important;
}

.site-header__nav {
    gap: 2px !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

.site-header__nav-link {
    min-height: 38px !important;
    padding: 0 14px !important;
    border-radius: 0 !important;
    color: #c9b99f !important;
    border: 1px solid transparent !important;
}

.site-header__nav-link:hover,
.site-header__nav-link--accent {
    color: #ead09a !important;
    background: rgba(201,154,69,.075) !important;
    border-color: rgba(201,154,69,.22) !important;
}

.site-header__nav-link::after {
    left: 14px !important;
    right: 14px !important;
    bottom: 4px !important;
    background: #c99a45 !important;
}

.site-header__account-btn,
.site-header__logout-btn,
.site-header__burger {
    min-height: 40px !important;
    background: rgba(8, 7, 8, .72) !important;
    border: 1px solid rgba(201,154,69,.30) !important;
    color: #ead09a !important;
}

.site-header__account-dot {
    border-radius: 2px !important;
    box-shadow: none !important;
    background: #c99a45 !important;
}

.site-header__burger-line { background: #ead09a !important; }

/* Общие секции и карточки: меньше радиусов, меньше сияния, чётче сетка */
.royal-hero {
    min-height: 600px !important;
    padding: 104px 16px 64px !important;
    border-bottom: 1px solid rgba(201,154,69,.18) !important;
}

.royal-hero__bg {
    opacity: .56 !important;
    filter: grayscale(.08) saturate(.76) contrast(1.02) !important;
}

.royal-hero::after,
.royal-status-card::before,
.royal-download__card::before,
.news-row::before,
.profile-card::before,
.legal-doc::before,
.privacy-card::before {
    display: none !important;
}

.royal-kicker,
.royal-hero__badges span,
.royal-status-card,
.royal-feature,
.royal-download__card,
.royal-download__step,
.home-news-showcase__item,
.news-row,
.news-card,
.news-detail,
.profile-nav,
.profile-card,
.profile-hero,
.profile-balance,
.password-form__intro,
.legal-doc,
.privacy-card,
.terms-card,
.modal__dialog,
.table-empty,
.site-footer__inner {
    border-radius: 6px !important;
    border: 1px solid rgba(201,154,69,.24) !important;
    background: linear-gradient(180deg, rgba(16,13,13,.94), rgba(9,8,8,.94)) !important;
    box-shadow: 0 12px 30px rgba(0,0,0,.34) !important;
}

.royal-feature,
.royal-download__step,
.home-news-showcase__item,
.news-row,
.profile-card,
.legal-doc,
.privacy-card {
    transition: border-color .16s ease, background .16s ease !important;
}

.royal-feature:hover,
.home-news-showcase__item:hover,
.news-row:hover,
.profile-card:hover {
    border-color: rgba(234,208,154,.38) !important;
    transform: none !important;
}

.royal-hero h1 {
    color: #f1d8a4 !important;
    text-shadow: none !important;
    letter-spacing: .015em !important;
}

.royal-status-card__value,
.royal-feature h3,
.royal-download__step h3,
.home-news-showcase__date,
.home-news-showcase__more,
.news-row__date,
.profile-section__title,
.legal-doc h2,
.privacy-card__title {
    color: #ead09a !important;
    text-shadow: none !important;
}

/* Осады: не превращаем карту в карточку, не скрываем изображение */
.siege-section {
    max-width: 1240px !important;
    margin: 64px auto 76px !important;
    padding: 0 16px !important;
}

.siege-dashboard {
    display: grid !important;
    grid-template-columns: 330px minmax(0, 1fr) !important;
    gap: 30px !important;
    align-items: start !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}

.siege-top {
    display: flex !important;
    flex-direction: column !important;
    padding: 20px !important;
    border-radius: 6px !important;
    border: 1px solid rgba(201,154,69,.24) !important;
    background: linear-gradient(180deg, rgba(16,13,13,.94), rgba(9,8,8,.94)) !important;
    box-shadow: 0 12px 30px rgba(0,0,0,.30) !important;
}

.siege-map {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}

.siege-map__layout,
.siege-map__container {
    display: block !important;
    position: relative !important;
    width: 100% !important;
    min-height: 1px !important;
    overflow: visible !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}

.map-box__image {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    border-radius: 0 !important;
    border: 1px solid rgba(201,154,69,.20) !important;
    box-shadow: none !important;
}

.siege-top__tab,
.map-box__point-text,
.map-box__point-info,
.profile-nav__link,
.profile-field__control input,
.modal__field input,
.modal__field-inline input,
.mobile-menu__link {
    border-radius: 4px !important;
}

.siege-top__tab {
    min-height: 36px !important;
    background: rgba(9,8,8,.75) !important;
    border-color: rgba(201,154,69,.24) !important;
    box-shadow: none !important;
}

.map-box__point-slot { box-shadow: none !important; }
.map-box__point-slot-bg { filter: sepia(.12) saturate(.9) !important; }
.map-box__point-slot:hover .map-box__point-slot-bg { box-shadow: none !important; filter: brightness(1.1) sepia(.12) !important; }

/* Footer / mobile / modal */
.site-footer {
    margin-top: 78px !important;
    background: linear-gradient(180deg, transparent, rgba(5,4,5,.96) 36%, #050405) !important;
}

.site-footer__inner {
    border-radius: 0 !important;
    border-left: 0 !important;
    border-right: 0 !important;
    border-bottom: 0 !important;
}

.mobile-menu__panel {
    border-radius: 0 !important;
    background: #080707 !important;
    border-left: 1px solid rgba(201,154,69,.26) !important;
    box-shadow: -18px 0 40px rgba(0,0,0,.62) !important;
}

.modal__dialog {
    border-radius: 6px !important;
    background: linear-gradient(180deg, rgba(17,14,14,.98), rgba(8,7,7,.98)) !important;
}

.profile-avatar__preview {
    border-radius: 6px !important;
    box-shadow: none !important;
    background: #0b0909 !important;
}

@media (max-width: 980px) {
    .siege-dashboard {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    .site-header__inner { min-height: 64px !important; }
    .site-header__logo-img { width: 38px !important; height: 38px !important; }
}
