.pb-c-stick .title,
.pb-c-text .title,
.pb-c-share .title {
    display: block;
    margin: 0 0 10px;
    color: var(--pbui-ink);
    font: 800 20px/1.2 var(--pbui-font);
}

.pb-c-stick .pb-hint span,
.pb-c-text .pb-hint span {
    text-wrap: balance;
}

html.pb-phone .pb-c-stick,
html.pb-phone .pb-c-text {
    padding-bottom: 28px;
}

.pb-c-text .pb-sub {
    margin: 18px 0 8px;
    color: #5b6b73;
    font: 700 13px/1.3 var(--pbui-font);
    letter-spacing: .06em;
    text-transform: uppercase;
}

@media (hover: hover) and (pointer: fine) {
    .pb-c-stick,
    .pb-c-text,
    .pb-c-share,
    .pb-c-photo .photos {
        scrollbar-gutter: stable;
    }

    .pb-c-stick::-webkit-scrollbar,
    .pb-c-text::-webkit-scrollbar,
    .pb-c-share::-webkit-scrollbar,
    .pb-c-photo .photos::-webkit-scrollbar {
        width: 10px;
        height: 10px;
    }

    .pb-c-stick::-webkit-scrollbar-track,
    .pb-c-text::-webkit-scrollbar-track,
    .pb-c-share::-webkit-scrollbar-track,
    .pb-c-photo .photos::-webkit-scrollbar-track {
        background: transparent;
    }

    .pb-c-stick::-webkit-scrollbar-thumb,
    .pb-c-text::-webkit-scrollbar-thumb,
    .pb-c-share::-webkit-scrollbar-thumb,
    .pb-c-photo .photos::-webkit-scrollbar-thumb {
        border: 2px solid #fff;
        border-radius: 999px;
        background: #cdd5d8;
    }

    .pb-c-stick::-webkit-scrollbar-thumb:hover,
    .pb-c-text::-webkit-scrollbar-thumb:hover,
    .pb-c-share::-webkit-scrollbar-thumb:hover,
    .pb-c-photo .photos::-webkit-scrollbar-thumb:hover {
        background: #a9b6bb;
    }

    @supports not selector(::-webkit-scrollbar) {
        .pb-c-stick,
        .pb-c-text,
        .pb-c-share,
        .pb-c-photo .photos {
            scrollbar-width: thin;
            scrollbar-color: #cdd5d8 transparent;
        }
    }
}

#sidebar .clip-arts {
    display: block;
    width: 100%;
}

#sidebar .pb-cats {
    position: sticky;
    top: 0;
    z-index: 4;
    margin: 0 0 8px;
    padding: 6px 0;
    background: #fff;
}

#sidebar .pb-cats.is-open {
    position: static;
}

#sidebar .pb-cats__rail {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 0;
    padding: 2px 1px;
    position: relative;
}

#sidebar .pb-chip {
    flex: none;
    max-width: 100%;
    height: 32px;
    margin: 0;
    padding: 0 12px;
    overflow: hidden;
    border: 1.5px solid var(--pbui-line);
    border-radius: 999px;
    background: #fff;
    color: var(--pbui-ink);
    font: 700 12.5px/1 var(--pbui-font);
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
    transition: background .15s, border-color .15s, color .15s;
}

#sidebar .pb-chip:hover {
    border-color: var(--pbui-primary);
    color: var(--pbui-primary);
}

#sidebar .pb-chip[aria-pressed="true"] {
    border-color: var(--pbui-primary);
    background: var(--pbui-primary);
    color: #fff;
}

#sidebar .pb-chip:focus-visible {
    outline: 2px solid var(--pbui-primary);
    outline-offset: 2px;
}

#sidebar .pb-cats__more {
    border-style: dashed;
    border-color: var(--pbui-primary);
    color: var(--pbui-primary);
}

#sidebar .pb-cats__more:hover {
    background: var(--pbui-tint);
}

#sidebar .pb-cats.is-open .pb-cats__more {
    order: -1;
}

