#ksp-advisor {
    position: fixed;
    inset: auto 1rem 1rem auto;
    z-index: 9990;
    width: min(24rem, calc(100% - 2rem));
    --ksp-orange: #ff811f;
    color: #161616;
    font: 15px/1.45 system-ui, sans-serif;
    display: grid;
    justify-items: end;
    gap: .6rem;
}
#ksp-panel[hidden] { display: none; }
#ksp-panel {
    box-sizing: border-box;
    width: 100%;
    max-height: min(70vh, 38rem);
    overflow: auto;
    background: var(--ksp-orange);
    border: 1px solid #bb5000;
    border-radius: .75rem;
    padding: 1rem;
    box-shadow: 0 8px 32px #0003;
}
#ksp-panel h2 { font-size: 1.2rem; margin: 0 0 .7rem; }
#ksp-panel form { display: grid; gap: .45rem; margin: 0; }
#ksp-query { box-sizing: border-box; width: 100%; min-height: 2.5rem; font-size: 16px; }
#ksp-advisor button {
    border: 0;
    border-radius: .4rem;
    background: var(--ksp-orange);
    color: #161616;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    padding: .55rem .9rem;
}
#ksp-advisor button:disabled { opacity: .65; cursor: wait; }
#ksp-advisor :focus-visible { outline: 3px solid #1858ab; outline-offset: 2px; }
#ksp-panel .ksp-note { font-size: .8rem; margin: .6rem 0; }
#ksp-panel .ksp-status { margin: .7rem 0; }
#ksp-panel .ksp-results { list-style: none; padding: 0; margin: 0; }
#ksp-panel .ksp-results:not(:empty) { background: #fffaf5; border-radius: .5rem; padding: 0 .65rem; }
#ksp-panel li + li { border-top: 1px solid #eee; }
#ksp-panel li a {
    display: flex;
    align-items: center;
    gap: .65rem;
    padding: .6rem 0;
    color: #171717;
    text-decoration: none;
}
#ksp-panel li a:hover strong { text-decoration: underline; }
#ksp-panel li img { width: 3.25rem; height: 3.25rem; object-fit: contain; }
#ksp-panel li span { display: block; }
#ksp-panel .ksp-summary { color: #555; font-size: .85rem; }
#ksp-panel .ksp-stock { color: #17602c; font-weight: 600; }

#ksp-heading, #ksp-advisor .ksp-toggle {
    display: flex;
    align-items: center;
    gap: .55rem;
}
#ksp-advisor .ksp-brand-logo {
    box-sizing: border-box;
    display: block;
    flex: none;
    width: 4.5rem;
    height: 2.25rem;
    padding: .2rem;
    background: #fff;
    border-radius: .3rem;
    object-fit: contain;
}
#ksp-advisor .ksp-toggle {
    max-width: 100%;
    box-shadow: 0 3px 12px #0003;
}
#ksp-panel form button {
    background: #161616;
    color: #fff;
}
