/* Command Palette Styles */

.cmd-palette-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.cmd-palette-overlay.active {
    opacity: 1;
    visibility: visible;
}

.cmd-palette {
    position: fixed;
    top: 20%;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    width: 90%;
    max-width: 580px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
    overflow: hidden;
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.cmd-palette.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.cmd-palette-search {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #eee;
}

.cmd-palette-search svg {
    width: 20px;
    height: 20px;
    color: #999;
    flex-shrink: 0;
}

.cmd-palette-search input {
    flex: 1;
    padding: 0.5rem 0;
    font-size: 1rem;
    border: none;
    outline: none;
    font-family: inherit;
    background: transparent;
}

.cmd-palette-search input::placeholder {
    color: #999;
}

.cmd-palette-hint {
    font-size: 0.7rem;
    color: #999;
    background: #f5f5f5;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.cmd-palette-results {
    max-height: 400px;
    overflow-y: auto;
    padding: 0.5rem;
}

.cmd-palette-category {
    padding: 0.75rem 0.75rem 0.5rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #999;
}

.cmd-palette-category:first-child {
    padding-top: 0.25rem;
}

.cmd-palette-separator {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0.5rem 0.75rem;
}

.cmd-palette-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.cmd-palette-item:hover,
.cmd-palette-item.selected {
    background: #f5f5f0;
}

.cmd-palette-item-icon {
    font-size: 1.25rem;
    width: 2rem;
    text-align: center;
}

.cmd-palette-item-content {
    flex: 1;
    min-width: 0;
}

.cmd-palette-item-title {
    font-weight: 500;
    font-size: 0.95rem;
    color: #1a1a1a;
}

.cmd-palette-item-desc {
    font-size: 0.8rem;
    color: #999;
    margin-top: 0.125rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cmd-palette-empty {
    padding: 2rem;
    text-align: center;
    color: #999;
}

.cmd-palette-footer {
    display: flex;
    gap: 1.5rem;
    padding: 0.75rem 1.25rem;
    border-top: 1px solid #eee;
    background: #fafafa;
    font-size: 0.75rem;
    color: #999;
}

.cmd-palette-footer kbd {
    display: inline-block;
    padding: 0.15rem 0.4rem;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 0.7rem;
    margin-right: 0.25rem;
}

/* Trigger hint button */
.cmd-trigger-hint {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    padding: 0.5rem 0.75rem;
    background: rgba(26, 26, 26, 0.9);
    color: #fff;
    border-radius: 8px;
    font-size: 0.8rem;
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    cursor: pointer;
    z-index: 100;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.cmd-trigger-hint:hover {
    transform: translateY(-2px);
}

.cmd-trigger-hint kbd {
    display: inline-block;
    padding: 0.125rem 0.375rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-family: inherit;
    margin-right: 0.25rem;
}

/* Scrollbar styling */
.cmd-palette-results::-webkit-scrollbar {
    width: 8px;
}

.cmd-palette-results::-webkit-scrollbar-track {
    background: transparent;
}

.cmd-palette-results::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 4px;
}

.cmd-palette-results::-webkit-scrollbar-thumb:hover {
    background: #ccc;
}
