.protocol-tools {
    position: sticky;
    z-index: 10;
    top: 0;
    display: flex;
    min-height: 44px;
    align-items: center;
    justify-content: flex-end;
    margin: -8px -8px 12px;
    padding: 0 16px;
    border-bottom: 1px solid #e5edf5;
    background: #f2f6fa;
}

.protocol-copy-button,
.protocol-tools .protocol-action {
    border: 0;
    background: transparent;
    color: #3795c0;
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
    font-size: 16px;
    font-weight: 500;
    font-style: normal;
    letter-spacing: normal;
    line-height: 44px;
    padding: 0;
    text-decoration: none;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.protocol-tools > * + * {
    margin-left: 20px;
}

.protocol-tools .protocol-history-action {
    margin-right: auto;
}

.protocol-copy-toast {
    position: fixed;
    z-index: 100;
    bottom: 72px;
    left: 50%;
    padding: 8px 14px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.72);
    color: #fff !important;
    font-size: 14px;
    line-height: 20px;
    opacity: 0;
    pointer-events: none;
    transform: translateX(-50%);
    transition: opacity 0.2s;
}

.protocol-copy-toast.show {
    opacity: 1;
}

body.dark .protocol-tools {
    border-bottom-color: rgba(255, 255, 255, 0.08);
    background: #262a32;
}

body.dark .protocol-copy-button,
body.dark .protocol-tools .protocol-action {
    color: #4aa8ec;
}

.protocol-version { text-align: left; text-indent: 0; }
.protocol-history-page { margin: 0; background: #f7f7f7; color: #19191a; font-family: sans-serif; }
.protocol-history-page ul { margin: 0; padding: 0; list-style: none; background: #fff; }
.protocol-history-page li a { position: relative; display: block; padding: 18px 44px 18px 16px; border-bottom: 1px solid #eee; color: inherit; text-decoration: none; font-size: 16px; line-height: 1.5; }
.protocol-history-page li a::after { position: absolute; top: 50%; right: 18px; width: 7px; height: 7px; border-top: 2px solid #aaa; border-right: 2px solid #aaa; content: ""; transform: translateY(-50%) rotate(45deg); }
.protocol-history-page #history-error { margin: 16px; }
.protocol-history-page.dark { background: #121212; color: #fff; }
.protocol-history-page.dark ul { background: #282828; }
.protocol-history-page.dark li a { border-color: #444; }
.protocol-history-page.dark li a::after { border-color: #777; }
.protocol-archive { font-size: 14px; line-height: 1.7; overflow-wrap: break-word; }
.protocol-archive h1 { font-size: 18px; text-align: center; }
.protocol-archive.dark { background: #282828; color: #fff; }