#sidebar .pb-stg {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    min-height: 120px;
    padding: 0 0 12px;
}

#sidebar .pb-stg .item.sticker {
    position: relative;
    display: block;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border: 1px solid var(--pbui-line);
    border-radius: 10px;
    background: #fff;
    cursor: grab;
    z-index: auto !important;
    transition: border-color .12s, box-shadow .12s, transform .12s;
}

#sidebar .pb-stg .item.sticker:hover {
    border-color: var(--pbui-accent);
    box-shadow: 0 6px 14px -8px rgba(13, 27, 34, .5);
    transform: translateY(-1px);
}

#sidebar .pb-stg .item.sticker:focus-visible {
    outline: 2px solid var(--pbui-primary);
    outline-offset: 2px;
}

#sidebar .pb-stg .item.sticker img {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 5px;
    box-sizing: border-box;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
    transition: opacity .2s;
}

#sidebar .pb-stg .item.sticker.is-load img,
#sidebar .pb-stg .item.sticker.is-bad img {
    opacity: 0;
}

#sidebar .pb-stg .item.sticker.is-bad {
    background: var(--pbui-soft);
    cursor: default;
}

.pb-stsk,
#sidebar .pb-stg .item.sticker.is-load {
    background: linear-gradient(100deg, #f1eee7 30%, #f9f7f3 50%, #f1eee7 70%) 100% 0 / 200% 100%;
    animation: pb-shimmer 1.3s linear infinite;
}

.pb-stsk {
    aspect-ratio: 1 / 1;
    border-radius: 10px;
}

@keyframes pb-shimmer {
    to {
        background-position: 0 0;
    }
}

#sidebar .pb-stmsg {
    display: grid;
    grid-column: 1 / -1;
    justify-items: center;
    gap: 12px;
    padding: 28px 12px;
    color: var(--pbui-muted);
    font: 600 13px/1.4 var(--pbui-font);
    text-align: center;
}

#sidebar .pb-stmsg p {
    margin: 0;
}

#sidebar .pb-stmsg .pb-btn {
    height: 40px;
}

.pb-stprev {
    position: fixed;
    z-index: 3300;
    display: none;
    width: 176px;
    height: 176px;
    padding: 10px;
    box-sizing: border-box;
    border: 1px solid var(--p55-hdr-line, #e6e2d9);
    border-radius: 18px;
    background:
        conic-gradient(#f3f1ec 25%, #fff 0 50%, #f3f1ec 0 75%, #fff 0) 0 0 / 16px 16px;
    box-shadow: 0 18px 40px -14px rgba(13, 27, 34, .55);
    pointer-events: none;
}

.pb-stprev.is-on {
    display: block;
    animation: pb-stprev-in .12s ease-out;
}

.pb-stprev img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

@keyframes pb-stprev-in {
    from {
        opacity: 0;
        transform: scale(.94);
    }
}

@media (prefers-reduced-motion: reduce) {
    .pb-stsk,
    #sidebar .pb-stg .item.sticker.is-load {
        animation: none;
    }

    .pb-stprev.is-on {
        animation: none;
    }

    #sidebar .pb-stg .item.sticker {
        transition: none;
    }
}

html.pb-phone #sidebar .pb-stg {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
}

html.pb-phone #sidebar .pb-stg .item.sticker {
    min-height: 0;
}

html.pb-phone #sidebar .pb-cats__rail {
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
}

html.pb-phone #sidebar .pb-cats__rail::-webkit-scrollbar {
    display: none;
}

html.pb-phone #sidebar .pb-chip {
    height: 40px;
    padding: 0 16px;
    font-size: 13.5px;
    scroll-snap-align: start;
}

html.pb-phone #sidebar .pb-cats__more {
    display: none;
}

#book-content .sticker.active-element {
    outline: 1.5px solid var(--p55-accent, #e6007e);
    outline-offset: 3px;
}

#book-content .sticker .ui-resizable-n,
#book-content .sticker .ui-resizable-e,
#book-content .sticker .ui-resizable-s,
#book-content .sticker .ui-resizable-w {
    display: none !important;
}

