@charset "UTF-8";

/* ===================== NOTIFICATIONS DROPDOWN (HEADER) ===================== */

.notifications-dropdown {
    position: relative;
}

.notifications-btn {
    position: relative;
    cursor: pointer;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff4444;
    color: white;
    font-size: 11px;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Dropdown Menu - Başlangıçta Gizli */
.notifications-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 400px;
    max-height: 500px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    flex-direction: column;
    z-index: 1000;
    
    /* Başlangıçta gizli */
    display: none;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Görünür Hale Getirme */
.notifications-dropdown-menu.active,
.notifications-dropdown-menu.show {
    display: flex !important;
    opacity: 1;
    transform: translateY(0);
}

/* Header */
.notifications-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
}

.notifications-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.mark-all-read {
    font-size: 13px;
    color: #D14B2A;
    text-decoration: none;
    transition: opacity 0.2s;
    cursor: pointer;
}

.mark-all-read:hover {
    opacity: 0.8;
}

/* Notifications List */
.notifications-list {
    flex: 1;
    overflow-y: auto;
    max-height: 380px;
}

/* Custom Scrollbar */
.notifications-list::-webkit-scrollbar {
    width: 6px;
}

.notifications-list::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.notifications-list::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.notifications-list::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* Notification Item */
.notification-item {
    display: flex;
    gap: 12px;
    padding: 14px 20px;
    border-bottom: 1px solid #f5f5f5;
    cursor: pointer;
    transition: background-color 0.2s;
    position: relative;
}

.notification-item:hover {
    background-color: #f9f9f9;
}

.notification-item.unread {
    background-color: #f0f7ff;
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #D14B2A;
}

/* Notification Icon */
.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

