/* ========== NOTIFICATIONS PAGE STYLES ========== */
/* Page-specific styles - Dark Industrial Theme */

/* ========== PAGE CONTAINER ========== */
.notifications-page {
    padding: 1rem 1.25rem;
    max-width: 1280px;
    margin: 0 auto;
}

/* ========== PAGE HEADER ========== */
.notifications-page .page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

.notifications-page .page-heading {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 0;
}

.notifications-page .page-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin: 0;
    font-size: 1.45rem;
    font-weight: 500;
    color: #00bcd4;
    letter-spacing: 0;
}

.notifications-page .page-title i {
    color: #00bcd4;
}

.notifications-page .total-count {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 400;
}

.notifications-page .page-subtitle {
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.8rem;
}

/* ========== HEADER ACTIONS ========== */
.notifications-page .header-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.settings-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.7);
    min-width: 36px;
    min-height: 34px;
    padding: 0.4rem 0.55rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.settings-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
    color: rgba(255, 255, 255, 0.9);
}

.mark-all-read-btn {
    background: transparent;
    border: 1px solid #4caf50;
    color: #4caf50;
    min-height: 34px;
    padding: 0.4rem 0.7rem;
}

.mark-all-read-btn:hover {
    background: rgba(76, 175, 80, 0.1);
}

.bulk-delete-btn {
    background: transparent;
    border: 1px solid #f44336;
    color: #f44336;
    min-height: 34px;
    padding: 0.4rem 0.7rem;
}

.bulk-delete-btn:hover {
    background: rgba(244, 67, 54, 0.1);
}

/* ========== FILTERS SECTION ========== */
.filters-section {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
    padding: 0.75rem 0.9rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(0, 188, 212, 0.1);
    border-radius: 6px;
}

.filter-pills {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.read-filters {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    padding-left: 0.75rem;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.selection-tools {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin-left: auto;
    flex-wrap: wrap;
}

.filter-pill {
    padding: 0.35rem 0.65rem;
    border: 1px solid rgba(0, 188, 212, 0.2);
    background: transparent;
    border-radius: 4px;
    font-size: 0.74rem;
    min-height: 30px;
    transition: all 0.2s;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0;
}

.filter-pill.active {
    background: rgba(0, 188, 212, 0.15);
    border-color: #00bcd4;
    color: #00bcd4;
}

.filter-pill:hover:not(.active) {
    background: rgba(0, 188, 212, 0.05);
    border-color: rgba(0, 188, 212, 0.3);
}

.select-all-btn {
    padding: 0.35rem 0.65rem;
    min-height: 30px;
    border: 1px solid rgba(0, 188, 212, 0.35);
    background: rgba(0, 188, 212, 0.08);
    color: #00bcd4;
    border-radius: 4px;
    font-size: 0.75rem;
}

.select-all-btn:hover {
    background: rgba(0, 188, 212, 0.15);
    border-color: rgba(0, 188, 212, 0.6);
}

.selected-count {
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.78rem;
    white-space: nowrap;
}

/* ========== NOTIFICATIONS CONTAINER ========== */
.notifications-container {
    max-height: calc(100vh - 235px);
    min-height: 320px;
    overflow-y: auto;
    border: 1px solid rgba(0, 188, 212, 0.1);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.02);
}

/* ========== LOADING SKELETON ========== */
.loading-skeleton {
    padding: 1rem;
}

.notification-skeleton {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem 0.9rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    animation: pulse 1.5s ease-in-out infinite;
}

.skeleton-icon {
    width: 32px;
    height: 32px;
    background: rgba(0, 188, 212, 0.1);
    border-radius: 50%;
}

.skeleton-content {
    flex: 1;
}

.skeleton-title {
    height: 20px;
    background: rgba(0, 188, 212, 0.1);
    margin-bottom: 0.5rem;
    width: 60%;
    border-radius: 4px;
}

.skeleton-text {
    height: 16px;
    background: rgba(255, 255, 255, 0.05);
    margin-bottom: 0.5rem;
    width: 80%;
    border-radius: 4px;
}

.skeleton-time {
    height: 14px;
    background: rgba(255, 255, 255, 0.05);
    width: 30%;
    border-radius: 4px;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ========== NOTIFICATION ITEM ========== */
.notification-item {
    display: grid;
    grid-template-columns: 24px 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    min-height: 58px;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.notification-item:hover {
    background: rgba(0, 188, 212, 0.05);
}

.notification-item.unread {
    background: rgba(0, 188, 212, 0.08);
    border-left: 2px solid #00bcd4;
}

.notification-item.selected {
    background: rgba(0, 188, 212, 0.12);
}

/* ========== NOTIFICATION CHECKBOX ========== */
.notification-checkbox {
    align-self: center;
    margin: 0;
}

/* ========== NOTIFICATION ICON ========== */
.notification-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 0.9rem;
}

.notification-item.type-error .notification-icon {
    background: rgba(244, 67, 54, 0.15);
    color: #f44336;
}

.notification-item.type-success .notification-icon {
    background: rgba(76, 175, 80, 0.15);
    color: #4caf50;
}

.notification-item.type-warning .notification-icon {
    background: rgba(255, 152, 0, 0.15);
    color: #ff9800;
}

.notification-item.type-info .notification-icon {
    background: rgba(0, 188, 212, 0.15);
    color: #00bcd4;
}

/* ========== NOTIFICATION CONTENT ========== */
.notifications-page .notification-content {
    flex: 1;
    min-width: 0;
    padding: 0 !important;
}

.notifications-page .notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.2rem;
    gap: 0.75rem;
    min-width: 0;
}

.notifications-page .notification-title {
    display: block !important;
    margin: 0;
    font-size: 0.92rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.94) !important;
    line-height: 1.25;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.notifications-page .notification-time {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.4);
    white-space: nowrap;
    flex-shrink: 0;
}

