// Admin Notifications Styles
.admin-notifications-container {
  position: fixed;
  top: 32px;
  right: 20px;
  z-index: 999999;

  .notification-bell {
    position: relative;
    background: #667eea;
    color: white;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;

    &:hover {
      background: darken(#667eea, 10%);
      transform: translateY(-2px);
      box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
    }

    svg {
      font-size: 24px;
    }

    .notification-badge {
      position: absolute;
      top: -4px;
      right: -4px;
      background: #ff5252;
      color: white;
      border-radius: 50%;
      min-width: 20px;
      height: 20px;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 12px;
      font-weight: 600;
      border: 2px solid white;
      animation: pulse 2s infinite;
    }
  }

  .notifications-panel {
    position: absolute;
    top: 60px;
    right: 0;
    width: 380px;
    max-height: 500px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border: 1px solid #e2e8f0;
    overflow: hidden;
    animation: slideInDown 0.3s ease-out;

    .notifications-header {
      background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
      color: white;
      padding: 16px 20px;
      display: flex;
      justify-content: space-between;
      align-items: center;

      h3 {
        margin: 0;
        font-size: 16px;
        font-weight: 600;
        color: #f9f9f9;
      }

      .header-actions {
        display: flex;
        gap: 8px;

        button {
          background: rgba(255, 255, 255, 0.2);
          border: none;
          border-radius: 6px;
          width: 32px;
          height: 32px;
          display: flex;
          align-items: center;
          justify-content: center;
          cursor: pointer;
          color: white;
          transition: all 0.2s ease;

          &:hover {
            background: rgba(255, 255, 255, 0.3);
          }

          svg {
            font-size: 18px;
          }
        }
      }
    }

    .notifications-list {
      max-height: 400px;
      overflow-y: auto;
      padding: 8px 0;

      &::-webkit-scrollbar {
        width: 4px;
      }

      &::-webkit-scrollbar-thumb {
        background: #cbd5e0;
        border-radius: 2px;
      }

      &::-webkit-scrollbar-track {
        background: transparent;
      }
    }

    .notification-item {
      display: flex;
      align-items: flex-start;
      padding: 16px 20px;
      border-bottom: 1px solid #f1f5f9;
      transition: all 0.2s ease;

      &:hover {
        background: #f8fafc;
      }

      &:last-child {
        border-bottom: none;
      }

      .notification-content {
        flex: 1;
        min-width: 0;

        .notification-title {
          font-weight: 600;
          color: #2d3748;
          font-size: 14px;
          line-height: 1.4;
          margin-bottom: 8px;
        }

        .notification-meta {
          display: flex;
          flex-direction: column;
          gap: 4px;
          font-size: 12px;
          color: #718096;

          .submission-time {
            font-weight: 500;
            color: #4a5568;
          }

          .form-id {
            color: #667eea;
            font-weight: 500;
          }

          .submission-count {
            color: #38a169;
            font-weight: 600;
            font-size: 11px;
          }

          @media (min-width: 400px) {
            flex-direction: row;
            align-items: center;
            gap: 12px;
          }
        }
      }

      .notification-actions {
        display: flex;
        align-items: center;
        gap: 8px;
        margin-left: 12px;

        .view-leads-btn {
          display: flex;
          align-items: center;
          gap: 4px;
          background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
          color: white;
          border: none;
          padding: 6px 12px;
          border-radius: 6px;
          font-size: 12px;
          font-weight: 600;
          cursor: pointer;
          transition: all 0.2s ease;
          box-shadow: 0 2px 4px rgba(102, 126, 234, 0.2);

          &:hover {
            background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 100%);
            transform: translateY(-1px);
            box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
          }

          &:active {
            transform: translateY(0);
          }

          svg {
            font-size: 14px;
          }

          span {
            @media (max-width: 380px) {
              display: none;
            }
          }
        }

        .mark-read-btn {
          background: none;
          border: none;
          color: #a0aec0;
          cursor: pointer;
          padding: 6px;
          border-radius: 4px;
          transition: all 0.2s ease;
          display: flex;
          align-items: center;
          justify-content: center;

          &:hover {
            background: #f1f5f9;
            color: #718096;
          }

          svg {
            font-size: 16px;
          }
        }
      }
    }

    .loading-state,
    .no-notifications {
      padding: 40px 20px;
      text-align: center;
      color: #718096;
      font-size: 14px;
    }

    .no-notifications p {
      margin: 0;
    }
  }
}

// Loading spinner styles
.dismiss-all-btn {
  .loading-spinner {
    margin-left: 4px;
    font-size: 12px;
    animation: spin 1s linear infinite;
  }

  &:disabled {
    opacity: 0.6;
    cursor: not-allowed;
  }
}

// Animations
@keyframes pulse {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.1);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

// Responsive adjustments
@media (max-width: 768px) {
  .admin-notifications-container {
    right: 10px;

    .notifications-panel {
      width: 340px;
      right: -10px;
    }
  }
}

@media (max-width: 480px) {
  .admin-notifications-container {
    .notifications-panel {
      width: 300px;
      right: -20px;

      .notification-item {
        padding: 12px 16px;

        .notification-content {
          .notification-title {
            font-size: 13px;
          }

          .notification-meta {
            font-size: 11px;
          }
        }

        .notification-actions {
          flex-direction: column;
          gap: 6px;
          margin-left: 8px;

          .view-leads-btn {
            padding: 4px 8px;
            font-size: 11px;

            svg {
              font-size: 12px;
            }
          }

          .mark-read-btn {
            padding: 4px;

            svg {
              font-size: 14px;
            }
          }
        }
      }
    }
  }
}

@media (max-width: 360px) {
  .admin-notifications-container {
    .notifications-panel {
      width: calc(100vw - 40px);
      right: -10px;
    }
  }
}