/* Modern Offcanvas Panels */

/* Offcanvas Header */
.offcanvas .offcanvas-header {
    background: linear-gradient(135deg, #8D3FF2 0%, #7C3AED 100%);
    padding: 24px;
    border-bottom: none;
}

.offcanvas .offcanvas-header .header-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.offcanvas .offcanvas-header .header-title h5 {
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    padding: 0;
}

.offcanvas .offcanvas-header .header-title i {
    color: #ffffff !important;
    font-size: 24px;
}

.offcanvas .offcanvas-header .text-reset {
    cursor: pointer;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 8px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.offcanvas .offcanvas-header .text-reset:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.offcanvas .offcanvas-header .text-reset img {
    filter: brightness(0) invert(1);
    width: 20px;
    height: 20px;
}

/* Offcanvas Body */
.offcanvas-body {
    padding: 20px;
    background: #f9fafb;
}

/* Announcements Cards */
.offcanvas-body .announcements {
    background: #ffffff;
    border-radius: 16px;
    padding: 0;
    margin-bottom: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    border: 2px solid #f3f4f6;
    transition: all 0.3s ease;
    overflow: visible;
}

.offcanvas-body .announcements:hover {
    border-color: #e9d5ff;
    box-shadow: 0 4px 16px rgba(141, 63, 242, 0.12);
    transform: translateY(-2px);
}

.offcanvas-body .announcements .announcements_content {
    padding: 20px;
    min-height: 80px;
}

.offcanvas-body .announcements_content .announcement_title {
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 8px;
    line-height: 1.4;
}

.offcanvas-body .announcements_content .announcement_desc {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.offcanvas-body .announcements_content p {
    margin-bottom: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.offcanvasAnnouncements .offcanvas-body img {
    width: 100%;
    margin-top: 16px;
    border-radius: 12px;
    object-fit: cover;
}

/* Announcement Actions */
.offcanvas-body .announcement_actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
    border-top: 2px solid #f3f4f6;
    border-radius: 0 0 16px 16px;
}

.offcanvas-body .announcement_actions .date {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #6b7280;
    font-weight: 600;
}

.offcanvas-body .announcement_actions .date svg {
    width: 16px;
    height: 16px;
}

.offcanvas-body .announcement_actions .mark_as_read {
    cursor: pointer;
}

.offcanvas-body .announcement_actions .btnMarkRead {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.offcanvas-body .announcement_actions .btnMarkRead:hover {
    background: rgba(141, 63, 242, 0.1);
    transform: scale(1.1);
}

.offcanvas-body .announcement_actions .btnMarkRead svg {
    width: 20px;
    height: 20px;
}

/* Announcement Link Button */
.announcements .announcements_content a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #8D3FF2 0%, #7C3AED 100%);
    color: #ffffff !important;
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    margin-top: 12px;
}

.announcements .announcements_content a:hover {
    background: transparent;
    color: #8D3FF2 !important;
    border-color: #8D3FF2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(141, 63, 242, 0.2);
}

/* View All Button */
.offcanvas-body .darkBtn {
    background: linear-gradient(135deg, #8D3FF2 0%, #7C3AED 100%);
    color: #ffffff;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border: 2px solid #8D3FF2;
    transition: all 0.3s ease;
    display: inline-block;
    margin-top: 16px;
}

.offcanvas-body .darkBtn:hover {
    background: linear-gradient(135deg, #7C3AED 0%, #6D28D9 100%);
    color: #ffffff;
    border-color: #6D28D9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(141, 63, 242, 0.3);
}

.offcanvas-body .darkBtn:active {
    transform: translateY(0);
}

/* UGC Italia Badge */
#announcements .offcanvas-body .header-title {
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
    border: 2px solid #e9d5ff;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

#announcements .offcanvas-body .header-title h5 {
    font-size: 18px;
    font-weight: 700;
    color: #8D3FF2;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 30px;
    text-align: center;
    animation: fadeIn 0.5s ease-out;
}

.empty-state-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    position: relative;
    animation: pulse 2s ease-in-out infinite;
}

.empty-state-icon::before {
    content: '';
    position: absolute;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, rgba(141, 63, 242, 0.1) 0%, rgba(124, 58, 237, 0.1) 100%);
    border-radius: 50%;
    z-index: -1;
}

.empty-state-icon i {
    font-size: 48px;
    color: #8D3FF2;
}

.empty-state-icon.announcements-empty {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
}

.empty-state-icon.announcements-empty::before {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.1) 0%, rgba(245, 158, 11, 0.1) 100%);
}

.empty-state-icon.announcements-empty i {
    color: #f59e0b;
}

.empty-state-title {
    font-size: 22px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 12px;
}

.empty-state-text {
    font-size: 15px;
    color: #6b7280;
    line-height: 1.6;
    max-width: 320px;
    margin: 0;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Scrollbar */
.offcanvas-body::-webkit-scrollbar {
    width: 8px;
}

.offcanvas-body::-webkit-scrollbar-track {
    background: #f3f4f6;
    border-radius: 10px;
}

.offcanvas-body::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}

.offcanvas-body::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

/* Responsive */
@media (max-width: 576px) {
    .offcanvas .offcanvas-header {
        padding: 20px 16px;
    }

    .offcanvas .offcanvas-header .header-title h5 {
        font-size: 20px;
    }

    .offcanvas-body {
        padding: 16px;
    }

    .offcanvas-body .announcements .announcements_content {
        padding: 16px;
    }

    .offcanvas-body .announcement_actions {
        padding: 12px 16px;
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .offcanvas-body .announcements_content .announcement_title {
        font-size: 16px;
    }
}
