.terminal-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
    background-color: var(--color-third);
    overflow: hidden;
}

.terminal-scroll-wrapper {
    height: 100%;
    width: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: var(--scroll-thumb) var(--scroll-background);
    position: relative;
    padding-bottom: 0px;
}

.terminal-output {
    flex-grow: 1;
    /* padding: 10px; */
    white-space: pre-wrap;
    overflow-y: auto;
    font-family: monospace;
    font-size: 13px;
    color: var(--token-identifier-js, var(--editor-foreground));
    /* color: var(--color-text); */
    padding-bottom: 0;
    /* border-bottom: 1px solid var(--color-border-hover); */
}

.terminal-block {
    padding: 8px 10px;
    /* padding-bottom: 16px; */
    border-top: 1px solid transparent;
    /* transition: background 0.2s, border 0.2s; */
    border-bottom: 1px solid var(--color-fourth);
    border-top: 1px solid transparent;
}

.terminal-block:last-of-type {
    /* border-bottom: 1px solid transparent; */
}

.terminal-block:hover {
    border-color: var(--color-border-color);
    background: var(--color-blur);
}

.terminal-block:last-of-type:hover {
    /* border-bottom: 1px solid transparent; */
}

.terminal-input-line {
    display: flex;
    align-items: center;
    padding: 0px 10px;
    padding-top: 8px;
    padding-bottom: 20px;
    /* position: sticky;
    bottom: 0px; */
    background-color: var(--color-third);
    /* border-top: 1px solid var(--color-border-color); */

}

.terminal-input-line .prompt {
    font-family: monospace;
    font-size: 13px;
    color: var(--token-string, var(--editor-keyword), var(--editor-keyword)) !important;
    padding-right: 5px;
    user-select: none;
    font-weight: 500;
    white-space: nowrap;
}

#terminal-input {
    flex: 1;
    background: transparent;
    border: none;
    color: inherit;
    font-family: monospace;
    font-size: 13px;
    outline: none;
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    font-weight: 500 !important;
}

.terminal-cmd {
    /* padding-top: 8px; */
    padding-bottom: 8px;
    font-family: monospace;
    font-size: 13px;
}

.terminal-cmd .terminal-prompt {
    color: var(--token-string, var(--editor-keyword), var(--editor-keyword)) !important;
    font-weight: 500;
    margin-right: 4px;
}

.terminal-cmd .terminal-input {
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    font-weight: 500 !important;
}

.terminal-welcome {
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    font-weight: 500;
}

.terminal-command {
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    font-weight: 500;
}

.terminal-usage {
    color: var(--token-comment, var(--editor-foreground));
}


.terminal-usage {
    color: var(--token-comment, var(--editor-foreground));
}

.terminal-file {
    color: var(--token-objectName, var(--editor-keyword));
}

.terminal-dir {
    color: var(--token-objectName, var(--editor-keyword));
    font-weight: bold;
}

.terminal-meta {
    color: var(--token-comment, var(--editor-foreground));
}

.terminal-logo {
    white-space: pre;
    font-family: monospace;
    color: var(--token-comment, var(--editor-keyword));
    /* or a custom color */
    line-height: 1.2;
    font-weight: bold;
    font-size: 4px;
    display: none;
}

.terminal-confirm {
    color: var(--color-error);
    /* border-left: 2px solid var(--color-error); */
    /* background-color: rgba(220, 53, 69, 0.12);
    padding: 5px;
    padding-left: 12px;
    margin-bottom: 8px; */
    margin-bottom: 8px;
}


#custom-input-container {
    font-family: monospace;
    background: transparent;
    color: var(--color-text);
    min-height: 1em;
    white-space: pre-wrap;
    outline: none;
    cursor: text;
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    font-weight: 500 !important;
    width: calc(100% - 20px);
}

.caret {
    display: inline-block;
    width: 7px;
    height: 17px;
    background-color: transparent;
    border: 1px solid var(--color-border-hover);
    /* background: var(--token-identifier-js, var(--editor-foreground)); */
    /* animation: blink 1s steps(1) infinite; */
    vertical-align: bottom;
}