.notifications-page .notification-message {
    margin: 0 !important;
    color: rgba(255, 255, 255, 0.72) !important;
    line-height: 1.35;
    font-size: 0.8rem;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: anywhere;
}

/* ========== NOTIFICATION ACTIONS ========== */
.notifications-page .notification-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.35rem;
    margin-top: 0 !important;
    opacity: 1;
    white-space: nowrap;
}

.notifications-page .notification-actions .e-btn {
    padding: 0.25rem 0.45rem;
    font-size: 0.7rem;
    min-height: 28px;
    border-radius: 4px;
}

.notifications-page .notification-actions .e-btn i {
    margin-right: 0.2rem;
}

.view-btn {
    background: transparent !important;
    border: 1px solid #00bcd4 !important;
    color: #00bcd4 !important;
}

.view-btn:hover {
    background: rgba(0, 188, 212, 0.1) !important;
}

/* ========== UNREAD INDICATOR ========== */
.unread-indicator {
    position: absolute;
    right: 0.65rem;
    top: 0.65rem;
    width: 6px;
    height: 6px;
    background: #00bcd4;
    border-radius: 50%;
}

/* ========== LOADING MORE ========== */
.loading-more {
    padding: 0.85rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(0, 188, 212, 0.2);
    border-top: 2px solid #00bcd4;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========== END MESSAGE ========== */
.end-message {
    padding: 0.85rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
}

.end-message i {
    color: #4caf50;
    margin-right: 0.5rem;
}

/* ========== EMPTY STATE ========== */
.notifications-page .empty-state {
    padding: 2.5rem 1.25rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
}

.notifications-page .empty-state i {
    font-size: 3rem;
    color: rgba(0, 188, 212, 0.3);
    margin-bottom: 1rem;
    display: block;
}

.notifications-page .empty-state h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 300;
}

.notifications-page .empty-state p {
    margin: 0;
    font-size: 0.875rem;
}

/* ========== MODAL STYLES ========== */
.notification-modal .modal-notification {
    padding: 1.5rem;
}

.notifications-page .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(0, 188, 212, 0.1);
}

.notification-type {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.notification-type.error {
    background: rgba(244, 67, 54, 0.15);
    color: #f44336;
}

.notification-type.success {
    background: rgba(76, 175, 80, 0.15);
    color: #4caf50;
}

.notification-type.warning {
    background: rgba(255, 152, 0, 0.15);
    color: #ff9800;
}

.notification-type.info {
    background: rgba(0, 188, 212, 0.15);
    color: #00bcd4;
}

.notification-date {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.5);
}

.modal-content h3 {
    margin: 0 0 1rem 0;
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
}

.message-body {
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1.5rem;
    max-height: 300px;
    overflow-y: auto;
}

.notifications-page .modal-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(0, 188, 212, 0.1);
}

.close-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.7);
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* ========== RESPONSIVE - Mobile ========== */
@media (max-width: 768px) {
    .notifications-page {
        padding: 0.75rem;
    }

    .notifications-page .page-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .notifications-page .header-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .notifications-page .header-actions .e-btn {
        flex: 0 1 auto;
    }

    .filter-pills,
    .read-filters {
        justify-content: flex-start;
    }

    .read-filters {
        padding-left: 0;
        border-left: 0;
    }

    .selection-tools {
        width: 100%;
        margin-left: 0;
    }

    .notification-item {
        grid-template-columns: 24px 32px minmax(0, 1fr);
        gap: 0.6rem;
        padding: 0.75rem;
        min-height: 64px;
    }

    .notification-header {
        gap: 0.5rem;
    }

    .notification-time {
        display: none;
    }

    .notification-actions {
        grid-column: 3 / 4;
        justify-content: flex-start;
        flex-wrap: wrap;
        white-space: normal;
    }

    .notifications-page .modal-actions {
        flex-direction: column;
    }

    .notifications-page :is(.filter-pill, .select-all-btn, .settings-btn, .mark-all-read-btn, .bulk-delete-btn) {
        min-height: 44px;
    }
}
