@import "~xterm/css/xterm.css";

/* Our terminal or logs */
.console-ct {
    font-family: Menlo, Monaco, Consolas, monospace;
    margin-top: 0;
    margin-bottom: 0;
    font-size: var(--pf-global--FontSize--md);
    text-align: center;
    line-height: normal;
}

@media (min-width: 568px) {
    .console-ct {
        font-size: var(--pf-global--FontSize--sm);
    }
}

.console-ct > pre {
    text-align: left;
    display: block;
    font-family: inherit;
    font-size: inherit;
    width: 48em;
    height: 310px;
    overflow-y: scroll;
    white-space: pre-wrap;
    margin: 0 auto;
}

.console-ct > .terminal {
    display: flex;
    height: 100%;
    /* Vertically center the terminal to split the extra space between top and bottom */
    align-items: center;
    /* Add a touch of space to the left */
    padding-left: var(--pf-global--spacer--xs);
}

.terminal .terminal-cursor {
    border: 1px solid var(--pf-global--palette--black-200);
}

.terminal:focus .terminal-cursor {
    border: none;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    from {
        color: var(--ct-color-text);
        background: var(--pf-global--palette--black-200);
    }
    50% {
        color: var(--pf-global--palette--black-200);
        background: var(--ct-color-text);
    }
}

/* Ensure the console fits to its container (and doesn't attempt to go beyond the limits) */
.xterm-screen, .xterm-viewport {
    width: auto !important;
}