#custom-input-container:focus .caret {
    background: var(--token-identifier-js, var(--editor-foreground));
    border: 1px solid var(--token-identifier-js, var(--editor-foreground));
    /* background: var(--color-text); */
    animation: blink 1s steps(1) infinite;
}

@keyframes blink {
    50% {
        background: transparent;
        border: 1px solid var(--color-border-hover);
    }
}


/* Help Menu Styles */
.help-header {
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    /* font-weight: bold;
    font-size: 16px; */
    font-style: italic;
    padding: 8px 0;
    margin-bottom: 12px;
}

/* ── collapsible help sections ─────────────────────────────── */
.help-section {
    margin-bottom: 0px;
}

.help-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    user-select: none;
    padding: 4px 8px;
    color: var(--token-string, var(--editor-keyword)) !important;
    border-left: 2px solid var(--token-string, var(--editor-keyword));
}

.help-toggle:hover {
    background: var(--color-fifth);
}

.help-chevron {
    font-size: 10px;
    transition: transform .15s ease;
}

.help-commands {
    display: none;
    /* padding: 2px 0 2px 22px; */
    padding-left: 12px;
}

/* open state */
.help-section[data-open="true"] .help-chevron {
    transform: rotate(90deg);
}

.help-section[data-open="true"] .help-commands {
    display: block;
}

.help-category {
    color: var(--token-string, var(--editor-keyword)) !important;
    /* font-weight: bold;
    font-size: 14px; */
    margin: 12px 0 6px 0;
    padding: 4px 8px;
    /* 
    border-left: 2px solid var(--token-string, var(--editor-keyword)); */

}

.help-command {
    display: flex;
    padding: 0px 8px;
    font-size: 13px;
    margin-left: 12px;
    border-radius: 3px;
}

.help-command:hover {
    background: var(--color-fifth);
}

.help-cmd-name {
    color: var(--token-objectName, var(--editor-keyword)) !important;
    font-weight: 500;
    min-width: 120px;
    padding-right: 16px;
}

.help-cmd-desc {
    flex: 1;
}

.help-footer {
    color: var(--token-comment, var(--editor-foreground));
    font-style: italic;
    padding: 12px 0;
    margin-top: 8px;
}

.help-highlight {
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    font-weight: 500;
    background: var(--color-fourth);
    padding: 2px 6px;
    border-radius: 3px;
}

/* Manual Page Styles */
.man-header {
    color: var(--token-keyword-declaration, var(--editor-keyword)) !important;
    /* font-weight: bold;
    font-size: 15px; */
    padding: 6px 0;
    padding-left: 14px;
    font-weight: 500;
}

.man-description {
    color: var(--token-identifier-js, var(--editor-foreground));
    /* color: var(--color-text); */
    line-height: 1.4;
    padding: 8px 0;
    padding: 12px;
    border-radius: 0px;
    border-left: 2px solid var(--token-objectName, var(--editor-keyword));
}

.man-summary {
    color: var(--token-comment, var(--editor-foreground));
    font-style: italic;
    padding: 6px 12px;
    border-radius: 3px;
}

.man-usage {
    color: var(--token-string, var(--editor-keyword)) !important;
    font-weight: 500;
    padding: 8px 12px;
    background: var(--color-blur);
    border-radius: 4px;
    border-left: 3px solid var(--token-string, var(--editor-keyword));
}

.man-error {
    color: var(--token-error, #ff6b6b);
    font-weight: 500;
    padding: 8px 12px;
    background: rgba(255, 107, 107, 0.1);
    border-radius: 4px;
    border-left: 3px solid var(--token-error, #ff6b6b);
}


.git-table-line {
    white-space: pre;
    /* preserves spacing and disables wrap */
    font-family: monospace;
    font-size: 13px;
    padding: 0px 8px;
    border-radius: 3px;
}

.git-table-line:hover {
    background-color: var(--color-fifth);
}

.git-cmd {
    color: var(--token-objectName, var(--editor-keyword));
    font-weight: 500;
}