﻿@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

/*
 * LEGACY STYLESHEET — przejściowy.
 *
 * Tokeny --codli-color-* zostały przemapowane na Codli Design (--brand-*, --ink-*).
 * Klasy .codli-* są tu zachowane tymczasowo, dopóki nie przepiszemy wszystkich
 * legacy komponentów na nowe klasy .r-* / .rise-card-*.
 *
 * Design system: Standalone/Codli.Design/DESIGN.md
 */

:root {
    /* Aliasy back-compat — wskazują na nowe tokeny zdefiniowane w app.css */
    --codli-color-900: var(--brand-700);
    --codli-color-700: var(--brand-500);
    --codli-color-300: var(--brand-200);
    --codli-color-hover: var(--brand-600);
    --codli-color-active: var(--brand-500);
    --codli-color-light: var(--ink-50);
    --codli-color-dark: var(--ink-900);
    --codli-color-white: var(--ink-0);
    --codli-color-black: var(--ink-950);
    --codli-color-backdrop-900: rgba(26, 35, 126, 0.69);
    --codli-color-backdrop-hover: rgba(36, 51, 153, 0.69);
    --codli-color-backdrop-active: rgba(47, 67, 184, 0.69);
    --codli-white-backdrop: rgba(255, 255, 255, 0.69);
    --codli-black-backdrop: rgba(10, 11, 20, 0.69);
    --codli-color-backdrop-light: rgba(248, 249, 251, 0.69);
    --codli-color-backdrop-dark: rgba(31, 34, 49, 0.69);
    --default-radius: 10px;

    /* Roboto alias — niektóre legacy komponenty referują tę zmienną. Mapujemy na Geist. */
    --roboto-font: var(--font-sans);
}

html, body {
    font-family: var(--font-sans);
}

a, .btn-link {
    color: #0366d6;
}

