/* ==========================================================================
   pages.css — стили конкретных страниц и секций
   ========================================================================== */

/* ==========================================================================
   Главная
   ========================================================================== */

/* ---------- Hero + форма обмена ---------- */
.hero {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 640px;
    gap: 0;
    padding: 60px 0;
    animation: fade-in-up 0.8s ease-out;
}

.hero__text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-width: 0;
}

.hero__title {
    margin: 0;
    font-size: 56px;
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--color-heading);
    animation: fade-in-left 0.9s ease-out 0.1s both;
}

.hero__title span {
    display: block;
}

.hero__title strong {
    display: inline-block;
    font-weight: 700;
}

.hero__subtitle {
    margin: 32px 0 0;
    font-size: 24px;
    line-height: 1.5;
    color: var(--color-gray);
    animation: fade-in-left 1s ease-out 0.2s both;
}

.hero__widget {
    position: relative;
    min-width: 0;
    padding: 20px;
    overflow: hidden;
    border: 2px solid rgba(87, 108, 211, 0.2);
    border-radius: 32px;
    background: linear-gradient(135deg, rgba(42, 42, 54, 0.6), rgba(42, 42, 54, 0.4));
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    animation: fade-in-right 1s ease-out 0.3s both;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.hero__widget::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -30%;
    width: 80%;
    height: 100%;
    background: radial-gradient(ellipse, rgba(87, 108, 211, 0.06) 0%, transparent 70%);
    pointer-events: none;
}

.hero__widget:hover {
    transform: translateY(-2px);
    border-color: rgba(87, 108, 211, 0.35);
    box-shadow: 0 15px 50px rgba(87, 108, 211, 0.25);
}

.exchange-widget {
    position: relative;
    padding: 24px;
}

.exchange-widget::before,
.exchange-widget::after {
    content: '';
    position: absolute;
    pointer-events: none;
}

.exchange-widget::before {
    top: -40%;
    left: -20%;
    width: 60%;
    height: 80%;
    background: radial-gradient(ellipse, rgba(87, 108, 211, 0.08) 0%, transparent 70%);
}

.exchange-widget::after {
    right: -15%;
    bottom: -30%;
    width: 50%;
    height: 70%;
    background: radial-gradient(ellipse, rgba(87, 108, 211, 0.06) 0%, transparent 70%);
}

.exchange-widget__field {
    position: relative;
    color: var(--color-muted);
}

.exchange-widget__label {
    display: block;
    margin-bottom: 8px;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
}

.exchange-widget__limits {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 1.2;
    color: var(--color-muted);
}

.exchange-widget__limits.is-error {
    color: var(--color-danger);
}

.exchange-widget__network-row {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.exchange-widget__network-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--color-muted);
}

.exchange-widget__network-row .network-select__button {
    height: 40px;
    background: rgba(255, 255, 255, 0.03);
}

.exchange-widget__swap {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 16px 0;
}

