/* ==========================================
   GLOBAL COMMAND PALETTE
========================================== */

.atlas-header-input-wrap{ position:relative; }
.atlas-header-input-wrap .atlas-header-search-input{ padding-right:76px; }

.atlas-command-trigger{
    position:absolute;
    right:7px;
    top:50%;
    display:flex;
    align-items:center;
    min-height:29px;
    padding:4px 7px;
    border:1px solid var(--border);
    border-radius:8px;
    background:rgba(255,255,255,.035);
    color:var(--text-light);
    cursor:pointer;
    transform:translateY(-50%);
    transition:.2s ease;
}

.atlas-command-trigger:hover{
    border-color:rgba(var(--workspace-accent-rgb),.45);
    background:rgba(var(--workspace-accent-rgb),.08);
    color:var(--text);
}

.atlas-command-trigger kbd,
.atlas-command-palette kbd{
    font-family:inherit;
    font-size:12px;
    font-weight:600;
}

.atlas-command-palette{
    width:min(760px,calc(100vw - 30px));
    max-height:min(760px,calc(100vh - 30px));
    padding:0;
    overflow:hidden;
    border:1px solid var(--border);
    border-radius:20px;
    background:var(--panel);
    color:var(--text);
    box-shadow:0 30px 90px rgba(0,0,0,.5);
}

.atlas-command-palette::backdrop{
    background:rgba(4,7,12,.78);
    backdrop-filter:blur(7px);
}

.atlas-command-shell{
    display:grid;
    grid-template-rows:auto minmax(0,1fr) auto;
    max-height:min(760px,calc(100vh - 30px));
}

.atlas-command-shell > header{
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    gap:11px;
    padding:15px 17px;
    border-bottom:1px solid var(--border);
}

.atlas-command-shell > header > i{
    color:var(--workspace-accent);
    font-size:17px;
}

.atlas-command-shell > header label{
    position:absolute;
    width:1px;
    height:1px;
    overflow:hidden;
    clip:rect(0 0 0 0);
}

.atlas-command-shell > header input{
    width:100%;
    min-height:42px;
    padding:0;
    border:0;
    outline:0;
    background:transparent;
    color:var(--text);
    font-family:inherit;
    font-size:16px;
}

.atlas-command-shell > header input::placeholder{ color:var(--text-light); }
.atlas-command-shell > header > kbd{
    padding:5px 7px;
    border:1px solid var(--border);
    border-radius:7px;
    background:rgba(255,255,255,.03);
    color:var(--text-light);
}

#atlasCommandResults{
    min-height:260px;
    overflow:auto;
    padding:9px;
}

.atlas-command-group + .atlas-command-group{ margin-top:7px; }
.atlas-command-group > h3{
    margin:0;
    padding:8px 9px 5px;
    color:var(--text-light);
    font-size:12px;
    font-weight:700;
    letter-spacing:.8px;
    text-transform:uppercase;
}

.atlas-command-group > div{ display:grid; gap:3px; }
.atlas-command-result{
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto auto;
    align-items:center;
    gap:11px;
    width:100%;
    min-width:0;
    padding:10px;
    border:1px solid transparent;
    border-radius:11px;
    background:transparent;
    color:var(--text);
    font-family:inherit;
    text-align:left;
    cursor:pointer;
}

.atlas-command-result:hover,
.atlas-command-result.active{
    border-color:rgba(var(--workspace-accent-rgb),.34);
    background:rgba(var(--workspace-accent-rgb),.09);
}

.atlas-command-icon{
    width:38px;
    height:38px;
    display:grid;
    place-items:center;
    border-radius:10px;
    background:rgba(var(--workspace-accent-rgb),.1);
    color:var(--workspace-accent);
}

.atlas-command-copy{ min-width:0; }
.atlas-command-copy strong,
.atlas-command-copy small{ display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.atlas-command-copy strong{ font-size:13px; }
.atlas-command-copy small{ margin-top:3px; color:var(--text-light); font-size:12px; }

.atlas-command-meta{
    max-width:140px;
    overflow:hidden;
    padding:5px 8px;
    border-radius:999px;
    background:rgba(255,255,255,.045);
    color:var(--text-light);
    font-size:12px;
    text-overflow:ellipsis;
    white-space:nowrap;
}

.atlas-command-arrow{
    color:var(--text-light);
    font-size:12px;
    opacity:0;
    transform:translateX(-4px);
    transition:.2s ease;
}

.atlas-command-result.active .atlas-command-arrow,
.atlas-command-result:hover .atlas-command-arrow{ opacity:1; transform:translateX(0); }

.atlas-command-empty{
    display:grid;
    place-items:center;
    align-content:center;
    min-height:300px;
    padding:30px;
    color:var(--text-light);
    text-align:center;
}

.atlas-command-empty i{ margin-bottom:10px; color:var(--workspace-accent); font-size:27px; }
.atlas-command-empty strong{ color:var(--text); font-size:16px; }
.atlas-command-empty p{ max-width:430px; margin:6px 0 0; font-size:12px; line-height:1.55; }

.atlas-command-shell > footer{
    display:flex;
    align-items:center;
    gap:18px;
    padding:10px 16px;
    border-top:1px solid var(--border);
    color:var(--text-light);
    font-size:12px;
}

.atlas-command-shell > footer span{ display:inline-flex; align-items:center; gap:5px; }
.atlas-command-shell > footer kbd{
    min-width:22px;
    padding:3px 5px;
    border:1px solid var(--border);
    border-radius:6px;
    background:rgba(255,255,255,.03);
    color:var(--text);
    text-align:center;
}
.atlas-command-shell > footer span:last-child{ margin-left:auto; }
.atlas-command-shell > footer i{ color:var(--workspace-accent); }

@media (max-width:700px){
    .atlas-command-meta{ display:none; }
    .atlas-command-shell > footer{ gap:10px; }
    .atlas-command-shell > footer span:last-child{ display:none; }
}

@media (max-width:480px){
    .atlas-command-trigger{ display:none; }
    .atlas-header-input-wrap .atlas-header-search-input{ padding-right:12px; }
    .atlas-command-palette{ width:calc(100vw - 16px); max-height:calc(100vh - 16px); border-radius:16px; }
    .atlas-command-shell{ max-height:calc(100vh - 16px); }
    .atlas-command-shell > footer span:nth-child(2){ margin-left:auto; }
}