.btn-sublink {
    padding-left: 0;
    font-size: 12px;
    line-height: inherit;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

app {
    position: relative;
    display: flex;
    flex-direction: column;
}

.top-row {
    height: 3.5rem;
    display: flex;
    align-items: center;
}

.main {
    flex: 1;
    font-family: var(--roboto-font) !important;
}

    .main .top-row {
        color: white;
        background-color: var(--codli-color-backdrop-900);
        backdrop-filter: blur(10px);
        box-shadow: 1px 1px 5px var(--codli-color-dark);
        justify-content: flex-end;
    }

        .main .top-row > a, .main .top-row .btn-link {
            white-space: nowrap;
            margin-left: 1.5rem;
            color: white;
        }

        .main .top-row a:first-child {
            overflow: hidden;
            text-overflow: ellipsis;
        }

.sidebar {
    background-color: var(--codli-color-900);
}

.nav-menu-shell {
    min-height: calc(100vh - 3.5rem);
    display: flex;
    flex-direction: column;
    position: relative;
    padding-bottom: 2rem;
}

    .nav-menu-shell .nav {
        flex: 1 1 auto;
    }

    .sidebar .top-row {
        background-color: rgba(0,0,0,0.4);
    }

    .sidebar .navbar-brand {
        font-size: 1.1rem;
        font-family: var(--roboto-font);
        font-weight: 300;
    }

    .sidebar .oi {
        width: 2rem;
        font-size: 1.1rem;
        vertical-align: text-top;
        top: -2px;
    }

    .sidebar .nav-item {
        font-size: 0.9rem;
        padding-bottom: 0.5rem;
    }

        .sidebar .nav-item:first-of-type {
            padding-top: 1rem;
        }

        .sidebar .nav-item:last-of-type {
            padding-bottom: 1rem;
        }

        .sidebar .nav-item a {
            color: #d7d7d7;
            border-radius: 4px;
            height: 3rem;
            display: flex;
            align-items: center;
            line-height: 3rem;
        }

            .sidebar .nav-item a.active {
                background-color: rgba(255,255,255,0.25);
                color: white;
            }

            .sidebar .nav-item a:hover {
                background-color: rgba(255,255,255,0.1);
                color: white;
            }

    .sidebar .version-info {
        position: absolute;
        left: 50%;
        bottom: 0.85rem;
        transform: translateX(-50%);
        width: 100%;
        padding: 0 1rem;
        color: rgba(255,255,255,0.48);
        font-size: 0.72rem;
        line-height: 1;
        letter-spacing: 0.04em;
        text-align: center;
        pointer-events: none;
    }

.content {
    padding-top: 1.1rem;
}

.navbar-toggler {
    background-color: rgba(255, 255, 255, 0.1);
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

@media (max-width: 767.98px) {
    .main .top-row:not(.auth) {
        display: none;
    }

    .main .top-row.auth {
        justify-content: space-between;
    }

    .main .top-row a, .main .top-row .btn-link {
        margin-left: 0;
    }

    .codli-btn-holder > button {
        width: 100%;
        margin-top: 10px;
    }
}

@media (min-width: 768px) {
    app {
        flex-direction: row;
    }

    .sidebar {
        width: 250px;
        height: 100vh;
        position: sticky;
        top: 0;
    }

    .main .top-row {
        position: sticky;
        top: 0;
    }

    .main > div {
        padding-left: 2rem !important;
        padding-right: 1.5rem !important;
    }

    .navbar-toggler {
        display: none;
    }

    .sidebar .collapse {
        /* Never collapse the sidebar for wide screens */
        display: block;
    }

    .codli-btn-holder > button {
        margin-right: 10px;
    }
}

/*CODLI*/

button {
    transition: 300ms;
}



.btn {
    font-family: var(--roboto-font);
    font-weight: 300;
}

.btn-link {
    color: var(--codli-color-900) !important;
}


.table {
    font-family: var(--roboto-font) !important;
}







.btn-group > button {
    box-shadow: none;
}

.btn-group {
    box-shadow: 1px 1px 5px var(--codli-color-dark);
}

.manual-page {
    padding-bottom: 24px;
}

.mcp-manual-intro {
    margin-bottom: 24px;
}

.mcp-agent-switcher {
    background-color: #FFFFFF;
    border: 1px solid #D9DDED;
    border-radius: var(--default-radius);
    box-shadow: 1px 1px 5px #00000020;
    overflow: hidden;
}

.mcp-agent-switcher-header {
    padding: 16px 18px 4px 18px;
    border-bottom: 1px solid #E4E7F3;
}

    .mcp-agent-switcher-header > h5 {
        margin-bottom: 6px;
        color: var(--codli-color-900);
    }

.mcp-agent-tabbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 16px 18px;
    border-bottom: 1px solid #E4E7F3;
}

    .mcp-agent-tabbar > button {
        box-shadow: none;
    }

.mcp-agent-panel {
    padding: 18px;
}

.mcp-agent-config-meta {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
    margin-bottom: 14px;
}

.mcp-agent-config-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.mcp-agent-config-code {
    background: #F5F5F5;
    padding: 12px;
    border-radius: 6px;
    font-size: 0.8em;
    overflow-x: auto;
    margin-bottom: 0;
}

.mcp-agent-config-hint {
    margin-top: 10px;
    margin-bottom: 0;
}

.mcp-token-banner-actions {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

@media (max-width: 767.98px) {
    .mcp-agent-tabbar {
        flex-direction: column;
    }

        .mcp-agent-tabbar > button {
            width: 100%;
        }

    .mcp-agent-config-meta {
        flex-direction: column;
        align-items: stretch;
    }
}


.blazored-modal {
    overflow-y: auto !important;
    max-height: 80vh !important;
    background-color: var(--codli-color-white) !important;
    border: none !important;
    box-shadow: 1px 1px 10px #000000 !important;
    border-radius: var(--default-radius) !important;
}

    .blazored-modal::-webkit-scrollbar {
        width: 4px;
    }

    /* Track */
    .blazored-modal::-webkit-scrollbar-track {
        /*box-shadow: inset 0 0 2px grey;
        border-radius: 10px;*/
    }

    /* Handle */
    .blazored-modal::-webkit-scrollbar-thumb {
        background-color: var(--codli-color-900);
    }

        /* Handle on hover */
        .blazored-modal::-webkit-scrollbar-thumb:hover {
            background-color: #FFFFFF;
        }




.blazored-modal-title {
    text-align: center !important;
    width: 100% !important;
    font-weight: 600;
    font-size: 20px;
}

.blazored-modal-close {
    background-color: var(--danger) !important;
    border-radius: 50% !important;
    height: 50px !important;
    width: 50px !important;
    line-height: 50px !important;
    padding: 0 !important;
    color: white !important;
}

    .blazored-modal-close:hover {
        box-shadow: 0 0 10px var(--secondary);
    }


        }

.blazing-quick-actions-panel-title {
    color: var(--text-color);
    margin: 0;
    padding: 20px 0;
    width: 100%;
    text-align: center;
}

.blazing-quick-actions-panel-title-hr {
    color: var(--text-color);
    width: 80%;
}

.blazing-quick-actions-holder {
    font-family: var(--roboto-font);
}

.blazing-quick-actions-panel > h5 {
    font-weight: 300;
    margin-top: 20px;
    margin-bottom: 10px;
    padding: 0;
    width: 100%;
    text-align: center;
}