.exchange-widget__submit {
    margin-top: 24px;
    height: 56px;
    font-size: 18px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* ---------- Последние обмены ---------- */
.recent-exchanges {
    position: relative;
    margin-top: 80px;
}

.recent-exchanges__grid {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px 32px;
    min-height: 330px;
    margin-top: 32px;
}

.exchange-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 0;
    padding: 28px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    background: linear-gradient(to right, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
    backdrop-filter: blur(12px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.exchange-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(87, 108, 211, 0.08) 50%, transparent 100%);
    transition: left 0.6s ease;
}

.exchange-card:hover {
    transform: translateX(4px);
    border-color: rgba(87, 108, 211, 0.25);
    box-shadow: 0 4px 16px rgba(87, 108, 211, 0.2);
}

.exchange-card:hover::before {
    left: 100%;
}

.exchange-card__amount {
    margin-bottom: 4px;
    font-size: 20px;
    font-weight: 500;
    color: var(--color-heading);
}

.exchange-card__date {
    font-size: 14px;
    color: var(--color-muted);
}

.exchange-card__pair {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin-left: auto;
}

.exchange-card__coin {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 500;
}

.exchange-card__coin img {
    display: block;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.exchange-card__arrow {
    width: 33px;
    height: 15px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='33' height='15' fill='none'%3E%3Cpath fill='%23576CD3' d='M32.707 8.207a1 1 0 0 0 0-1.414L26.343.429a1 1 0 1 0-1.414 1.414L30.586 7.5l-5.657 5.657a1 1 0 0 0 1.414 1.414l6.364-6.364ZM0 8.5h32v-2H0v2Z'/%3E%3C/svg%3E") no-repeat;
    background-size: contain;
    opacity: 0.7;
    transition: transform 0.3s ease;
}

.exchange-card:hover .exchange-card__coin img {
    transform: scale(1.1);
}

.exchange-card:hover .exchange-card__arrow {
    opacity: 1;
    transform: translateX(4px);
}

/* ---------- Как это работает (слайдер) ---------- */
.how-it-works {
    margin: 64px 0;
    overflow: hidden;
}

.how-it-works__track {
    display: flex;
    gap: 24px;
    transition: transform 0.3s ease;
}

.how-card {
    display: grid;
    flex: 0 0 100%;
    grid-template-columns: 1fr 240px;
    gap: 0 64px;
    padding: 48px;
    border-radius: 24px;
    background-color: rgba(255, 255, 255, 0.05);
    background-image: linear-gradient(90deg, rgba(87, 108, 211, 0.05), rgba(87, 108, 211, 0));
}

.how-card__content {
    min-width: 0;
}

.how-card__step {
    margin: 32px 0 0;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--color-heading);
}

.how-card__text {
    margin: 16px 0 0;
    font-size: 18px;
    line-height: 1.4;
    color: var(--color-muted);
}

.how-card__actions {
    display: flex;
    align-items: flex-start;
    gap: 32px;
    margin-top: 32px;
}

.how-card__aside {
    display: block;
    align-self: center;
    min-width: 0;
}

.how-card__image {
    display: block;
    width: 100%;
    height: auto;
}

.slider-btn {
    width: 48px;
    height: 48px;
    padding: 0;
}

.slider-btn img {
    display: block;
}

.slider-btn--prev img {
    transform: rotate(180deg);
}

/* ---------- Реферальные преимущества (карточки) ---------- */
.partners {
    position: relative;
    margin: 80px 0;
}

.partners__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 32px;
}

.feature-card {
    position: relative;
    min-width: 0;
    padding: 32px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    line-height: 1.5;
    backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(87, 108, 211, 0), rgba(87, 108, 211, 0.03), rgba(87, 108, 211, 0));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    border-color: rgba(87, 108, 211, 0.3);
    box-shadow: 0 12px 32px rgba(87, 108, 211, 0.25);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card__icon {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    margin-bottom: 20px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(87, 108, 211, 0.1), rgba(87, 108, 211, 0.05));
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-card__icon {
    transform: scale(1.1) rotate(5deg);
}

.feature-card__icon img {
    display: block;
    width: 100%;
    height: auto;
}

.feature-card__title {
    position: relative;
    z-index: 1;
    margin: 0 0 16px;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: -0.01em;
    color: var(--color-heading);
}

.feature-card__text {
    position: relative;
    z-index: 1;
    margin: 0;
    font-size: 15px;
    line-height: 1.6;
    color: var(--color-muted);
}

.partners__action {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 40px;
}

.partners__link {
    height: 56px;
    padding: 0 40px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-5) 100%);
    font-size: 18px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.partners__link::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.5s ease;
}

.partners__link:hover {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-5) 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(87, 108, 211, 0.3);
}

.partners__link:hover::before {
    transform: translate(-50%, -50%) scale(2);
}

/* ---------- Промо-баннер ---------- */
.promo-banner {
    position: relative;
    margin: 80px 0;
    animation: fade-in-up 0.8s ease-out;
}

.promo-banner__content {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    padding: 48px 56px;
    overflow: hidden;
    border: 2px solid rgba(87, 108, 211, 0.25);
    border-radius: 32px;
    background: linear-gradient(135deg, rgba(87, 108, 211, 0.15), rgba(87, 108, 211, 0.05));
    backdrop-filter: blur(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.promo-banner__content::before,
.promo-banner__content::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.promo-banner__content::before {
    top: -50%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(87, 108, 211, 0.15) 0%, transparent 70%);
}

.promo-banner__content::after {
    bottom: -30%;
    left: -5%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(87, 108, 211, 0.1) 0%, transparent 70%);
}

