/* Emoji Rating Styles */
._legy_ne_legy .floating-info-box {
    display:none;
}
.single_post_nav_szekelylap .floating-info-box {
    display:none;
}
.timeline_list_container .floating-info-box {
    display:none;
}
.frontpage_column_post_1 .floating-info-box ul li,
.frontpage_column_post_2 .floating-info-box ul li,
.frontpage_column_post_3 .floating-info-box ul li,
.frontpage_column_post_4 .floating-info-box ul li,
.frontpage_column_post_5 .floating-info-box ul li,
.frontpage_column_post_6 .floating-info-box ul li,
.frontpage_column_post_7 .floating-info-box ul li {
    color: var(--color-two)!important;
}
.emoji-rating {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 10px 0px 0px 0px;
    position: relative;
}

.emoji-container {
    text-align: center;
    margin: 0 7px;
    cursor: pointer;
    transition: transform 0.2s ease-in-out;
    position: relative;
    display: flex;
    align-items: center;
    z-index: 100;
    width: auto;
}
.random-posts-list .emoji i, .copy-icon i, .share-icon i, .view-icon i, .comment-icon i, .add_post_icon i{
    color: var(--color-two)!important;
}
.random-posts-list .emoji-vote-count{
    color: var(--color-two)!important;
}

/* Increase z-index of the comment icon's container when the comment box is open */
.comment-icon.active {
    z-index: 200; /* Higher than other .emoji-container elements */
}

.emoji i, .copy-icon i, .share-icon i, .view-icon i, .comment-icon i, .add_post_icon i {
    font-size: 0.9rem;
    color: var(--color-one);
    font-weight: 400;
    transition: transform 0.2s ease-in-out, color 0.2s ease-in-out;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
}

/* Marine blue icons on single post pages */
body.single-post .emoji i,
body.single-post .copy-icon i,
body.single-post .share-icon i,
body.single-post .view-icon i,
body.single-post .comment-icon i,
body.single-post .add_post_icon i {
    color: #013a63; /* Marine blue for icons on single post pages */
}

.emoji, .copy-icon, .share-icon, .view-icon, .comment-icon, .add_post_icon {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 1.5rem;
}

.emoji-vote-count {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.6rem;
    color: var(--color-one);
    margin: 0;
    padding: 0;
    width: 30px;
    text-align: center;
    white-space: nowrap;
}

.emoji-container:hover i,
.copy-icon:hover i,
.share-icon:hover i,
.view-icon:hover i,
.add_post_icon:hover i,
.comment-icon:hover i {
    transform: scale(1.2);
    color: #111111;
}

.emoji-container:active i,
.copy-icon:active i,
.share-icon:active i,
.view-icon:active i,
.add_post_icon:active i,
.comment-icon:active i {
    transform: scale(0.9);
    color: #79e5739c;
}

