/* Navbar "What's new" panel. Inherits the navbar's dark dropdown theme. */

#whatsNewNav.has-unread .whats-new-label {
    position: relative;
    padding-right: 0.7rem;
}

#whatsNewNav.has-unread .whats-new-label::after {
    content: "";
    position: absolute;
    top: 0.05rem;
    right: 0;
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    background: #f59e0b;
}

.whats-new-menu {
    width: 420px;
    max-width: calc(100vw - 1.5rem);
    padding: 0;
    overflow: hidden;
    text-transform: none;
    letter-spacing: normal;
}

/* Segmented control rather than .nav-tabs, which the console styles as Insights tabs. */
.whats-new-tabs {
    display: flex;
    gap: 0.25rem;
    margin: 0.75rem 0.75rem 0.5rem;
    padding: 0.2rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
}

.whats-new-tab {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem 0.75rem;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: none;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.whats-new-tab:hover {
    color: rgba(255, 255, 255, 0.9);
}

.whats-new-tab:focus-visible {
    outline: 2px solid #8b5cf6;
    outline-offset: 1px;
}

.whats-new-tab.active {
    background: rgba(255, 255, 255, 0.13);
    color: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

.whats-new-count {
    display: inline-block;
    margin-left: 0.4rem;
    padding: 0 0.4rem;
    border-radius: 999px;
    background: #f59e0b;
    color: #0b2e4a;
    font-size: 0.68rem;
    line-height: 1.4;
}

.whats-new-list {
    list-style: none;
    margin: 0;
    padding: 0 0 0.35rem;
    max-height: min(65vh, 30rem);
    overflow-y: auto;
}

.whats-new-list > li + li .whats-new-item::before {
    content: "";
    position: absolute;
    top: 0;
    left: 1rem;
    right: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.whats-new-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.7rem 1rem;
    color: rgba(255, 255, 255, 0.82);
    text-decoration: none;
    text-transform: none;
}

.whats-new-item:hover,
.whats-new-item:focus-visible {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

.whats-new-media {
    position: relative;
    flex: 0 0 auto;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 10px;
}

.whats-new-item.unread .whats-new-media::after {
    content: "";
    position: absolute;
    top: -0.2rem;
    right: -0.2rem;
    width: 0.6rem;
    height: 0.6rem;
    border: 2px solid var(--bs-dropdown-bg, #212529);
    border-radius: 50%;
    background: #f59e0b;
}

.whats-new-day {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(139, 92, 246, 0.16);
    color: #ddd6fe;
    line-height: 1;
}

.whats-new-day-num {
    font-size: 1.15rem;
    font-weight: 700;
}

.whats-new-day-month {
    margin-top: 0.2rem;
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.8;
}

.whats-new-thumb {
    background: rgba(255, 255, 255, 0.06);
}

.whats-new-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    object-fit: cover;
}

.whats-new-thumb.is-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.4);
    font-size: 1.2rem;
}

.whats-new-body {
    min-width: 0;
}

.whats-new-title {
    display: -webkit-box;
    overflow: hidden;
    font-size: 0.86rem;
    line-height: 1.4;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.whats-new-item.unread .whats-new-title {
    color: #fff;
    font-weight: 600;
}

.whats-new-date {
    margin-top: 0.2rem;
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.72rem;
}

.whats-new-empty {
    padding: 1rem;
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.85rem;
}

.whats-new-footer {
    display: flex;
    justify-content: flex-end;
    padding: 0.55rem 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.8rem;
}

.whats-new-footer a {
    color: #a5b4fc;
    text-decoration: none;
}

.whats-new-footer a:hover {
    color: #c7d2fe;
}