.promo-banner__content:hover {
    transform: translateY(-4px);
    border-color: rgba(87, 108, 211, 0.4);
    box-shadow: 0 20px 60px rgba(87, 108, 211, 0.35);
}

.promo-banner__main {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    align-items: center;
    gap: 32px;
    min-width: 0;
}

.promo-banner__icons {
    display: flex;
    flex-shrink: 0;
    align-items: center;
}

.promo-banner__icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border: 3px solid rgba(87, 108, 211, 0.3);
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(87, 108, 211, 0.2), rgba(87, 108, 211, 0.1));
    box-shadow: 0 4px 16px rgba(87, 108, 211, 0.25);
    transition: transform 0.3s ease;
}

.promo-banner__icon + .promo-banner__icon {
    margin-left: -12px;
}

.promo-banner__icon svg {
    filter: drop-shadow(0 2px 4px rgba(87, 108, 211, 0.3));
}

.promo-banner__icon--shield { color: var(--color-primary-6); }
.promo-banner__icon--gift { color: var(--color-primary-5); }
.promo-banner__icon--sparkles { color: var(--color-primary); }

.promo-banner__content:hover .promo-banner__icon {
    transform: translateY(-4px) rotate(5deg);
}

.promo-banner__text {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 0;
}

.promo-banner__badge {
    align-self: flex-start;
    height: 26px;
    padding: 0 12px;
    border-radius: 1000px;
    background: var(--gradient-primary);
    box-shadow: 0 4px 12px rgba(87, 108, 211, 0.2);
    font-size: 13px;
    font-weight: 600;
    line-height: 26px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #fff;
    white-space: nowrap;
    animation: fade-in-left 0.8s ease-out 0.2s both;
}

.promo-banner__title {
    margin: 0;
    font-size: 40px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--color-heading);
    animation: fade-in-left 0.8s ease-out 0.3s both;
}

.promo-banner__title em {
    display: inline;
    font-style: normal;
}

.promo-banner__description {
    margin: 0;
    font-size: 18px;
    line-height: 1.6;
    color: var(--color-muted);
    animation: fade-in-left 0.8s ease-out 0.4s both;
}

.promo-banner__description strong {
    font-weight: 600;
    color: var(--color-heading);
}

.promo-banner__aside {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    animation: fade-in-right 0.8s ease-out 0.5s both;
}

.promo-banner__button {
    height: 64px;
    padding: 0 48px;
    font-size: 18px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* ==========================================================================
   Страница обмена (exchange.html)
   ========================================================================== */
.exchange-pair {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0 32px;
}

.exchange-pair__side {
    flex-shrink: 0;
    width: 540px;
    min-width: 0;
}

.exchange-pair__arrow {
    flex-grow: 1;
    margin-top: 42px;
}

.exchange-pair__arrow svg {
    display: block;
    width: 100%;
    height: auto;
    margin: 0 auto;
}

.exchange-pair__row {
    margin-bottom: 16px;
}

.exchange-pair__label {
    display: block;
    margin-bottom: 12px;
    font-size: 16px;
    font-weight: 500;
    color: var(--color-muted);
}

.exchange-pair__error {
    margin: 8px 0 0;
    font-size: 14px;
    color: var(--color-danger);
}

.exchange-details {
    margin-top: 40px;
}

.exchange-details__title {
    margin: 0 0 24px;
    font-size: 24px;
    font-weight: 500;
    color: var(--color-heading);
}

.exchange-details__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px 40px;
}

.exchange-details__footer {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-top: 40px;
}

.exchange-details__agreements {
    flex-grow: 1;
    font-size: 14px;
    font-weight: 500;
    color: var(--color-muted);
}

.exchange-details__agreements .checkbox {
    margin-bottom: 10px;
}

.exchange-details__note {
    margin: 6px 0 0;
}

.exchange-details__submit {
    flex-shrink: 0;
    width: 320px;
}

