/* Post page (author card, emoji reactions) and the author page */

.sq-author-card {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 36px 0 8px;
    padding: 20px 22px;
    border: 1px solid #e5e5ea;
    border-radius: 18px;
    background: #fff;
}

.sq-author-card .sq-ac-photo {
    flex-shrink: 0;
}

.sq-author-card .sq-ac-photo img {
    display: block;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    background: #e8e8ed;
}

.sq-ac-body {
    flex: 1;
    min-width: 0;
}

.sq-ac-label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: #6e6e73;
    margin-bottom: 2px;
}

.sq-ac-name {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    color: #1d1d1f;
    text-decoration: none;
}

.sq-ac-name:hover {
    color: #0066cc;
}

.sq-ac-job {
    font-size: 14px;
    color: #6e6e73;
    margin-top: 2px;
}

.sq-ac-time {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 16px;
    margin-top: 8px;
    font-size: 13px;
    color: #6e6e73;
}

.sq-ac-more {
    flex-shrink: 0;
    padding: 9px 16px;
    border-radius: 980px;
    background: #f5f5f7;
    color: #0066cc;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    text-decoration: none;
}

.sq-ac-more:hover {
    background: #0066cc;
    color: #fff;
}

/* tags right under the card: smaller gap than the theme's mt-5 */
.sq-author-card + .post-tags {
    margin-top: 20px !important;
}

@media (max-width: 575px) {
    .sq-author-card {
        flex-wrap: wrap;
        padding: 16px;
        gap: 12px 14px;
    }

    .sq-author-card .sq-ac-photo img {
        width: 60px;
        height: 60px;
    }

    .sq-ac-more {
        width: 100%;
        text-align: center;
    }
}

/* Author page */

.sq-author-page {
    padding: 40px 0 56px;
}

.sq-ap {
    max-width: 860px;
    margin: 0 auto;
}

.sq-ap-head {
    display: flex;
    align-items: center;
    gap: 32px;
}

.sq-ap-photo {
    flex-shrink: 0;
    width: 168px;
    height: 168px;
    border-radius: 50%;
    object-fit: cover;
    background: #e8e8ed;
}

.sq-ap-name {
    margin: 0 0 10px;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.15;
    color: #1d1d1f;
}

.sq-ap-line {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    font-size: 14px;
    color: #6e6e73;
}

.sq-ap-line svg {
    flex-shrink: 0;
    opacity: .8;
}

.sq-ap-job {
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.sq-ap-line a {
    color: inherit;
}

.sq-ap-social {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 14px 0 0;
    padding: 0;
    list-style: none;
}

.sq-ap-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid #e5e5ea;
    border-radius: 50%;
    background: #fff;
    color: #1d1d1f;
    font-size: 15px;
    text-decoration: none;
}

.sq-ap-social a:hover {
    background: #0066cc;
    color: #fff;
}

.sq-ap-bio {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid #d2d2d7;
    font-size: 18px;
    line-height: 1.65;
    color: #1d1d1f;
}

.sq-ap-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 44px 0 4px;
    padding-bottom: 12px;
    border-bottom: 2px solid #1d1d1f;
}

.sq-ap-section-head h2 {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: #1d1d1f;
}

.sq-ap-section-head .count {
    font-size: 14px;
    color: #6e6e73;
}

.sq-ap-item {
    border-bottom: 1px solid #e5e5ea;
}

.sq-ap-link {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 18px 0;
    text-decoration: none;
}

.sq-ap-text {
    flex: 1;
    min-width: 0;
}

.sq-ap-meta {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #6e6e73;
    margin-bottom: 6px;
}

.sq-ap-title {
    margin: 0;
    font-size: 19px;
    font-weight: 600;
    line-height: 1.35;
    color: #1d1d1f;
}

.sq-ap-link:hover .sq-ap-title {
    color: #0066cc;
}

.sq-ap-thumb {
    flex-shrink: 0;
    width: 150px;
    height: 100px;
    border-radius: 12px;
    object-fit: cover;
    background: #e8e8ed;
}

.sq-ap-empty {
    padding: 24px 0;
    color: #6e6e73;
}

.sq-ap-more {
    display: block;
    width: max-content;
    margin: 28px auto 0;
    padding: 12px 28px;
    border-radius: 980px;
    background: #1d1d1f;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
}

