/**
 * Live Notifications to Customer
 *
 * @author    THECON
 * @copyright THECON
 * @license   http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
 */

.th_notification_inner {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    margin: 0 0.5em;
}

.th_notification_wrapper {
    width: 100%;
    height: 100%;
    position: relative;
}

.th_notification_show {
    cursor: pointer;
}

.th_notification_menu_item a {
    text-decoration: none !important;
}

.th_notification_menu_wrapper {
    z-index: 9999;
    position: fixed;
    width: 100%;
    height: 0;
    left: 0;
    top: 0;
}

.th_notification_menu {
    width: 25em;
    max-width: 40rem;
    z-index: 99999;
    position: fixed;
    overflow: auto;
    top: 5em;
    right: 0;
    background: #ffffff;
    box-shadow: 2px 2px 8px 0 rgba(0, 0, 0, .2);
    border: 1px solid rgba(0, 0, 0, .2);
    border-right: 0;
    border-radius: 5px 0 0 5px;
    margin-left: -25em;
    display: none;
}

.th-show {
    animation-name: animate-slide;
    animation-timing-function: cubic-bezier(0.26, 0.53, 0.74, 1.48);
    animation-duration: 0.2s;
    display: block;
}

@keyframes animate-slide {
    0% {
        opacity: 0;
        transform: translate(0, 20px);
    }
    100% {
        opacity: 1;
        transform: translate(0, 0);
    }
}

.th_notification_icon {
    width: 1.5em;
}

.th_notification_icon_main {
    width: 1.8em;
    height: initial;
}

.th_notification_menu_item {
    position: relative;
}

.th_notification {
    display: flex;
    align-items: center;
    position: relative;
    padding: 1em;
}

.th_notification_details p {
   margin: 0;
}

.th_notification_details {
    padding: 0 0.5em 0 0;
}

.th_notification_body {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.th_notification_time_wrapper {
    min-width: 4em;
    display: flex;
    justify-content: center;
    align-items: center;
}

.th_notification_time {
    width: 100%;
    font-weight: 600;
    font-size: 0.9em;
    text-align: center;
    padding: 3px;
    border-radius: 1em;
    background: #000;
    color: #fff;
}

.th_products_count_value {
    border-right: 1px solid #e8e8e8;
    padding-right: 1em;
    margin-right: 1em;
    color: #000;
}

/* Notification count badge - Desktop & Mobile */
.th_notification_count {
    position: absolute;
    top: -5px;          /* slightly higher to not cover bell too much */
    right: -5px;        /* slight offset from right edge */
    width: 20px;        /* fixed width */
    height: 20px;       /* equal height for perfect circle */
    border-radius: 50%;
    background-color: red;  
    display: flex;
    justify-content: center;
    align-items: center;   /* centers number inside circle */
    color: #fff;
    font-size: 0.75em;
    font-weight: bold;
    line-height: 1;
    z-index: 10;
}

/* Mobile adjustments */
@media only screen and (max-width: 479px) {
    .th_notification_count {
        width: 18px;       /* keep original mobile size */
        height: 18px;
        top: -3px;         /* touch bell properly */
        right: -3px;
        display: flex;     
        justify-content: center;
        align-items: center; /* vertically center number */
        padding: 0;
        line-height: 1;
    }

    /* Ensure the number inside is perfectly centered */
    .th_notification_count span {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        height: 100%;
        line-height: 1;
    }
}

.th_notification_count span {
    font-size: 0.79em;
    display: flex;
    justify-content: center;
    align-items: center;
}

.th_notification_pin {
    width: 12px;
}

.th_notification_pin_wrapper {
    position: absolute;
    top: 0;
    right: 5px;
}

.th_notification_menu_header {
    padding: 14px 12px;
    font-size: 18px;
    color: #141414;
    line-height: 22px;
    text-align: center;
    font-weight: 500;
    background-color: #f2f2f2;
    border-bottom: 1px solid #e8e8e8;
    position: relative;
    display: none;
}

.th_notification_menu_header_close {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    font-size: 35px;
    color: #141414;
    width: 25px;
    height: 25px;
}

.th_remove_overflow {
    overflow: scroll;
}

.float-xs-right .th_notification_wrapper {
    margin-top: 0.9375rem;
    margin-left: 2rem;
    text-align: right;
    white-space: nowrap;
    width: auto;
    height: auto;
}

.float-xs-right .th_notification_wrapper .th_notification_count {
    top: -10px;
}

.th_notification_left_img {
    width: 4em;
    padding-right: 0.5em;
}

@media only screen and (min-width : 320px) and (max-width : 479px) {
    .th_notification_menu {
        width: 70%;
        border-radius: 0;
        top: 0;
        height: 100%;
        position: fixed;
    }

    .th_notification_menu_header {
        display: block;
    }

    .th_notification {
        min-height: 4em;
    }

    /* 🔥 Modified positioning for mobile */
    .th_notification_count {
        top: auto;
        right: auto;
        bottom: 0;
        left: 0;
        transform: translate(-30%, 30%); /* keep it touching corner */
        display: block;
    }
}

.th_notification_count {
    display: none !important;
}
