/*
 * SmartBtn — /about/ai-providers ("Свой ИИ по API-ключу")
 *
 * Page-scoped stylesheet, loaded ONLY by this page (like
 * assets/css/instructions-page.css for /about/instructions) -- does not
 * touch any shared stylesheet, does not go through the webpack build.
 * Reuses the same tokens as instructions-page.css (#2563EB primary blue,
 * #211D2E dark text, #F7FAFF page background) so the two documentation
 * pages read as one family; adds a data-table, a prompt/copy block and a
 * provider-support grid that instructions-page.css has no need for.
 */

/* Toggled by the inline script at the bottom of about/ai-providers.blade.php
   to switch the page body between its two static language blocks
   (.byok-lang-ru / .byok-lang-en) -- see that file's top-of-file comment
   for why the body is NOT wired through jquery.i18n's .trans[data-i18n]. */
.byok-hidden {
    display: none !important;
}

.byok-doc {
    font-family: 'Gilroy', 'Roboto', Arial, sans-serif;
    color: #211D2E;
    background: #F7FAFF;
    padding: 48px 16px 80px;
}

.byok-doc,
.byok-doc * {
    box-sizing: border-box;
}

.byok-doc__container {
    max-width: 920px;
    margin: 0 auto;
}

.byok-doc__title {
    font-size: 32px;
    line-height: 1.2;
    font-weight: 800;
    margin: 0 0 14px;
    color: #211D2E;
}

.byok-doc__lead {
    font-size: 17px;
    line-height: 1.6;
    color: #42526E;
    margin: 0 0 28px;
}

.byok-doc__lead a,
.byok-doc a {
    color: #2563EB;
    text-decoration: none;
    font-weight: 600;
}

.byok-doc__lead a:hover,
.byok-doc a:hover {
    text-decoration: underline;
}

.byok-doc__anchor-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 36px;
    position: sticky;
    top: 0;
    z-index: 5;
    background: #F7FAFF;
    padding: 10px 0;
}

.byok-doc__anchor-nav a {
    background: #FFFFFF;
    border: 1px solid #E3ECFB;
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 13.5px;
    font-weight: 600;
    color: #2563EB;
    text-decoration: none;
    white-space: nowrap;
}

.byok-doc__anchor-nav a:hover {
    background: #EAF2FF;
    text-decoration: none;
}

.byok-doc__section {
    background: #FFFFFF;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(20, 102, 204, 0.08);
    padding: 32px 32px 36px;
    margin-bottom: 28px;
    scroll-margin-top: 68px;
}

@media (max-width: 600px) {
    .byok-doc__section {
        padding: 24px 18px 28px;
    }
}

.byok-doc__section-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
}

.byok-doc__section-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #EAF2FF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.byok-doc__section h2 {
    font-size: 21px;
    font-weight: 800;
    margin: 0;
    color: #211D2E;
}

.byok-doc__section p {
    font-size: 15px;
    line-height: 1.65;
    color: #333A4D;
    margin: 0 0 14px;
}

.byok-doc__section p:last-child {
    margin-bottom: 0;
}

.byok-doc__section code {
    background: #EEF3FE;
    color: #1745B8;
    border-radius: 6px;
    padding: 2px 6px;
    font-size: 0.92em;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
}

.byok-doc__callout {
    background: #FFF3E0;
    border-left: 4px solid #E8A93B;
    border-radius: 12px;
    padding: 14px 18px;
    font-size: 14.5px;
    line-height: 1.55;
    color: #6B4E12;
    margin-bottom: 22px;
}

.byok-doc__callout:last-child {
    margin-bottom: 0;
}

.byok-doc__steps {
    list-style: none;
    margin: 0;
    padding: 0;
    counter-reset: byok-step;
}

.byok-doc__step {
    counter-increment: byok-step;
    position: relative;
    padding: 0 0 22px 40px;
    font-size: 15px;
    line-height: 1.65;
    color: #333A4D;
}

.byok-doc__step:last-child {
    padding-bottom: 0;
}

.byok-doc__step::before {
    content: counter(byok-step);
    position: absolute;
    left: 0;
    top: 0;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #2563EB;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.byok-doc__step p {
    margin: 0 0 8px;
}

.byok-doc__step p:last-child {
    margin-bottom: 0;
}

/* Provider reference table */
.byok-doc__table-wrap {
    overflow-x: auto;
    margin: 0 0 8px;
    -webkit-overflow-scrolling: touch;
}

.byok-doc__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
    min-width: 640px;
}

.byok-doc__table th,
.byok-doc__table td {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 1px solid #E3ECFB;
    vertical-align: top;
    line-height: 1.5;
}

.byok-doc__table th {
    background: #EAF2FF;
    color: #1745B8;
    font-weight: 700;
    white-space: nowrap;
}

.byok-doc__table tr:last-child td {
    border-bottom: none;
}

.byok-doc__table td code {
    background: #EEF3FE;
    color: #1745B8;
    border-radius: 6px;
    padding: 1px 5px;
    font-size: 0.9em;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    white-space: nowrap;
}

.byok-doc__badge {
    display: inline-block;
    border-radius: 999px;
    padding: 2px 9px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.byok-doc__badge--yes {
    background: #E7F6EC;
    color: #1B8A4A;
}

.byok-doc__badge--no {
    background: #FCEBEC;
    color: #C0392B;
}

/* Starter-prompt blocks (one per language, toggled by the site's own
   RU/EN switcher -- see the inline script at the bottom of the page) */
.byok-doc__prompt {
    margin-bottom: 18px;
}

.byok-doc__prompt-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.byok-doc__prompt-label {
    font-size: 13px;
    font-weight: 700;
    color: #42526E;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.byok-doc__copy-btn {
    border: 1px solid #2563EB;
    background: #FFFFFF;
    color: #2563EB;
    border-radius: 999px;
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.byok-doc__copy-btn:hover {
    background: #2563EB;
    color: #FFFFFF;
}

.byok-doc__copy-btn.is-copied {
    background: #1B8A4A;
    border-color: #1B8A4A;
    color: #FFFFFF;
}

.byok-doc__prompt pre {
    background: #14161F;
    color: #E4E8F1;
    border-radius: 14px;
    padding: 18px 20px;
    font-size: 13px;
    line-height: 1.65;
    white-space: pre-wrap;
    word-break: break-word;
    margin: 0;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    max-height: 420px;
    overflow-y: auto;
}

.byok-doc__prompt-field {
    font-size: 12px;
    font-weight: 700;
    color: #8AA0C9;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    display: block;
    margin: 14px 0 4px;
}

.byok-doc__prompt-field:first-child {
    margin-top: 0;
}