.sq-ap-more:hover {
    background: #0066cc;
    color: #fff;
}

.sq-ap-more.loading {
    opacity: .6;
    pointer-events: none;
}

@media (max-width: 767px) {
    .sq-author-page {
        padding: 24px 0 40px;
    }

    .sq-ap-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
    }

    .sq-ap-photo {
        width: 128px;
        height: 128px;
    }

    .sq-ap-name {
        font-size: 28px;
    }

    .sq-ap-bio {
        font-size: 16px;
    }

    .sq-ap-title {
        font-size: 16px;
    }

    .sq-ap-link {
        gap: 14px;
        padding: 14px 0;
    }

    .sq-ap-thumb {
        width: 96px;
        height: 72px;
        border-radius: 10px;
    }
}

/* Dark mode */

.dark-mode .sq-author-card {
    border-color: #2c2c2e;
    background: #1c1c1e;
}

.dark-mode .sq-ac-name,
.dark-mode .sq-ap-name,
.dark-mode .sq-ap-bio,
.dark-mode .sq-ap-title,
.dark-mode .sq-ap-section-head h2 {
    color: #f5f5f7;
}

.dark-mode .sq-ac-label,
.dark-mode .sq-ac-job,
.dark-mode .sq-ac-time,
.dark-mode .sq-ap-line,
.dark-mode .sq-ap-meta,
.dark-mode .sq-ap-section-head .count,
.dark-mode .sq-ap-empty {
    color: #a1a1a6;
}

.dark-mode .sq-ac-more,
.dark-mode .sq-ap-social a {
    border-color: #2c2c2e;
    background: #2c2c2e;
    color: #f5f5f7;
}

.dark-mode .sq-ac-name:hover,
.dark-mode .sq-ap-link:hover .sq-ap-title {
    color: #2997ff;
}

.dark-mode .sq-ap-bio {
    border-top-color: #424245;
}

.dark-mode .sq-ap-section-head {
    border-bottom-color: #f5f5f7;
}

.dark-mode .sq-ap-item {
    border-bottom-color: #2c2c2e;
}

.dark-mode .sq-ap-more {
    background: #f5f5f7;
    color: #1d1d1f;
}

.dark-mode .sq-author-card .sq-ac-photo img,
.dark-mode .sq-ap-photo,
.dark-mode .sq-ap-thumb {
    background: #2c2c2e;
}

/* Emoji reactions: all 7 in one row, emoji and vote count only (names are in the tooltip and aria-label) */

.emoji-reactions-container {
    margin-top: 28px;
    margin-bottom: 8px !important;
}

.emoji-reactions-container .title-reactions {
    margin-bottom: 16px;
}

.emoji-reactions {
    flex-wrap: nowrap !important;
    justify-content: space-between !important;
    gap: 8px !important;
}

.emoji-reactions .reaction-container {
    flex: 1 1 0;
    min-width: 0;
}

.emoji-reactions .reaction {
    width: 100% !important;
    padding: 12px 2px 10px !important;
    border-radius: 14px !important;
}

.emoji-reactions .reaction.selected {
    border-color: #0066cc !important;
    box-shadow: 0 0 0 1px #0066cc !important;
    background-color: rgba(0, 102, 204, .06) !important;
}

.emoji-reactions .emoji {
    width: 52px !important;
    height: 52px !important;
}

.emoji-reactions .sq-emoji {
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Segoe UI Symbol", sans-serif;
    font-size: 42px;
    line-height: 1;
    transition: transform .15s;
}

.emoji-reactions .reaction:not(.disabled):hover .sq-emoji {
    transform: scale(1.12);
}

.emoji-reactions .text {
    display: none !important;
}

.emoji-reactions .reaction .vote {
    position: static !important;
    min-width: 0 !important;
    height: auto !important;
    margin-top: 6px;
    padding: 0;
    border-radius: 0 !important;
    background: transparent !important;
    color: #6e6e73 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    opacity: 1 !important;
}

.emoji-reactions .reaction.selected .vote {
    color: #0066cc !important;
}

.dark-mode .emoji-reactions .reaction .vote {
    color: #a1a1a6 !important;
}

.dark-mode .emoji-reactions .reaction.selected {
    border-color: #2997ff !important;
    box-shadow: 0 0 0 1px #2997ff !important;
    background-color: rgba(41, 151, 255, .1) !important;
}