/* Icon colors by type */
.notification-icon.ORDER { background: #e3f2fd; }
.notification-icon.PROMOTION { background: #fff3e0; }
.notification-icon.MESSAGE { background: #f3e5f5; }
.notification-icon.SECURITY { background: #ffebee; }
.notification-icon.SYSTEM,
.notification-icon.INFO { background: #e8f5e9; }
.notification-icon.WARNING { background: #fff9c4; }
.notification-icon.SUCCESS { background: #e8f5e9; }
.notification-icon.REMINDER { background: #fce4ec; }
.notification-icon.SOCIAL { background: #e1f5fe; }

/* Notification Content */
.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.notification-message {
    font-size: 13px;
    color: #666;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 4px;
}

.notification-time {
    font-size: 12px;
    color: #999;
}

/* Close Button */
.notification-close {
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    color: #999;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s, color 0.2s;
    flex-shrink: 0;
}

.notification-close:hover {
    background-color: #f5f5f5;
    color: #333;
}

/* Footer */
.notifications-footer {
    padding: 12px 20px;
    border-top: 1px solid #eee;
    text-align: center;
}

.view-all-notifications {
    display: inline-block;
    color: #D14B2A;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: opacity 0.2s;
}

.view-all-notifications:hover {
    opacity: 0.8;
}

/* Loading State */
.notifications-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    color: #999;
}

.loading-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #D14B2A;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 12px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.notifications-loading p {
    margin: 0;
    font-size: 14px;
}

/* Empty State */
.notifications-empty {
    text-align: center;
    padding: 40px 20px;
    color: #999;
}

.notifications-empty .empty-icon {
    font-size: 48px;
    margin-bottom: 10px;
    opacity: 0.5;
}

.notifications-empty p {
    margin: 0;
    font-size: 14px;
}

/* Error State */
.notifications-error {
    text-align: center;
    padding: 40px 20px;
    color: #f44336;
}

.notifications-error .error-icon {
    font-size: 48px;
    margin-bottom: 10px;
}

.notifications-error p {
    margin: 0 0 5px 0;
    font-size: 14px;
    font-weight: 600;
}

.notifications-error small {
    font-size: 12px;
    color: #999;
}

/* Toast Notifications */
.notification-toast {
    position: fixed;
    top: 80px;
    right: 20px;
    background: #2196f3;
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 10001;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideInRight 0.3s ease;
    font-size: 14px;
}

.notification-toast.toast-success { background: #4caf50; }
.notification-toast.toast-error { background: #f44336; }
.notification-toast.toast-info { background: #2196f3; }

.toast-icon {
    font-size: 18px;
    font-weight: bold;
}

.toast-message {
    flex: 1;
}

/* Toast Animations */
@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

/* Mobile Responsive - Dropdown */
@media (max-width: 768px) {
    .notifications-dropdown-menu {
        width: 320px;
        right: -10px;
    }
    
    .notification-item {
        padding: 12px 16px;
    }
    
    .notification-icon {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    
    .notification-title {
        font-size: 13px;
    }
    
    .notification-message {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .notifications-dropdown-menu {
        width: calc(100vw - 20px);
        right: 10px;
    }
}

/* ==================== NOTIFICATIONS PAGE ==================== */

.notifications-page {
    background: #f8f9fa;
    min-height: calc(100vh - 200px);
    padding: 40px 0;
}

.notifications-page-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Page Header */
.notifications-page-header {
    background: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.notifications-page-title-section {
    margin-bottom: 20px;
}

.notifications-page-title {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.notifications-page-icon {
    font-size: 36px;
}

.notifications-page-subtitle {
    font-size: 15px;
    color: #6c757d;
    margin: 0;
}

/* Filter Buttons */
.notifications-page-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.notifications-filter-btn {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #495057;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.notifications-filter-btn:hover {
    background: #e9ecef;
    border-color: #dee2e6;
}

.notifications-filter-btn.active {
    background: #4285f4;
    border-color: #4285f4;
    color: white;
}

.filter-count {
    background: rgba(0,0,0,0.1);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
}

.notifications-filter-btn.active .filter-count {
    background: rgba(255,255,255,0.2);
}

/* Bulk Actions */
.notifications-bulk-actions {
    background: white;
    border-radius: 12px;
    padding: 15px 20px;
    margin-bottom: 20px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.bulk-action-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #495057;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.bulk-action-btn:hover:not(:disabled) {
    background: #e9ecef;
    border-color: #adb5bd;
}

.bulk-action-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.bulk-action-btn.danger {
    color: #dc3545;
}

.bulk-action-btn.danger:hover:not(:disabled) {
    background: #fff5f5;
    border-color: #dc3545;
}

.bulk-action-icon {
    font-size: 16px;
}

/* Date Groups */
.notifications-date-group {
    margin-bottom: 30px;
}

.notifications-date-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    margin-bottom: 12px;
}

.notifications-date-title {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.notifications-date-count {
    font-size: 14px;
    color: #6c757d;
    background: #f8f9fa;
    padding: 4px 12px;
    border-radius: 12px;
}

/* Notification Items */
.notifications-page-list {
    margin-bottom: 30px;
}

.notification-page-item {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: flex;
    gap: 16px;
    transition: all 0.2s;
    position: relative;
}

.notification-page-item:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateX(3px);
}

.notification-page-item.unread {
    border-left: 4px solid #4285f4;
    background: #f8fbff;
}

/* Checkbox */
.notification-checkbox-wrapper {
    display: flex;
    align-items: flex-start;
    padding-top: 3px;
}

.notification-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #4285f4;
}

/* Notification Icon (Page) */
.notification-page-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
    background: #f0f0f0;
}

.notification-page-icon.ORDER { background: #e3f2fd; }
.notification-page-icon.PROMOTION { background: #fff3e0; }
.notification-page-icon.SYSTEM { background: #f3e5f5; }

/* Notification Content (Page) */
.notification-page-content {
    flex: 1;
    min-width: 0;
}

.notification-page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 10px;
}

.notification-page-title {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
    line-height: 1.4;
}

.notification-page-time {
    font-size: 13px;
    color: #999;
    white-space: nowrap;
    flex-shrink: 0;
}

.notification-page-message {
    font-size: 14px;
    color: #495057;
    line-height: 1.6;
    margin: 0 0 15px 0;
}

.notification-page-message strong {
    color: #2c3e50;
    font-weight: 600;
}

.highlight-text {
    color: #4285f4;
    font-weight: 600;
}

/* Notification Actions (Page) */
.notification-page-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.notification-action-link {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
    border: 1px solid #dee2e6;
    background: #f8f9fa;
    color: #495057;
    cursor: pointer;
}

.notification-action-link:hover {
    background: #e9ecef;
}

.notification-action-link.primary {
    background: #4285f4;
    border-color: #4285f4;
    color: white;
}

.notification-action-link.primary:hover {
    background: #1a73e8;
    border-color: #1a73e8;
}

.notification-action-link.danger {
    background: white;
    border-color: #dc3545;
    color: #dc3545;
}

.notification-action-link.danger:hover {
    background: #dc3545;
    color: white;
}

/* Close Button (Page) */
.notification-page-close {
    background: none;
    border: none;
    color: #999;
    font-size: 32px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    flex-shrink: 0;
    line-height: 1;
    align-self: flex-start;
}

.notification-page-close:hover {
    background: #f0f0f0;
    color: #666;
}

/* Empty State */
.notifications-empty-state {
    background: white;
    border-radius: 12px;
    padding: 60px 40px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.empty-state-icon {
    font-size: 80px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state-title {
    font-size: 24px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 12px 0;
}

.empty-state-message {
    font-size: 15px;
    color: #6c757d;
    line-height: 1.6;
    margin: 0 0 30px 0;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.empty-state-btn {
    display: inline-block;
    background: #4285f4;
    color: white;
    padding: 12px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.empty-state-btn:hover {
    background: #1a73e8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

/* Slide Out Animation for Delete */
@keyframes notificationSlideOut {
    from {
        opacity: 1;
        transform: translateX(0);
        max-height: 200px;
        margin-bottom: 12px;
    }
    to {
        opacity: 0;
        transform: translateX(100%);
        max-height: 0;
        margin-bottom: 0;
        padding-top: 0;
        padding-bottom: 0;
    }
}

.notification-page-item.removing {
    animation: notificationSlideOut 0.3s ease-out forwards;
    overflow: hidden;
}

@keyframes slideOut {
    from {
        opacity: 1;
        max-height: 100px;
    }
    to {
        opacity: 0;
        max-height: 0;
        margin: 0;
        padding: 0;
    }
}

/* Responsive - Page */
@media (max-width: 768px) {
    .notifications-page {
        padding: 20px 0;
    }
    
    .notifications-page-header {
        padding: 20px;
    }
    
    .notifications-page-title {
        font-size: 24px;
    }
    
    .notifications-page-icon {
        font-size: 28px;
    }
    
    .notifications-page-actions {
        gap: 8px;
    }
    
    .notifications-filter-btn {
        padding: 8px 14px;
        font-size: 13px;
    }
    
    .notifications-bulk-actions {
        padding: 12px 15px;
        gap: 8px;
    }
    
    .bulk-action-btn {
        padding: 8px 14px;
        font-size: 13px;
    }
    
    .notification-page-item {
        padding: 15px;
        flex-wrap: wrap;
    }
    
    .notification-checkbox-wrapper {
        order: 1;
    }
    
    .notification-page-icon {
        order: 2;
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .notification-page-close {
        order: 3;
        margin-left: auto;
    }
    
    .notification-page-content {
        order: 4;
        width: 100%;
    }
    
    .notification-page-header {
        flex-direction: column;
        gap: 5px;
        align-items: flex-start;
    }
    
    .notification-page-actions {
        flex-direction: column;
    }
    
    .notification-action-link {
        text-align: center;
    }
    
    .empty-state-icon {
        font-size: 60px;
    }
    
    .empty-state-title {
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .notifications-page-container {
        padding: 0 15px;
    }
    
    .notifications-filter-btn {
        flex: 1;
        min-width: calc(50% - 4px);
        justify-content: center;
    }
    
    .bulk-action-btn {
        flex: 1;
        min-width: calc(50% - 4px);
        justify-content: center;
    }
    
    .notifications-date-header {
        padding: 12px 15px;
    }
}