/*
 * Ghost Proxy's additions to the shared Ghost Assembly docs template.
 *
 * style.css is the template, kept byte-identical with the other Ghost Assembly
 * sites; what only this site needs lives here, loaded after it, using the
 * template's tokens. The one exception is the hero drawing, which takes the
 * extension's own colors (extension/base.css, dark scheme) so it looks like
 * the real popup.
 */

/* ---- The product drawing: toolbar icon and popup ------------------------ */

.gp-shot {
    gap: 8px;
    font-family: system-ui, sans-serif;
}

.gp-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    width: min(100%, 360px);
    padding: 8px 10px;
    border: 1px solid #30363d;
    border-radius: 12px;
    background: #1f252d;
}

.gp-omnibox {
    flex: 1;
    height: 26px;
    border-radius: 13px;
    background: #0d1117;
}

.gp-icon {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgb(255 255 255 / 0.1);
}

.gp-popup {
    width: min(100%, 300px);
    overflow: hidden;
    border: 1px solid #30363d;
    border-radius: 10px;
    background: #161b22;
    box-shadow: 0 18px 40px rgb(0 0 0 / 0.5);
    color: #e6edf3;
    font-size: 13px;
    line-height: 1.45;
}

.gp-head {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: #24292f;
}

.gp-head b {
    font-size: 14px;
    font-weight: 650;
}

.gp-head span {
    margin-inline-start: auto;
    font-size: 12px;
    opacity: 0.8;
}

.gp-rows {
    margin: 0;
    padding: 8px 8px 4px;
    list-style: none;
}

.gp-rows li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
}

/* The arch in the proxy's color, as the popup draws it. */
.gp-rows i {
    flex: none;
    width: 12px;
    height: 14px;
    border: 2.4px solid var(--c);
    border-block-end: 0;
    border-radius: 6px 6px 0 0;
}

.gp-rows b {
    font-weight: 550;
    white-space: nowrap;
}

.gp-rows span {
    margin-inline-start: auto;
    overflow: hidden;
    color: #9198a1;
    font-size: 12px;
    font-variant-numeric: tabular-nums;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.gp-rows .on {
    background: color-mix(in srgb, var(--c) 15%, transparent);
    box-shadow: inset 3px 0 0 var(--c);
}

.gp-foot {
    padding: 8px 18px 10px;
    border-block-start: 1px solid #30363d;
    color: #4493f8;
}

/* ---- Palette and toolbar states ----------------------------------------- */

.gp-palette {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    margin: 20px 0 0;
    padding: 0;
    color: var(--mist);
    font-size: 14px;
    list-style: none;
}

.gp-palette li {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.gp-palette li::before {
    content: '';
    width: 14px;
    height: 14px;
    border-radius: 4px;
    background: var(--c);
}

.gp-states {
    display: grid;
    gap: 12px;
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
}

.gp-states li {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--raised);
}

/* The icon's tile; slate with a grey inner arch when plain, as lib/icon.js draws it. */
.gp-tile {
    position: relative;
    display: block;
    width: 36px;
    height: 36px;
    border-radius: 9px;
    background: var(--c, #24292f);
    box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.12);
}

.gp-tile::before,
.gp-tile::after {
    content: '';
    position: absolute;
    border: 3px solid #24292f;
    border-block-end: 0;
}

.gp-tile::before {
    inset: 9px 8px 7px;
    border-radius: 10px 10px 0 0;
}

.gp-tile::after {
    inset: 15px 13px 7px;
    border-width: 2.5px;
    border-radius: 5px 5px 0 0;
}

.gp-tile.plain::before {
    border-color: #e6edf3;
}

.gp-tile.plain::after {
    border-color: #6e7781;
}

.gp-tile b {
    position: absolute;
    inset-block-start: -6px;
    inset-inline-end: -8px;
    min-width: 18px;
    padding: 0 4px;
    border-radius: 9px;
    background: #6e7781;
    color: #ffffff;
    font-size: 12px;
    line-height: 18px;
    text-align: center;
}

.gp-tile b.down {
    background: #cf222e;
}

/* Bypass entries such as <-loopback> must read as typed, not as an arrow ligature. */
.content code {
    font-variant-ligatures: none;
}