.dark-mode .emoji-reactions .reaction.selected .vote {
    color: #2997ff !important;
}

@media (max-width: 575px) {
    .emoji-reactions {
        gap: 4px !important;
    }

    .emoji-reactions .reaction {
        padding: 9px 0 7px !important;
        border-radius: 10px !important;
    }

    .emoji-reactions .emoji {
        width: 34px !important;
        height: 34px !important;
    }

    .emoji-reactions .sq-emoji {
        font-size: 28px;
    }

    .emoji-reactions .reaction .vote {
        margin-top: 4px;
        font-size: 12px !important;
    }
}

/* ---------- Post page on computers: wide article column, 300px sidebar and larger text (like kursiv.media) ---------- */
@media (min-width: 992px) {
    #postDetailsPage > .container-xl > .row > .col-lg-8 { flex: 1 1 0; width: auto; min-width: 0; }
    #postDetailsPage > .container-xl > .row > .col-lg-4 { flex: 0 0 348px; width: 348px; padding-left: 36px; }
    #postDetailsPage .post-content .post-summary { font-size: 19px; line-height: 1.5; margin-bottom: 18px; }
    /* the theme forces 15px on every element of the text (!important), so the sizes here are !important too */
    #postDetailsPage .post-content .post-text, #postDetailsPage .post-content .post-text * { font-size: 18px !important; line-height: 1.6 !important; }
    #postDetailsPage .post-content .post-text p { margin-bottom: 1.1em; }
    #postDetailsPage .post-content .post-text h2, #postDetailsPage .post-content .post-text h2 * { font-size: 26px !important; line-height: 1.3 !important; }
    #postDetailsPage .post-content .post-text h3, #postDetailsPage .post-content .post-text h3 * { font-size: 22px !important; line-height: 1.35 !important; }
    #postDetailsPage .post-content .post-text h2, #postDetailsPage .post-content .post-text h3 { margin: 1.3em 0 .5em; }
    #postDetailsPage .post-content .post-text li { margin-bottom: .4em; }
    #postDetailsPage .post-content .post-text blockquote, #postDetailsPage .post-content .post-text blockquote * { font-size: 20px !important; line-height: 1.5 !important; }
    #postDetailsPage .post-content .post-text figcaption, #postDetailsPage .post-content .post-text figcaption *, #postDetailsPage .post-content .post-text .image-description { font-size: 14px !important; line-height: 1.4 !important; }
}

/* ---------- Post page on big screens: the page uses the whole width (like kursiv.media) ---------- */
@media (min-width: 1400px) {
    body:has(#postDetailsPage) .container-xl { max-width: 1760px; padding-left: 40px; padding-right: 40px; }
}

/* ---------- Post page right column (like kursiv.media): "Topical" — latest news cards ---------- */
.sq-aside.col-sidebar { padding-left: 0; padding-right: 0; }
.sq-actual { margin-bottom: 44px; }
.sq-actual-head { text-align: center; margin-bottom: 24px; }
.sq-actual-head span { display: inline-block; background: #1d1d1f; color: #ffcc00; text-transform: uppercase; font-size: 17px; line-height: 1.45; letter-spacing: .03em; padding: 3px 22px; transform: skewX(-12deg); }
.sq-actual-item { margin-bottom: 38px; }
.sq-actual-img { display: block; margin-bottom: 10px; overflow: hidden; background: #eee; }
.sq-actual-img img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; transition: transform .4s ease; }
.sq-actual-item:hover .sq-actual-img img { transform: scale(1.03); }
.sq-actual-date { display: block; font-size: 12px; line-height: 1.4; color: #919191; margin-bottom: 5px; }
.sq-actual-title { font-size: 16px; line-height: 1.5; font-weight: 700; margin: 0; }
.sq-actual-title a { color: #333; }
.sq-actual-title a:hover { color: var(--vr-theme-color); }
.dark-mode .sq-actual-head span { background: #ffcc00; color: #111; }
.dark-mode .sq-actual-img { background: #222; }
.dark-mode .sq-actual-title a { color: #ececec; }
@media (max-width: 991px) {
    .sq-aside { margin-top: 32px; }
    .sq-actual { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; }
    .sq-actual-head { grid-column: 1 / -1; }
}
@media (max-width: 575px) {
    .sq-actual { grid-template-columns: minmax(0, 1fr); }
}