#book-content .sticker.active-element .ui-resizable-nw,
#book-content .sticker.active-element .ui-resizable-ne,
#book-content .sticker.active-element .ui-resizable-sw,
#book-content .sticker.active-element .ui-resizable-se {
    display: block;
    width: 14px !important;
    height: 14px !important;
    box-sizing: border-box;
    border: 2px solid var(--p55-accent, #e6007e);
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 6px rgba(13, 27, 34, .28);
    z-index: 5;
}

#book-content .sticker.active-element .ui-resizable-nw {
    top: -11px;
    left: -11px;
}

#book-content .sticker.active-element .ui-resizable-ne {
    top: -11px;
    right: -11px;
}

#book-content .sticker.active-element .ui-resizable-sw {
    bottom: -11px;
    left: -11px;
}

#book-content .sticker.active-element .ui-resizable-se {
    bottom: -11px !important;
    right: -11px !important;
}

#book-content .sticker.active-element .ui-resizable-handle::after {
    content: "";
    position: absolute;
    inset: -8px;
}

#book-content .sticker .ui-rotatable-handle {
    width: 26px;
    height: 26px;
    margin-left: -13px;
    top: -48px;
    box-sizing: border-box;
    border: 2px solid var(--p55-accent, #e6007e);
    border-radius: 50%;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230d1b22' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 11a8 8 0 1 0-2.3 5.7'/%3E%3Cpath d='M20 4v7h-7'/%3E%3C/svg%3E") center / 14px 14px no-repeat;
    box-shadow: 0 2px 6px rgba(13, 27, 34, .28);
    cursor: grab;
}

#book-content .sticker .ui-rotatable-handle::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 100%;
    width: 1.5px;
    height: 17px;
    margin-left: -.75px;
    background: var(--p55-accent, #e6007e);
}

html.pb-coarse #book-content .sticker.active-element .ui-resizable-nw,
html.pb-coarse #book-content .sticker.active-element .ui-resizable-ne,
html.pb-coarse #book-content .sticker.active-element .ui-resizable-sw,
html.pb-coarse #book-content .sticker.active-element .ui-resizable-se,
html.pb-phone #book-content .sticker.active-element .ui-resizable-nw,
html.pb-phone #book-content .sticker.active-element .ui-resizable-ne,
html.pb-phone #book-content .sticker.active-element .ui-resizable-sw,
html.pb-phone #book-content .sticker.active-element .ui-resizable-se {
    width: 22px !important;
    height: 22px !important;
}

html.pb-coarse #book-content .sticker.active-element .ui-resizable-nw,
html.pb-phone #book-content .sticker.active-element .ui-resizable-nw {
    top: -15px;
    left: -15px;
}

html.pb-coarse #book-content .sticker.active-element .ui-resizable-ne,
html.pb-phone #book-content .sticker.active-element .ui-resizable-ne {
    top: -15px;
    right: -15px;
}

html.pb-coarse #book-content .sticker.active-element .ui-resizable-sw,
html.pb-phone #book-content .sticker.active-element .ui-resizable-sw {
    bottom: -15px;
    left: -15px;
}

html.pb-coarse #book-content .sticker.active-element .ui-resizable-se,
html.pb-phone #book-content .sticker.active-element .ui-resizable-se {
    bottom: -15px !important;
    right: -15px !important;
}

#tools-panel {
    padding: 6px;
    border: 1px solid var(--p55-hdr-line, #e6e2d9);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 14px 30px -12px rgba(13, 27, 34, .45);
}

#tools-panel ul li {
    width: 36px;
    height: 36px;
    margin: 0 1px;
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--p55-btn-bg, #0d1b22);
    font-size: 15px;
    line-height: 36px;
    transition: background .12s, color .12s;
}

#tools-panel ul li:hover {
    background: rgba(0, 131, 143, .1);
    color: var(--p55-hdr-icon, #00838f);
}

#tools-panel ul li[onclick*="removeCurrentElement"]:hover {
    background: #fdecea;
    color: #b42318;
}

