.rbz-cc {
    --rbz-cc-ink: #111a2b;
    --rbz-cc-line: #dfe6ef;
    --rbz-cc-accent: #1759d5;
    position: relative;
    box-sizing: border-box;
    min-height: 72px;
    display: grid;
    grid-template-columns: 200px auto minmax(300px, 1fr) 28px;
    align-items: center;
    gap: 18px;
    margin: 14px 0;
    padding: 11px 14px;
    border: 1px solid var(--rbz-cc-line);
    border-radius: 16px;
    background: #fff;
    color: var(--rbz-cc-ink);
    box-shadow: 0 8px 30px rgba(31, 53, 84, .04);
    font-family: inherit;
    line-height: 1.3;
}

.rbz-cc *,
.rbz-cc *::before,
.rbz-cc *::after {
    box-sizing: border-box;
}

.rbz-cc button,
.rbz-cc input {
    font: inherit;
    color: inherit;
}

.rbz-cc__title {
    display: flex;
    align-items: center;
    gap: 9px;
}

.rbz-cc__seal {
    display: grid;
    place-items: center;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: #e8f1ff;
    color: var(--rbz-cc-accent);
    font-weight: 700;
}

.rbz-cc__caption {
    display: flex;
    flex-direction: column;
}

.rbz-cc__caption b {
    font-size: 13px;
}

.rbz-cc__caption small {
    margin-top: 2px;
    color: #1f7ae0;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.rbz-cc__rates {
    display: flex;
    gap: 5px;
}

.rbz-cc__rate {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 0;
    padding: 8px 10px;
    border: 0;
    border-radius: 9px;
    background: #f5f8fc;
    cursor: pointer;
}

.rbz-cc__rate[aria-pressed="true"] {
    background: #e5efff;
    color: var(--rbz-cc-accent);
}

.rbz-cc__rate:hover {
    background: #edf3fb;
}

.rbz-cc__code {
    font-size: 11px;
    font-weight: 700;
}

.rbz-cc__symbol {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    color: var(--rbz-cc-accent);
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
}

.rbz-cc__symbol--flag {
    flex: 0 0 20px;
    overflow: hidden;
    box-shadow: 0 0 0 1px rgba(17, 26, 43, .1);
}

.rbz-cc__symbol--flag svg {
    display: block;
    width: 100%;
    height: 100%;
}

.rbz-cc__rate strong {
    font-size: 13px;
}

.rbz-cc__converter {
    display: grid;
    grid-template-columns: minmax(110px, 1fr) 28px minmax(130px, 1fr);
    align-items: center;
    gap: 7px;
}

.rbz-cc__field,
.rbz-cc__result {
    height: 36px;
    display: flex;
    align-items: center;
    margin: 0;
    border-radius: 9px;
    background: #f5f8fc;
}

.rbz-cc__field {
    position: relative;
    gap: 7px;
    padding: 0 10px;
    font-weight: 400;
}

.rbz-cc__from {
    color: #5d6c82;
    font-size: 11px;
    font-weight: 700;
}

.rbz-cc__amount {
    min-width: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 14px;
}

/* Подсказка пустого поля «1 USD»; код валюты слева при этом не нужен. */
.rbz-cc__hint {
    display: none;
    position: absolute;
    top: 50%;
    left: 10px;
    color: #97a3b4;
    font-size: 14px;
    white-space: nowrap;
    transform: translateY(-50%);
    pointer-events: none;
}

.rbz-cc__field--empty .rbz-cc__hint {
    display: block;
}

.rbz-cc__field--empty .rbz-cc__from {
    display: none;
}

.rbz-cc__result {
    padding: 0 12px;
    overflow: hidden;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.rbz-cc__result--hint {
    color: #97a3b4;
    font-weight: 400;
}

.rbz-cc__swap,
.rbz-cc__source {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #5f6e84;
    text-decoration: none;
    cursor: pointer;
}

.rbz-cc__swap:hover,
.rbz-cc__source:hover,
.rbz-cc__source:focus {
    background: #edf3fb;
    color: var(--rbz-cc-accent);
    text-decoration: none;
}

.rbz-cc__rate:focus-visible,
.rbz-cc__swap:focus-visible,
.rbz-cc__source:focus-visible,
.rbz-cc__field:focus-within {
    outline: 3px solid #91b8f4;
    outline-offset: 2px;
}

.rbz-cc__unavailable {
    grid-column: 2 / 4;
    margin: 0;
    color: #5f6e84;
    font-size: 13px;
}

@media (max-width: 1120px) {
    .rbz-cc {
        grid-template-columns: 190px auto 1fr 28px;
    }
}

/* Узкий планшет: в одну строку конвертор не помещается — он уходит на вторую. */
@media (max-width: 1000px) {
    .rbz-cc {
        grid-template-columns: 190px minmax(0, 1fr) 28px;
        gap: 10px 18px;
    }

    .rbz-cc__converter {
        grid-column: 1 / -1;
        grid-row: 2;
    }

    .rbz-cc__source {
        grid-column: 3;
        grid-row: 1;
    }

    .rbz-cc__unavailable {
        grid-column: 2;
    }
}

@media (max-width: 760px) {
    .rbz-cc {
        grid-template-columns: 1fr auto;
        gap: 9px;
        margin: 8px 0 10px;
        padding: 10px 11px;
        border-radius: 14px;
    }

    .rbz-cc__title {
        grid-column: 1;
    }

    .rbz-cc__rates {
        grid-column: 1 / -1;
        grid-row: 2;
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .rbz-cc__rate {
        justify-content: center;
        gap: 5px;
        padding: 7px 6px;
    }

    .rbz-cc__converter {
        grid-column: 1 / -1;
        grid-row: 3;
        grid-template-columns: minmax(0, 1fr) 28px minmax(0, 1fr);
    }

    .rbz-cc__unavailable {
        grid-column: 1 / -1;
    }

    .rbz-cc__source {
        grid-column: 2;
        grid-row: 1;
    }
}

@media (max-width: 360px) {
    .rbz-cc {
        padding: 9px;
    }

    .rbz-cc__rate strong {
        font-size: 12px;
    }
}