.rate-info {
    margin: 40px 0;
    padding: 24px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    color: var(--color-heading);
}

.rate-info__title {
    margin: 0 0 16px;
    font-size: 18px;
    font-weight: 500;
}

.rate-info__item {
    margin-bottom: 16px;
}

.rate-info__item dt {
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--color-muted);
}

.rate-info__item dd {
    font-size: 16px;
    font-weight: 500;
    color: var(--color-heading);
    overflow-wrap: anywhere;
}

.rate-info p,
.exchange-support p {
    margin: 0 0 12px;
}

.rate-info p:last-child,
.exchange-support p:last-child {
    margin-bottom: 0;
}

.exchange-support {
    font-size: 16px;
    color: var(--color-heading);
}

/* ==========================================================================
   Детали локальной заявки (offer.html)
   ========================================================================== */
.offer-page {
    padding-top: 24px;
    padding-bottom: 64px;
}

.offer-card {
    max-width: 980px;
    margin: 0 auto;
}

.offer-card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 32px;
}

.offer-card__eyebrow {
    margin: 0 0 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-primary);
}

.offer-card__title {
    margin: 0;
    font-size: 32px;
    font-weight: 600;
    color: var(--color-heading);
}

.offer-status {
    flex-shrink: 0;
    padding: 9px 14px;
    border: 1px solid rgba(87, 108, 211, 0.45);
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
    color: #b7c0ef;
    background: rgba(87, 108, 211, 0.12);
}

.offer-route {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 24px;
    padding: 24px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
}

.offer-route__side {
    display: flex;
    flex-direction: column;
    min-width: 0;
    gap: 8px;
}

.offer-route__label,
.offer-route__network {
    font-size: 14px;
    color: var(--color-muted);
}

.offer-route__amount {
    overflow-wrap: anywhere;
    font-size: 24px;
    font-weight: 600;
    color: var(--color-heading);
}

.offer-route__arrow {
    font-size: 28px;
    color: var(--color-primary);
}

.offer-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.offer-details__item {
    min-width: 0;
    padding: 20px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
}

.offer-details__item--wide {
    grid-column: 1 / -1;
}

.offer-details dt {
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--color-muted);
}

.offer-details dd {
    overflow-wrap: anywhere;
    font-size: 16px;
    font-weight: 500;
    color: var(--color-heading);
}

.offer-card__note {
    margin: 24px 0 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--color-muted);
}

.offer-card__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-top: 24px;
    padding: 20px;
    border: 1px solid rgba(87, 108, 211, 0.35);
    border-radius: 12px;
    background: rgba(87, 108, 211, 0.08);
}

.offer-card__actions .offer-card__note {
    margin: 0;
    color: var(--color-heading);
}

.offer-card__paid {
    flex: 0 0 220px;
}

/* ==========================================================================
   Личный кабинет
   ========================================================================== */
.profile-page {
    padding-top: 8px;
    padding-bottom: 64px;
}

.profile-guard,
.profile-shell {
    max-width: 780px;
    margin: 0 auto;
}

.profile-shell {
    padding: 28px;
    border: 1px solid rgba(255, 255, 255, 0.025);
}

.profile-guard {
    text-align: center;
}

.profile-guard h1 {
    margin: 0 0 12px;
    color: var(--color-heading);
}

.profile-guard p {
    margin: 0 0 24px;
}

.profile-guard .btn {
    max-width: 260px;
}

.profile-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--color-border);
}

.profile-heading__title {
    margin: 0;
    font-size: 30px;
    font-weight: 600;
    color: var(--color-heading);
}

.profile-heading__logout {
    height: 44px;
    padding-right: 24px;
    padding-left: 24px;
}

.profile-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 24px;
}

.profile-tabs__item {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    height: 72px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    text-align: center;
    color: var(--color-gray);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01));
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}

.profile-tabs__item:hover {
    color: var(--color-heading);
    border-color: rgba(87, 108, 211, 0.65);
    text-decoration: none;
    transform: translateY(-1px);
}