html.pb-phone #tools-panel ul li {
    width: 44px;
    height: 44px;
    padding: 0;
    line-height: 44px;
}

#sidebar .pb-c-text .pb-txadd {
    width: 100%;
    height: 48px;
    margin: 4px 0 0;
    font-size: 15px;
}

#sidebar .pb-c-text .fonts-list .font-item {
    cursor: pointer;
    user-select: none;
}

#sidebar .pb-c-text .fonts-list .font-item:focus-visible {
    outline: 2px solid var(--pbui-primary);
    outline-offset: 2px;
}

#sidebar .pb-share .pb-share__l {
    display: block;
    margin: 0 0 6px;
    padding: 0;
    font: 600 12.5px/1.3 var(--pbui-font);
    color: var(--pbui-muted);
}

#sidebar .pb-share input.pb-share__in {
    display: block;
    box-sizing: border-box;
    width: 100%;
    height: 48px;
    margin: 0;
    padding: 0 14px;
    border: 1.5px solid var(--pbui-line);
    border-radius: 12px;
    background: #fff;
    color: var(--pbui-ink);
    font: 500 14px/1 var(--pbui-font);
    text-align: left;
    text-overflow: ellipsis;
    cursor: text;
}

#sidebar .pb-share input.pb-share__in:focus {
    border-color: var(--pbui-primary);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(0, 131, 143, .18);
}

#sidebar .pb-share .pb-share__btns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 10px 0 0;
}

#sidebar .pb-share .pb-btn {
    width: 100%;
    min-width: 0;
    height: 48px;
    margin: 0;
    padding: 0 8px;
    gap: 6px;
    font-size: 13.5px;
}

#sidebar .pb-share .pb-btn .pb-ic {
    font-size: 16px;
}

#sidebar .pb-share .pb-share__copy .pb-ic--ok,
#sidebar .pb-share .pb-share__copy.is-done .pb-ic--copy {
    display: none;
}

#sidebar .pb-share .pb-share__copy.is-done .pb-ic--ok {
    display: block;
}

#sidebar .pb-share .pb-share__copy.is-done {
    border-color: #16683e;
    background: #16683e;
}

#sidebar .pb-share .pb-btn[disabled] {
    opacity: .5;
    cursor: default;
}

#sidebar .pb-share .pb-share__menu {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin: 10px 0 0;
}

#sidebar .pb-share .pb-share__menu[hidden] {
    display: none;
}

#sidebar .pb-share .pb-share__menu a {
    display: grid;
    justify-items: center;
    gap: 6px;
    height: auto;
    padding: 12px 4px;
    border: 1.5px solid var(--pbui-line);
    border-radius: 12px;
    background: #fff;
    color: var(--pbui-ink);
    font: 600 12.5px/1.2 var(--pbui-font);
    text-decoration: none;
    transition: border-color .15s;
}

#sidebar .pb-share .pb-share__menu a .fab,
#sidebar .pb-share .pb-share__menu a .far {
    color: var(--pbui-primary);
    font-size: 20px;
}

#sidebar .pb-share .pb-share__menu a:hover,
#sidebar .pb-share .pb-share__menu a:focus-visible {
    border-color: var(--pbui-primary);
}

#sidebar .pb-pg__grid .item.photo .remove {
    top: 4px;
    right: 4px;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 26px;
    height: 26px;
    padding: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .95);
    color: #b42318;
    font-size: 12px;
    box-shadow: 0 1px 4px rgba(13, 27, 34, .3);
    opacity: 0;
    transform: scale(.9);
    transition: opacity .12s, transform .12s, background .12s, color .12s;
}

#sidebar .pb-pg__grid .item.photo:hover .remove,
#sidebar .pb-pg__grid .item.photo:focus-within .remove,
#sidebar .pb-pg__grid .item.photo .remove:focus-visible {
    opacity: 1;
    transform: none;
}

#sidebar .pb-pg__grid .item.photo .remove:hover {
    background: #b42318;
    color: #fff;
}

