﻿.stage-panel
{
    position: relative;
    display: grid;
    grid-template-rows: auto 1fr;
    height: 100vh;
    min-height: 0;
    overflow: hidden;
    background: transparent;
}

.stage-header
{
    position: sticky;
    z-index: 15;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
    background: var(--panel);
}

.stage-header h2
{
    margin: 0;
    font-size: 22px;
}

.stage-header p
{
    margin: 6px 0 0;
    font-size: 13px;
    color: var(--text-dim);
}

.stage-header-tools
{
    display: flex;
    gap: 8px;
    align-items: center;
}

.stage-content
{
    display: grid;
    min-height: 0;
    overflow: hidden;
}

.stage-chat[hidden]
{
    display: none !important;
}

.stage-action
{
    display: grid;
    grid-template-columns: 16px auto;
    gap: 7px;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 9px 12px;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
    background: var(--panel-soft);
    cursor: pointer;
}

.stage-action.primary
{
    border-color: transparent;
    color: #ffffff;
    background: var(--accent);
}

.stage-action:hover,
.stage-action:focus
{
    border-color: #8bcfc6;
    background: #eef8f6;
    outline: none;
}

.stage-action.primary:hover,
.stage-action.primary:focus
{
    background: var(--accent-hover);
}

.stage-action:disabled
{
    cursor: not-allowed;
    opacity: 0.55;
}

.stage-action svg
{
    width: 16px;
    height: 16px;
}

.stage-save-icon,
.stage-reset-icon
{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    flex: 0 0 auto;
    line-height: 0;
}

.stage-save-icon svg,
.stage-reset-icon svg
{
    display: block;
    width: 18px;
    height: 18px;
    stroke-width: 2.2;
}

.stage-layout-toggle
{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    flex: 0 0 auto;
    line-height: 0;
}

.stage-layout-toggle svg
{
    display: block;
    width: 18px;
    height: 18px;
    stroke-width: 2.2;
}

.stage-chat
{
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    height: 100%;
    width: 100%;
    min-height: 0;
    overflow: hidden;
    background: transparent;
}