.profile-tabs__item.is-active {
    color: #fff;
    border-color: var(--color-primary);
    background: linear-gradient(135deg, #6378df, #485fcf);
    box-shadow: 0 10px 24px rgba(72, 95, 207, 0.24);
}

.profile-tabs__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    color: #aeb9f5;
    background: rgba(87, 108, 211, 0.09);
    transition: color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}

.profile-tabs__icon svg {
    display: block;
    width: 38px;
    height: 38px;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.profile-tabs__item:hover .profile-tabs__icon {
    color: #dbe0ff;
    background: rgba(87, 108, 211, 0.18);
}

.profile-tabs__item.is-active .profile-tabs__icon {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
    transform: scale(1.04);
}

.profile-panel {
    min-height: 280px;
}

.profile-panel__header {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

.profile-panel__title {
    margin: 0 0 20px;
    font-size: 24px;
    color: var(--color-heading);
}

.profile-panel__header .profile-panel__title {
    margin-bottom: 8px;
}

.profile-panel__description {
    margin: 0 0 24px;
    font-size: 15px;
    color: var(--color-muted);
}

.profile-metrics {
    display: grid;
    gap: 16px;
    margin: 0;
}

.profile-metric {
    min-width: 0;
    padding: 20px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
}

.profile-metric__label {
    display: block;
    margin-bottom: 10px;
    font-size: 13px;
    color: var(--color-muted);
}

.profile-metric__value {
    margin: 0;
    overflow-wrap: anywhere;
    font-size: 20px;
    font-weight: 600;
    color: var(--color-heading);
}

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

.profile-settings {
    display: grid;
    gap: 20px;
    width: 100%;
}

.profile-settings__readonly {
    color: var(--color-text);
    background: rgba(18, 18, 24, 0.18);
    cursor: default;
}

.profile-password-summary {
    position: relative;
}

.profile-password-summary .input {
    padding-right: 52px;
    letter-spacing: 0.14em;
}

.profile-password-summary__edit {
    position: absolute;
    top: 0;
    right: 8px;
    bottom: 0;
    width: 40px;
    height: 40px;
    margin: auto;
    padding: 0;
    border: 0;
    border-radius: 8px;
    font-size: 24px;
    color: var(--color-text);
    background: transparent;
    cursor: pointer;
}

.profile-password-summary__edit:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.profile-password-form {
    display: grid;
    gap: 18px;
    padding: 20px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.015);
}

.profile-password-form__actions {
    display: flex;
    gap: 10px;
}

.profile-settings__message {
    margin: -4px 0 0;
    font-size: 14px;
    color: var(--color-danger);
}

.profile-settings__message.is-success {
    color: #8ed8a6;
}

.profile-settings__support {
    margin: 4px 0 0;
    padding-top: 18px;
    border-top: 1px solid var(--color-border);
    line-height: 1.45;
    color: var(--color-muted);
}

.profile-metric {
    display: flex;
    flex-direction: column;
}

.profile-metric__value {
    margin-bottom: 10px;
    font-size: 32px;
}

.profile-metric__value--timer {
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.04em;
}

.profile-metric__hint {
    font-size: 13px;
    color: var(--color-muted);
}

.history-list {
    display: grid;
    gap: 12px;
}

.history-item {
    display: grid;
    grid-template-columns: minmax(120px, 0.8fr) minmax(240px, 1.5fr) minmax(110px, 0.7fr) auto;
    align-items: center;
    gap: 18px;
    padding: 18px 20px;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
}

.history-item__id {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.history-item__id span,
.history-item time {
    font-size: 13px;
    color: var(--color-muted);
}

.history-item__id strong {
    color: var(--color-heading);
}

.history-item__route {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--color-heading);
}

.history-item__route i {
    color: var(--color-primary);
    font-style: normal;
}

.history-item__status {
    padding: 7px 11px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    color: #b8e7c6;
    background: rgba(48, 164, 92, 0.14);
}

.profile-empty {
    margin: 8px 0 0;
    padding: 36px 20px;
    border: 1px dashed var(--color-border);
    border-radius: 12px;
    text-align: center;
    color: var(--color-muted);
}

/* ==========================================================================
   Общий заголовок страниц (FAQ, Контакты)
   ========================================================================== */
.page-header {
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-width: 760px;
    color: var(--color-heading);
}

.page-header__title {
    margin: 0;
    font-size: 48px;
    font-weight: 600;
    line-height: 1.1;
}

.page-header__subtitle {
    margin: 0;
    font-size: 18px;
    line-height: 1.5;
    color: var(--color-gray);
}

.number-badge {
    display: inline-grid;
    place-items: center;
    flex-shrink: 0;
    width: 48px;
    min-width: 48px;
    height: 48px;
    border-radius: 16px;
    background: rgba(87, 105, 234, 0.18);
    box-shadow: 0 12px 28px rgba(87, 105, 234, 0.16);
    font-size: 17px;
    font-weight: 600;
    color: var(--color-primary);
}

/* ==========================================================================
   FAQ
   ========================================================================== */
.faq-section {
    margin-top: 80px;
}

.faq-section__header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.faq-section__title {
    margin: 0;
    font-size: 40px;
    font-weight: 600;
    line-height: 1.1;
    color: var(--color-heading);
}

.quick-nav {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.faq-categories {
    display: grid;
    gap: 24px;
    margin-top: 40px;
}

.faq-category {
    position: relative;
    padding: 32px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 18px 40px rgba(21, 27, 71, 0.08);
    scroll-margin-top: 120px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.faq-category:hover {
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: 0 20px 46px rgba(21, 27, 71, 0.12);
}

.faq-category__header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.faq-category__title {
    margin: 0;
    font-size: 22px;
    font-weight: 600;
    color: var(--color-heading);
}

.faq-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.faq-card {
    position: relative;
    display: flex;
    gap: 20px;
    padding: 32px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 24px 48px rgba(21, 27, 71, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.faq-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: 0 26px 54px rgba(21, 27, 71, 0.14);
}

.faq-card .number-badge {
    font-size: 18px;
    box-shadow: 0 14px 32px rgba(87, 105, 234, 0.16);
}

.faq-card__body {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-card__title {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--color-heading);
}

.faq-card__text {
    font-size: 16px;
    line-height: 1.55;
    color: var(--color-gray);
}

.faq-card__text p {
    margin: 16px 0;
}

.faq-card__text ol,
.faq-card__text ul {
    margin: 12px 0 0 20px;
    padding: 0;
}

.faq-card__text li {
    margin-bottom: 6px;
}

/* ==========================================================================
   Контакты
   ========================================================================== */
.contacts__accent {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--color-primary);
}

.contacts__lead {
    margin: 0;
    font-size: 22px;
    line-height: 1.4;
}

.contacts__description {
    margin: 0;
    font-size: 18px;
    line-height: 1.6;
    color: var(--color-gray);
}

.contact-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    margin-top: 56px;
}

.contact-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 32px;
    border: 1px solid rgba(87, 105, 234, 0.18);
    border-radius: 24px;
    background: rgba(87, 105, 234, 0.08);
    color: var(--color-heading);
    backdrop-filter: blur(6px);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.contact-card:hover {
    transform: translateY(-4px);
    border-color: rgba(87, 105, 234, 0.32);
    background: rgba(87, 105, 234, 0.12);
    box-shadow: 0 20px 45px rgba(25, 42, 109, 0.18);
}

.contact-card__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: linear-gradient(150deg, rgba(87, 105, 234, 0.22), rgba(87, 105, 234, 0.08));
    color: var(--color-primary);
}

.contact-card__title {
    margin: 0;
    font-size: 22px;
    font-weight: 600;
}

.contact-card__text {
    margin: 0;
    font-size: 17px;
    line-height: 1.55;
    color: var(--color-gray);
}

.contact-card__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    font-size: 16px;
    font-weight: 600;
    color: var(--color-primary);
    text-decoration: none;
}