.emoji-container.add_post_icon a {
    margin: 0;
    padding: 0;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.add_post_link a {
    margin: 0;
    padding: 0;
    line-height: 1;
}

.comment-box {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #fff;
    border: 1px solid #ddd;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    margin-top: 5px;
    display: none !important;
    width: 230px; /* Increased from 200px to accommodate icons */
    z-index: 1000;
    padding: 5px;
}

.comment-box.show {
    display: block !important;
}

.comment-icon {
    position: relative;
}

.comment-box-controls {
    position: absolute;
    top: 5px;
    right: 0px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px; /* Space between icons */
    z-index: 1001; /* Above the textarea */
}

.close-popup-emoji {
    font-size: 16px;
    font-weight: bold;
    color: #666;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    line-height: 1;
    margin-top: -5px;
}

.close-popup-emoji:hover {
    color: #000;
    background-color: rgba(255, 255, 255, 1);
}

/* Emoji toggle icon */
.emoji-toggle {
    cursor: pointer;
    font-size: 1px;
    color: #666;
    
}

.emoji-toggle:hover {
    color: #000;
}

.emoji-toggle:active {
    transform: scale(0.9);
}

/* Emoji picker */
.emoji-picker {
    position: absolute;
    bottom: 40px;
    right: 0;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    display: none !important;
    z-index: 2000;
    max-width: 200px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.emoji-picker.show {
    display: grid !important;
}

.emoji-option {
    font-size: 20px;
    cursor: pointer;
    display: inline-block;
    padding: 2px;
    text-align: center;
}

.emoji-option:hover {
    background-color: #f0f0f0;
    border-radius: 3px;
}

.comment-submit {
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
    padding: 5px 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: auto;
    background-color: transparent;
}



.comment-submit i {
    font-size: 16px;
}

.comment-textarea {
    width: calc(100% - 30px); /* Adjusted to leave space for the icons on the right */
    padding: 5px;
    resize: none;
    border: 1px solid #ddd;
    border-radius: 5px;
    height: 60px;
    box-sizing: border-box;
    float: left;
}

/* QR code popup */
.qr-code-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #fff;
    border: 1px solid #ddd;
    padding: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    display: none;
    z-index: 2000;
    width: 160px;
    min-width: 160px;
    box-sizing: border-box;
}

.qr-code-popup img {
    display: block;
    max-width: 150px;
    max-height: 150px;
    width: 100%;
    height: auto;
    border-radius: 3px;
}

/* Adjust padding for popups with close buttons */
.qr-code-popup {
    padding-top: 30px;
}

/* Floating Box for Stats and Comments */
.floating-info-box {
    position: relative;
    width: auto;
    max-width: 600px;
    margin: 10px auto 0;
    background: transparent;
    color: white;
    border-radius: 0;
    padding: 0;
    font-size: 0.7rem;
    box-shadow: none;
    backdrop-filter: none;
    z-index: 99;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
}

/* Comments container remains scrollable */
.floating-comments {
    max-height: 150px;
    overflow-y: auto;
    width: 100%;
}

/* Floating comment list with alternating chat bubble style */
[id^="floating-comment-list-"] {
    
    list-style: none;
}

/* Style for individual comments as chat bubbles */
.comment-item {
    max-width: 70%; /* Limit width to create bubble effect */
    padding: 8px 12px; /* Padding inside the bubble */
    margin: 2px 0;
    border-radius: 12px; /* Rounded corners for bubble effect */
    color: #013A63;
    opacity: 0.9;
    transition: opacity 0.3s ease-in-out;
    position: relative;
}

/* Alternate left and right alignment */
.comment-item:nth-child(odd) {
    background: rgb(0 0 0 / 5%); /* Slightly darker background for odd comments */
    align-self: flex-start; /* Align to the left */
    margin-right: 20%; /* Push away from the right edge */
}

.comment-item:nth-child(even) {
    background: rgb(0 0 0 / 2%); /* Original background for even comments */
    align-self: flex-end; /* Align to the right */
    margin-left: 20%; /* Push away from the left edge */
}

/* Add a small triangle (speech bubble tail) */
.comment-item:nth-child(odd):before {
    content: '';
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    border-right: 8px solid rgb(0 0 0 / 5%);
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.comment-item:nth-child(even):before {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    border-left: 8px solid rgb(0 0 0 / 2%);
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

/* Hover effect */
.comment-item:hover {
    opacity: 1;
}

/* Style View & Like Counts as Comments */
.floating-comment-list .static-info {
    font-size: 0.75rem;
    font-style: italic;
    opacity: 0.8;
    color: #ddd;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Style for static info (views & likes as comments) */
.static-info {
    font-size: 0.75rem;
    font-style: italic;
    opacity: 0.8;
    color: #aaa;
}

/* Media Queries for Responsive Design */
@media (max-width: 768px) {
    .qr-code-popup {
        width: 110px;
        min-width: 110px;
        padding: 5px;
    }
    .qr-code-popup img {
        max-width: 100px;
        max-height: 100px;
    }

    .comment-box {
        width: 230px; /* Increased for mobile as well */
        margin-top: 8px;
    }

    .comment-textarea {
        font-size: 0.8rem;
    }

    .emoji-picker {
        max-width: 150px;
    }
}