#sidebar .pb-pg__grid .item.photo .remove:focus-visible {
    outline: 2px solid var(--pbui-primary);
    outline-offset: 1px;
}

@media (hover: none), (pointer: coarse) {
    #sidebar .pb-pg__grid .item.photo .remove {
        width: 30px;
        height: 30px;
        opacity: 1;
        transform: none;
    }
}

.pb-pman {
    flex: none;
    padding: 10px 16px;
    border-bottom: 1px solid var(--pbui-line);
    background: #fff;
}

.pb-pman[hidden] {
    display: none;
}

.pb-pman__row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.pb-pman .pb-pman__row--sel,
.pb-pman.is-sel .pb-pman__row--idle {
    display: none;
}

.pb-pman.is-sel .pb-pman__row--sel {
    display: flex;
}

.pb-pman__b {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 34px;
    margin: 0;
    padding: 0 12px;
    border: 1.5px solid var(--pbui-line);
    border-radius: 999px;
    background: #fff;
    color: var(--pbui-ink);
    font: 700 12.5px/1 var(--pbui-font);
    white-space: nowrap;
    cursor: pointer;
    transition: border-color .15s, color .15s, background .15s;
}

.pb-pman__b:hover:not(:disabled) {
    border-color: var(--pbui-primary);
    color: var(--pbui-primary);
}

.pb-pman__b:focus-visible {
    outline: 2px solid var(--pbui-primary);
    outline-offset: 2px;
}

.pb-pman__b:disabled {
    opacity: .45;
    cursor: default;
}

.pb-pman__b i {
    display: inline-block;
    min-width: 18px;
    padding: 2px 5px;
    border-radius: 999px;
    background: var(--pbui-soft);
    font: 700 11px/1.2 var(--pbui-font);
    text-align: center;
}

.pb-pman .pb-pman__b--d {
    color: #b42318;
}

.pb-pman .pb-pman__b--d:hover:not(:disabled) {
    border-color: #b42318;
    color: #b42318;
}

.pb-pman .pb-pman__go {
    flex: 1 1 100%;
    justify-content: center;
    height: 40px;
    border-color: #b42318;
    background: #b42318;
    color: #fff;
}

.pb-pman .pb-pman__go:hover:not(:disabled) {
    border-color: #8f1c12;
    background: #8f1c12;
    color: #fff;
}

.pb-pman__n {
    flex: 1 1 auto;
    color: var(--pbui-ink);
    font: 700 13px/1.2 var(--pbui-font);
}

html.pb-phone .pb-pman {
    padding: 4px 0 12px;
    border-bottom: 0;
}

html.pb-phone .pb-pman__b {
    height: 40px;
}

.pb-c-photo.is-selmode .pb-pg__grid .item.photo {
    cursor: pointer;
    opacity: 1;
}

#sidebar .pb-c-photo.is-selmode .pb-pg__grid .item.photo .remove {
    display: none;
}

.pb-c-photo.is-selmode .pb-pg__grid .item.photo::after {
    content: "";
    position: absolute;
    top: 5px;
    left: 5px;
    z-index: 4;
    box-sizing: border-box;
    width: 20px;
    height: 20px;
    border: 1.5px solid #c6cbcd;
    border-radius: 6px;
    background: #fff no-repeat center / 14px 14px;
    pointer-events: none;
}

.pb-c-photo.is-selmode .pb-pg__grid .item.photo.is-sel {
    outline: 2.5px solid var(--p55-hdr-icon, #00838f);
    outline-offset: -2.5px;
}

.pb-c-photo.is-selmode .pb-pg__grid .item.photo.is-sel::after {
    border-color: var(--p55-hdr-icon, #00838f);
    background-color: var(--p55-hdr-icon, #00838f);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14' fill='none' stroke='%23fff' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.8 7.4l2.9 2.9 5.5-6'/%3E%3C/svg%3E");
}

.pb-dlg .pb-btn--d {
    border-color: #b42318;
    background: #b42318;
    color: #fff;
}