.contact-card__link::after {
    content: '';
    width: 18px;
    height: 18px;
    background: currentColor;
    -webkit-mask: url('data:image/svg+xml,%3Csvg width="18" height="18" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" fill="none"%3E%3Cpath d="M5 12h11.586l-3.293-3.293a1 1 0 011.414-1.414l5 5a1 1 0 010 1.414l-5 5a1 1 0 11-1.414-1.414L16.586 13H5a1 1 0 110-2z" fill="%23000"/%3E%3C/svg%3E') center / contain no-repeat;
    mask: url('data:image/svg+xml,%3Csvg width="18" height="18" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" fill="none"%3E%3Cpath d="M5 12h11.586l-3.293-3.293a1 1 0 011.414-1.414l5 5a1 1 0 010 1.414l-5 5a1 1 0 11-1.414-1.414L16.586 13H5a1 1 0 110-2z" fill="%23000"/%3E%3C/svg%3E') center / contain no-repeat;
    transition: transform 0.2s ease;
}

.contact-card__link:hover {
    color: var(--color-primary);
    text-decoration: none;
}

.contact-card__link:hover::after {
    transform: translateX(4px);
}

.contacts__note {
    max-width: 680px;
    margin: 48px 0 16px;
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-gray);
}

/* ==========================================================================
   Юридические страницы (Terms, AML/KYC)
   ========================================================================== */
.legal {
    padding: 48px;
    border-radius: 24px;
    background: var(--color-surface-strong);
    font-size: 16px;
    line-height: 1.4;
    color: var(--color-muted);
}

.legal__head {
    margin-bottom: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--color-border);
}

.legal__title {
    margin: 0;
    font-size: 32px;
    font-weight: 500;
    line-height: 1.2;
    color: var(--color-heading);
}

.legal__title em {
    font-style: normal;
    color: var(--color-primary);
}

.legal__content {
    --xpad: 24px;
    max-width: 960px;
    padding-left: var(--xpad);
    padding-right: var(--xpad);
}

.legal__content > :first-child {
    margin-top: 0 !important;
}

.legal__content > :last-child {
    margin-bottom: 0 !important;
}

.legal__content p {
    margin: 16px 0 8px;
}

.legal__heading {
    margin: 32px calc(0px - var(--xpad)) 24px;
    padding: 20px var(--xpad);
    border-radius: 12px;
    background: var(--color-border);
    font-size: 18px;
    font-weight: 400;
    line-height: 20px;
    color: var(--color-muted);
}

.legal__content ul {
    margin: 12px 0 12px 20px;
    padding: 0;
    list-style-type: disc;
}

.legal__content li {
    margin: 4px 0;
}

.legal__content li::marker {
    color: var(--color-primary);
}

/* ==========================================================================
   Реферальная программа
   ========================================================================== */
.referral-hero {
    display: grid;
    grid-template-columns: 1fr 640px;
    gap: 16px;
}

.referral-hero__text {
    min-width: 0;
    font-size: 24px;
    line-height: 1.4;
    color: var(--color-gray);
}

.referral-hero__title {
    margin: 0 0 32px;
    font-size: 48px;
    font-weight: 500;
    line-height: 1.2;
    color: var(--color-heading);
}

.referral-hero__title strong {
    font-weight: 500;
    color: var(--color-primary);
}

.referral-hero__lead {
    max-width: 600px;
    margin: 0;
}

.referral-hero__image {
    min-width: 0;
}

.referral-hero__image img {
    display: block;
    width: 240px;
    height: 240px;
    margin: 0 auto;
}

.referral-intro {
    margin: 64px 0 0;
    font-size: 24px;
    line-height: 1.4;
    color: var(--color-gray);
}

.referral-intro em {
    font-style: normal;
    color: var(--color-primary);
}

.referral-steps {
    margin: 64px 0;
}

.referral-steps__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 32px;
    border: 1px solid #2e2e34;
    border-radius: 16px;
    background-color: #222229;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.06);
}

.referral-step {
    min-width: 0;
    border-right: 1px solid #2e2e34;
}

.referral-step:last-child {
    border: 0;
}

.referral-step__title {
    padding: 24px;
    border-bottom: 1px solid #2e2e34;
    font-size: 16px;
    font-weight: 500;
    line-height: 18px;
    color: var(--color-heading);
}

.referral-step__text {
    padding: 24px;
    font-size: 16px;
    line-height: 1.4;
    color: var(--color-muted);
}

.referral-rules {
    margin: 64px 0 0;
}

.referral-rules__list {
    max-width: 960px;
    margin-top: 32px;
}

/* ==========================================================================
   Страница ошибки (404)
   ========================================================================== */
.error-page {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 64px;
}

.error-page__content {
    flex-grow: 1;
    min-width: 0;
}

.error-page__title {
    margin: 0 0 32px;
}

.error-page__text {
    margin: 0;
}

.error-page__aside {
    flex-shrink: 0;
    width: 240px;
    max-width: 100%;
}

.error-page__aside img {
    display: block;
    width: 100%;
    height: auto;
}

.alert {
    margin-bottom: 32px;
    padding: 24px;
    border: 1px solid var(--color-danger);
    border-radius: 8px;
    background: rgba(240, 68, 56, 0.1);
    font-size: 18px;
    line-height: 1.4;
    color: var(--color-danger);
}

/* ==========================================================================
   Блог
   ========================================================================== */
.blog {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 1140px;
    margin: 32px auto;
    padding: 0 16px;
}

.blog__title {
    margin: 0;
    font-size: 48px;
    font-weight: 500;
    line-height: 1.2;
    color: var(--color-text);
}

.blog__subtitle {
    margin: 0;
    font-size: 18px;
    line-height: 1.4;
    color: var(--color-dimmed);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.blog-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 20px;
    border-radius: 8px;
    background-color: rgba(255, 255, 255, 0.06);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0 10px 15px -5px, rgba(0, 0, 0, 0.04) 0 7px 7px -5px;
    color: var(--color-text);
    text-decoration: none;
    transition: transform 0.12s ease, box-shadow 0.12s ease, background-color 0.12s ease;
}

.blog-card:hover,
.blog-card:focus-visible {
    color: var(--color-text);
    text-decoration: none;
    background-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.tag {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 10px;
    border-radius: 1000px;
    background: rgba(0, 0, 0, 0.1);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    letter-spacing: 0.25px;
    text-transform: uppercase;
    white-space: nowrap;
    color: var(--color-text);
}

.blog-card__title {
    margin: 0;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.4;
    overflow-wrap: break-word;
    hyphens: auto;
}

.blog-card__excerpt {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    font-size: 16px;
    line-height: 1.5;
    color: var(--color-dimmed);
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.blog-card__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    line-height: 1.4;
}

.blog-card__date {
    font-size: 14px;
    color: var(--color-dimmed);
}

.blog-card__more {
    font-size: 18px;
    font-weight: 500;
}

/* Статья */
.article-meta,
.article-card,
.article-disclaimer {
    border: 1px solid #424242;
    border-radius: 8px;
}

.article-meta {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.08);
}

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    font-size: 18px;
    line-height: 1;
}

.breadcrumbs a,
.article-content a {
    color: #4dabf7;
}

.breadcrumbs a:hover,
.article-content a:hover {
    color: #4dabf7;
}

.breadcrumbs__separator {
    margin: 0 10px;
    color: var(--color-dimmed);
}

.article-meta__row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.article-meta__byline {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    font-size: 16px;
    line-height: 1.4;
    color: var(--color-dimmed);
}

.article-meta__divider {
    height: 16px;
    margin: 0 10px;
    border-left: 1px solid #424242;
}

.article-card {
    padding: 32px;
    background: rgba(255, 255, 255, 0.1);
}

.article-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    font-size: 18px;
    line-height: 1.4;
    color: var(--color-text);
}

.article-content h1 {
    margin: 0 0 16px;
    font-size: 28px;
    font-weight: 500;
    line-height: 1.3;
}

.article-content h2 {
    margin: 24px 0 12px;
    font-size: 22px;
    font-weight: 500;
    line-height: 1.35;
}

.article-content h3 {
    margin: 20px 0 8px;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.4;
}

.article-content p {
    margin: 0;
}

.article-content ul {
    margin: 0;
    padding-left: 25px;
    list-style: disc;
}

.article-content__lead {
    color: var(--color-dimmed);
}

.article-disclaimer {
    padding: 20px;
    background: rgba(255, 255, 255, 0.06);
}

.article-disclaimer p {
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
    color: var(--color-dimmed);
}
